diff options
author | Martin Weinelt <mweinelt@users.noreply.github.com> | 2023-06-28 17:37:58 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-06-28 17:37:58 +0200 |
commit | 42b603b67893fc2e9e75f7043a5c24bd14599521 (patch) | |
tree | fa9860bbcc5aa569fa9624c0fbf7d06c11644c35 | |
parent | 13d5e6245e67e7826a381ce563d94ccf2bfcbba8 (diff) | |
parent | be04cbebe13032e527737f3f6d978a70cc67b3b9 (diff) |
Merge pull request #237755 from natsukium/biopandas/init
python310Packages.biopandas: init at 0.4.1; python310Packages.mmtf-python: init at 1.1.3
-rw-r--r-- | pkgs/development/python-modules/biopandas/default.nix | 62 | ||||
-rw-r--r-- | pkgs/development/python-modules/mmtf-python/default.nix | 44 | ||||
-rw-r--r-- | pkgs/top-level/python-packages.nix | 4 |
3 files changed, 110 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/biopandas/default.nix b/pkgs/development/python-modules/biopandas/default.nix new file mode 100644 index 0000000000000..d33a9faf44031 --- /dev/null +++ b/pkgs/development/python-modules/biopandas/default.nix @@ -0,0 +1,62 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, looseversion +, mmtf-python +, nose +, numpy +, pandas +, pythonRelaxDepsHook +}: + +buildPythonPackage rec { + pname = "biopandas"; + version = "0.4.1"; + format = "setuptools"; + + src = fetchFromGitHub { + owner = "BioPandas"; + repo = "biopandas"; + rev = "refs/tags/v${version}"; + hash = "sha256-PRdemBo+bB2xJWmF2NylFTfNwEEo67i6XSaeDAFmQ/c="; + }; + + nativeBuildInputs = [ + pythonRelaxDepsHook + ]; + + pythonRelaxDeps = [ + "looseversion" + ]; + + propagatedBuildInputs = [ + numpy + pandas + mmtf-python + looseversion + ]; + + nativeCheckInputs = [ + nose + ]; + + checkPhase = '' + runHook preCheck + + nosetests + + runHook postCheck + ''; + + pythonImportsCheck = [ + "biopandas" + ]; + + meta = { + description = "Working with molecular structures in pandas DataFrames"; + homepage = "https://github.com/BioPandas/biopandas"; + changelog = "https://github.com/BioPandas/biopandas/releases/tag/${src.rev}"; + license = lib.licenses.bsd3; + maintainers = with lib.maintainers; [ natsukium ]; + }; +} diff --git a/pkgs/development/python-modules/mmtf-python/default.nix b/pkgs/development/python-modules/mmtf-python/default.nix new file mode 100644 index 0000000000000..197d0cf3e65bb --- /dev/null +++ b/pkgs/development/python-modules/mmtf-python/default.nix @@ -0,0 +1,44 @@ +{ lib +, buildPythonPackage +, fetchPypi +, msgpack +, numpy +, unittestCheckHook +}: + +buildPythonPackage rec { + pname = "mmtf-python"; + version = "1.1.3"; + format = "setuptools"; + + src = fetchPypi { + inherit pname version; + hash = "sha256-EqAv4bcTHworjORbRvHgzdKLmBj+RJlVTCaISYfqDDI="; + }; + + propagatedBuildInputs = [ + msgpack + numpy + ]; + + nativeCheckInputs = [ + unittestCheckHook + ]; + + unittestFlagsArray = [ + "-s mmtf/tests" + "-p \"*_tests.py\"" + ]; + + pythonImportsCheck = [ + "mmtf" + ]; + + meta = { + description = "The python implementation of the MMTF API, decoder and encoder"; + homepage = "https://github.com/rcsb/mmtf-python"; + changelog = "https://github.com/rcsb/mmtf-python/releases/tag/v${version}"; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ natsukium ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 3b1fd05cb344c..ec7cf76504c8c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -1326,6 +1326,8 @@ self: super: with self; { binwalk-full = self.binwalk.override { visualizationSupport = true; }; + biopandas = callPackage ../development/python-modules/biopandas { }; + biopython = callPackage ../development/python-modules/biopython { }; biplist = callPackage ../development/python-modules/biplist { }; @@ -6397,6 +6399,8 @@ self: super: with self; { mmpython = callPackage ../development/python-modules/mmpython { }; + mmtf-python = callPackage ../development/python-modules/mmtf-python { }; + mnemonic = callPackage ../development/python-modules/mnemonic { }; mne-python = callPackage ../development/python-modules/mne-python { }; |