Skip to content

Commit a9f8a97

Browse files
committed
BUG: Fix print statement to be python2/3 compatible
1 parent 61df1b6 commit a9f8a97

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

VisSimCommon/VisSimCommon.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
# slicer.util.reloadScriptedModule("VisSimCommon")
2323
# slicer.util.reloadScriptedModule(self.moduleName)
2424
#======================================================================================
25+
from __future__ import print_function
2526
import os, re, sys, math, unittest, logging, zipfile, platform, subprocess, hashlib
2627
from six.moves.urllib.request import urlretrieve
2728
import numpy as np
@@ -877,7 +878,7 @@ def locateItem(self, inputVolumeNode, inputPointEdt, reg, vtID):
877878
inputPointEdt.setText(str(self.inputPoint))
878879
# Check if a volume is selected
879880
if not self.inputVolumeNode:
880-
print >> sys.stderr, "You need to pick a input volume first before locating vertebra."
881+
print("You need to pick a input volume first before locating vertebra.", file=sys.stderr)
881882
return -1
882883
#endif
883884
# Display suitable during locating the vertebra

0 commit comments

Comments
 (0)