summarize_model¶
- summarize_model(model, tflite=False, build=False, test=False, built_model=None)[source]¶
Generate a summary of the given model and return the summary as a string
- Parameters:
model (
Union[str,YZLiteModel,Model,TfliteModel]) –Either
a path to a .tflite, .h5, .yzlite.zip, .py file,
or
yzlite.core.TfliteModelinstance
tflite (
bool) – If true, the return the summary of the corresponding .tflite model. If true and model=yzlite.core.KerasModel, this will quantize it into a .tflite modelbuild (
bool) – If true, then generate a .h5 or .tflite by training the givenyzlite.core.YZLiteModelmodel for 1 epoch. This is useful for summarizing theyzlite.core.YZLiteModelwithout fully training the model firsttest (
bool) – If true and the model is the name of a YZLiteModel, then load the YZLiteModel in testing modebuilt_model (
Union[Model,TfliteModel,None]) – Optional, previously builtyzlite.core.KerasModeloryzlite.core.TfliteModelassociated with givenyzlite.core.YZLiteModel
- Return type:
str- Returns:
A summary of the given model as a string