duartegroup / autodE

automated reaction profile generation
https://duartegroup.github.io/autodE/
MIT License
166 stars 51 forks source link

Dictionary Changed Size during Iteration #146

Closed FloRuepp closed 2 years ago

FloRuepp commented 2 years ago

I recently installed autodE and was trying to reproduce the butadiene-ethene DA reaction, using python 3.7.4 and orca 5.0.2 (although the same error was reproduced using orca 4.1.0). However, the calculation fails during the transition state search phase with the following error:

Process Process-143: Traceback (most recent call last): File "/cluster/apps/nss/python/3.7.4/x86_64/lib64/python3.7/multiprocessing/process.py", line 297, in _bootstrap self.run() File "/cluster/apps/nss/python/3.7.4/x86_64/lib64/python3.7/multiprocessing/process.py", line 99, in run self._target(*self._args, *self._kwargs) File "/cluster/home/rueppf/.local/lib/python3.7/site-packages/autode/utils.py", line 380, in handler queue.put(func(args, **kwargs)) File "/cluster/home/rueppf/.local/lib/python3.7/site-packages/autode/mol_graphs.py", line 484, in is_isomorphic graph1, graph2 = get_graphs_ignoring_active_edges(graph1, graph2) File "/cluster/home/rueppf/.local/lib/python3.7/site-packages/autode/mol_graphs.py", line 451, in get_graphs_ignoring_active_edges for edge in ga.edges: File "/cluster/apps/nss/python/3.7.4/x8664/lib64/python3.7/site-packages/networkx/classes/reportviews.py", line 1028, in __iter_\ for nbr in nbrs: RuntimeError: dictionary changed size during iteration

The code to obtain this result is simply:

import autode as ade ade.Config.n_cores = 8 ade.Config.max_core = 4000 rxn = ade.Reaction('C=CC=C.C=C>>C1=CCCCC1', name='DA') rxn.calculate_reaction_profile()

Environment

t-young31 commented 2 years ago

Hi @FloRuepp

This is interesting... I just briefly was trying to replicate this and I got stuck at Python 3.7.4 not being available on anaconda, which perhaps suggests that version of python has some kind of problem(?)

The default way I install python then autodE on a new system is to use miniforge with something like

wget https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-Linux-x86_64.sh
bash Miniforge3-Linux-x86_64.sh

(selecting all the defaults and letting it initialise, then just conda install autode)

Let me know if that works! 😄

FloRuepp commented 2 years ago

Dear Tom, since I am just freshly starting a new project, I had no issue just switching to python 3.8.5 and re-installing all the packages, which seemst to have instantly fixed the problem. Curious... Thanks for your help, Flo

t-young31 commented 2 years ago

Awesome – no problem at all