Skip to content

Commit

Permalink
More changes that were triggered by the system tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gesnerpassos committed Mar 5, 2013
1 parent 8478b6c commit 5d9c524
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Code/Mantid/scripts/SANS/ISISCommandInterface.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def SetVerboseMode(state):
# Print a message and log it if the
def _printMessage(msg, log = True, no_console=False):
if log == True and _VERBOSE_ == True:
mantid.logger.notice('::SANS::' + msg)
logger.notice('::SANS::' + msg)
if not no_console:
print msg

Expand Down
2 changes: 1 addition & 1 deletion Code/Mantid/scripts/SANS/SANSUtility.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ def QuadrantXML(centre,rmin,rmax,quadrant):
return xmlstring
##START REMOVED STEVE 13 September 2010 (SANSReductionSteps.py)
def StripEndZeroes(workspace, flag_value = 0.0):
result_ws = mantid.getMatrixWorkspace(workspace)
result_ws = mtd[workspace]
y_vals = result_ws.readY(0)
length = len(y_vals)
# Find the first non-zero value
Expand Down
4 changes: 2 additions & 2 deletions Code/Mantid/scripts/SANS/isis_instrument.py
Original file line number Diff line number Diff line change
Expand Up @@ -654,7 +654,7 @@ def check_can_logs(self):

def cur_detector_position(self, ws_name):
"""Return the position of the center of the detector bank"""
ws = mantid[ws_name]
ws = mtd[ws_name]
pos = ws.getInstrument().getComponentByName(self.cur_detector().name()).getPos()
cent_pos = 317.5/1000.0
return [cent_pos - pos.getX(), cent_pos - pos.getY()]
Expand Down Expand Up @@ -936,7 +936,7 @@ def load_transmission_inst(self, workspace):

def cur_detector_position(self, ws_name):
"""Return the position of the center of the detector bank"""
ws = mantid[ws_name]
ws = mtd[ws_name]
pos = ws.getInstrument().getComponentByName(self.cur_detector().name()).getPos()

return [-pos.getX(), -pos.getY()]
Expand Down
2 changes: 1 addition & 1 deletion Code/Mantid/scripts/SANS/isis_reducer.py
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ def deleteWorkspaces(workspaces):
"""
for wk in workspaces:
try:
if wk and mantid.workspaceExists(wk):
if wk and wk in mtd:
DeleteWorkspace(Workspace=wk)
except:
#if the workspace can't be deleted this function does nothing
Expand Down

0 comments on commit 5d9c524

Please sign in to comment.