Something went wrong. Try again.
What happens if I push all of nixpkgs
Something went wrong. Try again.
1.7 kB · 79 lines
Nix
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980{ lib, stdenv, fetchFromGitHub, fetchpatch, buildPythonPackage, pytestCheckHook, setuptools, matplotlib, numpy, packaging, torch, tqdm, flask, flask-compress, parameterized, scikit-learn,}:
buildPythonPackage rec { pname = "captum"; version = "0.8.0"; pyproject = true;
build-system = [ setuptools ];
src = fetchFromGitHub { owner = "pytorch"; repo = "captum"; tag = "v${version}"; hash = "sha256-WuKbMYZPHWaTYYhVseSSkwXQk9LBzGuWfmneDw9V2hg="; };
dependencies = [ matplotlib numpy packaging torch tqdm ];
pythonRelaxDeps = [ "numpy" ];
pythonImportsCheck = [ "captum" ];
nativeCheckInputs = [ pytestCheckHook flask flask-compress parameterized scikit-learn ];
disabledTestPaths = lib.optionals stdenv.hostPlatform.isDarwin [ # These tests may fail if multiple builds run them at the same time due # to hardcoded port number used for rendezvous "tests/attr/test_data_parallel.py" ] ++ lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) [ # Issue reported upstream at https://github.com/pytorch/captum/issues/1447 "tests/concept/test_tcav.py" ];
disabledTests = [ # Failing tests "test_softmax_classification_batch_zero_baseline" "test_tracin_identity_regression_9_check_idx_none_ArnoldiInfluenceFunction" ];
meta = { description = "Model interpretability and understanding for PyTorch"; homepage = "https://github.com/pytorch/captum"; license = lib.licenses.bsd3; maintainers = with lib.maintainers; [ drupol ]; };}