CopyMakeBorder
- cvcuda.copymakeborder(src: nvcv.Tensor, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None) nvcv.Tensor
Executes the Copy Make Border operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border operator for more details and usage examples.
- Parameters
src (nvcv.Tensor) – Input tensor containing one or more images.
border_mode (cvcuda.Border, optional) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (int) – The top pixel position.
left (int) – The left pixel position.
bottom (int) – The bottom pixel position.
right (int) – The right pixel position.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
The output tensor.
- Return type
nvcv.Tensor
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.
cvcuda.copymakeborder(src: nvcv.ImageBatchVarShape, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None) -> nvcv.ImageBatchVarShape
Executes the Copy Make Border operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border operator for more details and usage examples.
- Parameters
src (nvcv.ImageBatchVarShape) – Input image batch containing one or more images.
border_mode (cvcuda.Border, optional) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (nvcv.Tensor) – The top pixel position for each image.
left (nvcv.Tensor) – The left pixel position for each image.
out_heights (nvcv.Tensor) – The heights of each output image.
out_widths (nvcv.Tensor) – The widths of each output image.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
The output image batch.
- Return type
nvcv.ImageBatchVarShape
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.
- cvcuda.copymakeborder_into(dst: nvcv.Tensor, src: nvcv.Tensor, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None)
Executes the Copy Make Border operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border operator for more details and usage examples.
- Parameters
dst (nvcv.Tensor) – Output tensor to store the result of the operation.
src (nvcv.Tensor) – Input tensor containing one or more images.
border_mode (cvcuda.Border) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (int) – The top pixel position.
left (int) – The left pixel position.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
None
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.
cvcuda.copymakeborder_into(dst: nvcv.ImageBatchVarShape, src: nvcv.ImageBatchVarShape, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None)
Executes the Copy Make Border operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border operator for more details and usage examples.
- Parameters
dst (nvcv.ImageBatchVarShape) – Output image batch containing the result of the operation.
src (nvcv.ImageBatchVarShape) – Input image batch containing one or more images.
border_mode (cvcuda.Border, optional) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (nvcv.Tensor) – The top pixel position for each image.
left (nvcv.Tensor) – The left pixel position for each image.
out_heights (nvcv.Tensor) – The heights of each output image.
out_widths (nvcv.Tensor) – The widths of each output image.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
None
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.
- cvcuda.copymakeborderstack(src: nvcv.ImageBatchVarShape, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None) nvcv.Tensor
Executes the Copy Make Border Stack operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border Stack operator for more details and usage examples.
- Parameters
src (nvcv.ImageBatchVarShape) – Input image batch containing one or more images.
border_mode (cvcuda.Border, optional) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (nvcv.Tensor) – The top pixel position for each image.
left (nvcv.Tensor) – The left pixel position for each image.
out_height (int) – The height of the output.
out_width (int) – The width of the output.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
The output images.
- Return type
nvcv.Tensor
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.
- cvcuda.copymakeborderstack_into(dst: nvcv.Tensor, src: nvcv.ImageBatchVarShape, border_mode: cvcuda.Border = cvcuda.Border.CONSTANT, border_value: List[float], top: int, bottom: int, right: int, stream: Optional[nvcv.cuda.Stream] = None)
Executes the Copy Make Border Stack operation on the given cuda stream.
See also
Refer to the CV-CUDA C API reference for the Copy Make Border Stack operator for more details and usage examples.
- Parameters
dst (nvcv.Tensor) – Output tensor to store the result of the operation.
src (nvcv.ImageBatchVarShape) – Input image batch containing one or more images.
border_mode (cvcuda.Border, optional) – Border mode to be used when accessing elements outside input image.
border_value (List[float], optional) – Border value to be used for constant border mode, each element of the array corresponds to the image color channel must be a size <= 4 and dim of 1, where the values specify the border color for each color channel.
top (nvcv.Tensor) – The top pixel position for each image.
left (nvcv.Tensor) – The left pixel position for each image.
out_height (int) – The height of the output.
out_width (int) – The width of the output.
stream (nvcv.cuda.Stream, optional) – CUDA Stream on which to perform the operation.
- Returns
None
Caution
Restrictions to several arguments may apply. Check the C API references of the CV-CUDA operator.