When I tried to evaluate the new model with Use_the_current_trained_model: checked. I assumed it does not need any additional info, but this failed. So I filled the options of:
If not, indicate which model you want to assess: own model
If using your own model, please provide the path to the model (not the folder): - I gave the path to the pdf generated after
training the model.
This still produced an error:
IndexError Traceback (most recent call last)
in <cell line: 17>()
19 list_files = sorted([i for i in os.listdir(model_path+"/"+model_name) if not i.endswith('.pdf')])
20
---> 21 QC_model_path = model_path+"/"+model_name+"/"+list_files[0]
22 QC_model = "Own_model"
23
IndexError: list index out of range
Also, in the section Generate prediction(s) from unseen dataset (2D and 2D + t data). I get the error:
UnpicklingError Traceback (most recent call last)
in <cell line: 103>()
103 if model_choice == "Own_model":
104 channels=[segment_channel,nuclear_channel]
--> 105 model = models.CellposeModel(gpu=True, pretrained_model=Prediction_model)
106
107 print("Own model enabled")
Hi,
I have trained a model based on the cyto 2 model.
When I tried to evaluate the new model with Use_the_current_trained_model: checked. I assumed it does not need any additional info, but this failed. So I filled the options of: If not, indicate which model you want to assess: own model If using your own model, please provide the path to the model (not the folder): - I gave the path to the pdf generated after training the model. This still produced an error:
IndexError Traceback (most recent call last) in <cell line: 17>()
19 list_files = sorted([i for i in os.listdir(model_path+"/"+model_name) if not i.endswith('.pdf')])
20
---> 21 QC_model_path = model_path+"/"+model_name+"/"+list_files[0]
22 QC_model = "Own_model"
23
IndexError: list index out of range
Also, in the section Generate prediction(s) from unseen dataset (2D and 2D + t data). I get the error:
UnpicklingError Traceback (most recent call last) in <cell line: 103>()
103 if model_choice == "Own_model":
104 channels=[segment_channel,nuclear_channel]
--> 105 model = models.CellposeModel(gpu=True, pretrained_model=Prediction_model)
106
107 print("Own model enabled")
3 frames /usr/local/lib/python3.10/dist-packages/torch/serialization.py in _legacy_load(f, map_location, pickle_module, pickle_load_args) 1256 "functionality.") 1257 -> 1258 magic_number = pickle_module.load(f, pickle_load_args) 1259 if magic_number != MAGIC_NUMBER: 1260 raise RuntimeError("Invalid magic number; corrupt file?")
UnpicklingError: invalid load key, '%'.
Thanks! Yael