Force re-compute of cached frame

Hello all,

I am performing simulations with 2 different types of molecules that I want to analyze separately. This is what I am doing so far:

  1. Load data file and corresponding trajectory
  2. Select all particles belonging to molecules of one type using ExpressionSelectionModifier, delete the rest
  3. Perform the analysis

Afterwards, I want to use the same pipeline to perform the same analysis on the other molecule type, just by changing the ExpressionSelectionModifier. The problem is that the modifiers I am using cache the initial frame, which is needed as a reference for some computations. This result is that the first frame will not be recomputed in the modified pipeline, leading to erroneous results for quantities that depend on it.

So my question could be summarized as: How can I force the re-compute of a frame that has been cached? Or should I follow a completely different approach?

I know I could use 2 different runs of the same script and just edit the ExpressionSelectionModifier, but I am trying to avoid having to load the quite large trajectory files twice.

Thank you in advance,

Hi Christos,

I haven’t completely understood the caching question yet. To provide helpful advice, I need to know the details of what happens in step 3. Would you be able to share a state file or your Python code?