mask-rcnn-keras icon indicating copy to clipboard operation
mask-rcnn-keras copied to clipboard

有人试过转换成tflite吗?

Open lbininhbl opened this issue 4 years ago • 5 comments

我在打算将训练出来的模型转换成tflite格式在移动端上使用,但是转换的时候一直报错。 ValueError: Unknown layer: ProposalLayer

类似这些自定义层的问题,我都在加载model的时候都添加了这个参数解决 custom_objects={"ProposalLayer": ProposalLayer}

然后将自定义层的初始化方法的参数都加上了默认的值,最终还会报错 AttributeError: 'Node' object has no attribute 'output_masks'

lbininhbl avatar Jul 05 '21 08:07 lbininhbl

木,我没弄过的

bubbliiiing avatar Jul 15 '21 03:07 bubbliiiing

ValueError: Please initialize TimeDistributed layer with a Layer instance. You passed: <mrcnn.model.BatchNorm object at 0x7efc20fdf828>

我也在尝试,也加了custom 但是遇到这个问题

fire717 avatar Jul 25 '21 14:07 fire717

解决了,同时遇到了1楼的问题也解决了: https://blog.csdn.net/qq_30638831/article/details/84193517

fire717 avatar Jul 25 '21 15:07 fire717

最后转成tflite成功,但是加载的时候报错: RuntimeError: tensorflow/lite/kernels/strided_slice.cc:152 op_context.input->type != op_context.output->type (2 != 6)Node number 243 (STRIDED_SLICE) failed to prepare.

基本搜不到相关资料...

fire717 avatar Jul 26 '21 11:07 fire717

加油啊哥,我也不知道

bubbliiiing avatar Jul 30 '21 15:07 bubbliiiing