Giter Site home page Giter Site logo

crystalla's People

Contributors

asterite avatar dkhofer avatar spalladino avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

crystalla's Issues

Add rows to matrix / Add element to Ndarray: shouldn't it add it to the existing object instead of returning a new one ?

I'm experimenting with a new Ndarray class and while creating a class method add_element, I took a look at how the add_rows method was coded for the Matrix class, and I noticed that it wasn't modifying the object, but was returning a new one.

Instinctively, I would expect that I could do:

matrix = Crystalla::Matrix.new([1.0, 2.0, 2.0, 3.0], 2, 2)
p matrix
>> Matrix[[ 1.0, 2.0 ],
       [ 2.0, 3.0 ]]
matrix.add_rows(1, Crystalla::Matrix.new([4.5, 3.0], 1,2))
p matrix 
>> Matrix[[ 1.0, 2.0 ],
       [ 4.5, 3.0 ],
       [ 2.0, 3.0 ]]

Instead, I need to assign it to a new instance to get the modified matrix:
matrix2 = matrix.add_rows(1, Crystalla::Matrix.new([4.5, 3.0], 1,2))

Is there a particular reason why you made this choice ?
For Ndarrays, it would seem more natural to do:

array = Crystalla::Ndarray.new([1.0, 2.0, 2.0, 3.0])
array.add_element(6.0, 1)
p array 
>> Ndarray [1.0, 6.0, 2.0, 2.0, 3.0]

Let me know what you think !

Vector support

Hi, I have started to play with Crystal. For now, I'm trying to migrate some scripts I had in ruby with some algorithms implementations (about all ML algorithms). I could migrate some matrices using this library, but I couldn't find support for Vector class in Crystal and neither crystalla.

http://ruby-doc.org/stdlib-2.2.1/libdoc/matrix/rdoc/Vector.html

Can you help me? I am willing to contribute with these kind of libraries when I have enough knowledge and experience with Crystal , I think it has an enormous potential for Data Science, and I eventually want to use it in some real data oriented projects ๐Ÿ˜„

Load/Save to .npy files

The .npy file format has become standard to serialize arrays, so I think crystalla could really use it. It will open up possibility of interoperability with other systems such as tensorflow/python. WDYT?

Installation issues

Hi !

I'm trying to require crystalla in a small script but it crashes at the require.

Error in eig.cr:1: while requiring "crystalla"

require "crystalla"
^

in lib/crystalla/src/crystalla.cr:1: while requiring "./crystalla/*"

require "./crystalla/*"
^

Syntax error in lib/crystalla/src/crystalla/lib_blas.cr:4: expecting identifier 'end', not 'else'

  else
  ^

Since there isn't a lot of users yet, it's hard to find answers elsewhere. Is this a common issue ?

My shard.yml:

dependencies:
  crystalla:
    github: mverzilli/crystalla

Any idea ?

Thanks a lot

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.