Skip to content

Phase detection strategies#12

Draft
rollf wants to merge 3 commits intoseppinho:mainfrom
limbus-medtec:phase-detection-strategies
Draft

Phase detection strategies#12
rollf wants to merge 3 commits intoseppinho:mainfrom
limbus-medtec:phase-detection-strategies

Conversation

@rollf
Copy link

@rollf rollf commented Jan 2, 2025

This is an initial attempt to implement phasing detection strategies. See #7 .

  • I adapted the test.sh to make it runnable on systems without /bin/bash
  • I swapped the if-condition for phasedAutodetect to decrease the cognitive load
  • I added two strategies to detect phasing.

I'm not happy with my enum+fp-style approach but did not want to change in the middle of coding. Feel free to suggest another approach. Maybe simply OOP inheritance.

Moving previous around (see code) is only necessary if you care for performance (while looping over the variants) which is fine as is. Still, it's cumbersome and could be removed if performance is not a concern.

ONE_FOR_ALL and DEFAULT are no good names.

I am not sure what exactly phasedAutodetect is expected to mean. I guess the final PR should also touch on this attribute for a consistent approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant