INNER CODE UNIT · Python
vec
VITA-Group/Diffusion4D · rendering/blender.py:93
vec = vec / np.linalg.norm(vec, axis=0) * radius[0]
if maxz > vec[2] > minz:
correct = True
return vec
# def randomize_camera(
# radius_min: float = 5,
# radius_max: float = 5,
# maxz: float = 2.2,
# minz: float = -2.2,
# only_northern_hemisphere: bool = False,
# ) -> bpy.types.Object:
# """Randomizes the camera location and rotation inside of a spherical shell.
# Args:
# radius_min (float, optional): Minimum radius of the spherical shell. Defaults to
# 1.5.