|
地板
楼主 |
发表于 2019-11-14 20:13:55
|
只看该作者
开启 verbose 之后只多了一条日志:
D import clients finished
这个模型是我们自己训练的,在 tensorflow 上可以运行。转换的代码如下:
rknn = RKNN(verbose=True, verbose_file='./verbose.log')
rknn.config(channel_mean_value='0 0 0 255', reorder_channel='0 1 2')
ret = rknn.load_tensorflow(
'../dl_models/enhancement/E0815_99/saved_model.pb',
inputs=['input:0'],
outputs=['clip_by_value:0'],
input_size_list=[[1, 640, 640, 1]])
if ret != 0:
print('failed to load tf model')
exit(ret)
ret = rknn.build(do_quantization=False, pre_compile=False)
if ret != 0:
print('failed to build rknn model')
exit(ret)
ret = rknn.export_rknn('enhancement.rknn')
if ret != 0:
print('failed to export rknn model')
exit(ret)
rknn.release() |
|