Skip to content

Commit

Permalink
Set symmetric_padding for bypass model sample
Browse files Browse the repository at this point in the history
  • Loading branch information
placccebo committed Aug 7, 2024
1 parent b819af8 commit 8059893
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion samples/bypass_model/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ A result video can be viewed:
- in a player using `rtsp://127.0.0.1:554/stream/video-with-preprocessed-frame

The video consists of original video stream and the pre-processed video stream side by side from left to right. The white background highlights the original video frame because its size is different from the size of the pre-processed frame.
The pre-processed frame has a black background at the bottom, which is the result of the `maintain_aspect_ratio` flag.
The pre-processed frame has a black background to match the aspect ratio of the original frame, i.e. `maintain_aspect_ratio` flag is set to `true`. The frame is centered on the background, as the `symmetric_padding` flag is set to `true`.

Example output frame:
![](assets/result.jpg)
Expand Down
4 changes: 2 additions & 2 deletions samples/bypass_model/assets/result.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions samples/bypass_model/demo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ pipeline:
shape: ${parameters.result_shape}
# preprocessing settings
maintain_aspect_ratio: true
symmetric_padding: true

# configuration of model output
output:
Expand Down

0 comments on commit 8059893

Please sign in to comment.