diff options
author | Daniƫl de Kok <me@danieldk.eu> | 2020-09-01 15:49:05 +0200 |
---|---|---|
committer | Jon <jonringer@users.noreply.github.com> | 2020-09-01 10:33:34 -0700 |
commit | 2fb0ad3018044af858b9a93320752a2e3078d17d (patch) | |
tree | 5efd52f7e9e5e10f75260133f949f6632c39829e /pkgs/development/python-modules | |
parent | fee2b5df4184ec0c45ae5b85b07a48535554702f (diff) | |
download | nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar.gz nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar.bz2 nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar.lz nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar.xz nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.tar.zst nixpkgs-2fb0ad3018044af858b9a93320752a2e3078d17d.zip |
python3Packages.transformers: 3.0.2 -> 3.1.0
Transformers now has `nlp` as an optional dependency. `nlp` will require some work to package, since it attempts to download modules into its Python package path by default. So, the `nlp`-based test is disable for the time being.
Diffstat (limited to 'pkgs/development/python-modules')
-rw-r--r-- | pkgs/development/python-modules/transformers/default.nix | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/pkgs/development/python-modules/transformers/default.nix b/pkgs/development/python-modules/transformers/default.nix index eb7c1c2aa48..aa6db6a7353 100644 --- a/pkgs/development/python-modules/transformers/default.nix +++ b/pkgs/development/python-modules/transformers/default.nix @@ -16,13 +16,13 @@ buildPythonPackage rec { pname = "transformers"; - version = "3.0.2"; + version = "3.1.0"; src = fetchFromGitHub { owner = "huggingface"; repo = pname; rev = "v${version}"; - sha256 = "0rdlikh2qilwd0s9f3zif51p1q7sp3amxaccqic8p5qm6dqpfpz6"; + sha256 = "0wg36qrcljmpsyhjaxpqw3s1r6276yg8cq0bjrf52l4zlc5k4xzk"; }; propagatedBuildInputs = [ @@ -44,16 +44,23 @@ buildPythonPackage rec { postPatch = '' substituteInPlace setup.py \ - --replace "tokenizers == 0.8.1.rc1" "tokenizers>=0.8" + --replace "tokenizers == 0.8.1.rc2" "tokenizers>=0.8" ''; preCheck = '' export HOME="$TMPDIR" cd tests + + # This test requires the nlp module, which we haven't + # packaged yet. However, nlp is optional for transformers + # itself + rm test_trainer.py ''; # Disable tests that require network access. disabledTests = [ + "PegasusTokenizationTest" + "T5TokenizationTest" "test_all_tokenizers" "test_batch_encoding_is_fast" "test_batch_encoding_pickle" @@ -63,6 +70,7 @@ buildPythonPackage rec { "test_hf_api" "test_outputs_can_be_shorter" "test_outputs_not_longer_than_maxlen" + "test_padding_accepts_tensors" "test_pretokenized_tokenizers" "test_tokenizer_equivalence_en_de" "test_tokenizer_from_model_type" @@ -74,6 +82,7 @@ buildPythonPackage rec { meta = with stdenv.lib; { homepage = "https://github.com/huggingface/transformers"; description = "State-of-the-art Natural Language Processing for TensorFlow 2.0 and PyTorch"; + changelog = "https://github.com/huggingface/transformers/releases/tag/v${version}"; license = licenses.asl20; platforms = platforms.unix; maintainers = with maintainers; [ danieldk pashashocky ]; |