本文整理汇总了Python中tensorflow.RegisterShape方法的典型用法代码示例。如果您正苦于以下问题:Python tensorflow.RegisterShape方法的具体用法?Python tensorflow.RegisterShape怎么用?Python tensorflow.RegisterShape使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类tensorflow
的用法示例。
在下文中一共展示了tensorflow.RegisterShape方法的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1,xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
return nn_distance_module.nn_distance(xyz1,xyz2)
#@tf.RegisterShape('NnDistance')
#def _nn_distance_shape(op):
#shape1=op.inputs[0].get_shape().with_rank(3)
#shape2=op.inputs[1].get_shape().with_rank(3)
#return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
#tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例2: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1, xyz2):
"""
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
"""
xyz1 = tf.expand_dims(xyz1, 0)
xyz2 = tf.expand_dims(xyz2, 0)
return nn_distance_module.nn_distance(xyz1, xyz2)
# @tf.RegisterShape('NnDistance')
# def _nn_distance_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(3)
# return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
# tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例3: match_cost
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def match_cost(xyz1,xyz2,match):
'''
input:
xyz1 : batch_size * #dataset_points * 3
xyz2 : batch_size * #query_points * 3
match : batch_size * #query_points * #dataset_points
returns:
cost : batch_size
'''
return approxmatch_module.match_cost(xyz1,xyz2,match)
#@tf.RegisterShape('MatchCost')
#def _match_cost_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(3)
# shape3=op.inputs[2].get_shape().with_rank(3)
# return [tf.TensorShape([shape1.dims[0]])]
示例4: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1,xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
return nn_distance_module.nn_distance(xyz1,xyz2)
#@tf.RegisterShape('NnDistance')
#def _nn_distance_shape(op):
#shape1=op.inputs[0].get_shape().with_rank(3)
#shape2=op.inputs[1].get_shape().with_rank(3)
#return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
#tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例5: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1,xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
return nn_distance_module.nn_distance(xyz1,xyz2)
#@tf.RegisterShape('NnDistance')
#def _nn_distance_shape(op):
#shape1=op.inputs[0].get_shape().with_rank(3)
#shape2=op.inputs[1].get_shape().with_rank(3)
#return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
#tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例6: gather_point
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def gather_point(inp, idx):
'''
input:
batch_size * ndataset * 3 float32
batch_size * npoints int32
returns:
batch_size * npoints * 3 float32
'''
return sampling_module.gather_point(inp, idx)
# @tf.RegisterShape('GatherPoint')
# def _gather_point_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(2)
# return [tf.TensorShape([shape1.dims[0],shape2.dims[1],shape1.dims[2]])]
示例7: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1,xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
xyz1 = tf.expand_dims(xyz1, 0)
xyz2 = tf.expand_dims(xyz2, 0)
return nn_distance_module.nn_distance(xyz1,xyz2)
#@tf.RegisterShape('NnDistance')
#def _nn_distance_shape(op):
#shape1=op.inputs[0].get_shape().with_rank(3)
#shape2=op.inputs[1].get_shape().with_rank(3)
#return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
#tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例8: match_cost
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def match_cost(xyz1, xyz2, match):
'''
input:
xyz1 : batch_size * #dataset_points * 3
xyz2 : batch_size * #query_points * 3
match : batch_size * #query_points * #dataset_points
returns:
cost : batch_size
'''
return approxmatch_module.match_cost(xyz1, xyz2, match)
#@tf.RegisterShape('MatchCost')
# def _match_cost_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(3)
# shape3=op.inputs[2].get_shape().with_rank(3)
# return [tf.TensorShape([shape1.dims[0]])]
示例9: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1, xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
return nn_distance_module.nn_distance(xyz1, xyz2)
#@tf.RegisterShape('NnDistance')
# def _nn_distance_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(3)
# return [tf.TensorShape([shape1.dims[0],shape1.dims[1]]),tf.TensorShape([shape1.dims[0],shape1.dims[1]]),
# tf.TensorShape([shape2.dims[0],shape2.dims[1]]),tf.TensorShape([shape2.dims[0],shape2.dims[1]])]
示例10: match_cost
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def match_cost(xyz1,xyz2,match):
'''
input:
xyz1 : batch_size * #dataset_points * 3
xyz2 : batch_size * #query_points * 3
match : batch_size * #query_points * #dataset_points
returns:
cost : batch_size
'''
return approxmatch_module.match_cost(xyz1,xyz2,match)
#@tf.RegisterShape('MatchCost')
示例11: gather_point
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def gather_point(inp,idx):
'''
input:
batch_size * ndataset * 3 float32
batch_size * npoints int32
returns:
batch_size * npoints * 3 float32
'''
return sampling_module.gather_point(inp,idx)
#@tf.RegisterShape('GatherPoint')
#def _gather_point_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(2)
# return [tf.TensorShape([shape1.dims[0],shape2.dims[1],shape1.dims[2]])]
示例12: nn_distance
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def nn_distance(xyz1, xyz2):
'''
Computes the distance of nearest neighbors for a pair of point clouds
input: xyz1: (batch_size,#points_1,3) the first point cloud
input: xyz2: (batch_size,#points_2,3) the second point cloud
output: dist1: (batch_size,#point_1) distance from first to second
output: idx1: (batch_size,#point_1) nearest neighbor from first to second
output: dist2: (batch_size,#point_2) distance from second to first
output: idx2: (batch_size,#point_2) nearest neighbor from second to first
'''
xyz1 = tf.expand_dims(xyz1, 0)
xyz2 = tf.expand_dims(xyz2, 0)
return nn_distance_module.nn_distance(xyz1,xyz2)
#@tf.RegisterShape('NnDistance')
示例13: match_cost
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def match_cost(xyz1,xyz2,match):
'''
input:
xyz1 : batch_size * #dataset_points * 3
xyz2 : batch_size * #query_points * 3
match : batch_size * #query_points * #dataset_points
returns:
cost : batch_size
'''
xyz1 = tf.expand_dims(xyz1, 0)
xyz2 = tf.expand_dims(xyz2, 0)
return approxmatch_module.match_cost(xyz1,xyz2,match)
#@tf.RegisterShape('MatchCost')
示例14: gather_point
# 需要导入模块: import tensorflow [as 别名]
# 或者: from tensorflow import RegisterShape [as 别名]
def gather_point(inp,idx):
'''
input:
batch_size * ndataset * dim float32
batch_size * npoints int32
returns:
batch_size * npoints * dim float32
'''
return sampling_module.gather_point(inp,idx)
#@tf.RegisterShape('GatherPoint')
#def _gather_point_shape(op):
# shape1=op.inputs[0].get_shape().with_rank(3)
# shape2=op.inputs[1].get_shape().with_rank(2)
# return [tf.TensorShape([shape1.dims[0],shape2.dims[1],shape1.dims[2]])]