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

Function HistogramEqInto

python/mod_cvcuda/operators/OpHistogramEq.cpp:30–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28
29namespace {
30Tensor HistogramEqInto(Tensor &output, Tensor &input, std::optional<Stream> pstream)
31{
32 if (!pstream)
33 {
34 pstream = Stream::Current();
35 }
36 nvcv::TensorShape shape = input.shape();
37 auto op = CreateOperator<cvcuda::HistogramEq>((uint32_t)shape[0]);
38
39 ResourceGuard guard(*pstream);
40 guard.add(LockMode::LOCK_MODE_READ, {input});
41 guard.add(LockMode::LOCK_MODE_WRITE, {output});
42 guard.add(LockMode::LOCK_MODE_READWRITE, {*op});
43
44 op->submit(pstream->cudaHandle(), input, output);
45
46 return std::move(output);
47}
48
49Tensor HistogramEq(Tensor &input, nvcv::DataType dtype, std::optional<Stream> pstream)
50{

Callers 1

HistogramEqFunction · 0.85

Calls 4

cudaHandleMethod · 0.80
shapeMethod · 0.45
addMethod · 0.45
submitMethod · 0.45

Tested by

no test coverage detected