High memory usage

Hi,

I’m doing object detection with a model built with in Roboflow, consisting of around 2250 images, and running on Mac Mini M2 Pro with Roboflow.js. Object detection is currently running in a React app and on latest Opera browser. I’ve tried running on Safari and Chrome as well but Opera seems to be the best option.

So the issue I’m facing is that memory consumption seems to rise slowly but constantly until it reaches unacceptable levels and finally the system either shuts down or suggests to force quit Opera.

The model is trying to detect hands, food trays and utensils so three classes in total. If I run the same React app with a similar public model like EgoHands v9 then are no memory consumption issues. The EgoHands model has roughly twice the amount of images and four classses.

I’m currently tackling the issue by reloading the browser every now and then in order to keep memory consumption within acceptable limits. However, I’d like to be able to run the model for hours without interruptions. This seems to be doable with the currenrt setup and EgoHands.

At this point it seems like there’s some sort of an issue with the model and/or Roboflow.js’ way of utilizing it. I’ve tried to build differends kinds of models with different options and less images but the problem is still present.

Any help on how to tackle this would be appreciated. Thanks!

Project ID: ignaz-buffet-guard

Here’s another image of memory consumption.

Hey @Ilkka

Sorry to hear that you’re having issues! A couple clarifying questions so that we can help you better:

  • This issue is only happening on your model? (as opposed to the EgoHands model you mentioned)
  • Have you been able to test if this memory issue is consistent across devices and/or browsers?

Thanks for the reply and follow-up questions!

Yes, I’ve only noticed this memory issue with this model. Using for example EgoHands v9 doesn’t produce the same issue.

I’ve tested and noticed the same behaviour with my another computer (Macbook Pro M2 Pro). So yes, they’re both Macs with roughly the same kind of M2 Pro chips. I’ve tested the model with Chrome, Safari and Opera. Chrome seems to run into issues with memory consumption the quickest although Opera and Safari will react the same levels a little later.

Another thing I tested last night was that with Roboflow Inference Docker image this issue doesn’t appear meaning that the memory consumption will remain about the same for hours and doesn’t rise to unacceptable levels. So it seems this happens only with Roboflow.js.

Roboflow’s Support email account has access to the project.

Hi @Ilkka

Thank you for the extra details. We appreciate it and are looking into it.

Would you be able to look into the developer console of the browser and see if any console messages or errors appear?

Hi,

I’m using the model with Roboflow.js now as I’m writing this message. There are no messages in the developer console. Object detection is running continuously and providing expected results.

However, the GPU usage is high and is rising. Have you been able to replicate the issue at your end using this same model?

Hi @Ilkka

I see. I haven’t had the chance to try and replicate it yet, but I’ll try. Could you send the Universe project link or your workspace & project ID so that I can try to replicate the issues you are having?

The workspace ID is ilkka-l-cvgcn and project ID is ignaz-buffet-guard. Roboflow Support account has access to the project.

Thanks for your help!

Hi @Ilkka

How long of a time period did it take for the memory levels to increase? I tried recreating it, but was unable to after ten minutes of monitoring.

Also, could you share if you were using the embedded webcam demo, the demo webcam or another location? If you could share the URL of that, that would also be helpful.

Hi Leo,

And sorry for the delay in answering.

We did notice the memory consumption of browser’s GPU process to increase steadily rather quickly after starting the detection. You said you had tested for 10 minutes but would it be possible for you to leave the detection running in the background for an hour or so? That should be enough for the consumption to rise to high levels.

I’m sorry but I don’t have a public URL to share at this moment. But as long as the same model is run with Roboflow.js, you should be able to see the same behaviour.

Thanks for your help,
Ilkka

Hi @Ilkka

I was again not able to reproduce your issue, unfortunately.
image

To thoroughly troubleshoot your issue, could you go through the following steps:

  • Try in an incognito/private window (to isolate issues with possible extensions, etc)
  • Try using your model just through the Roboflow app: Click “Try with Webcam” on the Deploy page for your project.

Hi Leo,

And once again, thanks for your time. I’m glad you couldn’t reproduce the problem as it helps us in narrowing down possible causes.

I’ve tried with different browsers and in incognito mode but with no success.

However, I haven’t tried to preproduce the issue with Roboflow’s “Try with webcam”. I’ll do that and let you know how it goes.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.