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

Overwrote compress function to exclude all .yace files #163

Closed
wants to merge 1 commit into from
Closed
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
12 changes: 12 additions & 0 deletions pyiron_potentialfit/pacemaker/job.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ def __init__(self, project, job_name):
self.__version__ = "0.2"

self._train_job_id_list = []
self._compress_by_default = True

self.input = GenericParameters(table_name="input")
self._cutoff = 7.0
Expand Down Expand Up @@ -502,3 +503,14 @@ def check_inner_cutoffs(self):
plt.xlabel(r"Distance [$\AA$]")
plt.ylabel(r"Energy [eV]")
return df

def compress(self, files_to_compress=None):
"""
Compress the output files of a job object.

Args:
files_to_compress (list): A list of files to compress (optional)
"""
if files_to_compress is None:
files_to_compress = [f for f in self.files.list() if not f.endswith('.yace')]
super(PacemakerJob, self).compress(files_to_compress=files_to_compress)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
super(PacemakerJob, self).compress(files_to_compress=files_to_compress)
super().compress(files_to_compress=files_to_compress)

Loading