Comments (11)
@sharath @djsaunde Has there been any movement on this? If not it is something I can crank out rev 1 of this week. I will probably first look into subclassing torch.nn.Module
as it would provide the most functionality for the least work. Some benefits to exploit out of the box:
.to(device)
will allow for management of devices directly- saving of Networks and
torch.nn.Module
s together (e.g. a reservoir type setup as inexamples/mnist/minimal_reservoir.py
) - this enable the use of the full pytorch data loading pipeline with
pin_memory
enabled which provides asynchronous transfer to the gpu
from bindsnet.
from bindsnet.
@djsaunde so I've put some initial work into this. I need to check why the tests are failing on the build server. However, this should give you an initial look into how it could work. Almost everything utilizes the buffer functionality in torch.nn.Module
, except for the weights and biases which are Parameters without gradients. I haven't migrated the Network to inherit from torch.nn.Module
yet as I'm still thinking about how the Monitors will play out.
from bindsnet.
register_buffer
just registers a tensor to be tracked by pytorch to help with to()
and state_dict()
, so there's no real performance hit here.
The only reason would be to keep __init__.py
as strictly management of the submodule, which is traditionally what I've kept __init__.py
for. This would be more philosophy of design for bindsnet than anything else.
I think this would be a good feature, something I've been thinking about as I've been writing more code as well. But is definitely out of scope for this.
from bindsnet.
Hey @sharath, any movement on this feature?
from bindsnet.
@djsaunde I'll work on this soon.
from bindsnet.
@k-chaney it'd be great if you could take a look at this. I think the preferred approach is having Nodes
, Connection
s, and Network
objects subclass torch.nn.Module
, like you said.
from bindsnet.
I think @sharath will be occupied this week.
Feel free to start on it.
from bindsnet.
Great! The code changes look good so far. Do you think it will have any impact on runtime performance? What exactly does register_buffer
do?
One thing I'm a little wary of is migrating the Network
code to bindsnet.network.network
; that seems a little redundant, and it might be better to keep it in the __init__.py
file. Unless there's a good reason not to?
It may be interesting to optionally keep gradients for "smoothed" versions of nodes
/ topology
objects (i.e., without discontinuities), but that will probably be better off as future work.
from bindsnet.
@djsaunde what's the best way to look at the travis log? All of the tests pass for me locally. (nevermind I found the link to the travis-ci website)
from bindsnet.
This has been initially completed in #266
from bindsnet.
Related Issues (20)
- Low accuracy HOT 9
- SWAT: A Spiking Neural Network Training Algorithm for Classification Problems HOT 1
- A (serious) bug preventing RL algorithms to work HOT 4
- Has anyone manage to make one of the RL examples to work? HOT 2
- Saving, loading, and performing prediction from supervised examples HOT 1
- Is there any way to use BindsNet on RTX 3090? HOT 1
- 'bindsnet' is not recognized as an internal or external command, operable program or batch file. HOT 2
- How would I run this type of setup? HOT 2
- Reservoir issues!
- Network converted from ANN doesn't retain weights after training? HOT 3
- Question: Can it be used for speech emotion recognition task? HOT 1
- Does the `poisson` function under-produce spikes? HOT 13
- THE DEAD NEURON PROBLEM HOT 14
- ModuleNotFoundError: No module named 'torch._six' HOT 5
- Is SingleEncoder timing-based? HOT 7
- Are learning rules such as gradient descent available? HOT 1
- ModuleNotFoundError: No module named 'torch._six' HOT 4
- Columns and DataType Not Explicitly Set on line 18 of plot_benchmark.py
- How backpropagation work? HOT 6
- Using bindsnet for temperature prediction? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bindsnet.