Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to add multi-inputs? or how to test the benchmark on multi inputs? #28

Open
peiwenYe opened this issue Oct 19, 2020 · 4 comments
Open

Comments

@peiwenYe
Copy link

hello, I wonder that how to load multi inputs, I just add a comma and another input follow the original "validation_inputs_data", but a mistake occured ><, so can you answer me about that how to add two or three even more inputs to the validation input? Thank you very much!

@lee-bin
Copy link
Member

lee-bin commented Oct 19, 2020

Does your model have multiple input nodes? Or you want to validate the model with different input data? You can paste the yaml file if it helps to clarify.

@peiwenYe
Copy link
Author

Thank you for your reply very much. Here is my yaml, I just want to test multi input with the same input format. If I only put one input like "validation_inputs_data: - /home/ypw/speech/kaldi-onnx-master/mace_input.npy", It works.
library_name: aishell2
target_abis: [aarch64-linux-gnu]
model_graph_format: file
model_data_format: file
models:
aishell2:
platform: onnx
model_file_path: /home/ypw/speech/kaldi-onnx-master/text.onnx
model_sha256_checksum: 8d60e44c128523a82c82f9d592912fa9fe8923ad81443b66c9932f92d0d1dc3f
subgraphs:

  • input_tensors:
  • input
    input_shapes:
  • 1,52,40
    output_tensors:
    #- output.affine
    #- output-xent.log-softmax
  • output.linear
    output_shapes:
  • 1,7,4408
    backend: kaldi
    input_data_formats: NONE
    output_data_formats: NONE
    validation_inputs_data:
  • [/home/ypw/speech/kaldi-onnx-master/mace_input.npy,/home/ypw/speech/kaldi-onnx-master/test_input.npy]
    validation_outputs_data:
  • [/home/ypw/speech/kaldi-onnx-master/mace_output.npy,/home/ypw/speech/kaldi-onnx-master/test_output.npy]
    runtime: cpu
    limit_opencl_kernel_time: 0
    nnlib_graph_mode: 0
    obfuscate: 0

@lee-bin
Copy link
Member

lee-bin commented Oct 19, 2020

MACE only supports validation for one group of inputs (for models with multiple input nodes), you can't specify multiple groups of input data. You can validate it multiple times with different groups of input data or write your own codes to do it.

@peiwenYe
Copy link
Author

I got it. Thank you very much!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants