team-mayes / atesa

Python program for automating the "Aimless Transition Ensemble Sampling and Analysis" (ATESA) aimless shooting workflow on PBS/TORQUE or Slurm.
BSD 3-Clause "New" or "Revised" License
6 stars 1 forks source link

Continuation of failed TS search job #5

Closed varun-go closed 1 day ago

varun-go commented 3 weeks ago

Thank you for developing this software!

I have a question about using the 'ts_search' feature. I am attempting to run this step for the acylation step from the following paper and the ATESA files provided via Zenodo. While attempting the TS search, ATESA crashes, and the output file states that certain trajectory files (i.e., *.nc) files cannot be identified. I have faced a similar issue while running aimless shooting runs for the gas phase example system; following the advice from the ATESA documentation, I have continued the aimless shooting jobs by setting the 'restart' flag in the config file to true. However, when I have attempted to do so for the TS search, I recieve the following error message which states that the restart pkl file is not found:

Traceback (most recent call last):
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/bin/atesa", line 8, in <module>
    sys.exit(run_main())
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 466, in run_main
    exit_message = main(settings)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 345, in main
    allthreads = init_threads(settings)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 115, in init_threads
    allthreads = pickle.load(open(settings.working_directory + '/restart.pkl', 'rb'))
FileNotFoundError: [Errno 2] No such file or directory: '/scratch.global/gopal145/atesa_example/1.acylation/1.acylation/test_output_ts/restart.pkl'

I see that the restart.pkl file is present in the as_test directory which is inside the working_directory stated in the config file. Since the working_directory in the config file should be the same as original TS run, I have not changed this directory. However, when I create a symoblic link to the restart.pkl file in the working_directory, I get the following error:

The following error occurred while attempting to initialize threads from restart.pkl. It may be corrupted.
Traceback (most recent call last):
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/bin/atesa", line 8, in <module>
    sys.exit(run_main())
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 466, in run_main
    exit_message = main(settings)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 367, in main
    raise e
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 361, in main
    running = thread.process(running, settings)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/main.py", line 63, in process
    return process.process(self, running, settings)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/process.py", line 52, in process
    this_inpcrd = jobtype.get_inpcrd(thread)
  File "/home/sarupria/gopal145/.conda/envs/atesa_test_2/lib/python3.7/site-packages/atesa/jobtype.py", line 1336, in get_inpcrd
    return [thread.history.prod_inpcrd[0]]
AttributeError: 'Namespace' object has no attribute 'prod_inpcrd'

Is there a way that this issue can be resolved? Or are transition state search jobs not anticipated to be restarted? Thank you.

tuckerburgin commented 1 day ago

So sorry for the delay in getting back to you about this. I lost access to the email address associated with this account and so was not receiving notifications of issues!

You are correct: the restart = True option is not intended to support the find_ts jobtype. The reason for the failure when you linked the as_test/restart.pkl file to the find_ts working directory is because that file is specific to the aimless_shooting sub-job that find_ts runs to validate its transition state guesses. A hypothetical find_ts restart.pkl file would need to be constructed differently. I will update the documentation to clarify this.

Speaking instead to your other issue of unidentifiable .nc files, I believe this is an error introduced by the mdtraj package since I last updated ATESA (see their issue here). You may be able to solve this by installing the netcdf4 package, and depending on your mdtraj version, you may also need to manually delete the mistaken line of code at line 161 in mdtraj/formats/netcdf.py (the current version of the code does not have the broken line in it, so you could also just try updating mdtraj). If this does not fix your error, please provide me with a traceback and I'll take a closer look.

Thanks for using ATESA!