Skip to content

Commit

Permalink
Make dumping of problem components conditional
Browse files Browse the repository at this point in the history
  • Loading branch information
ccuetom committed May 8, 2024
1 parent 2415d7b commit cdf3aec
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions stride/problem/problem.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,10 +161,14 @@ def dump(self, *args, **kwargs):
kwargs['project_name'] = kwargs.get('project_name', self.name)
kwargs['path'] = kwargs.get('path', self.output_folder)

self.medium.dump(*args, **kwargs)
self.transducers.dump(*args, **kwargs)
self.geometry.dump(*args, **kwargs)
self.acquisitions.dump(*args, **kwargs)
if kwargs.pop('dump_medium', True):
self.medium.dump(*args, **kwargs)
if kwargs.pop('dump_transducers', True):
self.transducers.dump(*args, **kwargs)
if kwargs.pop('dump_geometry', True):
self.geometry.dump(*args, **kwargs)
if kwargs.pop('dump_acquisitions', True):
self.acquisitions.dump(*args, **kwargs)

def plot(self, **kwargs):
"""
Expand Down

0 comments on commit cdf3aec

Please sign in to comment.