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

Compatible with Windows for LibTorch deployment #303

Merged
merged 3 commits into from
Feb 8, 2022

Conversation

shining-love
Copy link
Contributor

@shining-love shining-love commented Feb 8, 2022

  • Compatible with Windows environment
  • Use LibTorchVision to read images in the LibTorch demo

We've met some issues about decode_image in LibTorchVision

libc++abi: terminating with uncaught exception of type c10::Error: decode_jpeg: torchvision not compiled with libjpeg support
Exception raised from decode_jpeg at /tmp/torchvision-20220127-98534-apsyj/vision-0.11.3/torchvision/csrc/io/image/cpu/decode_jpeg.cpp:10 (most recent call first):
frame #0: c10::detail::torchCheckFail(char const*, char const*, unsigned int, char const*) + 92 (0x10452b0d8 in libc10.dylib)
frame #1: vision::image::decode_png(at::Tensor const&, long long) + 0 (0x1046be46c in libtorchvision.dylib)
frame #2: ReadImage(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&) + 72 (0x10425a574 in yolort_torch)
frame #3: main + 2516 (0x10425b164 in yolort_torch)
frame #4: start + 520 (0x1042fd0f4 in dyld)

[1]    77736 abort      ./yolort_torch --checkpoint ../../../notebooks/yolov5n6.torchscript.pt

@CLAassistant
Copy link

CLAassistant commented Feb 8, 2022

CLA assistant check
All committers have signed the CLA.

@zhiqwang zhiqwang changed the title try_torchvision Use LibTorchVision to read images Feb 8, 2022
@codecov
Copy link

codecov bot commented Feb 8, 2022

Codecov Report

Merging #303 (4efda6c) into main (1fea1a6) will not change coverage.
The diff coverage is n/a.

❗ Current head 4efda6c differs from pull request most recent head 93b6114. Consider uploading reports for the commit 93b6114 to get more accurate results

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #303   +/-   ##
=======================================
  Coverage   94.93%   94.93%           
=======================================
  Files          11       11           
  Lines         731      731           
=======================================
  Hits          694      694           
  Misses         37       37           
Flag Coverage Δ
unittests 94.93% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1fea1a6...93b6114. Read the comment docs.

@zhiqwang zhiqwang added the enhancement New feature or request label Feb 8, 2022
@zhiqwang zhiqwang changed the title Use LibTorchVision to read images Compatible with Windows for LibTorch deployment Feb 8, 2022
Copy link
Owner

@zhiqwang zhiqwang left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks @yang-gis for your contributions to yolort.

@zhiqwang zhiqwang added bug / fix Something isn't working and removed enhancement New feature or request labels Feb 8, 2022
@zhiqwang zhiqwang merged commit fa06b7e into zhiqwang:main Feb 8, 2022
@zhiqwang zhiqwang added the deployment Inference acceleration for production label Feb 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug / fix Something isn't working deployment Inference acceleration for production
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants