Files
nixpkgs/pkgs/development/python-modules/fvcore/default.nix
T
Ihar Hrachyshka 567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00

64 lines
1.2 KiB
Nix

{
lib,
buildPythonPackage,
fetchPypi,
pythonOlder,
# build inputs
numpy,
yacs,
pyyaml,
tqdm,
termcolor,
pillow,
tabulate,
iopath,
shapely,
# check inputs
torch,
}:
let
pname = "fvcore";
version = "0.1.5.post20221221";
optional-dependencies = {
all = [ shapely ];
};
in
buildPythonPackage {
inherit pname version;
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
hash = "sha256-8vsLuQVyrmUcEceOIEk+0ZsiQFUKfku7LW3oe90DeGA=";
};
propagatedBuildInputs = [
numpy
yacs
pyyaml
tqdm
termcolor
pillow
tabulate
iopath
];
nativeCheckInputs = [ torch ];
# TypeError: flop_count() missing 2 required positional arguments: 'model' and 'inputs'
doCheck = false;
pythonImportsCheck = [ "fvcore" ];
optional-dependencies = optional-dependencies;
meta = {
description = "Collection of common code that's shared among different research projects in FAIR computer vision team";
homepage = "https://github.com/facebookresearch/fvcore";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ happysalada ];
};
}