aiqm / torchani

Accurate Neural Network Potential on PyTorch
https://aiqm.github.io/torchani/
MIT License
459 stars 126 forks source link

handle OSError in parse_neurochem_resources #562

Closed jananzhu closed 3 years ago

jananzhu commented 3 years ago

Hi, We're running TorchANI in an environment where the python packages are mounted in a read-only directory. _parse_neurochem_resources attempts to extract resources into the package directory and this raises a OSError for us. There's already handling for writing to a local folder in the home directory when a PermissionError is raised; this pull request applies the same handling to the OSError case as well and fixes this issue for us. Thanks!

zasdfgbnm commented 3 years ago

Thanks for your contribution!