torch

package module
v0.0.0-...-89e5866 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2026 License: AGPL-3.0 Imports: 4 Imported by: 0

README

BioTorch - Neuromorphic Compute(Bio-Neuron Inspired) DeepLearning Engine (WIP)

build

Inference Compute Runtime Support (WIP)

llama3 and llama3 vision example built on top of this framework
llama3_1b_cpu_01llama3_1b_cpu-02
CNN From Scratch example AND re-design build-in Graphic Renderer that compatible with Tensor data struct:
CNN From Scratchgraphic_renderer
Clear Structure For Highly Customizable Research AND Compute Graph and Visualization:
Clear Structure For Highly Customizable ResearchAutoEncoder Compute Graph and Visualization
More Examples: README.md
Notice

Some parts of this project’s code may generate, optimize, or annotate by AI.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Embedding

type Embedding struct {
	Weights     *tensor.Tensor
	GradWeights *tensor.Tensor
	VocabSize   int
	EmbDim      int
	LastIndices []int
}

func NewEmbedding

func NewEmbedding(vocabSize, embDim int) *Embedding

func (*Embedding) Backward

func (e *Embedding) Backward(gradOutput *tensor.Tensor, learningRate float32) *tensor.Tensor

func (*Embedding) Forward

func (e *Embedding) Forward(indices *tensor.Tensor) *tensor.Tensor

func (*Embedding) GetBias

func (e *Embedding) GetBias() *tensor.Tensor

func (*Embedding) GetWeights

func (e *Embedding) GetWeights() *tensor.Tensor

func (*Embedding) Parameters

func (e *Embedding) Parameters() []*tensor.Tensor

func (*Embedding) SetBiasAndShape

func (e *Embedding) SetBiasAndShape(data []float32, shape []int)

func (*Embedding) SetWeightsAndShape

func (e *Embedding) SetWeightsAndShape(data []float32, shape []int)

func (*Embedding) ZeroGrad

func (e *Embedding) ZeroGrad()

type Layer

type Layer interface {
	Forward(input *tensor.Tensor) *tensor.Tensor

	//DEL
	Backward(gradOutput *tensor.Tensor, learningRate float32) *tensor.Tensor
	ZeroGrad()
	Parameters() []*tensor.Tensor
}

type LayerForTesting

type LayerForTesting interface {
	GetWeights() *tensor.Tensor
	GetBias() *tensor.Tensor
}

type LayerLoader

type LayerLoader interface {
	SetWeightsAndShape(data []float32, shape []int)
	SetBiasAndShape(data []float32, shape []int)
}

Directories

Path Synopsis
cmd
data_store
datasets_loader
legacy
03_autoencoder command
pkg
fmt
log
risc-v
thirdparty
fp16_convert
Package float16 defines support for half-precision floating-point numbers.
Package float16 defines support for half-precision floating-point numbers.
onnx-go/backend/simple
Package simple holds a very simple graph structure suitable to receive an onnx model
Package simple holds a very simple graph structure suitable to receive an onnx model
onnx-go/backend/testbackend
Package testbackend provides a set of testing helper functions that test backend interface implementations.
Package testbackend provides a set of testing helper functions that test backend interface implementations.
onnx-go/backend/testbackend/onnx
Package onnxtest contains an export of the onnx test files
Package onnxtest contains an export of the onnx test files
onnx-go/backend/x/gorgonnx
Package gorgonnx creates a temporary graph that is compatible with backend.ComputationBackend.
Package gorgonnx creates a temporary graph that is compatible with backend.ComputationBackend.
onnx-go/doc/introduction command
Present displays slide presentations and articles.
Present displays slide presentations and articles.
vision

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL