MCPcopy Create free account
hub / github.com/tensorflow/tfjs / predict

Method predict

tfjs-converter/src/executor/graph_model.ts:357–361  ·  view source on GitHub ↗

* Execute the inference for the input tensors. * * @param input The input tensors, when there is single input for the model, * inputs param should be a `tf.Tensor`. For models with multiple inputs, * inputs params should be in either `tf.Tensor`[] if the input order is * fixed, or oth

(inputs: Tensor|Tensor[]|NamedTensorMap, config?: ModelPredictConfig)

Source from the content-addressed store, hash-verified

355 * @doc {heading: 'Models', subheading: 'Classes'}
356 */
357 predict(inputs: Tensor|Tensor[]|NamedTensorMap, config?: ModelPredictConfig):
358 Tensor|Tensor[]|NamedTensorMap {
359 const outputTensors = this.execute(inputs, this.outputNodes);
360 return this.addStructuredOutputNames(outputTensors);
361 }
362
363 /**
364 * Execute the inference for the input tensors in async fashion, use this

Callers

nothing calls this directly

Calls 2

executeMethod · 0.95

Tested by

no test coverage detected