Forums - oemconfig.so

3 posts / 0 new
Last post
oemconfig.so
junhyuk7.lee
Join Date: 19 Dec 13
Posts: 1
Posted: Tue, 2017-11-28 03:00

Hi ?

Now I am trying to implement for android example application with inceptionv3 dlc file.

I reach a troblem which is shown as below .

Please let me know how to get the so lib file .

 

 

vendor/qcom/proprietary/adsprpc/src/apps_std_imp.c:538:Error 45: fopen failed for oemconfig.so. (No such file or directory)

  • Up0
  • Down0
jesliger
Join Date: 6 Aug 13
Posts: 75
Posted: Tue, 2017-11-28 07:22

Hi.  That error is expected.  Unfortunately it's a log message built into the platform that occurs even in working cases.   It occurs when the DSP runtime is invoked. You should notice that error even when you use a working example.

Try running your model on CPU or GPU to be sure, but the error you are seeing is likely not the source of the issue you are having.  Can you provide more detail on what you have done/are trying to do?  

 

  • Up0
  • Down0
Starlitsky2010
Join Date: 13 Jan 18
Posts: 7
Posted: Wed, 2018-01-17 00:47

Hi, jesliger

I also met this problem. I tried implementing for an android example application with inceptionv3 dlc file according to

https://developer.qualcomm.com/forum/qdn-forums/software/snapdragon-neur...

And here is my patches for showing what I did

1st

app/src/main/java/com/qualcomm/qti/snpe/imageclassifiers/ModelOverviewFragment.java
@@ -150,7 +150,7 @@ public class ModelOverviewFragment extends Fragment {
     }
 
     public void setNetworkDimensions(Map<String, int[]> inputDimensions) {
-        mDimensionsText.setText(Arrays.toString(inputDimensions.get("data")));
+        mDimensionsText.setText(Arrays.toString(inputDimensions.get("Mul:0")));
     }

2nd

app/src/main/java/com/qualcomm/qti/snpe/imageclassifiers/tasks/ClassifyImageTask.java
@@ -29,7 +29,7 @@ public class ClassifyImageTask extends AsyncTask<Bitmap, Void, String[]> {
 
     private static final String LOG_TAG = ClassifyImageTask.class.getSimpleName();
 
-    public static final String OUTPUT_LAYER = "prob";
+    public static final String OUTPUT_LAYER = "softmax:0";
 
     private static final int FLOAT_SIZE = 4;
 
@@ -54,7 +54,7 @@ public class ClassifyImageTask extends AsyncTask<Bitmap, Void, String[]> {
         final List<String> result = new LinkedList<>();
 
         final FloatTensor tensor = mNeuralNetwork.createFloatTensor(
-                mNeuralNetwork.getInputTensorsShapes().get("data"));
+                mNeuralNetwork.getInputTensorsShapes().get("Mul:0"));
 
         final int[] dimensions = tensor.getShape();
         final FloatBuffer meanImage = loadMeanImageIfAvailable(mModel.meanImage, tensor.getSize());
@@ -95,15 +95,20 @@ public class ClassifyImageTask extends AsyncTask<Bitmap, Void, String[]> {
     }
 
     private void writeRgbBitmapAsFloat(Bitmap image, FloatBuffer meanImage, FloatTensor tensor) {
+        int imageMean = 128;
+        float imageStd = 128.0f;
         final int[] pixels = new int[image.getWidth() * image.getHeight()];
         image.getPixels(pixels, 0, image.getWidth(), 0, 0,
             image.getWidth(), image.getHeight());
         for (int y = 0; y < image.getHeight(); y++) {
             for (int x = 0; x < image.getWidth(); x++) {
                 final int rgb = pixels[y * image.getWidth() + x];
-                float b = ((rgb)       & 0xFF) - meanImage.get();
-                float g = ((rgb >>  8) & 0xFF) - meanImage.get();
-                float r = ((rgb >> 16) & 0xFF) - meanImage.get();
+                //float b = ((rgb)       & 0xFF) - meanImage.get();
+                float b = (((rgb) & 0xFF) - imageMean) / imageStd;  // imageMean = 128, imageStd = 128.0f
+                //float g = ((rgb >>  8) & 0xFF) - meanImage.get();
+                float g = (((rgb >>  8) & 0xFF) - imageMean) / imageStd; // imageMean = 128, imageStd = 128.0f
+                //float r = ((rgb >> 16) & 0xFF) - meanImage.get();
+                float r = (((rgb >>  16) & 0xFF) - imageMean) / imageStd; // imageMean = 128, imageStd = 128.0f

 3rd, I change alexnet to inception_v3 by this way:

app/src/main/java/com/qualcomm/qti/snpe/imageclassifiers/ModelCatalogueFragmentController.java
@@ -40,7 +40,7 @@ public class ModelCatalogueFragmentController extends
     }
 
     private void startModelsExtraction() {
-        ModelExtractionService.extractModel(mContext, "alexnet", R.raw.alexnet);
+        ModelExtractionService.extractModel(mContext, "inception_v3", R.raw.inception_v3);
     }

What I missed?

And here  is the error logs:

02-06 21:29:19.422 24875-24991/com.qualcomm.qti.snpe.imageclassifiers E/com.qualcomm.qti.snpe.imageclassifiers: vendor/qcom/proprietary/adsprpc/src/apps_std_imp.c:538:Error 45: fopen failed for oemconfig.so. (No such file or directory)
02-06 21:29:19.427 24875-24991/com.qualcomm.qti.snpe.imageclassifiers E/com.qualcomm.qti.snpe.imageclassifiers: vendor/qcom/proprietary/adsprpc/src/apps_std_imp.c:538:Error 45: fopen failed for testsig-0xb75420ea.so. (No such file or directory)
02-06 21:29:19.428 24875-24991/com.qualcomm.qti.snpe.imageclassifiers E/com.qualcomm.qti.snpe.imageclassifiers: vendor/qcom/proprietary/adsprpc/src/apps_std_imp.c:538:Error 45: fopen failed for testsig.so. (No such file or directory)
02-06 21:29:22.579 24875-24986/com.qualcomm.qti.snpe.imageclassifiers E/AndroidRuntime: FATAL EXCEPTION: AsyncTask #4
                                                                                        Process: com.qualcomm.qti.snpe.imageclassifiers, PID: 24875
                                                                                        java.lang.RuntimeException: An error occurred while executing doInBackground()
                                                                                            at android.os.AsyncTask$3.done(AsyncTask.java:325)
                                                                                            at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:354)
                                                                                            at java.util.concurrent.FutureTask.setException(FutureTask.java:223)
                                                                                            at java.util.concurrent.FutureTask.run(FutureTask.java:242)
                                                                                            at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:243)
                                                                                            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
                                                                                            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
                                                                                            at java.lang.Thread.run(Thread.java:761)
                                                                                         Caused by: com.qualcomm.qti.snpe.NeuralNetwork$InvalidInput: Tensor not amongst network input tensors: data
                                                                                            at com.qualcomm.qti.snpe.internal.NativeNetwork.assertInputTensor(NativeNetwork.java:275)
                                                                                            at com.qualcomm.qti.snpe.internal.NativeNetwork.execute(NativeNetwork.java:110)
                                                                                            at com.qualcomm.qti.snpe.imageclassifiers.tasks.ClassifyImageTask.doInBackground(ClassifyImageTask.java:75)
                                                                                            at com.qualcomm.qti.snpe.imageclassifiers.tasks.ClassifyImageTask.doInBackground(ClassifyImageTask.java:28)
                                                                                            at android.os.AsyncTask$2.call(AsyncTask.java:305)

 

Thanks

 

  • 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.