hellochick / PSPNet-tensorflow

TensorFlow-based implementation of "Pyramid Scene Parsing Network".
326 stars 123 forks source link

Error loading custom trained pspnet model file #67

Open lakshmankanakala opened 5 years ago

lakshmankanakala commented 5 years ago

I have trained my PSP net model using this repo: https://github.com/holyseven/PSPNet-TF-Reproduce . I wanted to load it through your inference code.

I trained my for 3 classes on ADE_20K dataset.

I change inference.py code according to 3 classes.

I am getting following error:

NotFoundError (see above for traceback): Restoring from checkpoint failed. This is most likely due to a Variable name or other graph key that is missing from the checkpoint. Please ensure that you have not altered the graph expected based on the checkpoint. Original error:

Key conv1_1_3x3_s2/weights not found in checkpoint
     [[node save/RestoreV2 (defined at inference.py:105)  = RestoreV2[dtypes=[DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, ..., DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT], _device="/job:localhost/replica:0/task:0/device:CPU:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]

Using yours inference.py , can't I load another model ? Is it model dependent ? It was trained on repo as suggested in readme.

Thanks