(config)
| 18 | |
| 19 | |
| 20 | def instantiate_from_config(config): |
| 21 | if "target" not in config: |
| 22 | raise KeyError("Expected key `target` to instantiate.") |
| 23 | return get_obj_from_str(config["target"])(**config.get("params", dict())) |
| 24 | |
| 25 | |
| 26 | def load_partial_from_config(config): |
no test coverage detected