-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
35 lines (27 loc) · 979 Bytes
/
main.py
File metadata and controls
35 lines (27 loc) · 979 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
"""
Main pipeline for processing PIT data.
This script allows users to run specific steps of the workflow:
1. Confidence masking
2. Coregistration
3. ELC correction
Users can choose which steps to run by providing input when prompted.
"""
import json
from helpers.ConfidenceMasking import confidence_masking
from helpers.Coregistration import coregister_images
from helpers.ELC import run_ELC
# --- Load configuration ---
with open("config/config_test.json", "r") as f:
config = json.load(f)
# --- Ask user which steps to run ---
steps = input("Enter steps to run (comma-separated: masking, coreg, elc): ").lower().split(",")
# --- Run selected steps ---
if "masking" in steps:
# Pass only the 'confidence_masking' section
confidence_masking(config["confidence_masking"])
if "coreg" in steps:
# Pass only the 'coregistration' section
coregister_images(config["coregistration"])
if "elc" in steps:
# Pass only the 'ELC' section
run_ELC(config)