pramod722445 / Melanoma_Detection_App

0 stars 0 forks source link

E/libEGL: call to OpenGL ES API with no current context (logged once per thread) #1

Open mubasharofficial opened 3 years ago

mubasharofficial commented 3 years ago

when i run applicaiton and run cameraActivity this error was rise E/libEGL: call to OpenGL ES API with no current context (logged once per thread) I follow your videos and create my own code but same error was rise

Error Report

E/libEGL: call to OpenGL ES API with no current context (logged once per thread) I/tflite: Initialized OpenGL-based API. E/emuglGLESv2_enc: device/MTL/opengl/system/GLESv2_enc/GL2Encoder.cpp:s_glGetBufferParameteri64v:3799 GL error 0x500 D/AndroidRuntime: Shutting down VM

--------- beginning of crash

E/AndroidRuntime: FATAL EXCEPTION: main Process: com.example.imagepro, PID: 3558 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.imagepro/com.example.imagepro.CameraActivity}: java.lang.IllegalArgumentException: Internal error: Failed to apply delegate: OpenCL library not loaded - dlopen failed: library "libOpenCL-pixel.so" not found Falling back to OpenGL TfLiteGpuDelegate Init: [GL_INVALID_ENUM]: An unacceptable value is specified for an enumerated argument.: glGetBufferParameteri64v in tensorflow/lite/delegates/gpu/gl/gl_buffer.cc:46 TfLiteGpuDelegate Prepare: delegate is not initialized Node number 69 (TfLiteGpuDelegateV2) failed to prepare.

Restored original execution plan after delegate application failure.
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2668)
    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2729)
    at android.app.ActivityThread.-wrap12(ActivityThread.java)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1480)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:154)
    at android.app.ActivityThread.main(ActivityThread.java:6198)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:891)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:781)
 Caused by: java.lang.IllegalArgumentException: Internal error: Failed to apply delegate: OpenCL library not loaded - dlopen failed: library "libOpenCL-pixel.so" not found
Falling back to OpenGL
TfLiteGpuDelegate Init: [GL_INVALID_ENUM]: An unacceptable value is specified for an enumerated argument.: glGetBufferParameteri64v in tensorflow/lite/delegates/gpu/gl/gl_buffer.cc:46
TfLiteGpuDelegate Prepare: delegate is not initialized
Node number 69 (TfLiteGpuDelegateV2) failed to prepare.

Restored original execution plan after delegate application failure.
    at org.tensorflow.lite.NativeInterpreterWrapper.applyDelegate(Native Method)
    at org.tensorflow.lite.NativeInterpreterWrapper.applyDelegates(NativeInterpreterWrapper.java:367)
    at org.tensorflow.lite.NativeInterpreterWrapper.init(NativeInterpreterWrapper.java:85)
    at org.tensorflow.lite.NativeInterpreterWrapper.<init>(NativeInterpreterWrapper.java:63)
    at org.tensorflow.lite.Interpreter.<init>(Interpreter.java:277)
    at com.example.imagepro.imageClassification.<init>(imageClassification.java:52)
    at com.example.imagepro.CameraActivity.onCreate(CameraActivity.java:76)
    at android.app.Activity.performCreate(Activity.java:6692)
    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1118)
    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2621)
        ... 9 more
pramod722445 commented 3 years ago

This error might be due to activity is not registered in Androidmanifest.xml. That is why you are not able to start the activity.

<activity android:name=".CameraActivity" />

When you create a new activity it is added in Androidmanifest.xml. But if you paste the activity file in your project, it is not added in Androidmanifest.xml. Hope this solves your problem. If this is not the case copy and paste your code here so that I can see the problem.