InvokeAI icon indicating copy to clipboard operation
InvokeAI copied to clipboard

[bug]: Patchmatch not loaded

Open NathanHazout opened this issue 2 years ago • 5 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

OS

macOS

GPU

amd

VRAM

No response

What happened?

During the first run after installing I got Patchmatch not loaded. I followed the instructions here https://github.com/invoke-ai/InvokeAI/blob/main/docs/installation/060_INSTALL_PATCHMATCH.md and ran
brew install opencv which installed sucessfully.

Still, Patchmatch not loaded at every run.

Screenshots

No response

Additional context

No response

Contact Details

No response

NathanHazout avatar Feb 02 '23 14:02 NathanHazout

@mauwii , could you have a look at this issue? I know that the brew recipe has been working for you.

lstein avatar Feb 03 '23 22:02 lstein

@NathanHazout could you please open a terminal, execute pkg-config --cflags opencv4 and post your output here?

mauwii avatar Feb 04 '23 22:02 mauwii

-I/opt/homebrew/opt/opencv/include/opencv4

NathanHazout avatar Feb 08 '23 13:02 NathanHazout

Ok, same for me, that's weird.

Your Verison of InvokeAI is up to date?

Which kind of Installation did you use?

When you write you followed these instructions, have you done more than just brew install opencv?

mauwii avatar Feb 08 '23 18:02 mauwii

It was the latest available release at the time of the writing (how do I check InvokeAI version?). I am trying to now update to the latest release.

I used the automated install (invoke.sh), and did nothing more than the instructions.

Note however that, as mentioned in this issue https://github.com/invoke-ai/InvokeAI/issues/2723 , there is something strange with python ...

NathanHazout avatar Feb 19 '23 06:02 NathanHazout

(I am reinstalling everything. Both python and invokeai)

NathanHazout avatar Feb 20 '23 13:02 NathanHazout

I wonder if it's related to opencv. Notice how it installs 3.11

hazout@f4d48896053f invokeai % brew install opencv
Running `brew update --auto-update`...
==> Auto-updated Homebrew!
Updated 1 tap (coursier/formulas).
==> Downloading https://formulae.brew.sh/api/formula.json
#=#=#                                                                         
==> Downloading https://formulae.brew.sh/api/cask.json
#=#=#                                                                         

You have 5 outdated formulae installed.
You can upgrade them with brew upgrade
or list them with brew outdated.

==> Fetching dependencies for opencv: cmocka, libvpx, ffmpeg, [email protected], qt@5 and vtk

NathanHazout avatar Feb 20 '23 14:02 NathanHazout

Reinstalling everything fixed the issue.

What changed:

  • I installed Python through the official installer instead of pyenv
  • I picked python 3.10 instead of 3.9
  • Even though brew installed python as a dependency of opencv, it happened AFTER I has already installed a fresh python

NathanHazout avatar Feb 20 '23 15:02 NathanHazout

Brew is using it's own python environment and normaly you should also set up a alias for brew which is removing the pyenv shims from the PATH:

alias brew='env PATH="${PATH//$(pyenv root)\/shims:/}" brew'

source

But happy to hear that the problem got resolved!

mauwii avatar Feb 20 '23 16:02 mauwii