How to convert gluoncv model(single .params) to mxnet model(.json + .params)?

I want to use this code to do the feature map visualization but it needs mxnet model. I used gluoncv to train a model and saved in a single .params file. However, mxnet model should have json file and params well at same time. So how to convert?
Besides, if there is any way to visualize directly using gluoncv model instead of mxnet model, please let me know…

Hey @zhoulukuan,
you can use Gluon’s export() method:

net.export(prefix, epoch=current_epoch)

Make sure to hybridize your network beforehand.

1 Like