Closed fdan closed 2 years ago
Hello @fdan ! And thanks for the request. You're right that there's less active development on this repo, particularly as this work has been superceded by the TorchScript / CatFileCreator work.
Regarding your own conversion and being unable to initialise an optimiser in TorchScript, would you mind sending that over to us (or something equivalent) to have a look? @johannabar
As for the asynchronous update process, while it is possible to do this (as shown in the Socket
example), I don't think we want to go there. One of the main reasons for not developing this work further is because we don't believe it's reliable enough to be used & supported in production. Re-engineering both the client & server code to handle asynchronous operations would be a big change in behaviour and would depart from our mostly state-less operation (which has helped so far.) I'd also be concerned about sending many more large uncompressed images over sockets as updates, something we've already heard is an issue when rendering sequences.
I can completely see the reasoning for asynchronous updates, like those seen in 'bucket' rendering, but sadly I don't think it's right for this project.
Hi @ringdk, thanks for the reply.
Unfortunately the inability to initialise an optimiser in TorchScript is an acknowledged limitation from the PyTorch folks - TorchScript allows only a limited range of usages compared to pytorch or torchlib. https://github.com/pytorch/pytorch/issues/80412
I ended up making the changes I need in a heavily modifed fork of the MLClient/Server, for research purposes it is doing what I need (multiple inputs, async update every n epochs), but like you said this is probably a significant divergence from the original design.
Longer term I'm looking to implement my pytorch code as a torchlib library, and then just write a conventional nuke node in c++, but it's been great to have the MLClient/Server code as a basis for prototyping.
Cross posting from the community forum where I posted a simpler repro: https://community.foundry.com/discuss/topic/159878/continuous-render-for-planariop
I'm trying to modify the MLClient / Server so that the server can pass progressive updates to the PlanarIop in Nuke. The reason for this is my model is an optimisation based style transfer, which can take a few minutes to run through sufficient epochs. My hope was to pass an update through for say every 10 epochs, so that the user gets some kind of color output quickly which then refines in front of them.
The only alternative I could think of was a button the user can press repeatedly to progressively refine the result, but that's not a great user experience.
Just tagging @ringdk as I'm not sure if this repo is still actively maintained. For what it's worth, I attempted to use Torchscript / Copycat, however a limitation there is that you cannot initialise an optimiser in Torchscript, which leaves my model dead in the water.