MCPcopy Create free account
hub / github.com/CVCUDA/CV-CUDA / ExportOpCenterCrop

Function ExportOpCenterCrop

python/mod_cvcuda/operators/OpCenterCrop.cpp:84–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

82} // namespace
83
84void ExportOpCenterCrop(py::module &m)
85{
86 using namespace pybind11::literals;
87
88 m.def("center_crop", &CenterCrop, "src"_a, "crop_size"_a, py::kw_only(), "stream"_a = nullptr, R"pbdoc(
89
90 Executes the Center Crop operation on the given cuda stream.
91
92 See also:
93 Refer to the CV-CUDA C API reference for the Center Crop operator
94 for more details and usage examples.
95
96 Args:
97 src (cvcuda.Tensor): Input tensor containing one or more images.
98 crop_size (Tuple[int, int]): Crop size in width and height.
99 stream (cvcuda.Stream, optional): CUDA Stream on which to perform the operation.
100
101 Returns:
102 cvcuda.Tensor: The output tensor.
103
104 Caution:
105 Restrictions to several arguments may apply. Check the C
106 API references of the CV-CUDA operator.
107 )pbdoc");
108
109 m.def("center_crop_into", &CenterCropInto, "dst"_a, "src"_a, "crop_size"_a, py::kw_only(), "stream"_a = nullptr,
110 R"pbdoc(
111
112 Executes the Center Crop operation on the given cuda stream.
113
114 See also:
115 Refer to the CV-CUDA C API reference for the Center Crop operator
116 for more details and usage examples.
117
118 Args:
119 dst (cvcuda.Tensor): Output tensor to store the result of the operation.
120 src (cvcuda.Tensor): Input tensor containing one or more images.
121 crop_size (Tuple[int, int]): Crop size in width and height.
122 stream (cvcuda.Stream, optional): CUDA Stream on which to perform the operation.
123
124 Returns:
125 None
126
127 Caution:
128 Restrictions to several arguments may apply. Check the C
129 API references of the CV-CUDA operator.
130 )pbdoc");
131}
132
133} // namespace cvcudapy

Callers 1

PYBIND11_MODULEFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected