Skip to content

js-pytorch 0.5.0

Latest
Compare
Choose a tag to compare
@eduardoleao052 eduardoleao052 released this 20 Jul 22:37
· 50 commits to main since this release

In this version, 2 main features were added:

  • 1. GPU support
    • The back-end GPU kernels are managed by the gpu.js library.
    • To add a Tensor to the gpu, pass 'gpu' as the device argument.
    • To add a whole layer (nn.Linear, nn.Block, nn.MultiHeadSelfAttention) to the gpu, , pass 'gpu' as the device argument.
    • The syntax is just like the PyTorch counterpart.
  • 2. Saving and Loading models
    • The functions are torch.save and torch.load.
    • The functionality is explained on the README.md file.