@@ -517,22 +517,17 @@ commands =
517517
518518[testenv:py{310,311}-transformers-{428,447,448,latest}]
519519deps =
520- # sentence-transformers 2.2.2 is the latest version that supports transformers 4.28.x
521- 428: sentence-transformers ==2.2.2
522- 428: transformers>=4.28.0,<4.29.0
523- 428: torch>=1.9.0,<1.14.0
524- 447: transformers>=4.47.0,<4.48.0
525- 447: torch>=1.9.0,<1.14.0
526- 455: transformers>=4.55.0,<4.56.0
527- 455: torch>=2.0.0,<2.1.0
528- latest: transformers>=4.55.0
529- latest: torch>=2.0.0
530- latest: accelerate>=1.6.0
531- tensorflow ==2.12.0
532- protobuf ==4.25.5
533- pip ==25.0.1
520+ # Environment dependencies are defined in the `setenv` section and installed in the `commands` section.
534521extras = test,gcp,ml_test
535- commands =
522+ setenv =
523+ COMMON_DEPS = tensorflow ==2.12.0 protobuf ==4.25.5 pip ==25.0.1
524+ # sentence-transformers 2.2.2 is the latest version that supports transformers 4.28.x
525+ 428: DEPS = sentence-transformers ==2.2.2 ' transformers>=4.28.0,<4.29.0' ' torch>=1.9.0,<1.14.0'
526+ 447: DEPS = ' transformers>=4.47.0,<4.48.0' ' torch>=1.9.0,<1.14.0'
527+ 455: DEPS = ' transformers>=4.55.0,<4.56.0' ' torch>=2.0.0,<2.1.0'
528+ latest: DEPS = ' transformers>=4.55.0' ' torch>=2.0.0' ' accelerate>=1.6.0'
529+ commands =
530+ /bin/sh -c " pip install .[{extras}] {env:DEPS} {env:COMMON_DEPS}"
536531 # Log transformers and its dependencies version for debugging
537532 /bin/sh -c " pip freeze | grep -E transformers"
538533 /bin/sh -c " pip freeze | grep -E torch"
0 commit comments