Forums - SNPE no output

4 posts / 0 new
Last post
SNPE no output
ktjktj0911
Join Date: 2 Jan 23
Posts: 14
Posted: Wed, 2023-03-29 00:03

Hello,

I am trying to implement dlc model in an android app runing it on dsp.

However, when I set dsp as a runtime, the model does not return any output (while, it gives correct output on GPU and CPU runtime).

I have checked that the device has dsp module using snpe-platform-validator. Also, model runs perfectly fine when I tried snpe-net-run setting runtime as dsp.

Is there way to fix this problem?

 

Thank you

  • Up0
  • Down0
sanjjey.a.sanjjey
Join Date: 17 May 22
Posts: 54
Posted: Wed, 2023-03-29 04:05

Hi,

Try specifying --use_dsp on your android target.

NOTE: The extra environment variable ADSP_LIBRARY_PATH must be set to use DSP.

Check the SNPE developer website for DSP RUNTIME ENVIRONMENT.

 

Thanks

  • Up0
  • Down0
ktjktj0911
Join Date: 2 Jan 23
Posts: 14
Posted: Wed, 2023-03-29 18:59

Hello,

While testing snpe-net-run, I have read the DSP RUNTIME ENVIRONMENT page (Snapdragon Neural Processing Engine SDK: DSP Runtime Environment (qualcomm.com)) and I have set ADSP_LIBRARY_PATH.

The snpe-platform-validator gives "dsp device present" and it gives correct output on snpe-net-run.

While testing the dlc file on android project, I have checked that dsp is available using isRunTimeAvaliable and I have set ADSP_LIBRARY_PATH using code below.

bool SetAdspLibraryPath(std::string nativeLibPath) {

std::stringstream path;
path << nativeLibPath << ";/system/lib/rfsa/adsp;/system/vendor/lib/rfsa/adsp;/dsp";
 
return setenv("ADSP_LIBRARY_PATH", path.str().c_str(), 1 /*override*/) == 0;

}

However, the model gives empty output.

is it possible some model to work only on snpe-net-run but not on android project?

 

Thank you

  • Up0
  • Down0
ktjktj0911
Join Date: 2 Jan 23
Posts: 14
Posted: Wed, 2023-03-29 18:59

Hello,

While testing snpe-net-run, I have read the DSP RUNTIME ENVIRONMENT page (Snapdragon Neural Processing Engine SDK: DSP Runtime Environment (qualcomm.com)) and I have set ADSP_LIBRARY_PATH.

The snpe-platform-validator gives "dsp device present" and it gives correct output on snpe-net-run.

While testing the dlc file on android project, I have checked that dsp is available using isRunTimeAvaliable and I have set ADSP_LIBRARY_PATH using code below.

bool SetAdspLibraryPath(std::string nativeLibPath) {

std::stringstream path;
path << nativeLibPath << ";/system/lib/rfsa/adsp;/system/vendor/lib/rfsa/adsp;/dsp";
 
return setenv("ADSP_LIBRARY_PATH", path.str().c_str(), 1 /*override*/) == 0;

}

However, the model gives empty output.

is it possible some model to work only on snpe-net-run but not on android project?

 

Thank you

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.