nx_image_grade_v2.nx
buildroot/runtime/nx_image_grade_v2.nx
about
nx_image_grade_v2.nx -- landmark-aware image grading composer.
CAPABILITY_COMPLETENESS: PARTIAL
MISSING_CAPABILITIES:
- face keypoint detection (eye/nose/mouth within head bbox):
blocks nx_micro_expression's full invocation; v2 returns
head BBOX but doesn't yet sub-detect facial features
- hand keypoint detection / finger segmentation: blocks
nx_finger_count's full invocation
- pose joint-angle extraction: blocks nx_pose_naturalness
from running end-to-end
- VLM grader source (triangulation second-source)
COVERED (PROMOTED FROM v1):
- Segmenter + landmark labeler composed
- nx_silhouette_integrity invoked on torso blob -> SHARP /
SOFT / MELTED verdict
- nx_limb_count invoked with landmark output -> OK /
EXTRA / FLOATING_LIMB / MISSING / etc.
- Skin-localized Lab + ITA + undertone (same as v1)
- Skin coverage Q10 (same as v1)
- 6 anatomical-region bboxes exposed in report for caller
to feed downstream tier-axes
Composes:
nx_png_decoder + nx_jpeg_decoder (format dispatch)
nx_segmenter_classical (skin connected-components)
nx_landmark_anatomy (head/torso/arm/leg labeling)
nx_silhouette_integrity (melty detector on torso)
nx_limb_count (anatomy coherence)
nx_lab_from_rgb + nx_skin_tone_ita + nx_undertone_class
nx_verdict_phrase
genealogy_id: substrate_image_grade_v2_landmark_aware_2026_05_16
lineage_id: nx_image_grade_v2
dependencies 13 imports · 2 importers
diagram shows first 10 each side; +3 more imports, +0 more importers in the complete lists below.
imports: nx_syscalls.nxnx_runtime.nxnx_tier.nxnx_png_decoder.nxnx_jpeg_decoder.nxnx_verdict_phrase.nxnx_lab_from_rgb.nxnx_skin_tone_ita.nxnx_undertone_class.nxnx_segmenter_classical.nxnx_landmark_anatomy.nxnx_silhouette_integrity.nxnx_limb_count.nx
imported by: nx_actor_role_image_grader.nxnx_image_grade_cli.nx
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| 76 | struct NxIgv2AxisVerdict |
| 89 | struct NxIgv2Report |
consts
| 50 | const NX_MAGIC_1024: i64 = 1024 |
| 54 | const NX_IGV2_FORMAT_UNKNOWN: nx_int = 0 |
| 55 | const NX_IGV2_FORMAT_PNG: nx_int = 1 |
| 56 | const NX_IGV2_FORMAT_JPEG: nx_int = 2 |
| 58 | const NX_IGV2_OK: nx_int = 0 |
| 59 | const NX_IGV2_ERR_TOO_SHORT: nx_int = 1 |
| 60 | const NX_IGV2_ERR_UNKNOWN_FORMAT: nx_int = 2 |
| 61 | const NX_IGV2_ERR_DECODER: nx_int = 3 |
| 62 | const NX_IGV2_ERR_NULL_PIXELS: nx_int = 4 |
| 66 | const NX_IGV2_AXIS_OK: nx_int = 0 |
| 67 | const NX_IGV2_AXIS_PENDING_KEYPOINT: nx_int = 1 // need face/hand keypoint detection |
| 68 | const NX_IGV2_AXIS_PENDING_POSE_ESTIMATE: nx_int = 2 // need joint-angle extractor |
| 69 | const NX_IGV2_AXIS_PENDING_VLM: nx_int = 3 |
| 70 | const NX_IGV2_AXIS_NOT_APPLICABLE: nx_int = 4 |
| 71 | const NX_IGV2_AXIS_NO_SKIN_DETECTED: nx_int = 5 |
| 72 | const NX_IGV2_AXIS_INSUFFICIENT_LANDMARKS: nx_int = 6 |
| 85 | const NX_IGV2_AXIS_VERDICT_BYTES: nx_size = 48 |
| 108 | const NX_IGV2_REPORT_BYTES: nx_size = 112 |
| 111 | const NX_IGV2_AX_DIMENSIONS: nx_int = 0 |
| 112 | const NX_IGV2_AX_LUMINANCE: nx_int = 1 |
| 113 | const NX_IGV2_AX_SKIN_TONE_ITA: nx_int = 4 |
| 114 | const NX_IGV2_AX_UNDERTONE: nx_int = 12 |
| 115 | const NX_IGV2_AX_SILHOUETTE: nx_int = 28 |
| 116 | const NX_IGV2_AX_VEIN_SIGNAL: nx_int = 16 |
| 117 | const NX_IGV2_AX_SUBSURFACE: nx_int = 17 |
| 118 | const NX_IGV2_AX_MICRO_EXPRESSION: nx_int = 22 |
| 119 | const NX_IGV2_AX_LIMB_COUNT: nx_int = 25 |
| 120 | const NX_IGV2_AX_POSE_NATURALNESS: nx_int = 26 |
| 121 | const NX_IGV2_AX_FINGER_COUNT: nx_int = 24 |
| 122 | const NX_IGV2_AX_SHADOW_DIRECTION: nx_int = 23 |
| 123 | const NX_IGV2_AX_SURFACE_PLANE: nx_int = 27 |
| 124 | const NX_IGV2_AX_SKIN_COVERAGE: nx_int = 100 |
| 125 | const NX_IGV2_AX_LANDMARK_CONF: nx_int = 101 |
| 127 | const NX_IGV2_N_AXES: nx_int = 15 |
functions
| 131 | func _igv2_detect_format(buf: *u8, n: nx_int) -> nx_int |
| 152 | func _igv2_is_skin_pixel(r: nx_int, g: nx_int, b: nx_int) -> nx_int |
| 173 | func _igv2_set_axis(axes: *NxIgv2AxisVerdict, idx: nx_int, |
| 223 | func nx_image_grade_v2(input: *u8, input_size: nx_int) -> *NxIgv2Report |
| 508 | func main() -> nx_int |