Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions bilby/gw/waveform_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -579,6 +579,17 @@ def _parameters_from_source_model(self):
return self._all_parameters.difference(self.defaults.keys())


class EccentricGWSignalWaveformGenerator(GWSignalWaveformGenerator):
"""
Subclass that initializes an eccentric GWSignal Waveform Generator.
Equivalent to `GWSignalWaveformGenerator` with `eccentric=True`.
See documentation of `GWSignalWaveformGenerator` for more information.
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's worth specifying that this doesn't do any kind of checking that the requested model actually supports eccentricity.

"""

def __init__(self, **kwargs):
super().__init__(eccentric=True, **kwargs)
Comment on lines +582 to +590
Copy link

Copilot AI Jan 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider adding test coverage for the new EccentricGWSignalWaveformGenerator class. While the implementation is straightforward, tests would ensure that the class properly initializes with eccentric=True and that the eccentric parameters are correctly included in the parameters (not in defaults). A simple test could verify that instantiating this class is equivalent to GWSignalWaveformGenerator(eccentric=True, ...).

Copilot uses AI. Check for mistakes.


def _try_waveform_call(func, parameters, generator, catch_waveform_errors):
try:
return func(parameters, generator)
Expand Down
Loading