vision-camera-realtime-object-detection
vision-camera-realtime-object-detection copied to clipboard
the detectObjects function is not working for me
const frameProcessor = useFrameProcessor(frame => { 'worklet';
const detectedObjects = detectObjects(frame, frameProcessorConfig);
//nothing happens console.log(detectObjects);
runOnJS(setObjects)(
detectedObjects.map(obj => ({
...obj,
top: obj.top * windowDimensions.height,
left: obj.left * windowDimensions.width,
width: obj.width * windowDimensions.width,
height: obj.height * windowDimensions.height,
})),
);
}, []);
"react-native-reanimated": "3.5.0",
"react-native-vision-camera": "^2.15.4",
"vision-camera-realtime-object-detection" :"0.5.1"
if a use react-native-reanimated 2.10.4
I get the frame is disabled because react native reanimated 3.5.0 is not installed
I am also having this issue where detectObjects
is undefined
@fazzysyed @nys99 Hi guys! Have you seen this thread? https://github.com/jaroslawkrol/vision-camera-realtime-object-detection/issues/7
First of all try to use model used here
@fazzysyed @nys99 Hi guys! Have you seen this thread? #7
First of all try to use model used here
Hi @jaroslawkrol thank you for the response and Happy New Year! I came across that thread and used the model that was mentioned there and that works for me!
However, It seems like I am having a similar issue with my model that it does not include metadata, however my error message is slightly different:
java.lang.RuntimeException: Error occurred when initializing ObjectDetector: Input tensor has type kTfLiteFloat32: it requires specifying NormalizationOptions metadata to preprocess input images.
Is the solution to add metadata to add metadata to the model?