Closed john- closed 6 months ago
GUI could either display Hz or keep MHz and have code all ref same list but with the multiplies in every instance of referencing the list. That is clearer code but slightly more operations. Or the list could contain all three: baseband, RF Hz and RF MHz frequencies in it per entry, making more memory but much clearer what is happening.
This branch removed a couple loops so I was comfortable in adding some information into each channel. Here is what is in it for each channel:
https://github.com/john-/ham2mon/blob/scan_cycle_reorg_squashed/apps/h2h_types.py
Note: I made a mistake with the file name here and will change it down the road.
II put the baseband
in there but it is not used in the UI. The frequency
is in Mhz.
The UI was changed to use frequency
, locked
', active
, priority
, and hanging
.
Here are some performance timings. As ham2mon needs to be manually stopped after replay completes that will create some variance. All timings are with ham2mon windows active and visible.
branch: scan_cycle_reorg_squashed
260.82 user+sys | 198.01s user 62.81s system 225% cpu 1:55.77 total
264.39 user+sys | 201.29s user 63.10s system 226% cpu 1:56.72 total
263.88 user+sys | 201.75s user 62.13s system 226% cpu 1:56.34 total
branch: master
263.32 user+sys | 200.88s user 62.44s system 226% cpu 1:56.43 total
263.25 user+sys | 197.35s user 65.90s system 225% cpu 1:56.52 total
262.99 user+sys | 196.83s user 66.16s system 226% cpu 1:56.05 total
Based on this it does seems the performance is comparable between this branch and master. At least nothing has broken with the changes.
This is now part of the master branch. Closing ticket.
Over time the current code in scan_cycle has grown and been modified such that it is not clear immediately what is happening. Also, it provides the GUI separate lists that contain active frequencies and tuned frequencies.
This change will re-organize the function and a single frequency list that contains metadata for each channel.
https://github.com/john-/ham2mon/tree/scan_cycle_reorg_squashed