# Opencv hangs in cv::cvtColor

**URL:** <https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490>\
**Category:** C++\
**Tags:** build, imgproc\
**Created:** [November 30, 2021, 8:07am UTC](https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490 "2021-11-30T08:07:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![wisecode](https://avatars.discourse-cdn.com/v4/letter/w/f14d63/32.png) [@wisecode](https://forum.opencv.org/u/wisecode)\
**Post date:** [November 30, 2021, 8:07am UTC](https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490/1 "2021-11-30T08:07:22Z")

</div>

I have a reproducible bug where OpenCV (454) hangs in cv::cvtColor, sometimes it get past it but instead hangs in cv::GaussianBlur operation instead. I have a really hard time to debug it but it looks like something happens in “parallel\_for” execution in “smooth.simd.hpp” and finaly in “parallel.cpp” function “getCurrentParallelForAPI”.

---

<div class="post-metadata">

**Author:** ![berak](https://avatars.discourse-cdn.com/v4/letter/b/85f322/32.png) [@berak](https://forum.opencv.org/u/berak)\
**Post date:** [November 30, 2021, 8:26am UTC](https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490/2 "2021-11-30T08:26:40Z")

</div>

example code / image to reproduce it ?

---

<div class="post-metadata">

**Author:** ![wisecode](https://avatars.discourse-cdn.com/v4/letter/w/f14d63/32.png) [@wisecode](https://forum.opencv.org/u/wisecode)\
**Post date:** [November 30, 2021, 9:20am UTC](https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490/3 "2021-11-30T09:20:36Z")

</div>

At the moment its not possible to link source code I can try to isolate it later. But I have noticed this output when I run debug build:  
[INFO:1] global c:\build\master\_winpack-build-win64-vc15\opencv\modules\core\src\parallel\registry\_parallel.impl.hpp (96) cv::parallel::ParallelBackendRegistry::ParallelBackendRegistry core(parallel): Enabled backends(3, sorted by priority): ONETBB(1000); TBB(990); OPENMP(980)

[INFO:1] global c:\build\master\_winpack-build-win64-vc15\opencv\modules\core\src\utils\plugin\_loader.impl.hpp (67) cv::plugin::impl::DynamicLib::libraryLoad load C:\Alex\fb\opencv\_core\_parallel\_onetbb454\_64d.dll =\> FAILED

I have no folder named c:\build\master\_winpack-build-win64-vc15\opencv !

Maybe I have not installed opencv correctly because that dll is missing in the installed opencv folder.

---

<div class="post-metadata">

**Author:** ![berak](https://avatars.discourse-cdn.com/v4/letter/b/85f322/32.png) [@berak](https://forum.opencv.org/u/berak)\
**Post date:** [November 30, 2021, 9:41am UTC](https://forum.opencv.org/t/opencv-hangs-in-cv-cvtcolor/6490/4 "2021-11-30T09:41:17Z")

</div>

> [@wisecode](#):
>
> Maybe I have not installed opencv correctly because that dll is missing in the installed opencv folder.

no, there is probably nothing wrong with your install.  
those plugin dlls are optional, and not supplied here.  
the info messages are also only shown in debug mode.

```
cout << getBuildInformation();

```

will show, which parallel support was builtin.

> I have no folder named c:\build\master\_winpack-build-win64-vc15\opencv !

this is from the machine, the libs were built on, not yours.
