finalize
This commit is contained in:
+3
-3
@@ -184,8 +184,8 @@ class SMPL:
|
||||
stacked = tf.stack(results, axis=0)
|
||||
results = stacked - self.pack(tf.matmul(stacked, tf.reshape(tf.concat((J, tf.zeros((24, 1), dtype=tf.float32)), axis=1), (24, 4, 1))))
|
||||
|
||||
# J = tf.matmul(results, tf.expand_dims(tf.concat([J, tf.ones([24, 1], tf.float32)], axis=1), axis=1), transpose_b=True)
|
||||
# J = tf.gather(J, tf.constant([0, 1, 2], tf.int32), axis=1)
|
||||
J = tf.matmul(results, tf.expand_dims(tf.concat([J, tf.ones([24, 1], tf.float32)], axis=1), axis=1), transpose_b=True)
|
||||
J = tf.gather(J, tf.constant([0, 1, 2], tf.int32), axis=1)
|
||||
|
||||
|
||||
T = tf.tensordot(weights[g], results, axes=((1), (0)))
|
||||
@@ -193,7 +193,7 @@ class SMPL:
|
||||
v = tf.matmul(T, tf.reshape(rest_shape_h, (-1, 4, 1)))
|
||||
v = tf.reshape(v, (-1, 4))[:, :3]
|
||||
|
||||
J = tf.transpose(tf.tensordot(v, self.J_regressor[g], axes=([0], [1])), [1,0])
|
||||
# J = tf.transpose(tf.tensordot(v, self.J_regressor[g], axes=([0], [1])), [1,0])
|
||||
|
||||
return v, tf.squeeze(J), v_posed, lrotmin
|
||||
|
||||
|
||||
Reference in New Issue
Block a user