\begin{array}{l} N =  \sum _{I, \texttt{mask} (I)  \ne 0} 1 \\ \texttt{mean} _c =  \frac{\sum_{ I: \; \texttt{mask}(I) \ne 0} \texttt{src} (I)_c}{N} \\ \texttt{stddev} _c =  \sqrt{\frac{\sum_{ I: \; \texttt{mask}(I) \ne 0} \left ( \texttt{src} (I)_c -  \texttt{mean} _c \right )^2}{N}} \end{array}

meanStdDev[1]Calculates a mean and standard deviation of array elements. C++: void meanStdDev(InputArray src, OutputArray mean, OutputArray stddev, InputArray mask=noArray())
Python: cv2.meanStdDev(src[, mean[, stddev[, mask]]]) → mean, stddev

me1237guy 發表在 痞客邦 留言(0) 人氣()

image
  • Viola–Jones object detection[1][7]包含下列四個步驟

    1. Haar Feature Selection
    2. Creating an Integral Image
    3. Adaboost Training
    4. Cascading Classifiers

  • me1237guy 發表在 痞客邦 留言(1) 人氣()

    image
    Microsoft 推出許多認知服務相關的API, 這些API工具包含影像處理, 語音辨識, 人工智慧, …可以廣泛應用在各專業領域, 有興趣的人可以去聲請測試, 一窺究竟…https://www.microsoft.com/cognitive-services/----------------------------------------------------------------------------------------------------------------------------------------------

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    請先參考下面這一篇, 篩選RGB得到顏色範圍內的遮罩
    • RGB顏色範圍內的遮罩應用 Part II

    • ----------------------------------------------------

    • 先來認識inRange函式定義

    • inRange

      Checks if array elements lie between the elements of two other arrays.

      C++: void inRange(InputArray src, InputArray lowerb, InputArray upperb, OutputArray dst)
      Python: cv2.inRange(src, lowerb, upperb[, dst]) → dst
      C: void cvInRange(const CvArr* src, const CvArr* lower, const CvArr* upper, CvArr* dst)
      C: void cvInRangeS(const CvArr* src, CvScalar lower, CvScalar upper, CvArr* dst)
      Python: cv.InRange(src, lower, upper, dst) → None
      Python: cv.InRangeS(src, lower, upper, dst) → None

      Parameters:

      • src – first input array.
      • lowerb – inclusive lower boundary array or a scalar.
      • upperb – inclusive upper boundary array or a scalar.
      • dst – output array of the same size as src and CV_8U type.

      The function checks the range as follows:

      • For every element of a single-channel input array:

        \texttt{dst} (I)= \texttt{lowerb} (I)_0 \leq \texttt{src} (I)_0 \leq \texttt{upperb} (I)_0

      • For two-channel arrays:

        \texttt{dst} (I)= \texttt{lowerb} (I)_0 \leq \texttt{src} (I)_0 \leq \texttt{upperb} (I)_0 \land \texttt{lowerb} (I)_1 \leq \texttt{src} (I)_1 \leq \texttt{upperb} (I)_1

      • and so forth.

      That is, dst (I) is set to 255 (all 1 -bits) if src (I) is within the specified 1D, 2D, 3D, ... box and 0 otherwise.

      When the lower and/or upper boundary parameters are scalars, the indexes (I) at lowerb and upperb in the above formulas should be omitted.

    • ----------------------------------------------------

    接下來, RGB2HSVcolorInRange.hcolorInRange.cpp
    void ImgProc::RGB2HSV()
    {
     Mat dst = RGB2HSV(m_src);
     namedWindow("HSV", CV_WINDOW_NORMAL);
     cv::imshow("HSV", dst);
    }
    Mat ImgProc::RGB2HSV(const Mat& src)
    {
     assert(src.type() == CV_8UC3);
     
     Mat dst;
     cv::cvtColor(src, dst, CV_BGR2HSV);
     return dst;
    }

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
    請先參考下面這一篇, 建立所需的編譯環境RGB顏色範圍內的遮罩應用 Part I: Visual Studio 2013編譯環境建構-------------------------------------------------------1. 先建立一個可以接收C# UI丟過來的影像檔案的路徑名稱 imread(filename)2. 利用imshow()顯示影像新增一個header file滑鼠點選Header File(.h)輸入檔名: colorInRange.hGeneral->Common Language Runtime Support

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
    首先, 先下載安裝OpenCV2.4.10, 安裝方式請參考下面這篇:Quick Installation for OpenCV 2.4.10 with Visual Studio 2013版本: Visual Studio 2013 and OpenCV 2.4.10 準備建立四種不同屬性管理員專案, 可以方便以後使用OpenCV2.4.10直接下載使用, 免除重複設定include & library環境1. VS2013OpenCV2410X86Release2. VS2013OpenCV2410X86Debug

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
  • 先下載OpenCV 2.4.10創建資料夾例如C:\OpenCV\OpenCV2410\
  • me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
    到官網下載下載後解壓縮至任何你喜歡的資料夾, 以我筆電為例E:\GLUT\glutdlls37beta先設定專案環境<環境變數>設定, 在Path變數加入GLUT安裝路徑(DLL目錄)如果懶得加入系統變數,則是將E:\GLUT\glutdlls37beta\glut32.dll複製一份至Debug資料夾下就可以正常執行…

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image

    註冊後, 可以線上閱讀學習小一 下 國語非常棒的互動式電子書, 適合家長與小孩一起學習…
    參考資料1. 沒帶課本回家 ? 康軒版電子課本線上看

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
    到 http://www.boost.org/ 下載最新版本目前是1.60.0點選熟悉的windows作業系統點選後直接連到Sourceforge下載檔案有些大 126MB解壓縮至如 E:\Boost Library\boost_1_60_0------------------------------------------------------------------------------執行bootstrap

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image
    音符[1] Do, Re, Mi, Fa, Sol, La, Si對應自然音記號:   C,   D,  E,  F,  G,   A,  BSol –> G 記憶法: So GoodRe->D 記憶法: Red

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    image

    Creating Various Types of Image ROIs by Drawing Lines, Rectangles or Eclipses


    先前研究

    C# 在PictureBox 畫線: 虛線, 點線, 點虛線

    目前可以做到

    1. 透過滑鼠兩點(button down and button up), 任意拉出一條 實線/虛線/點線 { L_i } where i=1,2,..,N

    2. 線段可以設定粗細,顏色

    3. 可以點選任意一組線段L_i, 進行整條線段拖拉動作

    3. 可以修改任意一組L_i線段的標籤位置

    4. 可刪除任意一組L_i

    -----------------------------------------------------------------------------------

    me1237guy 發表在 痞客邦 留言(0) 人氣()

    Blog Stats
    ⚠️

    成人內容提醒

    本部落格內容僅限年滿十八歲者瀏覽。
    若您未滿十八歲,請立即離開。

    已滿十八歲者,亦請勿將內容提供給未成年人士。