Open prb2307 opened 5 years ago
Hi @prashant-bansod , You may find this Jupyter Notebook helpful.
You need to add extra parameters to the load_model
function as follows:
from instance_normalization import InstanceNormalization
from my_upsampling_2d import MyUpSampling2D
from FgSegNet_v2_module import loss, acc, loss2, acc2
model = load_model(model_path, custom_objects={'MyUpSampling2D': MyUpSampling2D, 'InstanceNormalization': InstanceNormalization, 'loss':loss, 'acc':acc, 'loss2':loss2, 'acc2':acc2})
@lim-anggun Thank you very much. I made the required corrections. Thanks a ton for your reply. I had one more question, I tried the pedestrian model but the silhouettes I got are noisy. Does the background has an effect on the extracted silhouettes?
What do you think would be the best approach to extract human silhouettes?
thanks a lot for your great work, but how to make my own data like the CDnet2014? and how to train it?
@lim-anggun I have read your previous comment on adding the instance_nornalization.py .But I am still getting the error I have added this line of code as mentioned by you.
from FgSegNet.instance_normalization import InstanceNormalization model = load_model(mdl_path, custom_objects={'MyUpSampling2D': MyUpSampling2D, 'InstanceNormalization': InstanceNormalization})
Error :
I would appreciate your advice on this. Thank you.