code
stringlengths
3
6.57k
box_list.BoxList(boxes)
self.groundtruth_lists(fields.BoxListFields.boxes)
tf.pad(one_hot_encoding, [[0, 0], [1, 0]], mode='CONSTANT')
tf.zeros(tf.stack([tf.shape(mask)
tf.shape(mask)
resized_masks_list.append(resized_mask)
self.groundtruth_has_field(fields.BoxListFields.weights)
tf.shape(groundtruth_classes)
tf.ones(num_gt)
groundtruth_weights_list.append(groundtruth_weights)
contains (optional)
tf.greater(tf.argmax(cls_targets, axis=1)
tf.Print(positive_indicator, [positive_indicator, box_list_ops.to_normalized_coordinates(groundtruth_boxlist, debug[0], debug[1])
get()
tf.range(proposal_boxlist.num_boxes()
box_list_ops.boolean_mask(proposal_boxlist, sampled_indices)
get_box_inds(proposals)
proposals.get_shape()
as_list()
any(dim is None for dim in proposals_shape)
tf.shape(proposals)
tf.ones(proposals_shape[:2], dtype=tf.int32)
tf.range(start=0, limit=proposals_shape[0])
tf.reshape(ones_mat * multiplier, [-1])
_single_image_crop_and_resize(inputs)
tf.expand_dims(single_image_features_to_crop, 0)
self._flatten_first_two_dimensions(proposal_boxes_normalized)
get_box_inds(proposal_boxes_normalized)
predicted (final)
predictions (logits)
predictions (at class index 0)
self._compute_clip_window(image_shapes)
tf.sigmoid(mask_predictions)
tf.to_float(num_detections)
_batch_decode_boxes(self, box_encodings, anchor_boxes)
tf.expand_dims(anchor_boxes, 2)
tf.reshape(tiled_anchor_boxes, [-1, 4])
tf.reshape(box_encodings, [-1, self._box_coder.code_size])
tf.reshape(decoded_boxes.get()
loss(self, prediction_dict, true_image_shapes, scope=None)
tf.name_scope(scope, 'Loss', prediction_dict.values()
self._format_groundtruth_data(true_image_shapes)
prediction_dict.get('mask_predictions')
loss(self, prediction_dict, true_image_shapes, scope=None)
tf.name_scope(scope, 'Loss', prediction_dict.values()
self._format_groundtruth_data(true_image_shapes)
prediction_dict.get('mask_predictions')
predictions (logits)
hot (or k-hot)
tf.name_scope('RPNLoss')
box_list.BoxList(anchors)
len(groundtruth_boxlists)
tf.squeeze(batch_cls_targets, axis=2)
_minibatch_subsample_fn(inputs)
tf.cast(cls_weights, tf.bool)
tf.cast(cls_targets, tf.bool)
tf.reduce_sum(batch_sampled_indices, axis=1)
tf.to_int32(batch_cls_targets)
tf.reduce_sum(localization_losses, axis=1)
tf.reduce_sum(objectness_losses, axis=1)
zero (and thus should not be matched to)
predicted (final)
predictions (logits)
predictions (at class index 0)
hot (or k-hot)
tf.name_scope('BoxClassifierLoss')
box_list.BoxList(proposal_boxes_single_image)
tf.unstack(proposal_boxes)
len(proposal_boxlists)
tf.maximum(num_proposals, tf.ones_like(num_proposals)
flat_cls_targets_with_background.get_shape()
tf.greater(one_hot_flat_cls_targets_with_background, 0)
tf.boolean_mask(second_stage_loc_losses, paddings_indicator)
tf.boolean_mask(second_stage_cls_losses, paddings_indicator)
tf.zeros(image_shape[1:3], dtype=tf.float32)
prediction_masks.get_shape()
as_list()
tf.greater(one_hot_flat_cls_targets_with_background, 0)
tf.shape(batch_mask_targets)
box_list.BoxList(tf.reshape(proposal_boxes, [-1, 4])
get()
tf.expand_dims(flat_gt_masks, -1)
tf.range(flat_normalized_proposals.shape[0].value)
tf.ones((batch_size, 1)
tf.boolean_mask(second_stage_mask_losses, paddings_indicator)
image (integer)
tf.size(num_proposals)
tf.expand_dims(num_proposals, 1)
tf.expand_dims(tf.range(max_num_proposals)
tf.greater(tiled_num_proposals, tiled_proposal_index)
tf.unstack(second_stage_loc_losses)
tf.unstack(second_stage_cls_losses)
tf.unstack(num_proposals)
tf.slice(proposal_boxlist.get()
tf.expand_dims(single_image_loc_loss, 0)
tf.expand_dims(single_image_cls_loss, 0)
checkpoint (with compatible variable names)
names (to load from a checkpoint)
tf.global_variables()
variables_to_restore.append(slim.get_or_create_global_step()