Created
November 6, 2016 10:39
-
-
Save vaiorabbit/1534cbbbf204cceb35df961feb8460a7 to your computer and use it in GitHub Desktop.
NMatrix ( https://github.com/SciRuby/nmatrix ) test.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
# $ which gcc-6 | |
# /usr/local/bin/gcc-6 | |
# $ CXX=`which g++-6` CC=`which gcc-6` rvm install ruby-2.3.1 | |
# $ rvm use --default ruby-2.3.1 | |
# $ ruby --version | |
# ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin16] | |
# $ gem install nmatrix | |
# https://github.com/SciRuby/nmatrix | |
require 'nmatrix' | |
mtx = NMatrix.new([2, 3], [0, 1, 2, 3, 4, 5], dtype: :int64) | |
p mtx.shape # => [2, 3] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment