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

Fix processing cost calculator: the order of filter support #5009

Merged
merged 1 commit into from
Aug 21, 2023

Conversation

stiepan
Copy link
Member

@stiepan stiepan commented Aug 21, 2023

Category:

Bug fix (non-breaking change which fixes an issue)

Description:

In the setup, the resize operator estimates the cost of running the resize with different orders of the resampled axes. It uses output, input sizes and the size of filters used along particular axes. However, it seems that the filters support size is unnecesarily reversed when passed to the best order calculator, which may result in sub-optimal performance in some cases.

Additional information:

Affected modules and functionalities:

The performance of the dali resize operator, esp. for downsampling with antialias on and filters with big radious.

Key points relevant for the review:

While the shapes and arguments come in a (D)HW (limited to spatial dims) layout, the SampleDesc keeps the extents in the WH(D) order. The filters are setup in the SetFilters method called a few lines above the fix. They are kept in the SampleDesc in the WH(D) order, same as the computed input (roi) and output shapes here.

Tests:

  • Existing tests apply
  • New tests added
    • Python tests
    • GTests
    • Benchmark
    • Other
  • N/A

Checklist

Documentation

  • Existing documentation applies
  • Documentation updated
    • Docstring
    • Doxygen
    • RST
    • Jupyter
    • Other
  • N/A

DALI team only

Requirements

  • Implements new requirements
  • Affects existing requirements
  • N/A

REQ IDs: N/A

JIRA TASK: N/A

Signed-off-by: Kamil Tokarski <ktokarski@nvidia.com>
@stiepan stiepan marked this pull request as ready for review August 21, 2023 10:00
@stiepan
Copy link
Member Author

stiepan commented Aug 21, 2023

!build

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [9450865]: BUILD STARTED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [9450865]: BUILD FAILED

@dali-automaton
Copy link
Collaborator

CI MESSAGE: [9450865]: BUILD PASSED

@stiepan stiepan merged commit 2b1d801 into NVIDIA:main Aug 21, 2023
5 checks passed
JanuszL pushed a commit to JanuszL/DALI that referenced this pull request Oct 13, 2023
Fixes the order of the per-axis filter support sizes passed to the cost calculator.

Signed-off-by: Kamil Tokarski <ktokarski@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants