Skip to content

Commit

Permalink
Made _process_data docstring more explicit.
Browse files Browse the repository at this point in the history
  • Loading branch information
mickp committed Dec 19, 2019
1 parent 0c98ba9 commit 1c16359
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions microscope/devices.py
Original file line number Diff line number Diff line change
Expand Up @@ -495,8 +495,10 @@ def _fetch_data(self):
def _process_data(self, data):
"""Do any data processing and return data.
Subclasses should call super()._process_data(data) after doing their
own processing."""
Subclasses should add their processing to self.pipeline in preference
to overriding this method. Anything that overrides this method must
call super()_process_data(data) either before or after its own
processing."""
import functools
return functools.reduce(lambda x, f: f(x), self.pipeline, data)

Expand Down

0 comments on commit 1c16359

Please sign in to comment.