MCPcopy
hub / github.com/FACEGOOD/FACEGOOD-Audio2Face / run

Method run

code/train/step5_inference.py:31–41  ·  view source on GitHub ↗
(self, inputData)

Source from the content-addressed store, hash-verified

29 print(f'Save TFLite model to {self.model_path} successfully!')
30
31 def run(self, inputData):
32 # Preprocess the image before sending to the network.
33 inputData = np.expand_dims(inputData, axis=0)
34
35 # The actual detection.
36 self.interpreter.set_tensor(self.input_details[0]["index"], inputData)
37 self.interpreter.invoke()
38
39 # Save the results.
40 output = self.interpreter.get_tensor(self.output_details[0]["index"])[0]
41 return output
42
43 def get_weight(self, data, label_len=37):
44 # weight = self.run(data)

Callers 3

get_weightMethod · 0.95
trainFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected