owned this note changed 4 years ago
Linked with GitHub

追蹤動畫截圖出處的搜尋引擎 - soruly

由於場地問題,第二天我們移動到另一棟大樓啦!議程教室變動請見網站上的議程表

歡迎來到 https://hackmd.io/@coscup/2019 共筆

Image Not Showing Possible Reasons
  • The image file may be corrupted
  • The server hosting the image is unavailable
  • The image path is incorrect
  • The image format is not supported
Learn More →

點擊本頁上方的 開始用 Markdown 一起寫筆記!
手機版請點選上方 按鈕展開議程列表。

請從這裡開始

https://github.com/soruly/slides

https://github.com/soruly/slides/blob/master/2019-08-trace.moe.md

圖像描述

  • Color Layout ==> 顏色分布
    • 硬體需求低
    • 動畫顏色鮮明
    • 刪除重複的圖示,減少資料庫大小
  • Edge Histogram ==> 只看邊沿/紋理
  • Opponent Histogram
  • ScalableColor

取得圖像特徵 (Image Hash)

  • 原圖
  • 分成 8x8 格
  • 計算每格顏色平均值
  • 換算成 YCbCr 色域
  • DCT 變換
  • 量化 (quantize)
  • Zigzag 排列成線性

(求補充)

https://en.wikipedia.org/wiki/Color_layout_descriptor

在 LIRE 裡面 Color Layout 的程式碼
https://github.com/soruly/LIRE/blob/master/src/main/java/net/semanticmetadata/lire/imageanalysis/features/global/ColorLayout.java

自動幀測及裁剪黑邊

黑邊會影響到判斷的準確度,所以透過 OpenCV 去裁切掉黑邊

影片預覽

  • Before: 固定前 N 秒後 M 秒
    • 會包含不相關的畫面
    • 可能可以把整個動畫搜尋出來 (有版權疑慮)
  • After: 只顯示同一個鏡頭

同一個鏡頭判斷的原理

將每一幀所有像素相加,然後往前往後去找,直到超過一個臨界

關鍵的源碼在這
https://github.com/soruly/trace.moe-media/blob/master/src/detect-scene.js

tags: COSCUP2019 跨境合作 - HKOSCon (Open Source HK) IB302
Select a repo