Skip to content

Troubleshooting for MacOS 12.3.1+Python3.9.6+OpenCV4.5.5 #71

@ShuchangXu

Description

@ShuchangXu

In case anyone is trying to run face_morpher on the Dlib branch, here are the solutions to some issues I encountered.

My environment:

MacOS 12.3.1 with M1 chip
Python 3.9.6
OpenCV 4.5.5

1. cv2 not found

Please install openCV as follows:

$ brew update
$ brew install opencv

In my case, openCV 4.5.5 is installed.

You may have to export PYTHONPATH:
export PYTHONPATH=$PYTHONPATH:/opt/homebrew/Cellar/opencv/4.5.5_2/lib/python3.9/site-packages (this is the path in my case)

2. symbol not found in flat namespace '_png_do_expand_palette_rgb8_neon'

Please reinstall dlib as follows:
pip3 install dlib --force-reinstall --no-cache-dir --global-option=build_ext

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions