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

Function ResizeVarShapeInto

python/mod_cvcuda/operators/OpResize.cpp:58–76  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

56}
57
58ImageBatchVarShape ResizeVarShapeInto(ImageBatchVarShape &output, ImageBatchVarShape &input,
59 NVCVInterpolationType interp, std::optional<Stream> pstream)
60{
61 if (!pstream)
62 {
63 pstream = Stream::Current();
64 }
65
66 auto resize = CreateOperator<cvcuda::Resize>();
67
68 ResourceGuard guard(*pstream);
69 guard.add(LockMode::LOCK_MODE_READ, {input});
70 guard.add(LockMode::LOCK_MODE_WRITE, {output});
71 guard.add(LockMode::LOCK_MODE_NONE, {*resize});
72
73 resize->submit(pstream->cudaHandle(), input, output, interp);
74
75 return output;
76}
77
78ImageBatchVarShape ResizeVarShape(ImageBatchVarShape &input, const std::vector<std::tuple<int, int>> &out_size,
79 NVCVInterpolationType interp, std::optional<Stream> pstream)

Callers 1

ResizeVarShapeFunction · 0.85

Calls 3

cudaHandleMethod · 0.80
addMethod · 0.45
submitMethod · 0.45

Tested by

no test coverage detected