-
Notifications
You must be signed in to change notification settings - Fork 79
Barracuda + MiDaS v2 #187
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
Comments
Hi @GeorgeAdamon thanks for reporting we will be looking into it! |
Thanks in advance for your time @FlorentGuinier ! |
Sure! I was looking into converting the model to repro however it seems at least on my system this is a bit of a rabbithole. PS: random weights are fine. |
Thanks! So the problem here is that some convolution in the model are using "group" that are not 1 nor the input channel count. At the moment we only support those two version (ie regular convolution with group == 1, and depthwise convolution where group == input channel count). I will clarify the error message, however the real question here is "Do you need DepthwiseConvolution where group != input channel?". Is so please let us know your use case and dead line and we will open a feature request. |
Thanks for your reply @FlorentGuinier! To be honest, I am not familiar with the design philosophy of this model, therefore the reasons that led the authors to this kind of convolution, and whether this approach is inevitable / needed. I can try and raise this with intel isl, linking to this issue. The use-case is an academic one, a few groups of UCL interactive design students rely on this algorithm to be able to sense depth using simple smartphone cameras (not Lidar iphones). Their tests work using the offline python scripts, but their projects are actually real-time 3d, so the python workflow would add significant overhead. They would ideally like to have something presentable by end of June (intermediate crits). |
@FlorentGuinier as you can see in isl-org/MiDaS#113, this architectural feature is crucial for the MiDaS model. Are grouped convolutions something that the Unity Barracuda would be interested in supporting ? |
We have no immediate plan of supporting depthwise conv with group != channel atm unfortunatly, also performance might be hard with current implementaiton for realtime use case on mobile. Have you consider XRFoundation for the depth estimation? |
https://github.com/GeorgeAdamon/monocular-depth-unity Followed @ranftlr 's advice and used an alternative smaller model. Works like a charm ! It's absolutely worth doing performance/quality comparisons on mobile between MiDaS & XRFoundation. Thanks a lot for your help @FlorentGuinier |
Still a shame that the larger MiDaS model doesn't work with Barracuda. I'm using it on desktop and the PC is more than capable of running inference on that model in realtime. For now I'm stuck with the MiDaS small model... Hopefully MiDaS 3 will work with Barracuda. |
Hi @wtesler, Happy new year! |
Hi @FlorentGuinier, I am hoping that an ONXX distribution of MiDaS 3 comes out soon which is based on something called a Dense Predictive Transformer (So totally different than MiDaS 2), but also in the meantime, Using the larger MiDaS 2 model would be my short-term goal. |
Interresting! Back to square one :)
Florent |
@FlorentGuinier I would say the depthwise conv would be nice, and other people may benefit from it because MiDaS is excellent for AR applications and thus is a natural fit for Unity. I don't have a specific deadline for the project because the smaller MiDaS model at least works to some degree, it's just a matter of quality improvement to see the larger model work. |
I'm adding this to the backlog, thanks for your feedback. |
@FlorentGuinier Is there any status update on this item (depthwise conv) ? |
I would recommend signing up to Sentis |
Uh oh!
There was an error while loading. Please reload this page.
Hello I'm trying to run Intel's MiDaS v2 Monocular-Image-To-Depth model, which is provided by the authors in .onnx format. Here's my environment:
The model loads fine in Unity, without warnings, and I generate my tensors by providing a texture in the right format (RGB24, 384 x 384). However when I try to execute the model, I get this error pointing to the
DepthwiseConv2D
operator:The error seems to be triggered here:
Is this genuinely something that is not supported at the moment, or does the .onnx model need to be transformed slightly for it to play nicely with Barracuda?
Any help would be appreciated !
The text was updated successfully, but these errors were encountered: