| 131 | } // namespace |
| 132 | |
| 133 | void ExportOpStack(py::module &m) |
| 134 | { |
| 135 | using namespace pybind11::literals; |
| 136 | |
| 137 | m.def("stack", &Stack, "src"_a, py::kw_only(), "stream"_a = nullptr, R"pbdoc( |
| 138 | |
| 139 | Executes the Stack operation on the given cuda stream. This takes input tensors and combines them into a N(HWC/CHW) tensor. |
| 140 | |
| 141 | See also: |
| 142 | Refer to the CV-CUDA C API reference for the Stack operator |
| 143 | for more details and usage examples. |
| 144 | |
| 145 | Args: |
| 146 | src (List[cvcuda.Tensor]): Input tensors containing one or more samples each images all tensors must be N(HWC/CHW) or HWC/CHW and have the same data type and shape. |
| 147 | stream (cvcuda.Stream, optional): CUDA Stream on which to perform the operation. |
| 148 | |
| 149 | Returns: |
| 150 | cvcuda.Tensor: The output tensor containing the stacked input tensors. |
| 151 | |
| 152 | Caution: |
| 153 | Restrictions to several arguments may apply. Check the C |
| 154 | API references of the CV-CUDA operator. |
| 155 | )pbdoc"); |
| 156 | |
| 157 | m.def("stack_into", &StackInto, "dst"_a, "src"_a, py::kw_only(), "stream"_a = nullptr, R"pbdoc( |
| 158 | |
| 159 | Executes the Stack operation on the given cuda stream. This takes input tensors and combines them into a N(HWC/CHW) tensor. |
| 160 | |
| 161 | See also: |
| 162 | Refer to the CV-CUDA C API reference for the Stack operator |
| 163 | for more details and usage examples. |
| 164 | |
| 165 | Args: |
| 166 | dst (cvcuda.Tensor): Output N(CHW/HWC) tensor to store the result of the operation. |
| 167 | src (List[cvcuda.Tensor]): Input tensors containing one or more samples each images all tensors must be N(HWC/CHW) or HWC/CHW and have the same data type and shape. |
| 168 | stream (cvcuda.Stream, optional): CUDA Stream on which to perform the operation. |
| 169 | |
| 170 | Returns: |
| 171 | None |
| 172 | |
| 173 | Caution: |
| 174 | Restrictions to several arguments may apply. Check the C |
| 175 | API references of the CV-CUDA operator. |
| 176 | )pbdoc"); |
| 177 | } |
| 178 | |
| 179 | } // namespace cvcudapy |