Open ForJadeForest opened 1 month ago
Hi @ForJadeForest,
This is the desired behaviour: we don't want to experience nans in our outputs and the latest version doesn't have this. It's true that we generally want consistency of behaviour across versions, however in this case it appears there's a fix which we want
Hi @ForJadeForest,
This is the desired behaviour: we don't want to experience nans in our outputs and the latest version doesn't have this. It's true that we generally want consistency of behaviour across versions, however in this case it appears there's a fix which we want
Yeah, but I try to my old conda env with 4.33.2 transformers and I get the correct output. The old env's sys info is
- `transformers` version: 4.33.2
- Platform: Linux-4.15.0-76-generic-x86_64-with-glibc2.27
- Python version: 3.10.14
- Huggingface_hub version: 0.24.3
- Safetensors version: 0.4.3
- Accelerate version: 0.33.0
- Accelerate config: not found
- PyTorch version (GPU?): 2.0.1+cu117 (True)
- Tensorflow version (GPU?): not installed (NA)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Using GPU in script?: <fill in>
- Using distributed or parallel set-up in script?: <fill in>
The correct output with 4.33.2
The error output with 4.33.2
The output with 4.38.2
Btw, I find the first 4.33.2 output is different with 4.38.2 (I set do_sample to False). This phenomenon is very strange, it might affect my performance testing.
@ForJadeForest I'm not sure I understand the issue being reported. In the issue description, you said:
transformers version: 4.33.2 I run the official code in my machine, but get a invalid ouput. I try to do forward and find the logits are all NAN. But, when I upgrade my transformers package to 4.38.2 (Only upgrade the transformers). The result will be correct.
And then in the reply you said
Yeah, but I try to my old conda env with 4.33.2 transformers and I get the correct output.
So do you get the expected output with 4.33.2 or not?
Why are you comparing specifically with 4.38.2? Could you compare with the output on the most stable release -- 4.43.2? If there's a bug we can add commits which fix things for future releases - but we can't change the behaviour of older released versions
Sorry for my mistake. I meant there are three environments:
The other dependency packages are not identical between env_1 and env_2. However, env_2 and env_3 have the same dependency packages.
I have two questions:
do_sample = False
. This is problematic because I am trying to reproduce a paper, and the performance on all task (Image Captioning, VQA) of env_3 is lower compared to env_1. (Compared with figure1, the output of figure 3 are simple and less information. )This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.
Please note that issues that do not follow the contributing guidelines are likely to be ignored.
System Info
transformers
version: 4.33.2Who can help?
@amyeroberts @SunMarc
Information
Tasks
examples
folder (such as GLUE/SQuAD, ...)Reproduction
I run the official code in my machine, but get a invalid ouput.
output is below:
I try to do forward and find the logits are all NAN.
But, when I upgrade my transformers package to 4.38.2 (Only upgrade the transformers). The result will be correct.
Expected behavior
Different version of Transformers should generate the same output.