Checking the runmode of .prior files #251
-
Dear Reinvent4 Community, for a given .prior file I would like to check the run mode used for the training, to ensure that users only use Reinvent priors for Reinvent, Libinvent for Libinvent and so on. torch.load(input_prior, map_location="cpu", weights_only=False)
----
ModuleNotFoundError: No module named 'reinvent.runmodes' Does anyone have an idea on how this could be implemented? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hi, the priors contain metadata to identify, basically, what code in REINVENT needs to be run. The user supplies the desired prior and the correct code is triggered. Your error message suggests that your current Python environment does not have REINVENT installed. I would need to see the complete error message.. Many thanks, |
Beta Was this translation helpful? Give feedback.
Hi Hannes,
Ah indeed, I had a folder called reinvent in my own code, causing a name overlap and the imports no longer worked properly.
After refactoring, loading the prior worked.
Gives the run mode the prior was trained on, allowing the verification that the user selects the correct prior for the correct mode.
Thanks!