torchtuples

Training neural networks in PyTorch

BSD-2-CLAUSE License

Downloads
5.9K
Stars
27
Committers
5

Bot releases are visible (Hide)

torchtuples - Bug fix in predictions Latest Release

Published by havakv about 3 years ago

Previously could crash when checking input sizes. See https://github.com/havakv/pycox/issues/92#issuecomment-908221306

torchtuples - Bug fix, allow for ductyping in `to_device`

Published by havakv about 3 years ago

torchtuples - Updated API with v0.2.0

Published by havakv almost 5 years ago

Some restructuring to make Model more general. This means that some earlier code might break.

Main differences are:

  • model.predict will use the model.net.predict method if available. If not, it will use the old model.net.forward.
  • model.predict_net will use model.net.forward.
  • Both predict methods now works with dataloader input.
  • Removed predict_dataloader as predict works with dataloaders.
  • Both predict methods take the optional argument func which can be a torch function that is applied to the output. E.g., func=torch.sigmoid can be used for binary classification.
  • target is now an optional argument in fit.
  • compute_metrics take the argument data instead of input, target.
  • set_device can be used to change the device of the model. E.g., model.set_device('cpu') will enable the model to work on cpu.
  • Renamed DataLoaderSlice to DataLoaderBatch.
torchtuples - First working release

Published by havakv almost 5 years ago

Only cosmetic changes from v0.1.1 to make it look nicer on pypi.

torchtuples - First release

Published by havakv almost 5 years ago

First release to PyPI.