Skip to content

Commit

Permalink
Add supported layout info to Crop, CropMirrorNormalize and Flip
Browse files Browse the repository at this point in the history
Signed-off-by: Joaquin Anton <janton@nvidia.com>
  • Loading branch information
jantonguirao committed Mar 7, 2022
1 parent d2c62c5 commit fdc5c39
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
6 changes: 4 additions & 2 deletions dali/operators/generic/flip.cc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2019-2021, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// Copyright (c) 2019-2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -30,7 +30,9 @@ and depthwise).)code")
.AddOptionalArg("horizontal", R"code(Flip the horizontal dimension.)code", 1, true)
.AddOptionalArg("vertical", R"code(Flip the vertical dimension.)code", 0, true)
.AddOptionalArg("depthwise", R"code(Flip the depthwise dimension.)code", 0, true)
.InputLayout({"FDHWC", "FHWC", "DHWC", "HWC", "FCDHW", "FCHW", "CDHW", "CHW"})
.InputLayout(0, {"HWC", "CHW", "DHWC",
"FHWC", "FCHW", "CDHW", "CFHW",
"FDHWC", "FCDHW", "CFDHW"})
.AllowSequences()
.SupportVolumetric();

Expand Down
5 changes: 4 additions & 1 deletion dali/operators/image/crop/crop.cc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright (c) 2019, NVIDIA CORPORATION. All rights reserved.
// Copyright (c) 2019-2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -27,6 +27,9 @@ DALI_SCHEMA(Crop)
(upper left corner).)code")
.NumInput(1)
.NumOutput(1)
.InputLayout(0, {"HWC", "CHW", "DHWC",
"FHWC", "FCHW", "CDHW", "CFHW",
"FDHWC", "FCDHW", "CFDHW"})
.AllowSequences()
.SupportVolumetric()
.AddOptionalArg<DALIImageType>("image_type", "Image type", nullptr)
Expand Down
3 changes: 3 additions & 0 deletions dali/operators/image/crop/crop_mirror_normalize.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ Normalization takes the input images and produces the output by using the follow
)code")
.NumInput(1)
.NumOutput(1)
.InputLayout(0, {"HWC", "CHW", "DHWC",
"FHWC", "FCHW", "CDHW", "CFHW",
"FDHWC", "FCDHW", "CFDHW"})
.AllowSequences()
.SupportVolumetric()
.AddOptionalArg<DALIImageType>("image_type", "Image type", nullptr)
Expand Down

0 comments on commit fdc5c39

Please sign in to comment.