Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moving sequence number generation for traces and tails to mem_store #23

Open
hwalinga opened this issue Dec 14, 2023 · 0 comments
Open

Comments

@hwalinga
Copy link
Collaborator

This followed after a discussion with @RobBa

The traces and tails in flexfringe have an incrementing unique identifier. sequence and tail_nr. Inputdata handles correctly numbering these tails and traces. Inputdata maintains a num_sequences and num_tails.

Now, the active learning component also deals with these numbering since it has to add the traces on the fly which do not originate from inputdata. Robert and I were afraid this will go wrong at some time. (Somewhere else in the code, the abbodingoreader also shortcuts the numbering in the read function by using a loop variable.)

They all have one thing in common though. They all call to create_tail or create_trace of the mem_store first. My suggestion would therefore be to have the num_sequences and num_tails to be dealt with the mem_store instead. So maintain a static incrementer in mem_store for num_tails and num_sequences.

Since we are refactoring, maybe rename sequence to trace_nr and num_sequences to num_traces. The name sequence is a bit confusing to me, and this would be inline with how we call it for the traces.

Another thing I noticed is that inputdata maintains a traces list which it sorts after parsing. I don't know if things go wrong if more traces are added afterwards. Should this also be added here? Maybe this can also be dealt with in mem_store. A sorted collection would then be a better choice.

@hwalinga hwalinga mentioned this issue Jan 31, 2024
hwalinga added a commit to hwalinga/FlexFringe that referenced this issue Jul 3, 2024
hwalinga added a commit that referenced this issue Oct 30, 2024
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

No branches or pull requests

1 participant