雜散光(光暈)文件頁面
介紹: 雜散光測試與歸一化雜散光簡介|Imatest 雜散光分析輸出|歷史記錄
背景: 雜散光範例|根本原因|測試概述|測試因素|測試注意事項|術語表
計算: 度量影像|歸一化方法|光源遮罩方法|總結指標|分析通道|飽和度
說明: Imatest 進階分析說明(主控和 IT) |使用 Imatest 計算歸一化雜散光|電動雲台說明
設定: 設定清單和 INI 鍵/值|標準和建議|設定檔輸入
設定檔
在 Imatest Master 22.2 中,「config」檔案(設定檔)是雜散光(耀斑)分析的可選輸入。希望最大程度挖掘資料價值的使用者可以使用設定檔作為輸入,從而獲得額外的輸出和分析選項。在 Imatest IT 22.2 中,設定檔(或 StrayLightConfig 物件)是分析的必要輸入。
配置檔案是一個 JSON 編碼的文本文件,它定義了待分析的每個圖像文件的元信息,包括圖像文件的路徑以及與每個圖像關聯的光源的位置/角度。在分析過程中,這些元資訊與資料關聯,從而可以產生分析圖(例如,繪製雜散光統計資料與光源場角的關係圖)並更好地標註輸出結果。這種標註非常重要,因為它有助於更好地組織和管理結果,並且某些標準(例如 IEEE-P2020)要求報告這些資訊。設定檔可以相對輕鬆地透過程式設計方式生成,因為大多數程式語言都提供了處理和生成JSON(JavaScript 物件表示法)文字格式的工具。

在 Imatest Master 中,使用者可以選擇設定檔作為輸入,就像選擇輸入映像一樣;或者,使用者也可以選擇包含一個或多個設定檔的目錄。設定檔必須採用以下定義的 JSON 模式/屬性格式,且檔案副檔名必須為「.slconf」。
設定檔的屬性如下:
- captures: captureconfig 物件數組,表示有關每個捕獲位置的資訊。
- run_name:運行資訊。用於命名批次輸出。注意:包含以下字元可能會導致無法儲存 .fits 輸出檔案(度量影像和遮罩): “(*:<>?[|
- 註:關於運行元資料的註解。用於記錄保存。
- 版本:設定檔的版本。
每個 captureconfig 物件的屬性如下:
- image_paths:要分析的圖像(檔案)的路徑。
- source_field_angle_deg:光源的場角,單位為度。
- source_azimuth_angle_deg:光源的方位角,單位為度。
- source_comment:關於捕獲的評論,例如,來源超出了視野範圍。
在雜散光測試中,方位角和視場角表示光源相對於被測相機或裝置的位置。

官方JSON模式定義如下。
設定檔 JSON 模式
config.schema.json 的 JSON 編碼文字字串:
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "config.schema",
"type": "object",
"properties": {
"captures": {
"description": "Information about each capture position.",
"type": "array",
"items": [
{"$ref": "captureconfig.schema"
}
]
},
"run_name": {
"description": "Information about the run. This is used to name batch outputs.",
"type": "string"
},
"comment": {
"description": "A comment about the meta data of the run. This is used for record keeping.",
"type": "string"
},
"version": {
"description": "The version of the config format.",
"type": "integer",
"properties": {
"minimum": 1,
"maximum": 1
}
}
},
"required": [
"captures",
"run_name",
"version"
],
"unevaluatedProperties": false
}
“captureconfig”物件JSON模式
captureconfig.schema.json 的 JSON 編碼文字字串:
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "captureconfig.schema",
"type": "object",
"properties": {
"image_paths": {
"description": "The path to the image to analyze.",
"type": "string"
},
"source_field_angle_deg": {
"description": "The field angle of the source in degrees.",
"type": "number",
"minimum": 0,
"maximum": 180
},
"source_azimuth_angle_deg": {
"description": "The azimuth angle of the source in degrees.",
"type": "number",
"minimum": 0,
"exclusiveMaximum": 360
},
"source_comment": {
"description": "A comment about the capture, e.g., source is out of the FOV.",
"type": "string"
}
},
"required": [
"image_paths"
],
"unevaluatedProperties": false
}