Closed samhodge closed 6 years ago
Not nicely written up, but here's the snippet: https://github.com/matterport/Mask_RCNN/issues/222#issuecomment-373130661
Do you have a .pb file ready to go that matches with that model, or do I need to convert the materport myself? if so can I find the steps on that thread?
https://github.com/ericj974/Mask_RCNN/blob/master/scripts/export_model.py this should make one for me, just need to get my Python toolchain up and running.
Nearly there, using the matterport master and converting using ericj974 branch I get the following error
libc++abi.dylib: terminating with uncaught exception of type std::runtime_error: Expected mask dimensions to be [1,100,28,28,2] but got: [1,100,28,28,81]
Any ideas?
I would send you my .pb, but I dont know where to upload it to.
Here is my export script
import scripts.export_model
import config
import coco
class InferenceConfig(coco.CocoConfig):
# Set batch size to 1 since we'll be running inference on
# one image at a time. Batch size = GPU_COUNT * IMAGES_PER_GPU
GPU_COUNT = 1
IMAGES_PER_GPU = 1
config = InferenceConfig()
scripts.export_model.export(config,scripts.MODEL_DIR ,scripts.COCO_MODEL_PATH)
Using https://github.com/ericj974/Mask_RCNN/blob/master/scripts/export_model.py
with the v1.0 Matterport .h5 file from:
https://github.com/matterport/Mask_RCNN/releases actually it might be the v2.0 version. let me go back and check I am trying to upload my .pb file for you to have a look but Australian internet is slow.
OK here is the .pb file I made with the process above: https://drive.google.com/drive/folders/13LMELrHFvq1AU6-S7h8ZzPUqgO8C5pbi?usp=sharing
https://github.com/moorage/OpenCVTensorflowExample/commit/29f3bc9d77118549023559a3d8dd46003d3eae13 this is where I am up to I really dont have much idea what I am doing.
Hey Sam -- I'm sorry that I don't have time at the moment to help.
Thanks for responding
This url https://github.com/ericj974/Mask_RCNN/blob/master/scripts/export_model.py is not exists, who can give a right link. Thank you!
@Allen-wg https://github.com/ericj974/Mask_RCNN/blob/master/scripts/export.py
Got it ,Thank you! I have translate .h5 file to .pb file,when I use opencv3.4.4 to call my .pb model file, a new problem have arisen,as shown below:
cvNet=cv2.dnn.readNetFromTensorflow('mask_rcnn_playground_1000.pb')
Traceback (most recent call last):
File "
Do you have the ability to process the segmentation from a mask RCNN example.
That would be really useful.
Sam