✨️ tinygrad
A Rust crate for building and training neural networks. tinygrad provides a simple interface for defining tensors, performing forward and backward passes, and implementing basic operations such as dot products and summation.
🚀 Quick Start
Get started with the tinygrad library by following these simple steps:
- Install the
tinygradcrate by adding the following line to yourCargo.tomlfile:
[]
= "0.1.0"
- Use the
TensorandForwardBackwardtraits to create and work with tensors:
use ;
use ;
// Create a tensor
let value = array!;
let tensor = new;
// Perform forward and backward passes
let mut ctx = new;
let result = tensor.forward;
tensor.backward;
- Implement custom operations by defining structs that implement the
ForwardBackwardtrait:
use ArrayView1;
use ;
// Example operation: Dot product
;
🔧 Usage Example
use ;
use ;
🧪 Testing
Run tests for the tinygrad crate using:
🌐 GitHub Repository
You can access the source code for the tinygrad crate on GitHub.
🤝 Contributing
Contributions and feedback are welcome! If you'd like to contribute, report an issue, or suggest an enhancement, please engage with the project on GitHub. Your contributions help improve this crate for the community.
📘 Documentation
Full documentation for tinygrad is available on docs.rs.
📄 License
This project is licensed under the MIT License.