at master 1.2 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 pytestCheckHook, 6 pythonOlder, 7 matplotlib, 8 numpy, 9 pendulum, 10 pillow, 11 poetry-core, 12 pyquaternion, 13}: 14 15buildPythonPackage { 16 pname = "bbox"; 17 version = "0.9.4"; 18 pyproject = true; 19 20 disabled = pythonOlder "3.6"; 21 22 src = fetchFromGitHub { 23 owner = "varunagrawal"; 24 repo = "bbox"; 25 # matches 0.9.4 on PyPi + tests 26 rev = "d3f07ed0e38b6015cf4181e3b3edae6a263f8565"; 27 hash = "sha256-FrJ8FhlqwmnEB/QvPlkDfqZncNGPhwY9aagM9yv1LGs="; 28 }; 29 30 nativeBuildInputs = [ poetry-core ]; 31 32 postPatch = '' 33 substituteInPlace bbox/metrics.py \ 34 --replace-warn round_ round 35 ''; 36 37 propagatedBuildInputs = [ 38 pyquaternion 39 numpy 40 ]; 41 42 nativeCheckInputs = [ 43 matplotlib 44 pendulum 45 pillow 46 pytestCheckHook 47 ]; 48 49 disabledTests = [ 50 # performance test, racy on busy machines 51 "test_multi_jaccard_index_2d_performance" 52 ]; 53 54 pythonRelaxDeps = [ "numpy" ]; 55 56 pythonImportsCheck = [ "bbox" ]; 57 58 meta = { 59 description = "Python library for 2D/3D bounding boxes"; 60 homepage = "https://github.com/varunagrawal/bbox"; 61 license = lib.licenses.mit; 62 maintainers = with lib.maintainers; [ lucasew ]; 63 }; 64}