Skip to content

Commit 3886072

Browse files
committed
Fixed string formatting in VNCC.
1 parent 18f1dc4 commit 3886072

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/prpy/perception/vncc.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -125,17 +125,19 @@ def DetectObject(self, robot, obj_name, **kw_args):
125125
from prpy.perception.base import PerceptionException
126126

127127
if obj_name not in self.kinbody_to_query_map:
128-
raise PerceptionException('The VNCC module cannot detect object %s', obj_name)
128+
raise PerceptionException(
129+
'The VNCC module cannot detect object {:s}'.format(obj_name))
129130

130131
query_name = self.kinbody_to_query_map[obj_name]
131132
obj_pose = self._GetDetection(query_name)
132133
if obj_pose is None:
133-
raise PerceptionException('Failed to detect objects %s', obj_name)
134+
raise PerceptionException(
135+
'Failed to detect object {:s}'.format(obj_name))
134136

135137
env = robot.GetEnv()
136138
if env.GetKinBody(obj_name) is None:
137139
from prpy.rave import add_object
138-
kinbody_file = '%s.kinbody.xml' % obj_name
140+
kinbody_file = '{:s}.kinbody.xml'.format(obj_name)
139141
new_body = add_object(
140142
env,
141143
obj_name,

0 commit comments

Comments
 (0)