A tensor library for differentiable functional programming in F#, with PyTorch-like APIs and GPU support.
DiffSharp is a tensor library for differentiable programming, providing automatic differentiation capabilities for machine learning, optimization, and probabilistic programming. It integrates F# functional programming with efficient tensor operations via LibTorch backends, supporting GPU acceleration and cross-platform development.
Machine learning researchers, data scientists, and F# developers working on optimization, probabilistic models, or scientific computing who need automatic differentiation in a functional programming environment.
Developers choose DiffSharp for its combination of F#'s type safety and functional paradigms with PyTorch-like APIs and high-performance tensor operations, offering a unique, robust tool for differentiable programming in the .NET ecosystem.
DiffSharp: Differentiable Functional Programming
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Supports nested and mixed-mode differentiation for complex models, enabling sophisticated gradient computations as highlighted in the key features.
Leverages F# for type-safe, composable code, providing reliability in scientific computing workflows.
Utilizes LibTorch CUDA/C++ tensors for efficient GPU acceleration, allowing fast tensor operations on supported hardware.
Uses PyTorch naming and idioms, making it easier for developers transitioning from Python to F# for machine learning tasks.
The README notes this is a development branch with incomplete code and functionality likely to change, posing risks for reliable use.
Only x64 platforms are supported out of the box for the TorchSharp backend, restricting deployment on other architectures like ARM.
As an F# library in the .NET ecosystem, it has fewer community resources and pre-built models compared to Python-based frameworks.