nareshmlx/opencv-pr huggingface dataset:
**File:** modules/dnn/src/tensorflow/tf_importer.cpp
**Change Type:** modified
**Context:** PR #22249: Changing data_layout for pack in tf_importer
**Review Line:** 2544

**Code Changes:**
```diff
@@ -2541,6 +2541,8 @@ void TFImporter::parsePack(tensorflow::GraphDef& net, const tensorflow::NodeDef&
     if (dim != 0)
         CV_Error(Error::StsNotImplemented, "Unsupported mode of pack operation.");
 
+    data_layouts[name] = DATA_LAYOUT_UNKNOWN;
+
     CV_Assert(hasLayerAttr(layer, "N"));
     int num = (int)getLayerAttr(layer, "N").i();
     CV_CheckEQ(num_inputs, num, "");
```

Review comment:
A complete test example would be helpful. From [stack API](https://www.tensorflow.org/api_docs/python/tf/stack), we can find that the axis is `[-(R+1), R+1)`. The following code generates all possible cases of `tf.stack`. ``` for d in range(1, 7): for axis in range(-d - 1, d + 1): inp0 = tf.placeholder(tf.float32, list(range(1, d + 1)), 'input0') constant = tf.random_normal(list(range(1, d + 1))) pack_model = tf.stack([inp0, constant]) print(pack_model) # save(inp0, pack_model, f'pack_dim{d}_{axis}', optimize=False) ``` Maybe in `tf.stack`case, we should use two placeholders as model input. I'm not sure the `save` function in [generate_tf_models.py](https://github.com/opencv/opencv_extra/blob/4.x/testdata/dnn/tensorflow/generate_tf_models.py) can do this.
**File:** modules/dnn/src/tensorflow/tf_importer.cpp
**Change Type:** modified
**Context:** PR #22249: Changing data_layout for pack in tf_importer
**Review Line:** 2544

**Code Changes:**
```diff
@@ -2541,6 +2541,8 @@ void TFImporter::parsePack(tensorflow::GraphDef& net, const tensorflow::NodeDef&
     if (dim != 0)
         CV_Error(Error::StsNotImplemented, "Unsupported mode of pack operation.");
 
+    data_layouts[name] = DATA_LAYOUT_UNKNOWN;
+
     CV_Assert(hasLayerAttr(layer, "N"));
     int num = (int)getLayerAttr(layer, "N").i();
     CV_CheckEQ(num_inputs, num, "");
```

Review comment:
Testing a single `Pack` operator does not make any sense in this pull request. This pull request is changing the output data layout, and with or without this change, such tests will always pass.
**File:** modules/dnn/src/layers/fast_convolution/winograd_3x3s1_f63.cpp
**Change Type:** modified
**Context:** PR #22183: DNN: ARMv7 compatible fastConv
**Review Line:** 1095

**Code Changes:**
```diff
                         // init 16 registers. FMA/load ratio = 32/12
-                        float32x4_t r00 = vdupq_n_f32(0.0f), r01 = r00, r02 = r00, r03 = r00;
-                        float32x4_t r04 = r00, r05 = r00, r06 = r00, r07 = r00;
-                        float32x4_t r08 = r00, r09 = r00, r10 = r00, r11 = r00;
-                        float32x4_t r12 = r00, r13 = r00, r14 = r00, r15 = r00;
+                        float32x2_t q00 = vdup_n_f32(0.0f), q01 = q00, q02 = q00, q03 = q00,
+                                    q04 = q00, q05 = q00, q06 = q00, q07 = q00;
+
+                        float32x4_t r04 = vdupq_n_f32(0.0f), r05 = r04, r06 = r04, r07 = r04;
+                        float32x4_t r08 = r04, r09 = r04, r10 = r04, r11 = r04;
+                        float32x4_t r12 = r04, r13 = r04, r14 = r04, r15 = r04;
```

Review comment:
could you please explain why you use halves of NEON registers on ARMv7? ARMv7 still has 128-bit NEON registers, I don't see why not use all of them
**File:** modules/dnn/include/opencv2/dnn/dnn.hpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -621,8 +621,10 @@ CV__DNN_INLINE_NS_BEGIN
          *  @param calibData Calibration data to compute the quantization parameters.
          *  @param inputsDtype Datatype of quantized net's inputs. Can be CV_32F or CV_8S.
          *  @param outputsDtype Datatype of quantized net's outputs. Can be CV_32F or CV_8S.
+         *  @param perChannel Quantization granularity of quantized Net. The default is true, that means quantize model
+         *  in per-channel way (channel-wise). Set it false to quantize model in per-tensor way (or tensor-wise).
          */
-        CV_WRAP Net quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype);
+        CV_WRAP Net quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype, bool perChannel=true);
 
```

Review comment:
I think it was removed by accident.
**File:** modules/dnn/src/layers/fully_connected_layer.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -619,26 +619,36 @@ class FullyConnectedLayerImpl CV_FINAL : public InnerProductLayer
         Mat weightsQuantized(weightsMat.rows, weightsMat.cols, CV_8S);
         Mat biasQuantized(1, numOutput, CV_32S);
         Mat outputMultiplier(1, numOutput, CV_32F);
+        bool perChannel = params.get<bool>("per_channel", true);
 
-        double realMin, realMax, weightsScale;
-        for( int i = 0; i < numOutput; i++ )
+        if (perChannel) // per-Channel quantization.
         {
```

Review comment:
```cpp bool perTensor = params.get<bool>("perTensor", false); ```
**File:** modules/dnn/src/layers/convolution_layer.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -2174,26 +2174,36 @@ class ConvolutionLayerImpl CV_FINAL : public BaseConvolutionLayerImpl
         Mat weightsQuantized(weightsMat.rows, weightsMat.cols, CV_8S);
         Mat biasQuantized(1, numOutput, CV_32S);
         Mat outputMultiplier(1, numOutput, CV_32F);
-        double realMin, realMax, weightsScale;
+        bool perChannel = params.get<bool>("per_channel", true);
 
-        for( int i = 0; i < numOutput; i++ )
+        if (perChannel) // per-Channel quantization.
         {
```

Review comment:
It seems that we can avoid duplicating code. Consider, for example, a function, that is taking weightsMat and weightsQuantized and returns biasScale. And some other function, that calclulates biasQuantized and outputMultiplier at ith position. Then this would translate to something like: ```cpp // per Tensor float biasScale = calcBiasScale(weightsMat, weightsQuantized); for (int i = 0; i < numOutputt; ++i) { calcBiasAndOutputMultiplier(biasScale, i, weightsQuantized); } // per Channel for (int i = 0; i < numOutputt; ++i) { float biasScale = calcBiasScale(weightsMat.row(i), weightsQuantized.row(i)); calcBiasAndOutputMultiplier(biasScale, i, weightsQuantized); } ``` calcBiasAndOutputMultiplier could also probably be rewritten to act on marices, but I'm not sure what performance implications of that would be. Also, if designed carefully, this could be reused in other layers as well, e.g. the same story in fully connected layer.
**File:** modules/dnn/src/layers/convolution_layer.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -2174,26 +2174,36 @@ class ConvolutionLayerImpl CV_FINAL : public BaseConvolutionLayerImpl
         Mat weightsQuantized(weightsMat.rows, weightsMat.cols, CV_8S);
         Mat biasQuantized(1, numOutput, CV_32S);
         Mat outputMultiplier(1, numOutput, CV_32F);
-        double realMin, realMax, weightsScale;
+        bool perChannel = params.get<bool>("per_channel", true);
 
-        for( int i = 0; i < numOutput; i++ )
+        if (perChannel) // per-Channel quantization.
         {
```

Review comment:
`cvRound`
**File:** modules/dnn/src/layers/fully_connected_layer.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -619,26 +619,36 @@ class FullyConnectedLayerImpl CV_FINAL : public InnerProductLayer
         Mat weightsQuantized(weightsMat.rows, weightsMat.cols, CV_8S);
         Mat biasQuantized(1, numOutput, CV_32S);
         Mat outputMultiplier(1, numOutput, CV_32F);
+        bool perChannel = params.get<bool>("per_channel", true);
 
-        double realMin, realMax, weightsScale;
-        for( int i = 0; i < numOutput; i++ )
+        if (perChannel) // per-Channel quantization.
         {
```

Review comment:
`cvRound`
**File:** modules/dnn/src/net_quantization.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -33,7 +33,7 @@ void getQuantizationParams(const Mat& src, std::vector<float>& scales, std::vect
 }
 
 // FIXIT drop from inference API
-Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype)
+Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype, bool perChannel)
 {
     // Net can be quantized only once.
     if (netWasQuantized)
@@ -192,6 +192,10 @@ Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outpu
```

Review comment:
Do we need this method? (in internal class)
**File:** modules/dnn/test/test_int8_layers.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -29,7 +29,7 @@ class Test_Int8_layers : public DNNTestLayer
 public:
     void testLayer(const String& basename, const String& importer, double l1, double lInf,
                    int numInps = 1, int numOuts = 1, bool useCaffeModel = false,
-                   bool useCommonInputBlob = true, bool hasText = false)
+                   bool useCommonInputBlob = true, bool hasText = false, bool perChannel = true)
     {
         CV_Assert_N(numInps >= 1, numInps <= 10, numOuts >= 1, numOuts <= 10);
         std::vector<Mat> inps(numInps), inps_int8(numInps);
@@ -75,7 +75,7 @@ class Test_Int8_layers : public DNNTestLayer
```

Review comment:
BTW, It makes sense to create dedicated test or at least use `SCOPED_TRACE();`. (here and above)
**File:** modules/dnn/test/test_int8_layers.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -29,7 +29,7 @@ class Test_Int8_layers : public DNNTestLayer
 public:
     void testLayer(const String& basename, const String& importer, double l1, double lInf,
                    int numInps = 1, int numOuts = 1, bool useCaffeModel = false,
-                   bool useCommonInputBlob = true, bool hasText = false)
+                   bool useCommonInputBlob = true, bool hasText = false, bool perChannel = true)
     {
         CV_Assert_N(numInps >= 1, numInps <= 10, numOuts >= 1, numOuts <= 10);
         std::vector<Mat> inps(numInps), inps_int8(numInps);
@@ -75,7 +75,7 @@ class Test_Int8_layers : public DNNTestLayer
```

Review comment:
Ok, I will try to update it.
**File:** modules/dnn/src/net_quantization.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -33,7 +33,7 @@ void getQuantizationParams(const Mat& src, std::vector<float>& scales, std::vect
 }
 
 // FIXIT drop from inference API
-Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype)
+Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype, bool perChannel)
 {
     // Net can be quantized only once.
     if (netWasQuantized)
@@ -192,6 +192,10 @@ Net Net::Impl::quantize(InputArrayOfArrays calibData, int inputsDtype, int outpu
```

Review comment:
We could remove this if it is not used anymore.
**File:** modules/dnn/test/test_int8_layers.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -29,7 +29,7 @@ class Test_Int8_layers : public DNNTestLayer
 public:
     void testLayer(const String& basename, const String& importer, double l1, double lInf,
                    int numInps = 1, int numOuts = 1, bool useCaffeModel = false,
-                   bool useCommonInputBlob = true, bool hasText = false)
+                   bool useCommonInputBlob = true, bool hasText = false, bool perChannel = true)
     {
         CV_Assert_N(numInps >= 1, numInps <= 10, numOuts >= 1, numOuts <= 10);
         std::vector<Mat> inps(numInps), inps_int8(numInps);
@@ -75,7 +75,7 @@ class Test_Int8_layers : public DNNTestLayer
```

Review comment:
Hi, the `SCOPED_TRACE()` has been used in every test case of `per-tensor quantization`.
**File:** modules/dnn/src/net.cpp
**Change Type:** modified
**Context:** PR #21372: Add per_tensor_quantize to int8 quantize

**Code Changes:**
```diff
@@ -115,12 +115,12 @@ void Net::forward(std::vector<std::vector<Mat>>& outputBlobs,
 }
 
 // FIXIT drop from inference API
-Net Net::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype)
+Net Net::quantize(InputArrayOfArrays calibData, int inputsDtype, int outputsDtype, bool perChannel)
 {
     CV_TRACE_FUNCTION();
     CV_Assert(impl);
     CV_Assert(!empty());
```

Review comment:
> bool perTensor = false Default value works properly from .hpp files only. They are useless in .cpp files
**File:** apps/visualisation/opencv_visualisation.cpp
**Change Type:** modified
**Context:** PR #22065: apps/opencv_visualisation: configurable video codec

**Code Changes:**
```diff
@@ -86,6 +86,9 @@ int main( int argc, const char** argv )
         "{ image i        |      | (required) path to reference image }"
         "{ model m        |      | (required) path to cascade xml file }"
         "{ data d         |      | (optional) path to video output folder }"
+        "{ ext            | avi  | (optional) output video file extension e.g. avi (default) or mp4 }"
+        "{ fourcc         | XVID | (optional) output video file's 4-character codec e.g. XVID (default) or H264 }"
+        "{ fps            |   15 | (optional) output video file's frames-per-second rate }"
     );
     // Read in the input arguments
     if (parser.has("help")){
```

Review comment:
"incl. trailing path separator" - it's error prone solution. Double slash is usually handled by OS and works well. The path without slash leads to invalid location and app failure.
**File:** apps/visualisation/opencv_visualisation.cpp
**Change Type:** modified
**Context:** PR #22065: apps/opencv_visualisation: configurable video codec

**Code Changes:**
```diff
@@ -86,6 +86,9 @@ int main( int argc, const char** argv )
         "{ image i        |      | (required) path to reference image }"
         "{ model m        |      | (required) path to cascade xml file }"
         "{ data d         |      | (optional) path to video output folder }"
+        "{ ext            | avi  | (optional) output video file extension e.g. avi (default) or mp4 }"
+        "{ fourcc         | XVID | (optional) output video file's 4-character codec e.g. XVID (default) or H264 }"
+        "{ fps            |   15 | (optional) output video file's frames-per-second rate }"
     );
     // Read in the input arguments
     if (parser.has("help")){
```

Review comment:
> ... The path without slash leads to invalid location and app failure. Interesting. On my computer `--data=temp_data` instead of `--data=temp_data/` technically works i.e. files are created, not in the output folder but in the parent folder of the output folder. ``` temp_datamodel_visualization.mp4 temp_datastage_0.png temp_datastage_1.png ... ``` Continuing that thought: * if the parent folder was inaccessible due to permissions then the app would fail * as a user due to the "path to video output folder" wording I would consider "files in the parent folder" as a failure Either way though, changing the "data" usage message or the code logic w.r.t. missing trailing path separator is strictly speaking not in "configurable video codec" scope and so let me go and remove it accordingly then. ```suggestion "{ data d | | (optional) path to video output folder }" ```
**File:** apps/interactive-calibration/main.cpp
**Change Type:** modified
**Context:** PR #22079: Save Frames option for interactive calibration tool

**Code Changes:**
```diff
@@ -40,6 +40,7 @@ const std::string keys  =
         "{vis      | grid    | Captured boards visualisation (grid, window)}"
         "{d        | 0.8     | Min delay between captures}"
         "{pf       | defaultConfig.xml| Advanced application parameters}"
+        "{save_frames | false   | Save frames that contribute to final calibration}"
         "{help     |         | Print help}";
 
 bool calib::showOverlayMessage(const std::string& message)
```

Review comment:
BTW, `save` / `save_frames` looks more descriptive.
**File:** modules/calib3d/include/opencv2/calib3d.hpp
**Change Type:** modified
**Context:** PR #22045: Add fisheye camera model summary description with reference

**Code Changes:**
```diff
@@ -429,6 +429,9 @@ R & t \\
     \f[u = f_x (x' + \alpha y') + c_x \\
     v = f_y y' + c_y\f]
 
+    Summary:
+    Generic camera model @cite Kannala2006 with perspective projection and without distortion correction
+
     @defgroup calib3d_c C API
 
   @}
```

Review comment:
Please add it latex bib file and add reference here. See https://github.com/opencv/opencv/blob/4.x/doc/opencv.bib
**File:** modules/calib3d/test/test_undistort_points.cpp
**Change Type:** modified
**Context:** PR #21841: Add distort/undistort test for fisheye::undistortPoints()

**Code Changes:**
```diff
@@ -1,34 +1,24 @@
 // This file is part of OpenCV project.
 // It is subject to the license terms in the LICENSE file found in the top-level directory
 // of this distribution and at http://opencv.org/license.html.
+
+#include <opencv2/ts/cuda_test.hpp> // EXPECT_MAT_NEAR
 #include "test_precomp.hpp"
 
 namespace opencv_test { namespace {
 
```

Review comment:
You can use theRNG from base class.
**File:** modules/calib3d/perf/perf_undistort.cpp
**Change Type:** modified
**Context:** PR #21841: Add distort/undistort test for fisheye::undistortPoints()
**Review Line:** 32

**Code Changes:**
```diff
     SANITY_CHECK_NOTHING();
 }
 
+using PerfIntType = perf::TestBaseWithParam<std::tuple<int>>;
+PERF_TEST_P(PerfIntType, fisheye_undistortPoints,
+                                            (testing::Values(1e2, 1e3, 1e4)))
+{
+    const cv::Size imageSize(1280, 800);
+
+    /* Set camera matrix */
+    const cv::Matx33d K(558.478087865323,  0, 620.458515360843,
```

Review comment:
Test cases with parameters 100/1000 is unstable (result is not measurable - sample is too small against overhead, each dedicated run gives different result values) --- > PerfIntType It not a good part of the test name (non-descriptive). --- > `perf::TestBaseWithParam<std::tuple<int>>` Should be `perf::TestBaseWithParam<int>` --- Changed in #22028
**File:** modules/calib3d/perf/perf_undistort.cpp
**Change Type:** modified
**Context:** PR #21841: Add distort/undistort test for fisheye::undistortPoints()
**Review Line:** 32

**Code Changes:**
```diff
     SANITY_CHECK_NOTHING();
 }
 
+using PerfIntType = perf::TestBaseWithParam<std::tuple<int>>;
+PERF_TEST_P(PerfIntType, fisheye_undistortPoints,
+                                            (testing::Values(1e2, 1e3, 1e4)))
+{
+    const cv::Size imageSize(1280, 800);
+
+    /* Set camera matrix */
+    const cv::Matx33d K(558.478087865323,  0, 620.458515360843,
```

Review comment:
> It not a good part of the test name (non-descriptive). I was guided by this documentation https://github.com/opencv/opencv/wiki/HowToWritePerfTests > Test cases with parameters 100/1000 is unstable (result is not measurable - sample is too small against overhead, What is a minimal allowable process time? It was pretty stable on my machine. It was important to me to run with different amout of points to show how computation time depends on it.
**File:** modules/dnn/src/onnx/onnx_importer.cpp
**Change Type:** modified
**Context:** PR #21818: Add prefixes to layer names and layer output names
**Review Line:** 747

**Code Changes:**
```diff
-        return node_proto.name();
+        if (useLegacyNames)
+            return node_proto.name();
+        return cv::format("onnx_node!%s", node_proto.name().c_str());
     }
     for (int i = 0; i < node_proto.output_size(); ++i)
     {
@@ -735,7 +752,9 @@ const std::string& extractNodeName(const opencv_onnx::NodeProto& node_proto)
         // the second method is to use an empty string in place of an input or output name.
         if (!name.empty())
         {
```

Review comment:
Problem is still here. There are several "outputs" with different names. Why do we pick the first non-empty output name? IMHO, we should register all "outputs" instead.
**File:** .github/workflows/PR-3.4-ARM64.yaml
**Change Type:** added
**Context:** PR #21924: Workflow to build and test on ARM64 for 3.4 branch

**Code Changes:**
```diff
@@ -0,0 +1,189 @@
+name: PR:3.4 ARM64
+
+on:
+  pull_request:
+    branches:
+      - 3.4
+
+env:
+  EXTRA_CMAKE_OPTIONS: '-DBUILD_DOCS=ON -DPYTHON_DEFAULT_EXECUTABLE=/usr/bin/python3 -DBUILD_opencv_xfeatures2d=OFF -DBUILD_EXAMPLES=ON -DOPENCV_ENABLE_NONFREE=ON -DENABLE_CCACHE=OFF'
```

Review comment:
Let's rename `RET` to `OPENCV_EXTRA_FORK`?
**File:** .github/workflows/PR-3.4-ARM64.yaml
**Change Type:** added
**Context:** PR #21924: Workflow to build and test on ARM64 for 3.4 branch

**Code Changes:**
```diff
@@ -0,0 +1,189 @@
+name: PR:3.4 ARM64
+
+on:
+  pull_request:
+    branches:
+      - 3.4
+
+env:
+  EXTRA_CMAKE_OPTIONS: '-DBUILD_DOCS=ON -DPYTHON_DEFAULT_EXECUTABLE=/usr/bin/python3 -DBUILD_opencv_xfeatures2d=OFF -DBUILD_EXAMPLES=ON -DOPENCV_ENABLE_NONFREE=ON -DENABLE_CCACHE=OFF'
```

Review comment:
Yes, it is renamed to `OPENCV_EXTRA_FORK` in the lastest commit.
**File:** cmake/mirrors/gitcode.cmake
**Change Type:** modified
**Context:** PR #21811: Support mirrors for TIM-VX and others 3rdparty components in opencv_contrib

**Code Changes:**
```diff
@@ -1,14 +1,25 @@
-# Tengine (Download via commit id)
+######
+# Download via commit id
+######
+# Tengine
 ocv_update(TENGINE_PKG_MD5_GITCODE 1b5908632b557275cd6e85b0c03f9690)
 ocv_update(TENGINE_PKG_MD5_ORIGINAL 23f61ebb1dd419f1207d8876496289c5) # same as tengine_md5sum for TENGINE commit of e89cf8870de2ff0a80cfe626c0b52b2a16fb302e
+# NVIDIA_OPTICAL_FLOW
+ocv_update(NVIDIA_OPTICAL_FLOW_PKG_MD5_GITCODE 8d5b7eeb24d6ca9c6bcfdff4196d5b47)
```

Review comment:
Both Gitcode and Github branches works for me well. But I see issues with double slashes in Gitcode links like this: `https://gitcode.net/mirrors/WeChatCV/opencv_3rdparty/-/raw/a8b69ccc738421293254aec5ddb38bd523503252//detect.caffemodel`. It does not happen in default (github) configuration.
**File:** cmake/mirrors/gitcode.cmake
**Change Type:** modified
**Context:** PR #21811: Support mirrors for TIM-VX and others 3rdparty components in opencv_contrib

**Code Changes:**
```diff
@@ -1,14 +1,25 @@
-# Tengine (Download via commit id)
+######
+# Download via commit id
+######
+# Tengine
 ocv_update(TENGINE_PKG_MD5_GITCODE 1b5908632b557275cd6e85b0c03f9690)
 ocv_update(TENGINE_PKG_MD5_ORIGINAL 23f61ebb1dd419f1207d8876496289c5) # same as tengine_md5sum for TENGINE commit of e89cf8870de2ff0a80cfe626c0b52b2a16fb302e
+# NVIDIA_OPTICAL_FLOW
+ocv_update(NVIDIA_OPTICAL_FLOW_PKG_MD5_GITCODE 8d5b7eeb24d6ca9c6bcfdff4196d5b47)
```

Review comment:
I propose something like this to not duplicate URLs and logic: ``` set(DL_URL "https://gitcode.net/${OWNER}/opencv_3rdparty/-/raw/${__COMMIT_ID}/") if(__PKG_NAME) set(DL_URL "${DL_URL}${__PKG_NAME}/") endif() ```
**File:** modules/dnn/include/opencv2/dnn/all_layers.hpp
**Change Type:** modified
**Context:** PR #21036: dnn: TIM-VX NPU backend support

**Code Changes:**
```diff
@@ -262,7 +262,7 @@ CV__DNN_INLINE_NS_BEGIN
     {
     public:
         int input_zp, output_zp;
-        float output_sc;
+        float input_sc, output_sc;
         static Ptr<BaseConvolutionLayer> create(const LayerParams& params);
     };
 
@@ -322,6 +322,7 @@ CV__DNN_INLINE_NS_BEGIN
```

Review comment:
align order of input/output variables.