nmatrix-atlas 0.2.1 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ext/nmatrix/data/data.h +7 -8
- data/ext/nmatrix/data/ruby_object.h +1 -4
- data/ext/nmatrix/math/asum.h +10 -31
- data/ext/nmatrix/math/cblas_templates_core.h +10 -10
- data/ext/nmatrix/math/getrf.h +2 -2
- data/ext/nmatrix/math/imax.h +12 -9
- data/ext/nmatrix/math/laswp.h +3 -3
- data/ext/nmatrix/math/long_dtype.h +16 -3
- data/ext/nmatrix/math/magnitude.h +54 -0
- data/ext/nmatrix/math/nrm2.h +19 -14
- data/ext/nmatrix/math/trsm.h +40 -36
- data/ext/nmatrix/math/util.h +14 -0
- data/ext/nmatrix/nmatrix.h +39 -1
- data/ext/nmatrix/storage/common.h +9 -3
- data/ext/nmatrix/storage/yale/class.h +1 -1
- data/ext/nmatrix_atlas/extconf.rb +3 -131
- data/ext/nmatrix_atlas/math_atlas.cpp +15 -15
- data/lib/nmatrix/atlas.rb +59 -28
- data/spec/00_nmatrix_spec.rb +50 -1
- data/spec/02_slice_spec.rb +21 -21
- data/spec/blas_spec.rb +25 -3
- data/spec/math_spec.rb +233 -5
- data/spec/shortcuts_spec.rb +145 -5
- data/spec/spec_helper.rb +24 -1
- metadata +18 -8
data/spec/spec_helper.rb
CHANGED
@@ -32,7 +32,7 @@ require "./lib/nmatrix/rspec"
|
|
32
32
|
|
33
33
|
ALL_DTYPES = [:byte,:int8,:int16,:int32,:int64, :float32,:float64, :object,
|
34
34
|
:complex64, :complex128]
|
35
|
-
|
35
|
+
|
36
36
|
NON_INTEGER_DTYPES = [:float32, :float64, :complex64, :complex128,
|
37
37
|
:object]
|
38
38
|
|
@@ -48,6 +48,29 @@ COMPLEX_MATRIX32A_ARRAY = MATRIX32A_ARRAY.zip(MATRIX32A_ARRAY.reverse).collect {
|
|
48
48
|
GETRF_EXAMPLE_ARRAY = [-1,0,10,4,9,2,3,5,7,8,1,6]
|
49
49
|
GETRF_SOLUTION_ARRAY = [9.0, 2.0, 3.0, 5.0, 7.0/9, 58.0/9, -4.0/3, 19.0/9, -1.0/9, 1.0/29, 301.0/29, 130.0/29]
|
50
50
|
|
51
|
+
TAU_SOLUTION_ARRAY = [1.8571428571428572,1.9938461538461538, 0.0]
|
52
|
+
|
53
|
+
GEQRF_SOLUTION_ARRAY =[ -14.0, -21.0, 14.000000000000002,
|
54
|
+
0.23076923076923078, -175.00000000000003, 70.00000000000001,
|
55
|
+
-0.15384615384615385, 0.055555555555555546, -35.0]
|
56
|
+
|
57
|
+
R_SOLUTION_ARRAY = [-159.2388143638353, -41.00131005172065, -56.75123892439876, -90.75048729628048,
|
58
|
+
0.0, 25.137473501580676, 2.073591725046292, 9.790607357775713,
|
59
|
+
0.0, 0.0, -20.83259700334131, -17.592414929551445]
|
60
|
+
|
61
|
+
Q_SOLUTION_ARRAY_1 = [-0.632455532033676, -0.5209522876558295, -0.3984263084135902, -0.41214704991068,
|
62
|
+
-0.42783756578748666, -0.20837937347171134, 0.876505919951498, 0.07259770177184455,
|
63
|
+
-0.48364246567281094, 0.8265854747306287,-0.015758658987033422, -0.2873988222474053,
|
64
|
+
-0.42783756578748666, 0.044081783789183565, -0.26971376257215296, 0.8615487797670971]
|
65
|
+
|
66
|
+
Q_SOLUTION_ARRAY_2 = [-0.8571428571428572, 0.3942857142857143, 0.33142857142857146,
|
67
|
+
-0.4285714285714286, -0.9028571428571428, -0.03428571428571425,
|
68
|
+
0.28571428571428575, -0.1714285714285714, 0.9428571428571428]
|
69
|
+
|
70
|
+
Q_SOLUTION_ARRAY_3 = [-0.7724247413634004, -0.026670393594597247, -0.6345460653374136,
|
71
|
+
-0.5777485870360393, -0.38541856437557026, 0.7194853024298236,
|
72
|
+
-0.26375478973384403, 0.9223563413020934, 0.28229805268947933]
|
73
|
+
|
51
74
|
def create_matrix(stype) #:nodoc:
|
52
75
|
m = NMatrix.new([3,3], 0, dtype: :int32, stype: stype, default: 0)
|
53
76
|
|
metadata
CHANGED
@@ -1,16 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nmatrix-atlas
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
+
- Will Levine
|
7
8
|
- John Woods
|
8
|
-
- Chris Wailes
|
9
|
-
- Aleksey Timin
|
10
9
|
autorequire:
|
11
10
|
bindir: bin
|
12
11
|
cert_chain: []
|
13
|
-
date: 2016-
|
12
|
+
date: 2016-07-25 00:00:00.000000000 Z
|
14
13
|
dependencies:
|
15
14
|
- !ruby/object:Gem::Dependency
|
16
15
|
name: nmatrix
|
@@ -18,14 +17,14 @@ dependencies:
|
|
18
17
|
requirements:
|
19
18
|
- - '='
|
20
19
|
- !ruby/object:Gem::Version
|
21
|
-
version: 0.2.
|
20
|
+
version: 0.2.3
|
22
21
|
type: :runtime
|
23
22
|
prerelease: false
|
24
23
|
version_requirements: !ruby/object:Gem::Requirement
|
25
24
|
requirements:
|
26
25
|
- - '='
|
27
26
|
- !ruby/object:Gem::Version
|
28
|
-
version: 0.2.
|
27
|
+
version: 0.2.3
|
29
28
|
description: For using linear algebra fuctions provided by ATLAS
|
30
29
|
email:
|
31
30
|
- john.o.woods@gmail.com
|
@@ -48,6 +47,7 @@ files:
|
|
48
47
|
- ext/nmatrix/math/imax.h
|
49
48
|
- ext/nmatrix/math/laswp.h
|
50
49
|
- ext/nmatrix/math/long_dtype.h
|
50
|
+
- ext/nmatrix/math/magnitude.h
|
51
51
|
- ext/nmatrix/math/math.h
|
52
52
|
- ext/nmatrix/math/nrm2.h
|
53
53
|
- ext/nmatrix/math/rot.h
|
@@ -116,7 +116,7 @@ files:
|
|
116
116
|
- spec/utm5940.mtx
|
117
117
|
homepage: http://sciruby.com
|
118
118
|
licenses:
|
119
|
-
- BSD
|
119
|
+
- BSD-3-Clause
|
120
120
|
metadata: {}
|
121
121
|
post_install_message:
|
122
122
|
rdoc_options: []
|
@@ -134,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
134
134
|
version: '0'
|
135
135
|
requirements: []
|
136
136
|
rubyforge_project:
|
137
|
-
rubygems_version: 2.
|
137
|
+
rubygems_version: 2.5.1
|
138
138
|
signing_key:
|
139
139
|
specification_version: 4
|
140
140
|
summary: ATLAS backend for nmatrix
|
@@ -143,17 +143,27 @@ test_files:
|
|
143
143
|
- spec/01_enum_spec.rb
|
144
144
|
- spec/02_slice_spec.rb
|
145
145
|
- spec/03_nmatrix_monkeys_spec.rb
|
146
|
+
- spec/2x2_dense_double.mat
|
147
|
+
- spec/4x4_sparse.mat
|
148
|
+
- spec/4x5_dense.mat
|
146
149
|
- spec/blas_spec.rb
|
147
150
|
- spec/elementwise_spec.rb
|
148
151
|
- spec/homogeneous_spec.rb
|
149
152
|
- spec/io/fortran_format_spec.rb
|
150
153
|
- spec/io/harwell_boeing_spec.rb
|
154
|
+
- spec/io/test.rua
|
151
155
|
- spec/io_spec.rb
|
152
156
|
- spec/lapack_core_spec.rb
|
157
|
+
- spec/leakcheck.rb
|
153
158
|
- spec/math_spec.rb
|
159
|
+
- spec/nmatrix_yale_resize_test_associations.yaml
|
154
160
|
- spec/nmatrix_yale_spec.rb
|
161
|
+
- spec/rspec_monkeys.rb
|
155
162
|
- spec/rspec_spec.rb
|
156
163
|
- spec/shortcuts_spec.rb
|
157
164
|
- spec/slice_set_spec.rb
|
165
|
+
- spec/spec_helper.rb
|
158
166
|
- spec/stat_spec.rb
|
167
|
+
- spec/test.pcd
|
168
|
+
- spec/utm5940.mtx
|
159
169
|
- spec/plugins/atlas/atlas_spec.rb
|