Repository navigation
Releases: changhwang/APIS
Releases · changhwang/APIS
Release list
APIS v0.1.4
APIS v0.1.4 Release Notes
Summary
This release updates the XPL calibration/search workflow so APIS can handle film that is not centered vertically, and tightens the app UI around the sequence controls.
Changed Since v0.1.3
- Local XPL search now checks both background ROIs during the coarse scan:
- bottom ROI:
x=700, y=1000, width=700, height=80 px - top ROI:
x=700, y=0, width=700, height=80 px
- bottom ROI:
- Fine XPL search and confirmation now focus on whichever ROI produced the darker signal.
- XPL confirmation now requires ROI mean
<=65and<=1.2xof the selected scan minimum. - Polarizer calibration now uses the same adaptive local XPL search path as sequence capture.
- Polarizer calibration now uses one calibration exposure setting instead of separate coarse/fine exposure settings.
- Calibration metadata and CSV logs now include structured detail for top/bottom ROI readings, selected ROI, and confirmation results.
- Sequence XPL capture starts from
HOME, moves the sample stage to0 deg, runs adaptive XPL search, then keeps the selected polarizer angle fixed while imaging. - Sequence cleanup returns the sample stage to
0 degwithout homing/resetting the polarizer. - Long calibration/status messages no longer resize the app window; full text remains available through the log and tooltip.
- Sequence control button sizing was adjusted so labels such as
START SEQUENCEdo not clip at the default window size.
Validation
python -m compileall app apis scriptspython -m unittest tests.test_ximea_raw16_sequence.\build\build.ps1 -Version 0.1.4
Notes
- Sequence capture remains
RAW16only. - RAW16 preview conversion remains available inside the APIS app.
- Reusing the same
SampleIDmay append to the existing CSV log.
APIS v0.1.3
Summary
This release updates the polarization workflow around PPL/XPL, adds a reusable polarizer calibration baseline, and sets validated default acquisition exposures for routine PPL/XPL imaging.
Added
- Polarization mode naming is now standardized to
PPL/XPLacross the app, sequence flow, and documentation. - Polarizer-angle calibration now performs a coarse scan plus a fine scan around the darkest XPL angle.
- Calibrated polarizer baseline values are saved and restored on later app launches.
- Reachable orthogonal-angle handling for PPL derivation from the calibrated XPL angle.
scripts/analyze_xpl_exposure_sweep.pyfor reviewing RAW16 XPL exposure-sweep datasets.- Release packaging now stages files before zipping to avoid transient file-lock failures during archive creation.
Changed
- Default validated acquisition baseline:
PPL:18000 usat polarizer5 degXPL:400000 usat polarizer95 deg
- Default polarizer calibration exposure:
200000 us
PPLis no longer chosen from a brightness search; it is derived from the reachable orthogonal angle relative toXPL.- Sequence output folders now use
pplandxpl. - Distribution and implementation docs now match the current PPL/XPL baseline and calibration flow.
Sequence Behavior
- Live camera preview is paused before sequence capture and restored afterward.
- Sequence capture remains
XI_RAW16only. - Sequence images are saved as Bayer RAW
uint16 TIFF. - Sequence outputs include:
{SampleID}_log.csv{SampleID}_metadata.json
- CSV logs now include calibration signal metrics used during XPL-angle selection.
Polarizer Calibration
- The calibration scan searches for the darkest
XPLangle first. - A coarse scan identifies the minimum region, then a fine scan refines the result around that angle.
PPLis assigned asXPL + 90 degorXPL - 90 deg, whichever stays inside the reachable polarizer range.- The resulting baseline is saved for reuse on later runs.
Conversion Tool
- Converts saved RAW16 TIFF datasets into RGB preview images.
- Processes the selected folder and its immediate child folders.
- Saves results into a sibling
_rgbfolder. - Uses demosaic plus fixed white balance plus gamma for preview generation.
Validation
python -m py_compile apis\\config.py apis\\io.py apis\\sequence.py apis\\utils.py app\\main.py app\\workers.py scripts\\analyze_xpl_exposure_sweep.py tests\\test_ximea_raw16_sequence.pypython -m unittest tests.test_ximea_raw16_sequence tests.test_mock_serial.\build\build.ps1 -Version 0.1.3
Notes
- Sequence capture is still
RAW16-only in this release. - Live view and Snapshot behavior are unchanged.
- Reusing the same
SampleIDmay append to the existing CSV log.
APIS v0.1.2
Summary
This release adds a RAW16-based XIMEA sequence workflow for quantitative imaging while keeping live view and normal snapshot behavior unchanged.
Added
- XIMEA sequence capture in
XI_RAW16 - Per-sequence JSON metadata output
- RAW16 to RGB8 preview conversion tool
- Automated tests for RAW16 sequence, cleanup, metadata, and conversion
Changed
- Live view remains
XI_RGB24 - Snapshot remains preview RGB TIFF
- Camera gamma is fixed to
1.0 - Sequence capture enforces
gain = 0 dB - Default validated sequence exposures:
- Normal / PPL:
18000 us - Crosspol / XPL:
50000 us
- Normal / PPL:
Sequence behavior
- Live camera thread is stopped before sequence capture and restored afterward
- Sequence images are saved as Bayer RAW
uint16 TIFF - Sequence outputs now include:
{SampleID}_log.csv{SampleID}_metadata.json
Conversion tool
- Converts saved RAW16 TIFF datasets into RGB8 preview images
- Processes the selected folder and its immediate child folders
- Saves results into a sibling
_rgbfolder - Uses demosaic + fixed white balance + gamma for preview generation
Validation
- Unit tests passed
- Hardware validation confirmed:
- RAW16 TIFF output
- JSON metadata generation
- Live-view recovery after sequence
- Exposure baseline validation for PPL/XPL
Notes
- Sequence capture is RAW16-only in this release
- RAW Snapshot is not included
- Reusing the same
SampleIDmay append to the existing CSV log
APIS v0.1.1
Highlights
- Calibration-based stage-angle handling in Python for both polarizer and sample axes
- Calibrated software limit set to 169 deg per stage while keeping the standard 0-180 Arduino servo command path
- Fixed XIMEA acquisition baseline for more consistent Normal/Crosspol comparison
- Auto white balance disabled during capture
- Fixed white balance: R=1.40, G=1.00, B=1.20
- Default exposures: Normal 12000 us, Crosspol 50000 us
- Added hardware documentation for full system reproduction
- Hardware implementation guide (wiring, calibration, verification)
- Hardware assembly guide (printed parts, bearings, gears, stack-up)
- Added STL part set for the current mechanical build
- Documented current mechanical build details including M3 screws and heat-set brass inserts
Distribution
- [APIS-win64-v0.1.1.zip]
- APIS/ (GUI app)
- check_hardware/ (console tool)
- [README.txt]
- [prereq_checklist.md]
Prerequisites
- XIMEA Windows Software Package (drivers + xiAPI) must be installed
- Arduino firmware must be flashed ([APIS_Firmware.ino])
Notes
- Keep the APIS folder intact; do not move APIS.exe out of it
- Current sequence convention:
- Crosspol = polarizer 90 deg
- Normal = polarizer 0 deg
- The current build uses calibrated stage-angle mapping with a software max of 169 deg per stage
- If the camera is not detected, verify XIMEA drivers and device recognition first
- Hardware reproduction details are documented in:
- docs/implementation_guide.md
- docs/hardware_assembly_guide.md
APIS v0.1.0
Highlights
- PyQt6 GUI with live view, manual control, and automated sequence capture
- Safe state handling (LATCHED/ARMED) with ESTOP / RESET / HOME
- Crosspol/Normal sequence modes with custom angles
- Snapshot capture with metadata logging
- Hardware check tool (check_hardware) included for quick Arduino/ESTOP validation
Distribution
- [APIS-win64-v0.1.0.zip]
- APIS/ (GUI app)
- check_hardware/ (console tool)
- [README.txt]
- [prereq_checklist.md]
Prerequisites
-
XIMEA Windows Software Package (drivers + xiAPI) must be installed
-
Arduino firmware must be flashed ([APIS_Firmware.ino])
Notes
- Keep the APIS folder intact; do not move [APIS.exe] out of it
- If camera is not detected, verify drivers and device recognition first