MCPcopy Create free account

hub / github.com/akanazawa/cmr / functions

Functions262 in github.com/akanazawa/cmr

Functionmask_data_loader
(batch_size, opts)
data/cub.py:86
Functionmask_dt_loss
proj_verts: B x N x 2 (In normalized coordinate [-1, 1]) dist_transf: B x 1 x N x N Computes the distance transform at the points wh
nnutils/loss_utils.py:13
Methodmatrix
Return homogeneous rotation matrix.
utils/transformations.py:1621
Functionmkdirs
(paths)
utils/visutil.py:100
Methodnext
Continue rotation in direction of last drag.
utils/transformations.py:1616
Functionorthogonalization_matrix
Return orthogonalization matrix for crystallographic cell coordinates. Angles are expected in degrees. The de-orthogonalization matrix is th
utils/transformations.py:862
Functionorthographic_proj
X: B x N x 3 cam: B x 7: [sc, tx, ty, quaternions]
nnutils/geom_utils.py:30
Functionorthographic_proj_withz
X: B x N x 3 cam: B x 7: [sc, tx, ty, quaternions] Orth preserving the z.
nnutils/geom_utils.py:43
Functionpeturb_bbox
Jitters and pads the input bbox. Args: bbox: Zero-indexed tight bbox. pf: padding fraction. jf: jittering fraction.
utils/image.py:17
Methodplace
Place Arcball, e.g. when window size changes. center : sequence[2] Window coordinates of trackball center. radius : float
utils/transformations.py:1563
Functionprint_numpy
(x, val=True, shp=False)
utils/visutil.py:90
Functionproject_verts_on_mesh
(verts, mesh_verts, mesh_faces)
utils/geometry.py:42
Functionprojection_from_matrix
Return projection plane and perspective point from projection matrix. Return values are same as arguments for projection_matrix function: poi
utils/transformations.py:523
Functionprojection_matrix
Return matrix to project onto plane defined by point and normal. Using either perspective point, projection direction, or none of both. If p
utils/transformations.py:461
Functionquat_loss
Anti-podal squared L2 loss. Args: q1: N X 4 q2: N X 4 Returns: loss : N x 1
nnutils/loss_utils.py:136
Functionquaternion_about_axis
Return quaternion for rotation about axis. >>> q = quaternion_about_axis(0.123, [1, 0, 0]) >>> numpy.allclose(q, [0.99810947, 0.06146124, 0,
utils/transformations.py:1238
Functionquaternion_conjugate
Return conjugate of quaternion. >>> q0 = random_quaternion() >>> q1 = quaternion_conjugate(q0) >>> q1[0] == q0[0] and all(q1[1:] == -q0[1
utils/transformations.py:1383
Functionquaternion_from_euler
Return quaternion from Euler angles and axis sequence. ai, aj, ak : Euler's roll, pitch and yaw angles axes : One of 24 axis sequences as str
utils/transformations.py:1181
Functionquaternion_imag
Return imaginary part of quaternion. >>> quaternion_imag([3, 0, 1, 2]) array([ 0., 1., 2.])
utils/transformations.py:1421
Functionquaternion_inverse
Return inverse of quaternion. >>> q0 = random_quaternion() >>> q1 = quaternion_inverse(q0) >>> numpy.allclose(quaternion_multiply(q0, q1)
utils/transformations.py:1397
Functionquaternion_real
Return real part of quaternion. >>> quaternion_real([3, 0, 1, 2]) 3.0
utils/transformations.py:1411
Functionrandom_rotation_matrix
Return uniform random rotation matrix. rand: array like Three independent random variables that are uniformly distributed between
utils/transformations.py:1500
Functionrandom_vector
Return array of random doubles in the half-open interval [0.0, 1.0). >>> v = random_vector(10000) >>> numpy.all(v >= 0) and numpy.all(v < 1)
utils/transformations.py:1771
Functionreflection_from_matrix
Return mirror plane point and normal vector from reflection matrix. >>> v0 = numpy.random.random(3) - 0.5 >>> v1 = numpy.random.random(3) - 0
utils/transformations.py:273
Functionreflection_matrix
Return matrix to mirror at plane defined by point and normal vector. >>> v0 = numpy.random.random(4) - 0.5 >>> v0[3] = 1. >>> v1 = numpy.
utils/transformations.py:247
Functionresize_img
(img, scale_factor)
utils/image.py:8
Methodrotated
vert is N x 3, torch FloatTensor (or Variable)
utils/bird_vis.py:89
Functionrotation_from_matrix
Return rotation angle and axis from rotation matrix. >>> angle = (random.random() - 0.5) * (2*math.pi) >>> direc = numpy.random.random(3) - 0
utils/transformations.py:346
Functionrotation_matrix
Return matrix to rotate about axis defined by point and direction. >>> R = rotation_matrix(math.pi/2, [0, 0, 1], [1, 0, 0]) >>> numpy.allclos
utils/transformations.py:302
Functionsample_textures
texture_flow: B x F x T x T x 2 (In normalized coordinate [-1, 1]) images: B x 3 x N x N output: B x F x T x T x 3
nnutils/geom_utils.py:11
Functionsave_image
(image_numpy, image_path)
utils/visutil.py:70
Methodsave_images
(self, webpage, visuals, image_path)
utils/visualizer.py:108
Functionscale_from_matrix
Return scaling factor, origin and direction from scaling matrix. >>> factor = random.random() * 10 - 5 >>> origin = numpy.random.random(3) -
utils/transformations.py:420
Functionscale_matrix
Return matrix to scale by factor around origin in direction. Use factor -1 for point symmetry. >>> v = (numpy.random.rand(4, 5) - 0.5) * 20
utils/transformations.py:386
Methodset_input
(self, batch)
experiments/shape.py:122
Methodset_input
Should be implemented by the child class.
nnutils/test_utils.py:112
Methodsetaxes
Set axes to constrain rotations.
utils/transformations.py:1576
Functionsfm_data_loader
(batch_size, opts)
data/cub.py:90
Functionshear_from_matrix
Return shear angle, direction and plane from shear matrix. >>> angle = (random.random() - 0.5) * 4*math.pi >>> direct = numpy.random.random(3
utils/transformations.py:679
Functionshear_matrix
Return matrix to shear by angle along direction vector on shear plane. The shear plane is defined by a point and normal vector. The direction
utils/transformations.py:648
Functionsquare_bbox
Converts a bbox to have a square shape by increasing size along non-max dimension.
utils/image.py:40
Functionsuperimposition_matrix
Return matrix to transform given 3D point set into second point set. v0 and v1 are shape (3, \*) or (4, \*) arrays of at least 3 points. The
utils/transformations.py:998
Functiontensor2im
(image_tensor, imtype=np.uint8, scale_to_range_1=False)
utils/bird_vis.py:353
Functiontensor2im
(image_tensor, imtype=np.uint8)
utils/visutil.py:13
Functiontensor2im_batch
(image_tensor, num_batch, imtype=np.uint8)
utils/visutil.py:38
Functiontensor2kps
(kp_tensor)
utils/visutil.py:19
Functiontensor2mask
(image_tensor, imtype=np.uint8)
utils/bird_vis.py:187
Functiontensor2verts
(vert_tensor)
utils/visutil.py:28
Methodtest
Should be implemented by the child class.
nnutils/test_utils.py:121
Functiontexture_dt_loss
texture_flow: B x F x T x T x 2 (In normalized coordinate [-1, 1]) dist_transf: B x 1 x N x N Similar to geom_utils.sample_textures
nnutils/loss_utils.py:28
Functiontexture_loss
Input: img_pred, img_gt: B x 3 x H x W mask_pred, mask_gt: B x H x W
nnutils/loss_utils.py:71
Functiontranslation_from_matrix
Return translation vector from translation matrix. >>> v0 = numpy.random.random(3) - 0.5 >>> v1 = translation_from_matrix(translation_matrix(
utils/transformations.py:235
Functiontranslation_matrix
Return matrix to translate by direction vector. >>> v = numpy.random.random(3) - 0.5 >>> numpy.allclose(v, translation_matrix(v)[:3, 3])
utils/transformations.py:222
Functiontriangle_loss
Encourages dihedral angle to be 180 degrees. Args: verts: B X N X 3 edge2verts: B X E X 4 Returns: loss : scalar
nnutils/loss_utils.py:152
Functionundo_resnet_preprocess
(image_tensor)
utils/visutil.py:49
Functionvarname
(p)
utils/visutil.py:84
Functionvector_product
Return vector perpendicular to vectors. >>> v = vector_product([2, 0, 0], [0, 3, 0]) >>> numpy.allclose(v, [0, 0, 6]) True >>> v0 = [
utils/transformations.py:1786
Functionvis_verts
mean_shape: N x 3 verts: B x N x 3 face: numpy F x 3 textures: B x F x T x T (x T) x 3
utils/bird_vis.py:267
Functionvisflow
(flow_img)
utils/bird_vis.py:366
Functionvisflow_jonas
(flow_img, img_size)
utils/bird_vis.py:397
Methodvisualize
(self, verts, F_np, mv=None)
nnutils/loss_utils.py:288
Methodvisualize
(self, verts, mv=None)
nnutils/loss_utils.py:328
← previous201–262 of 262, ranked by callers