TorchSharp.Fun
0.77.0
.NET 7.0
dotnet add package TorchSharp.Fun --version 0.77.0
NuGet\Install-Package TorchSharp.Fun -Version 0.77.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="TorchSharp.Fun" Version="0.77.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add TorchSharp.Fun --version 0.77.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: TorchSharp.Fun, 0.77.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install TorchSharp.Fun as a Cake Addin
#addin nuget:?package=TorchSharp.Fun&version=0.77.0
// Install TorchSharp.Fun as a Cake Tool
#tool nuget:?package=TorchSharp.Fun&version=0.77.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
TorchSharp.Fun
A wrapper over TorchSharp that provides a function-compostion style of model construction. Makes the model structure more apparent. It is easier to make incremental changes to the model. Makes iterative model development faster.
Example usage
let lisht() =
F [] [] (fun z ->
use g = torch.nn.functional.tanh(z)
z * g
)
let model =
torch.nn.EmbeddingBag(EMB_INDX_DIM,EMB_DIM)
->> torch.nn.Linear(EMB_DIM,BTL_N)
->> lisht()
->> torch.nn.Dropout(0.1)
->> torch.nn.Linear(BTL_N,BTL_N)
->> lisht()
->> torch.nn.Dropout(0.1)
->> torch.nn.Linear(BTL_N,BASE_TGTS)
Product | Versions |
---|---|
.NET | net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows |
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.
-
net7.0
- FSharp.Core (>= 7.0.200)
- FsPickler (>= 5.3.2)
- TorchSharp (>= 0.99.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Fix deeply nested buffer references when moving model to another device