Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/gsteixeira/neuralnetwork-go
A simple feed forward neural network in Go
https://github.com/gsteixeira/neuralnetwork-go
Last synced: about 5 hours ago
JSON representation
A simple feed forward neural network in Go
- Host: GitHub
- URL: https://github.com/gsteixeira/neuralnetwork-go
- Owner: gsteixeira
- Created: 2021-09-30T03:03:51.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2021-10-11T18:30:02.000Z (about 3 years ago)
- Last Synced: 2024-06-21T02:05:15.281Z (5 months ago)
- Language: Go
- Size: 11.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# A Neural Network in Go
A feed forward neural network in Go
## usage:
If you just wanna try it:
```shell
make run
```## Create a neural network:
Create a network telling the size (nodes) of earch layer.
```go
nn := NewNeuralNetwork(size_input,
size_output,
[]int {hidden_sizes,})
// train the network
nn.Train(inputs, outputs, iteractions)
// Make predictions
predicted := nn.Predict(inputs[i])
```
It is possible to use multiple hidden layers. Just pass the size of each one of them in the list:
```go
// this will create a hidden layer of 3 layers, with sizes 4, 6 and 3.
nn := NewNeuralNetwork(size_input, size_output,
[]int {4, 6, 3})
```
## Two implementations:There are two implementations on this repository:
- neural.go - Object oriented, more flexible and has more features.
- neural_procedural.go - Simple, procedural implentation that uses arrays.