gumath 0.2.0dev5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/CONTRIBUTING.md +61 -0
- data/Gemfile +5 -0
- data/History.md +0 -0
- data/README.md +5 -0
- data/Rakefile +105 -0
- data/ext/ruby_gumath/examples.c +126 -0
- data/ext/ruby_gumath/extconf.rb +97 -0
- data/ext/ruby_gumath/functions.c +106 -0
- data/ext/ruby_gumath/gufunc_object.c +79 -0
- data/ext/ruby_gumath/gufunc_object.h +55 -0
- data/ext/ruby_gumath/gumath/AUTHORS.txt +5 -0
- data/ext/ruby_gumath/gumath/INSTALL.txt +42 -0
- data/ext/ruby_gumath/gumath/LICENSE.txt +29 -0
- data/ext/ruby_gumath/gumath/MANIFEST.in +3 -0
- data/ext/ruby_gumath/gumath/Makefile.in +62 -0
- data/ext/ruby_gumath/gumath/README.rst +20 -0
- data/ext/ruby_gumath/gumath/config.guess +1530 -0
- data/ext/ruby_gumath/gumath/config.h.in +52 -0
- data/ext/ruby_gumath/gumath/config.sub +1782 -0
- data/ext/ruby_gumath/gumath/configure +5049 -0
- data/ext/ruby_gumath/gumath/configure.ac +167 -0
- data/ext/ruby_gumath/gumath/doc/_static/copybutton.js +66 -0
- data/ext/ruby_gumath/gumath/doc/conf.py +26 -0
- data/ext/ruby_gumath/gumath/doc/gumath/functions.rst +62 -0
- data/ext/ruby_gumath/gumath/doc/gumath/index.rst +26 -0
- data/ext/ruby_gumath/gumath/doc/index.rst +45 -0
- data/ext/ruby_gumath/gumath/doc/libgumath/data-structures.rst +130 -0
- data/ext/ruby_gumath/gumath/doc/libgumath/functions.rst +78 -0
- data/ext/ruby_gumath/gumath/doc/libgumath/index.rst +25 -0
- data/ext/ruby_gumath/gumath/doc/libgumath/kernels.rst +41 -0
- data/ext/ruby_gumath/gumath/doc/releases/index.rst +11 -0
- data/ext/ruby_gumath/gumath/install-sh +527 -0
- data/ext/ruby_gumath/gumath/libgumath/Makefile.in +170 -0
- data/ext/ruby_gumath/gumath/libgumath/Makefile.vc +160 -0
- data/ext/ruby_gumath/gumath/libgumath/apply.c +201 -0
- data/ext/ruby_gumath/gumath/libgumath/extending/bfloat16.c +130 -0
- data/ext/ruby_gumath/gumath/libgumath/extending/examples.c +176 -0
- data/ext/ruby_gumath/gumath/libgumath/extending/graph.c +393 -0
- data/ext/ruby_gumath/gumath/libgumath/extending/pdist.c +140 -0
- data/ext/ruby_gumath/gumath/libgumath/extending/quaternion.c +156 -0
- data/ext/ruby_gumath/gumath/libgumath/func.c +177 -0
- data/ext/ruby_gumath/gumath/libgumath/gumath.h +205 -0
- data/ext/ruby_gumath/gumath/libgumath/kernels/binary.c +547 -0
- data/ext/ruby_gumath/gumath/libgumath/kernels/unary.c +449 -0
- data/ext/ruby_gumath/gumath/libgumath/nploops.c +219 -0
- data/ext/ruby_gumath/gumath/libgumath/tbl.c +223 -0
- data/ext/ruby_gumath/gumath/libgumath/thread.c +175 -0
- data/ext/ruby_gumath/gumath/libgumath/xndloops.c +130 -0
- data/ext/ruby_gumath/gumath/python/extending.py +24 -0
- data/ext/ruby_gumath/gumath/python/gumath/__init__.py +74 -0
- data/ext/ruby_gumath/gumath/python/gumath/_gumath.c +577 -0
- data/ext/ruby_gumath/gumath/python/gumath/examples.c +93 -0
- data/ext/ruby_gumath/gumath/python/gumath/functions.c +77 -0
- data/ext/ruby_gumath/gumath/python/gumath/pygumath.h +95 -0
- data/ext/ruby_gumath/gumath/python/test_gumath.py +405 -0
- data/ext/ruby_gumath/gumath/setup.py +298 -0
- data/ext/ruby_gumath/gumath/vcbuild/INSTALL.txt +36 -0
- data/ext/ruby_gumath/gumath/vcbuild/vcbuild32.bat +21 -0
- data/ext/ruby_gumath/gumath/vcbuild/vcbuild64.bat +21 -0
- data/ext/ruby_gumath/gumath/vcbuild/vcclean.bat +10 -0
- data/ext/ruby_gumath/gumath/vcbuild/vcdistclean.bat +11 -0
- data/ext/ruby_gumath/include/gumath.h +205 -0
- data/ext/ruby_gumath/include/ruby_gumath.h +41 -0
- data/ext/ruby_gumath/lib/libgumath.a +0 -0
- data/ext/ruby_gumath/lib/libgumath.so +1 -0
- data/ext/ruby_gumath/lib/libgumath.so.0 +1 -0
- data/ext/ruby_gumath/lib/libgumath.so.0.2.0dev3 +0 -0
- data/ext/ruby_gumath/ruby_gumath.c +295 -0
- data/ext/ruby_gumath/ruby_gumath.h +41 -0
- data/ext/ruby_gumath/ruby_gumath_internal.h +45 -0
- data/ext/ruby_gumath/util.c +68 -0
- data/ext/ruby_gumath/util.h +48 -0
- data/gumath.gemspec +47 -0
- data/lib/gumath.rb +7 -0
- data/lib/gumath/version.rb +5 -0
- data/lib/ruby_gumath.so +0 -0
- metadata +206 -0
@@ -0,0 +1,48 @@
|
|
1
|
+
/* BSD 3-Clause License
|
2
|
+
*
|
3
|
+
* Copyright (c) 2018, Quansight and Sameer Deshmukh
|
4
|
+
* All rights reserved.
|
5
|
+
*
|
6
|
+
* Redistribution and use in source and binary forms, with or without
|
7
|
+
* modification, are permitted provided that the following conditions are met:
|
8
|
+
*
|
9
|
+
* * Redistributions of source code must retain the above copyright notice, this
|
10
|
+
* list of conditions and the following disclaimer.
|
11
|
+
*
|
12
|
+
* * Redistributions in binary form must reproduce the above copyright notice,
|
13
|
+
* this list of conditions and the following disclaimer in the documentation
|
14
|
+
* and/or other materials provided with the distribution.
|
15
|
+
*
|
16
|
+
* * Neither the name of the copyright holder nor the names of its
|
17
|
+
* contributors may be used to endorse or promote products derived from
|
18
|
+
* this software without specific prior written permission.
|
19
|
+
*
|
20
|
+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
21
|
+
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
22
|
+
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
23
|
+
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
24
|
+
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
25
|
+
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
26
|
+
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
27
|
+
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
28
|
+
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
29
|
+
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
30
|
+
*/
|
31
|
+
|
32
|
+
/*
|
33
|
+
Utility functions for gumath.
|
34
|
+
*/
|
35
|
+
|
36
|
+
#ifndef GUMATH_UTIL_H
|
37
|
+
#define GUMATH_UTIL_H
|
38
|
+
|
39
|
+
VALUE array_new(int64_t size);
|
40
|
+
|
41
|
+
int xnd_exists(void);
|
42
|
+
|
43
|
+
int ndt_exists(void);
|
44
|
+
|
45
|
+
/* Raise an error stored in $!. Clears it before raising. */
|
46
|
+
void raise_error(void);
|
47
|
+
|
48
|
+
#endif /* GUMATH_UTIL_H */
|
data/gumath.gemspec
ADDED
@@ -0,0 +1,47 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
$:.unshift File.expand_path("../lib", __FILE__)
|
3
|
+
|
4
|
+
require 'gumath/version.rb'
|
5
|
+
|
6
|
+
def self.get_files
|
7
|
+
files = []
|
8
|
+
['ext', 'lib', 'spec'].each do |folder|
|
9
|
+
files.concat Dir.glob "#{folder}/**/*"
|
10
|
+
end
|
11
|
+
|
12
|
+
files.concat(
|
13
|
+
["CONTRIBUTING.md", "Gemfile", "History.md", "gumath.gemspec",
|
14
|
+
"README.md", "Rakefile"
|
15
|
+
])
|
16
|
+
|
17
|
+
files
|
18
|
+
end
|
19
|
+
files = get_files
|
20
|
+
|
21
|
+
Gumath::DESCRIPTION = <<MSG
|
22
|
+
Gumath is library for function dispatch to XND containers.
|
23
|
+
MSG
|
24
|
+
|
25
|
+
Gem::Specification.new do |spec|
|
26
|
+
spec.name = 'gumath'
|
27
|
+
spec.version = Gumath::VERSION
|
28
|
+
spec.authors = ['Sameer Deshmukh']
|
29
|
+
spec.email = ['sameer.deshmukh93@gmail.com']
|
30
|
+
spec.summary = %q{Ruby wrapper over libgumath. A library for dispatching math kernels.}
|
31
|
+
spec.description = Gumath::DESCRIPTION
|
32
|
+
spec.homepage = "https://github.com/plures/gumath"
|
33
|
+
spec.license = 'BSD-3 Clause'
|
34
|
+
|
35
|
+
spec.files = files
|
36
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
37
|
+
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
38
|
+
spec.require_paths = ["lib"]
|
39
|
+
|
40
|
+
spec.add_development_dependency 'minitest', '~> 5.11'
|
41
|
+
spec.add_development_dependency 'rake-compiler'
|
42
|
+
spec.add_development_dependency 'pry'
|
43
|
+
spec.add_development_dependency 'pry-byebug'
|
44
|
+
|
45
|
+
spec.add_runtime_dependency 'ndtypes', '>= 0.2.0dev5'
|
46
|
+
spec.add_runtime_dependency 'xnd', '>= 0.2.0dev5'
|
47
|
+
end
|
data/lib/gumath.rb
ADDED
data/lib/ruby_gumath.so
ADDED
Binary file
|
metadata
ADDED
@@ -0,0 +1,206 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: gumath
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.2.0dev5
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Sameer Deshmukh
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2018-09-26 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: minitest
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '5.11'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '5.11'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake-compiler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: pry
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: pry-byebug
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: ndtypes
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 0.2.0dev5
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 0.2.0dev5
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: xnd
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 0.2.0dev5
|
90
|
+
type: :runtime
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 0.2.0dev5
|
97
|
+
description: 'Gumath is library for function dispatch to XND containers.
|
98
|
+
|
99
|
+
'
|
100
|
+
email:
|
101
|
+
- sameer.deshmukh93@gmail.com
|
102
|
+
executables: []
|
103
|
+
extensions: []
|
104
|
+
extra_rdoc_files: []
|
105
|
+
files:
|
106
|
+
- CONTRIBUTING.md
|
107
|
+
- Gemfile
|
108
|
+
- History.md
|
109
|
+
- README.md
|
110
|
+
- Rakefile
|
111
|
+
- ext/ruby_gumath/examples.c
|
112
|
+
- ext/ruby_gumath/extconf.rb
|
113
|
+
- ext/ruby_gumath/functions.c
|
114
|
+
- ext/ruby_gumath/gufunc_object.c
|
115
|
+
- ext/ruby_gumath/gufunc_object.h
|
116
|
+
- ext/ruby_gumath/gumath/AUTHORS.txt
|
117
|
+
- ext/ruby_gumath/gumath/INSTALL.txt
|
118
|
+
- ext/ruby_gumath/gumath/LICENSE.txt
|
119
|
+
- ext/ruby_gumath/gumath/MANIFEST.in
|
120
|
+
- ext/ruby_gumath/gumath/Makefile.in
|
121
|
+
- ext/ruby_gumath/gumath/README.rst
|
122
|
+
- ext/ruby_gumath/gumath/config.guess
|
123
|
+
- ext/ruby_gumath/gumath/config.h.in
|
124
|
+
- ext/ruby_gumath/gumath/config.sub
|
125
|
+
- ext/ruby_gumath/gumath/configure
|
126
|
+
- ext/ruby_gumath/gumath/configure.ac
|
127
|
+
- ext/ruby_gumath/gumath/doc/_static/copybutton.js
|
128
|
+
- ext/ruby_gumath/gumath/doc/conf.py
|
129
|
+
- ext/ruby_gumath/gumath/doc/gumath/functions.rst
|
130
|
+
- ext/ruby_gumath/gumath/doc/gumath/index.rst
|
131
|
+
- ext/ruby_gumath/gumath/doc/index.rst
|
132
|
+
- ext/ruby_gumath/gumath/doc/libgumath/data-structures.rst
|
133
|
+
- ext/ruby_gumath/gumath/doc/libgumath/functions.rst
|
134
|
+
- ext/ruby_gumath/gumath/doc/libgumath/index.rst
|
135
|
+
- ext/ruby_gumath/gumath/doc/libgumath/kernels.rst
|
136
|
+
- ext/ruby_gumath/gumath/doc/releases/index.rst
|
137
|
+
- ext/ruby_gumath/gumath/install-sh
|
138
|
+
- ext/ruby_gumath/gumath/libgumath/Makefile.in
|
139
|
+
- ext/ruby_gumath/gumath/libgumath/Makefile.vc
|
140
|
+
- ext/ruby_gumath/gumath/libgumath/apply.c
|
141
|
+
- ext/ruby_gumath/gumath/libgumath/extending/bfloat16.c
|
142
|
+
- ext/ruby_gumath/gumath/libgumath/extending/examples.c
|
143
|
+
- ext/ruby_gumath/gumath/libgumath/extending/graph.c
|
144
|
+
- ext/ruby_gumath/gumath/libgumath/extending/pdist.c
|
145
|
+
- ext/ruby_gumath/gumath/libgumath/extending/quaternion.c
|
146
|
+
- ext/ruby_gumath/gumath/libgumath/func.c
|
147
|
+
- ext/ruby_gumath/gumath/libgumath/gumath.h
|
148
|
+
- ext/ruby_gumath/gumath/libgumath/kernels/binary.c
|
149
|
+
- ext/ruby_gumath/gumath/libgumath/kernels/unary.c
|
150
|
+
- ext/ruby_gumath/gumath/libgumath/nploops.c
|
151
|
+
- ext/ruby_gumath/gumath/libgumath/tbl.c
|
152
|
+
- ext/ruby_gumath/gumath/libgumath/thread.c
|
153
|
+
- ext/ruby_gumath/gumath/libgumath/xndloops.c
|
154
|
+
- ext/ruby_gumath/gumath/python/extending.py
|
155
|
+
- ext/ruby_gumath/gumath/python/gumath/__init__.py
|
156
|
+
- ext/ruby_gumath/gumath/python/gumath/_gumath.c
|
157
|
+
- ext/ruby_gumath/gumath/python/gumath/examples.c
|
158
|
+
- ext/ruby_gumath/gumath/python/gumath/functions.c
|
159
|
+
- ext/ruby_gumath/gumath/python/gumath/pygumath.h
|
160
|
+
- ext/ruby_gumath/gumath/python/test_gumath.py
|
161
|
+
- ext/ruby_gumath/gumath/setup.py
|
162
|
+
- ext/ruby_gumath/gumath/vcbuild/INSTALL.txt
|
163
|
+
- ext/ruby_gumath/gumath/vcbuild/vcbuild32.bat
|
164
|
+
- ext/ruby_gumath/gumath/vcbuild/vcbuild64.bat
|
165
|
+
- ext/ruby_gumath/gumath/vcbuild/vcclean.bat
|
166
|
+
- ext/ruby_gumath/gumath/vcbuild/vcdistclean.bat
|
167
|
+
- ext/ruby_gumath/include/gumath.h
|
168
|
+
- ext/ruby_gumath/include/ruby_gumath.h
|
169
|
+
- ext/ruby_gumath/lib/libgumath.a
|
170
|
+
- ext/ruby_gumath/lib/libgumath.so
|
171
|
+
- ext/ruby_gumath/lib/libgumath.so.0
|
172
|
+
- ext/ruby_gumath/lib/libgumath.so.0.2.0dev3
|
173
|
+
- ext/ruby_gumath/ruby_gumath.c
|
174
|
+
- ext/ruby_gumath/ruby_gumath.h
|
175
|
+
- ext/ruby_gumath/ruby_gumath_internal.h
|
176
|
+
- ext/ruby_gumath/util.c
|
177
|
+
- ext/ruby_gumath/util.h
|
178
|
+
- gumath.gemspec
|
179
|
+
- lib/gumath.rb
|
180
|
+
- lib/gumath/version.rb
|
181
|
+
- lib/ruby_gumath.so
|
182
|
+
homepage: https://github.com/plures/gumath
|
183
|
+
licenses:
|
184
|
+
- BSD-3 Clause
|
185
|
+
metadata: {}
|
186
|
+
post_install_message:
|
187
|
+
rdoc_options: []
|
188
|
+
require_paths:
|
189
|
+
- lib
|
190
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
191
|
+
requirements:
|
192
|
+
- - ">="
|
193
|
+
- !ruby/object:Gem::Version
|
194
|
+
version: '0'
|
195
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
196
|
+
requirements:
|
197
|
+
- - ">"
|
198
|
+
- !ruby/object:Gem::Version
|
199
|
+
version: 1.3.1
|
200
|
+
requirements: []
|
201
|
+
rubyforge_project:
|
202
|
+
rubygems_version: 2.6.14
|
203
|
+
signing_key:
|
204
|
+
specification_version: 4
|
205
|
+
summary: Ruby wrapper over libgumath. A library for dispatching math kernels.
|
206
|
+
test_files: []
|