<h5 dir="auto">System information (version)</h5>

<ul dir="auto">
<li>OpenCV =&gt;4.12</li>
<li>Operating System / Platform =&gt; Windows 64 Bit</li>
<li>Compiler =&gt; PyCharm 2018 CE</li>
</ul>
<h5 dir="auto">Detailed description</h5>

<p dir="auto">i tried to run text detection.py based on my own east model, but it failed at<br>
''outs = net.forward(outNames)''</p>
<p dir="auto">cv2.error: OpenCV(4.1.1) .\opencv-python\opencv\modules\dnn\src\dnn.cpp:525: error: (-2:Unspecified error)<br>
Can't create layer "resnet_v1_50/conv1/BatchNorm/FusedBatchNormV3" of type "FusedBatchNormV3" in function 'cv::dnn::dnn4_v20190621::LayerData::getLayerInstance'</p>
<p dir="auto">i saved my model in this:</p>
<p dir="auto">output_graph = "frozen_east_model_02.pb"<br>
output_graph_def = tf.graph_util.convert_variables_to_constants(sess, sess.graph_def,<br>
["feature_fusion/Conv_7/Sigmoid",<br>
"feature_fusion/concat_3"])<br>
tf.train.write_graph(output_graph_def, ".", output_graph, as_text=False)</p>
<p dir="auto">i have tried to modify model.py ， nevertheless it did not work.<br>
<a href="https://github.com/argman/EAST/blob/master/model.py">https://github.com/argman/EAST/blob/master/model.py</a> Line 150</p>
<p dir="auto">c1_1 = slim.conv2d(tf.concat([g[i-1], f[i]], axis=3), num_outputs[i], 1)<br>
pi2 = 0.5 * np.pi<br>
angle_map = (slim.conv2d(g[3], 1, 1, activation_fn=tf.nn.sigmoid, normalizer_fn=None) - 0.5) * pi2 # angle is between [-45, 45]<br>
F_geometry = tf.concat([geo_map, angle_map], axis=3)</p>
<h5 dir="auto">Steps to reproduce</h5>
<h5 dir="auto">System information (version)</h5>
<ul dir="auto">
<li>OpenCV =&gt; 4.1</li>
<li>Operating System / Platform =&gt; macOS Mojave (10.14.3)</li>
<li>Compiler =&gt; XCode 10.3</li>
</ul>
<h5 dir="auto">Detailed description</h5>
<p dir="auto">The camera crashes while trying to initialize when the user is prompted with the "Do you allow  to access your camera?" instead of waiting for approval. After granting approval and rerunning the program again everything works just as intended but it is not good for development where the binary changes often and every time you want to test a change you have to run your code twice.</p>
<h5 dir="auto">Note</h5>
<p dir="auto">In order to force the authorization prompt to appear I added the Info.plist file to be copied to the binary like the suggestion in <a href="https://stackoverflow.com/questions/52541086/nscamerausagedescription-needed-for-c-projects-in-xcode-for-macos-mojave" rel="nofollow">this StackOverflow post</a></p>
<h5 dir="auto">Steps to reproduce</h5>
<div class="highlight highlight-source-c++ notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="#include &quot;opencv2/opencv.hpp&quot;

int main() {
   const int cameraDev = 0;
   cv::VideoCapture capture(cameraDev);

   while (!capture.isOpened()) {
       return -1;
   }
   
   cv::Mat frame;
   
   while(true) {
       capture &gt;&gt; frame;
       
       if (frame.empty()) {
           std::cout &lt;&lt; &quot;Empty frame, breaking!&quot; &lt;&lt; std::endl;
           break;
       }
       
      cv::imshow(&quot;What I see&quot;, frame);
       
       if (cv::waitKey(30) == 27) break; // KEY_ESCAPE
   }
   return 0;
}"><pre class="notranslate">#<span class="pl-k">include</span> <span class="pl-s"><span class="pl-pds">"</span>opencv2/opencv.hpp<span class="pl-pds">"</span></span>

<span class="pl-k">int</span> <span class="pl-en">main</span>() {
   <span class="pl-k">const</span> <span class="pl-k">int</span> cameraDev = <span class="pl-c1">0</span>;
   cv::VideoCapture <span class="pl-smi">capture</span>(cameraDev);

   <span class="pl-k">while</span> (!capture.<span class="pl-c1">isOpened</span>()) {
       <span class="pl-k">return</span> -<span class="pl-c1">1</span>;
   }
   
   cv::Mat frame;
   
   <span class="pl-k">while</span>(<span class="pl-c1">true</span>) {
       capture &gt;&gt; frame;
       
       <span class="pl-k">if</span> (frame.<span class="pl-c1">empty</span>()) {
           std::cout &lt;&lt; <span class="pl-s"><span class="pl-pds">"</span>Empty frame, breaking!<span class="pl-pds">"</span></span> &lt;&lt; std::endl;
           <span class="pl-k">break</span>;
       }
       
      <span class="pl-c1">cv::imshow</span>(<span class="pl-s"><span class="pl-pds">"</span>What I see<span class="pl-pds">"</span></span>, frame);
       
       <span class="pl-k">if</span> (<span class="pl-c1">cv::waitKey</span>(<span class="pl-c1">30</span>) == <span class="pl-c1">27</span>) <span class="pl-k">break</span>; <span class="pl-c"><span class="pl-c">//</span> KEY_ESCAPE</span>
   }
   <span class="pl-k">return</span> <span class="pl-c1">0</span>;
}</pre></div>
<ol dir="auto">
<li>Hit run.</li>
<li>Accept the prompt when the popup appears.</li>
<li>Stop the execution.</li>
<li>Run again.</li>
</ol>