custom_imports = dict(imports=['my_module'], allow_failed_imports=False) optimizer = dict(type='CustomOptim')