AttributeError: 'Seq2SeqTrainer' object has no attribute 'is_fsdp_xla_enabled'
Author: abinzzz
Pull request: no
Labels: name: bug

### System Info

```
# packages in environment at /home/cyb/miniconda3/envs/edgellm:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main  
_openmp_mutex             5.1                       1_gnu  
accelerate                0.33.0                   pypi_0    pypi
aiohttp                   3.9.5                    pypi_0    pypi
aiosignal                 1.3.1                    pypi_0    pypi
async-timeout             4.0.3                    pypi_0    pypi
attrs                     23.2.0                   pypi_0    pypi
bitsandbytes              0.43.2                   pypi_0    pypi
blas                      1.0                         mkl  
brotli-python             1.0.9            py39h6a678d5_8  
bzip2                     1.0.8                h5eee18b_6  
ca-certificates           2024.7.2             h06a4308_0  
certifi                   2024.7.4         py39h06a4308_0  
charset-normalizer        3.3.2              pyhd3eb1b0_0  
click                     8.1.7                    pypi_0    pypi
cuda-cudart               12.4.127                      0    nvidia
cuda-cupti                12.4.127                      0    nvidia
cuda-libraries            12.4.0                        0    nvidia
cuda-nvrtc                12.4.127                      0    nvidia
cuda-nvtx                 12.4.127                      0    nvidia
cuda-opencl               12.5.39                       0    nvidia
cuda-runtime              12.4.0                        0    nvidia
cuda-version              12.5                          3    nvidia
datasets                  2.20.0                   pypi_0    pypi
deepdiff                  7.0.1                    pypi_0    pypi
dill                      0.3.8                    pypi_0    pypi
dipy                      1.9.0                    pypi_0    pypi
docker-pycreds            0.4.0                    pypi_0    pypi
evaluate                  0.4.2                    pypi_0    pypi
ffmpeg                    4.3                  hf484d3e_0    pytorch
filelock                  3.13.1           py39h06a4308_0  
freetype                  2.12.1               h4a9f257_0  
frozenlist                1.4.1                    pypi_0    pypi
fsspec                    2024.5.0                 pypi_0    pypi
gitdb                     4.0.11                   pypi_0    pypi
gitpython                 3.1.43                   pypi_0    pypi
gmp                       6.2.1                h295c915_3  
gmpy2                     2.1.2            py39heeb90bb_0  
gnutls                    3.6.15               he1e5248_0  
h5py                      3.11.0                   pypi_0    pypi
huggingface-hub           0.24.2                   pypi_0    pypi
idna                      3.7              py39h06a4308_0  
intel-openmp              2023.1.0         hdb19cb5_46306  
jinja2                    3.1.4            py39h06a4308_0  
joblib                    1.4.2                    pypi_0    pypi
jpeg                      9e                   h5eee18b_2  
lame                      3.100                h7b6447c_0  
lcms2                     2.12                 h3be6417_0  
ld_impl_linux-64          2.38                 h1181459_1  
lerc                      3.0                  h295c915_0  
libcublas                 12.4.2.65                     0    nvidia
libcufft                  11.2.0.44                     0    nvidia
libcufile                 1.10.1.7                      0    nvidia
libcurand                 10.3.6.82                     0    nvidia
libcusolver               11.6.0.99                     0    nvidia
libcusparse               12.3.0.142                    0    nvidia
libdeflate                1.17                 h5eee18b_1  
libffi                    3.4.4                h6a678d5_1  
libgcc-ng                 11.2.0               h1234567_1  
libgomp                   11.2.0               h1234567_1  
libiconv                  1.16                 h5eee18b_3  
libidn2                   2.3.4                h5eee18b_0  
libjpeg-turbo             2.0.0                h9bf148f_0    pytorch
libnpp                    12.2.5.2                      0    nvidia
libnvfatbin               12.5.82                       0    nvidia
libnvjitlink              12.4.99                       0    nvidia
libnvjpeg                 12.3.1.89                     0    nvidia
libpng                    1.6.39               h5eee18b_0  
libstdcxx-ng              11.2.0               h1234567_1  
libtasn1                  4.19.0               h5eee18b_0  
libtiff                   4.5.1                h6a678d5_0  
libunistring              0.9.10               h27cfd23_0  
libwebp-base              1.3.2                h5eee18b_0  
llvm-openmp               14.0.6               h9e868ea_0  
lz4-c                     1.9.4                h6a678d5_1  
markupsafe                2.1.3            py39h5eee18b_0  
mkl                       2023.1.0         h213fc3f_46344  
mkl-service               2.4.0            py39h5eee18b_1  
mkl_fft                   1.3.8            py39h5eee18b_0  
mkl_random                1.2.4            py39hdb19cb5_0  
mpc                       1.1.0                h10f8cd9_1  
mpfr                      4.0.2                hb69a4c5_1  
mpmath                    1.3.0            py39h06a4308_0  
multidict                 6.0.5                    pypi_0    pypi
multiprocess              0.70.16                  pypi_0    pypi
ncurses                   6.4                  h6a678d5_0  
nettle                    3.7.3                hbbd107a_1  
networkx                  3.2.1            py39h06a4308_0  
nibabel                   5.2.1                    pypi_0    pypi
numpy                     1.26.4           py39h5f9d8c6_0  
numpy-base                1.26.4           py39hb5e798b_0  
openh264                  2.1.1                h4ff587b_0  
openjpeg                  2.4.0                h9ca470c_2  
openssl                   3.0.14               h5eee18b_0  
ordered-set               4.1.0                    pypi_0    pypi
packaging                 24.1                     pypi_0    pypi
pandas                    2.2.2                    pypi_0    pypi
peft                      0.12.0                   pypi_0    pypi
pillow                    10.4.0           py39h5eee18b_0  
pip                       24.0             py39h06a4308_0  
platformdirs              4.2.2                    pypi_0    pypi
protobuf                  5.27.2                   pypi_0    pypi
psutil                    6.0.0                    pypi_0    pypi
pyarrow                   17.0.0                   pypi_0    pypi
pyarrow-hotfix            0.6                      pypi_0    pypi
pysocks                   1.7.1            py39h06a4308_0  
python                    3.9.19               h955ad1f_1  
python-dateutil           2.9.0.post0              pypi_0    pypi
pytorch                   2.4.0           py3.9_cuda12.4_cudnn9.1.0_0    pytorch
pytorch-cuda              12.4                 hc786d27_6    pytorch
pytorch-mutex             1.0                        cuda    pytorch
pytz                      2024.1                   pypi_0    pypi
pyyaml                    6.0.1            py39h5eee18b_0  
readline                  8.2                  h5eee18b_0  
regex                     2024.7.24                pypi_0    pypi
requests                  2.32.3           py39h06a4308_0  
safetensors               0.4.3                    pypi_0    pypi
scikit-learn              1.5.1                    pypi_0    pypi
scipy                     1.13.1                   pypi_0    pypi
sentencepiece             0.2.0                    pypi_0    pypi
sentry-sdk                2.11.0                   pypi_0    pypi
setproctitle              1.3.3                    pypi_0    pypi
setuptools                69.5.1           py39h06a4308_0  
setuptools-scm            8.1.0                    pypi_0    pypi
six                       1.16.0                   pypi_0    pypi
smmap                     5.0.1                    pypi_0    pypi
sqlite                    3.45.3               h5eee18b_0  
sympy                     1.12             py39h06a4308_0  
tbb                       2021.8.0             hdb19cb5_0  
threadpoolctl             3.5.0                    pypi_0    pypi
time-python               0.0.17                   pypi_0    pypi
tk                        8.6.14               h39e8969_0  
tokenizers                0.15.2                   pypi_0    pypi
tomli                     2.0.1                    pypi_0    pypi
torchaudio                2.4.0                py39_cu124    pytorch
torchtriton               3.0.0                      py39    pytorch
torchvision               0.19.0               py39_cu124    pytorch
tqdm                      4.66.4                   pypi_0    pypi
transformers              4.36.2                   pypi_0    pypi
trx-python                0.3                      pypi_0    pypi
typing_extensions         4.11.0           py39h06a4308_0  
tzdata                    2024.1                   pypi_0    pypi
urllib3                   2.2.2            py39h06a4308_0  
wandb                     0.17.5                   pypi_0    pypi
wheel                     0.43.0           py39h06a4308_0  
xxhash                    3.4.1                    pypi_0    pypi
xz                        5.4.6                h5eee18b_1  
yaml                      0.2.5                h7b6447c_0  
yarl                      1.9.4                    pypi_0    pypi
zlib                      1.2.13               h5eee18b_1  
zstd                      1.5.5                hc292b87_2 
```

### Who can help?

_No response_

### Information

- [ ] The official example scripts
- [ ] My own modified scripts

### Tasks

- [ ] An officially supported task in the `examples` folder (such as GLUE/SQuAD, ...)
- [ ] My own task or dataset (give details below)

### Reproduction

Traceback (most recent call last):
  File "/mnt/sda/cyb/Edge-LLM/main.py", line 384, in <module>
    train()
  File "/mnt/sda/cyb/Edge-LLM/main.py", line 372, in train
    train_result = trainer.train()
  File "/home/cyb/miniconda3/envs/edgellm/lib/python3.9/site-packages/transformers/trainer.py", line 1537, in train
    return inner_training_loop(
  File "/mnt/sda/cyb/Edge-LLM/utils/trainer_wrappers.py", line 663, in _inner_training_loop
    model = self._wrap_model(self.model_wrapped)
  File "/home/cyb/miniconda3/envs/edgellm/lib/python3.9/site-packages/transformers/trainer.py", line 1347, in _wrap_model
    if self.is_fsdp_xla_enabled:
AttributeError: 'Seq2SeqTrainer' object has no attribute 'is_fsdp_xla_enabled'

### Expected behavior

help

Comments: