Skip to content
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

build: provide a seperate python3-dlib dependency package on debian #814

Open
wants to merge 4 commits into
base: beta
Choose a base branch
from

Conversation

dingobits
Copy link

@dingobits dingobits commented Jul 5, 2023

Since PEP 668, system-wide Python packages are exclusively managed by package managers, which breaks dlib install on Debian-based OS (#774,#807). Although it's possible to override this behaviour, it can potentially break system packages. Therefore, this PR changes Debian control files to install a separate python3-dlib dependency package.

Unfortunately, python3-dlib doesn't exist as an official Debian package. However, since the deb file is provided via Ubuntu PPA, it is easy to provide python3-dlib package in the same repo with stdeb.

pypi-download dlib
py2dsc dlib-[version].tar.gz

This will automatically build a Debian source package that can be directly uploaded to Launchpad for building.

I have successfully built the packages with the latest beta. You can find the binary packages here.

@Winson-Huang
Copy link

You mean that gdebi the two packages in your release will fix the issue, right?

@Winson-Huang
Copy link

I tried this way, but the python3-lib package's dependency libstdc++6(>13.1) is not satisfied in Debian 12

@dingobits
Copy link
Author

@Winson-Huang I use Debian trixie, which uses GCC 13. I rebuilt the packages on bookworm and they should work for you. They're the deb12 variant on the same release page.

@Octopus1348
Copy link

Nice! I downloaded the deb12 variant, and it works on Ubuntu 23.10, just needs some extra stuff.
I had to install libinih-dev, it ended with an error, but sudo apt --fix-broken install fixed it.
When I tried to add a face using sudo howdy add, it dropped an error, and requested that I run sudo howdy config and change the device_path value, so I did. I ls'd /dev/v4l/by-path/, and have seen the camera devices, selected the one that end with index0, and so changed the value to /dev/v4l/by-path/pci-0000:00:1a.7-usb-0:2:1.0-video-index0.
Now I could add a face without problems, and the authentication works!

Comment on lines -179 to -185
log("Configuring howdy")

# Manually change the camera id to the one picked
for line in fileinput.input(["/etc/howdy/config.ini"], inplace=1):
line = line.replace("use_cnn = false", "use_cnn = " + str(cuda_used).lower())
print(line, end="")

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why did you remove these lines?

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CNN depends on CUDA, and nvidia-cuda-dev is only a suggested package i guess. Could negatively impact performance by not enabling it automatically like this

Comment on lines -179 to -185
log("Configuring howdy")

# Manually change the camera id to the one picked
for line in fileinput.input(["/etc/howdy/config.ini"], inplace=1):
line = line.replace("use_cnn = false", "use_cnn = " + str(cuda_used).lower())
print(line, end="")

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CNN depends on CUDA, and nvidia-cuda-dev is only a suggested package i guess. Could negatively impact performance by not enabling it automatically like this

@@ -9,9 +9,9 @@ Vcs-Git: https://github.com/boltgolt/howdy
Package: howdy
Homepage: https://github.com/boltgolt/howdy
Architecture: amd64
Depends: ${misc:Depends}, libc6, libgcc-s1, libpam0g, libstdc++6, curl | wget, python3, python3-pip, python3-dev, python3-setuptools, python3-numpy, python-opencv | python3-opencv, libopencv-dev, cmake, libinih-dev
PreDepends: python3:any | python3-minimal:any
Depends: ${misc:Depends}, libc6, libgcc-s1, libpam0g, libstdc++6, curl | wget, python3, python3-pip, python3-dev, python3-setuptools, python3-numpy, python-opencv | python3-opencv, libopencv-dev, cmake, libinih-dev, python3-dlib
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that python3-dlib was not used because it crashed a LOT for a ton of people in the early days. Is it stable now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants