Skip to content

Commit

Permalink
Merge pull request #26 from htem/rhoadesScholar-DataPipe-RandomLocation
Browse files Browse the repository at this point in the history
Update BaseDataPipe.py
  • Loading branch information
brianreicher authored Sep 18, 2023
2 parents 94cf386 + 3a65557 commit 33861b1
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/raygun/io/BaseDataPipe.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,10 @@ def get_source(self, path, src_names, src_specs=None):

def prenet_pipe(self, mode: str = "train"):
# Make pre-net datapipe
prenet_pipe = self.source + gp.RandomLocation()
prenet_pipe = self.source
if mode == "train":
sections = [
gp.RandomLocation(),
"reject",
"resample",
"preprocess",
Expand All @@ -41,7 +42,7 @@ def prenet_pipe(self, mode: str = "train"):
elif mode == "predict":
sections = ["reject", "resample", "preprocess", "unsqueeze", "stack"]
elif mode == "test":
sections = ["reject", "resample", "preprocess", "unsqueeze", gp.Stack(1)]
sections = [gp.RandomLocation(), "reject", "resample", "preprocess", "unsqueeze", gp.Stack(1)]
else:
raise ValueError(f"mode={mode} not implemented.")

Expand Down

0 comments on commit 33861b1

Please sign in to comment.