Skip to content

Commit

Permalink
Merge pull request #900 from xalbertoisorna/fix/readme
Browse files Browse the repository at this point in the history
readme minor update proposal
  • Loading branch information
panickal-xmos authored Jul 22, 2024
2 parents ee1a8d6 + 0d82385 commit 468784d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,12 +95,15 @@ Some of the commonly used configuration options are described [here](docs/rst/op
```python
from xmos_ai_tools.xinterpreters import TFLMHostInterpreter

input_data = ... # define your input data

ie = TFLMHostInterpreter()
ie.set_model(model_path='path_to_xcore_model', params_path='path_to_xcore_params')
ie.set_tensor(ie.get_input_details()[0]['index'], value='input_data')
ie.set_tensor(ie.get_input_details()[0]['index'], value=input_data)
ie.invoke()

xformer_outputs = []
num_of_outputs = len(ie.get_output_details())
for i in range(num_of_outputs):
xformer_outputs.append(ie.get_tensor(ie.get_output_details()[i]['index']))
```

0 comments on commit 468784d

Please sign in to comment.