Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mask2FormerImageProcessor - fails to process multichannel image #33295

Closed
2 of 4 tasks
maciej-adamiak opened this issue Sep 4, 2024 · 3 comments · Fixed by #33364
Closed
2 of 4 tasks

Mask2FormerImageProcessor - fails to process multichannel image #33295

maciej-adamiak opened this issue Sep 4, 2024 · 3 comments · Fixed by #33364
Labels

Comments

@maciej-adamiak
Copy link
Contributor

System Info

  • transformers version: 4.43.4
  • Platform: Linux-6.5.0-1027-oem-x86_64-with-glibc2.35
  • Python version: 3.11.9
  • Huggingface_hub version: 0.24.6
  • Safetensors version: 0.4.4
  • Accelerate version: not installed
  • Accelerate config: not found
  • PyTorch version (GPU?): 2.4.0 (True)
  • Tensorflow version (GPU?): not installed (NA)
  • Flax version (CPU?/GPU?/TPU?): not installed (NA)
  • Jax version: not installed
  • JaxLib version: not installed
  • Using distributed or parallel set-up in script?: no
  • Using GPU in script?: yes
  • GPU type: NVIDIA RTX A4500 Laptop GPU

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

Colab

Expected behavior

The image processing should be handled correctly.

It looks like the get_max_height_width is using a default parameter rather then a value input_data_format set in the class constructor.

@LysandreJik
Copy link
Member

cc @qubvel or @zucchini-nlp in case you have some bandwidth!

@qubvel
Copy link
Member

qubvel commented Sep 6, 2024

Hi @maciej-adamiak , thanks for opening an issue and providing an example to reproduce!

Would you like to make a fix? We should make sure that input_data_format is passed to get_max_height_width and all other transforms correctly handle it.

@maciej-adamiak
Copy link
Contributor Author

I'm on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants