-
Notifications
You must be signed in to change notification settings - Fork 4
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
PyTorch binding? #2
Comments
If you need equivalent models in PyTorch code, there you go (it'll be part of my new software https://torchstudio.ai ) : 2D customizable UNet:
1D customizable UNet:
|
I've used your c++ model for creating/training a unet model -- many thanks!! I'm now in the process of translating the model to onnx so I can embed it. So the python listing is extremely helpful too, since the onnx export is currently only supported from python. I noticed that the c++ and python models are not precisely the same. In particular, the python model seems to have two new variables, conv_per_block and add_merging. Per comparison with the c++ code, I think conv_per_block=2 and add_merging=false. Did I miss any other differences? |
That's right, if you leave those default values for conv_per_block and add_merging you'll get the same results as the C++ UNet. |
Thanks! |
I found a few places where the python and c++ code wasn't identical (required for onnx). See the SBW comments below:
|
Would it be possible to offer a pytorch binding? So this could be called from Python code?
The text was updated successfully, but these errors were encountered: