Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/UCSB-VRL/WildlifeMapper
/ functions
Functions
241 in github.com/UCSB-VRL/WildlifeMapper
⨍
Functions
241
◇
Types & classes
46
Method
forward
( self, hfc_embed, patch_embed, )
wildlifemapper/segment_anything/modeling/image_encoder.py:480
Method
forward
(self, x: torch.Tensor)
wildlifemapper/segment_anything/modeling/common.py:25
Method
forward
(self, x: torch.Tensor)
wildlifemapper/segment_anything/modeling/common.py:38
Method
forward
Args: image_embedding (torch.Tensor): image to attend to. Should be shape B x embedding_dim x h x w for any h and w.
wildlifemapper/segment_anything/modeling/transformer.py:62
Method
forward
( self, queries: Tensor, keys: Tensor, query_pe: Tensor, key_pe: Tensor )
wildlifemapper/segment_anything/modeling/transformer.py:151
Method
forward
(self, q: Tensor, k: Tensor, v: Tensor)
wildlifemapper/segment_anything/modeling/transformer.py:218
Method
forward
Predicts masks end-to-end from provided images and prompts. If prompts are not known in advance, using SamPredictor is recomm
wildlifemapper/segment_anything/modeling/sam.py:55
Method
forward
Embeds different types of prompts, returning both sparse and dense embeddings. Arguments: points (tuple(torch.Tens
wildlifemapper/segment_anything/modeling/prompt_encoder.py:128
Method
forward
Generate positional encoding for a grid of the specified size.
wildlifemapper/segment_anything/modeling/prompt_encoder.py:195
Method
forward
( self, image_embeddings: torch.Tensor, point_coords: torch.Tensor, point_labe
wildlifemapper/segment_anything/utils/onnx.py:108
Method
forward_with_coords
Positionally encode points that are not normalized to [0,1].
wildlifemapper/segment_anything/modeling/pos_encoder.py:72
Function
generate_crop_boxes
Generates a list of crop boxes of different sizes. Each layer has (2**i)**2 boxes for the ith layer.
wildlifemapper/segment_anything/utils/amg.py:200
Method
get_dense_pe
Returns the positional encoding used to encode point prompts, applied to a dense set of points the shape of the image encoding.
wildlifemapper/segment_anything/modeling/prompt_encoder.py:62
Method
get_image_embedding
Returns the image embeddings for the currently set image, with shape 1xCxHxW, where C is the embedding dimension and (H,W) are
wildlifemapper/segment_anything/predictor.py:245
Function
get_world_size
()
wildlifemapper/train_utils.py:66
Method
global_avg
(self)
wildlifemapper/segment_anything/utils/misc.py:260
Function
hist_equalize
(im, clahe=True, bgr=False)
wildlifemapper/segment_anything/utils/augmentation_yolo.py:49
Function
init_distributed_mode
(args)
wildlifemapper/train_utils.py:6
Function
init_distributed_mode
(args)
wildlifemapper/segment_anything/utils/misc.py:114
Function
is_box_near_crop_edge
Filter masks at the edge of a crop, but not at the edge of the original image.
wildlifemapper/segment_anything/utils/amg.py:78
Method
loss_boxes
Compute the losses related to the bounding boxes, the L1 regression loss and the GIoU loss targets dicts must contain the key "boxes" conta
wildlifemapper/segment_anything/build_sam.py:128
Method
loss_cardinality
Compute the cardinality error, ie the absolute error in the number of predicted non-empty boxes This is not really a loss, it is intended for
wildlifemapper/segment_anything/build_sam.py:115
Method
loss_labels
Classification loss (NLL) targets dicts must contain the key "labels" containing a tensor of dim [nb_target_boxes]
wildlifemapper/segment_anything/build_sam.py:93
Function
mask_to_rle_pytorch
Encodes masks to an uncompressed RLE, in the format expected by pycoco tools.
wildlifemapper/segment_anything/utils/amg.py:107
Function
masks_to_boxes
Compute the bounding boxes around the provided masks The masks should be in format [N, H, W] where N is the number of masks, (H, W) are the spati
wildlifemapper/segment_anything/utils/box_ops.py:64
Method
median
(self)
wildlifemapper/segment_anything/utils/misc.py:250
Function
mixup
(im, labels, im2, labels2)
wildlifemapper/segment_anything/utils/augmentation_yolo.py:86
Function
normalize
(x, mean=IMAGENET_MEAN, std=IMAGENET_STD, inplace=False)
wildlifemapper/segment_anything/utils/augmentation_yolo.py:22
Method
predict
Predict masks for the given input prompts, using the currently set image. Arguments: point_coords (np.ndarray or None): A
wildlifemapper/segment_anything/predictor.py:92
Function
reduce_dict
Args: input_dict (dict): all the values will be reduced average (bool): whether to do average or sum Reduce the values in the
wildlifemapper/segment_anything/utils/misc.py:150
Function
remove_small_regions
Removes small disconnected regions and holes in a mask. Returns the mask and an indicator of if the mask has been modified.
wildlifemapper/segment_anything/utils/amg.py:267
Function
rle_to_mask
Compute a binary mask from an uncompressed RLE.
wildlifemapper/segment_anything/utils/amg.py:138
Method
sanity_test
(self, img, boxes)
wildlifemapper/dataloader_coco.py:75
Function
save_on_master
(*args, **kwargs)
wildlifemapper/train_utils.py:54
Method
set_image
Calculates the image embeddings for the provided image, allowing masks to be predicted with the 'predict' method. Arguments:
wildlifemapper/segment_anything/predictor.py:34
Function
show_box
(box, ax)
wildlifemapper/visualize_prediction.py:94
Method
synchronize_between_processes
Warning: does not synchronize the deque!
wildlifemapper/segment_anything/utils/misc.py:236
Method
to_numpy
(self)
wildlifemapper/segment_anything/utils/amg.py:72
Function
uncrop_masks
( masks: torch.Tensor, crop_box: List[int], orig_h: int, orig_w: int )
wildlifemapper/segment_anything/utils/amg.py:255
Function
uncrop_points
(points: torch.Tensor, crop_box: List[int])
wildlifemapper/segment_anything/utils/amg.py:246
Method
value
(self)
wildlifemapper/segment_anything/utils/misc.py:268
← previous
201–241 of 241, ranked by callers