Open mattiasthalen opened 3 years ago
I wonder if we leave file open?
I wonder if we leave file open?
Well, the source shows that the final step, before return, is data.close()
.
Hi @mattiasthalen is this still an issue? If you are observing this when saving, then loading and then saving again then you can try setting az.rcParams["data.load"] = "eager"
I'm still getting this issue and when I looked for the files in the Windows resource manager, they seemed to still be open. Perhaps net_cdf is not closing the files?
For me too.
Edit: permission denied only if inside import pymc as pm; with pm.Model() as model: [...]
.
Edit2: No, something else is going on. Sometimes it failed, and sometimes it did not...
Describe the bug Exits with PermissionError when trying to use
arviz.InferenceData.to_netcdf()
to overwrite an existing file.To Reproduce Generate inference data. Export using
to_netcdf()
. Export again and get error.Expected behavior Existing file is overwritten.
Additional context Arviz 0.11.2 Google Colaboratory using TPU.
Error message PermissionError: [Errno 13] Permission denied: b'/content/drive/MyDrive/Colab Notebooks/Pyro: RepOne Strength/export/velocity_inference_mcmc.nc