grx-tensor 0.2.0 → 0.2.1
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 +4 -4
- data/CHANGELOG.md +9 -0
- data/GUIA_PRINCIPIANTES.md +307 -24
- data/README.es.md +1090 -161
- data/README.md +1102 -162
- data/ext/grx/extconf.rb +4 -18
- data/ext/grx/grx_core.c +411 -331
- data/ext/grx/grx_core.h +23 -13
- data/ext/unix/Makefile +3 -27
- data/ext/windows/Makefile.mingw +3 -23
- data/grx-tensor.gemspec +37 -33
- data/lib/grx/c_api.rb +47 -15
- data/lib/grx/nn.rb +9 -7
- data/lib/grx/optim.rb +12 -7
- data/lib/grx/storage.rb +6 -5
- data/lib/grx/tensor.rb +36 -0
- data/lib/grx/utils.rb +15 -0
- data/lib/grx/version.rb +1 -1
- data/lib/grx.rb +8 -3
- metadata +31 -27
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: grx-tensor
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Razo
|
|
@@ -67,8 +67,9 @@ dependencies:
|
|
|
67
67
|
version: '2.0'
|
|
68
68
|
description: |
|
|
69
69
|
GRX brings PyTorch-style tensor operations to Ruby. Every arithmetic op,
|
|
70
|
-
activation, and optimizer step runs through a native C library
|
|
71
|
-
|
|
70
|
+
activation, and optimizer step runs through a native C library with
|
|
71
|
+
dynamic multi-target SIMD dispatch (AVX2+FMA, SSE, and scalar fallback).
|
|
72
|
+
Ruby is the interface — C does the work.
|
|
72
73
|
|
|
73
74
|
Features: autograd, SGD/Adam optimizers, Linear/Sequential/Dropout/BatchNorm
|
|
74
75
|
layers, MSE/BCE/CrossEntropy loss functions, Xavier and He weight init.
|
|
@@ -112,36 +113,39 @@ metadata:
|
|
|
112
113
|
bug_tracker_uri: https://github.com/Gabo-Razo/grx-tensor/issues
|
|
113
114
|
post_install_message: |2+
|
|
114
115
|
|
|
115
|
-
|
|
116
|
-
GRX-Tensor 0.2.
|
|
117
|
-
|
|
116
|
+
============================================================
|
|
117
|
+
GRX-Tensor 0.2.1
|
|
118
|
+
============================================================
|
|
118
119
|
|
|
119
|
-
|
|
120
|
+
[ENGLISH]
|
|
121
|
+
Thank you for choosing and using GRX-Tensor!
|
|
120
122
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
+
* Native C acceleration with dynamic SIMD dispatch
|
|
124
|
+
(AVX2+FMA, SSE, and portable scalar C) is built and
|
|
125
|
+
configured automatically.
|
|
126
|
+
* Windows Note: Native C acceleration is supported when
|
|
127
|
+
using RubyInstaller with DevKit (MSYS2 / MinGW-w64).
|
|
128
|
+
Standalone pre-compiled Windows binaries are currently
|
|
129
|
+
in active development.
|
|
130
|
+
* Documentation, guides, and tutorials:
|
|
131
|
+
https://github.com/Gabo-Razo/grx-tensor
|
|
123
132
|
|
|
124
|
-
|
|
133
|
+
----------------------------------------------------------
|
|
125
134
|
|
|
126
|
-
|
|
135
|
+
[ESPAÑOL]
|
|
136
|
+
Muchas gracias por elegir y utilizar GRX-Tensor!
|
|
127
137
|
|
|
128
|
-
|
|
138
|
+
* La aceleracion nativa en C con despacho dinamico SIMD
|
|
139
|
+
(AVX2+FMA, SSE y C escalar portable) se compila y
|
|
140
|
+
configura de forma totalmente automatica.
|
|
141
|
+
* Nota para Windows: La aceleracion nativa esta soportada
|
|
142
|
+
al utilizar RubyInstaller con DevKit (MSYS2 / MinGW-w64).
|
|
143
|
+
Los binarios pre-compilados independientes para Windows
|
|
144
|
+
se encuentran actualmente en desarrollo activo.
|
|
145
|
+
* Documentacion, guias y tutoriales:
|
|
146
|
+
https://github.com/Gabo-Razo/grx-tensor
|
|
129
147
|
|
|
130
|
-
|
|
131
|
-
b = GRX.tensor([4.0, 5.0, 6.0], [3], requires_grad: true)
|
|
132
|
-
c = a + b
|
|
133
|
-
c.backward
|
|
134
|
-
puts a.grad.to_a # [1.0, 1.0, 1.0]
|
|
135
|
-
|
|
136
|
-
net = GRX::NN::Sequential.new(
|
|
137
|
-
GRX::NN::Linear.new(4, 16),
|
|
138
|
-
GRX::NN::ReLU.new,
|
|
139
|
-
GRX::NN::Linear.new(16, 1)
|
|
140
|
-
)
|
|
141
|
-
opt = GRX::Optim::Adam.new(net.parameters, lr: 0.001)
|
|
142
|
-
|
|
143
|
-
Docs: https://github.com/Gabo-Razo/grx-tensor
|
|
144
|
-
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
148
|
+
============================================================
|
|
145
149
|
|
|
146
150
|
rdoc_options: []
|
|
147
151
|
require_paths:
|