Skip to content

refactor(diffusion): replace crop_shape with resize_shape and crop_ratio#2685

Open
starlitxiling wants to merge 1 commit intohuggingface:mainfrom
starlitxiling:feat/resize-before-crop
Open

refactor(diffusion): replace crop_shape with resize_shape and crop_ratio#2685
starlitxiling wants to merge 1 commit intohuggingface:mainfrom
starlitxiling:feat/resize-before-crop

Conversation

@starlitxiling
Copy link

Summary / Motivation

When I used a larger resolution image with the diffusion policy, I found that the effect was not good. Later, I discovered that the diffusion policy strategy does not resize the image before cropping it, which causes problems when dealing with many images of different resolutions.

What changed

The image processing in the diffusion policy has been modified to resize the image before cropping it.

Checklist (required before merge)

  • Linting/formatting run (pre-commit run -a)
  • All tests pass locally (pytest)
  • Documentation updated
  • CI is green

@github-actions github-actions bot added the policies Items related to robot policies label Dec 19, 2025
Copy link

@stefanwagnerdev stefanwagnerdev left a comment

Choose a reason for hiding this comment

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

I also assumed that resizing happens automatically.
PR looks good to me

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

Labels

policies Items related to robot policies

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments