Files
lamp-testbench/crates/tm30/tests/golden/lamp_L0005.json
T
grabowski 2a3f28001c Lamp testbench in Rust around the HPCS 6500
lampbench station / export / label / tm30 / calibrate replace the Python
lamp_station.py, lamp_export.py, label_printer.py, tm30.py and
calibration.py that lived in HPCS6500-py. The driver is a submodule
(HPCS6500/, like mppt-testbench). Workspace crates: tm30 (TM-30-18 port of
colour-science 0.4.7), brother-ql (raster protocol, byte-identical to
brother_ql) and lamp-label (QR + ID labels for the QL-820NWB).

Bundles are byte-identical to lamp_export.py's (golden tests); the station
runs end to end in a test against the simulated instrument.
2026-10-22 17:26:14 +07:00

941 lines
14 KiB
JSON

{
"name": "lamp_L0005",
"source": "L0005/spd.csv",
"generator": "crates/tm30/tools/golden.py (tm30.py + colour-science 0.4.7, numpy 2.5.1)",
"wavelengths": [
380.0,
381.92,
383.84,
385.76,
387.68,
389.6,
391.52,
393.44,
395.36,
397.28,
399.2,
401.12,
403.04,
404.96,
406.88,
408.8,
410.72,
412.64,
414.56,
416.48,
418.4,
420.32,
422.23,
424.15,
426.07,
427.99,
429.91,
431.83,
433.75,
435.67,
437.59,
439.51,
441.43,
443.35,
445.27,
447.19,
449.11,
451.03,
452.95,
454.87,
456.79,
458.71,
460.63,
462.55,
464.47,
466.39,
468.31,
470.23,
472.15,
474.07,
475.99,
477.91,
479.83,
481.75,
483.67,
485.59,
487.51,
489.43,
491.35,
493.27,
495.19,
497.11,
499.03,
500.95,
502.87,
504.79,
506.7,
508.62,
510.54,
512.46,
514.38,
516.3,
518.22,
520.14,
522.06,
523.98,
525.9,
527.82,
529.74,
531.66,
533.58,
535.5,
537.42,
539.34,
541.26,
543.18,
545.1,
547.02,
548.94,
550.86,
552.78,
554.7,
556.62,
558.54,
560.46,
562.38,
564.3,
566.22,
568.14,
570.06,
571.98,
573.9,
575.82,
577.74,
579.66,
581.58,
583.5,
585.42,
587.34,
589.26,
591.17,
593.09,
595.01,
596.93,
598.85,
600.77,
602.69,
604.61,
606.53,
608.45,
610.37,
612.29,
614.21,
616.13,
618.05,
619.97,
621.89,
623.81,
625.73,
627.65,
629.57,
631.49,
633.41,
635.33,
637.25,
639.17,
641.09,
643.01,
644.93,
646.85,
648.77,
650.69,
652.61,
654.53,
656.45,
658.37,
660.29,
662.21,
664.13,
666.05,
667.97,
669.89,
671.81,
673.72,
675.64,
677.56,
679.48,
681.4,
683.32,
685.24,
687.16,
689.08,
691.0,
692.92,
694.84,
696.76,
698.68,
700.6,
702.52,
704.44,
706.36,
708.28,
710.2,
712.12,
714.04,
715.96,
717.88,
719.8,
721.72,
723.64,
725.56,
727.48,
729.4,
731.32,
733.24,
735.16,
737.08,
739.0,
740.92,
742.84,
744.76,
746.68,
748.6,
750.52,
752.44,
754.36,
756.28,
758.19,
760.11,
762.03,
763.95,
765.87,
767.79,
769.71,
771.63,
773.55,
775.47,
777.39,
779.31,
781.23,
783.15,
785.07,
786.99,
788.91,
790.83,
792.75,
794.67,
796.59,
798.51,
800.43,
802.35,
804.27,
806.19,
808.11,
810.03,
811.95,
813.87,
815.79,
817.71,
819.63,
821.55,
823.47,
825.39,
827.31,
829.23,
831.15,
833.07,
834.99,
836.91,
838.83,
840.74,
842.66,
844.58,
846.5,
848.42,
850.34,
852.26,
854.18,
856.1,
858.02,
859.94,
861.86,
863.78,
865.7,
867.62,
869.54,
871.46,
873.38,
875.3,
877.22,
879.14,
881.06,
882.98,
884.9,
886.82,
888.74,
890.66,
892.58,
894.5,
896.42,
898.34,
900.26,
902.18,
904.1,
906.02,
907.94,
909.86,
911.78,
913.7,
915.62,
917.54,
919.46,
921.38,
923.3,
925.21,
927.13,
929.05,
930.97,
932.89,
934.81,
936.73,
938.65,
940.57,
942.49,
944.41,
946.33,
948.25,
950.17,
952.09,
954.01,
955.93,
957.85,
959.77,
961.69,
963.61,
965.53,
967.45,
969.37,
971.29,
973.21,
975.13,
977.05,
978.97,
980.89,
982.81,
984.73,
986.65,
988.57,
990.49,
992.41,
994.33,
996.25,
998.17,
1000.09,
1002.01,
1003.93,
1005.85,
1007.77,
1009.68,
1011.6,
1013.52,
1015.44,
1017.36,
1019.28,
1021.2,
1023.12,
1025.04,
1026.96,
1028.88,
1030.8,
1032.72,
1034.64,
1036.56,
1038.48,
1040.4,
1042.32,
1044.24,
1046.16,
1048.08,
1050.0
],
"values": [
1.4212,
1.7419,
2.10394,
2.5039,
2.93606,
3.39889,
3.93454,
4.49359,
5.01257,
5.54877,
6.10222,
6.68219,
7.29638,
7.93514,
8.5931,
9.24619,
9.90701,
10.5765,
11.2605,
11.9645,
12.6711,
13.3723,
14.0493,
14.6832,
15.2642,
15.8132,
16.3287,
16.8228,
17.2915,
17.7187,
18.0902,
18.382,
18.592,
18.7226,
18.7717,
18.7254,
18.576,
18.3075,
17.9185,
17.4157,
16.8156,
16.1356,
15.3893,
14.5937,
13.7699,
12.9462,
12.1419,
11.3762,
10.6482,
9.95964,
9.31169,
8.70815,
8.15366,
7.64294,
7.17184,
6.7373,
6.33889,
5.97612,
5.64597,
5.34316,
5.06612,
4.81743,
4.5986,
4.41061,
4.25218,
4.12103,
4.00659,
3.91643,
3.84879,
3.80346,
3.78055,
3.77986,
3.80314,
3.85078,
3.92727,
4.03001,
4.1484,
4.28763,
4.44921,
4.63099,
4.83077,
5.04765,
5.27833,
5.52389,
5.78306,
6.05418,
6.33638,
6.628,
6.92813,
7.23399,
7.54393,
7.85199,
8.15893,
8.46237,
8.76243,
9.05838,
9.34514,
9.62164,
9.88696,
10.1422,
10.3832,
10.6101,
10.8211,
11.0168,
11.1993,
11.3703,
11.5257,
11.6629,
11.7837,
11.8895,
11.9867,
12.0839,
12.1791,
12.2662,
12.3425,
12.4078,
12.466,
12.5214,
12.5754,
12.6259,
12.6736,
12.7215,
12.774,
12.8267,
12.8787,
12.9257,
12.9679,
13.0099,
13.0493,
13.0835,
13.1099,
13.1311,
13.152,
13.1756,
13.1982,
13.2152,
13.2243,
13.2288,
13.2301,
13.229,
13.2249,
13.2152,
13.2011,
13.1834,
13.1637,
13.1405,
13.1139,
13.0846,
13.0521,
13.0183,
12.9848,
12.952,
12.9178,
12.8833,
12.8484,
12.8136,
12.7792,
12.7453,
12.7269,
12.7075,
12.6719,
12.6317,
12.5835,
12.5284,
12.4656,
12.3945,
12.3165,
12.2371,
12.1585,
12.0817,
12.0042,
11.9194,
11.8265,
11.7284,
11.6272,
11.5246,
11.4206,
11.3115,
11.1987,
11.0818,
10.9611,
10.8384,
10.7141,
10.6129,
10.5113,
10.3846,
10.2555,
10.1236,
9.98873,
9.85281,
9.71633,
9.57892,
9.44182,
9.3028,
9.16146,
9.0168,
8.86908,
8.7203,
8.57196,
8.42654,
8.28341,
8.14124,
8.00103,
7.88435,
7.76788,
7.62763,
7.48411,
7.33895,
7.19535,
7.05608,
6.92023,
6.78589,
6.65214,
6.51794,
6.38389,
6.25089,
6.11966,
5.99129,
5.86632,
5.74305,
5.62101,
5.51761,
5.41342,
5.2914,
5.17006,
5.05095,
4.93334,
4.81606,
4.69915,
4.58222,
4.46642,
4.35285,
4.2409,
4.13,
4.01949,
3.90912,
3.81533,
3.72338,
3.61776,
3.51387,
3.41173,
3.31158,
3.21455,
3.12043,
3.02806,
2.9375,
2.84828,
2.76111,
2.67621,
2.5926,
2.52159,
2.45227,
2.37415,
2.29974,
2.22875,
2.16007,
2.09361,
2.02931,
1.96636,
1.90426,
1.84288,
1.78329,
1.72633,
1.6787,
1.63161,
1.57766,
1.52388,
1.47098,
1.41934,
1.36869,
1.32023,
1.27303,
1.22641,
1.1799,
1.13381,
1.0896,
1.05327,
1.01825,
0.979388,
0.941846,
0.904806,
0.868271,
0.832064,
0.796383,
0.76247,
0.731021,
0.701246,
0.676909,
0.653443,
0.626491,
0.599819,
0.573896,
0.548988,
0.525677,
0.503604,
0.482191,
0.461504,
0.441348,
0.423077,
0.407844,
0.392133,
0.373466,
0.35349,
0.333593,
0.315277,
0.29785,
0.282291,
0.267882,
0.254207,
0.243396,
0.232792,
0.220971,
0.210188,
0.20019,
0.190529,
0.181201,
0.172511,
0.164088,
0.156279,
0.149948,
0.143313,
0.135445,
0.127207,
0.119077,
0.111116,
0.103413,
0.0961485,
0.0889833,
0.0820498,
0.0763345,
0.0709253,
0.06507,
0.0600421,
0.0555066,
0.0511544,
0.0467442,
0.0422355,
0.0375999,
0.0324369,
0.0277513,
0.0233159,
0.0184905,
0.0141661,
0.010318,
0.0065234,
0.00339913,
0.00142989,
0.0003136,
1.21648e-05,
0.0
],
"expected": {
"Rf": 72.42846923570649,
"Rg": 115.48226172022527,
"CCT_K": 4242.020225454432,
"Duv": -0.061811178268578196,
"bins": [
{
"bin": 1,
"ref_a": 21.43410030670144,
"ref_b": 4.90142850266573,
"test_a": 21.754364677788764,
"test_b": 6.028959887700748,
"ref_a_norm": 0.9748367120906379,
"ref_b_norm": 0.22292013089964466,
"test_a_norm": 0.9894025423351167,
"test_b_norm": 0.27420098581954466,
"Rcs_pct": 2.4290350400222676,
"Rhs": 0.047453855159103865,
"Rf_h": 83.53674808568866
},
{
"bin": 2,
"ref_a": 20.63505113818434,
"ref_b": 14.283337677544614,
"test_a": 18.25222692435521,
"test_b": 16.891133889352687,
"ref_a_norm": 0.8222381933674561,
"ref_b_norm": 0.5691435261582284,
"test_a_norm": 0.7272905693673594,
"test_b_norm": 0.6730555364318426,
"Rcs_pct": -2.121564435516107,
"Rhs": 0.13914975248617142,
"Rf_h": 69.77968032788063
},
{
"bin": 3,
"ref_a": 14.629113610798417,
"ref_b": 22.260093628513623,
"test_a": 10.384327641547301,
"test_b": 26.11873592756626,
"ref_a_norm": 0.5492054713971743,
"ref_b_norm": 0.8356873519369594,
"test_a_norm": 0.38984792306958044,
"test_b_norm": 0.9805483133857796,
"Rcs_pct": 3.1913177195830578,
"Rhs": 0.21298139703299326,
"Rf_h": 57.54160217933594
},
{
"bin": 4,
"ref_a": 3.8423149103576013,
"ref_b": 22.109218102792415,
"test_a": -0.9720534930269555,
"test_b": 25.385903109075425,
"ref_a_norm": 0.17122151182532394,
"ref_b_norm": 0.9852325582765982,
"test_a_norm": -0.04331671727439753,
"test_b_norm": 1.131248429864524,
"Rcs_pct": 10.13558853588513,
"Rhs": 0.23890222059233687,
"Rf_h": 59.58909922550171
},
{
"bin": 5,
"ref_a": -2.186571142791434,
"ref_b": 19.142977633613715,
"test_a": -5.886837111970642,
"test_b": 21.93731981339119,
"ref_a_norm": -0.1134852290405945,
"ref_b_norm": 0.993539683550488,
"test_a_norm": -0.30553273337531833,
"test_b_norm": 1.1385688372257725,
"Rcs_pct": 17.970906861711207,
"Rhs": 0.16006358109743493,
"Rf_h": 67.34382626976937
},
{
"bin": 6,
"ref_a": -11.104600804688529,
"ref_b": 17.233883700252907,
"test_a": -13.97297513106531,
"test_b": 19.346249262977278,
"ref_a_norm": -0.5416434405814599,
"ref_b_norm": 0.8406083411881414,
"test_a_norm": -0.681552669768544,
"test_b_norm": 0.9436421171233145,
"Rcs_pct": 16.339885679194687,
"Rhs": 0.05908777364453933,
"Rf_h": 75.25377187782897
},
{
"bin": 7,
"ref_a": -18.189968167341636,
"ref_b": 11.354085705300378,
"test_a": -19.7206081839055,
"test_b": 12.529259563187352,
"ref_a_norm": -0.8483051075881072,
"ref_b_norm": 0.5295077378470778,
"test_a_norm": -0.9196878462484812,
"test_b_norm": 0.5843130006588837,
"Rcs_pct": 8.980075067009068,
"Rhs": -0.00591078587114994,
"Rf_h": 80.20887812533893
},
{
"bin": 8,
"ref_a": -22.71806289835211,
"ref_b": 3.7143225742842416,
"test_a": -24.447871024049007,
"test_b": 3.7241303377402764,
"ref_a_norm": -0.9868965798659958,
"ref_b_norm": 0.16135408469821927,
"test_a_norm": -1.0620412667485428,
"test_b_norm": 0.16178014427267345,
"Rcs_pct": 7.378392289449014,
"Rhs": 0.014242128202517721,
"Rf_h": 80.82561555010895
},
{
"bin": 9,
"ref_a": -19.347306328963583,
"ref_b": -2.026321281934058,
"test_a": -20.06625868011774,
"test_b": -2.2169511268986613,
"ref_a_norm": -0.9945601047642705,
"ref_b_norm": -0.10416428376023783,
"test_a_norm": -1.0315182897191424,
"test_b_norm": -0.1139637274324231,
"Rcs_pct": 3.8159820415743932,
"Rhs": 0.002400965905842326,
"Rf_h": 84.18920436335856
},
{
"bin": 10,
"ref_a": -20.196747504457814,
"ref_b": -11.155645978902756,
"test_a": -19.571913022466653,
"test_b": -11.983094867927717,
"ref_a_norm": -0.8753463645436907,
"ref_b_norm": -0.48349637235468895,
"test_a_norm": -0.8482654401457509,
"test_b_norm": -0.5193587990495737,
"Rcs_pct": -0.25928689544241135,
"Rhs": 0.04486387349837399,
"Rf_h": 78.41799259263864
},
{
"bin": 11,
"ref_a": -12.180252597877518,
"ref_b": -17.29419405143065,
"test_a": -8.685736053966526,
"test_b": -19.136347393141005,
"ref_a_norm": -0.5758178906963753,
"ref_b_norm": -0.8175779820628593,
"test_a_norm": -0.4106156398276985,
"test_b_norm": -0.9046652442554165,
"Rcs_pct": -1.937104087873796,
"Rhs": 0.18574374203064478,
"Rf_h": 70.11612314013637
},
{
"bin": 12,
"ref_a": -5.5063114456196685,
"ref_b": -23.660299840104926,
"test_a": 0.33801652790105613,
"test_b": -25.549448307177354,
"ref_a_norm": -0.22666642762606753,
"ref_b_norm": -0.973972448577082,
"test_a_norm": 0.013914396164214258,
"test_b_norm": -1.051738942266285,
"Rcs_pct": 2.9337241934789535,
"Rhs": 0.2511296210166835,
"Rf_h": 57.44257228382194
},
{
"bin": 13,
"ref_a": 3.5184320625342473,
"ref_b": -15.384072281892932,
"test_a": 8.171211821546612,
"test_b": -15.810559390232124,
"ref_a_norm": 0.22294961668953173,
"ref_b_norm": -0.9748299689781756,
"test_a_norm": 0.517778519273329,
"test_b_norm": -1.0018548299495602,
"Rcs_pct": 8.40238513904124,
"Rhs": 0.2838915590622778,
"Rf_h": 68.25214199751044
},
{
"bin": 14,
"ref_a": 13.818253230994431,
"ref_b": -18.69223347630265,
"test_a": 19.465715586791525,
"test_b": -18.5055601512992,
"ref_a_norm": 0.5944537830128539,
"ref_b_norm": -0.8041297779971259,
"test_a_norm": 0.8374045601990865,
"test_b_norm": -0.7960991924823818,
"Rcs_pct": 12.82990320691419,
"Rhs": 0.2064677427813491,
"Rf_h": 61.93860124627672
},
{
"bin": 15,
"ref_a": 15.249684263415222,
"ref_b": -11.146224476355433,
"test_a": 18.69153846700258,
"test_b": -10.85760757482259,
"ref_a_norm": 0.8073350187996868,
"ref_b_norm": -0.5900933548343934,
"test_a_norm": 0.9895505571780975,
"test_b_norm": -0.5748136593600464,
"Rcs_pct": 14.301773907584508,
"Rhs": 0.11393813158884211,
"Rf_h": 76.24421565028895
},
{
"bin": 16,
"ref_a": 20.000399536628798,
"ref_b": -3.7137039513672825,
"test_a": 21.4803892244034,
"test_b": -2.9898158247964486,
"ref_a_norm": 0.9831945245209823,
"ref_b_norm": -0.18256102254303758,
"test_a_norm": 1.0559489589862838,
"test_b_norm": -0.14697559130668933,
"Rcs_pct": 6.441410516864719,
"Rhs": 0.049095353201348696,
"Rf_h": 81.87695242384159
}
]
}
}