Ishitori opened a new issue #13147: Feature request: Add dtype to gluon.nn.SymbolBlock.imports() to load float16 models URL: https://github.com/apache/incubator-mxnet/issues/13147 ## Description Currently, `gluon.nn.SymbolBlock.imports(...)` cannot load a model with parameters if they were saved as float16, because the method implicitly expects `float32`. There is no dtype in the method signature to tell the method to expect `float16`. I have created a [custom function](https://discuss.mxnet.io/t/import-export-fails-for-float16-net-after-cast/2149/2?u=sergey) to do it, but I have to add a dirty check for `BatchNorm`, because [BatchNorm doesn't support cast to float16](https://github.com/apache/incubator-mxnet/blob/master/python/mxnet/gluon/nn/basic_layers.py#L351) to help stable reduction for mean/var. That implementation doesn't look nice, and it would be great to have a normal solution with float16 support inside of the `gluon.nn.SymbolBlock.imports(...)`.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
