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

Unpinned the libjpeg version and fixed jpeg_mem_dest's size type Wind… #4288

Merged
merged 5 commits into from
Aug 19, 2021

Conversation

zzk1st
Copy link
Contributor

@zzk1st zzk1st commented Aug 18, 2021

Fixes #4181

@facebook-github-bot
Copy link

Hi @zzk1st!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks!

@NicolasHug
Copy link
Member

Thanks for working on this @zzk1st !
Let's see what the CI says - as a reference for the current CI health, you can check out #3808

We'll also need to make sure everything works on the fbcode side before merging this. Is there a corresponding diff on fbcode? If not let us know and we'll help you import the changes from GH to fbcode.

Copy link
Contributor

@datumbox datumbox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your PR.

I think the approach of defining a type conditionally will work. I like that you avoid using the preprocessor. I left one comment concerning windows, let me know what you think.

Before merging we should:

  1. Check that this patch works with both pinned and unpinned JPEG. This will help us ensure the solution works across different platforms and versions. A quick and dirty way to do this is to run the CI tests twice with the pinned and without it and confirm that all is green.
  2. Port this on FBcode and confirm that everything works there too.

The CI is currently a bit broken but based on what I see on master, it's only the cmake_windows_gpu job that should be failing. Worth checking that the current CI failures as I see they are related. Check the attached log file binary_linux_wheel_py3.6_cpu.log

torchvision/csrc/io/image/cpu/encode_jpeg.cpp Outdated Show resolved Hide resolved
@facebook-github-bot
Copy link

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Facebook open source project. Thanks!

@zzk1st zzk1st force-pushed the zzk1st/encode_jpeg_size_type branch from 4a45060 to ddadf4b Compare August 18, 2021 14:36
@zzk1st zzk1st force-pushed the zzk1st/encode_jpeg_size_type branch from ddadf4b to 1605654 Compare August 18, 2021 15:10
Copy link
Contributor

@datumbox datumbox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, good job @zzk1st.

Let's do a quick check and add back the pinning to confirm that your solution works both with 9b and 9d versions.

Also before merging, we will check FBcode. We'll catch up for that internally.

@datumbox
Copy link
Contributor

@zzk1st Looks like the patch works also with 9b. :)

Remove the pinning again and let's test this on FBcode.

@datumbox datumbox merged commit 16caba5 into pytorch:master Aug 19, 2021
@datumbox
Copy link
Contributor

Thanks for the contribution @zzk1st!

facebook-github-bot pushed a commit that referenced this pull request Aug 26, 2021
…type Wind… (#4288)

Summary:
* Unpinned the libjpeg version and fixed jpeg_mem_dest's size type Windows BC issue

* Temporarily get back pinned jpeg lib in order to run tests on CircleCI

* Revert "Temporarily get back pinned jpeg lib in order to run tests on CircleCI"

This reverts commit ab18a35.

* Used using instead of typedef and Fixed comment typo

Reviewed By: fmassa

Differential Revision: D30525893

fbshipit-source-id: bae9830e2d2212b9575a9ba6b4cc8313ba91e395

Co-authored-by: Zhongkai Zhu <zhongkai@fb.com>
Co-authored-by: Vasilis Vryniotis <datumbox@users.noreply.github.com>
@cprobert-insitro
Copy link

Hi @datumbox @zzk1st - Since this commit relaxes dependency constraints on the conda packages, I wanted to ask if there any chance you'd consider re-building/releasing the conda packages for 0.10.0 with this cherry-picked in? Or, could you provide any guidance on when 0.10.1 will be released (and if it will include this commit?). I am blocked on using 0.10.0 until this lands because of other packages depending on jpeg=9d.

@datumbox
Copy link
Contributor

datumbox commented Sep 1, 2021

Thanks @cprobert-insitro

The releases are coordinated along with PyTorch core, so it's something we can look into. I think if a revision is within the plans to be released (TBD) we can cherrypick this PR and fix the jpeg version issues.

Edit: We cherrypicked it here #4344 it should land in 0.10.1 but we don't have dates yet.

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

Successfully merging this pull request may close these issues.

RuntimeError: No such operator image::read_file on Docker
5 participants