Skip to content

Speedup.replace uniq with list of iter uniq#6664

Closed
wxtim wants to merge 1 commit intocylc:masterfrom
wxtim:speedup.replace_uniq_with_list_of_iter_uniq
Closed

Speedup.replace uniq with list of iter uniq#6664
wxtim wants to merge 1 commit intocylc:masterfrom
wxtim:speedup.replace_uniq_with_list_of_iter_uniq

Conversation

@wxtim
Copy link
Copy Markdown
Member

@wxtim wxtim commented Mar 12, 2025

list(iter_uniq(iterable))
# Is an order of magnitude faster than
uniq(iterable)

In both Python 3.8 and 3.13.

Full experiment posted in notebook in this comment.

Note

This will conflict with #6574 and will need to either be merged first or rebased.

Check List

  • I have read CONTRIBUTING.md and added my name as a Code Contributor.
  • Contains logically grouped changes (else tidy your branch by rebase).
  • Does not contain off-topic changes (use other PRs for other changes).
  • Applied any dependency changes to both setup.cfg (and conda-environment.yml if present).
  • This is a change of method, not interface:
    • Existing tests cover change.
    • Changelog not req'd
    • Opened against master
    • Docs not req'd

@wxtim wxtim requested a review from oliver-sanders March 12, 2025 09:32
@wxtim wxtim self-assigned this Mar 12, 2025
@wxtim wxtim added this to the 8.4.2 milestone Mar 12, 2025
@wxtim wxtim marked this pull request as draft March 13, 2025 09:25
@wxtim wxtim force-pushed the speedup.replace_uniq_with_list_of_iter_uniq branch 2 times, most recently from 6a78f3e to d585304 Compare March 18, 2025 10:53
@oliver-sanders oliver-sanders modified the milestones: 8.4.2, 8.4.x Apr 7, 2025
@wxtim wxtim force-pushed the speedup.replace_uniq_with_list_of_iter_uniq branch 3 times, most recently from 0cb8a0b to d585304 Compare May 8, 2025 13:24
@oliver-sanders oliver-sanders removed their request for review June 10, 2025 12:10
@wxtim wxtim force-pushed the speedup.replace_uniq_with_list_of_iter_uniq branch from d585304 to ffbcf2a Compare August 14, 2025 13:14
@wxtim
Copy link
Copy Markdown
Member Author

wxtim commented Aug 14, 2025

Stale. Not relevant.

@wxtim
Copy link
Copy Markdown
Member Author

wxtim commented Aug 26, 2025

Stale

@wxtim wxtim closed this Aug 26, 2025
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.

2 participants