Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update custom_object documentation and __init__() arguments serializa…
…tion_and_saving.py In the example of a CustomLayer class its __init__ method passed argument sublayer whereas while assigning to self it is using the variable layer instead of sublayer. Hence corrected the same. Also please check the documentation below. If the arguments passed to the constructor (`__init__()` method) of the custom object aren't Python objects (anything other than base types like ints, strings, etc.), then you **must** also explicitly deserialize these arguments in the `from_config()` class method. Actually we need to also add the statement like you must explicitly serialize the non_python arguments in get_config() method also so that it can be deserialized in from_config() method. As it is explicitly mentioned for from_config() it should be explicitly mentioned for get_config() also. This makes users well aware of this. Because without serializing non_python object in get_config() , it is not possible to reload that back into model.
- Loading branch information