TorchANI 1.1
Please update your PyTorch to latest nightly build!
Highlights
- Python 2 support is removed (#370, #390)
- Ignite helper is removed (#354, #364)
- AEV cacher is removed (#361)
EnergyShifter
now always use float64 as datatype (#338, #347)- The API for the ASE interface has been simplified (#386)
Python 3
Previously we were supporting Python 2, which limits the language feature we could use. Now PyTorch has started dropping Python 2 support on their nightly builds. So TorchANI also dropped Python 2 support, which enables lots of new language features to improve our code quality:
- Use
@
operator for matrix multiplication (#371) - Type annotation is now in Python 3 style (#372, #373, #374, #375)
TorchScript Support
In TorchANI 1.0, we added TorchScript support. But due to bugs/lacking features in PyTorch, we had to make many workarounds, which introduce some problems. PyTorch has improved a lot since then, so we remove some of the workarounds to make TorchANI great again:
- Ensemble size is no longer hardcoded to 8 (#352)
enumerate
is now correctly supported by JIT (#358)- Tensor factories like
new_zeros
are now correctly supported by JIT (#353, #362) - Subclassing
ModuleList
is now supported by JIT (#385) - Bugs on the type inference of
torch.arange
is now fixed (#357) __constants__
is deprecated by torch.jit (#378)
Bug Fixes and Miscellaneous Improves
- Fix bugs on CUDA support (#341, #350)
- Fix bug in discarding outlier energy conformers (#334, #340)
- Mention what unit is used in docs (#389)
- Fix the homepage URL in PyPI page (#363)
- Modules now return a named tuple instead of a tuple (#380)
- Support
nan
as a value in NeuroChem parser (#383) - Remove warning on don't use conda to install PyTorch, because this is no longer a problem (#366)
- Allow passing
pbc
andcell
totorchani.nn.Sequential
(#386) - Code for analytical stress calculation has been improved (#387)
- Use
torch.triu_indices
to simplify code (#367, #368)