1{ buildPythonPackage, fetchFromGitHub, pillow, click, dlib, numpy 2, face_recognition_models, stdenv, flake8, pytest, glibcLocales 3}: 4 5buildPythonPackage rec { 6 pname = "face_recognition"; 7 version = "1.2.2"; 8 9 src = fetchFromGitHub { 10 repo = pname; 11 owner = "ageitgey"; 12 rev = "v${version}"; 13 sha256 = "17jnyr80j1p74gyvh1jabvwd3zsxvip2y7cjhh2g6gsjv2dpvrjv"; 14 }; 15 16 postPatch = '' 17 substituteInPlace setup.py --replace "flake8==2.6.0" "flake8" 18 ''; 19 20 propagatedBuildInputs = [ pillow click dlib numpy face_recognition_models ]; 21 22 checkInputs = [ flake8 pytest glibcLocales ]; 23 checkPhase = '' 24 LC_ALL="en_US.UTF-8" py.test 25 ''; 26 27 meta = with stdenv.lib; { 28 license = licenses.mit; 29 homepage = https://github.com/ageitgey/face_recognition; 30 maintainers = with maintainers; [ ma27 ]; 31 description = "The world's simplest facial recognition api for Python and the command line"; 32 }; 33}