AnalysisError: SOMD free-energy analysis failed!
Closed this issue · 5 comments
Hi,
Sorry for my delay in reply, but I have found something strange while running FEP with somd. When I launch the calculation for the RBFE using BSS.FreeEnergy.Relative.analyse, I get the follow error:
File /cluster/ddu/cmmartinez001/miniconda3/envs/biosimspace-dev/lib/python3.9/site-packages/BioSimSpace/FreeEnergy/_relative.py:605, in Relative._analyse_somd(work_dir)
598 proc = _subprocess.run(
599 _Utils.command_split(command),
600 shell=False,
601 stdout=_subprocess.PIPE,
602 stderr=_subprocess.PIPE,
603 )
604 if proc.returncode != 0:
--> 605 raise _AnalysisError("SOMD free-energy analysis failed!")
607 # Re-run without subsampling if the subsampling has resulted in less than 50 samples.
608 with open("%s/mbar.txt" % work_dir) as file:
AnalysisError: SOMD free-energy analysis failed!
I have run the same for the O-xilene tutorial and it works fine. However when I see the simfile.dat I noticed that in my calculations it does not start from step 0. I noticed in the tutorial all lambdas begin from 0 and also, the version of sire is different.
Versions:
Tutorial: 2022.3.0
My calculation: 2023.0.3
Running in RHEL 7
I suspect BSS.FreeEnergy.Relative.analyse is not able to pick the data inside because I am missing step 0, The cfg file looks pretty much the same as the tutorial setup, so, I don't think the parameters were wrongly selected.
Please, let me know if you need more details.
Best wishes,
Cesar
Any chance you can try with the latest version of the code from the OpenBioSIm channel:
mamba create -n openbiosim-dev -c conda-forge -c openbiosim/label/dev biosimspace
mamba activate openbiosim-dev
You can use BioSImSpace to analyse existing data as follows:
import BioSImSpace as BSS
pmf, overlap = BSS.FreeEnergy.Relative.analyse("/path/to/your/data")
Here "/path/to/your/data"
is the working directory from an existing run.
The analysis code uses a wildcard to match whatever lambda directories exist, so I don't think it should fail if a directory is missing, or has a different name.
Alternatively, if it's not too large, you could zip up your working directory and post it here. (Or share by another means if it's too big.)
Cheers.
simfile.txt
Hi,
Please, find attached the simfile where I think the error comes, the data inside can not be readen because it starts from 250 step and not from 0. I will check if the version you mention can make a difference.
Best wishes,
Cesar
I've manually edited some local data so that all of the simfiles don't start from zero and it is still working for me. I'd try manually running analyse_freenrg
to see if it gives any more information as to why it failed, e.g.:
analyse_freenrg mbar -i free/lambda_*/simfile.dat -o free/mbar.txt --overlap --subsampling
Hi,
It works now whith tha latest version. Thanks a lot. Perhaps something was wrong the the previous version. I used the same data.
Great, I'm pleased to hear. I don't think the BioSImSpace analysis has changed in that time, but we have occasionally had to make edits to the analyse_freenrg
script due to changes in the pymbar
API, so maybe the version that you were using was broken.