Skip to content

Fix three issues: init __what_to_create, honor resample_dt, and correct get_t_isco indexing#13

Merged
AnujKankani merged 3 commits intodevfrom
codex/review-gwbob-package-for-issues-and-documentation
Feb 20, 2026
Merged

Fix three issues: init __what_to_create, honor resample_dt, and correct get_t_isco indexing#13
AnujKankani merged 3 commits intodevfrom
codex/review-gwbob-package-for-issues-and-documentation

Conversation

@AnujKankani
Copy link
Owner

Motivation

  • set_initial_time referenced self.__what_to_create before it was initialized, which can raise an AttributeError if initial time is set prior to selecting what to create.
  • The CCE initialization routine accepted a resample_dt argument but did not apply it, causing callers to be ignored.
  • get_t_isco computed a nearest-frequency index from a cropped frequency array but indexed the uncropped time array, producing incorrect ISCO time lookups.

Description

  • Initialize self.__what_to_create = "Nothing" in the BOB.__init__ constructor to ensure the attribute exists before set_initial_time uses it.
  • Set self.resample_dt = resample_dt at the start of the CCE initialization function so the passed resample_dt is honored for resampling.
  • Replace indexing of self.data.t[...] with freq_data.t[...] in get_t_isco so the time lookup matches the cropped frequency array used to compute the index.

Testing

  • Executed automated edit-and-verify scripts that applied the three minimal changes and read back gwBOB/BOB_utils.py to confirm the intended lines were modified, and those checks passed.
  • No project unit test suite (e.g. pytest) was executed for these changes.
  • Performed static inspection of the modified lines to confirm each fix is a single-line, localized change and no other behavior was altered.

Codex Task

@AnujKankani AnujKankani changed the base branch from dev_review to dev February 20, 2026 15:52
@AnujKankani AnujKankani merged commit f26d9a2 into dev Feb 20, 2026
0 of 2 checks passed
@AnujKankani AnujKankani deleted the codex/review-gwbob-package-for-issues-and-documentation branch February 25, 2026 15:00
AnujKankani added a commit that referenced this pull request Mar 25, 2026
* updated joss paper

* paper formatting

* Fix three issues: init `__what_to_create`, honor `resample_dt`, and correct `get_t_isco` indexing (#13)

* bump version [skip ci]

* Fix get_t_isco time indexing after cropping

* Add missing init and CCE resample_dt fixes

* update trusted values post cce dt fix

* update workflow [reset cache]

* [reset cache]

* change default dt

* mismatch resample reliability increased

* reduce tolerance

* reduce tolerance for optimized Omega_0 mismatch

* lower tolerance for Omega_0 as well

* fix mismatch testing

* fix file prefix
AnujKankani added a commit that referenced this pull request Mar 25, 2026
* updated joss paper

* paper formatting

* Fix three issues: init `__what_to_create`, honor `resample_dt`, and correct `get_t_isco` indexing (#13)

* bump version [skip ci]

* Fix get_t_isco time indexing after cropping

* Add missing init and CCE resample_dt fixes

* update trusted values post cce dt fix

* update workflow [reset cache]

* [reset cache]

* change default dt

* mismatch resample reliability increased

* reduce tolerance

* reduce tolerance for optimized Omega_0 mismatch

* lower tolerance for Omega_0 as well

* fix mismatch testing

* fix file prefix

* fix offline testing

* update env variables in testing

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant