samskalicky commented on a change in pull request #19386:
URL: https://github.com/apache/incubator-mxnet/pull/19386#discussion_r518412778
##########
File path: python/mxnet/gluon/block.py
##########
@@ -1156,23 +1157,23 @@ def hybridize(self, active=True, backend=None,
backend_opts=None, clear=True, **
Optimize for invariant input shapes between iterations. Must also
set static_alloc to True. Change of input shapes is still allowed
but slower.
+ **kwargs : dict
+ Optional backend options when hybridized is called with an
optimization backend.
"""
self._backend = backend
- if backend_opts is not None:
- assert isinstance(backend_opts, dict), \
- "HybridBlock hybridize requires backend_opts to be a dictionary."
- self._backend_opts = backend_opts
+ if len(kwargs) > 0:
+ self._backend_opts = kwargs
Review comment:
can we get rid of `_backend_opts` now?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]