<h5 dir="auto">System information (version)</h5>
<ul dir="auto">
<li>OpenCV =&gt; 4.5.3</li>
<li>Operating System / Platform =&gt; iOS 14.7.1 iOS 15</li>
<li>Compiler =&gt; Xcode 12</li>
</ul>
<h5 dir="auto">Detailed description</h5>
<p dir="auto">When I use version 4.5.3 to call the stitch method on IOS, the puzzle times an error. I can't debug. I don't know what the reason is. Please take a look. This problem is accidental. It is particularly easy to report an error by transmitting iPad screenshots to sitch.<br>
<a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/7530926/129342992-38fa8c5c-f26e-422b-b3ff-57cc3007a6ba.jpg"><img src="https://user-images.githubusercontent.com/7530926/129342992-38fa8c5c-f26e-422b-b3ff-57cc3007a6ba.jpg" alt="661628822758_ pic_hd" style="max-width: 100%;"></a></p>
<p dir="auto">The above figure shows the error stack.<br>
code:</p>
<p dir="auto">Ptr stitcher = Stitcher::create(cv::Stitcher::SCANS);<br>
Stitcher::Status status = stitcher-&gt;stitch(imgs, pano);</p>
<ul dir="auto">
<li>OpenCV =&gt; 3.4 / master (probably all 3.x versions)</li>
<li>Operating System / Platform =&gt; Windows 64 Bit</li>
<li>Compiler =&gt; python3.5, opencv3.4.3 (from pip here)</li>
</ul>
<h5 dir="auto">Detailed description</h5>
<p dir="auto">we <em>should</em> use <code class="notranslate">XXX_create()</code> functions, but folks will try to use <code class="notranslate">XXX()</code> instead ,<br>
leading to cryptic errors:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; img = np.array((2,2),np.uint8) # a dummy img, just for demo purpose
&gt;&gt;&gt; o = cv2.ORB()                  # this should not be possible, but it is !
&gt;&gt;&gt; o                              # it is a valid instance 
&lt;ORB 0000000603D44F90&gt;
&gt;&gt;&gt; o.detect(img)
Traceback (most recent call last):
  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
&gt;&gt;&gt; type(o)                        # python thinks, everything is ok here ;(
&lt;class 'cv2.ORB'&gt;
&gt;&gt;&gt; isinstance(o, cv2.Feature2D)   # same delusion
True
&gt;&gt;&gt;
&gt;&gt;&gt; s = cv2.xfeatures2d.SIFT()     # proper error.
Traceback (most recent call last):
  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;
AttributeError: module 'cv2.xfeatures2d' has no attribute 'SIFT'
&gt;&gt;&gt; s = cv2.xfeatures2d_SIFT()     # but uhhh !
&gt;&gt;&gt; s.detect(img)
Traceback (most recent call last):
  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
&gt;&gt;&gt; 
&gt;&gt;&gt; c = cv2.CLAHE()                # here, too !
&gt;&gt;&gt; c.apply(img)
Traceback (most recent call last):
  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'CLAHE' or its derivative)
"><pre class="notranslate"><code class="notranslate">&gt;&gt;&gt; img = np.array((2,2),np.uint8) # a dummy img, just for demo purpose
&gt;&gt;&gt; o = cv2.ORB()                  # this should not be possible, but it is !
&gt;&gt;&gt; o                              # it is a valid instance 
&lt;ORB 0000000603D44F90&gt;
&gt;&gt;&gt; o.detect(img)
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
&gt;&gt;&gt; type(o)                        # python thinks, everything is ok here ;(
&lt;class 'cv2.ORB'&gt;
&gt;&gt;&gt; isinstance(o, cv2.Feature2D)   # same delusion
True
&gt;&gt;&gt;
&gt;&gt;&gt; s = cv2.xfeatures2d.SIFT()     # proper error.
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
AttributeError: module 'cv2.xfeatures2d' has no attribute 'SIFT'
&gt;&gt;&gt; s = cv2.xfeatures2d_SIFT()     # but uhhh !
&gt;&gt;&gt; s.detect(img)
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'Feature2D' or its derivative)
&gt;&gt;&gt; 
&gt;&gt;&gt; c = cv2.CLAHE()                # here, too !
&gt;&gt;&gt; c.apply(img)
Traceback (most recent call last):
  File "&lt;stdin&gt;", line 1, in &lt;module&gt;
TypeError: Incorrect type of self (must be 'CLAHE' or its derivative)

</code></pre></div>