Traceback (most recent call last):
File "render.py", line 223, in <module>
render_function(mesh_list,tex_list,cam_info, os.path.join(args.scene_path, scene))
File "render.py", line 182, in render_function
point_at(cam, (info['target'][0],3.2,info['target'][1]))
File "render.py", line 59, in point_at
direction = target - loc
AttributeError: Vector subtraction: (Vector - Vector) invalid type for this operation
Then, I debug render.py from LINE 57. By running type(target) and type(loc), the results are all Vector. However, by running isinstance(target, mathutils.Vector) and isinstance(loc, mathutils.Vector), the results are True and False respectively. i.e. The
I find a way to solve this:
if not isinstance(loc, mathutils.Vector):
loc = mathutils.Vector(loc.to_tuple())
But this is somewhat unnature.
I think this caused by the inappropriate version of mathutils and bpy.
So could you please tell me the version of these two packages you are using?
Hi,
I'm rendering using scripts/render.py. There is an error on LINE 57
Errrors shown here:
Then, I debug
render.py
from LINE 57. By runningtype(target)
andtype(loc)
, the results are allVector
. However, by runningisinstance(target, mathutils.Vector)
andisinstance(loc, mathutils.Vector)
, the results areTrue
andFalse
respectively. i.e. TheI find a way to solve this:
But this is somewhat unnature.
I think this caused by the inappropriate version of
mathutils
andbpy
. So could you please tell me the version of these two packages you are using?Thanks a lot.