1{ stdenv 2, lib 3, pythonOlder 4, buildPythonPackage 5, fetchFromGitHub 6, numpy 7, scipy 8, pandas 9, matplotlib 10, tox 11, coverage 12, flake8 13, nbval 14, pyvisa 15, networkx 16, ipython 17, ipykernel 18, ipywidgets 19, jupyter-client 20, sphinx-rtd-theme 21, sphinx 22, nbsphinx 23, openpyxl 24, qtpy 25, pyqtgraph 26, pyqt5 27, setuptools 28, pytestCheckHook 29, pytest-cov 30, pytest-mock 31}: 32 33buildPythonPackage rec { 34 pname = "scikit-rf"; 35 version = "0.29.1"; 36 pyproject = true; 37 38 disabled = pythonOlder "3.7"; 39 40 src = fetchFromGitHub { 41 owner = "scikit-rf"; 42 repo = pname; 43 rev = "refs/tags/v${version}"; 44 hash = "sha256-sLE6rcBGUKmk5y7oO06rHON3GVIjcvnKlr6Tgddj64Y="; 45 }; 46 47 buildInputs = [ 48 setuptools 49 ]; 50 51 propagatedBuildInputs = [ 52 numpy 53 scipy 54 pandas 55 ]; 56 57 passthru.optional-dependencies = { 58 plot = [ 59 matplotlib 60 ]; 61 xlsx = [ 62 openpyxl 63 ]; 64 netw = [ 65 networkx 66 ]; 67 visa = [ 68 pyvisa 69 ]; 70 docs = [ 71 ipython 72 ipykernel 73 ipywidgets 74 jupyter-client 75 sphinx-rtd-theme 76 sphinx 77 nbsphinx 78 openpyxl 79 ]; 80 qtapps = [ 81 qtpy 82 pyqtgraph 83 pyqt5 84 ]; 85 }; 86 87 nativeCheckInputs = [ 88 tox 89 coverage 90 flake8 91 pytest-cov 92 pytest-mock 93 nbval 94 matplotlib 95 pyvisa 96 openpyxl 97 networkx 98 ]; 99 100 checkInputs = [ 101 pytestCheckHook 102 ]; 103 104 # test_calibration.py generates a divide by zero error on darwin 105 # https://github.com/scikit-rf/scikit-rf/issues/972 106 disabledTestPaths = 107 lib.optional (stdenv.isAarch64 && stdenv.isDarwin) 108 "skrf/calibration/tests/test_calibration.py"; 109 110 pythonImportsCheck = [ 111 "skrf" 112 ]; 113 114 meta = with lib; { 115 description = "A Python library for RF/Microwave engineering"; 116 homepage = "https://scikit-rf.org/"; 117 changelog = "https://github.com/scikit-rf/scikit-rf/releases/tag/v${version}"; 118 license = licenses.bsd3; 119 maintainers = with maintainers; [ lugarun ]; 120 }; 121}