From 0ef860111e8a90e2561ce0521d7d765a8638678b Mon Sep 17 00:00:00 2001 From: Ayzen Date: Tue, 30 Sep 2025 20:00:07 +0300 Subject: [PATCH] fixed realtime processor settings managment --- .../core/processors/configs/bscan_config.json | 8 +- .../core/processors/websocket_handler.py | 8 +- .../ыфвф/info.json | 7 + .../ыфвф/sweep_data.json | 4007 +++++++++++++++++ .../js/modules/charts/chart-settings.js | 137 +- .../js/modules/settings/reference-manager.js | 3 +- 6 files changed, 4153 insertions(+), 17 deletions(-) create mode 100644 vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/info.json create mode 100644 vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/sweep_data.json diff --git a/vna_system/core/processors/configs/bscan_config.json b/vna_system/core/processors/configs/bscan_config.json index a785399..09dc665 100644 --- a/vna_system/core/processors/configs/bscan_config.json +++ b/vna_system/core/processors/configs/bscan_config.json @@ -1,9 +1,9 @@ { - "open_air": true, - "axis": "abs", + "open_air": false, + "axis": "real", "data_limitation": "ph_only_1", - "cut": 2.0, - "max": 5.0, + "cut": 0.816, + "max": 3.8, "gain": 0.0, "start_freq": 100.0, "stop_freq": 8800.0, diff --git a/vna_system/core/processors/websocket_handler.py b/vna_system/core/processors/websocket_handler.py index c5c6fd0..f9a9fc9 100644 --- a/vna_system/core/processors/websocket_handler.py +++ b/vna_system/core/processors/websocket_handler.py @@ -229,10 +229,10 @@ class ProcessorWebSocketHandler: - Schedule a coroutine on the main event loop to broadcast to clients. """ # Best-effort persistence - try: - self.data_storage.store_result(processor_id, result) - except Exception: # noqa: BLE001 - logger.error("Failed to store processor result") + # try: + # self.data_storage.store_result(processor_id, result) + # except Exception: # noqa: BLE001 + # logger.error("Failed to store processor result") # Broadcast to clients self._broadcast_result_sync(processor_id, result) diff --git a/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/info.json b/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/info.json new file mode 100644 index 0000000..ea56e9f --- /dev/null +++ b/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/info.json @@ -0,0 +1,7 @@ +{ + "name": "ыфвф", + "timestamp": "2025-09-30T19:05:27.995476", + "preset_filename": "s11_start100_stop8800_points1000_bw1khz.bin", + "description": "фывфф", + "metadata": {} +} \ No newline at end of file diff --git a/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/sweep_data.json b/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/sweep_data.json new file mode 100644 index 0000000..09e0857 --- /dev/null +++ b/vna_system/references/s11_start100_stop8800_points1000_bw1khz/ыфвф/sweep_data.json @@ -0,0 +1,4007 @@ +{ + "sweep_number": 67, + "timestamp": 1759248327.994871, + "points": [ + [ + -2.673879384994507, + 0.45034343004226685 + ], + [ + -2.665564775466919, + 0.5132015347480774 + ], + [ + -2.6562392711639404, + 0.5752959251403809 + ], + [ + -2.6446821689605713, + 0.6358242034912109 + ], + [ + -2.6333236694335938, + 0.6970512866973877 + ], + [ + -3.408785820007324, + 0.9246849417686462 + ], + [ + -3.3876516819000244, + 1.0040525197982788 + ], + [ + -3.374244451522827, + 1.084684133529663 + ], + [ + -3.3516764640808105, + 1.1570050716400146 + ], + [ + -3.3330862522125244, + 1.2333258390426636 + ], + [ + -3.3083014488220215, + 1.309332013130188 + ], + [ + -3.284208297729492, + 1.3882856369018555 + ], + [ + -3.254488229751587, + 1.4607384204864502 + ], + [ + -3.2371931076049805, + 1.5390441417694092 + ], + [ + -3.2086315155029297, + 1.6120179891586304 + ], + [ + -3.1759417057037354, + 1.685226321220398 + ], + [ + -3.1457161903381348, + 1.7634719610214233 + ], + [ + -3.112475872039795, + 1.8338654041290283 + ], + [ + -3.075394868850708, + 1.9123713970184326 + ], + [ + -3.043600559234619, + 1.9838560819625854 + ], + [ + -3.005908250808716, + 2.052231788635254 + ], + [ + -2.9622373580932617, + 2.12821626663208 + ], + [ + -2.925149440765381, + 2.2032980918884277 + ], + [ + -2.8833460807800293, + 2.2725327014923096 + ], + [ + -2.8391480445861816, + 2.348518133163452 + ], + [ + -2.804717540740967, + 2.4166269302368164 + ], + [ + -2.7576935291290283, + 2.4874813556671143 + ], + [ + -2.709815740585327, + 2.564314365386963 + ], + [ + -2.652087926864624, + 2.6336772441864014 + ], + [ + -2.6039083003997803, + 2.70566725730896 + ], + [ + -2.560753583908081, + 2.7710275650024414 + ], + [ + -2.506577491760254, + 2.8356523513793945 + ], + [ + -2.4525246620178223, + 2.9044108390808105 + ], + [ + -2.3930115699768066, + 2.9665348529815674 + ], + [ + -2.3343374729156494, + 3.0344104766845703 + ], + [ + -2.267408609390259, + 3.097536325454712 + ], + [ + -2.2010626792907715, + 3.165208339691162 + ], + [ + -2.13356876373291, + 3.229306221008301 + ], + [ + -2.062558174133301, + 3.2894792556762695 + ], + [ + -1.9834651947021484, + 3.3547801971435547 + ], + [ + -1.9199848175048828, + 3.41880202293396 + ], + [ + -1.8517569303512573, + 3.4686570167541504 + ], + [ + -1.7754768133163452, + 3.528714418411255 + ], + [ + -1.692772388458252, + 3.5916764736175537 + ], + [ + -1.6194324493408203, + 3.6505839824676514 + ], + [ + -1.5369288921356201, + 3.7023215293884277 + ], + [ + -1.4488952159881592, + 3.7636780738830566 + ], + [ + -1.3697415590286255, + 3.8133492469787598 + ], + [ + -1.272585153579712, + 3.8690595626831055 + ], + [ + -1.1829332113265991, + 3.9124248027801514 + ], + [ + -1.0945035219192505, + 3.96964430809021 + ], + [ + -1.0027365684509277, + 4.014543056488037 + ], + [ + -0.8978794813156128, + 4.056924343109131 + ], + [ + -0.8066017627716064, + 4.105841159820557 + ], + [ + -0.7010014653205872, + 4.148725986480713 + ], + [ + -0.6071116924285889, + 4.181036949157715 + ], + [ + -0.5035353899002075, + 4.222141265869141 + ], + [ + -0.4042413532733917, + 4.257031440734863 + ], + [ + -0.29538217186927795, + 4.294173240661621 + ], + [ + -0.1770361363887787, + 4.319832801818848 + ], + [ + -0.06393121927976608, + 4.345107555389404 + ], + [ + 0.0521436482667923, + 4.365540981292725 + ], + [ + 0.17723585665225983, + 4.387279510498047 + ], + [ + 0.3009042739868164, + 4.398560047149658 + ], + [ + 0.4162294268608093, + 4.4149885177612305 + ], + [ + 0.5414218306541443, + 4.426281452178955 + ], + [ + 0.6619608998298645, + 4.432175159454346 + ], + [ + 0.7908840775489807, + 4.429026126861572 + ], + [ + 0.9192125797271729, + 4.438940048217773 + ], + [ + 1.0528147220611572, + 4.43931245803833 + ], + [ + 1.187084436416626, + 4.434693336486816 + ], + [ + 1.320568323135376, + 4.412112712860107 + ], + [ + 1.455965280532837, + 4.395557403564453 + ], + [ + 1.5927037000656128, + 4.3799591064453125 + ], + [ + 1.720033049583435, + 4.353991985321045 + ], + [ + 1.8598345518112183, + 4.316638469696045 + ], + [ + 1.9871100187301636, + 4.291810989379883 + ], + [ + 2.1333563327789307, + 4.2548394203186035 + ], + [ + 2.262843132019043, + 4.210961818695068 + ], + [ + 2.3990073204040527, + 4.148233890533447 + ], + [ + 2.530311346054077, + 4.111722946166992 + ], + [ + 2.653146505355835, + 4.045919895172119 + ], + [ + 2.7889347076416016, + 3.9861161708831787 + ], + [ + 2.910874128341675, + 3.9228012561798096 + ], + [ + 3.0276811122894287, + 3.8459408283233643 + ], + [ + 3.151028871536255, + 3.777480363845825 + ], + [ + 3.263461112976074, + 3.6993637084960938 + ], + [ + 3.3852381706237793, + 3.612227201461792 + ], + [ + 3.4960968494415283, + 3.5268797874450684 + ], + [ + 3.606017589569092, + 3.4275991916656494 + ], + [ + 3.709500789642334, + 3.333488702774048 + ], + [ + 3.828979253768921, + 3.2225804328918457 + ], + [ + 3.936012029647827, + 3.118386745452881 + ], + [ + 4.042214870452881, + 2.992899179458618 + ], + [ + 4.159492492675781, + 2.8729279041290283 + ], + [ + 4.250351905822754, + 2.743238687515259 + ], + [ + 4.353085041046143, + 2.6222586631774902 + ], + [ + 4.432857036590576, + 2.4748873710632324 + ], + [ + 4.5283989906311035, + 2.346834897994995 + ], + [ + 4.592705726623535, + 2.2009799480438232 + ], + [ + 4.661201000213623, + 2.0621559619903564 + ], + [ + 4.729924201965332, + 1.9110386371612549 + ], + [ + 4.792031764984131, + 1.750780463218689 + ], + [ + 4.846599102020264, + 1.5891872644424438 + ], + [ + 4.898535251617432, + 1.433856725692749 + ], + [ + 4.940338611602783, + 1.270239233970642 + ], + [ + 4.986243724822998, + 1.1061490774154663 + ], + [ + 5.005819320678711, + 0.9476364850997925 + ], + [ + 5.041126251220703, + 0.7771790027618408 + ], + [ + 5.064940452575684, + 0.6043146252632141 + ], + [ + 5.068663120269775, + 0.4390215277671814 + ], + [ + 5.083299160003662, + 0.2741352617740631 + ], + [ + 5.073055744171143, + 0.11593249440193176 + ], + [ + 5.06704044342041, + -0.04944586381316185 + ], + [ + 5.052793979644775, + -0.22043561935424805 + ], + [ + 5.0263566970825195, + -0.3495676517486572 + ], + [ + 4.994487285614014, + -0.4987591803073883 + ], + [ + 4.962217807769775, + -0.6425657272338867 + ], + [ + 4.9122467041015625, + -0.7928994297981262 + ], + [ + 4.869486331939697, + -0.9357696771621704 + ], + [ + 4.809210300445557, + -1.0715595483779907 + ], + [ + 4.743401050567627, + -1.2213093042373657 + ], + [ + 4.671783924102783, + -1.3437674045562744 + ], + [ + 4.602938652038574, + -1.48027503490448 + ], + [ + 4.512936115264893, + -1.618385910987854 + ], + [ + 4.428931713104248, + -1.7421212196350098 + ], + [ + 4.3417582511901855, + -1.881231427192688 + ], + [ + 4.232879161834717, + -2.001862049102783 + ], + [ + 4.149479866027832, + -2.1439719200134277 + ], + [ + 4.0595011711120605, + -2.272122383117676 + ], + [ + 3.9512648582458496, + -2.3875467777252197 + ], + [ + 3.8581342697143555, + -2.5228688716888428 + ], + [ + 3.762732982635498, + -2.6366007328033447 + ], + [ + 3.6464927196502686, + -2.7398312091827393 + ], + [ + 3.559253692626953, + -2.8458285331726074 + ], + [ + 3.455227851867676, + -2.9311623573303223 + ], + [ + 3.3625669479370117, + -3.0143961906433105 + ], + [ + 3.2669677734375, + -3.0804855823516846 + ], + [ + 3.158651828765869, + -3.144343614578247 + ], + [ + 3.0619277954101562, + -3.1974668502807617 + ], + [ + 2.9550182819366455, + -3.2283501625061035 + ], + [ + 2.8579578399658203, + -3.272095203399658 + ], + [ + 2.7438817024230957, + -3.288590431213379 + ], + [ + 2.632884979248047, + -3.3115603923797607 + ], + [ + 2.5266706943511963, + -3.335301399230957 + ], + [ + 2.4161088466644287, + -3.344374656677246 + ], + [ + 2.2963662147521973, + -3.3497982025146484 + ], + [ + 2.20406436920166, + -3.374359130859375 + ], + [ + 2.081284523010254, + -3.370788812637329 + ], + [ + 1.9641565084457397, + -3.3766164779663086 + ], + [ + 1.857128381729126, + -3.3900036811828613 + ], + [ + 1.7390642166137695, + -3.4058279991149902 + ], + [ + 1.617970585823059, + -3.4290106296539307 + ], + [ + 1.4687310457229614, + -3.624319314956665 + ], + [ + 1.362749695777893, + -3.633251905441284 + ], + [ + 1.2741098403930664, + -3.6283628940582275 + ], + [ + 1.18071448802948, + -3.606994867324829 + ], + [ + 1.0760998725891113, + -3.6149966716766357 + ], + [ + 0.9784203171730042, + -3.5972657203674316 + ], + [ + 0.8746886253356934, + -3.5940520763397217 + ], + [ + 0.7832847237586975, + -3.5804407596588135 + ], + [ + 0.6931656002998352, + -3.5708134174346924 + ], + [ + 0.5935088396072388, + -3.5525197982788086 + ], + [ + 0.5003278255462646, + -3.538074254989624 + ], + [ + 0.41882550716400146, + -3.5180845260620117 + ], + [ + 0.33230820298194885, + -3.49902081489563 + ], + [ + 0.24515210092067719, + -3.477196455001831 + ], + [ + 0.1677747517824173, + -3.456658363342285 + ], + [ + 0.08423208445310593, + -3.428090810775757 + ], + [ + 0.011858844198286533, + -3.4017374515533447 + ], + [ + -0.06709910184144974, + -3.388357639312744 + ], + [ + -0.13392968475818634, + -3.354372024536133 + ], + [ + -0.2137821465730667, + -3.3338277339935303 + ], + [ + -0.27141350507736206, + -3.301431179046631 + ], + [ + -0.34108468890190125, + -3.2709739208221436 + ], + [ + -0.40503084659576416, + -3.2414400577545166 + ], + [ + -0.4653622508049011, + -3.2145814895629883 + ], + [ + -0.5247371196746826, + -3.1862998008728027 + ], + [ + -0.5936928987503052, + -3.166163444519043 + ], + [ + -0.6431136131286621, + -3.1275603771209717 + ], + [ + -0.7077580094337463, + -3.0955002307891846 + ], + [ + -0.7667393684387207, + -3.0675458908081055 + ], + [ + -0.8179530501365662, + -3.0280628204345703 + ], + [ + -0.8716320395469666, + -2.997732639312744 + ], + [ + -0.9280540943145752, + -2.9686062335968018 + ], + [ + -0.9804704189300537, + -2.9257874488830566 + ], + [ + -1.0337542295455933, + -2.8916916847229004 + ], + [ + -1.0876811742782593, + -2.856269598007202 + ], + [ + -1.136438250541687, + -2.826388359069824 + ], + [ + -1.184805989265442, + -2.7858495712280273 + ], + [ + -1.2272425889968872, + -2.757347583770752 + ], + [ + -1.2829912900924683, + -2.7208495140075684 + ], + [ + -1.325449824333191, + -2.6815381050109863 + ], + [ + -1.3709875345230103, + -2.6459105014801025 + ], + [ + -1.4041738510131836, + -2.6106929779052734 + ], + [ + -1.4512306451797485, + -2.5705690383911133 + ], + [ + -1.4903404712677002, + -2.526524066925049 + ], + [ + -1.5316119194030762, + -2.481710195541382 + ], + [ + -1.5743186473846436, + -2.4385969638824463 + ], + [ + -1.5706182718276978, + -2.370633125305176 + ], + [ + -1.6049416065216064, + -2.3218040466308594 + ], + [ + -1.6659789085388184, + -2.273040771484375 + ], + [ + -1.7092821598052979, + -2.228924512863159 + ], + [ + -1.7485969066619873, + -2.1746435165405273 + ], + [ + -1.802674412727356, + -2.1232852935791016 + ], + [ + -1.8392478227615356, + -2.0685882568359375 + ], + [ + -1.8861421346664429, + -2.018838405609131 + ], + [ + -1.934127926826477, + -1.9663031101226807 + ], + [ + -1.9703720808029175, + -1.9212241172790527 + ], + [ + -2.009040117263794, + -1.865545630455017 + ], + [ + -2.047513961791992, + -1.8177233934402466 + ], + [ + -2.0835931301116943, + -1.7655282020568848 + ], + [ + -2.119816541671753, + -1.7118792533874512 + ], + [ + -2.1515088081359863, + -1.664065957069397 + ], + [ + -2.1793034076690674, + -1.6158039569854736 + ], + [ + -2.212163209915161, + -1.5620038509368896 + ], + [ + -2.2409889698028564, + -1.5100774765014648 + ], + [ + -2.263092279434204, + -1.4652581214904785 + ], + [ + -2.287264108657837, + -1.41200852394104 + ], + [ + -2.305711269378662, + -1.3661179542541504 + ], + [ + -2.321873664855957, + -1.3157360553741455 + ], + [ + -2.339871406555176, + -1.2637181282043457 + ], + [ + -2.35886812210083, + -1.2176247835159302 + ], + [ + -2.3700602054595947, + -1.1690919399261475 + ], + [ + -2.3754584789276123, + -1.1199049949645996 + ], + [ + -2.393494129180908, + -1.0706475973129272 + ], + [ + -2.4034526348114014, + -1.0239976644515991 + ], + [ + -2.4095988273620605, + -0.972332775592804 + ], + [ + -2.4206724166870117, + -0.9194153547286987 + ], + [ + -2.430724859237671, + -0.8669642210006714 + ], + [ + -2.4377670288085938, + -0.8104314208030701 + ], + [ + -2.4484314918518066, + -0.7516742944717407 + ], + [ + -2.460961103439331, + -0.6976881623268127 + ], + [ + -2.468679189682007, + -0.6368488669395447 + ], + [ + -2.480379343032837, + -0.5759366154670715 + ], + [ + -2.4899849891662598, + -0.5174520611763 + ], + [ + -2.5027356147766113, + -0.4548189043998718 + ], + [ + -2.5142810344696045, + -0.3932490944862366 + ], + [ + -2.5238053798675537, + -0.3335418105125427 + ], + [ + -2.5324041843414307, + -0.276204377412796 + ], + [ + -2.539215326309204, + -0.2156970351934433 + ], + [ + -2.542572259902954, + -0.15971730649471283 + ], + [ + -2.5296359062194824, + -0.10425982624292374 + ], + [ + -2.52449631690979, + -0.050281889736652374 + ], + [ + -2.5211164951324463, + 0.004174203146249056 + ], + [ + -2.5173285007476807, + 0.059319138526916504 + ], + [ + -2.510463237762451, + 0.11573084443807602 + ], + [ + -2.5025923252105713, + 0.17167647182941437 + ], + [ + -2.497792959213257, + 0.2303711324930191 + ], + [ + -2.489349126815796, + 0.2895134687423706 + ], + [ + -2.479904890060425, + 0.34109875559806824 + ], + [ + -2.4701199531555176, + 0.40159907937049866 + ], + [ + -2.463653564453125, + 0.4622311592102051 + ], + [ + -2.4544804096221924, + 0.5223498344421387 + ], + [ + -2.447765350341797, + 0.5838895440101624 + ], + [ + -2.4287049770355225, + 0.6349610090255737 + ], + [ + -2.4196906089782715, + 0.6967796683311462 + ], + [ + -2.4106693267822266, + 0.7584748864173889 + ], + [ + -2.4031991958618164, + 0.8201522827148438 + ], + [ + -2.3979146480560303, + 0.8800861239433289 + ], + [ + -2.376051425933838, + 0.9322449564933777 + ], + [ + -2.3657712936401367, + 0.9919634461402893 + ], + [ + -2.3582258224487305, + 1.0505867004394531 + ], + [ + -2.351317882537842, + 1.106482744216919 + ], + [ + -2.3440840244293213, + 1.1615136861801147 + ], + [ + -2.3203561305999756, + 1.2171612977981567 + ], + [ + -2.3095641136169434, + 1.2682719230651855 + ], + [ + -2.2988338470458984, + 1.3202928304672241 + ], + [ + -2.291278600692749, + 1.3614782094955444 + ], + [ + -2.2775325775146484, + 1.4010944366455078 + ], + [ + -2.258916139602661, + 1.434198021888733 + ], + [ + -2.238499402999878, + 1.4946768283843994 + ], + [ + -2.219085931777954, + 1.5282800197601318 + ], + [ + -2.1960160732269287, + 1.5650825500488281 + ], + [ + -2.1671013832092285, + 1.591500163078308 + ], + [ + -2.1325128078460693, + 1.6241987943649292 + ], + [ + -2.1067535877227783, + 1.6761174201965332 + ], + [ + -2.067854642868042, + 1.7115031480789185 + ], + [ + -2.023430109024048, + 1.7450233697891235 + ], + [ + -1.9752942323684692, + 1.7777637243270874 + ], + [ + -1.916222095489502, + 1.8176367282867432 + ], + [ + -1.8555419445037842, + 1.8670443296432495 + ], + [ + -1.8258215188980103, + 1.9063886404037476 + ], + [ + -1.761204719543457, + 1.9511314630508423 + ], + [ + -1.7035105228424072, + 1.9974887371063232 + ], + [ + -1.6367671489715576, + 2.0577280521392822 + ], + [ + -1.5695029497146606, + 2.1217477321624756 + ], + [ + -1.5235545635223389, + 2.162782669067383 + ], + [ + -1.4554104804992676, + 2.2185702323913574 + ], + [ + -1.4032678604125977, + 2.2791388034820557 + ], + [ + -1.3324105739593506, + 2.338758707046509 + ], + [ + -1.2848204374313354, + 2.411426067352295 + ], + [ + -1.2287544012069702, + 2.4896321296691895 + ], + [ + -1.173365592956543, + 2.526703357696533 + ], + [ + -1.1185193061828613, + 2.595423698425293 + ], + [ + -1.0647169351577759, + 2.650475025177002 + ], + [ + -1.0099823474884033, + 2.7081618309020996 + ], + [ + -0.9608904123306274, + 2.768918752670288 + ], + [ + -0.8971781730651855, + 2.8038394451141357 + ], + [ + -0.8410267233848572, + 2.8551831245422363 + ], + [ + -0.7773101925849915, + 2.915147066116333 + ], + [ + -0.7195039987564087, + 2.9536867141723633 + ], + [ + -0.6551497578620911, + 3.0029428005218506 + ], + [ + -0.5919046998023987, + 3.051692247390747 + ], + [ + -0.5440273880958557, + 3.0789635181427 + ], + [ + -0.4503094553947449, + 3.1162612438201904 + ], + [ + -0.3799096643924713, + 3.1508800983428955 + ], + [ + -0.3111131191253662, + 3.189399242401123 + ], + [ + -0.23611898720264435, + 3.2169549465179443 + ], + [ + -0.15617500245571136, + 3.24678373336792 + ], + [ + -0.09169376641511917, + 3.259803295135498 + ], + [ + 0.0028818307910114527, + 3.284752368927002 + ], + [ + 0.08263864368200302, + 3.298041582107544 + ], + [ + 0.16084763407707214, + 3.32407808303833 + ], + [ + 0.24488799273967743, + 3.343198776245117 + ], + [ + 0.31564781069755554, + 3.3371710777282715 + ], + [ + 0.39630359411239624, + 3.341456174850464 + ], + [ + 0.6032431721687317, + 3.210148811340332 + ], + [ + 0.6945414543151855, + 3.2114758491516113 + ], + [ + 0.7918944954872131, + 3.2103960514068604 + ], + [ + 0.8945416212081909, + 3.2117373943328857 + ], + [ + 0.9892821311950684, + 3.2014405727386475 + ], + [ + 1.0842889547348022, + 3.1943845748901367 + ], + [ + 1.170902132987976, + 3.184906482696533 + ], + [ + 1.2928799390792847, + 3.1667885780334473 + ], + [ + 1.3809318542480469, + 3.1416678428649902 + ], + [ + 1.4716544151306152, + 3.1202166080474854 + ], + [ + 1.5592331886291504, + 3.0978963375091553 + ], + [ + 1.6439768075942993, + 3.0650079250335693 + ], + [ + 1.7668354511260986, + 3.0342068672180176 + ], + [ + 1.847901701927185, + 2.9935247898101807 + ], + [ + 1.9218064546585083, + 2.9485843181610107 + ], + [ + 2.010770797729492, + 2.903829574584961 + ], + [ + 2.0900180339813232, + 2.8472299575805664 + ], + [ + 2.1859140396118164, + 2.8008530139923096 + ], + [ + 2.2605395317077637, + 2.7346692085266113 + ], + [ + 2.3314590454101562, + 2.666731357574463 + ], + [ + 2.3972525596618652, + 2.5947012901306152 + ], + [ + 2.4742352962493896, + 2.5113847255706787 + ], + [ + 2.5521860122680664, + 2.4445176124572754 + ], + [ + 2.6182398796081543, + 2.3601315021514893 + ], + [ + 2.6870596408843994, + 2.2711894512176514 + ], + [ + 2.746469020843506, + 2.176966667175293 + ], + [ + 2.816293478012085, + 2.0760059356689453 + ], + [ + 2.8847930431365967, + 1.974202036857605 + ], + [ + 2.940298557281494, + 1.89357590675354 + ], + [ + 2.999443292617798, + 1.791290283203125 + ], + [ + 3.0588841438293457, + 1.682450294494629 + ], + [ + 3.119178533554077, + 1.5757489204406738 + ], + [ + 3.175814151763916, + 1.4693280458450317 + ], + [ + 3.216240167617798, + 1.3761863708496094 + ], + [ + 3.265913248062134, + 1.26282799243927 + ], + [ + 3.3107104301452637, + 1.1616498231887817 + ], + [ + 3.352593183517456, + 1.0597248077392578 + ], + [ + 3.391913890838623, + 0.9530385732650757 + ], + [ + 3.4278626441955566, + 0.8558634519577026 + ], + [ + 3.4503982067108154, + 0.7600604891777039 + ], + [ + 3.4739460945129395, + 0.6653347611427307 + ], + [ + 3.4932570457458496, + 0.5702391862869263 + ], + [ + 3.505308151245117, + 0.4774516820907593 + ], + [ + 3.5117928981781006, + 0.38872990012168884 + ], + [ + 3.513148307800293, + 0.2994142472743988 + ], + [ + 3.5127177238464355, + 0.21363747119903564 + ], + [ + 3.5036277770996094, + 0.1244107261300087 + ], + [ + 3.4906601905822754, + 0.03618241474032402 + ], + [ + 3.4728100299835205, + -0.05454164743423462 + ], + [ + 3.451603889465332, + -0.14589978754520416 + ], + [ + 3.4271371364593506, + -0.24253228306770325 + ], + [ + 3.400449752807617, + -0.33144593238830566 + ], + [ + 3.373833179473877, + -0.4298672080039978 + ], + [ + 3.3446218967437744, + -0.5290217399597168 + ], + [ + 3.3209564685821533, + -0.631708025932312 + ], + [ + 3.2965176105499268, + -0.7369712591171265 + ], + [ + 3.279282331466675, + -0.8396831750869751 + ], + [ + 3.273404359817505, + -0.9402376413345337 + ], + [ + 3.242584705352783, + -1.0311659574508667 + ], + [ + 3.2361438274383545, + -1.1230831146240234 + ], + [ + 3.2374422550201416, + -1.1989103555679321 + ], + [ + 3.2275705337524414, + -1.272014856338501 + ], + [ + 3.219716787338257, + -1.3295764923095703 + ], + [ + 3.2115652561187744, + -1.3698656558990479 + ], + [ + 3.1908953189849854, + -1.4314398765563965 + ], + [ + 3.1716551780700684, + -1.4696811437606812 + ], + [ + 3.133413553237915, + -1.503006100654602 + ], + [ + 3.100367546081543, + -1.5341663360595703 + ], + [ + 3.0614242553710938, + -1.5612390041351318 + ], + [ + 3.007091999053955, + -1.5961450338363647 + ], + [ + 2.9426236152648926, + -1.6102468967437744 + ], + [ + 2.8916096687316895, + -1.6491425037384033 + ], + [ + 2.821396589279175, + -1.6719636917114258 + ], + [ + 2.752002000808716, + -1.707094669342041 + ], + [ + 2.6947555541992188, + -1.7423508167266846 + ], + [ + 2.635885715484619, + -1.7783761024475098 + ], + [ + 2.5609309673309326, + -1.812219262123108 + ], + [ + 2.487571954727173, + -1.8455934524536133 + ], + [ + 2.4256062507629395, + -1.8693386316299438 + ], + [ + 2.346987724304199, + -1.901849389076233 + ], + [ + 2.2617437839508057, + -1.9412846565246582 + ], + [ + 2.1899423599243164, + -1.9786001443862915 + ], + [ + 2.111798048019409, + -2.0206687450408936 + ], + [ + 2.0369999408721924, + -2.072073221206665 + ], + [ + 1.956707239151001, + -2.1196560859680176 + ], + [ + 1.9012460708618164, + -2.165464401245117 + ], + [ + 1.8240058422088623, + -2.217679023742676 + ], + [ + 1.755162239074707, + -2.264065742492676 + ], + [ + 1.6958938837051392, + -2.3075742721557617 + ], + [ + 1.6362764835357666, + -2.366138458251953 + ], + [ + 1.5645216703414917, + -2.4183194637298584 + ], + [ + 1.518439531326294, + -2.459367513656616 + ], + [ + 1.4661810398101807, + -2.502366065979004 + ], + [ + 1.5158418416976929, + -2.437701940536499 + ], + [ + 1.4430205821990967, + -2.4615871906280518 + ], + [ + 1.374841570854187, + -2.4857852458953857 + ], + [ + 1.2952051162719727, + -2.5167973041534424 + ], + [ + 1.217679500579834, + -2.5461368560791016 + ], + [ + 1.1602590084075928, + -2.5608296394348145 + ], + [ + 1.1193971633911133, + -2.5743284225463867 + ], + [ + 1.0498968362808228, + -2.592916965484619 + ], + [ + 0.9949187636375427, + -2.6239101886749268 + ], + [ + 0.9256278872489929, + -2.6455769538879395 + ], + [ + 0.8601546883583069, + -2.6704983711242676 + ], + [ + 0.7871147394180298, + -2.6898694038391113 + ], + [ + 0.753436803817749, + -2.6816515922546387 + ], + [ + 0.6850923895835876, + -2.6972899436950684 + ], + [ + 0.6326475143432617, + -2.710496187210083 + ], + [ + 0.5722131133079529, + -2.7282631397247314 + ], + [ + 0.5149729251861572, + -2.7543177604675293 + ], + [ + 0.4643811583518982, + -2.765561819076538 + ], + [ + 0.39999568462371826, + -2.736865282058716 + ], + [ + 0.3441928029060364, + -2.755094289779663 + ], + [ + 0.2889079451560974, + -2.7649292945861816 + ], + [ + 0.24312511086463928, + -2.76983380317688 + ], + [ + 0.2022274136543274, + -2.7808477878570557 + ], + [ + 0.1464477926492691, + -2.786886692047119 + ], + [ + 0.08174329996109009, + -2.7667346000671387 + ], + [ + 0.035222239792346954, + -2.770958423614502 + ], + [ + -0.002817871980369091, + -2.7700884342193604 + ], + [ + -0.045333147048950195, + -2.77578067779541 + ], + [ + -0.0905364379286766, + -2.7706751823425293 + ], + [ + -0.12939555943012238, + -2.753854274749756 + ], + [ + -0.20060096681118011, + -2.7440102100372314 + ], + [ + -0.24258339405059814, + -2.745410203933716 + ], + [ + -0.2899944484233856, + -2.7372796535491943 + ], + [ + -0.3251279294490814, + -2.733071804046631 + ], + [ + -0.36782142519950867, + -2.7163705825805664 + ], + [ + -0.4008866250514984, + -2.7052881717681885 + ], + [ + -0.4412674009799957, + -2.6776134967803955 + ], + [ + -0.5018724203109741, + -2.6713051795959473 + ], + [ + -0.5385190844535828, + -2.655921459197998 + ], + [ + -0.5797053575515747, + -2.6479568481445312 + ], + [ + -0.6080065369606018, + -2.632046937942505 + ], + [ + -0.6550417542457581, + -2.6023025512695312 + ], + [ + -0.6893910765647888, + -2.579710006713867 + ], + [ + -0.7386165857315063, + -2.578834056854248 + ], + [ + -0.7798205018043518, + -2.548426389694214 + ], + [ + -0.8105757236480713, + -2.5228211879730225 + ], + [ + -0.8480023145675659, + -2.497105836868286 + ], + [ + -0.8817964792251587, + -2.4660966396331787 + ], + [ + -0.9231424331665039, + -2.436702251434326 + ], + [ + -0.9598646759986877, + -2.4042510986328125 + ], + [ + -0.9997817873954773, + -2.400123357772827 + ], + [ + -1.0435855388641357, + -2.3613216876983643 + ], + [ + -1.081380844116211, + -2.3248984813690186 + ], + [ + -1.1231592893600464, + -2.2859790325164795 + ], + [ + -1.173890233039856, + -2.249624490737915 + ], + [ + -1.2226743698120117, + -2.2161126136779785 + ], + [ + -1.287166714668274, + -2.1753547191619873 + ], + [ + -1.3016976118087769, + -2.158297300338745 + ], + [ + -1.3480045795440674, + -2.1187527179718018 + ], + [ + -1.3953943252563477, + -2.07719087600708 + ], + [ + -1.4545598030090332, + -2.0497326850891113 + ], + [ + -1.5125001668930054, + -2.0183627605438232 + ], + [ + -1.5684632062911987, + -1.9979150295257568 + ], + [ + -1.6217223405838013, + -1.9727489948272705 + ], + [ + -1.677498459815979, + -1.955116629600525 + ], + [ + -1.702416181564331, + -1.911095142364502 + ], + [ + -1.7554208040237427, + -1.8870742321014404 + ], + [ + -1.805309534072876, + -1.8704710006713867 + ], + [ + -1.8491032123565674, + -1.853888988494873 + ], + [ + -1.8928778171539307, + -1.8379619121551514 + ], + [ + -1.9314547777175903, + -1.8280348777770996 + ], + [ + -1.9654933214187622, + -1.811942458152771 + ], + [ + -2.002817392349243, + -1.7691670656204224 + ], + [ + -2.041670560836792, + -1.7502009868621826 + ], + [ + -2.0706353187561035, + -1.7361234426498413 + ], + [ + -2.093374252319336, + -1.7156755924224854 + ], + [ + -2.1135308742523193, + -1.696468472480774 + ], + [ + -2.134767532348633, + -1.676099419593811 + ], + [ + -2.1529181003570557, + -1.65422523021698 + ], + [ + -2.161452293395996, + -1.6221623420715332 + ], + [ + -2.209280014038086, + -1.5803214311599731 + ], + [ + -2.224235773086548, + -1.555343747138977 + ], + [ + -2.240346908569336, + -1.5157535076141357 + ], + [ + -2.2539288997650146, + -1.4778640270233154 + ], + [ + -2.7827720642089844, + -1.911102294921875 + ], + [ + -2.8201467990875244, + -1.869498610496521 + ], + [ + -2.8565616607666016, + -1.822503924369812 + ], + [ + -2.8926382064819336, + -1.765484094619751 + ], + [ + -2.926426410675049, + -1.7074424028396606 + ], + [ + -2.9659109115600586, + -1.6530169248580933 + ], + [ + -3.004871129989624, + -1.5961601734161377 + ], + [ + -3.0376739501953125, + -1.5297824144363403 + ], + [ + -3.0678367614746094, + -1.4701228141784668 + ], + [ + -3.1023812294006348, + -1.409132480621338 + ], + [ + -3.137296199798584, + -1.3445252180099487 + ], + [ + -3.169431447982788, + -1.2731881141662598 + ], + [ + -1.9431064128875732, + -0.6906207799911499 + ], + [ + -1.9608728885650635, + -0.6475919485092163 + ], + [ + -1.9759193658828735, + -0.6033298373222351 + ], + [ + -1.989857792854309, + -0.5574836730957031 + ], + [ + -2.0046322345733643, + -0.5133157968521118 + ], + [ + -2.0176141262054443, + -0.4667280614376068 + ], + [ + -2.029890537261963, + -0.41899555921554565 + ], + [ + -2.040055274963379, + -0.3710392415523529 + ], + [ + -2.0497424602508545, + -0.32220837473869324 + ], + [ + -2.058206081390381, + -0.27302277088165283 + ], + [ + -2.0658907890319824, + -0.2230430245399475 + ], + [ + -2.071608781814575, + -0.17310315370559692 + ], + [ + -2.0770859718322754, + -0.122914157807827 + ], + [ + -2.0814807415008545, + -0.07351361215114594 + ], + [ + -2.0836598873138428, + -0.023191766813397408 + ], + [ + -2.0826895236968994, + 0.029797911643981934 + ], + [ + -2.0836341381073, + 0.07909835875034332 + ], + [ + -2.082091808319092, + 0.1305580586194992 + ], + [ + -2.079831838607788, + 0.18091236054897308 + ], + [ + -2.0760655403137207, + 0.23257263004779816 + ], + [ + -2.0731794834136963, + 0.284938782453537 + ], + [ + -2.066438674926758, + 0.33633360266685486 + ], + [ + -2.0599539279937744, + 0.3868623971939087 + ], + [ + -2.050075054168701, + 0.4372195303440094 + ], + [ + -2.0401763916015625, + 0.4874071776866913 + ], + [ + -2.0293216705322266, + 0.5389388203620911 + ], + [ + -2.0208351612091064, + 0.5901783108711243 + ], + [ + -2.004997968673706, + 0.6415860056877136 + ], + [ + -1.9898439645767212, + 0.6891674995422363 + ], + [ + -1.9716616868972778, + 0.7416689991950989 + ], + [ + -1.9525744915008545, + 0.7907543778419495 + ], + [ + -1.9332375526428223, + 0.8438668251037598 + ], + [ + -1.913996696472168, + 0.8874861598014832 + ], + [ + -1.8907991647720337, + 0.9381811618804932 + ], + [ + -1.866302251815796, + 0.9876819252967834 + ], + [ + -1.8425092697143555, + 1.0335773229599 + ], + [ + -1.813812494277954, + 1.0814974308013916 + ], + [ + -1.7877576351165771, + 1.1295219659805298 + ], + [ + -1.7631217241287231, + 1.17141592502594 + ], + [ + -1.73313570022583, + 1.2169731855392456 + ], + [ + -1.7011988162994385, + 1.2714091539382935 + ], + [ + -1.6639213562011719, + 1.306943416595459 + ], + [ + -1.6323145627975464, + 1.3508708477020264 + ], + [ + -1.5929765701293945, + 1.3929574489593506 + ], + [ + -1.5539312362670898, + 1.4322718381881714 + ], + [ + -1.5236287117004395, + 1.4742146730422974 + ], + [ + -1.4822911024093628, + 1.5060850381851196 + ], + [ + -1.4448297023773193, + 1.5492397546768188 + ], + [ + -1.4060431718826294, + 1.58462655544281 + ], + [ + -1.3611215353012085, + 1.6255407333374023 + ], + [ + -1.3241493701934814, + 1.6539429426193237 + ], + [ + -1.2689343690872192, + 1.6859380006790161 + ], + [ + -1.2381850481033325, + 1.7177824974060059 + ], + [ + -1.194074034690857, + 1.7520418167114258 + ], + [ + -1.1491423845291138, + 1.7852462530136108 + ], + [ + -1.1039953231811523, + 1.8114522695541382 + ], + [ + -1.0607413053512573, + 1.8308024406433105 + ], + [ + -1.0142507553100586, + 1.852925181388855 + ], + [ + -0.9557077288627625, + 1.8850469589233398 + ], + [ + -0.9180520176887512, + 1.9068809747695923 + ], + [ + -0.8812049627304077, + 1.9246915578842163 + ], + [ + -0.822360634803772, + 1.9474653005599976 + ], + [ + -0.7804776430130005, + 1.9609335660934448 + ], + [ + -0.7332459092140198, + 1.9803617000579834 + ], + [ + -0.674475908279419, + 1.9977799654006958 + ], + [ + -0.6336607933044434, + 2.009939432144165 + ], + [ + -0.5799455642700195, + 2.0227601528167725 + ], + [ + -0.5320523381233215, + 2.0304696559906006 + ], + [ + -0.48106062412261963, + 2.035276412963867 + ], + [ + -0.43670377135276794, + 2.051649808883667 + ], + [ + -0.3758656680583954, + 2.0422871112823486 + ], + [ + -0.33736300468444824, + 2.058194398880005 + ], + [ + -0.2900923490524292, + 2.0589771270751953 + ], + [ + -0.23239955306053162, + 2.055549144744873 + ], + [ + -0.18483519554138184, + 2.0667684078216553 + ], + [ + -0.12722714245319366, + 2.067822217941284 + ], + [ + -0.06862516701221466, + 2.063431739807129 + ], + [ + -0.015123934485018253, + 2.0644099712371826 + ], + [ + 0.030928008258342743, + 2.067495107650757 + ], + [ + 0.09127835929393768, + 2.063350200653076 + ], + [ + 0.13529576361179352, + 2.0660927295684814 + ], + [ + 0.1849118024110794, + 2.0574159622192383 + ], + [ + 0.23018145561218262, + 2.050771474838257 + ], + [ + 0.289027601480484, + 2.0300488471984863 + ], + [ + 0.3391689658164978, + 2.0200464725494385 + ], + [ + 0.40182599425315857, + 2.0158586502075195 + ], + [ + 0.44075316190719604, + 1.998063325881958 + ], + [ + 0.49597930908203125, + 1.9728323221206665 + ], + [ + 0.5408308506011963, + 1.9566659927368164 + ], + [ + 0.5957908630371094, + 1.9359196424484253 + ], + [ + 0.6341782212257385, + 1.9183156490325928 + ], + [ + 0.6886486411094666, + 1.8998762369155884 + ], + [ + 0.7372673153877258, + 1.8791358470916748 + ], + [ + 0.7851836085319519, + 1.854367971420288 + ], + [ + 0.831741988658905, + 1.8239606618881226 + ], + [ + 0.8762319684028625, + 1.7912583351135254 + ], + [ + 0.9320883750915527, + 1.76921808719635 + ], + [ + 0.9838749170303345, + 1.7458168268203735 + ], + [ + 1.0260305404663086, + 1.7094637155532837 + ], + [ + 1.0700156688690186, + 1.6772642135620117 + ], + [ + 1.1227588653564453, + 1.6382092237472534 + ], + [ + 1.163109540939331, + 1.6123778820037842 + ], + [ + 1.2070971727371216, + 1.5757298469543457 + ], + [ + 1.246800184249878, + 1.5337655544281006 + ], + [ + 1.2821485996246338, + 1.5053163766860962 + ], + [ + 1.3273814916610718, + 1.4638346433639526 + ], + [ + 1.368068814277649, + 1.4244567155838013 + ], + [ + 1.41217839717865, + 1.3832087516784668 + ], + [ + 1.448974847793579, + 1.3404016494750977 + ], + [ + 1.482162356376648, + 1.296686053276062 + ], + [ + 1.5193276405334473, + 1.2548013925552368 + ], + [ + 1.5538455247879028, + 1.209206461906433 + ], + [ + 1.5850876569747925, + 1.1652491092681885 + ], + [ + 1.6263158321380615, + 1.1171597242355347 + ], + [ + 1.6573079824447632, + 1.0729808807373047 + ], + [ + 1.6826426982879639, + 1.023290753364563 + ], + [ + 1.7142287492752075, + 0.978568434715271 + ], + [ + 1.7451101541519165, + 0.9293307065963745 + ], + [ + 1.7685964107513428, + 0.8814813494682312 + ], + [ + 1.7971667051315308, + 0.8324535489082336 + ], + [ + 1.8214480876922607, + 0.7781585454940796 + ], + [ + 1.8444955348968506, + 0.7306589484214783 + ], + [ + 1.8706496953964233, + 0.6765663027763367 + ], + [ + 1.8898853063583374, + 0.6253588795661926 + ], + [ + 1.9118601083755493, + 0.5722693800926208 + ], + [ + 1.9302058219909668, + 0.5198811888694763 + ], + [ + 1.947145700454712, + 0.46527406573295593 + ], + [ + 1.965453863143921, + 0.4096638560295105 + ], + [ + 1.9805258512496948, + 0.35491102933883667 + ], + [ + 1.9924898147583008, + 0.30033454298973083 + ], + [ + 2.004241466522217, + 0.24494512379169464 + ], + [ + 2.015066385269165, + 0.18898533284664154 + ], + [ + 2.022773027420044, + 0.13293732702732086 + ], + [ + 2.031710147857666, + 0.0769147276878357 + ], + [ + 2.0372190475463867, + 0.01908448152244091 + ], + [ + 2.040909767150879, + -0.035074759274721146 + ], + [ + 2.0440638065338135, + -0.08935869485139847 + ], + [ + 2.047966241836548, + -0.14466224610805511 + ], + [ + 2.0473921298980713, + -0.19172322750091553 + ], + [ + 2.046835422515869, + -0.24784305691719055 + ], + [ + 2.0443944931030273, + -0.29899999499320984 + ], + [ + 2.042672634124756, + -0.3583148419857025 + ], + [ + 2.038681745529175, + -0.41062209010124207 + ], + [ + 2.029522180557251, + -0.46813541650772095 + ], + [ + 2.022932291030884, + -0.5243436694145203 + ], + [ + 2.0160176753997803, + -0.576770544052124 + ], + [ + 2.0059802532196045, + -0.6276736855506897 + ], + [ + 1.9878891706466675, + -0.6887748837471008 + ], + [ + 1.9868382215499878, + -0.7337639927864075 + ], + [ + 1.9695417881011963, + -0.7927341461181641 + ], + [ + 1.9534540176391602, + -0.8334392309188843 + ], + [ + 1.937059760093689, + -0.8926897644996643 + ], + [ + 1.9200162887573242, + -0.9392163157463074 + ], + [ + 1.9015607833862305, + -0.9966413378715515 + ], + [ + 1.8859161138534546, + -1.0481314659118652 + ], + [ + 1.8678964376449585, + -1.0979235172271729 + ], + [ + 1.8450133800506592, + -1.1438063383102417 + ], + [ + 1.8242247104644775, + -1.1958235502243042 + ], + [ + 1.7922215461730957, + -1.244111180305481 + ], + [ + 1.7661068439483643, + -1.2846626043319702 + ], + [ + 1.735505223274231, + -1.3262171745300293 + ], + [ + 1.7078253030776978, + -1.3778356313705444 + ], + [ + 1.6779425144195557, + -1.4151180982589722 + ], + [ + 1.64871084690094, + -1.4715179204940796 + ], + [ + 1.6129841804504395, + -1.5053656101226807 + ], + [ + 1.5836549997329712, + -1.5487159490585327 + ], + [ + 1.5471584796905518, + -1.5870716571807861 + ], + [ + 1.5098284482955933, + -1.6321276426315308 + ], + [ + 1.4612634181976318, + -1.6517654657363892 + ], + [ + 1.4303957223892212, + -1.6830366849899292 + ], + [ + 1.3779003620147705, + -1.7157574892044067 + ], + [ + 1.3377851247787476, + -1.7537962198257446 + ], + [ + 1.303261160850525, + -1.781805157661438 + ], + [ + 1.2698436975479126, + -1.8086180686950684 + ], + [ + 1.2165939807891846, + -1.8441859483718872 + ], + [ + 1.1808315515518188, + -1.868228554725647 + ], + [ + 1.1294984817504883, + -1.894709825515747 + ], + [ + 1.0916029214859009, + -1.927372932434082 + ], + [ + 1.0195517539978027, + -1.9014862775802612 + ], + [ + 0.9749638438224792, + -1.9138243198394775 + ], + [ + 0.9320724010467529, + -1.9449403285980225 + ], + [ + 0.8791441321372986, + -1.9673694372177124 + ], + [ + 0.849484384059906, + -2.0042386054992676 + ], + [ + 0.8075143098831177, + -2.0405232906341553 + ], + [ + 0.7785810232162476, + -2.086521625518799 + ], + [ + 0.7204858660697937, + -2.1270697116851807 + ], + [ + 0.6627941727638245, + -2.1575982570648193 + ], + [ + 0.6147179007530212, + -2.2019026279449463 + ], + [ + 0.526021420955658, + -2.176147937774658 + ], + [ + 0.44810962677001953, + -2.1708192825317383 + ], + [ + 0.3606488108634949, + -2.1802165508270264 + ], + [ + 0.25244030356407166, + -2.160471200942993 + ], + [ + 0.12187284231185913, + -2.1265501976013184 + ], + [ + -0.05309205502271652, + -2.02766752243042 + ], + [ + -0.23650498688220978, + -1.8923842906951904 + ], + [ + -0.378227174282074, + -1.7500911951065063 + ], + [ + -0.4845530092716217, + -1.6284940242767334 + ], + [ + -0.5329082012176514, + -1.5847606658935547 + ], + [ + -0.5538867712020874, + -1.575793743133545 + ], + [ + -0.6084126234054565, + -1.9024738073349 + ], + [ + -0.633672297000885, + -1.956154704093933 + ], + [ + -0.6567145586013794, + -1.9704457521438599 + ], + [ + -0.675355076789856, + -1.9371675252914429 + ], + [ + -0.6828770041465759, + -1.8625471591949463 + ], + [ + -0.6685677170753479, + -1.7828258275985718 + ], + [ + -0.6524471640586853, + -1.7008553743362427 + ], + [ + -0.6222482323646545, + -1.6155303716659546 + ], + [ + -0.5879253149032593, + -1.531545877456665 + ], + [ + -0.5463774800300598, + -1.470475435256958 + ], + [ + -0.5017487406730652, + -1.4306631088256836 + ], + [ + -0.5819907188415527, + -1.5277762413024902 + ], + [ + -0.5471396446228027, + -1.472273349761963 + ], + [ + -0.5352677702903748, + -1.4421628713607788 + ], + [ + -0.5009836554527283, + -1.42885422706604 + ], + [ + -0.4958421289920807, + -1.4589509963989258 + ], + [ + -0.549737811088562, + -1.5556272268295288 + ], + [ + -0.6609029173851013, + -1.7138975858688354 + ], + [ + -0.8199916481971741, + -1.907806634902954 + ], + [ + -0.9792655110359192, + -2.076702833175659 + ], + [ + -1.104825735092163, + -2.160984992980957 + ], + [ + -1.2024871110916138, + -2.176417827606201 + ], + [ + -1.2831171751022339, + -2.1586129665374756 + ], + [ + -1.298262596130371, + -2.1198177337646484 + ], + [ + -1.3795892000198364, + -2.1025054454803467 + ], + [ + -1.4601125717163086, + -2.0592188835144043 + ], + [ + -1.5200345516204834, + -2.010713577270508 + ], + [ + -1.584712266921997, + -1.952749252319336 + ], + [ + -1.6362184286117554, + -1.894748330116272 + ], + [ + -1.6799736022949219, + -1.831517219543457 + ], + [ + -1.7152293920516968, + -1.723393201828003 + ], + [ + -1.7381972074508667, + -1.6471476554870605 + ], + [ + -1.7520257234573364, + -1.5716354846954346 + ], + [ + -1.7664263248443604, + -1.5178518295288086 + ], + [ + -1.79789137840271, + -1.4903546571731567 + ], + [ + -1.8716315031051636, + -1.4893171787261963 + ], + [ + -1.9291502237319946, + -1.4853469133377075 + ], + [ + -1.9937034845352173, + -1.4773945808410645 + ], + [ + -2.0492889881134033, + -1.485238790512085 + ], + [ + -2.1199405193328857, + -1.5014959573745728 + ], + [ + -2.2032034397125244, + -1.4964275360107422 + ], + [ + -2.2781496047973633, + -1.4943405389785767 + ], + [ + -2.3481667041778564, + -1.4608793258666992 + ], + [ + -2.4154863357543945, + -1.4208773374557495 + ], + [ + -2.479438304901123, + -1.3767651319503784 + ], + [ + -2.542043447494507, + -1.3173489570617676 + ], + [ + -2.589993715286255, + -1.255146861076355 + ], + [ + -2.632763147354126, + -1.201883316040039 + ], + [ + -2.6865274906158447, + -1.1386297941207886 + ], + [ + -2.7308905124664307, + -1.0707415342330933 + ], + [ + -2.7759697437286377, + -0.9952607154846191 + ], + [ + -2.8055944442749023, + -0.9207450747489929 + ], + [ + -2.8327479362487793, + -0.849988579750061 + ], + [ + -2.860353469848633, + -0.7765509486198425 + ], + [ + -2.8793654441833496, + -0.7026222348213196 + ], + [ + -2.892465829849243, + -0.6272369027137756 + ], + [ + -2.902817487716675, + -0.5555972456932068 + ], + [ + -2.9116790294647217, + -0.48349758982658386 + ], + [ + -2.918236017227173, + -0.4074442684650421 + ], + [ + -2.9187958240509033, + -0.3345179855823517 + ], + [ + -3.0101253986358643, + -0.25093960762023926 + ], + [ + -3.0223467350006104, + -0.17107868194580078 + ], + [ + -3.026792526245117, + -0.09443966299295425 + ], + [ + -3.038479804992676, + -0.016458474099636078 + ], + [ + -3.035649299621582, + 0.05776268243789673 + ], + [ + -3.0316102504730225, + 0.13476750254631042 + ], + [ + -3.0221798419952393, + 0.21070967614650726 + ], + [ + -3.0166234970092773, + 0.2850847840309143 + ], + [ + -3.0040411949157715, + 0.3545473515987396 + ], + [ + -2.998262643814087, + 0.4311525821685791 + ], + [ + -2.985095739364624, + 0.5032853484153748 + ], + [ + -2.9656307697296143, + 0.573911726474762 + ], + [ + -2.9509856700897217, + 0.6478416323661804 + ], + [ + -2.9774582386016846, + 0.7544730305671692 + ], + [ + -2.9581856727600098, + 0.8233698606491089 + ], + [ + -2.9304726123809814, + 0.8984294533729553 + ], + [ + -2.9223520755767822, + 0.9659346342086792 + ], + [ + -2.8962745666503906, + 1.0306555032730103 + ], + [ + -2.877412796020508, + 1.1024197340011597 + ], + [ + -2.860436201095581, + 1.1722915172576904 + ], + [ + -2.8302507400512695, + 1.2420697212219238 + ], + [ + -2.8050360679626465, + 1.3129205703735352 + ], + [ + -2.7693519592285156, + 1.4080904722213745 + ], + [ + -2.7252252101898193, + 1.4853971004486084 + ], + [ + -2.6674158573150635, + 1.561537504196167 + ], + [ + -2.60815691947937, + 1.621754765510559 + ], + [ + -2.5493781566619873, + 1.6656687259674072 + ], + [ + -2.489377737045288, + 1.7383959293365479 + ], + [ + -2.443174123764038, + 1.7692310810089111 + ], + [ + -2.391227960586548, + 1.8020970821380615 + ], + [ + -2.355318069458008, + 1.8413567543029785 + ], + [ + -2.319249153137207, + 1.8797041177749634 + ], + [ + -2.2623488903045654, + 1.9189950227737427 + ], + [ + -2.2191598415374756, + 1.9580657482147217 + ], + [ + -2.178715467453003, + 1.9959529638290405 + ], + [ + -2.119974136352539, + 2.041602849960327 + ], + [ + -2.0622687339782715, + 2.078333854675293 + ], + [ + -2.023862838745117, + 2.1061837673187256 + ], + [ + -1.9819486141204834, + 2.152911424636841 + ], + [ + -1.9198423624038696, + 2.183983564376831 + ], + [ + -1.8616220951080322, + 2.2092113494873047 + ], + [ + -1.8226842880249023, + 2.2510716915130615 + ], + [ + -1.7609449625015259, + 2.281665563583374 + ], + [ + -1.693050503730774, + 2.303267478942871 + ], + [ + -1.6543574333190918, + 2.3424506187438965 + ], + [ + -1.5970817804336548, + 2.3649210929870605 + ], + [ + -1.530425786972046, + 2.368894338607788 + ], + [ + -1.4838554859161377, + 2.396942377090454 + ], + [ + -1.422627329826355, + 2.408193349838257 + ], + [ + -1.3622794151306152, + 2.4297618865966797 + ], + [ + -1.2955546379089355, + 2.454420804977417 + ], + [ + -1.2403985261917114, + 2.463020086288452 + ], + [ + -1.171358585357666, + 2.4794552326202393 + ], + [ + -1.1004438400268555, + 2.4838457107543945 + ], + [ + -1.0331093072891235, + 2.496394157409668 + ], + [ + -0.9815578460693359, + 2.5124824047088623 + ], + [ + -0.9362171292304993, + 2.5201120376586914 + ], + [ + -0.8720076084136963, + 2.511498212814331 + ], + [ + -0.8413461446762085, + 2.5292160511016846 + ], + [ + -0.7750102281570435, + 2.5176007747650146 + ], + [ + -0.7149544954299927, + 2.5295608043670654 + ], + [ + -0.671284556388855, + 2.537451982498169 + ], + [ + -0.6259118318557739, + 2.5280368328094482 + ], + [ + -0.5742679834365845, + 2.538456678390503 + ], + [ + -0.5358436703681946, + 2.5423471927642822 + ], + [ + -0.48490989208221436, + 2.542586326599121 + ], + [ + -0.44473209977149963, + 2.546142816543579 + ], + [ + -0.3934434950351715, + 2.5208518505096436 + ], + [ + -0.3398311138153076, + 2.5201871395111084 + ], + [ + -0.2993241548538208, + 2.528916835784912 + ], + [ + -0.2501712739467621, + 2.5498993396759033 + ], + [ + -0.20875194668769836, + 2.5158941745758057 + ], + [ + -0.15772129595279694, + 2.559781074523926 + ], + [ + -0.12056411802768707, + 2.5678799152374268 + ], + [ + -0.06543491780757904, + 2.5306167602539062 + ], + [ + 0.005234293639659882, + 2.518563747406006 + ], + [ + 0.052930597215890884, + 2.5447611808776855 + ], + [ + 0.10923980176448822, + 2.5415525436401367 + ], + [ + 0.1518799513578415, + 2.5466232299804688 + ], + [ + 0.2312612533569336, + 2.5277135372161865 + ], + [ + 0.2884332239627838, + 2.539086103439331 + ], + [ + 0.3282262682914734, + 2.519498109817505 + ], + [ + 0.40646541118621826, + 2.5215442180633545 + ], + [ + 0.45107632875442505, + 2.5107197761535645 + ], + [ + 0.5308259725570679, + 2.4964487552642822 + ], + [ + 0.5767718553543091, + 2.4823317527770996 + ], + [ + 0.6441046595573425, + 2.4694926738739014 + ], + [ + 0.7121195793151855, + 2.4577736854553223 + ], + [ + 0.7660779356956482, + 2.4471077919006348 + ], + [ + 0.8346983194351196, + 2.414515972137451 + ], + [ + 0.8925744295120239, + 2.4052786827087402 + ], + [ + 0.9734922051429749, + 2.3771371841430664 + ], + [ + 1.0217409133911133, + 2.361171007156372 + ], + [ + 1.0866529941558838, + 2.3218815326690674 + ], + [ + 1.1571775674819946, + 2.3004720211029053 + ], + [ + 1.2106231451034546, + 2.274348020553589 + ], + [ + 1.2767994403839111, + 2.245527505874634 + ], + [ + 1.3425474166870117, + 2.2045857906341553 + ], + [ + 1.4005872011184692, + 2.172541618347168 + ], + [ + 1.448798656463623, + 2.1453299522399902 + ], + [ + 1.5147812366485596, + 2.0981967449188232 + ], + [ + 1.5746650695800781, + 2.085909366607666 + ], + [ + 1.6324917078018188, + 2.0319557189941406 + ], + [ + 1.6980937719345093, + 1.995584487915039 + ], + [ + 1.7542548179626465, + 1.946749210357666 + ], + [ + 1.8138316869735718, + 1.9029030799865723 + ], + [ + 1.864791750907898, + 1.8639050722122192 + ], + [ + 1.9165326356887817, + 1.8098610639572144 + ], + [ + 1.979564905166626, + 1.7670280933380127 + ], + [ + 2.0401179790496826, + 1.7173961400985718 + ], + [ + 2.08520770072937, + 1.663623332977295 + ], + [ + 2.134101152420044, + 1.609822392463684 + ], + [ + 2.182267427444458, + 1.5627154111862183 + ], + [ + 2.240908145904541, + 1.5109940767288208 + ], + [ + 2.2912609577178955, + 1.4485622644424438 + ], + [ + 2.3446643352508545, + 1.3925657272338867 + ], + [ + 2.383392095565796, + 1.3304764032363892 + ], + [ + 2.432049512863159, + 1.2756415605545044 + ], + [ + 2.4659271240234375, + 1.2147940397262573 + ], + [ + 2.5242176055908203, + 1.161635160446167 + ], + [ + 2.567708730697632, + 1.087670087814331 + ], + [ + 2.6048314571380615, + 1.0211224555969238 + ], + [ + 2.6506543159484863, + 0.9463127255439758 + ], + [ + 2.6974620819091797, + 0.8756498098373413 + ], + [ + 2.7212371826171875, + 0.8186050057411194 + ], + [ + 2.7481672763824463, + 0.745904266834259 + ], + [ + 2.794951915740967, + 0.6796261072158813 + ], + [ + 2.826310873031616, + 0.6060991287231445 + ], + [ + 2.8582327365875244, + 0.5235772132873535 + ], + [ + 2.890470027923584, + 0.4465790390968323 + ], + [ + 2.916278600692749, + 0.3639524281024933 + ], + [ + 2.9442710876464844, + 0.2763388156890869 + ], + [ + 2.974216938018799, + 0.192255437374115 + ], + [ + 2.9987754821777344, + 0.10285664349794388 + ], + [ + 3.022555112838745, + 0.00858770776540041 + ], + [ + 3.0467159748077393, + -0.07881409674882889 + ], + [ + 3.0488224029541016, + -0.14931350946426392 + ], + [ + 3.063749313354492, + -0.2508717179298401 + ], + [ + 3.075169324874878, + -0.3409633934497833 + ], + [ + 3.0771260261535645, + -0.4268382489681244 + ], + [ + 3.0978245735168457, + -0.5200355052947998 + ], + [ + 3.098001718521118, + -0.6176422238349915 + ], + [ + 3.0996530055999756, + -0.7199413180351257 + ], + [ + 3.092864990234375, + -0.8187753558158875 + ], + [ + 3.0958383083343506, + -0.9250320196151733 + ], + [ + 3.0881073474884033, + -1.0330142974853516 + ], + [ + 3.078226089477539, + -1.1312776803970337 + ], + [ + 3.0724833011627197, + -1.2435870170593262 + ], + [ + 3.079737901687622, + -1.3417354822158813 + ], + [ + 3.0078694820404053, + -1.4375965595245361 + ], + [ + 3.009146213531494, + -1.5663940906524658 + ], + [ + 2.965874433517456, + -1.6621694564819336 + ], + [ + 2.9289886951446533, + -1.7721500396728516 + ], + [ + 2.8844597339630127, + -1.8680769205093384 + ], + [ + 2.8588693141937256, + -1.9923861026763916 + ], + [ + 2.8172430992126465, + -2.082726240158081 + ], + [ + 2.7544071674346924, + -2.1967368125915527 + ], + [ + 2.7051470279693604, + -2.3034956455230713 + ], + [ + 2.6379764080047607, + -2.4324865341186523 + ], + [ + 2.558474540710449, + -2.5422937870025635 + ], + [ + 2.471386671066284, + -2.6357181072235107 + ], + [ + 2.3823559284210205, + -2.754545211791992 + ], + [ + 2.2651026248931885, + -2.8015880584716797 + ], + [ + 2.2152745723724365, + -2.918107748031616 + ], + [ + 2.1001737117767334, + -3.017451763153076 + ], + [ + 1.966606616973877, + -3.1447527408599854 + ], + [ + 1.903632640838623, + -3.218885898590088 + ], + [ + 1.7814874649047852, + -3.3170831203460693 + ], + [ + 1.6630516052246094, + -3.3639731407165527 + ], + [ + 1.5284147262573242, + -3.4312703609466553 + ], + [ + 1.3823412656784058, + -3.5063681602478027 + ], + [ + 1.2275278568267822, + -3.560445547103882 + ], + [ + 1.0397803783416748, + -3.593855619430542 + ], + [ + 0.8758334517478943, + -3.5980522632598877 + ], + [ + 0.6644202470779419, + -3.6194090843200684 + ], + [ + 0.4410528838634491, + -3.6239709854125977 + ], + [ + 0.4547095000743866, + -3.715928316116333 + ], + [ + 0.3494267463684082, + -3.801729917526245 + ], + [ + 0.19944539666175842, + -3.856053352355957 + ], + [ + 0.04670459404587746, + -3.894422769546509 + ], + [ + -0.09681452065706253, + -3.946538209915161 + ], + [ + -0.2401135414838791, + -3.99469256401062 + ], + [ + -0.41141700744628906, + -4.027231693267822 + ], + [ + -0.594424843788147, + -4.011796474456787 + ], + [ + -0.7545819282531738, + -3.9666550159454346 + ], + [ + -0.9487808346748352, + -3.9010508060455322 + ], + [ + -1.1231809854507446, + -3.8510947227478027 + ], + [ + -1.3436819314956665, + -3.765307664871216 + ], + [ + -1.521907925605774, + -3.6597251892089844 + ], + [ + -3.1263885498046875, + -7.112203121185303 + ], + [ + -3.2177417278289795, + -7.479513645172119 + ], + [ + -3.480865240097046, + -7.546562194824219 + ], + [ + -3.874922037124634, + -7.529038429260254 + ], + [ + -4.151881694793701, + -7.543000221252441 + ], + [ + -4.538069725036621, + -7.542847633361816 + ], + [ + -4.803671360015869, + -7.3437676429748535 + ], + [ + -5.123751640319824, + -7.284602642059326 + ], + [ + -5.400559902191162, + -7.112001419067383 + ], + [ + -5.716497898101807, + -6.920029640197754 + ], + [ + -5.968345642089844, + -6.674455642700195 + ], + [ + -6.225388526916504, + -6.427611351013184 + ], + [ + -6.427318572998047, + -6.14524507522583 + ], + [ + -6.6470818519592285, + -5.81395149230957 + ], + [ + -6.842352867126465, + -5.421909809112549 + ], + [ + -7.005984783172607, + -5.008433818817139 + ], + [ + -7.481100559234619, + -5.653930187225342 + ], + [ + -7.683799743652344, + -5.449618816375732 + ], + [ + -7.973441123962402, + -5.17804479598999 + ], + [ + -8.121448516845703, + -4.988949775695801 + ], + [ + -8.335877418518066, + -4.627930641174316 + ], + [ + -8.518875122070312, + -4.432589054107666 + ], + [ + -8.661578178405762, + -4.104216575622559 + ], + [ + -8.810067176818848, + -3.8470871448516846 + ], + [ + -8.964255332946777, + -3.564910650253296 + ], + [ + -9.020991325378418, + -3.2293381690979004 + ], + [ + -9.132935523986816, + -2.981459856033325 + ], + [ + -9.179617881774902, + -2.6769537925720215 + ], + [ + -9.265387535095215, + -2.4442577362060547 + ], + [ + -9.277227401733398, + -2.1451542377471924 + ], + [ + -9.261114120483398, + -1.8187271356582642 + ], + [ + -9.593423843383789, + -1.6435199975967407 + ], + [ + -9.59833812713623, + -1.3387527465820312 + ], + [ + -9.656662940979004, + -1.0919047594070435 + ], + [ + -9.653846740722656, + -0.7802780270576477 + ], + [ + -9.661758422851562, + -0.5249062180519104 + ], + [ + -9.667686462402344, + -0.23585547506809235 + ], + [ + -9.66568374633789, + 0.024780185893177986 + ], + [ + -9.660018920898438, + 0.2418333888053894 + ], + [ + -9.624190330505371, + 0.5253020524978638 + ], + [ + -9.598389625549316, + 0.732669472694397 + ], + [ + -9.599457740783691, + 1.0241851806640625 + ], + [ + -9.572659492492676, + 1.2640724182128906 + ], + [ + -9.591958999633789, + 1.4792450666427612 + ], + [ + -9.470619201660156, + 1.7063535451889038 + ], + [ + -9.411030769348145, + 1.9775224924087524 + ] + ], + "total_points": 1000 +} \ No newline at end of file diff --git a/vna_system/web_ui/static/js/modules/charts/chart-settings.js b/vna_system/web_ui/static/js/modules/charts/chart-settings.js index 3840e57..17a3118 100644 --- a/vna_system/web_ui/static/js/modules/charts/chart-settings.js +++ b/vna_system/web_ui/static/js/modules/charts/chart-settings.js @@ -11,6 +11,9 @@ export class ChartSettingsManager { this.lastSettingValues = {}; this.settingDebounceTimers = {}; this.lastUiParameters = new Map(); + this.lastUserInteractionTime = new Map(); + this.parameterChangeTimestamps = {}; + this.containerListeners = new Map(); // Store listeners per container } updateSettings(processorId, settingsContainer, latestData) { @@ -26,6 +29,13 @@ export class ChartSettingsManager { return; } + // Check if user recently interacted with controls + const lastInteraction = this.lastUserInteractionTime.get(processorId); + if (lastInteraction && Date.now() - lastInteraction < 1000) { + console.log(`Skipping update for ${processorId} - user is actively editing`); + return; + } + console.log(`Updating settings for ${processorId}`); this.lastUiParameters.set(processorId, uiParameters ? JSON.parse(JSON.stringify(uiParameters)) : null); @@ -47,13 +57,18 @@ export class ChartSettingsManager { return; } - // Generate settings HTML - const settingsHtml = uiParameters.map(param => - createParameterControl(param, processorId, 'chart') - ).join(''); - - settingsContainer.innerHTML = settingsHtml; - this.setupEvents(settingsContainer, processorId); + // Smart update: only update changed parameters, skip focused elements + const hasExistingControls = settingsContainer.children.length > 0; + if (hasExistingControls) { + this.updateParametersSelectively(processorId, settingsContainer, uiParameters); + } else { + // Initial render: full rebuild + const settingsHtml = uiParameters.map(param => + createParameterControl(param, processorId, 'chart') + ).join(''); + settingsContainer.innerHTML = settingsHtml; + this.setupEvents(settingsContainer, processorId); + } // Initialize last values if (uiParameters) { @@ -66,6 +81,73 @@ export class ChartSettingsManager { renderIcons(settingsContainer); } + updateParametersSelectively(processorId, settingsContainer, newParameters) { + const now = Date.now(); + + // Temporarily remove event listeners to prevent programmatic changes from triggering events + this.removeEventListeners(settingsContainer); + + for (const param of newParameters) { + const settingElement = settingsContainer.querySelector(`[data-param="${param.name}"]`); + if (!settingElement) continue; + + const settingKey = `${processorId}_${param.name}`; + const currentValue = this.lastSettingValues[settingKey]; + + console.log(`[UPDATE CHECK] ${param.name}: currentValue=${currentValue}, newValue=${param.value}`); + + // ALWAYS sync lastSettingValues with backend value + const valueChanged = currentValue !== param.value; + if (valueChanged) { + this.lastSettingValues[settingKey] = param.value; + console.log(`[SYNCED] lastSettingValues["${settingKey}"] = ${param.value}`); + } else { + console.log(`[SKIP] ${param.name}: value unchanged`); + continue; + } + + // Skip UI update if element has focus + if (settingElement.contains(document.activeElement)) { + console.log(`Skipping UI update for ${param.name} - has focus`); + continue; + } + + // Skip UI update if user recently changed this parameter + const lastChange = this.parameterChangeTimestamps[settingKey]; + if (lastChange && now - lastChange < 2000) { + console.log(`Skipping UI update for ${param.name} - user changed it ${now - lastChange}ms ago`); + continue; + } + + // Update UI control based on type (without triggering events) + if (param.type === 'toggle') { + const checkbox = settingElement.querySelector('input[type="checkbox"]'); + if (checkbox && checkbox.checked !== param.value) { + console.log(`[UPDATE] Toggle ${param.name}: ${checkbox.checked} -> ${param.value}`); + checkbox.checked = param.value; + } + } else if (param.type === 'slider') { + const slider = settingElement.querySelector('input[type="range"]'); + const valueDisplay = settingElement.querySelector('.chart-setting__value'); + if (slider && parseFloat(slider.value) !== param.value) { + slider.value = param.value; + if (valueDisplay) { + valueDisplay.textContent = param.value; + } + } + } else if (param.type === 'select') { + const select = settingElement.querySelector('select'); + if (select && select.value !== String(param.value)) { + console.log(`[UPDATE] Select ${param.name}: ${select.value} -> ${param.value}`); + select.value = String(param.value); + } + } + } + + // Re-add event listeners after all updates are complete + this.restoreEventListeners(settingsContainer, processorId); + } + setupEvents(settingsContainer, processorId) { const onParamChange = (e) => { if (!e.target.closest('.chart-setting')) return; @@ -77,16 +159,52 @@ export class ChartSettingsManager { this.handleButtonClick(e, processorId); }; + // Store listeners for later removal/restoration + this.containerListeners.set(settingsContainer, { + input: onParamChange, + change: onParamChange, + click: onButtonClick + }); + settingsContainer.addEventListener('input', onParamChange); settingsContainer.addEventListener('change', onParamChange); settingsContainer.addEventListener('click', onButtonClick); } + removeEventListeners(settingsContainer) { + const listeners = this.containerListeners.get(settingsContainer); + if (!listeners) return; + + settingsContainer.removeEventListener('input', listeners.input); + settingsContainer.removeEventListener('change', listeners.change); + settingsContainer.removeEventListener('click', listeners.click); + } + + restoreEventListeners(settingsContainer, processorId) { + const listeners = this.containerListeners.get(settingsContainer); + if (!listeners) { + // If listeners don't exist, set them up + this.setupEvents(settingsContainer, processorId); + return; + } + + settingsContainer.addEventListener('input', listeners.input); + settingsContainer.addEventListener('change', listeners.change); + settingsContainer.addEventListener('click', listeners.click); + } + handleSettingChange(event, processorId) { const settingElement = event.target.closest('.chart-setting'); if (!settingElement) return; + const now = Date.now(); const paramName = settingElement.dataset.param; + const settingKey = `${processorId}_${paramName}`; + + // Mark user interaction time for both processor and specific parameter + this.lastUserInteractionTime.set(processorId, now); + this.parameterChangeTimestamps[settingKey] = now; + const input = event.target; let value; @@ -105,18 +223,21 @@ export class ChartSettingsManager { value = value === 'true'; } - const settingKey = `${processorId}_${paramName}`; let lastValue = this.lastSettingValues[settingKey]; if (typeof lastValue === 'string' && (lastValue === 'true' || lastValue === 'false')) { lastValue = lastValue === 'true'; } + console.log(`[CHANGE] ${processorId}.${paramName}: ${lastValue} -> ${value} (type: ${typeof value})`); + // Check for duplicate if (lastValue === value) { + console.log(`Skipping duplicate value for ${processorId}.${paramName}: ${value}`); return; } this.lastSettingValues[settingKey] = value; + console.log(`[SAVED] lastSettingValues["${settingKey}"] = ${value}`); // Debounce updates const debounceKey = `${processorId}_${paramName}`; diff --git a/vna_system/web_ui/static/js/modules/settings/reference-manager.js b/vna_system/web_ui/static/js/modules/settings/reference-manager.js index fbc4628..3930626 100644 --- a/vna_system/web_ui/static/js/modules/settings/reference-manager.js +++ b/vna_system/web_ui/static/js/modules/settings/reference-manager.js @@ -67,7 +67,8 @@ export class ReferenceManager { return; } - if (previousPreset !== newPreset) { + // Clear current reference only if preset actually changed (not on initial load) + if (previousPreset !== null && previousPreset !== newPreset) { await this.clearServerCurrentReference(); }