{"id":6632,"date":"2026-06-22T23:33:57","date_gmt":"2026-06-22T18:33:57","guid":{"rendered":"https:\/\/cifrum.kz\/?p=6632"},"modified":"2026-06-23T09:19:31","modified_gmt":"2026-06-23T04:19:31","slug":"python-opencv-aqylly-kamera","status":"publish","type":"post","link":"https:\/\/cifrum.kz\/kk\/python-opencv-aqylly-kamera\/","title":{"rendered":"Python-\u0493\u0430 OpenCV \u043e\u0440\u043d\u0430\u0442\u044b\u043f, \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u0436\u0430\u0441\u0430\u0443"},"content":{"rendered":"<p class=\"has-large-font-size wp-block-paragraph\"><strong>\u0411\u04b1\u043b \u043d\u04b1\u0441\u049b\u0430\u0443\u043b\u044b\u049b\u0442\u0430 Python \u043a\u04e9\u043c\u0435\u0433\u0456\u043c\u0435\u043d \u0436\u04b1\u043c\u044b\u0441 \u0456\u0441\u0442\u0435\u0439\u0442\u0456\u043d \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u0436\u0430\u0441\u0430\u0439\u043c\u044b\u0437:<\/strong> OpenCV \u0432\u0435\u0431-\u043a\u0430\u043c\u0435\u0440\u0430\u0434\u0430\u043d \u043a\u0430\u0434\u0440 \u0430\u043b\u0430\u0434\u044b, \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441\u0442\u044b \u0430\u043d\u044b\u049b\u0442\u0430\u0439\u0434\u044b, QR-\u043a\u043e\u0434\u0442\u044b \u043e\u049b\u0438\u0434\u044b \u0436\u04d9\u043d\u0435 \u043e\u049b\u0438\u0493\u0430 \u0441\u0443\u0440\u0435\u0442\u0456\u043d \u0441\u0430\u049b\u0442\u0430\u0439\u0434\u044b. \u0421\u043e\u04a3\u044b\u043d\u0434\u0430 RTSP \u043a\u0430\u043c\u0435\u0440\u0430\u0441\u044b \u043c\u0435\u043d YOLO \u043c\u043e\u0434\u0435\u043b\u0456\u043d \u049b\u043e\u0441\u0443 \u0436\u043e\u043b\u044b\u043d \u043a\u04e9\u0440\u0441\u0435\u0442\u0435\u043c\u0456\u0437.<\/p>\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\"><p><strong>2026 \u0436\u044b\u043b\u0493\u044b 22 \u043c\u0430\u0443\u0441\u044b\u043c\u0434\u0430\u0493\u044b \u0436\u0430\u0493\u0434\u0430\u0439 \u0431\u043e\u0439\u044b\u043d\u0448\u0430 \u04e9\u0437\u0435\u043a\u0442\u0456.<\/strong> \u041a\u043e\u043c\u0430\u043d\u0434\u0430\u043b\u0430\u0440 <a href=\"https:\/\/pypi.org\/project\/opencv-python\/\" target=\"_blank\" rel=\"noopener\">opencv-python PyPI \u043f\u0430\u0440\u0430\u0493\u044b\u043c\u0435\u043d<\/a> \u0436\u04d9\u043d\u0435 OpenCV-\u0434\u0456\u04a3 <a href=\"https:\/\/docs.opencv.org\/4.x\/dd\/d43\/tutorial_py_video_display.html\" target=\"_blank\" rel=\"noopener\">\u0432\u0438\u0434\u0435\u043e<\/a>, <a href=\"https:\/\/docs.opencv.org\/4.x\/d1\/dc5\/tutorial_background_subtraction.html\" target=\"_blank\" rel=\"noopener\">\u0444\u043e\u043d\u0434\u044b \u0430\u043b\u044b\u043f \u0442\u0430\u0441\u0442\u0430\u0443<\/a>, <a href=\"https:\/\/docs.opencv.org\/4.x\/df\/d77\/group__objdetect__qrcode.html\" target=\"_blank\" rel=\"noopener\">QRCodeDetector<\/a> \u049b\u04b1\u0436\u0430\u0442\u0442\u0430\u043c\u0430\u043b\u0430\u0440\u044b\u043c\u0435\u043d \u0442\u0435\u043a\u0441\u0435\u0440\u0456\u043b\u0434\u0456. \u041c\u0430\u049b\u0430\u043b\u0430 \u043a\u04af\u043d\u0456\u043d\u0434\u0435\u0433\u0456 \u0442\u04b1\u0440\u0430\u049b\u0442\u044b PyPI \u043f\u0430\u043a\u0435\u0442\u0456 \u2014 4.13.0.92.<\/p><\/blockquote>\n<h2 class=\"wp-block-heading\">\u041d\u04d9\u0442\u0438\u0436\u0435\u0441\u0456\u043d\u0434\u0435 \u043d\u0435 \u0430\u043b\u0430\u0441\u044b\u0437<\/h2><ul class=\"wp-block-list\"><li>\u043a\u0430\u043c\u0435\u0440\u0430\u043d\u044b\u04a3 \u0442\u0456\u0440\u0456 \u043a\u0435\u0441\u043a\u0456\u043d\u0456 \u0436\u04d9\u043d\u0435 FPS;<\/li><li>\u0456\u0440\u0456 \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441 \u0430\u0439\u043c\u0430\u049b\u0442\u0430\u0440\u044b\u043d\u044b\u04a3 \u049b\u043e\u0440\u0448\u0430\u0443\u043b\u0430\u0440\u044b;<\/li><li>\u0431\u04b1\u043b\u0442\u0441\u044b\u0437 QR-\u043a\u043e\u0434 \u043e\u049b\u0443;<\/li><li><code>events<\/code> \u0431\u0443\u043c\u0430\u0441\u044b\u043d\u0430 \u0431\u0435\u0441 \u0441\u0435\u043a\u0443\u043d\u0434\u0442\u0430 \u0431\u0456\u0440 \u0440\u0435\u0442\u0442\u0435\u043d \u0436\u0438\u0456 \u0435\u043c\u0435\u0441 \u0441\u0430\u049b\u0442\u0430\u043b\u0430\u0442\u044b\u043d \u043a\u0430\u0434\u0440\u043b\u0430\u0440;<\/li><li>IP-\u043a\u0430\u043c\u0435\u0440\u0430 \u043c\u0435\u043d YOLO \u049b\u043e\u0441\u0443\u0493\u0430 \u0434\u0430\u0439\u044b\u043d \u043d\u0435\u0433\u0456\u0437.<\/li><\/ul>\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/cifrum.kz\/wp-content\/uploads\/2026\/06\/opencv-workflow-kk.jpg\" alt=\"OpenCV \u043d\u0435\u0433\u0456\u0437\u0456\u043d\u0434\u0435\u0433\u0456 \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430\u043d\u044b\u04a3 \u0436\u04b1\u043c\u044b\u0441 \u0441\u044b\u0437\u0431\u0430\u0441\u044b\"\/><figcaption class=\"wp-element-caption\">\u041a\u0430\u0434\u0440 \u0430\u043b\u044b\u043d\u0430\u0434\u044b, \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441 \u043f\u0435\u043d QR \u04e9\u04a3\u0434\u0435\u043b\u0435\u0434\u0456, \u0441\u043e\u0434\u0430\u043d \u043a\u0435\u0439\u0456\u043d \u043e\u049b\u0438\u0493\u0430\u043d\u044b \u0441\u0430\u049b\u0442\u0430\u0443 \u0442\u0443\u0440\u0430\u043b\u044b \u0448\u0435\u0448\u0456\u043c \u049b\u0430\u0431\u044b\u043b\u0434\u0430\u043d\u0430\u0434\u044b.<\/figcaption><\/figure>\n<h2 class=\"wp-block-heading\">1-\u049b\u0430\u0434\u0430\u043c. \u0416\u043e\u0431\u0430 \u043c\u0435\u043d \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u0434\u044b \u043e\u0440\u0442\u0430 \u0436\u0430\u0441\u0430\u04a3\u044b\u0437<\/h2><p>macOS \u0436\u04d9\u043d\u0435 Linux:<\/p>\n<pre class=\"wp-block-code\"><code>mkdir opencv-smart-camera\ncd opencv-smart-camera\npython3 -m venv .venv\nsource .venv\/bin\/activate<\/code><\/pre><p>Windows PowerShell:<\/p>\n<pre class=\"wp-block-code\"><code>mkdir opencv-smart-camera\ncd opencv-smart-camera\npy -m venv .venv\n.venv\\Scripts\\Activate.ps1<\/code><\/pre>\n<h2 class=\"wp-block-heading\">2-\u049b\u0430\u0434\u0430\u043c. OpenCV \u043e\u0440\u043d\u0430\u0442\u044b\u04a3\u044b\u0437<\/h2>\n<pre class=\"wp-block-code\"><code>python -m pip install --upgrade pip\npython -m pip install opencv-python\npython -c \"import cv2; print(cv2.__version__)\"<\/code><\/pre><p>\u0411\u0456\u0440 \u043e\u0440\u0442\u0430\u0493\u0430 OpenCV \u043f\u0430\u043a\u0435\u0442\u0456\u043d\u0456\u04a3 \u0431\u0456\u0440\u0435\u0443\u0456\u043d \u0493\u0430\u043d\u0430 \u043e\u0440\u043d\u0430\u0442\u044b\u04a3\u044b\u0437. \u0422\u0435\u0440\u0435\u0437\u0435\u0441\u0456\u0437 \u0441\u0435\u0440\u0432\u0435\u0440\u0433\u0435 <code>opencv-python-headless<\/code>, \u049b\u043e\u0441\u044b\u043c\u0448\u0430 \u043c\u043e\u0434\u0443\u043b\u044c\u0434\u0435\u0440 \u049b\u0430\u0436\u0435\u0442 \u0431\u043e\u043b\u0441\u0430 <code>opencv-contrib-python<\/code> \u049b\u043e\u043b\u0434\u0430\u043d\u044b\u043b\u0430\u0434\u044b.<\/p>\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/cifrum.kz\/wp-content\/uploads\/2026\/06\/opencv-install-kk.jpg\" alt=\"OpenCV-\u0434\u0456 \u0431\u04e9\u043b\u0435\u043a Python \u043e\u0440\u0442\u0430\u0441\u044b\u043d\u0430 \u043e\u0440\u043d\u0430\u0442\u0443 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u043b\u0430\u0440\u044b\"\/><figcaption class=\"wp-element-caption\">PyPI \u043f\u0430\u043a\u0435\u0442\u0456\u043d\u0456\u04a3 \u0430\u0442\u0430\u0443\u044b \u2014 <code>opencv-python<\/code>, \u0430\u043b Python \u0438\u043c\u043f\u043e\u0440\u0442\u044b \u2014 <code>cv2<\/code>.<\/figcaption><\/figure>\n<h2 class=\"wp-block-heading\">3-\u049b\u0430\u0434\u0430\u043c. \u041a\u0430\u043c\u0435\u0440\u0430\u043d\u044b \u0442\u0435\u043a\u0441\u0435\u0440\u0456\u04a3\u0456\u0437<\/h2>\n<pre class=\"wp-block-code\"><code>import cv2\ncamera = cv2.VideoCapture(0)\nif not camera.isOpened():\n    raise SystemExit(\"Cannot open camera\")\nwhile True:\n    ok, frame = camera.read()\n    if not ok: break\n    cv2.imshow(\"Camera test\", frame)\n    if cv2.waitKey(1) &amp; 0xFF == ord(\"q\"): break\ncamera.release()\ncv2.destroyAllWindows()<\/code><\/pre><p>\u0424\u0430\u0439\u043b\u0434\u044b <code>camera_test.py<\/code> \u0434\u0435\u043f \u0441\u0430\u049b\u0442\u0430\u043f, <code>python camera_test.py<\/code> \u043e\u0440\u044b\u043d\u0434\u0430\u04a3\u044b\u0437. \u041a\u0430\u043c\u0435\u0440\u0430 \u0430\u0448\u044b\u043b\u043c\u0430\u0441\u0430, Zoom \u0441\u0435\u043a\u0456\u043b\u0434\u0456 \u049b\u043e\u043b\u0434\u0430\u043d\u0431\u0430\u043b\u0430\u0440\u0434\u044b \u0436\u0430\u0443\u044b\u043f, \u0436\u04af\u0439\u0435\u043b\u0456\u043a \u0440\u04b1\u049b\u0441\u0430\u0442\u0442\u044b \u0436\u04d9\u043d\u0435 <code>1<\/code> \u0438\u043d\u0434\u0435\u043a\u0441\u0456\u043d \u0442\u0435\u043a\u0441\u0435\u0440\u0456\u04a3\u0456\u0437.<\/p>\n<h2 class=\"wp-block-heading\">4-\u049b\u0430\u0434\u0430\u043c. \u049a\u043e\u0437\u0493\u0430\u043b\u044b\u0441 \u043f\u0435\u043d QR-\u043a\u043e\u0434\u0442\u044b \u049b\u043e\u0441\u044b\u04a3\u044b\u0437<\/h2><p><code>MOG2<\/code> \u049b\u043e\u0437\u0493\u0430\u043b\u043c\u0430\u0439\u0442\u044b\u043d \u0444\u043e\u043d \u043c\u043e\u0434\u0435\u043b\u0456\u043d \u049b\u04b1\u0440\u0430\u0434\u044b. 200-\u0434\u0435\u043d \u0442\u04e9\u043c\u0435\u043d \u043c\u0430\u0441\u043a\u0430 \u043c\u04d9\u043d\u0434\u0435\u0440\u0456 \u043a\u04e9\u043b\u0435\u04a3\u043a\u0435 \u0440\u0435\u0442\u0456\u043d\u0434\u0435 \u0430\u043b\u044b\u043d\u044b\u043f \u0442\u0430\u0441\u0442\u0430\u043b\u0430\u0434\u044b, \u043c\u043e\u0440\u0444\u043e\u043b\u043e\u0433\u0438\u044f\u043b\u044b\u049b \u0441\u04af\u0437\u0433\u0456 \u04b1\u0441\u0430\u049b \u0448\u0443\u0434\u044b \u0442\u0430\u0437\u0430\u0440\u0442\u0430\u0434\u044b, \u0430\u043b <code>MIN_AREA<\/code> \u0442\u044b\u043c \u043a\u0456\u0448\u043a\u0435\u043d\u0442\u0430\u0439 \u043a\u043e\u043d\u0442\u0443\u0440\u043b\u0430\u0440\u0434\u044b \u04e9\u0442\u043a\u0456\u0437\u0431\u0435\u0439\u0434\u0456.<\/p>\n<pre class=\"wp-block-code\"><code>from datetime import datetime\nfrom pathlib import Path\nimport time\nimport cv2\nimport numpy as np\n\nSOURCE, MIN_AREA, COOLDOWN = 0, 2500, 5.0\nout = Path(\"events\"); out.mkdir(exist_ok=True)\ncamera = cv2.VideoCapture(SOURCE)\nif not camera.isOpened(): raise SystemExit(\"Cannot open camera\")\nmodel = cv2.createBackgroundSubtractorMOG2(500, 36, True)\nqr = cv2.QRCodeDetector()\nkernel = np.ones((3, 3), np.uint8)\nlast_saved = 0.0\n\ntry:\n    while True:\n        ok, frame = camera.read()\n        if not ok: break\n        mask = model.apply(frame)\n        _, mask = cv2.threshold(mask, 200, 255, cv2.THRESH_BINARY)\n        mask = cv2.morphologyEx(mask, cv2.MORPH_OPEN, kernel, iterations=2)\n        mask = cv2.dilate(mask, kernel, iterations=2)\n        motion = False\n        contours, _ = cv2.findContours(mask, cv2.RETR_EXTERNAL,\n                                       cv2.CHAIN_APPROX_SIMPLE)\n        for contour in contours:\n            if cv2.contourArea(contour) &lt; MIN_AREA: continue\n            x, y, w, h = cv2.boundingRect(contour)\n            cv2.rectangle(frame, (x, y), (x+w, y+h), (0,220,180), 2)\n            motion = True\n        text, points, _ = qr.detectAndDecode(frame)\n        if text and points is not None:\n            pts = points.astype(int).reshape(-1, 2)\n            cv2.polylines(frame, [pts], True, (0,210,255), 3)\n            cv2.putText(frame, f\"QR: {text[:40]}\", (20,70),\n                        cv2.FONT_HERSHEY_SIMPLEX, .7, (0,210,255), 2)\n        now = time.monotonic()\n        if motion and now-last_saved &gt;= COOLDOWN:\n            name = datetime.now().strftime(\"event_%Y%m%d_%H%M%S.jpg\")\n            cv2.imwrite(str(out\/name), frame); last_saved = now\n        cv2.imshow(\"OpenCV smart camera\", frame)\n        if cv2.waitKey(1) &amp; 0xFF == ord(\"q\"): break\nfinally:\n    camera.release(); cv2.destroyAllWindows()<\/code><\/pre>\n<h2 class=\"wp-block-heading\">5-\u049b\u0430\u0434\u0430\u043c. \u0406\u0441\u043a\u0435 \u049b\u043e\u0441\u044b\u043f, \u0441\u0435\u0437\u0456\u043c\u0442\u0430\u043b\u0434\u044b\u049b\u0442\u044b \u0440\u0435\u0442\u0442\u0435\u04a3\u0456\u0437<\/h2><pre class=\"wp-block-code\"><code>python smart_camera.py<\/code><\/pre><ul><li><code>MIN_AREA<\/code> \u2014 \u04b1\u0441\u0430\u049b \u043a\u04e9\u043b\u0435\u04a3\u043a\u0435\u043b\u0435\u0440\u0433\u0435 \u0440\u0435\u0430\u043a\u0446\u0438\u044f\u043d\u044b \u0430\u0437\u0430\u0439\u0442\u0430\u0434\u044b;<\/li><li><code>COOLDOWN<\/code> \u2014 \u0441\u0430\u049b\u0442\u0430\u0443\u043b\u0430\u0440 \u0430\u0440\u0430\u0441\u044b\u043d\u0434\u0430\u0493\u044b \u04af\u0437\u0456\u043b\u0456\u0441;<\/li><li><code>Q<\/code> \u2014 \u043a\u0430\u043c\u0435\u0440\u0430\u043d\u044b \u0434\u04b1\u0440\u044b\u0441 \u0431\u043e\u0441\u0430\u0442\u044b\u043f, \u0431\u0430\u0493\u0434\u0430\u0440\u043b\u0430\u043c\u0430\u043d\u044b \u0436\u0430\u0431\u0430\u0434\u044b.<\/li><\/ul>\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/cifrum.kz\/wp-content\/uploads\/2026\/06\/opencv-result-kk.jpg\" alt=\"OpenCV \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430\u0441\u044b\u043d\u044b\u04a3 \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u044f\u043b\u044b\u049b \u044d\u043a\u0440\u0430\u043d\u044b\"\/><figcaption class=\"wp-element-caption\">\u049a\u043e\u0437\u0493\u0430\u043b\u044b\u0441 \u049b\u043e\u0440\u0448\u0430\u0443\u044b, QR-\u043a\u043e\u0434 \u0436\u04d9\u043d\u0435 \u043e\u049b\u0438\u0493\u0430\u043b\u0430\u0440 \u043a\u04e9\u0440\u0441\u0435\u0442\u0456\u043b\u0433\u0435\u043d \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u044f\u043b\u044b\u049b \u043d\u04d9\u0442\u0438\u0436\u0435.<\/figcaption><\/figure>\n<h2 class=\"wp-block-heading\">6-\u049b\u0430\u0434\u0430\u043c. \u0412\u0438\u0434\u0435\u043e \u043d\u0435\u043c\u0435\u0441\u0435 RTSP \u049b\u043e\u0441\u044b\u04a3\u044b\u0437<\/h2><pre class=\"wp-block-code\"><code>SOURCE = \"video.mp4\"\n# \u043d\u0435\u043c\u0435\u0441\u0435\nSOURCE = \"rtsp:\/\/USER:PASSWORD@CAMERA_IP:554\/STREAM_PATH\"<\/code><\/pre><p>\u041d\u0430\u049b\u0442\u044b \u049b\u04b1\u043f\u0438\u044f\u0441\u04e9\u0437\u0434\u0456 Git-\u043a\u0435 \u043d\u0435\u043c\u0435\u0441\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u049b\u0430 \u049b\u043e\u0441\u043f\u0430\u04a3\u044b\u0437. \u041a\u0430\u043c\u0435\u0440\u0430\u043d\u044b \u0436\u0435\u0440\u0433\u0456\u043b\u0456\u043a\u0442\u0456 \u0436\u0435\u043b\u0456\u043c\u0435\u043d \u0448\u0435\u043a\u0442\u0435\u043f, RTSP \u043f\u043e\u0440\u0442\u044b\u043d \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u043a\u0435 \u0442\u0456\u043a\u0435\u043b\u0435\u0439 \u0430\u0448\u043f\u0430\u04a3\u044b\u0437.<\/p>\n<h2 class=\"wp-block-heading\">7-\u049b\u0430\u0434\u0430\u043c. YOLO26 \u043c\u043e\u0434\u0435\u043b\u0456\u043d \u049b\u043e\u0441\u044b\u04a3\u044b\u0437<\/h2><pre class=\"wp-block-code\"><code>python -m pip install ultralytics<\/code><\/pre><pre class=\"wp-block-code\"><code>from ultralytics import YOLO\nmodel = YOLO(\"best.pt\")\nresults = model.predict(frame, conf=0.35, verbose=False)\nframe = results[0].plot()<\/code><\/pre><p>\u0416\u04af\u043a\u0442\u0435\u043c\u0435\u043d\u0456 \u0430\u0437\u0430\u0439\u0442\u0443 \u04af\u0448\u0456\u043d \u043d\u0435\u0439\u0440\u043e\u043d\u0434\u044b\u049b \u0436\u0435\u043b\u0456\u043d\u0456 \u04d9\u0440 \u0435\u043a\u0456\u043d\u0448\u0456 \u043d\u0435\u043c\u0435\u0441\u0435 \u04af\u0448\u0456\u043d\u0448\u0456 \u043a\u0430\u0434\u0440\u0434\u0430 \u0456\u0441\u043a\u0435 \u049b\u043e\u0441\u044b\u04a3\u044b\u0437. \u041c\u043e\u0434\u0435\u043b\u044c\u0434\u0456 \u043e\u049b\u044b\u0442\u0443 <a href=\"https:\/\/cifrum.kz\/kk\/yolo26-ornatu-okytu-nuskaulygy\/\">YOLO26 \u043d\u04b1\u0441\u049b\u0430\u0443\u043b\u044b\u0493\u044b\u043d\u0434\u0430<\/a> \u0431\u0435\u0440\u0456\u043b\u0433\u0435\u043d.<\/p>\n<h2 class=\"wp-block-heading\">\u0416\u0438\u0456 \u043a\u0435\u0437\u0434\u0435\u0441\u0435\u0442\u0456\u043d \u049b\u0430\u0442\u0435\u043b\u0435\u0440<\/h2><ul><li><strong>\u041a\u0430\u043c\u0435\u0440\u0430 \u0430\u0448\u044b\u043b\u043c\u0430\u0439\u0434\u044b:<\/strong> \u041e\u0421 \u0440\u04b1\u049b\u0441\u0430\u0442\u044b\u043d, \u0438\u043d\u0434\u0435\u043a\u0441\u0442\u0456 \u0436\u04d9\u043d\u0435 \u043a\u0430\u043c\u0435\u0440\u0430\u043d\u044b \u0438\u0435\u043b\u0435\u043d\u0433\u0435\u043d \u049b\u043e\u043b\u0434\u0430\u043d\u0431\u0430\u043b\u0430\u0440\u0434\u044b \u0442\u0435\u043a\u0441\u0435\u0440\u0456\u04a3\u0456\u0437.<\/li><li><strong>\u0421\u0435\u0440\u0432\u0435\u0440\u0434\u0435 \u0442\u0435\u0440\u0435\u0437\u0435 \u0436\u043e\u049b:<\/strong> headless \u043f\u0430\u043a\u0435\u0442\u0456\u043d\u0434\u0435 <code>imshow<\/code> \u049b\u043e\u043b\u0434\u0430\u043d\u044b\u043b\u043c\u0430\u0439\u0434\u044b.<\/li><li><strong>\u041e\u049b\u0438\u0493\u0430 \u0442\u044b\u043c \u043a\u04e9\u043f:<\/strong> <code>MIN_AREA<\/code> \u0436\u04d9\u043d\u0435 <code>COOLDOWN<\/code> \u043c\u04d9\u043d\u0434\u0435\u0440\u0456\u043d \u0430\u0440\u0442\u0442\u044b\u0440\u044b\u04a3\u044b\u0437.<\/li><li><strong>QR \u043e\u049b\u044b\u043b\u043c\u0430\u0439\u0434\u044b:<\/strong> \u0436\u0430\u0440\u044b\u049b\u0442\u044b \u0436\u0430\u049b\u0441\u0430\u0440\u0442\u044b\u043f, \u0448\u0430\u0493\u044b\u043b\u044b\u0441\u0442\u044b \u0430\u0437\u0430\u0439\u0442\u044b\u04a3\u044b\u0437.<\/li><\/ul>\n<h2 class=\"wp-block-heading\">\u049a\u043e\u0440\u044b\u0442\u044b\u043d\u0434\u044b<\/h2><p>OpenCV \u043a\u04e9\u043c\u0435\u0433\u0456\u043c\u0435\u043d \u0431\u04b1\u043b\u0442\u0441\u044b\u0437 \u043f\u0430\u0439\u0434\u0430\u043b\u044b \u043f\u0440\u043e\u0442\u043e\u0442\u0438\u043f \u0436\u0430\u0441\u0430\u0443\u0493\u0430 \u0431\u043e\u043b\u0430\u0434\u044b: \u0432\u0438\u0434\u0435\u043e\u043d\u044b \u043e\u049b\u0443, \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441\u0442\u044b \u0431\u04e9\u043b\u0456\u043f \u0430\u043b\u0443, QR-\u043a\u043e\u0434\u0442\u044b \u0442\u0430\u043d\u0443 \u0436\u04d9\u043d\u0435 \u043e\u049b\u0438\u0493\u0430\u043d\u044b \u0441\u0430\u049b\u0442\u0430\u0443. \u0410\u043b\u0434\u044b\u043c\u0435\u043d \u0432\u0435\u0431-\u043a\u0430\u043c\u0435\u0440\u0430\u043d\u044b \u0442\u04b1\u0440\u0430\u049b\u0442\u0430\u043d\u0434\u044b\u0440\u044b\u043f, \u043a\u0435\u0439\u0456\u043d RTSP \u043f\u0435\u043d YOLO-\u043d\u044b \u0431\u0456\u0440-\u0431\u0456\u0440\u0434\u0435\u043d \u049b\u043e\u0441\u044b\u04a3\u044b\u0437.<\/p><p><em>\u041c\u04b1\u049b\u0430\u0431\u0430 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u0438\u0432\u0442\u0456 \u043c\u043e\u0434\u0435\u043b\u044c\u043c\u0435\u043d \u0436\u0430\u0441\u0430\u043b\u0434\u044b. \u0421\u044b\u0437\u0431\u0430\u043b\u0430\u0440\u0434\u0430 \u043d\u0430\u049b\u0442\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u043c\u0435\u043a\u0435\u043d\u0436\u0430\u0439\u043b\u0430\u0440\u044b, \u0442\u0456\u0440\u043a\u0435\u043b\u0433\u0456 \u0434\u0435\u0440\u0435\u043a\u0442\u0435\u0440\u0456 \u043d\u0435\u043c\u0435\u0441\u0435 \u0436\u0435\u043a\u0435 \u0430\u049b\u043f\u0430\u0440\u0430\u0442 \u0436\u043e\u049b.<\/em><\/p>\n<style>body.postid-6632 .cf-code-copy-wrap{position:relative;margin:1.5em 0}body.postid-6632 .cf-code-copy-wrap pre{margin:0;padding-top:3.25rem;overflow-x:auto}body.postid-6632 .cf-code-copy-button{position:absolute;top:.75rem;right:.75rem;z-index:2;padding:.45rem .75rem;background:#fff;border:1px solid #cbd4e5;border-radius:5px;font-weight:600}<\/style><script>document.addEventListener('DOMContentLoaded',function(){document.querySelectorAll('body.postid-6632 pre.wp-block-code').forEach(function(p){var w=document.createElement('div');w.className='cf-code-copy-wrap';p.parentNode.insertBefore(w,p);w.appendChild(p);var b=document.createElement('button');b.className='cf-code-copy-button';b.textContent='\u041a\u04e9\u0448\u0456\u0440\u0443';b.onclick=function(){var t=(p.querySelector('code')||p).innerText;navigator.clipboard.writeText(t).catch(function(){var a=document.createElement('textarea');a.value=t;document.body.appendChild(a);a.select();document.execCommand('copy');a.remove()}).then(function(){b.textContent='\u041a\u04e9\u0448\u0456\u0440\u0456\u043b\u0434\u0456'})};w.insertBefore(b,p)})});<\/script>\n","protected":false},"excerpt":{"rendered":"<p>Python-\u0493\u0430 OpenCV \u043e\u0440\u043d\u0430\u0442\u0443 \u0436\u04d9\u043d\u0435 \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u0436\u0430\u0441\u0430\u0443: \u0432\u0435\u0431-\u043a\u0430\u043c\u0435\u0440\u0430, \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441, QR-\u043a\u043e\u0434\u0442\u0430\u0440, \u043e\u049b\u0438\u0493\u0430\u043b\u0430\u0440\u0434\u044b \u0441\u0430\u049b\u0442\u0430\u0443, RTSP \u0436\u04d9\u043d\u0435 YOLO.<\/p>\n","protected":false},"author":1,"featured_media":6623,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"rank_math_focus_keyword":"Python-\u0493\u0430 OpenCV \u043e\u0440\u043d\u0430\u0442\u0443","rank_math_title":"Python-\u0493\u0430 OpenCV \u043e\u0440\u043d\u0430\u0442\u044b\u043f, \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u0436\u0430\u0441\u0430\u0443","rank_math_description":"Python-\u0493\u0430 OpenCV \u043e\u0440\u043d\u0430\u0442\u044b\u043f, \u049b\u043e\u0437\u0493\u0430\u043b\u044b\u0441\u0442\u044b \u0436\u04d9\u043d\u0435 QR-\u043a\u043e\u0434\u0442\u0430\u0440\u0434\u044b \u0430\u043d\u044b\u049b\u0442\u0430\u0439\u0442\u044b\u043d, \u043e\u049b\u0438\u0493\u0430\u043b\u0430\u0440\u0434\u044b \u0441\u0430\u049b\u0442\u0430\u0439\u0442\u044b\u043d \u0430\u049b\u044b\u043b\u0434\u044b \u043a\u0430\u043c\u0435\u0440\u0430 \u0436\u0430\u0441\u0430\u0443\u0434\u044b\u04a3 \u049b\u0430\u0434\u0430\u043c\u0434\u044b\u049b \u043d\u04b1\u0441\u049b\u0430\u0443\u043b\u044b\u0493\u044b.","rank_math_canonical_url":"","rank_math_seo_score":"25","rank_math_pillar_content":"","rank_math_facebook_title":"","rank_math_facebook_description":"","rank_math_facebook_image":"","rank_math_facebook_image_id":"","rank_math_twitter_title":"","rank_math_twitter_description":"","rank_math_twitter_image":"","rank_math_twitter_image_id":"","rank_math_news_sitemap_genre":"","rank_math_news_sitemap_keywords":"","rank_math_news_sitemap_stock_tickers":"","rank_math_robots":"","rank_math_advanced_robots":"","rank_math_schema_News":"","footnotes":""},"categories":[1793,1631],"tags":[],"cifrum_os_content_type":[],"class_list":["post-6632","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-zhasandy-intellekt","category-artificial_intelligence"],"acf":[],"_links":{"self":[{"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/posts\/6632","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/comments?post=6632"}],"version-history":[{"count":1,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/posts\/6632\/revisions"}],"predecessor-version":[{"id":6635,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/posts\/6632\/revisions\/6635"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/media\/6623"}],"wp:attachment":[{"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/media?parent=6632"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/categories?post=6632"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/tags?post=6632"},{"taxonomy":"cifrum_os_content_type","embeddable":true,"href":"https:\/\/cifrum.kz\/kk\/wp-json\/wp\/v2\/cifrum_os_content_type?post=6632"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}