-
Notifications
You must be signed in to change notification settings - Fork 59
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
[WIP FEATURE] Linux Snap Install #152
Comments
Are you all open to updating the logic here for determining the Python interpreter? Some Linux distros have stopped shipping a Python interpreter named |
Yes, I think so. Looking back at that logic, I'm actually a little bit confused why we do that (get the path, and then append the right executable name to it).. I would think that Anyway, yes, definitely open to any improvements here! |
nope, not missing anything. we should be using sys.executable. this will ensure we are pointing to the same python interpreter that was used in the virtual environment. |
Hi @frenchwr - do you want to create the PR for this one? if not I can do it. thanks! |
A few other nice-to-haves if you're open to it:
from gimpopenvino.plugins.openvino_utils.tools.model_manager import ModelManger
I'm happy to help make these changes and test, but just wanted to get your thoughts first in case I'm missing something. |
Also I can create a separate issue for this if you prefer, but whenever I run stable diffusion on a NPU (balanced or power efficiency mode) I'm seeing errors like the following: File "/snap/gimp/x14/usr/lib/x86_64-linux-gnu/gimp/2.99/plug-ins/openvino_utils/tools/openvino_common/models_ov/stable_diffusion_engine.py", line 157, in load_model
with open(os.path.join(model, f"{model_name}.blob"), "rb") as f:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/home/ubuntu/openvino-ai-plugins-gimp/weights/stable-diffusion-ov/stable-diffusion-1.5/square_int8/unet_int8.blob' I don't see those blob files after downloading the models with |
Please feel free to make the changes and submit a PR, thanks!
After the model download completes, the NPU .blobs should get created. For example, see step 3 of the standalone script README. If that is not happening, let me know. Which platform are you running on? |
Aha - ok all good now. I didn't realize the NPU runtime libs were needed at the model download stage. I assume the models are compiled for the NPU at this stage because the compilation is somewhat slow? |
I'll work on a PR tomorrow. This will get me really close to having the snap functioning without any hacks in the packaging. |
Correct. We don't want to have the user waiting for the models to compile the first time they run a specific feature. So we compile them at model download time, since they are already waiting for the models to download. |
@RyanMetcalfeInt8 @gblong1 I just opened a PR with the changes I mentioned yesterday: #156 Let me know what you think. |
Thanks! We'll test it out and provide any feedback. |
Hello! The snap packaging work is very close to being done on our (Canonical) side. I was hoping to share some details today for how you could test and provide feedback, but unfortunately it's not quite ready. I'll have something to share in the new year. Happy holidays! |
Hi @gblong1 and @RyanMetcalfeInt8 , We have published a version of the GIMP snap (still using version 2.99.16 at this point) in the Snap Store. If you want to try installing it on an Ubuntu 24.04 machine and running some tests that would be valuable feedback for us! Instructions for installing and running can be found in the README here: https://github.com/snapcrafters/gimp/tree/2.99-openvino Some notes:
Let us know what you think! We hope this will make the GIMP plugin work you've done more accessible for Linux users. |
Let's coordinate tasks needed to support Snap installation on Ubuntu (and other distros)
All changes to support this feature will go into
snap
branch, so please target PRs accordingly. Once it's all working alongside the traditional Windows/Linux install mechanism, we'll mergesnap
intomain
.Some initial details (from @frenchwr), in response to this question: "Would it be possible for you to give a high level description of what the Snap installation will actually do? e.g. Will it invoke install.sh, or simply extract some bundled set of artifacts (like python virtual env.) from a previous installation?"
TODO List (This will grow):
The text was updated successfully, but these errors were encountered: