Skip to content

Commit

Permalink
Use generator
Browse files Browse the repository at this point in the history
  • Loading branch information
burggraaff committed Mar 1, 2024
1 parent 191088c commit 638e73e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fpcup/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ def from_folder(cls, folder: PathOrStr, extension: Optional[str]="*.wsum", progr

# Load the files (with a tqdm progressbar if desired)
filenames = tqdm(filenames, desc="Loading summaries", unit="file", disable=not progressbar, leave=leave_progressbar)
summaries_individual = [cls.from_file(filename) for filename in filenames]
summaries_individual = (cls.from_file(filename) for filename in filenames)
return cls.from_ensemble(summaries_individual)

def to_file(self, filename: PathOrStr, **kwargs) -> None:
Expand Down

0 comments on commit 638e73e

Please sign in to comment.