Skip to content

Commit

Permalink
Refs #8528. Avoid slicing the sample
Browse files Browse the repository at this point in the history
By making the can workspaces histograms, in loading time, we ensure that
they will not be sliced in any time during reduction.
  • Loading branch information
gesnerpassos committed Dec 3, 2013
1 parent 884ff7f commit fe55d84
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Code/Mantid/scripts/SANS/isis_reducer.py
Expand Up @@ -80,6 +80,16 @@ def get_periods_in_file(self):

class Can(Sample):
ISSAMPLE = False
def set_run(self, run, reload, period, reducer):

super(Can, self).set_run(run, reload, period, reducer)

# currently, no slices will be applied to Can #8535
for period in reversed(range(self.loader.periods_in_file)):
self.loader.move2ws(period)
name = self.loader.wksp_name
if su.isEventWorkspace(name):
su.fromEvent2Histogram(mtd[name])

class ISISReducer(SANSReducer):
"""
Expand Down Expand Up @@ -225,6 +235,7 @@ def set_sample(self, run, reload, period):

def set_can(self, run, reload, period):
self._can_run.set_run(run, reload, period, self)


def get_sample(self):
"""
Expand Down

0 comments on commit fe55d84

Please sign in to comment.