tensorflow

class platypush.message.response.tensorflow.TensorflowPredictResponse(*args, prediction: numpy.ndarray, output_labels: Optional[List[str]] = None, **kwargs)[source]

Bases: TensorflowResponse

Tensorflow model prediction response.

__init__(*args, prediction: numpy.ndarray, output_labels: Optional[List[str]] = None, **kwargs)[source]
Parameters:

model – Name of the model.

class platypush.message.response.tensorflow.TensorflowResponse(*args, model: tensorflow.keras.models.Model, model_name: Optional[str] = None, **kwargs)[source]

Bases: Response

Generic Tensorflow response.

__init__(*args, model: tensorflow.keras.models.Model, model_name: Optional[str] = None, **kwargs)[source]
Parameters:

model – Name of the model.

class platypush.message.response.tensorflow.TensorflowTrainResponse(*args, epochs: List[int], history: Dict[str, List[Union[int, float]]], **kwargs)[source]

Bases: TensorflowResponse

Tensorflow model fit/train response.

__init__(*args, epochs: List[int], history: Dict[str, List[Union[int, float]]], **kwargs)[source]
Parameters:
  • epochs – List of epoch indexes the model has been trained on.

  • history – Train history, as a metric -> [values] dictionary where each value in values is the value for of that metric on a specific epoch.