You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
foriinsims:
# make a protein Universeu=i.universe# select Li atomsions=u.select_atoms('name LI')
forioninions:
# make radial distribution functiondf=pdbionsurvey.coordination.en(u, ion)
# make directory if it doesn't existi['coordination/LI/'].make()
# store radial distribution function in .csv filedf.to_csv(i['coordination/LI/{}.csv'.format(ion.number)].abspath)
will run out of open file descriptors if there are too many sims because the line
u=i.universe
creates a MDAnalysis.Universe as a side effect and keeps it alive.
The code in the Li+ notebook
will run out of open file descriptors if there are too many sims because the line
creates a
MDAnalysis.Universe
as a side effect and keeps it alive.Instead do something like
This will ensure that the Universe is garbage-collected and with it the file descriptors will be released again.
Add a comment to the code and say why you're not using
i.universe
. It will also make it easier to make the code independent of MDS #13.The text was updated successfully, but these errors were encountered: