nareshmlx/opencv-pr huggingface dataset:
**File:** modules/dnn/src/layers/cpu_kernels/softmax.hpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,28 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
This is the exact same with `GemmOpt`, https://github.com/opencv/opencv/blob/617d7ff575200c0a647cc615b86003f10b64587b/modules/dnn/src/layers/cpu_kernels/fast_gemm.hpp#L20-L43 I think we should not make duplicates here. It's better to make a general one and use it everywhere.
**File:** modules/dnn/src/layers/softmax_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -52,6 +52,7 @@
 #include <algorithm>
 #include <stdlib.h>
 #include <opencv2/core/utils/logger.hpp>
+#include "cpu_kernels/softmax.hpp"
 using std::max;
 
 #ifdef HAVE_OPENCL
@@ -225,89 +226,15 @@ class SoftMaxLayerImpl CV_FINAL : public SoftmaxLayer
         std::vector<Mat> inputs, outputs, internals;
```

Review comment:
1. Is `axis` normalized somewhere? I could not find it. 2. I propose to put `opt.init()` in `finalize` to keep alignment with that in gemm.
**File:** modules/dnn/src/layers/cpu_kernels/softmax.hpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,28 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
Should this Opt belong to all layers or just for cpu kernel? Should I change it for `convolution.hpp`
**File:** modules/dnn/src/layers/softmax_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -52,6 +52,7 @@
 #include <algorithm>
 #include <stdlib.h>
 #include <opencv2/core/utils/logger.hpp>
+#include "cpu_kernels/softmax.hpp"
 using std::max;
 
 #ifdef HAVE_OPENCL
@@ -225,89 +226,15 @@ class SoftMaxLayerImpl CV_FINAL : public SoftmaxLayer
         std::vector<Mat> inputs, outputs, internals;
```

Review comment:
1. the `axis` normalized in the `softmax` kernel. Also in `forward` function. 2. 👌
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -707,4 +707,55 @@ INSTANTIATE_TEST_CASE_P(/**/, Layer_FullyConnected, Combine(
     dnnBackendsAndTargets()
 ));
 
+typedef TestBaseWithParam<tuple<std::vector<int>, int, tuple<Backend, Target> > > Layer_Softmax;
+PERF_TEST_P_(Layer_Softmax, softmax_3d) {
+    std::vector<int> shape = get<0>(GetParam());
+    int axis = get<1>(GetParam());
+    int backendId = get<0>(get<2>(GetParam()));
+    int targetId = get<1>(get<2>(GetParam()));
```

Review comment:
`net.connect` is not needed in case of `net.addLayerToPrev`
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -707,4 +707,55 @@ INSTANTIATE_TEST_CASE_P(/**/, Layer_FullyConnected, Combine(
     dnnBackendsAndTargets()
 ));
 
+typedef TestBaseWithParam<tuple<std::vector<int>, int, tuple<Backend, Target> > > Layer_Softmax;
+PERF_TEST_P_(Layer_Softmax, softmax_3d) {
+    std::vector<int> shape = get<0>(GetParam());
+    int axis = get<1>(GetParam());
+    int backendId = get<0>(get<2>(GetParam()));
+    int targetId = get<1>(get<2>(GetParam()));
```

Review comment:
Maybe just `net.setInput(data)` without `setInputsNames`? There is only one input in the model
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...
**Review Line:** 742

**Code Changes:**
```diff
+    TEST_CYCLE() {
+        Mat res = net.forward();
+    }
+
+    SANITY_CHECK_NOTHING();
+}
+
+INSTANTIATE_TEST_CASE_P(/**/, Layer_Softmax, Combine(
+    Values(                // input size
+            std::vector<int>({16, 50, 50}),
+            std::vector<int>({16, 197, 197}),
```

Review comment:
Make sense to add a parameter for different axes to `INSTANTIATE_TEST_CASE_P`
**File:** modules/dnn/src/layers/softmax_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -52,6 +52,7 @@
 #include <algorithm>
 #include <stdlib.h>
 #include <opencv2/core/utils/logger.hpp>
+#include "cpu_kernels/softmax.hpp"
 using std::max;
 
 #ifdef HAVE_OPENCL
@@ -225,89 +226,15 @@ class SoftMaxLayerImpl CV_FINAL : public SoftmaxLayer
         std::vector<Mat> inputs, outputs, internals;
```

Review comment:
This option should be handled in ONNX importer, not in the layer.
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...
**Review Line:** 742

**Code Changes:**
```diff
+    TEST_CYCLE() {
+        Mat res = net.forward();
+    }
+
+    SANITY_CHECK_NOTHING();
+}
+
+INSTANTIATE_TEST_CASE_P(/**/, Layer_Softmax, Combine(
+    Values(                // input size
+            std::vector<int>({16, 50, 50}),
+            std::vector<int>({16, 197, 197}),
```

Review comment:
Test all axis cases is needed, but the axis may be different for different dimension.
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...
**Review Line:** 742

**Code Changes:**
```diff
+    TEST_CYCLE() {
+        Mat res = net.forward();
+    }
+
+    SANITY_CHECK_NOTHING();
+}
+
+INSTANTIATE_TEST_CASE_P(/**/, Layer_Softmax, Combine(
+    Values(                // input size
+            std::vector<int>({16, 50, 50}),
+            std::vector<int>({16, 197, 197}),
```

Review comment:
Should I just make the perf test to a same dimension?
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...
**Review Line:** 742

**Code Changes:**
```diff
+    TEST_CYCLE() {
+        Mat res = net.forward();
+    }
+
+    SANITY_CHECK_NOTHING();
+}
+
+INSTANTIATE_TEST_CASE_P(/**/, Layer_Softmax, Combine(
+    Values(                // input size
+            std::vector<int>({16, 50, 50}),
+            std::vector<int>({16, 197, 197}),
```

Review comment:
Yep, the same dimensions if fine. I mean varying axis might be also useful: ``` {16, 1080, 1920, 3}, 1 {16, 1080, 1920, 3}, 2 {16, 1080, 1920, 3}, 3 ``` Instead of a new tests, you may add a parameter
**File:** modules/dnn/src/layers/cpu_kernels/softmax.cpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,157 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
Please use the same alignment
**File:** modules/dnn/src/layers/cpu_kernels/softmax.hpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,28 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
We can keep it as-is, then submit a PR to change this after merge.
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -707,4 +707,55 @@ INSTANTIATE_TEST_CASE_P(/**/, Layer_FullyConnected, Combine(
     dnnBackendsAndTargets()
 ));
 
+typedef TestBaseWithParam<tuple<std::vector<int>, int, tuple<Backend, Target> > > Layer_Softmax;
+PERF_TEST_P_(Layer_Softmax, softmax_3d) {
+    std::vector<int> shape = get<0>(GetParam());
+    int axis = get<1>(GetParam());
+    int backendId = get<0>(get<2>(GetParam()));
+    int targetId = get<1>(get<2>(GetParam()));
```

Review comment:
I suggest to put comments indicating parameter names, for example, ```cpp dnnBackendsAndTargets(/* withInferenceEngine = */ false, ...); ```
**File:** modules/dnn/src/layers/cpu_kernels/softmax.cpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,157 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
Multiple empty lines.
**File:** modules/dnn/src/layers/softmax_layer.cpp
**Change Type:** modified
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -52,6 +52,7 @@
 #include <algorithm>
 #include <stdlib.h>
 #include <opencv2/core/utils/logger.hpp>
+#include "cpu_kernels/softmax.hpp"
 using std::max;
 
 #ifdef HAVE_OPENCL
@@ -225,89 +226,15 @@ class SoftMaxLayerImpl CV_FINAL : public SoftmaxLayer
         std::vector<Mat> inputs, outputs, internals;
```

Review comment:
Indeed, the second one is under `HAVE_OPENCL` directive
**File:** modules/dnn/src/layers/cpu_kernels/softmax.cpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,157 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
I can see that these two macros are only used once respectively. I propose not to use macro but just plain code.
**File:** modules/dnn/src/layers/cpu_kernels/softmax.cpp
**Change Type:** added
**Context:** PR #24466: Improve and refactor softmax layer - This PR improves softmax from [ficus nn](https://github.com/vpisarev/ficus/tree/master/lib/NN). Perfor...

**Code Changes:**
```diff
@@ -0,0 +1,157 @@
+// 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.
+
+// This file is modified from the ficus (https://github.com/vpisarev/ficus/blob/master/lib/NN/OpNN.fx).
+// Here is the original license:
+/*
+    This file is a part of ficus language project.
+    See ficus/LICENSE for the licensing terms
```

Review comment:
Not sure whether definition of `CV_SIMD` guarantee availability of universal intrinsics. `#if CV_SIMD` is much more safe I think. Correct me if I am wrong.
**File:** modules/dnn/perf/perf_layer.cpp
**Change Type:** modified
**Context:** PR #24486: (5.x) Merge 4.x - OpenCV Contrib: https://github.com/opencv/opencv_contrib/pull/3587 Opencv Extra: https://github.com/opencv/opencv_extra/p...

**Code Changes:**
```diff
@@ -633,6 +633,56 @@ PERF_TEST_P_(Layer_LayerNormExpanded, DISABLED_LayerNormExpanded)
     test_layer({N, H ,W});
 }
 
+struct Layer_GatherElements : public TestBaseWithParam<tuple<Backend, Target> >
+{
+    void test_layer(const std::vector<int>& data_shape, const std::vector<int>& indices_shape, int axis = 0)
+    {
+        int backendId = get<0>(GetParam());
+        int targetId = get<1>(GetParam());
```

Review comment:
Should be: ``` INSTANTIATE_TEST_CASE_P(/**/, Layer_Slice, dnnBackendsAndTargets(/* withInferenceEngine = */false, /* obsolete_withHalide = */false)); ``` (keep 5.x version)
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
recompute mean/scale considering std parameter. ``` blob = [(inp - mean) * scale / std] ``` is the same as ``` blob = [(inp - mean / std) * (scale / std)] ```
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
There is no such field in common.py
**File:** samples/dnn/segmentation.py
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -14,7 +14,7 @@
 parser.add_argument('--zoo', default=os.path.join(os.path.dirname(os.path.abspath(__file__)), 'models.yml'),
                     help='An optional path to file with preprocessing parameters.')
 parser.add_argument('--input', help='Path to input image or video file. Skip this argument to capture frames from a camera.')
-parser.add_argument('--framework', choices=['caffe', 'tensorflow', 'torch', 'darknet'],
+parser.add_argument('--framework', choices=['caffe', 'tensorflow', 'torch', 'darknet', 'onnx'],
                     help='Optional name of an origin framework of the model. '
                          'Detect it automatically if it does not set.')
 parser.add_argument('--colors', help='Optional path to a text file with colors for an every class. '
```

Review comment:
Please remove trailing whitespaces
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Where we can find an original model?
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Hello sir, the model and clolor file are here https://github.com/richard28039/fcnresnet101_onnx_model
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
`pascal-voc-classes.txt` missed file
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
This is a newly created repository. Can you please refer how ONNX model was created?
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Hello sir, classes file is here https://github.com/richard28039/fcnresnet101_onnx_model/blob/main/pascal-voc-classes.txt
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Hello sir, I added the code that how I create the onnx model in my repository. https://github.com/richard28039/fcnresnet101_onnx_model/blob/main/torch_fcnresnet101_to_onnx.py
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Please use https://github.com/opencv/opencv/blob/4.x/samples/data/dnn/object_detection_classes_pascal_voc.txt instead. They match each other.
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Is there any difference with https://github.com/onnx/models/blob/main/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx ?
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
I had try this model berfore and it occurred the problem below, it seem that cv2.dnn.readnet can not accept dynamic shape, so I create the model which shape is (1, 3, 500, 500) by myself. ![螢幕擷取畫面 2023-10-19 181108](https://github.com/opencv/opencv/assets/89371302/1d454143-34f9-4226-919b-4936aa58c9f3)
**File:** samples/dnn/models.yml
**Change Type:** modified
**Context:** PR #24397: Added PyTorch fcnresnet101 segmentation conversion cases

**Code Changes:**
```diff
@@ -178,3 +178,15 @@ fcn8s:
   height: 500
   rgb: false
   sample: "segmentation"
+
+fcnresnet101:
+  load_info:
+    url: "https://github.com/onnx/models/raw/fb8271d5d5d9b90dbb1eb5e8e40f8f580fb248b3/vision/object_detection_segmentation/fcn/model/fcn-resnet101-11.onnx"
+    sha1: "e7e76474bf6b73334ab32c4be1374c9e605f5aed"
+  model: "fcn-resnet101-11.onnx"
```

Review comment:
Please add an image with resulting segmentation from a sample launch. I have a concern that classes might be 1 position shifted (depends on background id). So please run a sample on an image with more that one segmented object and put to PR description or in this thread,