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

[Bug report] Attempt to invoke virtual method 'com.google.mlkit.vision.face.internal.FaceDetectorImpl com.google.mlkit.vision.face.internal.zzc.zzb(com.google.mlkit.vision.face.FaceDetectorOptions)' on a null object reference #888

Open
Bui-Ly opened this issue Oct 28, 2024 · 0 comments
Assignees

Comments

@Bui-Ly
Copy link

Bui-Ly commented Oct 28, 2024

Describe the bug
this my code:

MlKitContext.initializeIfNeeded(this); // 

FaceDetectorOptions realTimeOpts =
                new FaceDetectorOptions.Builder()
                        .setContourMode(FaceDetectorOptions.CONTOUR_MODE_ALL)
                        .build();

when i initialize FaceDetectorOptions i always get this error

Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'com.google.mlkit.vision.face.internal.FaceDetectorImpl com.google.mlkit.vision.face.internal.zzc.zzb(com.google.mlkit.vision.face.FaceDetectorOptions)' on a null object reference
at com.google.mlkit.vision.face.FaceDetection.getClient(com.google.android.gms:play-services-mlkit-face-detection@@17.1.0:3)

SDK Info:

  • SDK Name & Version:
    • com.google.mlkit:face-detection:16.1.5
    • com.google.mlkit:face-detection:16.1.7
    • com.google.android.gms:play-services-mlkit-face-detection:17.1.0
      Development Environment:
      Android Studio Electric Eel | 2022.1.1
      Build #AI-221.6008.13.2211.9477386, built on January 11, 2023
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