SYMBOL INDEX (4580 symbols across 336 files) FILE: asone/asone.py class ASOne (line 20) | class ASOne: method __init__ (line 21) | def __init__(self, method get_detector (line 54) | def get_detector(self, detector: int, weights: str, recognizer, num_cl... method get_recognizer (line 59) | def get_recognizer(self, recognizer: int, languages): method get_tracker (line 67) | def get_tracker(self, tracker: int): method get_segmentor (line 72) | def get_segmentor(self, segmentor, segmentor_weights): method _update_args (line 76) | def _update_args(self, kwargs): method track_stream (line 85) | def track_stream(self, method stream_tracker (line 103) | def stream_tracker(self, method track_video (line 116) | def track_video(self, method video_tracker (line 134) | def video_tracker(self, method detect_video (line 146) | def detect_video(self, method video_detecter (line 164) | def video_detecter(self, method detect (line 176) | def detect(self, source, **kwargs)->np.ndarray: method detecter (line 194) | def detecter(self, source, **kwargs): method detect_and_track (line 213) | def detect_and_track(self, frame, **kwargs): method detect_track_manager (line 227) | def detect_track_manager(self, frame, **kwargs): method detect_text (line 243) | def detect_text(self, image): method track_webcam (line 251) | def track_webcam(self, method webcam_tracker (line 270) | def webcam_tracker(self, method _start_tracking (line 284) | def _start_tracking(self, method draw (line 377) | def draw(dets, display=False, img=None, **kwargs): method draw_masks (line 413) | def draw_masks(dets, display, img=None, **kwargs): method read_video (line 457) | def read_video(self, video_path): method format_output (line 462) | def format_output(self, bbox_details, frame_details): FILE: asone/demo_detector.py function main (line 8) | def main(args): FILE: asone/demo_ocr.py function main (line 5) | def main(args): FILE: asone/demo_pose_estimator.py function main (line 10) | def main(args): FILE: asone/demo_segmentor.py function main (line 8) | def main(args): FILE: asone/demo_tracker.py function main (line 10) | def main(args): FILE: asone/detectors/detector.py class Detector (line 7) | class Detector: method __init__ (line 8) | def __init__(self, method _select_detector (line 16) | def _select_detector(self, model_flag, weights, cuda, recognizer, num_... method get_detector (line 106) | def get_detector(self): method detect (line 109) | def detect(self, FILE: asone/detectors/easyocr_detector/text_detector.py class TextDetector (line 5) | class TextDetector: method __init__ (line 6) | def __init__(self, detect_network, languages: list = ['en'], use_cuda=... method detect (line 11) | def detect(self, image: list, freelist: bool=False, return_image=Fals... FILE: asone/detectors/utils/cfg_path.py function get_cfg_path (line 9) | def get_cfg_path(model_flag): FILE: asone/detectors/utils/coreml_utils.py function yolo_to_xyxy (line 4) | def yolo_to_xyxy(bboxes, img_size): function generalize_output_format (line 20) | def generalize_output_format(bboxes, confidence_list, conf_thres): function scale_bboxes (line 42) | def scale_bboxes(bboxes, org_img_shape, resized_img_shape): FILE: asone/detectors/utils/exp_name.py function get_exp__name (line 15) | def get_exp__name(model_flag): FILE: asone/detectors/utils/weights_path.py function get_weight_path (line 138) | def get_weight_path(model_flag): FILE: asone/detectors/yolonas/yolonas.py class YOLOnasDetector (line 20) | class YOLOnasDetector: method __init__ (line 21) | def __init__(self, method load_model (line 45) | def load_model(self, weights): method detect (line 66) | def detect(self, image: list, FILE: asone/detectors/yolor/models/common.py class DWT (line 17) | class DWT(nn.Module): method __init__ (line 18) | def __init__(self): method forward (line 22) | def forward(self, x): method __init__ (line 29) | def __init__(self): method forward (line 32) | def forward(self, x): class DWT (line 28) | class DWT(nn.Module): # use ReOrg instead method __init__ (line 18) | def __init__(self): method forward (line 22) | def forward(self, x): method __init__ (line 29) | def __init__(self): method forward (line 32) | def forward(self, x): class ImplicitA (line 36) | class ImplicitA(nn.Module): method __init__ (line 37) | def __init__(self, channel): method forward (line 43) | def forward(self, x): class ImplicitM (line 47) | class ImplicitM(nn.Module): method __init__ (line 48) | def __init__(self, channel): method forward (line 54) | def forward(self, x): class ReOrg (line 58) | class ReOrg(nn.Module): method __init__ (line 59) | def __init__(self): method forward (line 62) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) function autopad (line 65) | def autopad(k, p=None): # kernel, padding function DWConv (line 72) | def DWConv(c1, c2, k=1, s=1, act=True): class Conv (line 77) | class Conv(nn.Module): method __init__ (line 79) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 85) | def forward(self, x): method fuseforward (line 88) | def fuseforward(self, x): class ConvSig (line 92) | class ConvSig(nn.Module): method __init__ (line 94) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 99) | def forward(self, x): method fuseforward (line 102) | def fuseforward(self, x): class ConvSqu (line 106) | class ConvSqu(nn.Module): method __init__ (line 108) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 113) | def forward(self, x): method fuseforward (line 116) | def fuseforward(self, x): class Bottleneck (line 120) | class Bottleneck(nn.Module): method __init__ (line 122) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 129) | def forward(self, x): class BottleneckG (line 133) | class BottleneckG(nn.Module): method __init__ (line 135) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 142) | def forward(self, x): class BottleneckCSP (line 146) | class BottleneckCSP(nn.Module): method __init__ (line 148) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 159) | def forward(self, x): class BottleneckCSPF (line 165) | class BottleneckCSPF(nn.Module): method __init__ (line 167) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 178) | def forward(self, x): class BottleneckCSPL (line 184) | class BottleneckCSPL(nn.Module): method __init__ (line 186) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 197) | def forward(self, x): class BottleneckCSPLG (line 203) | class BottleneckCSPLG(nn.Module): method __init__ (line 205) | def __init__(self, c1, c2, n=1, shortcut=True, g=3, e=0.25): # ch_in,... method forward (line 216) | def forward(self, x): class BottleneckCSPSE (line 222) | class BottleneckCSPSE(nn.Module): method __init__ (line 224) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 238) | def forward(self, x): class BottleneckCSPSEA (line 245) | class BottleneckCSPSEA(nn.Module): method __init__ (line 247) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 261) | def forward(self, x): class BottleneckCSPSAM (line 268) | class BottleneckCSPSAM(nn.Module): method __init__ (line 270) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 282) | def forward(self, x): class BottleneckCSPSAMA (line 289) | class BottleneckCSPSAMA(nn.Module): method __init__ (line 291) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 303) | def forward(self, x): class BottleneckCSPSAMB (line 310) | class BottleneckCSPSAMB(nn.Module): method __init__ (line 312) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 324) | def forward(self, x): class BottleneckCSPGC (line 331) | class BottleneckCSPGC(nn.Module): method __init__ (line 333) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method spatial_pool (line 353) | def spatial_pool(self, x): method forward (line 377) | def forward(self, x): class BottleneckCSPDNL (line 385) | class BottleneckCSPDNL(nn.Module): method __init__ (line 387) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 409) | def forward(self, x): class BottleneckCSP2 (line 456) | class BottleneckCSP2(nn.Module): method __init__ (line 458) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 468) | def forward(self, x): class BottleneckCSP2SAM (line 475) | class BottleneckCSP2SAM(nn.Module): method __init__ (line 477) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 488) | def forward(self, x): class VoVCSP (line 496) | class VoVCSP(nn.Module): method __init__ (line 498) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 505) | def forward(self, x): class SPP (line 512) | class SPP(nn.Module): method __init__ (line 514) | def __init__(self, c1, c2, k=(5, 9, 13)): method forward (line 521) | def forward(self, x): class SPPCSP (line 526) | class SPPCSP(nn.Module): method __init__ (line 528) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... method forward (line 542) | def forward(self, x): class Focus (line 549) | class Focus(nn.Module): method __init__ (line 551) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 555) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class MP (line 559) | class MP(nn.Module): method __init__ (line 561) | def __init__(self, k=2): method forward (line 565) | def forward(self, x): class DownD (line 569) | class DownD(nn.Module): method __init__ (line 571) | def __init__(self, c1, c2, n=1, k=2): method forward (line 580) | def forward(self, x): class DownC (line 584) | class DownC(nn.Module): method __init__ (line 586) | def __init__(self, c1, c2, n=1, k=2): method forward (line 594) | def forward(self, x): class DNL (line 598) | class DNL(nn.Module): method __init__ (line 600) | def __init__(self, c1, c2, k=3, s=1): method forward (line 622) | def forward(self, x): class GC (line 678) | class GC(nn.Module): method __init__ (line 680) | def __init__(self, c1, c2, k=3, s=1): method spatial_pool (line 697) | def spatial_pool(self, x): method forward (line 721) | def forward(self, x): class SAM (line 726) | class SAM(nn.Module): method __init__ (line 728) | def __init__(self, c1, c2, k=3, s=1): method forward (line 734) | def forward(self, x): class SAMA (line 739) | class SAMA(nn.Module): method __init__ (line 741) | def __init__(self, c1, c2, k=3, s=1): method forward (line 747) | def forward(self, x): class SAMB (line 752) | class SAMB(nn.Module): method __init__ (line 754) | def __init__(self, c1, c2, k=3, s=1): method forward (line 760) | def forward(self, x): class Concat (line 767) | class Concat(nn.Module): method __init__ (line 769) | def __init__(self, dimension=1): method forward (line 773) | def forward(self, x): class NMS (line 777) | class NMS(nn.Module): method __init__ (line 783) | def __init__(self): method forward (line 786) | def forward(self, x): class autoShape (line 790) | class autoShape(nn.Module): method __init__ (line 797) | def __init__(self, model): method forward (line 801) | def forward(self, imgs, size=640, augment=False, profile=False): class Detections (line 844) | class Detections: method __init__ (line 846) | def __init__(self, imgs, pred, names=None): method display (line 857) | def display(self, pprint=False, show=False, save=False): method print (line 879) | def print(self): method show (line 882) | def show(self): method save (line 885) | def save(self): class Flatten (line 889) | class Flatten(nn.Module): method forward (line 892) | def forward(x): class Classify (line 896) | class Classify(nn.Module): method __init__ (line 898) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1): # ch_in, ch_out, k... method forward (line 904) | def forward(self, x): class TransformerLayer (line 909) | class TransformerLayer(nn.Module): method __init__ (line 910) | def __init__(self, c, num_heads): method forward (line 922) | def forward(self, x): class TransformerBlock (line 930) | class TransformerBlock(nn.Module): method __init__ (line 931) | def __init__(self, c1, c2, num_heads, num_layers): method forward (line 941) | def forward(self, x): class BottleneckCSPTR (line 960) | class BottleneckCSPTR(nn.Module): method __init__ (line 962) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 973) | def forward(self, x): class BottleneckCSP2TR (line 978) | class BottleneckCSP2TR(nn.Module): method __init__ (line 980) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 990) | def forward(self, x): class SPPCSPTR (line 997) | class SPPCSPTR(nn.Module): method __init__ (line 999) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... method forward (line 1013) | def forward(self, x): class TR (line 1019) | class TR(BottleneckCSPTR): method __init__ (line 1020) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): FILE: asone/detectors/yolor/models/models.py function create_modules (line 9) | def create_modules(module_defs, img_size, cfg): class YOLOLayer (line 339) | class YOLOLayer(nn.Module): method __init__ (line 340) | def __init__(self, anchors, nc, img_size, yolo_index, layers, stride): method create_grids (line 358) | def create_grids(self, ng=(13, 13), device='cpu'): method forward (line 371) | def forward(self, p, out): class JDELayer (line 432) | class JDELayer(nn.Module): method __init__ (line 433) | def __init__(self, anchors, nc, img_size, yolo_index, layers, stride): method create_grids (line 451) | def create_grids(self, ng=(13, 13), device='cpu'): method forward (line 464) | def forward(self, p, out): class Darknet (line 524) | class Darknet(nn.Module): method __init__ (line 527) | def __init__(self, cfg, img_size=(416, 416), verbose=False): method forward (line 540) | def forward(self, x, augment=False, verbose=False): method forward_once (line 570) | def forward_once(self, x, augment=False, verbose=False): method fuse (line 627) | def fuse(self): method info (line 644) | def info(self, verbose=False): function get_yolo_layers (line 648) | def get_yolo_layers(model): function load_darknet_weights (line 652) | def load_darknet_weights(self, weights, cutoff=-1): function save_weights (line 702) | def save_weights(self, path='model.weights', cutoff=-1): function convert (line 728) | def convert(cfg='cfg/yolov3-spp.cfg', weights='weights/yolov3-spp.weight... function attempt_download (line 742) | def attempt_download(weights): FILE: asone/detectors/yolor/utils/activations.py class Swish (line 9) | class Swish(nn.Module): # method forward (line 11) | def forward(x): class Hardswish (line 15) | class Hardswish(nn.Module): # export-friendly version of nn.Hardswish() method forward (line 17) | def forward(x): class MemoryEfficientSwish (line 22) | class MemoryEfficientSwish(nn.Module): class F (line 23) | class F(torch.autograd.Function): method forward (line 25) | def forward(ctx, x): method backward (line 30) | def backward(ctx, grad_output): method forward (line 35) | def forward(self, x): class Mish (line 40) | class Mish(nn.Module): method forward (line 42) | def forward(x): class MemoryEfficientMish (line 46) | class MemoryEfficientMish(nn.Module): class F (line 47) | class F(torch.autograd.Function): method forward (line 49) | def forward(ctx, x): method backward (line 54) | def backward(ctx, grad_output): method forward (line 60) | def forward(self, x): class FReLU (line 65) | class FReLU(nn.Module): method __init__ (line 66) | def __init__(self, c1, k=3): # ch_in, kernel method forward (line 71) | def forward(self, x): FILE: asone/detectors/yolor/utils/autoanchor.py function check_anchor_order (line 10) | def check_anchor_order(m): function check_anchors (line 21) | def check_anchors(dataset, model, thr=4.0, imgsz=640): function kmean_anchors (line 55) | def kmean_anchors(path='./data/coco128.yaml', n=9, img_size=640, thr=4.0... FILE: asone/detectors/yolor/utils/datasets.py function get_hash (line 40) | def get_hash(files): function exif_size (line 45) | def exif_size(img): function create_dataloader (line 60) | def create_dataloader(path, imgsz, batch_size, stride, opt, hyp=None, au... function create_dataloader9 (line 86) | def create_dataloader9(path, imgsz, batch_size, stride, opt, hyp=None, a... class InfiniteDataLoader (line 112) | class InfiniteDataLoader(torch.utils.data.dataloader.DataLoader): method __init__ (line 118) | def __init__(self, *args, **kwargs): method __len__ (line 123) | def __len__(self): method __iter__ (line 126) | def __iter__(self): class _RepeatSampler (line 131) | class _RepeatSampler(object): method __init__ (line 138) | def __init__(self, sampler): method __iter__ (line 141) | def __iter__(self): class LoadImages (line 146) | class LoadImages: # for inference method __init__ (line 147) | def __init__(self, path, img_size=640, auto_size=32): method __iter__ (line 176) | def __iter__(self): method __next__ (line 180) | def __next__(self): method new_video (line 218) | def new_video(self, path): method __len__ (line 223) | def __len__(self): class LoadWebcam (line 227) | class LoadWebcam: # for inference method __init__ (line 228) | def __init__(self, pipe='0', img_size=640): method __iter__ (line 241) | def __iter__(self): method __next__ (line 245) | def __next__(self): method __len__ (line 280) | def __len__(self): class LoadStreams (line 284) | class LoadStreams: # multiple IP or RTSP cameras method __init__ (line 285) | def __init__(self, sources='streams.txt', img_size=640): method update (line 318) | def update(self, index, cap): method __iter__ (line 330) | def __iter__(self): method __next__ (line 334) | def __next__(self): method __len__ (line 353) | def __len__(self): class LoadImagesAndLabels (line 357) | class LoadImagesAndLabels(Dataset): # for training/testing method __init__ (line 358) | def __init__(self, path, img_size=640, batch_size=16, augment=False, h... method cache_labels (line 513) | def cache_labels(self, path='labels.cache3'): method __len__ (line 537) | def __len__(self): method __getitem__ (line 546) | def __getitem__(self, index): method collate_fn (line 633) | def collate_fn(batch): class LoadImagesAndLabels9 (line 640) | class LoadImagesAndLabels9(Dataset): # for training/testing method __init__ (line 641) | def __init__(self, path, img_size=640, batch_size=16, augment=False, h... method cache_labels (line 796) | def cache_labels(self, path='labels.cache3'): method __len__ (line 820) | def __len__(self): method __getitem__ (line 829) | def __getitem__(self, index): method collate_fn (line 916) | def collate_fn(batch): function load_image (line 924) | def load_image(self, index): function augment_hsv (line 941) | def augment_hsv(img, hgain=0.5, sgain=0.5, vgain=0.5): function load_mosaic (line 960) | def load_mosaic(self, index): function load_mosaic9 (line 1018) | def load_mosaic9(self, index): function replicate (line 1092) | def replicate(img, labels): function letterbox (line 1109) | def letterbox(img, new_shape=(640, 640), color=(114, 114, 114), auto=Tru... function random_perspective (line 1142) | def random_perspective(img, targets=(), degrees=10, translate=.1, scale=... function box_candidates (line 1229) | def box_candidates(box1, box2, wh_thr=2, ar_thr=20, area_thr=0.1): # bo... function cutout (line 1237) | def cutout(image, labels): function create_folder (line 1283) | def create_folder(path='./new'): function flatten_recursive (line 1290) | def flatten_recursive(path='../coco128'): FILE: asone/detectors/yolor/utils/general.py function set_logging (line 33) | def set_logging(rank=-1): function init_seeds (line 39) | def init_seeds(seed=0): function get_latest_run (line 45) | def get_latest_run(search_dir='.'): function check_git_status (line 51) | def check_git_status(): function check_img_size (line 59) | def check_img_size(img_size, s=32): function check_file (line 67) | def check_file(file): function check_dataset (line 78) | def check_dataset(dict): function make_divisible (line 98) | def make_divisible(x, divisor): function labels_to_class_weights (line 103) | def labels_to_class_weights(labels, nc=80): function labels_to_image_weights (line 122) | def labels_to_image_weights(labels, nc=80, class_weights=np.ones(80)): function coco80_to_coco91_class (line 131) | def coco80_to_coco91_class(): # converts 80-index (val2014) to 91-index... function xyxy2xywh (line 143) | def xyxy2xywh(x): function xywh2xyxy (line 153) | def xywh2xyxy(x): function scale_coords (line 163) | def scale_coords(img1_shape, coords, img0_shape, ratio_pad=None): function clip_coords (line 179) | def clip_coords(boxes, img_shape): function bbox_iou (line 187) | def bbox_iou(box1, box2, x1y1x2y2=True, GIoU=False, DIoU=False, CIoU=Fal... function box_iou (line 247) | def box_iou(box1, box2): function wh_iou (line 272) | def wh_iou(wh1, wh2): function non_max_suppression (line 280) | def non_max_suppression(prediction, conf_thres=0.1, iou_thres=0.6, merge... function strip_optimizer (line 359) | def strip_optimizer(f='weights/best.pt', s=''): # from utils.general im... function print_mutation (line 373) | def print_mutation(hyp, results, yaml_file='hyp_evolved.yaml', bucket=''): function apply_classifier (line 404) | def apply_classifier(x, model, img, im0): function increment_path (line 439) | def increment_path(path, exist_ok=True, sep=''): FILE: asone/detectors/yolor/utils/google_utils.py function gsutil_getsize (line 13) | def gsutil_getsize(url=''): function attempt_download (line 19) | def attempt_download(weights): function attempt_load (line 39) | def attempt_load(weights, map_location=None): function gdrive_download (line 55) | def gdrive_download(id='1n_oKgR81BJtqk75b00eAjdv03qVCQn2f', name='coco12... function get_token (line 89) | def get_token(cookie="./cookie"): class Ensemble (line 96) | class Ensemble(nn.ModuleList): method __init__ (line 98) | def __init__(self): method forward (line 101) | def forward(self, x, augment=False, profile=False, visualize=False): FILE: asone/detectors/yolor/utils/layers.py class Mish (line 10) | class Mish(nn.Module): # https://github.com/digantamisra98/Mish method forward (line 11) | def forward(self, x): class DWT (line 17) | class DWT(nn.Module): method __init__ (line 18) | def __init__(self): method forward (line 22) | def forward(self, x): method forward (line 29) | def forward(self, x): class DWT (line 28) | class DWT(nn.Module): method __init__ (line 18) | def __init__(self): method forward (line 22) | def forward(self, x): method forward (line 29) | def forward(self, x): class Reorg (line 33) | class Reorg(nn.Module): method forward (line 34) | def forward(self, x): function make_divisible (line 38) | def make_divisible(v, divisor): class Flatten (line 44) | class Flatten(nn.Module): method forward (line 46) | def forward(self, x): class Concat (line 50) | class Concat(nn.Module): method __init__ (line 52) | def __init__(self, dimension=1): method forward (line 56) | def forward(self, x): class FeatureConcat (line 60) | class FeatureConcat(nn.Module): method __init__ (line 61) | def __init__(self, layers): method forward (line 66) | def forward(self, x, outputs): class FeatureConcat2 (line 70) | class FeatureConcat2(nn.Module): method __init__ (line 71) | def __init__(self, layers): method forward (line 76) | def forward(self, x, outputs): class FeatureConcat3 (line 80) | class FeatureConcat3(nn.Module): method __init__ (line 81) | def __init__(self, layers): method forward (line 86) | def forward(self, x, outputs): class FeatureConcat_l (line 90) | class FeatureConcat_l(nn.Module): method __init__ (line 91) | def __init__(self, layers): method forward (line 96) | def forward(self, x, outputs): class WeightedFeatureFusion (line 100) | class WeightedFeatureFusion(nn.Module): # weighted sum of 2 or more lay... method __init__ (line 101) | def __init__(self, layers, weight=False): method forward (line 109) | def forward(self, x, outputs): class MixConv2d (line 132) | class MixConv2d(nn.Module): # MixConv: Mixed Depthwise Convolutional Ke... method __init__ (line 133) | def __init__(self, in_ch, out_ch, k=(3, 5, 7), stride=1, dilation=1, b... method forward (line 156) | def forward(self, x): class SwishImplementation (line 161) | class SwishImplementation(torch.autograd.Function): method forward (line 163) | def forward(ctx, x): method backward (line 168) | def backward(ctx, grad_output): class MishImplementation (line 174) | class MishImplementation(torch.autograd.Function): method forward (line 176) | def forward(ctx, x): method backward (line 181) | def backward(ctx, grad_output): class MemoryEfficientSwish (line 188) | class MemoryEfficientSwish(nn.Module): method forward (line 189) | def forward(self, x): class MemoryEfficientMish (line 193) | class MemoryEfficientMish(nn.Module): method forward (line 194) | def forward(self, x): class Swish (line 198) | class Swish(nn.Module): method forward (line 199) | def forward(self, x): class HardSwish (line 203) | class HardSwish(nn.Module): # https://arxiv.org/pdf/1905.02244.pdf method forward (line 204) | def forward(self, x): class DeformConv2d (line 208) | class DeformConv2d(nn.Module): method __init__ (line 209) | def __init__(self, inc, outc, kernel_size=3, padding=1, stride=1, bias... method _set_lr (line 232) | def _set_lr(module, grad_input, grad_output): method forward (line 236) | def forward(self, x): method _get_p_n (line 294) | def _get_p_n(self, N, dtype): method _get_p_0 (line 304) | def _get_p_0(self, h, w, N, dtype): method _get_p (line 314) | def _get_p(self, offset, dtype): method _get_x_q (line 324) | def _get_x_q(self, x, q, N): method _reshape_x_offset (line 341) | def _reshape_x_offset(x_offset, ks): class GAP (line 349) | class GAP(nn.Module): method __init__ (line 350) | def __init__(self): method forward (line 353) | def forward(self, x): class Silence (line 358) | class Silence(nn.Module): method __init__ (line 359) | def __init__(self): method forward (line 361) | def forward(self, x): class ScaleChannel (line 365) | class ScaleChannel(nn.Module): # weighted sum of 2 or more layers https... method __init__ (line 366) | def __init__(self, layers): method forward (line 370) | def forward(self, x, outputs): class ShiftChannel (line 375) | class ShiftChannel(nn.Module): # weighted sum of 2 or more layers https... method __init__ (line 376) | def __init__(self, layers): method forward (line 380) | def forward(self, x, outputs): class ShiftChannel2D (line 385) | class ShiftChannel2D(nn.Module): # weighted sum of 2 or more layers htt... method __init__ (line 386) | def __init__(self, layers): method forward (line 390) | def forward(self, x, outputs): class ControlChannel (line 395) | class ControlChannel(nn.Module): # weighted sum of 2 or more layers htt... method __init__ (line 396) | def __init__(self, layers): method forward (line 400) | def forward(self, x, outputs): class ControlChannel2D (line 405) | class ControlChannel2D(nn.Module): # weighted sum of 2 or more layers h... method __init__ (line 406) | def __init__(self, layers): method forward (line 410) | def forward(self, x, outputs): class AlternateChannel (line 415) | class AlternateChannel(nn.Module): # weighted sum of 2 or more layers h... method __init__ (line 416) | def __init__(self, layers): method forward (line 420) | def forward(self, x, outputs): class AlternateChannel2D (line 425) | class AlternateChannel2D(nn.Module): # weighted sum of 2 or more layers... method __init__ (line 426) | def __init__(self, layers): method forward (line 430) | def forward(self, x, outputs): class SelectChannel (line 435) | class SelectChannel(nn.Module): # weighted sum of 2 or more layers http... method __init__ (line 436) | def __init__(self, layers): method forward (line 440) | def forward(self, x, outputs): class SelectChannel2D (line 445) | class SelectChannel2D(nn.Module): # weighted sum of 2 or more layers ht... method __init__ (line 446) | def __init__(self, layers): method forward (line 450) | def forward(self, x, outputs): class ScaleSpatial (line 455) | class ScaleSpatial(nn.Module): # weighted sum of 2 or more layers https... method __init__ (line 456) | def __init__(self, layers): method forward (line 460) | def forward(self, x, outputs): class ImplicitA (line 465) | class ImplicitA(nn.Module): method __init__ (line 466) | def __init__(self, channel): method forward (line 472) | def forward(self): class ImplicitC (line 476) | class ImplicitC(nn.Module): method __init__ (line 477) | def __init__(self, channel): method forward (line 483) | def forward(self): class ImplicitM (line 487) | class ImplicitM(nn.Module): method __init__ (line 488) | def __init__(self, channel): method forward (line 494) | def forward(self): class Implicit2DA (line 499) | class Implicit2DA(nn.Module): method __init__ (line 500) | def __init__(self, atom, channel): method forward (line 506) | def forward(self): class Implicit2DC (line 510) | class Implicit2DC(nn.Module): method __init__ (line 511) | def __init__(self, atom, channel): method forward (line 517) | def forward(self): class Implicit2DM (line 521) | class Implicit2DM(nn.Module): method __init__ (line 522) | def __init__(self, atom, channel): method forward (line 528) | def forward(self): FILE: asone/detectors/yolor/utils/loss.py function smooth_BCE (line 10) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class BCEBlurWithLogitsLoss (line 15) | class BCEBlurWithLogitsLoss(nn.Module): method __init__ (line 17) | def __init__(self, alpha=0.05): method forward (line 22) | def forward(self, pred, true): class FocalLoss (line 32) | class FocalLoss(nn.Module): method __init__ (line 34) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 42) | def forward(self, pred, true): function compute_loss (line 62) | def compute_loss(p, targets, model): # predictions, targets, model function build_targets (line 127) | def build_targets(p, targets, model): FILE: asone/detectors/yolor/utils/metrics.py function fitness (line 7) | def fitness(x): function fitness_p (line 13) | def fitness_p(x): function fitness_r (line 19) | def fitness_r(x): function fitness_ap50 (line 25) | def fitness_ap50(x): function fitness_ap (line 31) | def fitness_ap(x): function fitness_f (line 37) | def fitness_f(x): function ap_per_class (line 43) | def ap_per_class(tp, conf, pred_cls, target_cls, plot=False, fname='prec... function compute_ap (line 114) | def compute_ap(recall, precision): FILE: asone/detectors/yolor/utils/parse_config.py function parse_model_cfg (line 6) | def parse_model_cfg(path): function parse_data_cfg (line 55) | def parse_data_cfg(path): FILE: asone/detectors/yolor/utils/plots.py function color_list (line 26) | def color_list(): function hist2d (line 34) | def hist2d(x, y, n=100): function butter_lowpass_filtfilt (line 43) | def butter_lowpass_filtfilt(data, cutoff=1500, fs=50000, order=5): function plot_one_box (line 54) | def plot_one_box(x, img, color=None, label=None, line_thickness=None): function plot_wh_methods (line 68) | def plot_wh_methods(): # from utils.general import *; plot_wh_methods() function output_to_target (line 89) | def output_to_target(output, width, height): function plot_images (line 111) | def plot_images(images, targets, paths=None, fname='images.jpg', names=N... function plot_lr_scheduler (line 186) | def plot_lr_scheduler(optimizer, scheduler, epochs=300, save_dir=''): function plot_test_txt (line 203) | def plot_test_txt(): # from utils.general import *; plot_test() function plot_targets_txt (line 220) | def plot_targets_txt(): # from utils.general import *; plot_targets_txt() function plot_study_txt (line 233) | def plot_study_txt(f='study.txt', x=None): # from utils.general import ... function plot_labels (line 265) | def plot_labels(labels, save_dir=''): function plot_evolution (line 297) | def plot_evolution(yaml_file='data/hyp.finetune.yaml'): # from utils.ge... function plot_results_overlay (line 321) | def plot_results_overlay(start=0, stop=0): # from utils.general import ... function plot_results (line 344) | def plot_results(start=0, stop=0, bucket='', id=(), labels=(), save_dir=... FILE: asone/detectors/yolor/utils/torch_utils.py function torch_distributed_zero_first (line 20) | def torch_distributed_zero_first(local_rank: int): function init_torch_seeds (line 31) | def init_torch_seeds(seed=0): function select_device (line 42) | def select_device(device='', batch_size=None): function time_synchronized (line 68) | def time_synchronized(): function is_parallel (line 73) | def is_parallel(model): function intersect_dicts (line 77) | def intersect_dicts(da, db, exclude=()): function initialize_weights (line 82) | def initialize_weights(model): function find_modules (line 94) | def find_modules(model, mclass=nn.Conv2d): function sparsity (line 99) | def sparsity(model): function prune (line 108) | def prune(model, amount=0.3): function fuse_conv_and_bn (line 119) | def fuse_conv_and_bn(conv, bn): function model_info (line 142) | def model_info(model, verbose=False, img_size=640): function load_classifier (line 164) | def load_classifier(name='resnet101', n=2): function scale_img (line 183) | def scale_img(img, ratio=1.0, same_shape=False): # img(16,3,256,416), r... function copy_attr (line 197) | def copy_attr(a, b, include=(), exclude=()): class ModelEMA (line 206) | class ModelEMA: method __init__ (line 216) | def __init__(self, model, decay=0.9999, updates=0): method update (line 226) | def update(self, model): method update_attr (line 238) | def update_attr(self, model, include=(), exclude=('process_group', 're... FILE: asone/detectors/yolor/utils/yolor_utils.py function box_area (line 14) | def box_area(box): function box_iou (line 19) | def box_iou(box1, box2, eps=1e-7): function xywh2xyxy (line 39) | def xywh2xyxy(x): function non_max_suppression (line 48) | def non_max_suppression(prediction, function letterbox (line 148) | def letterbox(im, new_shape=(640, 640), color=(114, 114, 114), auto=True... function scale_coords (line 180) | def scale_coords(img1_shape, coords, img0_shape, ratio_pad=None): function clip_coords (line 196) | def clip_coords(boxes, shape): FILE: asone/detectors/yolor/yolor_detector.py class YOLOrDetector (line 18) | class YOLOrDetector: method __init__ (line 19) | def __init__(self, method load_model (line 40) | def load_model(self, use_cuda, weights, cfg, img_size, fp16=False): method image_preprocessing (line 60) | def image_preprocessing(self, method detect (line 73) | def detect(self, image: list, FILE: asone/detectors/yolov5/yolov5/export.py class iOSModel (line 93) | class iOSModel(torch.nn.Module): method __init__ (line 94) | def __init__(self, model, im): method forward (line 107) | def forward(self, x): function export_formats (line 113) | def export_formats(): function try_export (line 132) | def try_export(inner_func): function export_torchscript (line 151) | def export_torchscript(model, im, file, optimize, prefix=colorstr("Torch... function export_onnx (line 169) | def export_onnx(model, im, file, opset, dynamic, simplify, prefix=colors... function export_openvino (line 226) | def export_openvino(file, metadata, half, int8, data, prefix=colorstr("O... function export_paddle (line 282) | def export_paddle(model, im, file, metadata, prefix=colorstr("PaddlePadd... function export_coreml (line 299) | def export_coreml(model, im, file, int8, half, nms, prefix=colorstr("Cor... function export_engine (line 324) | def export_engine(model, im, file, half, dynamic, simplify, workspace=4,... function export_saved_model (line 390) | def export_saved_model( function export_pb (line 453) | def export_pb(keras_model, file, prefix=colorstr("TensorFlow GraphDef:")): function export_tflite (line 470) | def export_tflite( function export_edgetpu (line 506) | def export_edgetpu(file, prefix=colorstr("Edge TPU:")): function export_tfjs (line 548) | def export_tfjs(file, int8, prefix=colorstr("TensorFlow.js:")): function add_tflite_metadata (line 585) | def add_tflite_metadata(file, metadata, num_outputs): function pipeline_coreml (line 622) | def pipeline_coreml(model, im, file, names, y, prefix=colorstr("CoreML P... function run (line 756) | def run( function parse_opt (line 892) | def parse_opt(known=False): function main (line 928) | def main(opt): FILE: asone/detectors/yolov5/yolov5/models/common.py function autopad (line 28) | def autopad(k, p=None): # kernel, padding class Conv (line 35) | class Conv(nn.Module): method __init__ (line 37) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 43) | def forward(self, x): method forward_fuse (line 46) | def forward_fuse(self, x): class DWConv (line 50) | class DWConv(Conv): method __init__ (line 52) | def __init__(self, c1, c2, k=1, s=1, act=True): # ch_in, ch_out, kern... class DWConvTranspose2d (line 56) | class DWConvTranspose2d(nn.ConvTranspose2d): method __init__ (line 58) | def __init__(self, c1, c2, k=1, s=1, p1=0, p2=0): # ch_in, ch_out, ke... class TransformerLayer (line 62) | class TransformerLayer(nn.Module): method __init__ (line 64) | def __init__(self, c, num_heads): method forward (line 73) | def forward(self, x): class TransformerBlock (line 79) | class TransformerBlock(nn.Module): method __init__ (line 81) | def __init__(self, c1, c2, num_heads, num_layers): method forward (line 90) | def forward(self, x): class Bottleneck (line 98) | class Bottleneck(nn.Module): method __init__ (line 100) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 107) | def forward(self, x): class BottleneckCSP (line 111) | class BottleneckCSP(nn.Module): method __init__ (line 113) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 124) | def forward(self, x): class CrossConv (line 130) | class CrossConv(nn.Module): method __init__ (line 132) | def __init__(self, c1, c2, k=3, s=1, g=1, e=1.0, shortcut=False): method forward (line 140) | def forward(self, x): class C3 (line 144) | class C3(nn.Module): method __init__ (line 146) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 154) | def forward(self, x): class C3x (line 158) | class C3x(C3): method __init__ (line 160) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): class C3TR (line 166) | class C3TR(C3): method __init__ (line 168) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): class C3SPP (line 174) | class C3SPP(C3): method __init__ (line 176) | def __init__(self, c1, c2, k=(5, 9, 13), n=1, shortcut=True, g=1, e=0.5): class C3Ghost (line 182) | class C3Ghost(C3): method __init__ (line 184) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): class SPP (line 190) | class SPP(nn.Module): method __init__ (line 192) | def __init__(self, c1, c2, k=(5, 9, 13)): method forward (line 199) | def forward(self, x): class SPPF (line 206) | class SPPF(nn.Module): method __init__ (line 208) | def __init__(self, c1, c2, k=5): # equivalent to SPP(k=(5, 9, 13)) method forward (line 215) | def forward(self, x): class Focus (line 224) | class Focus(nn.Module): method __init__ (line 226) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 231) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class GhostConv (line 236) | class GhostConv(nn.Module): method __init__ (line 238) | def __init__(self, c1, c2, k=1, s=1, g=1, act=True): # ch_in, ch_out,... method forward (line 244) | def forward(self, x): class GhostBottleneck (line 249) | class GhostBottleneck(nn.Module): method __init__ (line 251) | def __init__(self, c1, c2, k=3, s=1): # ch_in, ch_out, kernel, stride method forward (line 261) | def forward(self, x): class Contract (line 265) | class Contract(nn.Module): method __init__ (line 267) | def __init__(self, gain=2): method forward (line 271) | def forward(self, x): class Expand (line 279) | class Expand(nn.Module): method __init__ (line 281) | def __init__(self, gain=2): method forward (line 285) | def forward(self, x): class Concat (line 293) | class Concat(nn.Module): method __init__ (line 295) | def __init__(self, dimension=1): method forward (line 299) | def forward(self, x): class DetectMultiBackend (line 303) | class DetectMultiBackend(nn.Module): method __init__ (line 305) | def __init__(self, weights='yolov5s.pt', device=torch.device('cpu'), d... method forward (line 451) | def forward(self, im, augment=False, visualize=False, val=False): method warmup (line 517) | def warmup(self, imgsz=(1, 3, 640, 640)): method model_type (line 526) | def model_type(p='path/to/model.pt'): method _load_metadata (line 538) | def _load_metadata(f='path/to/meta.yaml'): class AutoShape (line 545) | class AutoShape(nn.Module): method __init__ (line 555) | def __init__(self, model, verbose=True): method _apply (line 564) | def _apply(self, fn): method forward (line 576) | def forward(self, imgs, size=640, augment=False, profile=False): class Detections (line 638) | class Detections: method __init__ (line 640) | def __init__(self, imgs, pred, files, times=(0, 0, 0, 0), names=None, ... method display (line 657) | def display(self, pprint=False, show=False, save=False, crop=False, re... method print (line 700) | def print(self): method show (line 704) | def show(self, labels=True): method save (line 707) | def save(self, labels=True, save_dir='runs/detect/exp'): method crop (line 711) | def crop(self, save=True, save_dir='runs/detect/exp'): method render (line 715) | def render(self, labels=True): method pandas (line 719) | def pandas(self): method tolist (line 729) | def tolist(self): method __len__ (line 738) | def __len__(self): method __str__ (line 741) | def __str__(self): class Classify (line 746) | class Classify(nn.Module): method __init__ (line 748) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1): # ch_in, ch_out, k... method forward (line 754) | def forward(self, x): FILE: asone/detectors/yolov5/yolov5/models/experimental.py class Ensemble (line 12) | class Ensemble(nn.ModuleList): method __init__ (line 14) | def __init__(self): method forward (line 17) | def forward(self, x, augment=False, profile=False, visualize=False): function attempt_load (line 25) | def attempt_load(weights, device=None, inplace=True, fuse=True): FILE: asone/detectors/yolov5/yolov5/models/general.py function is_kaggle (line 55) | def is_kaggle(): function is_writeable (line 65) | def is_writeable(dir, test=False): function set_logging (line 79) | def set_logging(name=None, verbose=VERBOSE): function user_config_dir (line 98) | def user_config_dir(dir='Ultralytics', env_var='YOLOV5_CONFIG_DIR'): class Profile (line 114) | class Profile(contextlib.ContextDecorator): method __enter__ (line 116) | def __enter__(self): method __exit__ (line 119) | def __exit__(self, type, value, traceback): class Timeout (line 123) | class Timeout(contextlib.ContextDecorator): method __init__ (line 125) | def __init__(self, seconds, *, timeout_msg='', suppress_timeout_errors... method _timeout_handler (line 130) | def _timeout_handler(self, signum, frame): method __enter__ (line 133) | def __enter__(self): method __exit__ (line 138) | def __exit__(self, exc_type, exc_val, exc_tb): class WorkingDirectory (line 145) | class WorkingDirectory(contextlib.ContextDecorator): method __init__ (line 147) | def __init__(self, new_dir): method __enter__ (line 151) | def __enter__(self): method __exit__ (line 154) | def __exit__(self, exc_type, exc_val, exc_tb): function try_except (line 158) | def try_except(func): function threaded (line 169) | def threaded(func): function methods (line 179) | def methods(instance): function print_args (line 184) | def print_args(args: Optional[dict] = None, show_file=True, show_fcn=Fal... function init_seeds (line 195) | def init_seeds(seed=0, deterministic=False): function intersect_dicts (line 213) | def intersect_dicts(da, db, exclude=()): function get_latest_run (line 218) | def get_latest_run(search_dir='.'): function is_docker (line 224) | def is_docker() -> bool: function is_colab (line 235) | def is_colab(): function is_pip (line 244) | def is_pip(): function is_ascii (line 249) | def is_ascii(s=''): function is_chinese (line 255) | def is_chinese(s='人工智能'): function emojis (line 260) | def emojis(str=''): function file_age (line 265) | def file_age(path=__file__): function file_date (line 271) | def file_date(path=__file__): function file_size (line 277) | def file_size(path): function check_online (line 289) | def check_online(): function git_describe (line 299) | def git_describe(path=ROOT): # path must be a directory function check_git_status (line 310) | def check_git_status(repo='ultralytics/yolov5'): function check_python (line 336) | def check_python(minimum='3.7.0'): function check_version (line 341) | def check_version(current='0.0.0', minimum='0.0.0', name='version ', pin... function check_requirements (line 354) | def check_requirements(requirements=ROOT / 'requirements.txt', exclude=(... function check_img_size (line 390) | def check_img_size(imgsz, s=32, floor=0): function check_imshow (line 402) | def check_imshow(): function check_suffix (line 417) | def check_suffix(file='yolov5s.pt', suffix=('.pt',), msg=''): function check_yaml (line 428) | def check_yaml(file, suffix=('.yaml', '.yml')): function check_file (line 433) | def check_file(file, suffix=''): function check_font (line 458) | def check_font(font=FONT, progress=False): function check_dataset (line 468) | def check_dataset(data, autodownload=True): function check_amp (line 528) | def check_amp(model): function url2file (line 556) | def url2file(url): function download (line 562) | def download(url, dir='.', unzip=True, delete=True, curl=False, threads=... function make_divisible (line 608) | def make_divisible(x, divisor): function clean_str (line 615) | def clean_str(s): function one_cycle (line 620) | def one_cycle(y1=0.0, y2=1.0, steps=100): function colorstr (line 625) | def colorstr(*input): function labels_to_class_weights (line 651) | def labels_to_class_weights(labels, nc=80): function labels_to_image_weights (line 670) | def labels_to_image_weights(labels, nc=80, class_weights=np.ones(80)): function coco80_to_coco91_class (line 677) | def coco80_to_coco91_class(): # converts 80-index (val2014) to 91-index... function xyxy2xywh (line 689) | def xyxy2xywh(x): function xywh2xyxy (line 699) | def xywh2xyxy(x): function xywhn2xyxy (line 709) | def xywhn2xyxy(x, w=640, h=640, padw=0, padh=0): function xyxy2xywhn (line 719) | def xyxy2xywhn(x, w=640, h=640, clip=False, eps=0.0): function xyn2xy (line 731) | def xyn2xy(x, w=640, h=640, padw=0, padh=0): function segment2box (line 739) | def segment2box(segment, width=640, height=640): function segments2boxes (line 747) | def segments2boxes(segments): function resample_segments (line 756) | def resample_segments(segments, n=1000): function scale_coords (line 766) | def scale_coords(img1_shape, coords, img0_shape, ratio_pad=None): function clip_coords (line 782) | def clip_coords(boxes, shape): function non_max_suppression (line 794) | def non_max_suppression(prediction, function strip_optimizer (line 896) | def strip_optimizer(f='best.pt', s=''): # from utils.general import *; ... function print_mutation (line 912) | def print_mutation(results, hyp, save_dir, bucket, prefix=colorstr('evol... function apply_classifier (line 952) | def apply_classifier(x, model, img, im0): function increment_path (line 987) | def increment_path(path, exist_ok=False, sep='', mkdir=False): function imread (line 1017) | def imread(path, flags=cv2.IMREAD_COLOR): function imwrite (line 1021) | def imwrite(path, im): function imshow (line 1029) | def imshow(path, im): FILE: asone/detectors/yolov5/yolov5/models/tf.py class TFBN (line 51) | class TFBN(keras.layers.Layer): method __init__ (line 53) | def __init__(self, w=None): method call (line 64) | def call(self, inputs): class TFPad (line 69) | class TFPad(keras.layers.Layer): method __init__ (line 71) | def __init__(self, pad): method call (line 84) | def call(self, inputs): class TFConv (line 89) | class TFConv(keras.layers.Layer): method __init__ (line 91) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True, w=None): method call (line 115) | def call(self, inputs): class TFDWConv (line 120) | class TFDWConv(keras.layers.Layer): method __init__ (line 122) | def __init__(self, c1, c2, k=1, s=1, p=None, act=True, w=None): method call (line 144) | def call(self, inputs): class TFDWConvTranspose2d (line 149) | class TFDWConvTranspose2d(keras.layers.Layer): method __init__ (line 151) | def __init__(self, c1, c2, k=1, s=1, p1=0, p2=0, w=None): method call (line 176) | def call(self, inputs): class TFFocus (line 181) | class TFFocus(keras.layers.Layer): method __init__ (line 183) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True, w=None): method call (line 193) | def call(self, inputs): class TFBottleneck (line 203) | class TFBottleneck(keras.layers.Layer): method __init__ (line 205) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5, w=None): method call (line 218) | def call(self, inputs): class TFCrossConv (line 225) | class TFCrossConv(keras.layers.Layer): method __init__ (line 227) | def __init__(self, c1, c2, k=3, s=1, g=1, e=1.0, shortcut=False, w=None): method call (line 235) | def call(self, inputs): class TFConv2d (line 240) | class TFConv2d(keras.layers.Layer): method __init__ (line 242) | def __init__(self, c1, c2, k, s=1, g=1, bias=True, w=None): method call (line 258) | def call(self, inputs): class TFBottleneckCSP (line 263) | class TFBottleneckCSP(keras.layers.Layer): method __init__ (line 265) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 282) | def call(self, inputs): class TFC3 (line 291) | class TFC3(keras.layers.Layer): method __init__ (line 293) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 306) | def call(self, inputs): class TFC3x (line 315) | class TFC3x(keras.layers.Layer): method __init__ (line 317) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 332) | def call(self, inputs): class TFSPP (line 337) | class TFSPP(keras.layers.Layer): method __init__ (line 339) | def __init__(self, c1, c2, k=(5, 9, 13), w=None): method call (line 347) | def call(self, inputs): class TFSPPF (line 353) | class TFSPPF(keras.layers.Layer): method __init__ (line 355) | def __init__(self, c1, c2, k=5, w=None): method call (line 365) | def call(self, inputs): class TFDetect (line 375) | class TFDetect(keras.layers.Layer): method __init__ (line 377) | def __init__(self, nc=80, anchors=(), ch=(), imgsz=(640, 640), w=None): method call (line 397) | def call(self, inputs): method _make_grid (line 422) | def _make_grid(nx=20, ny=20): class TFSegment (line 429) | class TFSegment(TFDetect): method __init__ (line 431) | def __init__(self, nc=80, anchors=(), nm=32, npr=256, ch=(), imgsz=(64... method call (line 443) | def call(self, x): class TFProto (line 452) | class TFProto(keras.layers.Layer): method __init__ (line 453) | def __init__(self, c1, c_=256, c2=32, w=None): method call (line 463) | def call(self, inputs): class TFUpsample (line 468) | class TFUpsample(keras.layers.Layer): method __init__ (line 470) | def __init__(self, size, scale_factor, mode, w=None): method call (line 485) | def call(self, inputs): class TFConcat (line 490) | class TFConcat(keras.layers.Layer): method __init__ (line 492) | def __init__(self, dimension=1, w=None): method call (line 498) | def call(self, inputs): function parse_model (line 503) | def parse_model(d, ch, model, imgsz): class TFModel (line 583) | class TFModel: method __init__ (line 585) | def __init__(self, cfg="yolov5s.yaml", ch=3, nc=None, model=None, imgs... method predict (line 605) | def predict( method _xywh2xyxy (line 646) | def _xywh2xyxy(xywh): class AgnosticNMS (line 654) | class AgnosticNMS(keras.layers.Layer): method call (line 656) | def call(self, input, topk_all, iou_thres, conf_thres): method _nms (line 666) | def _nms(x, topk_all=100, iou_thres=0.45, conf_thres=0.25): function activations (line 701) | def activations(act=nn.SiLU): function representative_dataset_gen (line 713) | def representative_dataset_gen(dataset, ncalib=100): function run (line 726) | def run( function parse_opt (line 751) | def parse_opt(): function main (line 766) | def main(opt): FILE: asone/detectors/yolov5/yolov5/models/yolo.py class Detect (line 44) | class Detect(nn.Module): method __init__ (line 49) | def __init__(self, nc=80, anchors=(), ch=(), inplace=True): # detecti... method forward (line 61) | def forward(self, x): method _make_grid (line 85) | def _make_grid(self, nx=20, ny=20, i=0): class DetectionModel (line 99) | class DetectionModel(nn.Module): method __init__ (line 101) | def __init__(self, cfg='yolov5s.yaml', ch=3, nc=None, anchors=None): ... method forward (line 139) | def forward(self, x, augment=False, profile=False, visualize=False): method _forward_augment (line 144) | def _forward_augment(self, x): method _forward_once (line 158) | def _forward_once(self, x, profile=False, visualize=False): method _descale_pred (line 171) | def _descale_pred(self, p, flips, scale, img_size): method _clip_augmented (line 188) | def _clip_augmented(self, y): method _profile_one_layer (line 199) | def _profile_one_layer(self, m, x, dt): method _initialize_biases (line 212) | def _initialize_biases(self, cf=None): # initialize biases into Detec... method _print_biases (line 222) | def _print_biases(self): method _print_weights (line 229) | def _print_weights(self): method fuse (line 234) | def fuse(self): # fuse model Conv2d() + BatchNorm2d() layers method info (line 244) | def info(self, verbose=False, img_size=640): # print model information method _apply (line 247) | def _apply(self, fn): function parse_model (line 261) | def parse_model(d, ch): # model_dict, input_channels(3) FILE: asone/detectors/yolov5/yolov5/utils/activations.py class SiLU (line 9) | class SiLU(nn.Module): method forward (line 11) | def forward(x): class Hardswish (line 20) | class Hardswish(nn.Module): method forward (line 22) | def forward(x): class Mish (line 31) | class Mish(nn.Module): method forward (line 35) | def forward(x): class MemoryEfficientMish (line 40) | class MemoryEfficientMish(nn.Module): class F (line 41) | class F(torch.autograd.Function): method forward (line 43) | def forward(ctx, x): method backward (line 49) | def backward(ctx, grad_output): method forward (line 56) | def forward(self, x): class FReLU (line 61) | class FReLU(nn.Module): method __init__ (line 64) | def __init__(self, c1, k=3): # ch_in, kernel method forward (line 70) | def forward(self, x): class AconC (line 79) | class AconC(nn.Module): method __init__ (line 87) | def __init__(self, c1): method forward (line 94) | def forward(self, x): class MetaAconC (line 100) | class MetaAconC(nn.Module): method __init__ (line 108) | def __init__(self, c1, k=1, s=1, r=16): method forward (line 119) | def forward(self, x): FILE: asone/detectors/yolov5/yolov5/utils/augmentations.py class Albumentations (line 20) | class Albumentations: method __init__ (line 22) | def __init__(self, size=640): method __call__ (line 49) | def __call__(self, im, labels, p=1.0): function normalize (line 57) | def normalize(x, mean=IMAGENET_MEAN, std=IMAGENET_STD, inplace=False): function denormalize (line 66) | def denormalize(x, mean=IMAGENET_MEAN, std=IMAGENET_STD): function augment_hsv (line 73) | def augment_hsv(im, hgain=0.5, sgain=0.5, vgain=0.5): function hist_equalize (line 89) | def hist_equalize(im, clahe=True, bgr=False): function replicate (line 100) | def replicate(im, labels): function letterbox (line 121) | def letterbox(im, new_shape=(640, 640), color=(114, 114, 114), auto=True... function random_perspective (line 154) | def random_perspective( function copy_paste (line 244) | def copy_paste(im, labels, segments, p=0.5): function cutout (line 270) | def cutout(im, labels, p=0.5): function mixup (line 301) | def mixup(im, labels, im2, labels2): function box_candidates (line 313) | def box_candidates(box1, box2, wh_thr=2, ar_thr=100, area_thr=0.1, eps=1... function classify_albumentations (line 326) | def classify_albumentations( function classify_transforms (line 370) | def classify_transforms(size=224): class LetterBox (line 377) | class LetterBox: method __init__ (line 379) | def __init__(self, size=(640, 640), auto=False, stride=32): method __call__ (line 388) | def __call__(self, im): class CenterCrop (line 404) | class CenterCrop: method __init__ (line 406) | def __init__(self, size=640): method __call__ (line 411) | def __call__(self, im): class ToTensor (line 423) | class ToTensor: method __init__ (line 425) | def __init__(self, half=False): method __call__ (line 430) | def __call__(self, im): FILE: asone/detectors/yolov5/yolov5/utils/dataloaders.py function get_hash (line 75) | def get_hash(paths): function exif_size (line 83) | def exif_size(img): function exif_transpose (line 93) | def exif_transpose(image): function seed_worker (line 120) | def seed_worker(worker_id): class SmartDistributedSampler (line 133) | class SmartDistributedSampler(distributed.DistributedSampler): method __iter__ (line 134) | def __iter__(self): function create_dataloader (line 158) | def create_dataloader( class InfiniteDataLoader (line 217) | class InfiniteDataLoader(dataloader.DataLoader): method __init__ (line 224) | def __init__(self, *args, **kwargs): method __len__ (line 232) | def __len__(self): method __iter__ (line 236) | def __iter__(self): class _RepeatSampler (line 242) | class _RepeatSampler: method __init__ (line 250) | def __init__(self, sampler): method __iter__ (line 254) | def __iter__(self): class LoadScreenshots (line 260) | class LoadScreenshots: method __init__ (line 262) | def __init__(self, source, img_size=640, stride=32, auto=True, transfo... method __iter__ (line 296) | def __iter__(self): method __next__ (line 300) | def __next__(self): class LoadImages (line 317) | class LoadImages: method __init__ (line 320) | def __init__(self, path, img_size=640, stride=32, auto=True, transform... method __iter__ (line 358) | def __iter__(self): method __next__ (line 363) | def __next__(self): method _new_video (line 404) | def _new_video(self, path): method _cv2_rotate (line 414) | def _cv2_rotate(self, im): method __len__ (line 424) | def __len__(self): class LoadStreams (line 429) | class LoadStreams: method __init__ (line 431) | def __init__(self, sources="file.streams", img_size=640, stride=32, au... method update (line 479) | def update(self, i, cap, stream): method __iter__ (line 495) | def __iter__(self): method __next__ (line 500) | def __next__(self): method __len__ (line 519) | def __len__(self): function img2label_paths (line 524) | def img2label_paths(img_paths): class LoadImagesAndLabels (line 532) | class LoadImagesAndLabels(Dataset): method __init__ (line 537) | def __init__( method check_cache_ram (line 695) | def check_cache_ram(self, safety_margin=0.1, prefix=""): method cache_labels (line 714) | def cache_labels(self, path=Path("./labels.cache"), prefix=""): method __len__ (line 754) | def __len__(self): method __getitem__ (line 764) | def __getitem__(self, index): method load_image (line 841) | def load_image(self, i): method cache_images_to_disk (line 866) | def cache_images_to_disk(self, i): method load_mosaic (line 872) | def load_mosaic(self, index): method load_mosaic9 (line 932) | def load_mosaic9(self, index): method collate_fn (line 1014) | def collate_fn(batch): method collate_fn4 (line 1022) | def collate_fn4(batch): function flatten_recursive (line 1051) | def flatten_recursive(path=DATASETS_DIR / "coco128"): function extract_boxes (line 1063) | def extract_boxes(path=DATASETS_DIR / "coco128"): function autosplit (line 1102) | def autosplit(path=DATASETS_DIR / "coco128/images", weights=(0.9, 0.1, 0... function verify_image_label (line 1128) | def verify_image_label(args): class HUBDatasetStats (line 1180) | class HUBDatasetStats: method __init__ (line 1196) | def __init__(self, path="coco128.yaml", autodownload=False): method _find_yaml (line 1217) | def _find_yaml(dir): method _unzip (line 1229) | def _unzip(self, path): method _hub_ops (line 1239) | def _hub_ops(self, f, max_dim=1920): method get_json (line 1257) | def get_json(self, save=False, verbose=False): method process_images (line 1295) | def process_images(self): class ClassificationDataset (line 1311) | class ClassificationDataset(torchvision.datasets.ImageFolder): method __init__ (line 1321) | def __init__(self, root, augment, imgsz, cache=False): method __getitem__ (line 1332) | def __getitem__(self, i): function create_classification_dataloader (line 1350) | def create_classification_dataloader( FILE: asone/detectors/yolov5/yolov5/utils/downloads.py.py function is_url (line 13) | def is_url(url, check=True): function gsutil_getsize (line 24) | def gsutil_getsize(url=""): function url_getsize (line 34) | def url_getsize(url="https://ultralytics.com/images/bus.jpg"): function curl_download (line 40) | def curl_download(url, filename, *, silent: bool = False) -> bool: function safe_download (line 60) | def safe_download(file, url, url2=None, min_bytes=1e0, error_msg=""): function attempt_download (line 88) | def attempt_download(file, repo="ultralytics/yolov5", release="v7.0"): FILE: asone/detectors/yolov5/yolov5/utils/general.py function is_ascii (line 73) | def is_ascii(s=""): function is_chinese (line 79) | def is_chinese(s="人工智能"): function is_colab (line 84) | def is_colab(): function is_jupyter (line 89) | def is_jupyter(): function is_kaggle (line 103) | def is_kaggle(): function is_docker (line 108) | def is_docker() -> bool: function is_writeable (line 119) | def is_writeable(dir, test=False): function set_logging (line 136) | def set_logging(name=LOGGING_NAME, verbose=True): function user_config_dir (line 170) | def user_config_dir(dir="Ultralytics", env_var="YOLOV5_CONFIG_DIR"): class Profile (line 188) | class Profile(contextlib.ContextDecorator): method __init__ (line 190) | def __init__(self, t=0.0, device: torch.device = None): method __enter__ (line 196) | def __enter__(self): method __exit__ (line 201) | def __exit__(self, type, value, traceback): method time (line 206) | def time(self): class Timeout (line 213) | class Timeout(contextlib.ContextDecorator): method __init__ (line 215) | def __init__(self, seconds, *, timeout_msg="", suppress_timeout_errors... method _timeout_handler (line 221) | def _timeout_handler(self, signum, frame): method __enter__ (line 225) | def __enter__(self): method __exit__ (line 231) | def __exit__(self, exc_type, exc_val, exc_tb): class WorkingDirectory (line 239) | class WorkingDirectory(contextlib.ContextDecorator): method __init__ (line 241) | def __init__(self, new_dir): method __enter__ (line 246) | def __enter__(self): method __exit__ (line 250) | def __exit__(self, exc_type, exc_val, exc_tb): function methods (line 255) | def methods(instance): function print_args (line 260) | def print_args(args: Optional[dict] = None, show_file=True, show_func=Fa... function init_seeds (line 275) | def init_seeds(seed=0, deterministic=False): function intersect_dicts (line 294) | def intersect_dicts(da, db, exclude=()): function get_default_args (line 301) | def get_default_args(func): function get_latest_run (line 307) | def get_latest_run(search_dir="."): function file_age (line 313) | def file_age(path=__file__): function file_date (line 319) | def file_date(path=__file__): function file_size (line 325) | def file_size(path): function check_online (line 337) | def check_online(): function git_describe (line 354) | def git_describe(path=ROOT): function check_git_status (line 369) | def check_git_status(repo="ultralytics/yolov5", branch="master"): function check_git_info (line 398) | def check_git_info(path="."): function check_python (line 416) | def check_python(minimum="3.8.0"): function check_version (line 421) | def check_version(current="0.0.0", minimum="0.0.0", name="version ", pin... function check_img_size (line 433) | def check_img_size(imgsz, s=32, floor=0): function check_imshow (line 445) | def check_imshow(warn=False): function check_suffix (line 461) | def check_suffix(file="yolov5s.pt", suffix=(".pt",), msg=""): function check_yaml (line 472) | def check_yaml(file, suffix=(".yaml", ".yml")): function check_file (line 477) | def check_file(file, suffix=""): function check_font (line 507) | def check_font(font=FONT, progress=False): function check_dataset (line 517) | def check_dataset(data, autodownload=True): function check_amp (line 583) | def check_amp(model): function yaml_load (line 611) | def yaml_load(file="data.yaml"): function yaml_save (line 617) | def yaml_save(file="data.yaml", data={}): function unzip_file (line 625) | def unzip_file(file, path=None, exclude=(".DS_Store", "__MACOSX")): function url2file (line 637) | def url2file(url): function download (line 647) | def download(url, dir=".", unzip=True, delete=True, curl=False, threads=... function make_divisible (line 694) | def make_divisible(x, divisor): function clean_str (line 701) | def clean_str(s): function one_cycle (line 708) | def one_cycle(y1=0.0, y2=1.0, steps=100): function colorstr (line 717) | def colorstr(*input): function labels_to_class_weights (line 748) | def labels_to_class_weights(labels, nc=80): function labels_to_image_weights (line 767) | def labels_to_image_weights(labels, nc=80, class_weights=np.ones(80)): function coco80_to_coco91_class (line 774) | def coco80_to_coco91_class(): function xyxy2xywh (line 868) | def xyxy2xywh(x): function xywh2xyxy (line 878) | def xywh2xyxy(x): function xywhn2xyxy (line 888) | def xywhn2xyxy(x, w=640, h=640, padw=0, padh=0): function xyxy2xywhn (line 898) | def xyxy2xywhn(x, w=640, h=640, clip=False, eps=0.0): function xyn2xy (line 910) | def xyn2xy(x, w=640, h=640, padw=0, padh=0): function segment2box (line 918) | def segment2box(segment, width=640, height=640): function segments2boxes (line 929) | def segments2boxes(segments): function resample_segments (line 938) | def resample_segments(segments, n=1000): function scale_boxes (line 948) | def scale_boxes(img1_shape, boxes, img0_shape, ratio_pad=None): function scale_segments (line 964) | def scale_segments(img1_shape, segments, img0_shape, ratio_pad=None, nor... function clip_boxes (line 983) | def clip_boxes(boxes, shape): function clip_segments (line 995) | def clip_segments(segments, shape): function non_max_suppression (line 1005) | def non_max_suppression( function strip_optimizer (line 1119) | def strip_optimizer(f="best.pt", s=""): function print_mutation (line 1140) | def print_mutation(keys, results, hyp, save_dir, bucket, prefix=colorstr... function apply_classifier (line 1195) | def apply_classifier(x, model, img, im0): function increment_path (line 1230) | def increment_path(path, exist_ok=False, sep="", mkdir=False): function imread (line 1265) | def imread(filename, flags=cv2.IMREAD_COLOR): function imwrite (line 1272) | def imwrite(filename, img): function imshow (line 1281) | def imshow(path, im): FILE: asone/detectors/yolov5/yolov5/utils/metrics.py function fitness (line 15) | def fitness(x): function smooth (line 21) | def smooth(y, f=0.05): function ap_per_class (line 29) | def ap_per_class(tp, conf, pred_cls, target_cls, plot=False, save_dir=".... function compute_ap (line 98) | def compute_ap(recall, precision): class ConfusionMatrix (line 126) | class ConfusionMatrix: method __init__ (line 128) | def __init__(self, nc, conf=0.25, iou_thres=0.45): method process_batch (line 135) | def process_batch(self, detections, labels): method tp_fp (line 182) | def tp_fp(self): method plot (line 192) | def plot(self, normalize=True, save_dir="", names=()): method print (line 224) | def print(self): function bbox_iou (line 230) | def bbox_iou(box1, box2, xywh=True, GIoU=False, DIoU=False, CIoU=False, ... function box_iou (line 276) | def box_iou(box1, box2, eps=1e-7): function bbox_ioa (line 298) | def bbox_ioa(box1, box2, eps=1e-7): function wh_iou (line 324) | def wh_iou(wh1, wh2, eps=1e-7): function plot_pr_curve (line 338) | def plot_pr_curve(px, py, ap, save_dir=Path("pr_curve.png"), names=()): function plot_mc_curve (line 363) | def plot_mc_curve(px, py, save_dir=Path("mc_curve.png"), names=(), xlabe... FILE: asone/detectors/yolov5/yolov5/utils/torch_utils.py function smart_DDP (line 37) | def smart_DDP(model): function torch_distributed_zero_first (line 49) | def torch_distributed_zero_first(local_rank: int): function device_count (line 58) | def device_count(): function select_device (line 68) | def select_device(device='', batch_size=0, newline=True): function time_sync (line 104) | def time_sync(): function profile (line 111) | def profile(input, ops, n=10, device=None): function is_parallel (line 155) | def is_parallel(model): function de_parallel (line 160) | def de_parallel(model): function initialize_weights (line 165) | def initialize_weights(model): function find_modules (line 177) | def find_modules(model, mclass=nn.Conv2d): function sparsity (line 182) | def sparsity(model): function prune (line 191) | def prune(model, amount=0.3): function fuse_conv_and_bn (line 202) | def fuse_conv_and_bn(conv, bn): function model_info (line 225) | def model_info(model, verbose=False, img_size=640): function scale_img (line 250) | def scale_img(img, ratio=1.0, same_shape=False, gs=32): # img(16,3,256,... function copy_attr (line 262) | def copy_attr(a, b, include=(), exclude=()): function smart_optimizer (line 271) | def smart_optimizer(model, name='Adam', lr=0.001, momentum=0.9, weight_d... class EarlyStopping (line 301) | class EarlyStopping: method __init__ (line 303) | def __init__(self, patience=30): method __call__ (line 309) | def __call__(self, epoch, fitness): class ModelEMA (line 324) | class ModelEMA: method __init__ (line 330) | def __init__(self, model, decay=0.9999, tau=2000, updates=0): method update (line 340) | def update(self, model): method update_attr (line 352) | def update_attr(self, model, include=(), exclude=('process_group', 're... FILE: asone/detectors/yolov5/yolov5/utils/yolov5_utils.py function box_area (line 12) | def box_area(box): function box_iou (line 17) | def box_iou(box1, box2, eps=1e-7): function xywh2xyxy (line 37) | def xywh2xyxy(x): function non_max_suppression (line 46) | def non_max_suppression(prediction, function letterbox (line 146) | def letterbox(im, new_shape=(640, 640), color=(114, 114, 114), auto=True... function scale_coords (line 180) | def scale_coords(img1_shape, coords, img0_shape, ratio_pad=None): function clip_coords (line 196) | def clip_coords(boxes, shape): function yolov5_in_syspath (line 208) | def yolov5_in_syspath(): FILE: asone/detectors/yolov5/yolov5_detector.py class YOLOv5Detector (line 19) | class YOLOv5Detector: method __init__ (line 20) | def __init__(self, method load_model (line 37) | def load_model(self, use_cuda, weights, fp16=False): method image_preprocessing (line 56) | def image_preprocessing(self, method detect (line 69) | def detect(self, image: list, FILE: asone/detectors/yolov6/yolov6/assigners/anchor_generator.py function generate_anchors (line 4) | def generate_anchors(feats, fpn_strides, grid_cell_size=5.0, grid_cell_o... FILE: asone/detectors/yolov6/yolov6/assigners/assigner_utils.py function dist_calculator (line 4) | def dist_calculator(gt_bboxes, anchor_bboxes): function select_candidates_in_gts (line 25) | def select_candidates_in_gts(xy_centers, gt_bboxes, eps=1e-9): function select_highest_overlaps (line 46) | def select_highest_overlaps(mask_pos, overlaps, n_max_boxes): function iou_calculator (line 69) | def iou_calculator(box1, box2, eps=1e-9): FILE: asone/detectors/yolov6/yolov6/assigners/atss_assigner.py class ATSSAssigner (line 7) | class ATSSAssigner(nn.Module): method __init__ (line 9) | def __init__(self, method forward (line 18) | def forward(self, method select_topk_candidates (line 88) | def select_topk_candidates(self, method thres_calculator (line 117) | def thres_calculator(self, method get_targets (line 138) | def get_targets(self, FILE: asone/detectors/yolov6/yolov6/assigners/iou2d_calculator.py function cast_tensor_type (line 7) | def cast_tensor_type(x, scale=1., dtype=None): function fp16_clamp (line 14) | def fp16_clamp(x, min=None, max=None): function iou2d_calculator (line 22) | def iou2d_calculator(bboxes1, bboxes2, mode='iou', is_aligned=False, sca... function bbox_overlaps (line 63) | def bbox_overlaps(bboxes1, bboxes2, mode='iou', is_aligned=False, eps=1e... FILE: asone/detectors/yolov6/yolov6/assigners/tal_assigner.py class TaskAlignedAssigner (line 6) | class TaskAlignedAssigner(nn.Module): method __init__ (line 7) | def __init__(self, method forward (line 22) | def forward(self, method get_pos_mask (line 75) | def get_pos_mask(self, method get_box_metrics (line 95) | def get_box_metrics(self, method select_topk_candidates (line 113) | def select_topk_candidates(self, method get_targets (line 130) | def get_targets(self, FILE: asone/detectors/yolov6/yolov6/layers/common.py class SiLU (line 14) | class SiLU(nn.Module): method forward (line 17) | def forward(x): class Conv (line 21) | class Conv(nn.Module): method __init__ (line 23) | def __init__(self, in_channels, out_channels, kernel_size, stride, gro... method forward (line 38) | def forward(self, x): method forward_fuse (line 41) | def forward_fuse(self, x): class SimConv (line 45) | class SimConv(nn.Module): method __init__ (line 47) | def __init__(self, in_channels, out_channels, kernel_size, stride, gro... method forward (line 62) | def forward(self, x): method forward_fuse (line 65) | def forward_fuse(self, x): class ConvWrapper (line 68) | class ConvWrapper(nn.Module): method __init__ (line 70) | def __init__(self, in_channels, out_channels, kernel_size=3, stride=1,... method forward (line 74) | def forward(self, x): class SimConvWrapper (line 78) | class SimConvWrapper(nn.Module): method __init__ (line 80) | def __init__(self, in_channels, out_channels, kernel_size=3, stride=1,... method forward (line 84) | def forward(self, x): class SimSPPF (line 88) | class SimSPPF(nn.Module): method __init__ (line 90) | def __init__(self, in_channels, out_channels, kernel_size=5): method forward (line 97) | def forward(self, x): class SPPF (line 106) | class SPPF(nn.Module): method __init__ (line 108) | def __init__(self, in_channels, out_channels, kernel_size=5): # equiv... method forward (line 115) | def forward(self, x): class Transpose (line 124) | class Transpose(nn.Module): method __init__ (line 126) | def __init__(self, in_channels, out_channels, kernel_size=2, stride=2): method forward (line 136) | def forward(self, x): class Concat (line 140) | class Concat(nn.Module): method __init__ (line 141) | def __init__(self, dimension=1): method forward (line 145) | def forward(self, x): function conv_bn (line 149) | def conv_bn(in_channels, out_channels, kernel_size, stride, padding, gro... class RepVGGBlock (line 158) | class RepVGGBlock(nn.Module): method __init__ (line 162) | def __init__(self, in_channels, out_channels, kernel_size=3, method forward (line 206) | def forward(self, inputs): method get_equivalent_kernel_bias (line 218) | def get_equivalent_kernel_bias(self): method _pad_1x1_to_3x3_tensor (line 224) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 230) | def _fuse_bn_tensor(self, branch): method switch_to_deploy (line 258) | def switch_to_deploy(self): class RealVGGBlock (line 278) | class RealVGGBlock(nn.Module): method __init__ (line 280) | def __init__(self, in_channels, out_channels, kernel_size=3, stride=1,... method forward (line 293) | def forward(self, inputs): class ScaleLayer (line 298) | class ScaleLayer(torch.nn.Module): method __init__ (line 300) | def __init__(self, num_features, use_bias=True, scale_init=1.0): method forward (line 311) | def forward(self, inputs): class LinearAddBlock (line 319) | class LinearAddBlock(nn.Module): method __init__ (line 321) | def __init__(self, in_channels, out_channels, kernel_size=3, stride=1,... method forward (line 341) | def forward(self, inputs): class DetectBackend (line 349) | class DetectBackend(nn.Module): method __init__ (line 350) | def __init__(self, weights='yolov6s.pt', device=None, dnn=True): method forward (line 359) | def forward(self, im, val=False): class RepBlock (line 366) | class RepBlock(nn.Module): method __init__ (line 370) | def __init__(self, in_channels, out_channels, n=1, block=RepVGGBlock, ... method forward (line 380) | def forward(self, x): class BottleRep (line 387) | class BottleRep(nn.Module): method __init__ (line 389) | def __init__(self, in_channels, out_channels, basic_block=RepVGGBlock,... method forward (line 402) | def forward(self, x): function autopad (line 409) | def autopad(k, p=None): # kernel, padding class Conv_C3 (line 416) | class Conv_C3(nn.Module): method __init__ (line 418) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 423) | def forward(self, x): method forward_fuse (line 425) | def forward_fuse(self, x): class BepC3 (line 429) | class BepC3(nn.Module): method __init__ (line 431) | def __init__(self, in_channels, out_channels, n=1, e=0.5, concat=True,... method forward (line 447) | def forward(self, x): function get_block (line 454) | def get_block(mode): FILE: asone/detectors/yolov6/yolov6/layers/dbb_transforms.py function transI_fusebn (line 6) | def transI_fusebn(kernel, bn): function transII_addbranch (line 12) | def transII_addbranch(kernels, biases): function transIII_1x1_kxk (line 16) | def transIII_1x1_kxk(k1, b1, k2, b2, groups): function transIV_depthconcat (line 35) | def transIV_depthconcat(kernels, biases): function transV_avg (line 39) | def transV_avg(channels, kernel_size, groups): function transVI_multiscale (line 47) | def transVI_multiscale(kernel, target_kernel_size): FILE: asone/detectors/yolov6/yolov6/models/efficientrep.py class EfficientRep (line 5) | class EfficientRep(nn.Module): method __init__ (line 11) | def __init__( method forward (line 95) | def forward(self, x): class CSPBepBackbone (line 110) | class CSPBepBackbone(nn.Module): method __init__ (line 115) | def __init__( method forward (line 208) | def forward(self, x): FILE: asone/detectors/yolov6/yolov6/models/effidehead.py class Detect (line 10) | class Detect(nn.Module): method __init__ (line 15) | def __init__(self, num_classes=80, anchors=1, num_layers=3, inplace=Tr... method initialize_biases (line 53) | def initialize_biases(self): method forward (line 75) | def forward(self, x): function build_effidehead_layer (line 137) | def build_effidehead_layer(channels_list, num_anchors, num_classes, reg_... FILE: asone/detectors/yolov6/yolov6/models/end2end.py class ORT_NMS (line 6) | class ORT_NMS(torch.autograd.Function): method forward (line 9) | def forward(ctx, method symbolic (line 26) | def symbolic(g, boxes, scores, max_output_boxes_per_class, iou_thresho... class TRT8_NMS (line 30) | class TRT8_NMS(torch.autograd.Function): method forward (line 33) | def forward( method symbolic (line 53) | def symbolic(g, class TRT7_NMS (line 77) | class TRT7_NMS(torch.autograd.Function): method forward (line 80) | def forward( method symbolic (line 104) | def symbolic(g, class ONNX_ORT (line 140) | class ONNX_ORT(nn.Module): method __init__ (line 142) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 153) | def forward(self, x): class ONNX_TRT7 (line 171) | class ONNX_TRT7(nn.Module): method __init__ (line 173) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 192) | def forward(self, x): class ONNX_TRT8 (line 216) | class ONNX_TRT8(nn.Module): method __init__ (line 218) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 230) | def forward(self, x): class End2End (line 242) | class End2End(nn.Module): method __init__ (line 244) | def __init__(self, model, max_obj=100, iou_thres=0.45, score_thres=0.2... method forward (line 254) | def forward(self, x): FILE: asone/detectors/yolov6/yolov6/models/loss.py class ComputeLoss (line 15) | class ComputeLoss: method __init__ (line 17) | def __init__(self, method __call__ (line 51) | def __call__( method preprocess (line 119) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 129) | def bbox_decode(self, anchor_points, pred_dist): class VarifocalLoss (line 136) | class VarifocalLoss(nn.Module): method __init__ (line 137) | def __init__(self): method forward (line 140) | def forward(self, pred_score,gt_score, label, alpha=0.75, gamma=2.0): class BboxLoss (line 149) | class BboxLoss(nn.Module): method __init__ (line 150) | def __init__(self, num_classes, reg_max, use_dfl=False, iou_type='giou'): method forward (line 157) | def forward(self, pred_dist, pred_bboxes, anchor_points, method _df_loss (line 196) | def _df_loss(self, pred_dist, target): FILE: asone/detectors/yolov6/yolov6/models/loss_distill.py class ComputeLoss (line 15) | class ComputeLoss: method __init__ (line 17) | def __init__(self, method __call__ (line 59) | def __call__( method distill_loss_cls (line 154) | def distill_loss_cls(self, logits_student, logits_teacher, num_classes... method distill_loss_cw (line 165) | def distill_loss_cw(self, s_feats, t_feats, temperature=1): method preprocess (line 189) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 199) | def bbox_decode(self, anchor_points, pred_dist): class VarifocalLoss (line 206) | class VarifocalLoss(nn.Module): method __init__ (line 207) | def __init__(self): method forward (line 210) | def forward(self, pred_score,gt_score, label, alpha=0.75, gamma=2.0): class BboxLoss (line 219) | class BboxLoss(nn.Module): method __init__ (line 220) | def __init__(self, num_classes, reg_max, use_dfl=False, iou_type='giou'): method forward (line 227) | def forward(self, pred_dist, pred_bboxes, t_pred_dist, t_pred_bboxes, ... method _df_loss (line 274) | def _df_loss(self, pred_dist, target): method distill_loss_dfl (line 287) | def distill_loss_dfl(self, logits_student, logits_teacher, temperature... FILE: asone/detectors/yolov6/yolov6/models/reppan.py class RepPANNeck (line 6) | class RepPANNeck(nn.Module): method __init__ (line 12) | def __init__( method upsample_enable_quant (line 89) | def upsample_enable_quant(self): method forward (line 100) | def forward(self, input): class CSPRepPANNeck (line 131) | class CSPRepPANNeck(nn.Module): method __init__ (line 136) | def __init__( method forward (line 218) | def forward(self, input): FILE: asone/detectors/yolov6/yolov6/models/yolo.py class Model (line 14) | class Model(nn.Module): method __init__ (line 19) | def __init__(self, config, channels=3, num_classes=None, anchors=None)... method forward (line 37) | def forward(self, x): method _apply (line 47) | def _apply(self, fn): function make_divisible (line 54) | def make_divisible(x, divisor): function build_network (line 59) | def build_network(config, channels, num_classes, anchors, num_layers): function build_model (line 112) | def build_model(cfg, num_classes, device): FILE: asone/detectors/yolov6/yolov6/utils/checkpoint.py function load_state_dict (line 11) | def load_state_dict(weights, model, map_location=None): function load_checkpoint (line 22) | def load_checkpoint(weights, map_location=None, inplace=True, fuse=True): function save_checkpoint (line 35) | def save_checkpoint(ckpt, is_best, save_dir, model_name=""): function strip_optimizer (line 46) | def strip_optimizer(ckpt_dir, epoch): FILE: asone/detectors/yolov6/yolov6/utils/events.py function set_logging (line 9) | def set_logging(name=None): function load_yaml (line 19) | def load_yaml(file_path): function save_yaml (line 27) | def save_yaml(data_dict, save_path): function write_tblog (line 33) | def write_tblog(tblogger, epoch, results, losses): function write_tbimg (line 47) | def write_tbimg(tblogger, imgs, step, type='train'): FILE: asone/detectors/yolov6/yolov6/utils/figure_iou.py class IOUloss (line 7) | class IOUloss: method __init__ (line 10) | def __init__(self, box_format='xywh', iou_type='ciou', reduction='none... method __call__ (line 23) | def __call__(self, box1, box2): function pairwise_bbox_iou (line 103) | def pairwise_bbox_iou(box1, box2, box_format='xywh'): FILE: asone/detectors/yolov6/yolov6/utils/general.py function increment_name (line 9) | def increment_name(path): function find_latest_checkpoint (line 23) | def find_latest_checkpoint(search_dir='.'): function dist2bbox (line 29) | def dist2bbox(distance, anchor_points, box_format='xyxy'): function bbox2dist (line 43) | def bbox2dist(anchor_points, bbox, reg_max): function xywh2xyxy (line 52) | def xywh2xyxy(bboxes): function box_iou (line 60) | def box_iou(box1, box2): FILE: asone/detectors/yolov6/yolov6/utils/torch_utils.py function torch_distributed_zero_first (line 20) | def torch_distributed_zero_first(local_rank: int): function time_sync (line 31) | def time_sync(): function initialize_weights (line 38) | def initialize_weights(model): function fuse_conv_and_bn (line 50) | def fuse_conv_and_bn(conv, bn): function fuse_model (line 85) | def fuse_model(model): function get_model_info (line 96) | def get_model_info(model, img_size=640): FILE: asone/detectors/yolov6/yolov6/utils/yolov6_utils.py function nms (line 12) | def nms(boxes, scores, iou_threshold): function process_output (line 34) | def process_output(output, img_height, img_width, function compute_iou (line 66) | def compute_iou(box, boxes): function xywh2xyxy (line 87) | def xywh2xyxy(x): function prepare_input (line 96) | def prepare_input(image, input_width, input_height): function process_and_scale_boxes (line 109) | def process_and_scale_boxes(predictions, img_height, img_width, function load_pytorch (line 126) | def load_pytorch(weights, map_location=None, inplace=True, fuse=False): function fuse_model (line 136) | def fuse_model(model): function fuse_conv_and_bn (line 144) | def fuse_conv_and_bn(conv, bn): function non_max_suppression (line 179) | def non_max_suppression(prediction, conf_thres=0.25, iou_thres=0.45, cla... FILE: asone/detectors/yolov6/yolov6_detector.py class YOLOv6Detector (line 16) | class YOLOv6Detector: method __init__ (line 17) | def __init__(self, method load_model (line 40) | def load_model(self, use_cuda, weights, fp16=False): method ONNXModel_detail (line 56) | def ONNXModel_detail(self, model): method ONNXModel_names (line 66) | def ONNXModel_names(self, model): method detect (line 76) | def detect(self, image: list, FILE: asone/detectors/yolov7/yolov7/models/common.py function autopad (line 19) | def autopad(k, p=None): # kernel, padding class MP (line 26) | class MP(nn.Module): method __init__ (line 27) | def __init__(self, k=2): method forward (line 31) | def forward(self, x): class SP (line 35) | class SP(nn.Module): method __init__ (line 36) | def __init__(self, k=3, s=1): method forward (line 40) | def forward(self, x): class ReOrg (line 44) | class ReOrg(nn.Module): method __init__ (line 45) | def __init__(self): method forward (line 48) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class Concat (line 52) | class Concat(nn.Module): method __init__ (line 53) | def __init__(self, dimension=1): method forward (line 57) | def forward(self, x): class Chuncat (line 61) | class Chuncat(nn.Module): method __init__ (line 62) | def __init__(self, dimension=1): method forward (line 66) | def forward(self, x): class Shortcut (line 76) | class Shortcut(nn.Module): method __init__ (line 77) | def __init__(self, dimension=0): method forward (line 81) | def forward(self, x): class Foldcut (line 85) | class Foldcut(nn.Module): method __init__ (line 86) | def __init__(self, dimension=0): method forward (line 90) | def forward(self, x): class Conv (line 95) | class Conv(nn.Module): method __init__ (line 97) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 103) | def forward(self, x): method fuseforward (line 106) | def fuseforward(self, x): class RobustConv (line 110) | class RobustConv(nn.Module): method __init__ (line 112) | def __init__(self, c1, c2, k=7, s=1, p=None, g=1, act=True, layer_scal... method forward (line 118) | def forward(self, x): class RobustConv2 (line 126) | class RobustConv2(nn.Module): method __init__ (line 128) | def __init__(self, c1, c2, k=7, s=4, p=None, g=1, act=True, layer_scal... method forward (line 136) | def forward(self, x): function DWConv (line 143) | def DWConv(c1, c2, k=1, s=1, act=True): class GhostConv (line 148) | class GhostConv(nn.Module): method __init__ (line 150) | def __init__(self, c1, c2, k=1, s=1, g=1, act=True): # ch_in, ch_out,... method forward (line 156) | def forward(self, x): class Stem (line 161) | class Stem(nn.Module): method __init__ (line 163) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 172) | def forward(self, x): class DownC (line 177) | class DownC(nn.Module): method __init__ (line 179) | def __init__(self, c1, c2, n=1, k=2): method forward (line 187) | def forward(self, x): class SPP (line 191) | class SPP(nn.Module): method __init__ (line 193) | def __init__(self, c1, c2, k=(5, 9, 13)): method forward (line 200) | def forward(self, x): class Bottleneck (line 205) | class Bottleneck(nn.Module): method __init__ (line 207) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 214) | def forward(self, x): class Res (line 218) | class Res(nn.Module): method __init__ (line 220) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 228) | def forward(self, x): class ResX (line 232) | class ResX(Res): method __init__ (line 234) | def __init__(self, c1, c2, shortcut=True, g=32, e=0.5): # ch_in, ch_o... class Ghost (line 239) | class Ghost(nn.Module): method __init__ (line 241) | def __init__(self, c1, c2, k=3, s=1): # ch_in, ch_out, kernel, stride method forward (line 250) | def forward(self, x): class SPPCSPC (line 258) | class SPPCSPC(nn.Module): method __init__ (line 260) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... method forward (line 272) | def forward(self, x): class GhostSPPCSPC (line 278) | class GhostSPPCSPC(SPPCSPC): method __init__ (line 280) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... class GhostStem (line 292) | class GhostStem(Stem): method __init__ (line 294) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... class BottleneckCSPA (line 303) | class BottleneckCSPA(nn.Module): method __init__ (line 305) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 313) | def forward(self, x): class BottleneckCSPB (line 319) | class BottleneckCSPB(nn.Module): method __init__ (line 321) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 329) | def forward(self, x): class BottleneckCSPC (line 336) | class BottleneckCSPC(nn.Module): method __init__ (line 338) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 347) | def forward(self, x): class ResCSPA (line 353) | class ResCSPA(BottleneckCSPA): method __init__ (line 355) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResCSPB (line 361) | class ResCSPB(BottleneckCSPB): method __init__ (line 363) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResCSPC (line 369) | class ResCSPC(BottleneckCSPC): method __init__ (line 371) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResXCSPA (line 377) | class ResXCSPA(ResCSPA): method __init__ (line 379) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class ResXCSPB (line 385) | class ResXCSPB(ResCSPB): method __init__ (line 387) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class ResXCSPC (line 393) | class ResXCSPC(ResCSPC): method __init__ (line 395) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class GhostCSPA (line 401) | class GhostCSPA(BottleneckCSPA): method __init__ (line 403) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class GhostCSPB (line 409) | class GhostCSPB(BottleneckCSPB): method __init__ (line 411) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class GhostCSPC (line 417) | class GhostCSPC(BottleneckCSPC): method __init__ (line 419) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ImplicitA (line 429) | class ImplicitA(nn.Module): method __init__ (line 430) | def __init__(self, channel, mean=0., std=.02): method forward (line 438) | def forward(self, x): class ImplicitM (line 442) | class ImplicitM(nn.Module): method __init__ (line 443) | def __init__(self, channel, mean=0., std=.02): method forward (line 451) | def forward(self, x): class RepConv (line 459) | class RepConv(nn.Module): method __init__ (line 463) | def __init__(self, c1, c2, k=3, s=1, p=None, g=1, act=True, deploy=Fal... method forward (line 494) | def forward(self, inputs): method get_equivalent_kernel_bias (line 505) | def get_equivalent_kernel_bias(self): method _pad_1x1_to_3x3_tensor (line 514) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 520) | def _fuse_bn_tensor(self, branch): method repvgg_convert (line 550) | def repvgg_convert(self): method fuse_conv_bn (line 557) | def fuse_conv_bn(self, conv, bn): method fuse_repvgg_block (line 580) | def fuse_repvgg_block(self): class RepBottleneck (line 642) | class RepBottleneck(Bottleneck): method __init__ (line 644) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... class RepBottleneckCSPA (line 650) | class RepBottleneckCSPA(BottleneckCSPA): method __init__ (line 652) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepBottleneckCSPB (line 658) | class RepBottleneckCSPB(BottleneckCSPB): method __init__ (line 660) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... class RepBottleneckCSPC (line 666) | class RepBottleneckCSPC(BottleneckCSPC): method __init__ (line 668) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepRes (line 674) | class RepRes(Res): method __init__ (line 676) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... class RepResCSPA (line 682) | class RepResCSPA(ResCSPA): method __init__ (line 684) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepResCSPB (line 690) | class RepResCSPB(ResCSPB): method __init__ (line 692) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... class RepResCSPC (line 698) | class RepResCSPC(ResCSPC): method __init__ (line 700) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepResX (line 706) | class RepResX(ResX): method __init__ (line 708) | def __init__(self, c1, c2, shortcut=True, g=32, e=0.5): # ch_in, ch_o... class RepResXCSPA (line 714) | class RepResXCSPA(ResXCSPA): method __init__ (line 716) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class RepResXCSPB (line 722) | class RepResXCSPB(ResXCSPB): method __init__ (line 724) | def __init__(self, c1, c2, n=1, shortcut=False, g=32, e=0.5): # ch_in... class RepResXCSPC (line 730) | class RepResXCSPC(ResXCSPC): method __init__ (line 732) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class TransformerLayer (line 742) | class TransformerLayer(nn.Module): method __init__ (line 744) | def __init__(self, c, num_heads): method forward (line 753) | def forward(self, x): class TransformerBlock (line 759) | class TransformerBlock(nn.Module): method __init__ (line 761) | def __init__(self, c1, c2, num_heads, num_layers): method forward (line 770) | def forward(self, x): class Focus (line 792) | class Focus(nn.Module): method __init__ (line 794) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 799) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class SPPF (line 804) | class SPPF(nn.Module): method __init__ (line 806) | def __init__(self, c1, c2, k=5): # equivalent to SPP(k=(5, 9, 13)) method forward (line 813) | def forward(self, x): class Contract (line 820) | class Contract(nn.Module): method __init__ (line 822) | def __init__(self, gain=2): method forward (line 826) | def forward(self, x): class Expand (line 834) | class Expand(nn.Module): method __init__ (line 836) | def __init__(self, gain=2): method forward (line 840) | def forward(self, x): class NMS (line 848) | class NMS(nn.Module): method __init__ (line 854) | def __init__(self): method forward (line 857) | def forward(self, x): class autoShape (line 861) | class autoShape(nn.Module): method __init__ (line 867) | def __init__(self, model): method autoshape (line 871) | def autoshape(self): method forward (line 876) | def forward(self, imgs, size=640, augment=False, profile=False): class Detections (line 931) | class Detections: method __init__ (line 933) | def __init__(self, imgs, pred, files, times=None, names=None, shape=No... method display (line 949) | def display(self, pprint=False, show=False, save=False, render=False, ... method print (line 973) | def print(self): method show (line 977) | def show(self): method save (line 980) | def save(self, save_dir='runs/hub/exp'): method render (line 985) | def render(self): method pandas (line 989) | def pandas(self): method tolist (line 999) | def tolist(self): method __len__ (line 1007) | def __len__(self): class Classify (line 1011) | class Classify(nn.Module): method __init__ (line 1013) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1): # ch_in, ch_out, k... method forward (line 1019) | def forward(self, x): function transI_fusebn (line 1028) | def transI_fusebn(kernel, bn): class ConvBN (line 1034) | class ConvBN(nn.Module): method __init__ (line 1035) | def __init__(self, in_channels, out_channels, kernel_size, method forward (line 1050) | def forward(self, x): method switch_to_deploy (line 1056) | def switch_to_deploy(self): class OREPA_3x3_RepConv (line 1068) | class OREPA_3x3_RepConv(nn.Module): method __init__ (line 1070) | def __init__(self, in_channels, out_channels, kernel_size, method fre_init (line 1153) | def fre_init(self): method weight_gen (line 1166) | def weight_gen(self): method dwsc2full (line 1202) | def dwsc2full(self, weight_dw, weight_pw, groups): method forward (line 1214) | def forward(self, inputs): class RepConv_OREPA (line 1220) | class RepConv_OREPA(nn.Module): method __init__ (line 1222) | def __init__(self, c1, c2, k=3, s=1, padding=1, dilation=1, groups=1, ... method forward (line 1259) | def forward(self, inputs): method get_custom_L2 (line 1286) | def get_custom_L2(self): method get_equivalent_kernel_bias (line 1297) | def get_equivalent_kernel_bias(self): method _pad_1x1_to_3x3_tensor (line 1303) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 1309) | def _fuse_bn_tensor(self, branch): method switch_to_deploy (line 1341) | def switch_to_deploy(self): class WindowAttention (line 1363) | class WindowAttention(nn.Module): method __init__ (line 1365) | def __init__(self, dim, window_size, num_heads, qkv_bias=True, qk_scal... method forward (line 1399) | def forward(self, x, mask=None): class Mlp (line 1433) | class Mlp(nn.Module): method __init__ (line 1435) | def __init__(self, in_features, hidden_features=None, out_features=Non... method forward (line 1444) | def forward(self, x): function window_partition (line 1452) | def window_partition(x, window_size): function window_reverse (line 1460) | def window_reverse(windows, window_size, H, W): class SwinTransformerLayer (line 1468) | class SwinTransformerLayer(nn.Module): method __init__ (line 1470) | def __init__(self, dim, num_heads, window_size=8, shift_size=0, method create_mask (line 1495) | def create_mask(self, H, W): method forward (line 1517) | def forward(self, x): class SwinTransformerBlock (line 1580) | class SwinTransformerBlock(nn.Module): method __init__ (line 1581) | def __init__(self, c1, c2, num_heads, num_layers, window_size=8): method forward (line 1591) | def forward(self, x): class STCSPA (line 1598) | class STCSPA(nn.Module): method __init__ (line 1600) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1610) | def forward(self, x): class STCSPB (line 1616) | class STCSPB(nn.Module): method __init__ (line 1618) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 1628) | def forward(self, x): class STCSPC (line 1635) | class STCSPC(nn.Module): method __init__ (line 1637) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1648) | def forward(self, x): class WindowAttention_v2 (line 1658) | class WindowAttention_v2(nn.Module): method __init__ (line 1660) | def __init__(self, dim, window_size, num_heads, qkv_bias=True, attn_dr... method forward (line 1719) | def forward(self, x, mask=None): method extra_repr (line 1760) | def extra_repr(self) -> str: method flops (line 1764) | def flops(self, N): class Mlp_v2 (line 1777) | class Mlp_v2(nn.Module): method __init__ (line 1778) | def __init__(self, in_features, hidden_features=None, out_features=Non... method forward (line 1787) | def forward(self, x): function window_partition_v2 (line 1796) | def window_partition_v2(x, window_size): function window_reverse_v2 (line 1804) | def window_reverse_v2(windows, window_size, H, W): class SwinTransformerLayer_v2 (line 1812) | class SwinTransformerLayer_v2(nn.Module): method __init__ (line 1814) | def __init__(self, dim, num_heads, window_size=7, shift_size=0, method create_mask (line 1841) | def create_mask(self, H, W): method forward (line 1863) | def forward(self, x): method extra_repr (line 1923) | def extra_repr(self) -> str: method flops (line 1927) | def flops(self): class SwinTransformer2Block (line 1942) | class SwinTransformer2Block(nn.Module): method __init__ (line 1943) | def __init__(self, c1, c2, num_heads, num_layers, window_size=7): method forward (line 1953) | def forward(self, x): class ST2CSPA (line 1960) | class ST2CSPA(nn.Module): method __init__ (line 1962) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1972) | def forward(self, x): class ST2CSPB (line 1978) | class ST2CSPB(nn.Module): method __init__ (line 1980) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 1990) | def forward(self, x): class ST2CSPC (line 1997) | class ST2CSPC(nn.Module): method __init__ (line 1999) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 2010) | def forward(self, x): FILE: asone/detectors/yolov7/yolov7/models/experimental.py class Ensemble (line 6) | class Ensemble(nn.ModuleList): method __init__ (line 8) | def __init__(self): method forward (line 11) | def forward(self, x, augment=False): function attempt_load (line 20) | def attempt_load(weights, map_location=None): FILE: asone/detectors/yolov7/yolov7/models/yolo.py class Detect (line 21) | class Detect(nn.Module): method __init__ (line 28) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 42) | def forward(self, x): method _make_grid (line 86) | def _make_grid(nx=20, ny=20): method convert (line 90) | def convert(self, z): class IDetect (line 103) | class IDetect(nn.Module): method __init__ (line 110) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 127) | def forward(self, x): method fuseforward (line 151) | def fuseforward(self, x): method fuse (line 195) | def fuse(self): method _make_grid (line 211) | def _make_grid(nx=20, ny=20): method convert (line 215) | def convert(self, z): class IKeypoint (line 228) | class IKeypoint(nn.Module): method __init__ (line 232) | def __init__(self, nc=80, anchors=(), nkpt=17, ch=(), inplace=True, dw... method forward (line 270) | def forward(self, x): method _make_grid (line 336) | def _make_grid(nx=20, ny=20): class IAuxDetect (line 341) | class IAuxDetect(nn.Module): method __init__ (line 348) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 368) | def forward(self, x): method fuseforward (line 405) | def fuseforward(self, x): method fuse (line 447) | def fuse(self): method _make_grid (line 463) | def _make_grid(nx=20, ny=20): method convert (line 467) | def convert(self, z): class IBin (line 480) | class IBin(nn.Module): method __init__ (line 484) | def __init__(self, nc=80, anchors=(), ch=(), bin_count=21): # detecti... method forward (line 511) | def forward(self, x): method _make_grid (line 557) | def _make_grid(nx=20, ny=20): class Model (line 562) | class Model(nn.Module): method __init__ (line 564) | def __init__(self, cfg='yolor-csp-c.yaml', ch=3, nc=None, anchors=None): method forward (line 644) | def forward(self, x, augment=False, profile=False): method forward_once (line 666) | def forward_once(self, x, profile=False): method _initialize_biases (line 701) | def _initialize_biases(self, cf=None): method _initialize_aux_biases (line 714) | def _initialize_aux_biases(self, cf=None): method _initialize_biases_bin (line 733) | def _initialize_biases_bin(self, cf=None): method _initialize_biases_kpt (line 751) | def _initialize_biases_kpt(self, cf=None): method _print_biases (line 763) | def _print_biases(self): method fuse (line 775) | def fuse(self): # fuse model Conv2d() + BatchNorm2d() layers method nms (line 794) | def nms(self, mode=True): # add or remove NMS module method autoshape (line 808) | def autoshape(self): # add autoShape module method info (line 815) | def info(self, verbose=False, img_size=640): # print model information function parse_model (line 819) | def parse_model(d, ch): # model_dict, input_channels(3) FILE: asone/detectors/yolov7/yolov7/utils/torch_utils.py function torch_distributed_zero_first (line 28) | def torch_distributed_zero_first(local_rank: int): function init_torch_seeds (line 39) | def init_torch_seeds(seed=0): function date_modified (line 48) | def date_modified(path=__file__): function git_describe (line 54) | def git_describe(path=Path(__file__).parent): # path must be a directory function select_device (line 63) | def select_device(device='', batch_size=None): function time_synchronized (line 89) | def time_synchronized(): function profile (line 96) | def profile(x, ops, n=100, device=None): function is_parallel (line 135) | def is_parallel(model): function intersect_dicts (line 139) | def intersect_dicts(da, db, exclude=()): function initialize_weights (line 144) | def initialize_weights(model): function find_modules (line 156) | def find_modules(model, mclass=nn.Conv2d): function sparsity (line 161) | def sparsity(model): function prune (line 170) | def prune(model, amount=0.3): function fuse_conv_and_bn (line 181) | def fuse_conv_and_bn(conv, bn): function model_info (line 204) | def model_info(model, verbose=False, img_size=640): function load_classifier (line 228) | def load_classifier(name='resnet101', n=2): function scale_img (line 247) | def scale_img(img, ratio=1.0, same_shape=False, gs=32): # img(16,3,256,... function copy_attr (line 260) | def copy_attr(a, b, include=(), exclude=()): class ModelEMA (line 269) | class ModelEMA: method __init__ (line 279) | def __init__(self, model, decay=0.9999, updates=0): method update (line 289) | def update(self, model): method update_attr (line 301) | def update_attr(self, model, include=(), exclude=('process_group', 're... class BatchNormXd (line 306) | class BatchNormXd(torch.nn.modules.batchnorm._BatchNorm): method _check_input_dim (line 307) | def _check_input_dim(self, input): function revert_sync_batchnorm (line 318) | def revert_sync_batchnorm(module): class TracedModel (line 343) | class TracedModel(nn.Module): method __init__ (line 345) | def __init__(self, model=None, device=None, img_size=(640,640)): method forward (line 371) | def forward(self, x, augment=False, profile=False): FILE: asone/detectors/yolov7/yolov7/utils/yolov7_utils.py function prepare_input (line 7) | def prepare_input(image, input_shape): function process_output (line 20) | def process_output(output, ori_shape, input_shape, conf_threshold, iou_t... function rescale_boxes (line 71) | def rescale_boxes(boxes, ori_shape, input_shape): function nms (line 81) | def nms(boxes, scores, iou_threshold): function compute_iou (line 103) | def compute_iou(box, boxes): function xywh2xyxy (line 124) | def xywh2xyxy(x): function non_max_suppression (line 133) | def non_max_suppression(prediction, conf_thres=0.25, iou_thres=0.45, cla... FILE: asone/detectors/yolov7/yolov7_detector.py function xywh2xyxy (line 19) | def xywh2xyxy(x): class YOLOv7Detector (line 29) | class YOLOv7Detector: method __init__ (line 30) | def __init__(self, method load_model (line 50) | def load_model(self, use_cuda, weights, fp16=False): method detect (line 71) | def detect(self, image: list, FILE: asone/detectors/yolov8/utils/yolov8_utils.py function prepare_input (line 7) | def prepare_input(image, input_shape, stride, pt): function process_output (line 16) | def process_output(detections, function rescale_boxes (line 46) | def rescale_boxes(boxes, ori_shape, input_shape): FILE: asone/detectors/yolov8/yolov8_detector.py class YOLOv8Detector (line 18) | class YOLOv8Detector: method __init__ (line 19) | def __init__(self, method load_model (line 39) | def load_model(self, use_cuda, weights, fp16=False): method detect (line 64) | def detect(self, image: list, FILE: asone/detectors/yolov9/export.py function export_formats (line 34) | def export_formats(): function try_export (line 53) | def try_export(inner_func): function export_torchscript (line 72) | def export_torchscript(model, im, file, optimize, prefix=colorstr('Torch... function export_onnx (line 88) | def export_onnx(model, im, file, opset, dynamic, simplify, prefix=colors... function export_onnx_end2end (line 144) | def export_onnx_end2end(model, im, file, simplify, topk_all, iou_thres, ... function export_openvino (line 202) | def export_openvino(file, metadata, half, prefix=colorstr('OpenVINO:')): function export_paddle (line 220) | def export_paddle(model, im, file, metadata, prefix=colorstr('PaddlePadd... function export_coreml (line 235) | def export_coreml(model, im, file, int8, half, prefix=colorstr('CoreML:')): function export_engine (line 258) | def export_engine(model, im, file, half, dynamic, simplify, workspace=4,... function export_saved_model (line 320) | def export_saved_model(model, function export_pb (line 372) | def export_pb(keras_model, file, prefix=colorstr('TensorFlow GraphDef:')): function export_tflite (line 389) | def export_tflite(keras_model, im, file, int8, data, nms, agnostic_nms, ... function export_edgetpu (line 420) | def export_edgetpu(file, prefix=colorstr('Edge TPU:')): function export_tfjs (line 445) | def export_tfjs(file, prefix=colorstr('TensorFlow.js:')): function add_tflite_metadata (line 473) | def add_tflite_metadata(file, metadata, num_outputs): function run (line 507) | def run( function parse_opt (line 639) | def parse_opt(): function main (line 679) | def main(opt): FILE: asone/detectors/yolov9/yolov9/models/common.py function autopad (line 34) | def autopad(k, p=None, d=1): # kernel, padding, dilation class Conv (line 43) | class Conv(nn.Module): method __init__ (line 47) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, d=1, act=True): method forward (line 53) | def forward(self, x): method forward_fuse (line 56) | def forward_fuse(self, x): class AConv (line 60) | class AConv(nn.Module): method __init__ (line 61) | def __init__(self, c1, c2): # ch_in, ch_out, shortcut, kernels, group... method forward (line 65) | def forward(self, x): class ADown (line 70) | class ADown(nn.Module): method __init__ (line 71) | def __init__(self, c1, c2): # ch_in, ch_out, shortcut, kernels, group... method forward (line 77) | def forward(self, x): class RepConvN (line 86) | class RepConvN(nn.Module): method __init__ (line 92) | def __init__(self, c1, c2, k=3, s=1, p=1, g=1, d=1, act=True, bn=False... method forward_fuse (line 104) | def forward_fuse(self, x): method forward (line 108) | def forward(self, x): method get_equivalent_kernel_bias (line 113) | def get_equivalent_kernel_bias(self): method _avg_to_3x3_tensor (line 119) | def _avg_to_3x3_tensor(self, avgp): method _pad_1x1_to_3x3_tensor (line 128) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 134) | def _fuse_bn_tensor(self, branch): method fuse_convs (line 161) | def fuse_convs(self): class SP (line 187) | class SP(nn.Module): method __init__ (line 188) | def __init__(self, k=3, s=1): method forward (line 192) | def forward(self, x): class MP (line 196) | class MP(nn.Module): method __init__ (line 198) | def __init__(self, k=2): method forward (line 202) | def forward(self, x): class ConvTranspose (line 206) | class ConvTranspose(nn.Module): method __init__ (line 210) | def __init__(self, c1, c2, k=2, s=2, p=0, bn=True, act=True): method forward (line 216) | def forward(self, x): class DWConv (line 220) | class DWConv(Conv): method __init__ (line 222) | def __init__(self, c1, c2, k=1, s=1, d=1, act=True): # ch_in, ch_out,... class DWConvTranspose2d (line 226) | class DWConvTranspose2d(nn.ConvTranspose2d): method __init__ (line 228) | def __init__(self, c1, c2, k=1, s=1, p1=0, p2=0): # ch_in, ch_out, ke... class DFL (line 232) | class DFL(nn.Module): method __init__ (line 234) | def __init__(self, c1=17): method forward (line 241) | def forward(self, x): class BottleneckBase (line 247) | class BottleneckBase(nn.Module): method __init__ (line 249) | def __init__(self, c1, c2, shortcut=True, g=1, k=(1, 3), e=0.5): # ch... method forward (line 256) | def forward(self, x): class RBottleneckBase (line 260) | class RBottleneckBase(nn.Module): method __init__ (line 262) | def __init__(self, c1, c2, shortcut=True, g=1, k=(3, 1), e=0.5): # ch... method forward (line 269) | def forward(self, x): class RepNRBottleneckBase (line 273) | class RepNRBottleneckBase(nn.Module): method __init__ (line 275) | def __init__(self, c1, c2, shortcut=True, g=1, k=(3, 1), e=0.5): # ch... method forward (line 282) | def forward(self, x): class Bottleneck (line 286) | class Bottleneck(nn.Module): method __init__ (line 288) | def __init__(self, c1, c2, shortcut=True, g=1, k=(3, 3), e=0.5): # ch... method forward (line 295) | def forward(self, x): class RepNBottleneck (line 299) | class RepNBottleneck(nn.Module): method __init__ (line 301) | def __init__(self, c1, c2, shortcut=True, g=1, k=(3, 3), e=0.5): # ch... method forward (line 308) | def forward(self, x): class Res (line 312) | class Res(nn.Module): method __init__ (line 314) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 322) | def forward(self, x): class RepNRes (line 326) | class RepNRes(nn.Module): method __init__ (line 328) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 336) | def forward(self, x): class BottleneckCSP (line 340) | class BottleneckCSP(nn.Module): method __init__ (line 342) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 353) | def forward(self, x): class CSP (line 359) | class CSP(nn.Module): method __init__ (line 361) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 369) | def forward(self, x): class RepNCSP (line 373) | class RepNCSP(nn.Module): method __init__ (line 375) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 383) | def forward(self, x): class CSPBase (line 387) | class CSPBase(nn.Module): method __init__ (line 389) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 397) | def forward(self, x): class SPP (line 401) | class SPP(nn.Module): method __init__ (line 403) | def __init__(self, c1, c2, k=(5, 9, 13)): method forward (line 410) | def forward(self, x): class ASPP (line 417) | class ASPP(torch.nn.Module): method __init__ (line 419) | def __init__(self, in_channels, out_channels): method forward (line 443) | def forward(self, x): class SPPCSPC (line 454) | class SPPCSPC(nn.Module): method __init__ (line 456) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... method forward (line 468) | def forward(self, x): class SPPF (line 475) | class SPPF(nn.Module): method __init__ (line 477) | def __init__(self, c1, c2, k=5): # equivalent to SPP(k=(5, 9, 13)) method forward (line 485) | def forward(self, x): class ReOrg (line 498) | class ReOrg(nn.Module): method __init__ (line 500) | def __init__(self): method forward (line 503) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class Contract (line 507) | class Contract(nn.Module): method __init__ (line 509) | def __init__(self, gain=2): method forward (line 513) | def forward(self, x): class Expand (line 521) | class Expand(nn.Module): method __init__ (line 523) | def __init__(self, gain=2): method forward (line 527) | def forward(self, x): class Concat (line 535) | class Concat(nn.Module): method __init__ (line 537) | def __init__(self, dimension=1): method forward (line 541) | def forward(self, x): class Shortcut (line 545) | class Shortcut(nn.Module): method __init__ (line 546) | def __init__(self, dimension=0): method forward (line 550) | def forward(self, x): class Silence (line 554) | class Silence(nn.Module): method __init__ (line 555) | def __init__(self): method forward (line 557) | def forward(self, x): class SPPELAN (line 563) | class SPPELAN(nn.Module): method __init__ (line 565) | def __init__(self, c1, c2, c3): # ch_in, ch_out, number, shortcut, gr... method forward (line 574) | def forward(self, x): class RepNCSPELAN4 (line 580) | class RepNCSPELAN4(nn.Module): method __init__ (line 582) | def __init__(self, c1, c2, c3, c4, c5=1): # ch_in, ch_out, number, sh... method forward (line 590) | def forward(self, x): method forward_split (line 595) | def forward_split(self, x): class ImplicitA (line 605) | class ImplicitA(nn.Module): method __init__ (line 606) | def __init__(self, channel): method forward (line 612) | def forward(self, x): class ImplicitM (line 616) | class ImplicitM(nn.Module): method __init__ (line 617) | def __init__(self, channel): method forward (line 623) | def forward(self, x): class CBLinear (line 631) | class CBLinear(nn.Module): method __init__ (line 632) | def __init__(self, c1, c2s, k=1, s=1, p=None, g=1): # ch_in, ch_outs,... method forward (line 637) | def forward(self, x): class CBFuse (line 641) | class CBFuse(nn.Module): method __init__ (line 642) | def __init__(self, idx): method forward (line 646) | def forward(self, xs): class DetectMultiBackend (line 655) | class DetectMultiBackend(nn.Module): method __init__ (line 657) | def __init__(self, weights='yolo.pt', device=torch.device('cpu'), dnn=... method forward (line 845) | def forward(self, im, augment=False, visualize=False): method from_numpy (line 927) | def from_numpy(self, x): method warmup (line 930) | def warmup(self, imgsz=(1, 3, 640, 640)): method _model_type (line 939) | def _model_type(p='path/to/model.pt'): method _load_metadata (line 954) | def _load_metadata(f=Path('path/to/meta.yaml')): class AutoShape (line 962) | class AutoShape(nn.Module): method __init__ (line 972) | def __init__(self, model, verbose=True): method _apply (line 985) | def _apply(self, fn): method forward (line 998) | def forward(self, ims, size=640, augment=False, profile=False): class Detections (line 1062) | class Detections: method __init__ (line 1064) | def __init__(self, ims, pred, files, times=(0, 0, 0), names=None, shap... method _run (line 1081) | def _run(self, pprint=False, show=False, save=False, crop=False, rende... method show (line 1127) | def show(self, labels=True): method save (line 1130) | def save(self, labels=True, save_dir='runs/detect/exp', exist_ok=False): method crop (line 1134) | def crop(self, save=True, save_dir='runs/detect/exp', exist_ok=False): method render (line 1138) | def render(self, labels=True): method pandas (line 1142) | def pandas(self): method tolist (line 1152) | def tolist(self): method print (line 1161) | def print(self): method __len__ (line 1164) | def __len__(self): # override len(results) method __str__ (line 1167) | def __str__(self): # override print(results) method __repr__ (line 1170) | def __repr__(self): class Proto (line 1174) | class Proto(nn.Module): method __init__ (line 1176) | def __init__(self, c1, c_=256, c2=32): # ch_in, number of protos, num... method forward (line 1183) | def forward(self, x): class UConv (line 1187) | class UConv(nn.Module): method __init__ (line 1188) | def __init__(self, c1, c_=256, c2=256): # ch_in, number of protos, nu... method forward (line 1195) | def forward(self, x): class Classify (line 1199) | class Classify(nn.Module): method __init__ (line 1201) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1): # ch_in, ch_out, k... method forward (line 1209) | def forward(self, x): FILE: asone/detectors/yolov9/yolov9/models/experimental.py class Sum (line 11) | class Sum(nn.Module): method __init__ (line 13) | def __init__(self, n, weight=False): # n: number of inputs method forward (line 20) | def forward(self, x): class MixConv2d (line 32) | class MixConv2d(nn.Module): method __init__ (line 34) | def __init__(self, c1, c2, k=(1, 3), s=1, equal_ch=True): # ch_in, ch... method forward (line 53) | def forward(self, x): class Ensemble (line 57) | class Ensemble(nn.ModuleList): method __init__ (line 59) | def __init__(self): method forward (line 62) | def forward(self, x, augment=False, profile=False, visualize=False): class ORT_NMS (line 70) | class ORT_NMS(torch.autograd.Function): method forward (line 73) | def forward(ctx, method symbolic (line 90) | def symbolic(g, boxes, scores, max_output_boxes_per_class, iou_thresho... class TRT_NMS (line 94) | class TRT_NMS(torch.autograd.Function): method forward (line 97) | def forward( method symbolic (line 118) | def symbolic(g, class ONNX_ORT (line 143) | class ONNX_ORT(nn.Module): method __init__ (line 145) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 157) | def forward(self, x): class ONNX_TRT (line 185) | class ONNX_TRT(nn.Module): method __init__ (line 187) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 200) | def forward(self, x): class End2End (line 220) | class End2End(nn.Module): method __init__ (line 222) | def __init__(self, model, max_obj=100, iou_thres=0.45, score_thres=0.2... method forward (line 232) | def forward(self, x): function attempt_load (line 238) | def attempt_load(weights, device=None, inplace=True, fuse=True): FILE: asone/detectors/yolov9/yolov9/models/tf.py class TFBN (line 26) | class TFBN(keras.layers.Layer): method __init__ (line 28) | def __init__(self, w=None): method call (line 37) | def call(self, inputs): class TFPad (line 41) | class TFPad(keras.layers.Layer): method __init__ (line 43) | def __init__(self, pad): method call (line 50) | def call(self, inputs): class TFConv (line 54) | class TFConv(keras.layers.Layer): method __init__ (line 56) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True, w=None): method call (line 74) | def call(self, inputs): class TFDWConv (line 78) | class TFDWConv(keras.layers.Layer): method __init__ (line 80) | def __init__(self, c1, c2, k=1, s=1, p=None, act=True, w=None): method call (line 96) | def call(self, inputs): class TFDWConvTranspose2d (line 100) | class TFDWConvTranspose2d(keras.layers.Layer): method __init__ (line 102) | def __init__(self, c1, c2, k=1, s=1, p1=0, p2=0, w=None): method call (line 119) | def call(self, inputs): class TFFocus (line 123) | class TFFocus(keras.layers.Layer): method __init__ (line 125) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True, w=None): method call (line 130) | def call(self, inputs): # x(b,w,h,c) -> y(b,w/2,h/2,4c) class TFBottleneck (line 136) | class TFBottleneck(keras.layers.Layer): method __init__ (line 138) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5, w=None): # ch_i... method call (line 145) | def call(self, inputs): class TFCrossConv (line 149) | class TFCrossConv(keras.layers.Layer): method __init__ (line 151) | def __init__(self, c1, c2, k=3, s=1, g=1, e=1.0, shortcut=False, w=None): method call (line 158) | def call(self, inputs): class TFConv2d (line 162) | class TFConv2d(keras.layers.Layer): method __init__ (line 164) | def __init__(self, c1, c2, k, s=1, g=1, bias=True, w=None): method call (line 176) | def call(self, inputs): class TFBottleneckCSP (line 180) | class TFBottleneckCSP(keras.layers.Layer): method __init__ (line 182) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 194) | def call(self, inputs): class TFC3 (line 200) | class TFC3(keras.layers.Layer): method __init__ (line 202) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 211) | def call(self, inputs): class TFC3x (line 215) | class TFC3x(keras.layers.Layer): method __init__ (line 217) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5, w=None): method call (line 227) | def call(self, inputs): class TFSPP (line 231) | class TFSPP(keras.layers.Layer): method __init__ (line 233) | def __init__(self, c1, c2, k=(5, 9, 13), w=None): method call (line 240) | def call(self, inputs): class TFSPPF (line 245) | class TFSPPF(keras.layers.Layer): method __init__ (line 247) | def __init__(self, c1, c2, k=5, w=None): method call (line 254) | def call(self, inputs): class TFDetect (line 261) | class TFDetect(keras.layers.Layer): method __init__ (line 263) | def __init__(self, nc=80, anchors=(), ch=(), imgsz=(640, 640), w=None)... method call (line 280) | def call(self, inputs): method _make_grid (line 304) | def _make_grid(nx=20, ny=20): class TFSegment (line 311) | class TFSegment(TFDetect): method __init__ (line 313) | def __init__(self, nc=80, anchors=(), nm=32, npr=256, ch=(), imgsz=(64... method call (line 322) | def call(self, x): class TFProto (line 330) | class TFProto(keras.layers.Layer): method __init__ (line 332) | def __init__(self, c1, c_=256, c2=32, w=None): method call (line 339) | def call(self, inputs): class TFUpsample (line 343) | class TFUpsample(keras.layers.Layer): method __init__ (line 345) | def __init__(self, size, scale_factor, mode, w=None): # warning: all ... method call (line 354) | def call(self, inputs): class TFConcat (line 358) | class TFConcat(keras.layers.Layer): method __init__ (line 360) | def __init__(self, dimension=1, w=None): method call (line 365) | def call(self, inputs): function parse_model (line 369) | def parse_model(d, ch, model, imgsz): # model_dict, input_channels(3) class TFModel (line 425) | class TFModel: method __init__ (line 427) | def __init__(self, cfg='yolo.yaml', ch=3, nc=None, model=None, imgsz=(... method predict (line 443) | def predict(self, method _xywh2xyxy (line 486) | def _xywh2xyxy(xywh): class AgnosticNMS (line 492) | class AgnosticNMS(keras.layers.Layer): method call (line 494) | def call(self, input, topk_all, iou_thres, conf_thres): method _nms (line 502) | def _nms(x, topk_all=100, iou_thres=0.45, conf_thres=0.25): # agnosti... function activations (line 530) | def activations(act=nn.SiLU): function representative_dataset_gen (line 542) | def representative_dataset_gen(dataset, ncalib=100): function run (line 553) | def run( function parse_opt (line 578) | def parse_opt(): function main (line 590) | def main(opt): FILE: asone/detectors/yolov9/yolov9/models/yolo.py class Detect (line 29) | class Detect(nn.Module): method __init__ (line 37) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 53) | def forward(self, x): method bias_init (line 68) | def bias_init(self): class DDetect (line 78) | class DDetect(nn.Module): method __init__ (line 86) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 102) | def forward(self, x): method bias_init (line 117) | def bias_init(self): class DualDetect (line 127) | class DualDetect(nn.Module): method __init__ (line 135) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 157) | def forward(self, x): method bias_init (line 177) | def bias_init(self): class DualDDetect (line 190) | class DualDDetect(nn.Module): method __init__ (line 198) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 220) | def forward(self, x): method bias_init (line 246) | def bias_init(self): class TripleDetect (line 259) | class TripleDetect(nn.Module): method __init__ (line 267) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 295) | def forward(self, x): method bias_init (line 319) | def bias_init(self): class TripleDDetect (line 335) | class TripleDDetect(nn.Module): method __init__ (line 343) | def __init__(self, nc=80, ch=(), inplace=True): # detection layer method forward (line 377) | def forward(self, x): method bias_init (line 403) | def bias_init(self): class Segment (line 419) | class Segment(Detect): method __init__ (line 421) | def __init__(self, nc=80, nm=32, npr=256, ch=(), inplace=True): method forward (line 431) | def forward(self, x): class Panoptic (line 442) | class Panoptic(Detect): method __init__ (line 444) | def __init__(self, nc=80, sem_nc=93, nm=32, npr=256, ch=(), inplace=Tr... method forward (line 457) | def forward(self, x): class BaseModel (line 469) | class BaseModel(nn.Module): method forward (line 471) | def forward(self, x, profile=False, visualize=False): method _forward_once (line 474) | def _forward_once(self, x, profile=False, visualize=False): method _profile_one_layer (line 487) | def _profile_one_layer(self, m, x, dt): method fuse (line 500) | def fuse(self): # fuse model Conv2d() + BatchNorm2d() layers method info (line 513) | def info(self, verbose=False, img_size=640): # print model information method _apply (line 516) | def _apply(self, fn): class DetectionModel (line 528) | class DetectionModel(BaseModel): method __init__ (line 530) | def __init__(self, cfg='yolo.yaml', ch=3, nc=None, anchors=None): # m... method forward (line 579) | def forward(self, x, augment=False, profile=False, visualize=False): method _forward_augment (line 584) | def _forward_augment(self, x): method _descale_pred (line 598) | def _descale_pred(self, p, flips, scale, img_size): method _clip_augmented (line 615) | def _clip_augmented(self, y): class SegmentationModel (line 630) | class SegmentationModel(DetectionModel): method __init__ (line 632) | def __init__(self, cfg='yolo-seg.yaml', ch=3, nc=None, anchors=None): class ClassificationModel (line 636) | class ClassificationModel(BaseModel): method __init__ (line 638) | def __init__(self, cfg=None, model=None, nc=1000, cutoff=10): # yaml,... method _from_detection_model (line 642) | def _from_detection_model(self, model, nc=1000, cutoff=10): method _from_yaml (line 657) | def _from_yaml(self, cfg): function parse_model (line 662) | def parse_model(d, ch): # model_dict, input_channels(3) FILE: asone/detectors/yolov9/yolov9/utils/__init__.py function emojis (line 6) | def emojis(str=''): class TryExcept (line 11) | class TryExcept(contextlib.ContextDecorator): method __init__ (line 13) | def __init__(self, msg=''): method __enter__ (line 16) | def __enter__(self): method __exit__ (line 19) | def __exit__(self, exc_type, value, traceback): function threaded (line 25) | def threaded(func): function join_threads (line 35) | def join_threads(verbose=False): function notebook_init (line 45) | def notebook_init(verbose=True): FILE: asone/detectors/yolov9/yolov9/utils/activations.py class SiLU (line 6) | class SiLU(nn.Module): method forward (line 9) | def forward(x): class Hardswish (line 13) | class Hardswish(nn.Module): method forward (line 16) | def forward(x): class Mish (line 21) | class Mish(nn.Module): method forward (line 24) | def forward(x): class MemoryEfficientMish (line 28) | class MemoryEfficientMish(nn.Module): class F (line 30) | class F(torch.autograd.Function): method forward (line 33) | def forward(ctx, x): method backward (line 38) | def backward(ctx, grad_output): method forward (line 44) | def forward(self, x): class FReLU (line 48) | class FReLU(nn.Module): method __init__ (line 50) | def __init__(self, c1, k=3): # ch_in, kernel method forward (line 55) | def forward(self, x): class AconC (line 59) | class AconC(nn.Module): method __init__ (line 65) | def __init__(self, c1): method forward (line 71) | def forward(self, x): class MetaAconC (line 76) | class MetaAconC(nn.Module): method __init__ (line 82) | def __init__(self, c1, k=1, s=1, r=16): # ch_in, kernel, stride, r method forward (line 92) | def forward(self, x): FILE: asone/detectors/yolov9/yolov9/utils/augmentations.py class Albumentations (line 17) | class Albumentations: method __init__ (line 19) | def __init__(self, size=640): method __call__ (line 43) | def __call__(self, im, labels, p=1.0): function normalize (line 50) | def normalize(x, mean=IMAGENET_MEAN, std=IMAGENET_STD, inplace=False): function denormalize (line 55) | def denormalize(x, mean=IMAGENET_MEAN, std=IMAGENET_STD): function augment_hsv (line 62) | def augment_hsv(im, hgain=0.5, sgain=0.5, vgain=0.5): function hist_equalize (line 78) | def hist_equalize(im, clahe=True, bgr=False): function replicate (line 89) | def replicate(im, labels): function letterbox (line 106) | def letterbox(im, new_shape=(640, 640), color=(114, 114, 114), auto=True... function random_perspective (line 139) | def random_perspective(im, function copy_paste (line 235) | def copy_paste(im, labels, segments, p=0.5): function cutout (line 260) | def cutout(im, labels, p=0.5): function mixup (line 287) | def mixup(im, labels, im2, labels2): function box_candidates (line 295) | def box_candidates(box1, box2, wh_thr=2, ar_thr=100, area_thr=0.1, eps=1... function classify_albumentations (line 303) | def classify_albumentations( function classify_transforms (line 345) | def classify_transforms(size=224): class LetterBox (line 352) | class LetterBox: method __init__ (line 354) | def __init__(self, size=(640, 640), auto=False, stride=32): method __call__ (line 360) | def __call__(self, im): # im = np.array HWC class CenterCrop (line 371) | class CenterCrop: method __init__ (line 373) | def __init__(self, size=640): method __call__ (line 377) | def __call__(self, im): # im = np.array HWC class ToTensor (line 384) | class ToTensor: method __init__ (line 386) | def __init__(self, half=False): method __call__ (line 390) | def __call__(self, im): # im = np.array HWC in BGR order FILE: asone/detectors/yolov9/yolov9/utils/autoanchor.py function check_anchor_order (line 14) | def check_anchor_order(m): function check_anchors (line 25) | def check_anchors(dataset, model, thr=4.0, imgsz=640): function kmean_anchors (line 62) | def kmean_anchors(dataset='./data/coco128.yaml', n=9, img_size=640, thr=... FILE: asone/detectors/yolov9/yolov9/utils/autobatch.py function check_train_batch_size (line 10) | def check_train_batch_size(model, imgsz=640, amp=True): function autobatch (line 16) | def autobatch(model, imgsz=640, fraction=0.8, batch_size=16): FILE: asone/detectors/yolov9/yolov9/utils/callbacks.py class Callbacks (line 4) | class Callbacks: method __init__ (line 9) | def __init__(self): method register_action (line 33) | def register_action(self, hook, name='', callback=None): method get_registered_actions (line 46) | def get_registered_actions(self, hook=None): method run (line 55) | def run(self, hook, *args, thread=False, **kwargs): FILE: asone/detectors/yolov9/yolov9/utils/coco_utils.py function getCocoIds (line 53) | def getCocoIds(name = 'semantic'): function getMappingId (line 63) | def getMappingId(index, name = 'semantic'): function getMappingIndex (line 67) | def getMappingIndex(id, name = 'semantic'): function annToRLE (line 72) | def annToRLE(ann, img_size): function annToMask (line 89) | def annToMask(ann, img_size): function convert_to_polys (line 95) | def convert_to_polys(mask): FILE: asone/detectors/yolov9/yolov9/utils/dataloaders.py function get_hash (line 47) | def get_hash(paths): function exif_size (line 55) | def exif_size(img): function exif_transpose (line 65) | def exif_transpose(image): function seed_worker (line 91) | def seed_worker(worker_id): function create_dataloader (line 98) | def create_dataloader(path, class InfiniteDataLoader (line 154) | class InfiniteDataLoader(dataloader.DataLoader): method __init__ (line 160) | def __init__(self, *args, **kwargs): method __len__ (line 165) | def __len__(self): method __iter__ (line 168) | def __iter__(self): class _RepeatSampler (line 173) | class _RepeatSampler: method __init__ (line 180) | def __init__(self, sampler): method __iter__ (line 183) | def __iter__(self): class LoadScreenshots (line 188) | class LoadScreenshots: method __init__ (line 190) | def __init__(self, source, img_size=640, stride=32, auto=True, transfo... method __iter__ (line 219) | def __iter__(self): method __next__ (line 222) | def __next__(self): class LoadImages (line 237) | class LoadImages: method __init__ (line 239) | def __init__(self, path, img_size=640, stride=32, auto=True, transform... method __iter__ (line 272) | def __iter__(self): method __next__ (line 276) | def __next__(self): method _new_video (line 316) | def _new_video(self, path): method _cv2_rotate (line 324) | def _cv2_rotate(self, im): method __len__ (line 334) | def __len__(self): class LoadStreams (line 338) | class LoadStreams: method __init__ (line 340) | def __init__(self, sources='streams.txt', img_size=640, stride=32, aut... method update (line 384) | def update(self, i, cap, stream): method __iter__ (line 400) | def __iter__(self): method __next__ (line 404) | def __next__(self): method __len__ (line 420) | def __len__(self): function img2label_paths (line 424) | def img2label_paths(img_paths): class LoadImagesAndLabels (line 430) | class LoadImagesAndLabels(Dataset): method __init__ (line 435) | def __init__(self, method check_cache_ram (line 585) | def check_cache_ram(self, safety_margin=0.1, prefix=''): method cache_labels (line 602) | def cache_labels(self, path=Path('./labels.cache'), prefix=''): method __len__ (line 640) | def __len__(self): method __getitem__ (line 649) | def __getitem__(self, index): method load_image (line 723) | def load_image(self, i): method cache_images_to_disk (line 740) | def cache_images_to_disk(self, i): method load_mosaic (line 746) | def load_mosaic(self, index): method load_mosaic9 (line 804) | def load_mosaic9(self, index): method collate_fn (line 882) | def collate_fn(batch): method collate_fn4 (line 889) | def collate_fn4(batch): function flatten_recursive (line 916) | def flatten_recursive(path=DATASETS_DIR / 'coco128'): function extract_boxes (line 926) | def extract_boxes(path=DATASETS_DIR / 'coco128'): # from utils.dataload... function autosplit (line 960) | def autosplit(path=DATASETS_DIR / 'coco128/images', weights=(0.9, 0.1, 0... function verify_image_label (line 986) | def verify_image_label(args): class HUBDatasetStats (line 1038) | class HUBDatasetStats(): method __init__ (line 1053) | def __init__(self, path='coco128.yaml', autodownload=False): method _find_yaml (line 1072) | def _find_yaml(dir): method _unzip (line 1082) | def _unzip(self, path): method _hub_ops (line 1092) | def _hub_ops(self, f, max_dim=1920): method get_json (line 1110) | def get_json(self, save=False, verbose=False): method process_images (line 1145) | def process_images(self): class ClassificationDataset (line 1159) | class ClassificationDataset(torchvision.datasets.ImageFolder): method __init__ (line 1168) | def __init__(self, root, augment, imgsz, cache=False): method __getitem__ (line 1176) | def __getitem__(self, i): function create_classification_dataloader (line 1193) | def create_classification_dataloader(path, FILE: asone/detectors/yolov9/yolov9/utils/downloads.py function is_url (line 11) | def is_url(url, check=True): function gsutil_getsize (line 22) | def gsutil_getsize(url=''): function url_getsize (line 28) | def url_getsize(url='https://ultralytics.com/images/bus.jpg'): function safe_download (line 34) | def safe_download(file, url, url2=None, min_bytes=1E0, error_msg=''): function attempt_download (line 57) | def attempt_download(file, repo='ultralytics/yolov5', release='v7.0'): FILE: asone/detectors/yolov9/yolov9/utils/general.py function is_ascii (line 58) | def is_ascii(s=''): function is_chinese (line 64) | def is_chinese(s='人工智能'): function is_colab (line 69) | def is_colab(): function is_notebook (line 74) | def is_notebook(): function is_kaggle (line 80) | def is_kaggle(): function is_docker (line 85) | def is_docker() -> bool: function is_writeable (line 96) | def is_writeable(dir, test=False): function set_logging (line 113) | def set_logging(name=LOGGING_NAME, verbose=True): function user_config_dir (line 142) | def user_config_dir(dir='Ultralytics', env_var='YOLOV5_CONFIG_DIR'): class Profile (line 158) | class Profile(contextlib.ContextDecorator): method __init__ (line 160) | def __init__(self, t=0.0): method __enter__ (line 164) | def __enter__(self): method __exit__ (line 168) | def __exit__(self, type, value, traceback): method time (line 172) | def time(self): class Timeout (line 178) | class Timeout(contextlib.ContextDecorator): method __init__ (line 180) | def __init__(self, seconds, *, timeout_msg='', suppress_timeout_errors... method _timeout_handler (line 185) | def _timeout_handler(self, signum, frame): method __enter__ (line 188) | def __enter__(self): method __exit__ (line 193) | def __exit__(self, exc_type, exc_val, exc_tb): class WorkingDirectory (line 200) | class WorkingDirectory(contextlib.ContextDecorator): method __init__ (line 202) | def __init__(self, new_dir): method __enter__ (line 206) | def __enter__(self): method __exit__ (line 209) | def __exit__(self, exc_type, exc_val, exc_tb): function methods (line 213) | def methods(instance): function print_args (line 218) | def print_args(args: Optional[dict] = None, show_file=True, show_func=Fa... function init_seeds (line 233) | def init_seeds(seed=0, deterministic=False): function intersect_dicts (line 248) | def intersect_dicts(da, db, exclude=()): function get_default_args (line 253) | def get_default_args(func): function get_latest_run (line 259) | def get_latest_run(search_dir='.'): function file_age (line 265) | def file_age(path=__file__): function file_date (line 271) | def file_date(path=__file__): function file_size (line 277) | def file_size(path): function check_online (line 289) | def check_online(): function git_describe (line 304) | def git_describe(path=ROOT): # path must be a directory function check_git_status (line 315) | def check_git_status(repo='WongKinYiu/yolov9', branch='main'): function check_git_info (line 342) | def check_git_info(path='.'): function check_python (line 359) | def check_python(minimum='3.7.0'): function check_version (line 364) | def check_version(current='0.0.0', minimum='0.0.0', name='version ', pin... function check_requirements (line 377) | def check_requirements(requirements=ROOT / 'requirements.txt', exclude=(... function check_img_size (line 411) | def check_img_size(imgsz, s=32, floor=0): function check_imshow (line 423) | def check_imshow(warn=False): function check_suffix (line 439) | def check_suffix(file='yolo.pt', suffix=('.pt',), msg=''): function check_yaml (line 450) | def check_yaml(file, suffix=('.yaml', '.yml')): function check_file (line 455) | def check_file(file, suffix=''): function check_font (line 483) | def check_font(font=FONT, progress=False): function check_dataset (line 493) | def check_dataset(data, autodownload=True): function check_amp (line 559) | def check_amp(model): function yaml_load (line 587) | def yaml_load(file='data.yaml'): function yaml_save (line 593) | def yaml_save(file='data.yaml', data={}): function unzip_file (line 599) | def unzip_file(file, path=None, exclude=('.DS_Store', '__MACOSX')): function url2file (line 609) | def url2file(url): function download (line 615) | def download(url, dir='.', unzip=True, delete=True, curl=False, threads=... function make_divisible (line 664) | def make_divisible(x, divisor): function clean_str (line 671) | def clean_str(s): function one_cycle (line 676) | def one_cycle(y1=0.0, y2=1.0, steps=100): function one_flat_cycle (line 681) | def one_flat_cycle(y1=0.0, y2=1.0, steps=100): function colorstr (line 687) | def colorstr(*input): function labels_to_class_weights (line 713) | def labels_to_class_weights(labels, nc=80): function labels_to_image_weights (line 732) | def labels_to_image_weights(labels, nc=80, class_weights=np.ones(80)): function coco80_to_coco91_class (line 739) | def coco80_to_coco91_class(): # converts 80-index (val2014) to 91-index... function xyxy2xywh (line 751) | def xyxy2xywh(x): function xywh2xyxy (line 761) | def xywh2xyxy(x): function xywhn2xyxy (line 771) | def xywhn2xyxy(x, w=640, h=640, padw=0, padh=0): function xyxy2xywhn (line 781) | def xyxy2xywhn(x, w=640, h=640, clip=False, eps=0.0): function xyn2xy (line 793) | def xyn2xy(x, w=640, h=640, padw=0, padh=0): function segment2box (line 801) | def segment2box(segment, width=640, height=640): function segments2boxes (line 809) | def segments2boxes(segments): function resample_segments (line 818) | def resample_segments(segments, n=1000): function scale_boxes (line 828) | def scale_boxes(img1_shape, boxes, img0_shape, ratio_pad=None): function scale_segments (line 844) | def scale_segments(img1_shape, segments, img0_shape, ratio_pad=None, nor... function clip_boxes (line 863) | def clip_boxes(boxes, shape): function clip_segments (line 875) | def clip_segments(segments, shape): function non_max_suppression (line 885) | def non_max_suppression( function strip_optimizer (line 997) | def strip_optimizer(f='best.pt', s=''): # from utils.general import *; ... function print_mutation (line 1013) | def print_mutation(keys, results, hyp, save_dir, bucket, prefix=colorstr... function apply_classifier (line 1052) | def apply_classifier(x, model, img, im0): function increment_path (line 1087) | def increment_path(path, exist_ok=False, sep='', mkdir=False): function imread (line 1117) | def imread(path, flags=cv2.IMREAD_COLOR): function imwrite (line 1121) | def imwrite(path, im): function imshow (line 1129) | def imshow(path, im): FILE: asone/detectors/yolov9/yolov9/utils/lion.py class Lion (line 6) | class Lion(Optimizer): method __init__ (line 9) | def __init__(self, params, lr=1e-4, betas=(0.9, 0.99), weight_decay=0.0): method step (line 30) | def step(self, closure=None): FILE: asone/detectors/yolov9/yolov9/utils/loss.py function smooth_BCE (line 9) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class BCEBlurWithLogitsLoss (line 14) | class BCEBlurWithLogitsLoss(nn.Module): method __init__ (line 16) | def __init__(self, alpha=0.05): method forward (line 21) | def forward(self, pred, true): class FocalLoss (line 31) | class FocalLoss(nn.Module): method __init__ (line 33) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 41) | def forward(self, pred, true): class QFocalLoss (line 61) | class QFocalLoss(nn.Module): method __init__ (line 63) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 71) | def forward(self, pred, true): class ComputeLoss (line 87) | class ComputeLoss: method __init__ (line 91) | def __init__(self, model, autobalance=False): method __call__ (line 116) | def __call__(self, p, targets): # predictions, targets method build_targets (line 171) | def build_targets(self, p, targets): class ComputeLoss_NEW (line 228) | class ComputeLoss_NEW: method __init__ (line 232) | def __init__(self, model, autobalance=False): method __call__ (line 258) | def __call__(self, p, targets): # predictions, targets method build_targets (line 303) | def build_targets(self, p, targets): FILE: asone/detectors/yolov9/yolov9/utils/loss_tal.py function smooth_BCE (line 14) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class VarifocalLoss (line 19) | class VarifocalLoss(nn.Module): method __init__ (line 21) | def __init__(self): method forward (line 24) | def forward(self, pred_score, gt_score, label, alpha=0.75, gamma=2.0): class FocalLoss (line 32) | class FocalLoss(nn.Module): method __init__ (line 34) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 42) | def forward(self, pred, true): class BboxLoss (line 62) | class BboxLoss(nn.Module): method __init__ (line 63) | def __init__(self, reg_max, use_dfl=False): method forward (line 68) | def forward(self, pred_dist, pred_bboxes, anchor_points, target_bboxes... method _df_loss (line 94) | def _df_loss(self, pred_dist, target): class ComputeLoss (line 106) | class ComputeLoss: method __init__ (line 108) | def __init__(self, model, use_dfl=True): method preprocess (line 142) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 157) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 165) | def __call__(self, p, targets, img=None, epoch=0): FILE: asone/detectors/yolov9/yolov9/utils/loss_tal_dual.py function smooth_BCE (line 14) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class VarifocalLoss (line 19) | class VarifocalLoss(nn.Module): method __init__ (line 21) | def __init__(self): method forward (line 24) | def forward(self, pred_score, gt_score, label, alpha=0.75, gamma=2.0): class FocalLoss (line 32) | class FocalLoss(nn.Module): method __init__ (line 34) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 42) | def forward(self, pred, true): class BboxLoss (line 62) | class BboxLoss(nn.Module): method __init__ (line 63) | def __init__(self, reg_max, use_dfl=False): method forward (line 68) | def forward(self, pred_dist, pred_bboxes, anchor_points, target_bboxes... method _df_loss (line 94) | def _df_loss(self, pred_dist, target): class ComputeLoss (line 106) | class ComputeLoss: method __init__ (line 108) | def __init__(self, model, use_dfl=True): method preprocess (line 147) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 162) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 170) | def __call__(self, p, targets, img=None, epoch=0): class ComputeLossLH (line 254) | class ComputeLossLH: method __init__ (line 256) | def __init__(self, model, use_dfl=True): method preprocess (line 290) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 305) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 313) | def __call__(self, p, targets, img=None, epoch=0): FILE: asone/detectors/yolov9/yolov9/utils/loss_tal_triple.py function smooth_BCE (line 14) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class VarifocalLoss (line 19) | class VarifocalLoss(nn.Module): method __init__ (line 21) | def __init__(self): method forward (line 24) | def forward(self, pred_score, gt_score, label, alpha=0.75, gamma=2.0): class FocalLoss (line 32) | class FocalLoss(nn.Module): method __init__ (line 34) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 42) | def forward(self, pred, true): class BboxLoss (line 62) | class BboxLoss(nn.Module): method __init__ (line 63) | def __init__(self, reg_max, use_dfl=False): method forward (line 68) | def forward(self, pred_dist, pred_bboxes, anchor_points, target_bboxes... method _df_loss (line 94) | def _df_loss(self, pred_dist, target): class ComputeLoss (line 106) | class ComputeLoss: method __init__ (line 108) | def __init__(self, model, use_dfl=True): method preprocess (line 152) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 167) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 175) | def __call__(self, p, targets, img=None, epoch=0): FILE: asone/detectors/yolov9/yolov9/utils/metrics.py function fitness (line 12) | def fitness(x): function smooth (line 18) | def smooth(y, f=0.05): function ap_per_class (line 26) | def ap_per_class(tp, conf, pred_cls, target_cls, plot=False, save_dir='.... function compute_ap (line 93) | def compute_ap(recall, precision): class ConfusionMatrix (line 121) | class ConfusionMatrix: method __init__ (line 123) | def __init__(self, nc, conf=0.25, iou_thres=0.45): method process_batch (line 129) | def process_batch(self, detections, labels): method matrix (line 175) | def matrix(self): method tp_fp (line 178) | def tp_fp(self): method plot (line 185) | def plot(self, normalize=True, save_dir='', names=()): method print (line 215) | def print(self): class WIoU_Scale (line 220) | class WIoU_Scale: method __init__ (line 233) | def __init__(self, iou): method _update (line 238) | def _update(cls, self): method _scaled_loss (line 243) | def _scaled_loss(cls, self, gamma=1.9, delta=3): function bbox_iou (line 254) | def bbox_iou(box1, box2, xywh=True, GIoU=False, DIoU=False, CIoU=False, ... function box_iou (line 300) | def box_iou(box1, box2, eps=1e-7): function bbox_ioa (line 321) | def bbox_ioa(box1, box2, eps=1e-7): function wh_iou (line 343) | def wh_iou(wh1, wh2, eps=1e-7): function plot_pr_curve (line 355) | def plot_pr_curve(px, py, ap, save_dir=Path('pr_curve.png'), names=()): function plot_mc_curve (line 378) | def plot_mc_curve(px, py, save_dir=Path('mc_curve.png'), names=(), xlabe... FILE: asone/detectors/yolov9/yolov9/utils/plots.py class Colors (line 29) | class Colors: method __init__ (line 31) | def __init__(self): method __call__ (line 38) | def __call__(self, i, bgr=False): method hex2rgb (line 43) | def hex2rgb(h): # rgb order (PIL) function check_pil_font (line 50) | def check_pil_font(font=FONT, size=10): class Annotator (line 66) | class Annotator: method __init__ (line 68) | def __init__(self, im, line_width=None, font_size=None, font='Arial.tt... method box_label (line 81) | def box_label(self, box, label='', color=(128, 128, 128), txt_color=(2... method masks (line 112) | def masks(self, masks, colors, im_gpu=None, alpha=0.5): method rectangle (line 158) | def rectangle(self, xy, fill=None, outline=None, width=1): method text (line 162) | def text(self, xy, text, txt_color=(255, 255, 255), anchor='top'): method fromarray (line 169) | def fromarray(self, im): method result (line 174) | def result(self): function feature_visualization (line 179) | def feature_visualization(x, module_type, stage, n=32, save_dir=Path('ru... function hist2d (line 207) | def hist2d(x, y, n=100): function butter_lowpass_filtfilt (line 216) | def butter_lowpass_filtfilt(data, cutoff=1500, fs=50000, order=5): function output_to_target (line 229) | def output_to_target(output, max_det=300): function plot_images (line 240) | def plot_images(images, targets, paths=None, fname='images.jpg', names=N... function plot_lr_scheduler (line 304) | def plot_lr_scheduler(optimizer, scheduler, epochs=300, save_dir=''): function plot_val_txt (line 321) | def plot_val_txt(): # from utils.plots import *; plot_val() function plot_targets_txt (line 338) | def plot_targets_txt(): # from utils.plots import *; plot_targets_txt() function plot_val_study (line 351) | def plot_val_study(file='', dir='', x=None): # from utils.plots import ... function plot_labels (line 397) | def plot_labels(labels, names=(), save_dir=Path('')): function imshow_cls (line 442) | def imshow_cls(im, labels=None, pred=None, names=None, nmax=25, verbose=... function plot_evolve (line 471) | def plot_evolve(evolve_csv='path/to/evolve.csv'): # from utils.plots im... function plot_results (line 498) | def plot_results(file='path/to/results.csv', dir=''): function profile_idetection (line 524) | def profile_idetection(start=0, stop=0, labels=(), save_dir=''): function save_one_box (line 555) | def save_one_box(xyxy, im, file=Path('im.jpg'), gain=1.02, pad=10, squar... FILE: asone/detectors/yolov9/yolov9/utils/segment/augmentations.py function mixup (line 11) | def mixup(im, labels, segments, im2, labels2, segments2): function random_perspective (line 20) | def random_perspective(im, FILE: asone/detectors/yolov9/yolov9/utils/segment/dataloaders.py function create_dataloader (line 18) | def create_dataloader(path, class LoadImagesAndLabelsAndMasks (line 78) | class LoadImagesAndLabelsAndMasks(LoadImagesAndLabels): # for training/... method __init__ (line 80) | def __init__( method __getitem__ (line 103) | def __getitem__(self, index): method load_mosaic (line 204) | def load_mosaic(self, index): method collate_fn (line 263) | def collate_fn(batch): function polygon2mask (line 271) | def polygon2mask(img_size, polygons, color=1, downsample_ratio=1): function polygons2masks (line 291) | def polygons2masks(img_size, polygons, color, downsample_ratio=1): function polygons2masks_overlap (line 306) | def polygons2masks_overlap(img_size, segments, downsample_ratio=1): FILE: asone/detectors/yolov9/yolov9/utils/segment/general.py function crop_mask (line 7) | def crop_mask(masks, boxes): function process_mask_upsample (line 25) | def process_mask_upsample(protos, masks_in, bboxes, shape): function process_mask (line 43) | def process_mask(protos, masks_in, bboxes, shape, upsample=False): function scale_image (line 70) | def scale_image(im1_shape, masks, im0_shape, ratio_pad=None): function mask_iou (line 98) | def mask_iou(mask1, mask2, eps=1e-7): function masks_iou (line 111) | def masks_iou(mask1, mask2, eps=1e-7): function masks2segments (line 124) | def masks2segments(masks, strategy='largest'): FILE: asone/detectors/yolov9/yolov9/utils/segment/loss.py class ComputeLoss (line 12) | class ComputeLoss: method __init__ (line 14) | def __init__(self, model, autobalance=False, overlap=False): method __call__ (line 44) | def __call__(self, preds, targets, masks): # predictions, targets, model method single_mask_loss (line 112) | def single_mask_loss(self, gt_mask, pred, proto, xyxy, area): method build_targets (line 118) | def build_targets(self, p, targets): FILE: asone/detectors/yolov9/yolov9/utils/segment/loss_tal.py function smooth_BCE (line 17) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class VarifocalLoss (line 22) | class VarifocalLoss(nn.Module): method __init__ (line 24) | def __init__(self): method forward (line 27) | def forward(self, pred_score, gt_score, label, alpha=0.75, gamma=2.0): class FocalLoss (line 35) | class FocalLoss(nn.Module): method __init__ (line 37) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 45) | def forward(self, pred, true): class BboxLoss (line 65) | class BboxLoss(nn.Module): method __init__ (line 66) | def __init__(self, reg_max, use_dfl=False): method forward (line 71) | def forward(self, pred_dist, pred_bboxes, anchor_points, target_bboxes... method _df_loss (line 97) | def _df_loss(self, pred_dist, target): class ComputeLoss (line 109) | class ComputeLoss: method __init__ (line 111) | def __init__(self, model, use_dfl=True, overlap=True): method preprocess (line 147) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 162) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 170) | def __call__(self, p, targets, masks, img=None, epoch=0): method single_mask_loss (line 246) | def single_mask_loss(self, gt_mask, pred, proto, xyxy, area): FILE: asone/detectors/yolov9/yolov9/utils/segment/loss_tal_dual.py function smooth_BCE (line 17) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class VarifocalLoss (line 22) | class VarifocalLoss(nn.Module): method __init__ (line 24) | def __init__(self): method forward (line 27) | def forward(self, pred_score, gt_score, label, alpha=0.75, gamma=2.0): class FocalLoss (line 35) | class FocalLoss(nn.Module): method __init__ (line 37) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 45) | def forward(self, pred, true): class BboxLoss (line 65) | class BboxLoss(nn.Module): method __init__ (line 66) | def __init__(self, reg_max, use_dfl=False): method forward (line 71) | def forward(self, pred_dist, pred_bboxes, anchor_points, target_bboxes... method _df_loss (line 97) | def _df_loss(self, pred_dist, target): class ComputeLoss (line 109) | class ComputeLoss: method __init__ (line 111) | def __init__(self, model, use_dfl=True, overlap=True): method preprocess (line 152) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 167) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 175) | def __call__(self, p, targets, masks, img=None, epoch=0): method single_mask_loss (line 311) | def single_mask_loss(self, gt_mask, pred, proto, xyxy, area): class ComputeLossLH (line 326) | class ComputeLossLH: method __init__ (line 328) | def __init__(self, model, use_dfl=True, overlap=True): method preprocess (line 364) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 379) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 387) | def __call__(self, p, targets, masks, img=None, epoch=0): method single_mask_loss (line 513) | def single_mask_loss(self, gt_mask, pred, proto, xyxy, area): class ComputeLossLH0 (line 528) | class ComputeLossLH0: method __init__ (line 530) | def __init__(self, model, use_dfl=True, overlap=True): method preprocess (line 566) | def preprocess(self, targets, batch_size, scale_tensor): method bbox_decode (line 581) | def bbox_decode(self, anchor_points, pred_dist): method __call__ (line 589) | def __call__(self, p, targets, masks, img=None, epoch=0): method single_mask_loss (line 715) | def single_mask_loss(self, gt_mask, pred, proto, xyxy, area): FILE: asone/detectors/yolov9/yolov9/utils/segment/metrics.py function fitness (line 6) | def fitness(x): function ap_per_class_box_and_mask (line 12) | def ap_per_class_box_and_mask( class Metric (line 61) | class Metric: method __init__ (line 63) | def __init__(self) -> None: method ap50 (line 71) | def ap50(self): method ap (line 79) | def ap(self): method mp (line 87) | def mp(self): method mr (line 95) | def mr(self): method map50 (line 103) | def map50(self): method map (line 111) | def map(self): method mean_results (line 118) | def mean_results(self): method class_result (line 122) | def class_result(self, i): method get_maps (line 126) | def get_maps(self, nc): method update (line 132) | def update(self, results): class Metrics (line 145) | class Metrics: method __init__ (line 148) | def __init__(self) -> None: method update (line 152) | def update(self, results): method mean_results (line 160) | def mean_results(self): method class_result (line 163) | def class_result(self, i): method get_maps (line 166) | def get_maps(self, nc): method ap_class_index (line 170) | def ap_class_index(self): FILE: asone/detectors/yolov9/yolov9/utils/segment/plots.py function plot_images_and_masks (line 17) | def plot_images_and_masks(images, targets, masks, paths=None, fname='ima... function plot_results_with_masks (line 111) | def plot_results_with_masks(file="path/to/results.csv", dir="", best=True): FILE: asone/detectors/yolov9/yolov9/utils/segment/tal/anchor_generator.py function make_anchors (line 8) | def make_anchors(feats, strides, grid_cell_offset=0.5): function dist2bbox (line 23) | def dist2bbox(distance, anchor_points, xywh=True, dim=-1): function bbox2dist (line 35) | def bbox2dist(anchor_points, bbox, reg_max): FILE: asone/detectors/yolov9/yolov9/utils/segment/tal/assigner.py function select_candidates_in_gts (line 8) | def select_candidates_in_gts(xy_centers, gt_bboxes, eps=1e-9): function select_highest_overlaps (line 25) | def select_highest_overlaps(mask_pos, overlaps, n_max_boxes): class TaskAlignedAssigner (line 51) | class TaskAlignedAssigner(nn.Module): method __init__ (line 52) | def __init__(self, topk=13, num_classes=80, alpha=1.0, beta=6.0, eps=1... method forward (line 62) | def forward(self, pd_scores, pd_bboxes, anc_points, gt_labels, gt_bbox... method get_pos_mask (line 107) | def get_pos_mask(self, pd_scores, pd_bboxes, gt_labels, gt_bboxes, anc... method get_box_metrics (line 121) | def get_box_metrics(self, pd_scores, pd_bboxes, gt_labels, gt_bboxes): method select_topk_candidates (line 134) | def select_topk_candidates(self, metrics, largest=True, topk_mask=None): method get_targets (line 157) | def get_targets(self, gt_labels, gt_bboxes, target_gt_idx, fg_mask): FILE: asone/detectors/yolov9/yolov9/utils/tal/anchor_generator.py function make_anchors (line 8) | def make_anchors(feats, strides, grid_cell_offset=0.5): function dist2bbox (line 23) | def dist2bbox(distance, anchor_points, xywh=True, dim=-1): function bbox2dist (line 35) | def bbox2dist(anchor_points, bbox, reg_max): FILE: asone/detectors/yolov9/yolov9/utils/tal/assigner.py function select_candidates_in_gts (line 8) | def select_candidates_in_gts(xy_centers, gt_bboxes, eps=1e-9): function select_highest_overlaps (line 25) | def select_highest_overlaps(mask_pos, overlaps, n_max_boxes): class TaskAlignedAssigner (line 51) | class TaskAlignedAssigner(nn.Module): method __init__ (line 52) | def __init__(self, topk=13, num_classes=80, alpha=1.0, beta=6.0, eps=1... method forward (line 62) | def forward(self, pd_scores, pd_bboxes, anc_points, gt_labels, gt_bbox... method get_pos_mask (line 106) | def get_pos_mask(self, pd_scores, pd_bboxes, gt_labels, gt_bboxes, anc... method get_box_metrics (line 120) | def get_box_metrics(self, pd_scores, pd_bboxes, gt_labels, gt_bboxes): method select_topk_candidates (line 133) | def select_topk_candidates(self, metrics, largest=True, topk_mask=None): method get_targets (line 156) | def get_targets(self, gt_labels, gt_bboxes, target_gt_idx, fg_mask): FILE: asone/detectors/yolov9/yolov9/utils/torch_utils.py function smart_inference_mode (line 34) | def smart_inference_mode(torch_1_9=check_version(torch.__version__, '1.9... function smartCrossEntropyLoss (line 42) | def smartCrossEntropyLoss(label_smoothing=0.0): function smart_DDP (line 51) | def smart_DDP(model): function reshape_classifier_output (line 62) | def reshape_classifier_output(model, n=1000): function torch_distributed_zero_first (line 85) | def torch_distributed_zero_first(local_rank: int): function device_count (line 94) | def device_count(): function select_device (line 104) | def select_device(device='', batch_size=0, newline=True): function time_sync (line 140) | def time_sync(): function profile (line 147) | def profile(input, ops, n=10, device=None): function is_parallel (line 198) | def is_parallel(model): function de_parallel (line 203) | def de_parallel(model): function initialize_weights (line 208) | def initialize_weights(model): function find_modules (line 220) | def find_modules(model, mclass=nn.Conv2d): function sparsity (line 225) | def sparsity(model): function prune (line 234) | def prune(model, amount=0.3): function fuse_conv_and_bn (line 244) | def fuse_conv_and_bn(conv, bn): function model_info (line 268) | def model_info(model, verbose=False, imgsz=640): function scale_img (line 293) | def scale_img(img, ratio=1.0, same_shape=False, gs=32): # img(16,3,256,... function copy_attr (line 305) | def copy_attr(a, b, include=(), exclude=()): function smart_optimizer (line 314) | def smart_optimizer(model, name='Adam', lr=0.001, momentum=0.9, decay=1e... function smart_hub_load (line 446) | def smart_hub_load(repo='ultralytics/yolov5', model='yolov5s', **kwargs): function smart_resume (line 458) | def smart_resume(ckpt, optimizer, ema=None, weights='yolov5s.pt', epochs... class EarlyStopping (line 478) | class EarlyStopping: method __init__ (line 480) | def __init__(self, patience=30): method __call__ (line 486) | def __call__(self, epoch, fitness): class ModelEMA (line 501) | class ModelEMA: method __init__ (line 507) | def __init__(self, model, decay=0.9999, tau=2000, updates=0): method update (line 515) | def update(self, model): method update_attr (line 527) | def update_attr(self, model, include=(), exclude=('process_group', 're... FILE: asone/detectors/yolov9/yolov9/utils/triton.py class TritonRemoteModel (line 7) | class TritonRemoteModel: method __init__ (line 13) | def __init__(self, url: str): method runtime (line 47) | def runtime(self): method __call__ (line 51) | def __call__(self, *args, **kwargs) -> typing.Union[torch.Tensor, typi... method _create_inputs (line 64) | def _create_inputs(self, *args, **kwargs): FILE: asone/detectors/yolov9/yolov9/utils/yolov9_utils.py function prepare_input (line 9) | def prepare_input(image, input_shape): function process_output (line 22) | def process_output(output, ori_shape, input_shape, conf_threshold, iou_t... function rescale_boxes (line 73) | def rescale_boxes(boxes, ori_shape, input_shape): function nms (line 83) | def nms(boxes, scores, iou_threshold): function compute_iou (line 105) | def compute_iou(box, boxes): function xywh2xyxy (line 126) | def xywh2xyxy(x): function non_max_suppression (line 135) | def non_max_suppression( FILE: asone/detectors/yolov9/yolov9_detector.py function xywh2xyxy (line 20) | def xywh2xyxy(x): class YOLOv9Detector (line 31) | class YOLOv9Detector: method __init__ (line 32) | def __init__(self, method load_model (line 52) | def load_model(self, use_cuda, weights, fp16=False): method detect (line 73) | def detect(self, image: list, FILE: asone/detectors/yolox/exps/yolov3.py class Exp (line 12) | class Exp(MyExp): method __init__ (line 13) | def __init__(self): method get_model (line 19) | def get_model(self, sublinear=False): FILE: asone/detectors/yolox/exps/yolox_l.py class Exp (line 10) | class Exp(MyExp): method __init__ (line 11) | def __init__(self): FILE: asone/detectors/yolox/exps/yolox_m.py class Exp (line 10) | class Exp(MyExp): method __init__ (line 11) | def __init__(self): FILE: asone/detectors/yolox/exps/yolox_nano.py class Exp (line 12) | class Exp(MyExp): method __init__ (line 13) | def __init__(self): method get_model (line 25) | def get_model(self, sublinear=False): FILE: asone/detectors/yolox/exps/yolox_s.py class Exp (line 10) | class Exp(MyExp): method __init__ (line 11) | def __init__(self): FILE: asone/detectors/yolox/exps/yolox_tiny.py class Exp (line 10) | class Exp(MyExp): method __init__ (line 11) | def __init__(self): FILE: asone/detectors/yolox/exps/yolox_x.py class Exp (line 10) | class Exp(MyExp): method __init__ (line 11) | def __init__(self): FILE: asone/detectors/yolox/yolox/core/launch.py function _find_free_port (line 24) | def _find_free_port(): function launch (line 39) | def launch( function _distributed_worker (line 101) | def _distributed_worker( FILE: asone/detectors/yolox/yolox/core/trainer.py class Trainer (line 36) | class Trainer: method __init__ (line 37) | def __init__(self, exp: Exp, args): method train (line 73) | def train(self): method train_in_epoch (line 82) | def train_in_epoch(self): method train_in_iter (line 88) | def train_in_iter(self): method train_one_iter (line 94) | def train_one_iter(self): method before_train (line 129) | def before_train(self): method after_train (line 194) | def after_train(self): method before_epoch (line 202) | def before_epoch(self): method after_epoch (line 217) | def after_epoch(self): method before_iter (line 224) | def before_iter(self): method after_iter (line 227) | def after_iter(self): method progress_in_iter (line 289) | def progress_in_iter(self): method resume_train (line 292) | def resume_train(self, model): method evaluate_and_save_model (line 327) | def evaluate_and_save_model(self): method save_ckpt (line 361) | def save_ckpt(self, ckpt_name, update_best_ckpt=False, ap=None): FILE: asone/detectors/yolox/yolox/data/data_augment.py function augment_hsv (line 21) | def augment_hsv(img, hgain=5, sgain=30, vgain=30): function get_aug_params (line 34) | def get_aug_params(value, center=0): function get_affine_matrix (line 46) | def get_affine_matrix( function apply_affine_to_bboxes (line 82) | def apply_affine_to_bboxes(targets, target_size, M, scale): function random_affine (line 114) | def random_affine( function _mirror (line 134) | def _mirror(image, boxes, prob=0.5): function preproc (line 142) | def preproc(img, input_size, swap=(2, 0, 1)): class TrainTransform (line 161) | class TrainTransform: method __init__ (line 162) | def __init__(self, max_labels=50, flip_prob=0.5, hsv_prob=1.0): method __call__ (line 167) | def __call__(self, image, targets, input_dim): class ValTransform (line 213) | class ValTransform: method __init__ (line 231) | def __init__(self, swap=(2, 0, 1), legacy=False): method __call__ (line 236) | def __call__(self, img, res, input_size): FILE: asone/detectors/yolox/yolox/data/data_prefetcher.py class DataPrefetcher (line 8) | class DataPrefetcher: method __init__ (line 16) | def __init__(self, loader): method preload (line 23) | def preload(self): method next (line 35) | def next(self): method _input_cuda_for_image (line 46) | def _input_cuda_for_image(self): method _record_stream_for_image (line 50) | def _record_stream_for_image(input): FILE: asone/detectors/yolox/yolox/data/dataloading.py function get_yolox_datadir (line 18) | def get_yolox_datadir(): class DataLoader (line 32) | class DataLoader(torchDataLoader): method __init__ (line 40) | def __init__(self, *args, **kwargs): method close_mosaic (line 88) | def close_mosaic(self): function list_collate (line 92) | def list_collate(batch): function worker_init_reset_seed (line 109) | def worker_init_reset_seed(worker_id): FILE: asone/detectors/yolox/yolox/data/datasets/coco.py function remove_useless_info (line 15) | def remove_useless_info(coco): class COCODataset (line 34) | class COCODataset(CacheDataset): method __init__ (line 39) | def __init__( method __len__ (line 86) | def __len__(self): method _load_coco_annotations (line 89) | def _load_coco_annotations(self): method load_anno_from_ids (line 92) | def load_anno_from_ids(self, id_): method load_anno (line 130) | def load_anno(self, index): method load_resized_img (line 133) | def load_resized_img(self, index): method load_image (line 143) | def load_image(self, index): method read_img (line 154) | def read_img(self, index): method pull_item (line 157) | def pull_item(self, index): method __getitem__ (line 165) | def __getitem__(self, index): FILE: asone/detectors/yolox/yolox/data/datasets/datasets_wrapper.py class ConcatDataset (line 22) | class ConcatDataset(torchConcatDataset): method __init__ (line 23) | def __init__(self, datasets): method pull_item (line 29) | def pull_item(self, idx): class MixConcatDataset (line 44) | class MixConcatDataset(torchConcatDataset): method __init__ (line 45) | def __init__(self, datasets): method __getitem__ (line 51) | def __getitem__(self, index): class Dataset (line 72) | class Dataset(torchDataset): method __init__ (line 80) | def __init__(self, input_dimension, mosaic=True): method input_dim (line 86) | def input_dim(self): method mosaic_getitem (line 100) | def mosaic_getitem(getitem_fn): class CacheDataset (line 127) | class CacheDataset(Dataset, metaclass=ABCMeta): method __init__ (line 147) | def __init__( method __del__ (line 176) | def __del__(self): method read_img (line 181) | def read_img(self, index): method cache_images (line 190) | def cache_images( method cal_cache_occupy (line 262) | def cal_cache_occupy(self, num_imgs): function cache_read_img (line 272) | def cache_read_img(use_cache=True): FILE: asone/detectors/yolox/yolox/data/datasets/mosaicdetection.py function get_mosaic_coordinate (line 16) | def get_mosaic_coordinate(mosaic_image, mosaic_index, xc, yc, w, h, inpu... class MosaicDetection (line 37) | class MosaicDetection(Dataset): method __init__ (line 40) | def __init__( method __len__ (line 75) | def __len__(self): method __getitem__ (line 79) | def __getitem__(self, idx): method mixup (line 162) | def mixup(self, origin_img, origin_labels, input_dim): FILE: asone/detectors/yolox/yolox/data/datasets/voc.py class AnnotationTransform (line 23) | class AnnotationTransform(object): method __init__ (line 37) | def __init__(self, class_to_ind=None, keep_difficult=True): method __call__ (line 43) | def __call__(self, target): class VOCDetection (line 82) | class VOCDetection(CacheDataset): method __init__ (line 101) | def __init__( method __len__ (line 151) | def __len__(self): method _load_coco_annotations (line 154) | def _load_coco_annotations(self): method load_anno_from_ids (line 157) | def load_anno_from_ids(self, index): method load_anno (line 171) | def load_anno(self, index): method load_resized_img (line 174) | def load_resized_img(self, index): method load_image (line 185) | def load_image(self, index): method read_img (line 193) | def read_img(self, index): method pull_item (line 196) | def pull_item(self, index): method __getitem__ (line 213) | def __getitem__(self, index): method evaluate_detections (line 221) | def evaluate_detections(self, all_boxes, output_dir=None): method _get_voc_results_file_template (line 245) | def _get_voc_results_file_template(self): method _write_voc_results_file (line 253) | def _write_voc_results_file(self, all_boxes): method _do_python_eval (line 278) | def _do_python_eval(self, output_dir="output", iou=0.5): FILE: asone/detectors/yolox/yolox/data/samplers.py class YoloBatchSampler (line 14) | class YoloBatchSampler(torchBatchSampler): method __init__ (line 21) | def __init__(self, *args, mosaic=True, **kwargs): method __iter__ (line 25) | def __iter__(self): class InfiniteSampler (line 30) | class InfiniteSampler(Sampler): method __init__ (line 41) | def __init__( method __iter__ (line 69) | def __iter__(self): method _infinite_indices (line 75) | def _infinite_indices(self): method __len__ (line 84) | def __len__(self): FILE: asone/detectors/yolox/yolox/evaluators/coco_evaluator.py function per_class_AR_table (line 31) | def per_class_AR_table(coco_eval, class_names=COCO_CLASSES, headers=["cl... function per_class_AP_table (line 54) | def per_class_AP_table(coco_eval, class_names=COCO_CLASSES, headers=["cl... class COCOEvaluator (line 79) | class COCOEvaluator: method __init__ (line 85) | def __init__( method evaluate (line 116) | def evaluate( method convert_to_coco_format (line 207) | def convert_to_coco_format(self, outputs, info_imgs, ids, return_outpu... method evaluate_prediction (line 255) | def evaluate_prediction(self, data_dict, statistics): FILE: asone/detectors/yolox/yolox/evaluators/voc_eval.py function parse_rec (line 14) | def parse_rec(filename): function voc_ap (line 36) | def voc_ap(rec, prec, use_07_metric=False): function voc_eval (line 70) | def voc_eval( FILE: asone/detectors/yolox/yolox/evaluators/voc_evaluator.py class VOCEvaluator (line 19) | class VOCEvaluator: method __init__ (line 24) | def __init__(self, dataloader, img_size, confthre, nmsthre, num_classes): method evaluate (line 41) | def evaluate( method convert_to_voc_format (line 120) | def convert_to_voc_format(self, outputs, info_imgs, ids): method evaluate_prediction (line 140) | def evaluate_prediction(self, data_dict, statistics): FILE: asone/detectors/yolox/yolox/exp/base_exp.py class BaseExp (line 18) | class BaseExp(metaclass=ABCMeta): method __init__ (line 21) | def __init__(self): method get_model (line 28) | def get_model(self) -> Module: method get_data_loader (line 32) | def get_data_loader( method get_optimizer (line 38) | def get_optimizer(self, batch_size: int) -> torch.optim.Optimizer: method get_lr_scheduler (line 42) | def get_lr_scheduler( method get_evaluator (line 48) | def get_evaluator(self): method eval (line 52) | def eval(self, model, evaluator, weights): method __repr__ (line 55) | def __repr__(self): method merge (line 64) | def merge(self, cfg_list): FILE: asone/detectors/yolox/yolox/exp/build.py function get_exp_by_file (line 10) | def get_exp_by_file(exp_file): function get_exp_by_name (line 23) | def get_exp_by_name(exp_name): function get_exp (line 30) | def get_exp(exp_file=None, exp_name=None): FILE: asone/detectors/yolox/yolox/exp/default/__init__.py class _ExpFinder (line 17) | class _ExpFinder(importlib.abc.MetaPathFinder): method find_spec (line 19) | def find_spec(self, name, path, target=None): FILE: asone/detectors/yolox/yolox/exp/yolox_base.py class Exp (line 15) | class Exp(BaseExp): method __init__ (line 16) | def __init__(self): method get_model (line 110) | def get_model(self): method get_data_loader (line 130) | def get_data_loader(self, batch_size, is_distributed, no_aug=False, ca... method random_resize (line 197) | def random_resize(self, data_loader, epoch, rank, is_distributed): method preprocess (line 218) | def preprocess(self, inputs, targets, tsize): method get_optimizer (line 229) | def get_optimizer(self, batch_size): method get_lr_scheduler (line 257) | def get_lr_scheduler(self, lr, iters_per_epoch): method get_eval_loader (line 272) | def get_eval_loader(self, batch_size, is_distributed, testdev=False, l... method get_evaluator (line 301) | def get_evaluator(self, batch_size, is_distributed, testdev=False, leg... method get_trainer (line 315) | def get_trainer(self, args): method eval (line 321) | def eval(self, model, evaluator, is_distributed, half=False, return_ou... FILE: asone/detectors/yolox/yolox/models/build.py function create_yolox_model (line 32) | def create_yolox_model(name: str, pretrained: bool = True, num_classes: ... function yolox_nano (line 82) | def yolox_nano(pretrained: bool = True, num_classes: int = 80, device: s... function yolox_tiny (line 86) | def yolox_tiny(pretrained: bool = True, num_classes: int = 80, device: s... function yolox_s (line 90) | def yolox_s(pretrained: bool = True, num_classes: int = 80, device: str ... function yolox_m (line 94) | def yolox_m(pretrained: bool = True, num_classes: int = 80, device: str ... function yolox_l (line 98) | def yolox_l(pretrained: bool = True, num_classes: int = 80, device: str ... function yolox_x (line 102) | def yolox_x(pretrained: bool = True, num_classes: int = 80, device: str ... function yolov3 (line 106) | def yolov3(pretrained: bool = True, num_classes: int = 80, device: str =... function yolox_custom (line 110) | def yolox_custom(ckpt_path: str = None, exp_path: str = None, device: st... FILE: asone/detectors/yolox/yolox/models/darknet.py class Darknet (line 10) | class Darknet(nn.Module): method __init__ (line 14) | def __init__( method make_group_layer (line 59) | def make_group_layer(self, in_channels: int, num_blocks: int, stride: ... method make_spp_block (line 66) | def make_spp_block(self, filters_list, in_filters): method forward (line 82) | def forward(self, x): class CSPDarknet (line 97) | class CSPDarknet(nn.Module): method __init__ (line 98) | def __init__( method forward (line 167) | def forward(self, x): FILE: asone/detectors/yolox/yolox/models/losses.py class IOUloss (line 9) | class IOUloss(nn.Module): method __init__ (line 10) | def __init__(self, reduction="none", loss_type="iou"): method forward (line 15) | def forward(self, pred, target): FILE: asone/detectors/yolox/yolox/models/network_blocks.py class SiLU (line 9) | class SiLU(nn.Module): method forward (line 13) | def forward(x): function get_activation (line 17) | def get_activation(name="silu", inplace=True): class BaseConv (line 29) | class BaseConv(nn.Module): method __init__ (line 32) | def __init__( method forward (line 50) | def forward(self, x): method fuseforward (line 53) | def fuseforward(self, x): class DWConv (line 57) | class DWConv(nn.Module): method __init__ (line 60) | def __init__(self, in_channels, out_channels, ksize, stride=1, act="si... method forward (line 74) | def forward(self, x): class Bottleneck (line 79) | class Bottleneck(nn.Module): method __init__ (line 81) | def __init__( method forward (line 97) | def forward(self, x): class ResLayer (line 104) | class ResLayer(nn.Module): method __init__ (line 107) | def __init__(self, in_channels: int): method forward (line 117) | def forward(self, x): class SPPBottleneck (line 122) | class SPPBottleneck(nn.Module): method __init__ (line 125) | def __init__( method forward (line 140) | def forward(self, x): class CSPLayer (line 147) | class CSPLayer(nn.Module): method __init__ (line 150) | def __init__( method forward (line 180) | def forward(self, x): class Focus (line 188) | class Focus(nn.Module): method __init__ (line 191) | def __init__(self, in_channels, out_channels, ksize=1, stride=1, act="... method forward (line 195) | def forward(self, x): FILE: asone/detectors/yolox/yolox/models/yolo_fpn.py class YOLOFPN (line 12) | class YOLOFPN(nn.Module): method __init__ (line 17) | def __init__( method _make_cbl (line 38) | def _make_cbl(self, _in, _out, ks): method _make_embedding (line 41) | def _make_embedding(self, filters_list, in_filters): method load_pretrained_model (line 53) | def load_pretrained_model(self, filename="./weights/darknet53.mix.pth"): method forward (line 59) | def forward(self, inputs): FILE: asone/detectors/yolox/yolox/models/yolo_head.py class YOLOXHead (line 18) | class YOLOXHead(nn.Module): method __init__ (line 19) | def __init__( method initialize_biases (line 132) | def initialize_biases(self, prior_prob): method forward (line 143) | def forward(self, xin, labels=None, imgs=None): method get_output_and_grid (line 216) | def get_output_and_grid(self, output, k, stride, dtype): method decode_outputs (line 236) | def decode_outputs(self, outputs, dtype): method get_losses (line 253) | def get_losses( method get_l1_target (line 421) | def get_l1_target(self, l1_target, gt, stride, x_shifts, y_shifts, eps... method get_assignments (line 429) | def get_assignments( method get_in_boxes_info (line 526) | def get_in_boxes_info( method dynamic_k_matching (line 611) | def dynamic_k_matching(self, cost, pair_wise_ious, gt_classes, num_gt,... FILE: asone/detectors/yolox/yolox/models/yolo_pafpn.py class YOLOPAFPN (line 12) | class YOLOPAFPN(nn.Module): method __init__ (line 17) | def __init__( method forward (line 83) | def forward(self, input): FILE: asone/detectors/yolox/yolox/models/yolox.py class YOLOX (line 11) | class YOLOX(nn.Module): method __init__ (line 18) | def __init__(self, backbone=None, head=None): method forward (line 28) | def forward(self, x, targets=None): FILE: asone/detectors/yolox/yolox/utils/allreduce_norm.py function get_async_norm_states (line 32) | def get_async_norm_states(module): function pyobj2tensor (line 41) | def pyobj2tensor(pyobj, device="cuda"): function tensor2pyobj (line 47) | def tensor2pyobj(tensor): function _get_reduce_op (line 52) | def _get_reduce_op(op_name): function all_reduce (line 59) | def all_reduce(py_dict, op="sum", group=None): function all_reduce_norm (line 97) | def all_reduce_norm(module): FILE: asone/detectors/yolox/yolox/utils/boxes.py function filter_box (line 21) | def filter_box(output, scale_range): function postprocess (line 32) | def postprocess(prediction, num_classes, conf_thre=0.7, nms_thre=0.45, c... function bboxes_iou (line 80) | def bboxes_iou(bboxes_a, bboxes_b, xyxy=True): function matrix_iou (line 106) | def matrix_iou(a, b): function adjust_box_anns (line 119) | def adjust_box_anns(bbox, scale_ratio, padw, padh, w_max, h_max): function xyxy2xywh (line 125) | def xyxy2xywh(bboxes): function xyxy2cxcywh (line 131) | def xyxy2cxcywh(bboxes): FILE: asone/detectors/yolox/yolox/utils/checkpoint.py function load_ckpt (line 11) | def load_ckpt(model, ckpt): function save_checkpoint (line 36) | def save_checkpoint(state, is_best, save_dir, model_name=""): FILE: asone/detectors/yolox/yolox/utils/compat.py function meshgrid (line 11) | def meshgrid(*tensors): FILE: asone/detectors/yolox/yolox/utils/demo_utils.py function mkdir (line 12) | def mkdir(path): function nms (line 17) | def nms(boxes, scores, nms_thr): function multiclass_nms (line 47) | def multiclass_nms(boxes, scores, nms_thr, score_thr, class_agnostic=True): function multiclass_nms_class_aware (line 56) | def multiclass_nms_class_aware(boxes, scores, nms_thr, score_thr): function multiclass_nms_class_agnostic (line 80) | def multiclass_nms_class_agnostic(boxes, scores, nms_thr, score_thr): function demo_postprocess (line 99) | def demo_postprocess(outputs, img_size, p6=False): FILE: asone/detectors/yolox/yolox/utils/dist.py function get_num_devices (line 41) | def get_num_devices(): function wait_for_the_master (line 52) | def wait_for_the_master(local_rank: int = None): function synchronize (line 75) | def synchronize(): function get_world_size (line 89) | def get_world_size() -> int: function get_rank (line 97) | def get_rank() -> int: function get_local_rank (line 105) | def get_local_rank() -> int: function get_local_size (line 120) | def get_local_size() -> int: function is_main_process (line 132) | def is_main_process() -> bool: function _get_global_gloo_group (line 137) | def _get_global_gloo_group(): function _serialize_to_tensor (line 148) | def _serialize_to_tensor(data, group): function _pad_to_largest_tensor (line 165) | def _pad_to_largest_tensor(tensor, group): function all_gather (line 195) | def all_gather(data, group=None): function gather (line 233) | def gather(data, dst=0, group=None): function shared_random_seed (line 277) | def shared_random_seed(): function time_synchronized (line 290) | def time_synchronized(): FILE: asone/detectors/yolox/yolox/utils/ema.py function is_parallel (line 13) | def is_parallel(model): class ModelEMA (line 22) | class ModelEMA: method __init__ (line 33) | def __init__(self, model, decay=0.9999, updates=0): method update (line 48) | def update(self, model): FILE: asone/detectors/yolox/yolox/utils/logger.py function get_caller_name (line 17) | def get_caller_name(depth=0): class StreamToLoguru (line 34) | class StreamToLoguru: method __init__ (line 39) | def __init__(self, level="INFO", caller_names=("apex", "pycocotools")): method write (line 50) | def write(self, buf): method flush (line 60) | def flush(self): method isatty (line 63) | def isatty(self): function redirect_sys_output (line 72) | def redirect_sys_output(log_level="INFO"): function setup_logger (line 78) | def setup_logger(save_dir, distributed_rank=0, filename="log.txt", mode=... class WandbLogger (line 113) | class WandbLogger(object): method __init__ (line 125) | def __init__(self, method run (line 213) | def run(self): method _log_validation_set (line 227) | def _log_validation_set(self, val_dataset): method log_metrics (line 253) | def log_metrics(self, metrics, step=None): method log_images (line 270) | def log_images(self, predictions): method save_checkpoint (line 335) | def save_checkpoint(self, save_dir, model_name, is_best, metadata=None): method finish (line 370) | def finish(self): method initialize_wandb_logger (line 374) | def initialize_wandb_logger(cls, args, exp, val_dataset): FILE: asone/detectors/yolox/yolox/utils/lr_scheduler.py class LRScheduler (line 9) | class LRScheduler: method __init__ (line 10) | def __init__(self, name, lr, iters_per_epoch, total_epochs, **kwargs): method update_lr (line 33) | def update_lr(self, iters): method _get_lr_func (line 36) | def _get_lr_func(self, name): function cos_lr (line 97) | def cos_lr(lr, total_iters, iters): function warm_cos_lr (line 103) | def warm_cos_lr(lr, total_iters, warmup_total_iters, warmup_lr_start, it... function yolox_warm_cos_lr (line 121) | def yolox_warm_cos_lr( function yolox_semi_warm_cos_lr (line 151) | def yolox_semi_warm_cos_lr( function multistep_lr (line 201) | def multistep_lr(lr, milestones, gamma, iters): FILE: asone/detectors/yolox/yolox/utils/metric.py function get_total_and_free_memory_in_Mb (line 22) | def get_total_and_free_memory_in_Mb(cuda_device): function occupy_mem (line 34) | def occupy_mem(cuda_device, mem_ratio=0.9): function gpu_mem_usage (line 46) | def gpu_mem_usage(): class AverageMeter (line 54) | class AverageMeter: method __init__ (line 59) | def __init__(self, window_size=50): method update (line 64) | def update(self, value): method median (line 70) | def median(self): method avg (line 75) | def avg(self): method global_avg (line 81) | def global_avg(self): method latest (line 85) | def latest(self): method total (line 89) | def total(self): method reset (line 92) | def reset(self): method clear (line 97) | def clear(self): class MeterBuffer (line 101) | class MeterBuffer(defaultdict): method __init__ (line 104) | def __init__(self, window_size=20): method reset (line 108) | def reset(self): method get_filtered_meter (line 112) | def get_filtered_meter(self, filter_key="time"): method update (line 115) | def update(self, values=None, **kwargs): method clear_meters (line 124) | def clear_meters(self): FILE: asone/detectors/yolox/yolox/utils/model_utils.py function get_model_info (line 22) | def get_model_info(model: nn.Module, tsize: Sequence[int]) -> str: function fuse_conv_and_bn (line 35) | def fuse_conv_and_bn(conv: nn.Conv2d, bn: nn.BatchNorm2d) -> nn.Conv2d: function fuse_model (line 80) | def fuse_model(model: nn.Module) -> nn.Module: function replace_module (line 99) | def replace_module(module, replaced_module_type, new_module_type, replac... function freeze_module (line 131) | def freeze_module(module: nn.Module, name=None) -> nn.Module: function adjust_status (line 160) | def adjust_status(module: nn.Module, training: bool = False) -> nn.Module: FILE: asone/detectors/yolox/yolox/utils/setup_env.py function configure_nccl (line 16) | def configure_nccl(): function configure_omp (line 28) | def configure_omp(num_threads=1): function configure_module (line 51) | def configure_module(ulimit_value=8192): FILE: asone/detectors/yolox/yolox/utils/visualize.py function vis (line 11) | def vis(img, boxes, scores, cls_ids, conf=0.5, class_names=None): FILE: asone/detectors/yolox/yolox_detector.py class YOLOxDetector (line 18) | class YOLOxDetector: method __init__ (line 19) | def __init__(self, method load_onnx_model (line 47) | def load_onnx_model(self, use_cuda, weights): method load_torch_model (line 56) | def load_torch_model(self, weights, method detect (line 83) | def detect(self, FILE: asone/detectors/yolox/yolox_utils.py function preprocess (line 4) | def preprocess(img, input_size, swap=(2, 0, 1)): function nms (line 22) | def nms(boxes, scores, nms_thr): function multiclass_nms (line 52) | def multiclass_nms(boxes, scores, nms_thr, score_thr, class_agnostic=True): function multiclass_nms_class_aware (line 61) | def multiclass_nms_class_aware(boxes, scores, nms_thr, score_thr): function multiclass_nms_class_agnostic (line 85) | def multiclass_nms_class_agnostic(boxes, scores, nms_thr, score_thr): function demo_postprocess (line 103) | def demo_postprocess(outputs, img_size, p6=False): FILE: asone/pose_estimator.py class PoseEstimator (line 14) | class PoseEstimator: method __init__ (line 15) | def __init__(self, estimator_flag, weights: str=None, use_cuda=True): method get_estimator (line 26) | def get_estimator(self, estimator_flag: int, weights: str, use_cuda: b... method estimate_image (line 36) | def estimate_image(self, frame): method estimate_video (line 41) | def estimate_video(self, video_path, save=True, conf_thresh=0.5, displ... method video_estimator (line 101) | def video_estimator(self, video_path, save=True, conf_thresh=0.5, disp... method format_output (line 158) | def format_output(self, bbox_details, frame_details): FILE: asone/pose_estimators/yolov7_pose/models/common.py function autopad (line 23) | def autopad(k, p=None): # kernel, padding class MP (line 30) | class MP(nn.Module): method __init__ (line 31) | def __init__(self, k=2): method forward (line 35) | def forward(self, x): class SP (line 39) | class SP(nn.Module): method __init__ (line 40) | def __init__(self, k=3, s=1): method forward (line 44) | def forward(self, x): class ReOrg (line 48) | class ReOrg(nn.Module): method __init__ (line 49) | def __init__(self): method forward (line 52) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class Concat (line 56) | class Concat(nn.Module): method __init__ (line 57) | def __init__(self, dimension=1): method forward (line 61) | def forward(self, x): class Chuncat (line 65) | class Chuncat(nn.Module): method __init__ (line 66) | def __init__(self, dimension=1): method forward (line 70) | def forward(self, x): class Shortcut (line 80) | class Shortcut(nn.Module): method __init__ (line 81) | def __init__(self, dimension=0): method forward (line 85) | def forward(self, x): class Foldcut (line 89) | class Foldcut(nn.Module): method __init__ (line 90) | def __init__(self, dimension=0): method forward (line 94) | def forward(self, x): class Conv (line 99) | class Conv(nn.Module): method __init__ (line 101) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 107) | def forward(self, x): method fuseforward (line 110) | def fuseforward(self, x): class RobustConv (line 114) | class RobustConv(nn.Module): method __init__ (line 116) | def __init__(self, c1, c2, k=7, s=1, p=None, g=1, act=True, layer_scal... method forward (line 122) | def forward(self, x): class RobustConv2 (line 130) | class RobustConv2(nn.Module): method __init__ (line 132) | def __init__(self, c1, c2, k=7, s=4, p=None, g=1, act=True, layer_scal... method forward (line 140) | def forward(self, x): function DWConv (line 147) | def DWConv(c1, c2, k=1, s=1, act=True): class GhostConv (line 152) | class GhostConv(nn.Module): method __init__ (line 154) | def __init__(self, c1, c2, k=1, s=1, g=1, act=True): # ch_in, ch_out,... method forward (line 160) | def forward(self, x): class Stem (line 165) | class Stem(nn.Module): method __init__ (line 167) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 176) | def forward(self, x): class DownC (line 181) | class DownC(nn.Module): method __init__ (line 183) | def __init__(self, c1, c2, n=1, k=2): method forward (line 191) | def forward(self, x): class SPP (line 195) | class SPP(nn.Module): method __init__ (line 197) | def __init__(self, c1, c2, k=(5, 9, 13)): method forward (line 204) | def forward(self, x): class Bottleneck (line 209) | class Bottleneck(nn.Module): method __init__ (line 211) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 218) | def forward(self, x): class Res (line 222) | class Res(nn.Module): method __init__ (line 224) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... method forward (line 232) | def forward(self, x): class ResX (line 236) | class ResX(Res): method __init__ (line 238) | def __init__(self, c1, c2, shortcut=True, g=32, e=0.5): # ch_in, ch_o... class Ghost (line 243) | class Ghost(nn.Module): method __init__ (line 245) | def __init__(self, c1, c2, k=3, s=1): # ch_in, ch_out, kernel, stride method forward (line 254) | def forward(self, x): class SPPCSPC (line 262) | class SPPCSPC(nn.Module): method __init__ (line 264) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... method forward (line 276) | def forward(self, x): class GhostSPPCSPC (line 282) | class GhostSPPCSPC(SPPCSPC): method __init__ (line 284) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5, k=(5, 9, 1... class GhostStem (line 296) | class GhostStem(Stem): method __init__ (line 298) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... class BottleneckCSPA (line 307) | class BottleneckCSPA(nn.Module): method __init__ (line 309) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 317) | def forward(self, x): class BottleneckCSPB (line 323) | class BottleneckCSPB(nn.Module): method __init__ (line 325) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 333) | def forward(self, x): class BottleneckCSPC (line 340) | class BottleneckCSPC(nn.Module): method __init__ (line 342) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 351) | def forward(self, x): class ResCSPA (line 357) | class ResCSPA(BottleneckCSPA): method __init__ (line 359) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResCSPB (line 365) | class ResCSPB(BottleneckCSPB): method __init__ (line 367) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResCSPC (line 373) | class ResCSPC(BottleneckCSPC): method __init__ (line 375) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ResXCSPA (line 381) | class ResXCSPA(ResCSPA): method __init__ (line 383) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class ResXCSPB (line 389) | class ResXCSPB(ResCSPB): method __init__ (line 391) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class ResXCSPC (line 397) | class ResXCSPC(ResCSPC): method __init__ (line 399) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class GhostCSPA (line 405) | class GhostCSPA(BottleneckCSPA): method __init__ (line 407) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class GhostCSPB (line 413) | class GhostCSPB(BottleneckCSPB): method __init__ (line 415) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class GhostCSPC (line 421) | class GhostCSPC(BottleneckCSPC): method __init__ (line 423) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class ImplicitA (line 433) | class ImplicitA(nn.Module): method __init__ (line 434) | def __init__(self, channel, mean=0., std=.02): method forward (line 442) | def forward(self, x): class ImplicitM (line 446) | class ImplicitM(nn.Module): method __init__ (line 447) | def __init__(self, channel, mean=0., std=.02): method forward (line 455) | def forward(self, x): class RepConv (line 463) | class RepConv(nn.Module): method __init__ (line 467) | def __init__(self, c1, c2, k=3, s=1, p=None, g=1, act=True, deploy=Fal... method forward (line 498) | def forward(self, inputs): method get_equivalent_kernel_bias (line 509) | def get_equivalent_kernel_bias(self): method _pad_1x1_to_3x3_tensor (line 518) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 524) | def _fuse_bn_tensor(self, branch): method repvgg_convert (line 554) | def repvgg_convert(self): method fuse_conv_bn (line 561) | def fuse_conv_bn(self, conv, bn): method fuse_repvgg_block (line 584) | def fuse_repvgg_block(self): class RepBottleneck (line 646) | class RepBottleneck(Bottleneck): method __init__ (line 648) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... class RepBottleneckCSPA (line 654) | class RepBottleneckCSPA(BottleneckCSPA): method __init__ (line 656) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepBottleneckCSPB (line 662) | class RepBottleneckCSPB(BottleneckCSPB): method __init__ (line 664) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... class RepBottleneckCSPC (line 670) | class RepBottleneckCSPC(BottleneckCSPC): method __init__ (line 672) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepRes (line 678) | class RepRes(Res): method __init__ (line 680) | def __init__(self, c1, c2, shortcut=True, g=1, e=0.5): # ch_in, ch_ou... class RepResCSPA (line 686) | class RepResCSPA(ResCSPA): method __init__ (line 688) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepResCSPB (line 694) | class RepResCSPB(ResCSPB): method __init__ (line 696) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... class RepResCSPC (line 702) | class RepResCSPC(ResCSPC): method __init__ (line 704) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... class RepResX (line 710) | class RepResX(ResX): method __init__ (line 712) | def __init__(self, c1, c2, shortcut=True, g=32, e=0.5): # ch_in, ch_o... class RepResXCSPA (line 718) | class RepResXCSPA(ResXCSPA): method __init__ (line 720) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class RepResXCSPB (line 726) | class RepResXCSPB(ResXCSPB): method __init__ (line 728) | def __init__(self, c1, c2, n=1, shortcut=False, g=32, e=0.5): # ch_in... class RepResXCSPC (line 734) | class RepResXCSPC(ResXCSPC): method __init__ (line 736) | def __init__(self, c1, c2, n=1, shortcut=True, g=32, e=0.5): # ch_in,... class TransformerLayer (line 746) | class TransformerLayer(nn.Module): method __init__ (line 748) | def __init__(self, c, num_heads): method forward (line 757) | def forward(self, x): class TransformerBlock (line 763) | class TransformerBlock(nn.Module): method __init__ (line 765) | def __init__(self, c1, c2, num_heads, num_layers): method forward (line 774) | def forward(self, x): class Focus (line 796) | class Focus(nn.Module): method __init__ (line 798) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1, act=True): # ch_in,... method forward (line 803) | def forward(self, x): # x(b,c,w,h) -> y(b,4c,w/2,h/2) class SPPF (line 808) | class SPPF(nn.Module): method __init__ (line 810) | def __init__(self, c1, c2, k=5): # equivalent to SPP(k=(5, 9, 13)) method forward (line 817) | def forward(self, x): class Contract (line 824) | class Contract(nn.Module): method __init__ (line 826) | def __init__(self, gain=2): method forward (line 830) | def forward(self, x): class Expand (line 838) | class Expand(nn.Module): method __init__ (line 840) | def __init__(self, gain=2): method forward (line 844) | def forward(self, x): class NMS (line 852) | class NMS(nn.Module): method __init__ (line 858) | def __init__(self): method forward (line 861) | def forward(self, x): class autoShape (line 865) | class autoShape(nn.Module): method __init__ (line 871) | def __init__(self, model): method autoshape (line 875) | def autoshape(self): method forward (line 880) | def forward(self, imgs, size=640, augment=False, profile=False): class Detections (line 935) | class Detections: method __init__ (line 937) | def __init__(self, imgs, pred, files, times=None, names=None, shape=No... method display (line 953) | def display(self, pprint=False, show=False, save=False, render=False, ... method print (line 977) | def print(self): method show (line 981) | def show(self): method save (line 984) | def save(self, save_dir='runs/hub/exp'): method render (line 989) | def render(self): method pandas (line 993) | def pandas(self): method tolist (line 1003) | def tolist(self): method __len__ (line 1011) | def __len__(self): class Classify (line 1015) | class Classify(nn.Module): method __init__ (line 1017) | def __init__(self, c1, c2, k=1, s=1, p=None, g=1): # ch_in, ch_out, k... method forward (line 1023) | def forward(self, x): function transI_fusebn (line 1032) | def transI_fusebn(kernel, bn): class ConvBN (line 1038) | class ConvBN(nn.Module): method __init__ (line 1039) | def __init__(self, in_channels, out_channels, kernel_size, method forward (line 1054) | def forward(self, x): method switch_to_deploy (line 1060) | def switch_to_deploy(self): class OREPA_3x3_RepConv (line 1072) | class OREPA_3x3_RepConv(nn.Module): method __init__ (line 1074) | def __init__(self, in_channels, out_channels, kernel_size, method fre_init (line 1157) | def fre_init(self): method weight_gen (line 1170) | def weight_gen(self): method dwsc2full (line 1206) | def dwsc2full(self, weight_dw, weight_pw, groups): method forward (line 1218) | def forward(self, inputs): class RepConv_OREPA (line 1224) | class RepConv_OREPA(nn.Module): method __init__ (line 1226) | def __init__(self, c1, c2, k=3, s=1, padding=1, dilation=1, groups=1, ... method forward (line 1263) | def forward(self, inputs): method get_custom_L2 (line 1290) | def get_custom_L2(self): method get_equivalent_kernel_bias (line 1301) | def get_equivalent_kernel_bias(self): method _pad_1x1_to_3x3_tensor (line 1307) | def _pad_1x1_to_3x3_tensor(self, kernel1x1): method _fuse_bn_tensor (line 1313) | def _fuse_bn_tensor(self, branch): method switch_to_deploy (line 1345) | def switch_to_deploy(self): class WindowAttention (line 1367) | class WindowAttention(nn.Module): method __init__ (line 1369) | def __init__(self, dim, window_size, num_heads, qkv_bias=True, qk_scal... method forward (line 1403) | def forward(self, x, mask=None): class Mlp (line 1437) | class Mlp(nn.Module): method __init__ (line 1439) | def __init__(self, in_features, hidden_features=None, out_features=Non... method forward (line 1448) | def forward(self, x): function window_partition (line 1456) | def window_partition(x, window_size): function window_reverse (line 1464) | def window_reverse(windows, window_size, H, W): class SwinTransformerLayer (line 1472) | class SwinTransformerLayer(nn.Module): method __init__ (line 1474) | def __init__(self, dim, num_heads, window_size=8, shift_size=0, method create_mask (line 1499) | def create_mask(self, H, W): method forward (line 1521) | def forward(self, x): class SwinTransformerBlock (line 1584) | class SwinTransformerBlock(nn.Module): method __init__ (line 1585) | def __init__(self, c1, c2, num_heads, num_layers, window_size=8): method forward (line 1595) | def forward(self, x): class STCSPA (line 1602) | class STCSPA(nn.Module): method __init__ (line 1604) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1614) | def forward(self, x): class STCSPB (line 1620) | class STCSPB(nn.Module): method __init__ (line 1622) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 1632) | def forward(self, x): class STCSPC (line 1639) | class STCSPC(nn.Module): method __init__ (line 1641) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1652) | def forward(self, x): class WindowAttention_v2 (line 1662) | class WindowAttention_v2(nn.Module): method __init__ (line 1664) | def __init__(self, dim, window_size, num_heads, qkv_bias=True, attn_dr... method forward (line 1723) | def forward(self, x, mask=None): method extra_repr (line 1764) | def extra_repr(self) -> str: method flops (line 1768) | def flops(self, N): class Mlp_v2 (line 1781) | class Mlp_v2(nn.Module): method __init__ (line 1782) | def __init__(self, in_features, hidden_features=None, out_features=Non... method forward (line 1791) | def forward(self, x): function window_partition_v2 (line 1800) | def window_partition_v2(x, window_size): function window_reverse_v2 (line 1808) | def window_reverse_v2(windows, window_size, H, W): class SwinTransformerLayer_v2 (line 1816) | class SwinTransformerLayer_v2(nn.Module): method __init__ (line 1818) | def __init__(self, dim, num_heads, window_size=7, shift_size=0, method create_mask (line 1845) | def create_mask(self, H, W): method forward (line 1867) | def forward(self, x): method extra_repr (line 1927) | def extra_repr(self) -> str: method flops (line 1931) | def flops(self): class SwinTransformer2Block (line 1946) | class SwinTransformer2Block(nn.Module): method __init__ (line 1947) | def __init__(self, c1, c2, num_heads, num_layers, window_size=7): method forward (line 1957) | def forward(self, x): class ST2CSPA (line 1964) | class ST2CSPA(nn.Module): method __init__ (line 1966) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 1976) | def forward(self, x): class ST2CSPB (line 1982) | class ST2CSPB(nn.Module): method __init__ (line 1984) | def __init__(self, c1, c2, n=1, shortcut=False, g=1, e=0.5): # ch_in,... method forward (line 1994) | def forward(self, x): class ST2CSPC (line 2001) | class ST2CSPC(nn.Module): method __init__ (line 2003) | def __init__(self, c1, c2, n=1, shortcut=True, g=1, e=0.5): # ch_in, ... method forward (line 2014) | def forward(self, x): FILE: asone/pose_estimators/yolov7_pose/models/experimental.py class CrossConv (line 10) | class CrossConv(nn.Module): method __init__ (line 12) | def __init__(self, c1, c2, k=3, s=1, g=1, e=1.0, shortcut=False): method forward (line 20) | def forward(self, x): class Sum (line 24) | class Sum(nn.Module): method __init__ (line 26) | def __init__(self, n, weight=False): # n: number of inputs method forward (line 33) | def forward(self, x): class MixConv2d (line 45) | class MixConv2d(nn.Module): method __init__ (line 47) | def __init__(self, c1, c2, k=(1, 3), s=1, equal_ch=True): method forward (line 65) | def forward(self, x): class Ensemble (line 69) | class Ensemble(nn.ModuleList): method __init__ (line 71) | def __init__(self): method forward (line 74) | def forward(self, x, augment=False): class ORT_NMS (line 87) | class ORT_NMS(torch.autograd.Function): method forward (line 90) | def forward(ctx, method symbolic (line 107) | def symbolic(g, boxes, scores, max_output_boxes_per_class, iou_thresho... class TRT_NMS (line 111) | class TRT_NMS(torch.autograd.Function): method forward (line 114) | def forward( method symbolic (line 134) | def symbolic(g, class ONNX_ORT (line 159) | class ONNX_ORT(nn.Module): method __init__ (line 161) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 172) | def forward(self, x): class ONNX_TRT (line 190) | class ONNX_TRT(nn.Module): method __init__ (line 192) | def __init__(self, max_obj=100, iou_thres=0.45, score_thres=0.25, max_... method forward (line 204) | def forward(self, x): class End2End (line 216) | class End2End(nn.Module): method __init__ (line 218) | def __init__(self, model, max_obj=100, iou_thres=0.45, score_thres=0.2... method forward (line 228) | def forward(self, x): function attempt_load (line 237) | def attempt_load(weights, map_location=None): FILE: asone/pose_estimators/yolov7_pose/models/yolo.py class Detect (line 23) | class Detect(nn.Module): method __init__ (line 29) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 41) | def forward(self, x): method _make_grid (line 76) | def _make_grid(nx=20, ny=20): method convert (line 80) | def convert(self, z): class IDetect (line 93) | class IDetect(nn.Module): method __init__ (line 99) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 114) | def forward(self, x): method fuseforward (line 135) | def fuseforward(self, x): method fuse (line 165) | def fuse(self): method _make_grid (line 180) | def _make_grid(nx=20, ny=20): method convert (line 184) | def convert(self, z): class IKeypoint (line 197) | class IKeypoint(nn.Module): method __init__ (line 201) | def __init__(self, nc=80, anchors=(), nkpt=17, ch=(), inplace=True, dw... method forward (line 235) | def forward(self, x): method _make_grid (line 293) | def _make_grid(nx=20, ny=20): class IAuxDetect (line 298) | class IAuxDetect(nn.Module): method __init__ (line 302) | def __init__(self, nc=80, anchors=(), ch=()): # detection layer method forward (line 318) | def forward(self, x): method _make_grid (line 343) | def _make_grid(nx=20, ny=20): class IBin (line 348) | class IBin(nn.Module): method __init__ (line 352) | def __init__(self, nc=80, anchors=(), ch=(), bin_count=21): # detecti... method forward (line 375) | def forward(self, x): method _make_grid (line 418) | def _make_grid(nx=20, ny=20): class Model (line 423) | class Model(nn.Module): method __init__ (line 424) | def __init__(self, cfg='yolor-csp-c.yaml', ch=3, nc=None, anchors=None... method forward (line 496) | def forward(self, x, augment=False, profile=False): method forward_once (line 516) | def forward_once(self, x, profile=False): method _initialize_biases (line 548) | def _initialize_biases(self, cf=None): # initialize biases into Detec... method _initialize_aux_biases (line 558) | def _initialize_aux_biases(self, cf=None): # initialize biases into D... method _initialize_biases_bin (line 572) | def _initialize_biases_bin(self, cf=None): # initialize biases into D... method _initialize_biases_kpt (line 587) | def _initialize_biases_kpt(self, cf=None): # initialize biases into D... method _print_biases (line 597) | def _print_biases(self): method fuse (line 608) | def fuse(self): # fuse model Conv2d() + BatchNorm2d() layers method nms (line 627) | def nms(self, mode=True): # add or remove NMS module method autoshape (line 641) | def autoshape(self): # add autoShape module method info (line 647) | def info(self, verbose=False, img_size=640): # print model information function parse_model (line 651) | def parse_model(d, ch): # model_dict, input_channels(3) FILE: asone/pose_estimators/yolov7_pose/utils/activations.py class SiLU (line 9) | class SiLU(nn.Module): # export-friendly version of nn.SiLU() method forward (line 11) | def forward(x): class Hardswish (line 15) | class Hardswish(nn.Module): # export-friendly version of nn.Hardswish() method forward (line 17) | def forward(x): class MemoryEfficientSwish (line 22) | class MemoryEfficientSwish(nn.Module): class F (line 23) | class F(torch.autograd.Function): method forward (line 25) | def forward(ctx, x): method backward (line 30) | def backward(ctx, grad_output): method forward (line 35) | def forward(self, x): class Mish (line 40) | class Mish(nn.Module): method forward (line 42) | def forward(x): class MemoryEfficientMish (line 46) | class MemoryEfficientMish(nn.Module): class F (line 47) | class F(torch.autograd.Function): method forward (line 49) | def forward(ctx, x): method backward (line 54) | def backward(ctx, grad_output): method forward (line 60) | def forward(self, x): class FReLU (line 65) | class FReLU(nn.Module): method __init__ (line 66) | def __init__(self, c1, k=3): # ch_in, kernel method forward (line 71) | def forward(self, x): FILE: asone/pose_estimators/yolov7_pose/utils/add_nms.py class RegisterNMS (line 13) | class RegisterNMS(object): method __init__ (line 14) | def __init__( method infer (line 27) | def infer(self): method save (line 60) | def save(self, output_path): method register_nms (line 72) | def register_nms( method save (line 145) | def save(self, output_path): FILE: asone/pose_estimators/yolov7_pose/utils/autoanchor.py function check_anchor_order (line 12) | def check_anchor_order(m): function check_anchors (line 23) | def check_anchors(dataset, model, thr=4.0, imgsz=640): function kmean_anchors (line 62) | def kmean_anchors(path='./data/coco.yaml', n=9, img_size=640, thr=4.0, g... FILE: asone/pose_estimators/yolov7_pose/utils/datasets.py function get_hash (line 45) | def get_hash(files): function exif_size (line 50) | def exif_size(img): function create_dataloader (line 65) | def create_dataloader(path, imgsz, batch_size, stride, opt, hyp=None, au... class InfiniteDataLoader (line 94) | class InfiniteDataLoader(torch.utils.data.dataloader.DataLoader): method __init__ (line 100) | def __init__(self, *args, **kwargs): method __len__ (line 105) | def __len__(self): method __iter__ (line 108) | def __iter__(self): class _RepeatSampler (line 113) | class _RepeatSampler(object): method __init__ (line 120) | def __init__(self, sampler): method __iter__ (line 123) | def __iter__(self): class LoadImages (line 128) | class LoadImages: # for inference method __init__ (line 129) | def __init__(self, path, img_size=640, stride=32): method __iter__ (line 157) | def __iter__(self): method __next__ (line 161) | def __next__(self): method new_video (line 199) | def new_video(self, path): method __len__ (line 204) | def __len__(self): class LoadWebcam (line 208) | class LoadWebcam: # for inference method __init__ (line 209) | def __init__(self, pipe='0', img_size=640, stride=32): method __iter__ (line 223) | def __iter__(self): method __next__ (line 227) | def __next__(self): method __len__ (line 262) | def __len__(self): class LoadStreams (line 266) | class LoadStreams: # multiple IP or RTSP cameras method __init__ (line 267) | def __init__(self, sources='streams.txt', img_size=640, stride=32): method update (line 307) | def update(self, index, cap): method __iter__ (line 320) | def __iter__(self): method __next__ (line 324) | def __next__(self): method __len__ (line 343) | def __len__(self): function img2label_paths (line 347) | def img2label_paths(img_paths): class LoadImagesAndLabels (line 353) | class LoadImagesAndLabels(Dataset): # for training/testing method __init__ (line 354) | def __init__(self, path, img_size=640, batch_size=16, augment=False, h... method cache_labels (line 470) | def cache_labels(self, path=Path('./labels.cache'), prefix=''): method __len__ (line 525) | def __len__(self): method __getitem__ (line 534) | def __getitem__(self, index): method collate_fn (line 632) | def collate_fn(batch): method collate_fn4 (line 639) | def collate_fn4(batch): function load_image (line 666) | def load_image(self, index): function augment_hsv (line 683) | def augment_hsv(img, hgain=0.5, sgain=0.5, vgain=0.5): function hist_equalize (line 697) | def hist_equalize(img, clahe=True, bgr=False): function load_mosaic (line 708) | def load_mosaic(self, index): function load_mosaic9 (line 767) | def load_mosaic9(self, index): function load_samples (line 843) | def load_samples(self, index): function copy_paste (line 894) | def copy_paste(img, labels, segments, probability=0.5): function remove_background (line 918) | def remove_background(img, labels, segments): function sample_segments (line 935) | def sample_segments(img, labels, segments, probability=0.5): function replicate (line 967) | def replicate(img, labels): function letterbox (line 984) | def letterbox(img, new_shape=(640, 640), color=(114, 114, 114), auto=Tru... function random_perspective (line 1017) | def random_perspective(img, targets=(), segments=(), degrees=10, transla... function box_candidates (line 1106) | def box_candidates(box1, box2, wh_thr=2, ar_thr=20, area_thr=0.1, eps=1e... function bbox_ioa (line 1114) | def bbox_ioa(box1, box2): function cutout (line 1133) | def cutout(image, labels): function pastein (line 1161) | def pastein(image, labels, sample_labels, sample_images, sample_masks): class Albumentations (line 1218) | class Albumentations: method __init__ (line 1220) | def __init__(self): method __call__ (line 1236) | def __call__(self, im, labels, p=1.0): function create_folder (line 1243) | def create_folder(path='./new'): function flatten_recursive (line 1250) | def flatten_recursive(path='../coco'): function extract_boxes (line 1258) | def extract_boxes(path='../coco/'): # from utils.datasets import *; ext... function autosplit (line 1293) | def autosplit(path='../coco', weights=(0.9, 0.1, 0.0), annotated_only=Fa... function load_segmentations (line 1316) | def load_segmentations(self, index): FILE: asone/pose_estimators/yolov7_pose/utils/general.py function set_logging (line 33) | def set_logging(rank=-1): function init_seeds (line 39) | def init_seeds(seed=0): function get_latest_run (line 46) | def get_latest_run(search_dir='.'): function isdocker (line 52) | def isdocker(): function emojis (line 57) | def emojis(str=''): function check_online (line 62) | def check_online(): function check_git_status (line 72) | def check_git_status(): function check_requirements (line 94) | def check_requirements(requirements='requirements.txt', exclude=()): function check_img_size (line 123) | def check_img_size(img_size, s=32): function check_imshow (line 131) | def check_imshow(): function check_file (line 145) | def check_file(file): function check_dataset (line 156) | def check_dataset(dict): function make_divisible (line 176) | def make_divisible(x, divisor): function clean_str (line 181) | def clean_str(s): function one_cycle (line 186) | def one_cycle(y1=0.0, y2=1.0, steps=100): function colorstr (line 191) | def colorstr(*input): function labels_to_class_weights (line 216) | def labels_to_class_weights(labels, nc=80): function labels_to_image_weights (line 235) | def labels_to_image_weights(labels, nc=80, class_weights=np.ones(80)): function coco80_to_coco91_class (line 243) | def coco80_to_coco91_class(): # converts 80-index (val2014) to 91-index... function xyxy2xywh (line 255) | def xyxy2xywh(x): function xywh2xyxy (line 265) | def xywh2xyxy(x): function xywhn2xyxy (line 275) | def xywhn2xyxy(x, w=640, h=640, padw=0, padh=0): function xyn2xy (line 285) | def xyn2xy(x, w=640, h=640, padw=0, padh=0): function segment2box (line 293) | def segment2box(segment, width=640, height=640): function segments2boxes (line 301) | def segments2boxes(segments): function resample_segments (line 310) | def resample_segments(segments, n=1000): function scale_coords (line 319) | def scale_coords(img1_shape, coords, img0_shape, ratio_pad=None): function clip_coords (line 335) | def clip_coords(boxes, img_shape): function bbox_iou (line 343) | def bbox_iou(box1, box2, x1y1x2y2=True, GIoU=False, DIoU=False, CIoU=Fal... function bbox_alpha_iou (line 391) | def bbox_alpha_iou(box1, box2, x1y1x2y2=False, GIoU=False, DIoU=False, C... function box_iou (line 443) | def box_iou(box1, box2): function wh_iou (line 468) | def wh_iou(wh1, wh2): function box_giou (line 476) | def box_giou(box1, box2): function box_ciou (line 510) | def box_ciou(box1, box2, eps: float = 1e-7): function box_diou (line 562) | def box_diou(box1, box2, eps: float = 1e-7): function non_max_suppression (line 607) | def non_max_suppression(prediction, conf_thres=0.25, iou_thres=0.45, cla... function non_max_suppression_kpt (line 698) | def non_max_suppression_kpt(prediction, conf_thres=0.25, iou_thres=0.45,... function strip_optimizer (line 795) | def strip_optimizer(device='cpu',f='yolov7-w6-pose.pt', s=''): # from u... function print_mutation (line 814) | def print_mutation(hyp, results, yaml_file='hyp_evolved.yaml', bucket=''): function apply_classifier (line 845) | def apply_classifier(x, model, img, im0): function increment_path (line 880) | def increment_path(path, exist_ok=True, sep=''): FILE: asone/pose_estimators/yolov7_pose/utils/google_utils.py function gsutil_getsize (line 13) | def gsutil_getsize(url=''): function attempt_download (line 19) | def attempt_download(file, repo='WongKinYiu/yolov7'): function gdrive_download (line 55) | def gdrive_download(id='', file='tmp.zip'): function get_token (line 90) | def get_token(cookie="./cookie"): FILE: asone/pose_estimators/yolov7_pose/utils/loss.py function smooth_BCE (line 11) | def smooth_BCE(eps=0.1): # https://github.com/ultralytics/yolov3/issues... class BCEBlurWithLogitsLoss (line 16) | class BCEBlurWithLogitsLoss(nn.Module): method __init__ (line 18) | def __init__(self, alpha=0.05): method forward (line 23) | def forward(self, pred, true): class SigmoidBin (line 33) | class SigmoidBin(nn.Module): method __init__ (line 37) | def __init__(self, bin_count=10, min=0.0, max=1.0, reg_scale = 2.0, us... method get_length (line 68) | def get_length(self): method forward (line 71) | def forward(self, pred): method training_loss (line 89) | def training_loss(self, pred, target): class FocalLoss (line 121) | class FocalLoss(nn.Module): method __init__ (line 123) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 131) | def forward(self, pred, true): class QFocalLoss (line 151) | class QFocalLoss(nn.Module): method __init__ (line 153) | def __init__(self, loss_fcn, gamma=1.5, alpha=0.25): method forward (line 161) | def forward(self, pred, true): class RankSort (line 176) | class RankSort(torch.autograd.Function): method forward (line 178) | def forward(ctx, logits, targets, delta_RS=0.50, eps=1e-10): method backward (line 271) | def backward(ctx, out_grad1, out_grad2): class aLRPLoss (line 275) | class aLRPLoss(torch.autograd.Function): method forward (line 277) | def forward(ctx, logits, targets, regression_losses, delta=1., eps=1e-5): method backward (line 340) | def backward(ctx, out_grad1, out_grad2, out_grad3): class APLoss (line 345) | class APLoss(torch.autograd.Function): method forward (line 347) | def forward(ctx, logits, targets, delta=1.): method backward (line 417) | def backward(ctx, out_grad1): class ComputeLoss (line 422) | class ComputeLoss: method __init__ (line 424) | def __init__(self, model, autobalance=False): method __call__ (line 450) | def __call__(self, p, targets): # predictions, targets, model method build_targets (line 500) | def build_targets(self, p, targets): class ComputeLossOTA (line 556) | class ComputeLossOTA: method __init__ (line 558) | def __init__(self, model, autobalance=False): method __call__ (line 582) | def __call__(self, p, targets, imgs): # predictions, targets, model method build_targets (line 638) | def build_targets(self, p, targets, imgs): method find_3_positive (line 795) | def find_3_positive(self, p, targets): class ComputeLossBinOTA (line 849) | class ComputeLossBinOTA: method __init__ (line 851) | def __init__(self, model, autobalance=False): method __call__ (line 881) | def __call__(self, p, targets, imgs): # predictions, targets, model method build_targets (line 961) | def build_targets(self, p, targets, imgs): method find_3_positive (line 1122) | def find_3_positive(self, p, targets): class ComputeLossAuxOTA (line 1176) | class ComputeLossAuxOTA: method __init__ (line 1178) | def __init__(self, model, autobalance=False): method __call__ (line 1202) | def __call__(self, p, targets, imgs): # predictions, targets, model method build_targets (line 1287) | def build_targets(self, p, targets, imgs): method build_targets2 (line 1440) | def build_targets2(self, p, targets, imgs): method find_5_positive (line 1593) | def find_5_positive(self, p, targets): method find_3_positive (line 1646) | def find_3_positive(self, p, targets): FILE: asone/pose_estimators/yolov7_pose/utils/metrics.py function fitness (line 12) | def fitness(x): function ap_per_class (line 18) | def ap_per_class(tp, conf, pred_cls, target_cls, plot=False, save_dir='.... function compute_ap (line 81) | def compute_ap(recall, precision): class ConfusionMatrix (line 109) | class ConfusionMatrix: method __init__ (line 111) | def __init__(self, nc, conf=0.25, iou_thres=0.45): method process_batch (line 117) | def process_batch(self, detections, labels): method matrix (line 157) | def matrix(self): method plot (line 160) | def plot(self, save_dir='', names=()): method print (line 179) | def print(self): function plot_pr_curve (line 186) | def plot_pr_curve(px, py, ap, save_dir='pr_curve.png', names=()): function plot_mc_curve (line 206) | def plot_mc_curve(px, py, save_dir='mc_curve.png', names=(), xlabel='Con... FILE: asone/pose_estimators/yolov7_pose/utils/plots.py class Colors (line 28) | class Colors: method __init__ (line 30) | def __init__(self): method __call__ (line 34) | def __call__(self, i, bgr=False): method hex2rgb (line 39) | def hex2rgb(h): # rgb order (PIL) function plot_one_box_kpt (line 43) | def plot_one_box_kpt(x, im, color=None, label=None, line_thickness=3, kp... function color_list (line 63) | def color_list(): function hist2d (line 70) | def hist2d(x, y, n=100): function butter_lowpass_filtfilt (line 79) | def butter_lowpass_filtfilt(data, cutoff=1500, fs=50000, order=5): function plot_one_box (line 90) | def plot_one_box(x, img, color=None, label=None, line_thickness=1): function plot_one_box_PIL (line 104) | def plot_one_box_PIL(box, img, color=None, label=None, line_thickness=No... function plot_wh_methods (line 118) | def plot_wh_methods(): # from utils.plots import *; plot_wh_methods() function output_to_target (line 138) | def output_to_target(output): function plot_images (line 147) | def plot_images(images, targets, paths=None, fname='images.jpg', names=N... function plot_lr_scheduler (line 226) | def plot_lr_scheduler(optimizer, scheduler, epochs=300, save_dir=''): function plot_test_txt (line 243) | def plot_test_txt(): # from utils.plots import *; plot_test() function plot_targets_txt (line 260) | def plot_targets_txt(): # from utils.plots import *; plot_targets_txt() function plot_study_txt (line 273) | def plot_study_txt(path='', x=None): # from utils.plots import *; plot_... function plot_labels (line 305) | def plot_labels(labels, names=(), save_dir=Path(''), loggers=None): function plot_evolution (line 354) | def plot_evolution(yaml_file='data/hyp.finetune.yaml'): # from utils.pl... function profile_idetection (line 378) | def profile_idetection(start=0, stop=0, labels=(), save_dir=''): function plot_results_overlay (line 410) | def plot_results_overlay(start=0, stop=0): # from utils.plots import *;... function plot_results (line 433) | def plot_results(start=0, stop=0, bucket='', id=(), labels=(), save_dir=... function output_to_keypoint (line 469) | def output_to_keypoint(output): function plot_skeleton_kpts (line 480) | def plot_skeleton_kpts(im, kpts, steps, orig_shape=None): FILE: asone/pose_estimators/yolov7_pose/utils/torch_utils.py function torch_distributed_zero_first (line 28) | def torch_distributed_zero_first(local_rank: int): function init_torch_seeds (line 39) | def init_torch_seeds(seed=0): function date_modified (line 48) | def date_modified(path=__file__): function git_describe (line 54) | def git_describe(path=Path(__file__).parent): # path must be a directory function select_device (line 63) | def select_device(device='', batch_size=None): function time_synchronized (line 89) | def time_synchronized(): function profile (line 96) | def profile(x, ops, n=100, device=None): function is_parallel (line 135) | def is_parallel(model): function intersect_dicts (line 139) | def intersect_dicts(da, db, exclude=()): function initialize_weights (line 144) | def initialize_weights(model): function find_modules (line 156) | def find_modules(model, mclass=nn.Conv2d): function sparsity (line 161) | def sparsity(model): function prune (line 170) | def prune(model, amount=0.3): function fuse_conv_and_bn (line 181) | def fuse_conv_and_bn(conv, bn): function model_info (line 204) | def model_info(model, verbose=False, img_size=640): function load_classifier (line 228) | def load_classifier(name='resnet101', n=2): function scale_img (line 247) | def scale_img(img, ratio=1.0, same_shape=False, gs=32): # img(16,3,256,... function copy_attr (line 260) | def copy_attr(a, b, include=(), exclude=()): class ModelEMA (line 269) | class ModelEMA: method __init__ (line 279) | def __init__(self, model, decay=0.9999, updates=0): method update (line 289) | def update(self, model): method update_attr (line 301) | def update_attr(self, model, include=(), exclude=('process_group', 're... class BatchNormXd (line 306) | class BatchNormXd(torch.nn.modules.batchnorm._BatchNorm): method _check_input_dim (line 307) | def _check_input_dim(self, input): function revert_sync_batchnorm (line 318) | def revert_sync_batchnorm(module): class TracedModel (line 343) | class TracedModel(nn.Module): method __init__ (line 345) | def __init__(self, model=None, device=None, img_size=(640,640)): method forward (line 371) | def forward(self, x, augment=False, profile=False): FILE: asone/pose_estimators/yolov7_pose/utils/wandb_logging/log_dataset.py function create_dataset_artifact (line 10) | def create_dataset_artifact(opt): FILE: asone/pose_estimators/yolov7_pose/utils/wandb_logging/wandb_utils.py function remove_prefix (line 23) | def remove_prefix(from_string, prefix=WANDB_ARTIFACT_PREFIX): function check_wandb_config_file (line 27) | def check_wandb_config_file(data_config_file): function get_run_info (line 34) | def get_run_info(run_path): function check_wandb_resume (line 42) | def check_wandb_resume(opt): function process_wandb_config_ddp_mode (line 56) | def process_wandb_config_ddp_mode(opt): class WandbLogger (line 80) | class WandbLogger(): method __init__ (line 81) | def __init__(self, opt, name, run_id, data_dict, job_type='Training'): method check_and_upload_dataset (line 115) | def check_and_upload_dataset(self, opt): method setup_training (line 126) | def setup_training(self, opt, data_dict): method download_dataset_artifact (line 159) | def download_dataset_artifact(self, path, alias): method download_model_artifact (line 167) | def download_model_artifact(self, opt): method log_model (line 179) | def log_model(self, path, opt, epoch, fitness_score, best_model=False): method log_dataset_artifact (line 193) | def log_dataset_artifact(self, data_file, single_cls, project, overwri... method map_val_table_path (line 222) | def map_val_table_path(self): method create_dataset_table (line 228) | def create_dataset_table(self, dataset, class_to_id, name='dataset'): method log_training_progress (line 263) | def log_training_progress(self, predn, path, names): method log (line 285) | def log(self, log_dict): method end_epoch (line 290) | def end_epoch(self, best_result=False): method finish_run (line 302) | def finish_run(self): FILE: asone/pose_estimators/yolov7_pose/utils/yolov7_pose_utils.py function yolov7_in_syspath (line 6) | def yolov7_in_syspath(): FILE: asone/pose_estimators/yolov7_pose/yolov7.py class Yolov7PoseEstimator (line 16) | class Yolov7PoseEstimator: method __init__ (line 17) | def __init__(self, weights="yolov7-w6-pose.pt", use_cuda=True): method estimate (line 27) | def estimate(self, frame): FILE: asone/pose_estimators/yolov8_pose/plots.py class Colors (line 28) | class Colors: method __init__ (line 30) | def __init__(self): method __call__ (line 34) | def __call__(self, i, bgr=False): method hex2rgb (line 39) | def hex2rgb(h): # rgb order (PIL) function plot_one_box_kpt (line 43) | def plot_one_box_kpt(x, im, color=None, label=None, line_thickness=3, kp... function color_list (line 63) | def color_list(): function hist2d (line 70) | def hist2d(x, y, n=100): function butter_lowpass_filtfilt (line 79) | def butter_lowpass_filtfilt(data, cutoff=1500, fs=50000, order=5): function plot_one_box (line 90) | def plot_one_box(x, img, color=None, label=None, line_thickness=1): function plot_one_box_PIL (line 104) | def plot_one_box_PIL(box, img, color=None, label=None, line_thickness=No... function plot_wh_methods (line 118) | def plot_wh_methods(): # from utils.plots import *; plot_wh_methods() function output_to_target (line 138) | def output_to_target(output): function plot_images (line 147) | def plot_images(images, targets, paths=None, fname='images.jpg', names=N... function plot_lr_scheduler (line 226) | def plot_lr_scheduler(optimizer, scheduler, epochs=300, save_dir=''): function plot_test_txt (line 243) | def plot_test_txt(): # from utils.plots import *; plot_test() function plot_targets_txt (line 260) | def plot_targets_txt(): # from utils.plots import *; plot_targets_txt() function plot_study_txt (line 273) | def plot_study_txt(path='', x=None): # from utils.plots import *; plot_... function plot_labels (line 305) | def plot_labels(labels, names=(), save_dir=Path(''), loggers=None): function plot_evolution (line 354) | def plot_evolution(yaml_file='data/hyp.finetune.yaml'): # from utils.pl... function profile_idetection (line 378) | def profile_idetection(start=0, stop=0, labels=(), save_dir=''): function plot_results_overlay (line 410) | def plot_results_overlay(start=0, stop=0): # from utils.plots import *;... function plot_results (line 433) | def plot_results(start=0, stop=0, bucket='', id=(), labels=(), save_dir=... function output_to_keypoint (line 469) | def output_to_keypoint(output): function plot_skeleton_kpts (line 480) | def plot_skeleton_kpts(im, kpts, steps, orig_shape=None): FILE: asone/pose_estimators/yolov8_pose/yolov8.py class Yolov8PoseEstimator (line 5) | class Yolov8PoseEstimator: method __init__ (line 6) | def __init__(self, weights, use_cuda=True): method estimate (line 10) | def estimate(self, source): FILE: asone/recognizers/easyocr_recognizer/easyocr_recognizer.py class EasyOCRRecognizer (line 6) | class EasyOCRRecognizer: method __init__ (line 8) | def __init__ (self, languages: list = ['en'], detect_network="craft", method detect (line 14) | def detect(self, img): method recognize (line 18) | def recognize(self, img, horizontal_list=None, free_list=None): FILE: asone/recognizers/recognizer.py class TextRecognizer (line 5) | class TextRecognizer: method __init__ (line 7) | def __init__(self, method _select_recognizer (line 14) | def _select_recognizer(self, model_flag, use_cuda, languages): method get_recognizer (line 20) | def get_recognizer(self): method recognize (line 23) | def recognize(self, FILE: asone/recognizers/utils/recognizer_name.py function get_recognizer_name (line 7) | def get_recognizer_name(model_flag): FILE: asone/schemas/output_schemas.py class ModelOutput (line 1) | class ModelOutput: method __init__ (line 2) | def __init__(self): class Detections (line 6) | class Detections: method __init__ (line 7) | def __init__(self): class ImageInfo (line 13) | class ImageInfo: method __init__ (line 14) | def __init__(self): FILE: asone/segmentors/segment_anything/sam.py class SamSegmentor (line 9) | class SamSegmentor: method __init__ (line 10) | def __init__(self, method load_models (line 17) | def load_models(self, ckpt: str) -> None: method draw_masks_fromList (line 23) | def draw_masks_fromList(self, image, masks_generated, labels, colors=[... method create_mask (line 37) | def create_mask(self, bbox_xyxy, image): FILE: asone/segmentors/segmentor.py class Segmentor (line 8) | class Segmentor: method __init__ (line 9) | def __init__(self, method _select_segmentor (line 22) | def _select_segmentor(self, model_flag, weights, use_cuda): method create_mask (line 27) | def create_mask(self, bbox_xyxy, image): FILE: asone/segmentors/utils/weights_path.py function get_weight_path (line 8) | def get_weight_path(model_flag): FILE: asone/trackers/byte_track/bytetracker.py class ByteTrack (line 6) | class ByteTrack(object): method __init__ (line 7) | def __init__(self, detector, min_box_area: int = 10, aspect_ratio_thre... method detect_and_track (line 23) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: method _tracker_update (line 39) | def _tracker_update(self, dets: np.ndarray, image_info: dict): FILE: asone/trackers/byte_track/tracker/basetrack.py class TrackState (line 5) | class TrackState(object): class BaseTrack (line 12) | class BaseTrack(object): method end_frame (line 31) | def end_frame(self): method next_id (line 35) | def next_id(): method activate (line 39) | def activate(self, *args): method predict (line 42) | def predict(self): method update (line 45) | def update(self, *args, **kwargs): method mark_lost (line 48) | def mark_lost(self): method mark_removed (line 51) | def mark_removed(self): FILE: asone/trackers/byte_track/tracker/byte_tracker.py class STrack (line 6) | class STrack(BaseTrack): method __init__ (line 8) | def __init__(self, tlwh, score): method predict (line 19) | def predict(self): method multi_predict (line 26) | def multi_predict(stracks): method activate (line 38) | def activate(self, kalman_filter, frame_id): method re_activate (line 52) | def re_activate(self, new_track, frame_id, new_id=False): method update (line 64) | def update(self, new_track, frame_id): method tlwh (line 85) | def tlwh(self): method tlbr (line 98) | def tlbr(self): method tlwh_to_xyah (line 108) | def tlwh_to_xyah(tlwh): method to_xyah (line 117) | def to_xyah(self): method tlbr_to_tlwh (line 122) | def tlbr_to_tlwh(tlbr): method tlwh_to_tlbr (line 129) | def tlwh_to_tlbr(tlwh): method __repr__ (line 134) | def __repr__(self): class BYTETracker (line 138) | class BYTETracker(object): method __init__ (line 139) | def __init__(self, track_thresh=0.5,match_thresh=0.8, track_buffer=30,... method update (line 155) | def update(self, output_results, img_info, img_size): function joint_stracks (line 288) | def joint_stracks(tlista, tlistb): function sub_stracks (line 302) | def sub_stracks(tlista, tlistb): function remove_duplicate_stracks (line 313) | def remove_duplicate_stracks(stracksa, stracksb): FILE: asone/trackers/byte_track/tracker/kalman_filter.py class KalmanFilter (line 23) | class KalmanFilter(object): method __init__ (line 40) | def __init__(self): method initiate (line 55) | def initiate(self, measurement): method predict (line 88) | def predict(self, mean, covariance): method project (line 126) | def project(self, mean, covariance): method multi_predict (line 155) | def multi_predict(self, mean, covariance): method update (line 194) | def update(self, mean, covariance, measurement): method gating_distance (line 228) | def gating_distance(self, mean, covariance, measurements, FILE: asone/trackers/byte_track/tracker/matching.py function merge_matches (line 8) | def merge_matches(m1, m2, shape): function _indices_to_matches (line 25) | def _indices_to_matches(cost_matrix, indices, thresh): function linear_assignment (line 36) | def linear_assignment(cost_matrix, thresh): function ious (line 50) | def ious(atlbrs, btlbrs): function iou_distance (line 70) | def iou_distance(atracks, btracks): function v_iou_distance (line 90) | def v_iou_distance(atracks, btracks): function embedding_distance (line 110) | def embedding_distance(tracks, detections, metric='cosine'): function gate_cost_matrix (line 129) | def gate_cost_matrix(kf, cost_matrix, tracks, detections, only_position=... function fuse_motion (line 142) | def fuse_motion(kf, cost_matrix, tracks, detections, only_position=False... function fuse_iou (line 156) | def fuse_iou(cost_matrix, tracks, detections): function fuse_score (line 170) | def fuse_score(cost_matrix, detections): FILE: asone/trackers/deep_sort/deepsort.py class DeepSort (line 7) | class DeepSort: method __init__ (line 8) | def __init__(self, detector, weights=None, use_cuda=True): method detect_and_track (line 34) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: method _tracker_update (line 56) | def _tracker_update(self, dets_xyxy: np.ndarray, image_info: dict): FILE: asone/trackers/deep_sort/tracker/__init__.py function build_tracker (line 7) | def build_tracker(weights, cfg, use_cuda=True): FILE: asone/trackers/deep_sort/tracker/deep/feature_extractor.py class Extractor (line 10) | class Extractor(object): method __init__ (line 11) | def __init__(self, model_path, use_cuda=True): method _preprocess (line 26) | def _preprocess(self, im_crops): method __call__ (line 42) | def __call__(self, im_crops): FILE: asone/trackers/deep_sort/tracker/deep/model.py class BasicBlock (line 6) | class BasicBlock(nn.Module): method __init__ (line 7) | def __init__(self, c_in, c_out, is_downsample=False): method forward (line 33) | def forward(self, x): function make_layers (line 44) | def make_layers(c_in, c_out, repeat_times, is_downsample=False): class Net (line 54) | class Net(nn.Module): method __init__ (line 55) | def __init__(self, num_classes=751, reid=False): method forward (line 87) | def forward(self, x): FILE: asone/trackers/deep_sort/tracker/deep/original_model.py class BasicBlock (line 6) | class BasicBlock(nn.Module): method __init__ (line 7) | def __init__(self, c_in, c_out, is_downsample=False): method forward (line 33) | def forward(self, x): function make_layers (line 44) | def make_layers(c_in, c_out, repeat_times, is_downsample=False): class Net (line 54) | class Net(nn.Module): method __init__ (line 55) | def __init__(self, num_classes=625, reid=False): method forward (line 87) | def forward(self, x): FILE: asone/trackers/deep_sort/tracker/deep/train.py function train (line 80) | def train(epoch): function test (line 119) | def test(epoch): function draw_curve (line 168) | def draw_curve(epoch, train_loss, train_err, test_loss, test_err): function lr_decay (line 188) | def lr_decay(): function main (line 196) | def main(): FILE: asone/trackers/deep_sort/tracker/deep_sort.py class DeepSORT (line 13) | class DeepSORT(object): method __init__ (line 14) | def __init__(self, model_path, max_dist=0.2, min_confidence=0.3, nms_m... method update (line 26) | def update(self, bbox_xywh, confidences, oids, ori_img): method _xywh_to_tlwh (line 63) | def _xywh_to_tlwh(bbox_xywh): method _xywh_to_xyxy (line 72) | def _xywh_to_xyxy(self, bbox_xywh): method _tlwh_to_xyxy (line 80) | def _tlwh_to_xyxy(self, bbox_tlwh): method increment_ages (line 93) | def increment_ages(self): method _xyxy_to_tlwh (line 96) | def _xyxy_to_tlwh(self, bbox_xyxy): method _get_features (line 105) | def _get_features(self, bbox_xywh, ori_img): FILE: asone/trackers/deep_sort/tracker/parser.py class YamlParser (line 6) | class YamlParser(edict): method __init__ (line 11) | def __init__(self, cfg_dict=None, config_file=None): method merge_from_file (line 23) | def merge_from_file(self, config_file): method merge_from_dict (line 28) | def merge_from_dict(self, config_dict): function get_config (line 32) | def get_config(config_file=None): FILE: asone/trackers/deep_sort/tracker/sort/detection.py class Detection (line 5) | class Detection(object): method __init__ (line 29) | def __init__(self, tlwh, confidence, feature, oid): method to_tlbr (line 35) | def to_tlbr(self): method to_xyah (line 43) | def to_xyah(self): FILE: asone/trackers/deep_sort/tracker/sort/iou_matching.py function iou (line 7) | def iou(bbox, candidates): function iou_cost (line 42) | def iou_cost(tracks, detections, track_indices=None, FILE: asone/trackers/deep_sort/tracker/sort/kalman_filter.py class KalmanFilter (line 23) | class KalmanFilter(object): method __init__ (line 40) | def __init__(self): method initiate (line 55) | def initiate(self, measurement): method predict (line 88) | def predict(self, mean, covariance): method project (line 125) | def project(self, mean, covariance): method update (line 154) | def update(self, mean, covariance, measurement): method gating_distance (line 188) | def gating_distance(self, mean, covariance, measurements, FILE: asone/trackers/deep_sort/tracker/sort/linear_assignment.py function min_cost_matching (line 12) | def min_cost_matching( function matching_cascade (line 80) | def matching_cascade( function gate_cost_matrix (line 146) | def gate_cost_matrix( FILE: asone/trackers/deep_sort/tracker/sort/nn_matching.py function _pdist (line 5) | def _pdist(a, b): function _cosine_distance (line 31) | def _cosine_distance(a, b, data_is_normalized=False): function _nn_euclidean_distance (line 57) | def _nn_euclidean_distance(x, y): function _nn_cosine_distance (line 78) | def _nn_cosine_distance(x, y): class NearestNeighborDistanceMetric (line 99) | class NearestNeighborDistanceMetric(object): method __init__ (line 123) | def __init__(self, metric, matching_threshold, budget=None): method partial_fit (line 136) | def partial_fit(self, features, targets, active_targets): method distance (line 155) | def distance(self, features, targets): FILE: asone/trackers/deep_sort/tracker/sort/preprocessing.py function non_max_suppression (line 6) | def non_max_suppression(boxes, max_bbox_overlap, scores=None): FILE: asone/trackers/deep_sort/tracker/sort/track.py class TrackState (line 4) | class TrackState: class Track (line 19) | class Track: method __init__ (line 66) | def __init__(self, mean, covariance, track_id, n_init, max_age, oid, method to_tlwh (line 84) | def to_tlwh(self): method to_tlbr (line 99) | def to_tlbr(self): method increment_age (line 113) | def increment_age(self): method predict (line 117) | def predict(self, kf): method update (line 130) | def update(self, kf, detection): method mark_missed (line 151) | def mark_missed(self): method is_tentative (line 159) | def is_tentative(self): method is_confirmed (line 164) | def is_confirmed(self): method is_deleted (line 168) | def is_deleted(self): FILE: asone/trackers/deep_sort/tracker/sort/tracker.py class Tracker (line 10) | class Tracker: method __init__ (line 40) | def __init__(self, metric, max_iou_distance=0.7, max_age=70, n_init=3): method predict (line 50) | def predict(self): method increment_ages (line 58) | def increment_ages(self): method update (line 63) | def update(self, detections): method _match (line 103) | def _match(self, detections): method _initiate_track (line 140) | def _initiate_track(self, detection): FILE: asone/trackers/motpy/motpy.py class Motpy (line 5) | class Motpy: method __init__ (line 7) | def __init__(self, detector, dt=0.1) -> None: method detect_and_track (line 17) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: method _tracker_update (line 37) | def _tracker_update(self): FILE: asone/trackers/nor_fair/norfair.py class NorFair (line 5) | class NorFair: method __init__ (line 6) | def __init__(self, detector, max_distance_between_points=30) -> None: method _euclidean_distance (line 18) | def _euclidean_distance(self, detection, tracked_object): method detect_and_track (line 21) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: method _tracker_update (line 46) | def _tracker_update(self, dets_xyxy: list, image_info: dict): FILE: asone/trackers/oc_sort/ocsort.py class OcSort (line 6) | class OcSort: method __init__ (line 7) | def __init__(self, detector) -> None: method detect_and_track (line 16) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: FILE: asone/trackers/oc_sort/tracker/association.py function iou_batch (line 5) | def iou_batch(bboxes1, bboxes2): function giou_batch (line 24) | def giou_batch(bboxes1, bboxes2): function diou_batch (line 59) | def diou_batch(bboxes1, bboxes2): function ciou_batch (line 98) | def ciou_batch(bboxes1, bboxes2): function ct_dist (line 152) | def ct_dist(bboxes1, bboxes2): function speed_direction_batch (line 177) | def speed_direction_batch(dets, tracks): function linear_assignment (line 189) | def linear_assignment(cost_matrix): function associate_detections_to_trackers (line 200) | def associate_detections_to_trackers(detections,trackers,iou_threshold =... function associate (line 244) | def associate(detections, trackers, iou_threshold, velocities, previous_... function associate_kitti (line 303) | def associate_kitti(detections, trackers, det_cates, iou_threshold, FILE: asone/trackers/oc_sort/tracker/kalmanfilter.py class KalmanFilterNew (line 109) | class KalmanFilterNew(object): method __init__ (line 283) | def __init__(self, dim_x, dim_z, dim_u=0): method predict (line 339) | def predict(self, u=None, B=None, F=None, Q=None): method freeze (line 383) | def freeze(self): method unfreeze (line 390) | def unfreeze(self): method update (line 437) | def update(self, z, R=None, H=None): method predict_steadystate (line 528) | def predict_steadystate(self, u=0, B=None): method update_steadystate (line 557) | def update_steadystate(self, z): method update_correlated (line 624) | def update_correlated(self, z, R=None, H=None): method batch_filter (line 701) | def batch_filter(self, zs, Fs=None, Qs=None, Hs=None, method rts_smoother (line 837) | def rts_smoother(self, Xs, Ps, Fs=None, Qs=None, inv=np.linalg.inv): method get_prediction (line 901) | def get_prediction(self, u=None, B=None, F=None, Q=None): method get_update (line 944) | def get_update(self, z=None): method residual_of (line 989) | def residual_of(self, z): method measurement_of_state (line 997) | def measurement_of_state(self, x): method log_likelihood (line 1014) | def log_likelihood(self): method likelihood (line 1023) | def likelihood(self): method mahalanobis (line 1038) | def mahalanobis(self): method alpha (line 1051) | def alpha(self): method log_likelihood_of (line 1061) | def log_likelihood_of(self, z): method alpha (line 1072) | def alpha(self, value): method __repr__ (line 1078) | def __repr__(self): method test_matrix_dimensions (line 1108) | def test_matrix_dimensions(self, z=None, H=None, R=None, F=None, Q=None): function update (line 1208) | def update(x, P, z, R, H=None, return_all=False): function update_steadystate (line 1300) | def update_steadystate(x, z, K, H=None): function predict (line 1348) | def predict(x, P, F=1, Q=0, u=0, B=1, alpha=1.): function predict_steadystate (line 1389) | def predict_steadystate(x, F=1, u=0, B=1): function batch_filter (line 1421) | def batch_filter(x, P, zs, Fs, Qs, Hs, Rs, Bs=None, us=None, function rts_smoother (line 1529) | def rts_smoother(Xs, Ps, Fs, Qs): FILE: asone/trackers/oc_sort/tracker/ocsort.py function k_previous_obs (line 11) | def k_previous_obs(observations, cur_age, k): function convert_bbox_to_z (line 22) | def convert_bbox_to_z(bbox): function convert_x_to_bbox (line 37) | def convert_x_to_bbox(x, score=None): function speed_direction (line 50) | def speed_direction(bbox1, bbox2): class KalmanBoxTracker (line 58) | class KalmanBoxTracker(object): method __init__ (line 65) | def __init__(self, bbox, conf, cls, delta_t=3, orig=False): method update (line 121) | def update(self, bbox, cls): method predict (line 158) | def predict(self): method get_state (line 173) | def get_state(self): class OCSort (line 189) | class OCSort(object): method __init__ (line 190) | def __init__( method update (line 216) | def update(self, dets, _): FILE: asone/trackers/strong_sort/strongsort.py class StrongSort (line 5) | class StrongSort: method __init__ (line 6) | def __init__(self, detector) -> None: method detect_and_track (line 15) | def detect_and_track(self, image: np.ndarray, config: dict) -> tuple: FILE: asone/trackers/strong_sort/tracker/__init__.py function build_tracker (line 7) | def build_tracker(cfg, use_cuda): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/DML/default_config.py function get_default_config (line 4) | def get_default_config(): function imagedata_kwargs (line 113) | def imagedata_kwargs(cfg): function videodata_kwargs (line 139) | def videodata_kwargs(cfg): function optimizer_kwargs (line 163) | def optimizer_kwargs(cfg): function lr_scheduler_kwargs (line 180) | def lr_scheduler_kwargs(cfg): function engine_run_kwargs (line 189) | def engine_run_kwargs(cfg): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/DML/dml.py class ImageDMLEngine (line 10) | class ImageDMLEngine(Engine): method __init__ (line 12) | def __init__( method forward_backward (line 55) | def forward_backward(self, data): method compute_kl_div (line 107) | def compute_kl_div(p, q, is_logit=True): method two_stepped_transfer_learning (line 113) | def two_stepped_transfer_learning( method extract_features (line 138) | def extract_features(self, input): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/DML/main.py function reset_config (line 22) | def reset_config(cfg, args): function main (line 33) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/OSNet_AIN/default_config.py function get_default_config (line 4) | def get_default_config(): function imagedata_kwargs (line 117) | def imagedata_kwargs(cfg): function videodata_kwargs (line 142) | def videodata_kwargs(cfg): function optimizer_kwargs (line 166) | def optimizer_kwargs(cfg): function lr_scheduler_kwargs (line 183) | def lr_scheduler_kwargs(cfg): function engine_run_kwargs (line 192) | def engine_run_kwargs(cfg): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/OSNet_AIN/main.py function reset_config (line 23) | def reset_config(cfg, args): function main (line 34) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/OSNet_AIN/osnet_child.py class ConvLayer (line 9) | class ConvLayer(nn.Module): method __init__ (line 12) | def __init__( method forward (line 38) | def forward(self, x): class Conv1x1 (line 44) | class Conv1x1(nn.Module): method __init__ (line 47) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 61) | def forward(self, x): class Conv1x1Linear (line 67) | class Conv1x1Linear(nn.Module): method __init__ (line 70) | def __init__(self, in_channels, out_channels, stride=1, bn=True): method forward (line 79) | def forward(self, x): class Conv3x3 (line 86) | class Conv3x3(nn.Module): method __init__ (line 89) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 103) | def forward(self, x): class LightConv3x3 (line 109) | class LightConv3x3(nn.Module): method __init__ (line 115) | def __init__(self, in_channels, out_channels): method forward (line 132) | def forward(self, x): class LightConvStream (line 139) | class LightConvStream(nn.Module): method __init__ (line 142) | def __init__(self, in_channels, out_channels, depth): method forward (line 153) | def forward(self, x): class ChannelGate (line 160) | class ChannelGate(nn.Module): method __init__ (line 163) | def __init__( method forward (line 206) | def forward(self, x): class OSBlock (line 221) | class OSBlock(nn.Module): method __init__ (line 224) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 240) | def forward(self, x): class OSBlockINv1 (line 254) | class OSBlockINv1(nn.Module): method __init__ (line 257) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 274) | def forward(self, x): class OSBlockINv2 (line 289) | class OSBlockINv2(nn.Module): method __init__ (line 292) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 309) | def forward(self, x): class OSBlockINv3 (line 324) | class OSBlockINv3(nn.Module): method __init__ (line 327) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 345) | def forward(self, x): class OSNet (line 364) | class OSNet(nn.Module): method __init__ (line 373) | def __init__( method _make_layer (line 422) | def _make_layer(self, blocks, layer, in_channels, out_channels): method _construct_fc_layer (line 429) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 450) | def _init_params(self): method featuremaps (line 476) | def featuremaps(self, x): method forward (line 486) | def forward(self, x, return_featuremaps=False, **kwargs): function osnet_ain_x1_0 (line 508) | def osnet_ain_x1_0( function build_model (line 529) | def build_model(name, num_classes=100): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/OSNet_AIN/osnet_search.py class IBN (line 13) | class IBN(nn.Module): method __init__ (line 16) | def __init__(self, num_channels): method forward (line 24) | def forward(self, x): class ConvLayer (line 31) | class ConvLayer(nn.Module): method __init__ (line 34) | def __init__( method forward (line 60) | def forward(self, x): class Conv1x1 (line 66) | class Conv1x1(nn.Module): method __init__ (line 69) | def __init__( method forward (line 88) | def forward(self, x): class Conv1x1Linear (line 94) | class Conv1x1Linear(nn.Module): method __init__ (line 97) | def __init__(self, in_channels, out_channels, stride=1, bn=True): method forward (line 106) | def forward(self, x): class Conv3x3 (line 113) | class Conv3x3(nn.Module): method __init__ (line 116) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 130) | def forward(self, x): class LightConv3x3 (line 136) | class LightConv3x3(nn.Module): method __init__ (line 142) | def __init__(self, in_channels, out_channels): method forward (line 159) | def forward(self, x): class LightConvStream (line 166) | class LightConvStream(nn.Module): method __init__ (line 169) | def __init__(self, in_channels, out_channels, depth): method forward (line 180) | def forward(self, x): class ChannelGate (line 187) | class ChannelGate(nn.Module): method __init__ (line 190) | def __init__( method forward (line 233) | def forward(self, x): class OSBlock (line 248) | class OSBlock(nn.Module): method __init__ (line 251) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 267) | def forward(self, x): class OSBlockINv1 (line 281) | class OSBlockINv1(nn.Module): method __init__ (line 284) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 301) | def forward(self, x): class OSBlockINv2 (line 316) | class OSBlockINv2(nn.Module): method __init__ (line 319) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 336) | def forward(self, x): class OSBlockINv3 (line 351) | class OSBlockINv3(nn.Module): method __init__ (line 354) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 372) | def forward(self, x): class NASBlock (line 388) | class NASBlock(nn.Module): method __init__ (line 391) | def __init__(self, in_channels, out_channels, search_space=None): method build_child_graph (line 403) | def build_child_graph(self): method forward (line 413) | def forward(self, x, lmda=1.): class OSNet (line 433) | class OSNet(nn.Module): method __init__ (line 442) | def __init__( method _make_layer (line 488) | def _make_layer( method _construct_fc_layer (line 499) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method build_child_graph (line 520) | def build_child_graph(self): method featuremaps (line 532) | def featuremaps(self, x, lmda): method forward (line 545) | def forward(self, x, lmda=1., return_featuremaps=False): function osnet_nas (line 562) | def osnet_nas(num_classes=1000, loss='softmax', **kwargs): function build_model (line 578) | def build_model(name, num_classes=100): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/OSNet_AIN/softmax_nas.py class ImageSoftmaxNASEngine (line 8) | class ImageSoftmaxNASEngine(Engine): method __init__ (line 10) | def __init__( method forward_backward (line 44) | def forward_backward(self, data): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/datasets/__init__.py function init_dataset (line 8) | def init_dataset(name, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/datasets/dataset.py class Dataset (line 7) | class Dataset(object): method __init__ (line 9) | def __init__( method num_attrs (line 38) | def num_attrs(self): method attr_dict (line 42) | def attr_dict(self): method __len__ (line 45) | def __len__(self): method __getitem__ (line 48) | def __getitem__(self, index): method check_before_run (line 55) | def check_before_run(self, required_files): method show_summary (line 67) | def show_summary(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/datasets/pa100k.py class PA100K (line 9) | class PA100K(Dataset): method __init__ (line 22) | def __init__(self, root='', **kwargs): method extract_data (line 36) | def extract_data(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/default_parser.py function init_parser (line 5) | def init_parser(): function optimizer_kwargs (line 221) | def optimizer_kwargs(parsed_args): function lr_scheduler_kwargs (line 238) | def lr_scheduler_kwargs(parsed_args): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/main.py function init_dataset (line 31) | def init_dataset(use_gpu): function main (line 106) | def main(): function train (line 220) | def train(epoch, model, criterion, optimizer, scheduler, trainloader, us... function test (line 288) | def test(model, testloader, attr_dict, use_gpu): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/models/__init__.py function build_model (line 11) | def build_model(name, num_classes, pretrained=True, use_gpu=True): FILE: asone/trackers/strong_sort/tracker/deep/reid/projects/attribute_recognition/models/osnet.py class ConvLayer (line 12) | class ConvLayer(nn.Module): method __init__ (line 15) | def __init__( method forward (line 37) | def forward(self, x): class Conv1x1 (line 44) | class Conv1x1(nn.Module): method __init__ (line 47) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 61) | def forward(self, x): class Conv1x1Linear (line 68) | class Conv1x1Linear(nn.Module): method __init__ (line 71) | def __init__(self, in_channels, out_channels, stride=1): method forward (line 78) | def forward(self, x): class Conv3x3 (line 84) | class Conv3x3(nn.Module): method __init__ (line 87) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 101) | def forward(self, x): class LightConv3x3 (line 108) | class LightConv3x3(nn.Module): method __init__ (line 114) | def __init__(self, in_channels, out_channels): method forward (line 131) | def forward(self, x): class ChannelGate (line 142) | class ChannelGate(nn.Module): method __init__ (line 145) | def __init__( method forward (line 188) | def forward(self, x): class OSBlock (line 203) | class OSBlock(nn.Module): method __init__ (line 206) | def __init__(self, in_channels, out_channels, **kwargs): method forward (line 232) | def forward(self, x): class BaseNet (line 250) | class BaseNet(nn.Module): method _make_layer (line 252) | def _make_layer( method _construct_fc_layer (line 271) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method init_params (line 292) | def init_params(self): class OSNet (line 315) | class OSNet(BaseNet): method __init__ (line 317) | def __init__( method featuremaps (line 372) | def featuremaps(self, x): method forward (line 381) | def forward(self, x): function osnet_avgpool (line 393) | def osnet_avgpool(num_classes=1000, loss='softmax', **kwargs): function osnet_maxpool (line 405) | def osnet_maxpool(num_classes=1000, loss='softmax', **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/scripts/default_config.py function get_default_config (line 4) | def get_default_config(): function imagedata_kwargs (line 112) | def imagedata_kwargs(cfg): function videodata_kwargs (line 142) | def videodata_kwargs(cfg): function optimizer_kwargs (line 168) | def optimizer_kwargs(cfg): function lr_scheduler_kwargs (line 185) | def lr_scheduler_kwargs(cfg): function engine_run_kwargs (line 194) | def engine_run_kwargs(cfg): FILE: asone/trackers/strong_sort/tracker/deep/reid/scripts/main.py function build_datamanager (line 20) | def build_datamanager(cfg): function build_engine (line 27) | def build_engine(cfg, datamanager, model, optimizer, scheduler): function reset_config (line 80) | def reset_config(cfg, args): function check_cfg (line 91) | def check_cfg(cfg): function main (line 97) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/setup.py function readme (line 8) | def readme(): function find_version (line 14) | def find_version(): function numpy_include (line 21) | def numpy_include(): function get_requirements (line 38) | def get_requirements(filename='requirements.txt'): FILE: asone/trackers/strong_sort/tracker/deep/reid/tools/compute_mean_std.py function main (line 19) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/tools/parse_test_res.py function parse_file (line 32) | def parse_file(filepath, regex_mAP, regex_r1, regex_r5, regex_r10, regex... function main (line 69) | def main(args): FILE: asone/trackers/strong_sort/tracker/deep/reid/tools/visualize_actmap.py function visactmap (line 26) | def visactmap( function main (line 130) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datamanager.py class DataManager (line 9) | class DataManager(object): method __init__ (line 25) | def __init__( method num_train_pids (line 64) | def num_train_pids(self): method num_train_cams (line 69) | def num_train_cams(self): method fetch_test_loaders (line 73) | def fetch_test_loaders(self, name): method preprocess_pil_img (line 84) | def preprocess_pil_img(self, img): class ImageDataManager (line 89) | class ImageDataManager(DataManager): method __init__ (line 153) | def __init__( class VideoDataManager (line 350) | class VideoDataManager(DataManager): method __init__ (line 411) | def __init__( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/__init__.py function init_image_dataset (line 34) | def init_image_dataset(name, **kwargs): function init_video_dataset (line 45) | def init_video_dataset(name, **kwargs): function register_image_dataset (line 56) | def register_image_dataset(name, dataset): function register_video_dataset (line 89) | def register_video_dataset(name, dataset): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/dataset.py class Dataset (line 12) | class Dataset(object): method __init__ (line 42) | def __init__( method __getitem__ (line 95) | def __getitem__(self, index): method __len__ (line 98) | def __len__(self): method __add__ (line 101) | def __add__(self, other): method __radd__ (line 141) | def __radd__(self, other): method get_num_pids (line 148) | def get_num_pids(self, data): method get_num_cams (line 159) | def get_num_cams(self, data): method get_num_datasets (line 170) | def get_num_datasets(self, data): method show_summary (line 181) | def show_summary(self): method combine_all (line 185) | def combine_all(self): method download_dataset (line 214) | def download_dataset(self, dataset_dir, dataset_url): method check_before_run (line 256) | def check_before_run(self, required_files): method __repr__ (line 269) | def __repr__(self): method _transform_image (line 294) | def _transform_image(self, tfm, k_tfm, img0): class ImageDataset (line 310) | class ImageDataset(Dataset): method __init__ (line 321) | def __init__(self, train, query, gallery, **kwargs): method __getitem__ (line 324) | def __getitem__(self, index): method show_summary (line 338) | def show_summary(self): class VideoDataset (line 370) | class VideoDataset(Dataset): method __init__ (line 381) | def __init__( method __getitem__ (line 397) | def __getitem__(self, index): method show_summary (line 453) | def show_summary(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/cuhk01.py class CUHK01 (line 12) | class CUHK01(ImageDataset): method __init__ (line 30) | def __init__(self, root='', split_id=0, **kwargs): method extract_file (line 64) | def extract_file(self): method prepare_split (line 71) | def prepare_split(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/cuhk02.py class CUHK02 (line 8) | class CUHK02(ImageDataset): method __init__ (line 30) | def __init__(self, root='', **kwargs): method get_data_list (line 41) | def get_data_list(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/cuhk03.py class CUHK03 (line 9) | class CUHK03(ImageDataset): method __init__ (line 26) | def __init__( method preprocess_split (line 92) | def preprocess_split(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/cuhksysu.py class CUHKSYSU (line 9) | class CUHKSYSU(ImageDataset): method __init__ (line 26) | def __init__(self, root='', **kwargs): method process_dir (line 38) | def process_dir(self, dirname): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/dukemtmcreid.py class DukeMTMCreID (line 9) | class DukeMTMCreID(ImageDataset): method __init__ (line 26) | def __init__(self, root='', **kwargs): method process_dir (line 49) | def process_dir(self, dir_path, relabel=False): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/grid.py class GRID (line 11) | class GRID(ImageDataset): method __init__ (line 28) | def __init__(self, root='', split_id=0, **kwargs): method prepare_split (line 72) | def prepare_split(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/ilids.py class iLIDS (line 13) | class iLIDS(ImageDataset): method __init__ (line 27) | def __init__(self, root='', split_id=0, **kwargs): method prepare_split (line 52) | def prepare_split(self): method get_pid2label (line 109) | def get_pid2label(self, img_names): method parse_img_names (line 117) | def parse_img_names(self, img_names, pid2label=None): method process_split (line 130) | def process_split(self, split): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/market1501.py class Market1501 (line 10) | class Market1501(ImageDataset): method __init__ (line 26) | def __init__(self, root='', market1501_500k=False, **kwargs): method process_dir (line 64) | def process_dir(self, dir_path, relabel=False): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/msmt17.py class MSMT17 (line 25) | class MSMT17(ImageDataset): method __init__ (line 41) | def __init__(self, root='', **kwargs): method process_dir (line 85) | def process_dir(self, dir_path, list_path): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/prid.py class PRID (line 10) | class PRID(ImageDataset): method __init__ (line 29) | def __init__(self, root='', split_id=0, **kwargs): method prepare_split (line 59) | def prepare_split(self): method process_split (line 78) | def process_split(self, split): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/sensereid.py class SenseReID (line 9) | class SenseReID(ImageDataset): method __init__ (line 27) | def __init__(self, root='', **kwargs): method process_dir (line 60) | def process_dir(self, dir_path): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/university1652.py class University1652 (line 10) | class University1652(ImageDataset): method __init__ (line 52) | def __init__(self, root='', **kwargs): method process_dir (line 84) | def process_dir(self, dir_path, relabel=False, train=False): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/image/viper.py class VIPeR (line 11) | class VIPeR(ImageDataset): method __init__ (line 27) | def __init__(self, root='', split_id=0, **kwargs): method prepare_split (line 61) | def prepare_split(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/video/dukemtmcvidreid.py class DukeMTMCVidReID (line 11) | class DukeMTMCVidReID(VideoDataset): method __init__ (line 29) | def __init__(self, root='', min_seq_len=0, **kwargs): method process_dir (line 67) | def process_dir(self, dir_path, json_path, relabel): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/video/ilidsvid.py class iLIDSVID (line 11) | class iLIDSVID(VideoDataset): method __init__ (line 27) | def __init__(self, root='', split_id=0, **kwargs): method prepare_split (line 65) | def prepare_split(self): method process_data (line 122) | def process_data(self, dirnames, cam1=True, cam2=True): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/video/mars.py class Mars (line 9) | class Mars(VideoDataset): method __init__ (line 25) | def __init__(self, root='', **kwargs): method get_names (line 76) | def get_names(self, fpath): method process_data (line 84) | def process_data( method combine_all (line 129) | def combine_all(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/datasets/video/prid2011.py class PRID2011 (line 10) | class PRID2011(VideoDataset): method __init__ (line 27) | def __init__(self, root='', split_id=0, **kwargs): method process_dir (line 59) | def process_dir(self, dirnames, cam1=True, cam2=True): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/sampler.py class RandomIdentitySampler (line 14) | class RandomIdentitySampler(Sampler): method __init__ (line 23) | def __init__(self, data_source, batch_size, num_instances): method __iter__ (line 51) | def __iter__(self): method __len__ (line 81) | def __len__(self): class RandomDomainSampler (line 85) | class RandomDomainSampler(Sampler): method __init__ (line 100) | def __init__(self, data_source, batch_size, n_domain): method __iter__ (line 120) | def __iter__(self): method __len__ (line 142) | def __len__(self): class RandomDatasetSampler (line 146) | class RandomDatasetSampler(Sampler): method __init__ (line 159) | def __init__(self, data_source, batch_size, n_dataset): method __iter__ (line 179) | def __iter__(self): method __len__ (line 201) | def __len__(self): function build_train_sampler (line 205) | def build_train_sampler( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/data/transforms.py class Random2DTranslation (line 12) | class Random2DTranslation(object): method __init__ (line 28) | def __init__(self, height, width, p=0.5, interpolation=Image.BILINEAR): method __call__ (line 34) | def __call__(self, img): class RandomErasing (line 51) | class RandomErasing(object): method __init__ (line 68) | def __init__( method __call__ (line 82) | def __call__(self, img): class ColorAugmentation (line 109) | class ColorAugmentation(object): method __init__ (line 121) | def __init__(self, p=0.5): method _check_input (line 132) | def _check_input(self, tensor): method __call__ (line 135) | def __call__(self, tensor): class RandomPatch (line 144) | class RandomPatch(object): method __init__ (line 160) | def __init__( method generate_wh (line 183) | def generate_wh(self, W, H): method transform_patch (line 198) | def transform_patch(self, patch): method __call__ (line 205) | def __call__(self, img): function build_transforms (line 233) | def build_transforms( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/engine/engine.py class Engine (line 19) | class Engine(object): method __init__ (line 28) | def __init__(self, datamanager, use_gpu=True): method register_model (line 44) | def register_model(self, name='model', model=None, optim=None, sched=N... method get_model_names (line 64) | def get_model_names(self, names=None): method save_model (line 75) | def save_model(self, epoch, rank1, save_dir, is_best=False): method set_model_mode (line 91) | def set_model_mode(self, mode='train', names=None): method get_current_lr (line 101) | def get_current_lr(self, names=None): method update_lr (line 106) | def update_lr(self, names=None): method run (line 113) | def run( method train (line 230) | def train(self, print_freq=10, fixbase_epoch=0, open_layers=None): method forward_backward (line 289) | def forward_backward(self, data): method test (line 292) | def test( method _evaluate (line 345) | def _evaluate( method compute_loss (line 435) | def compute_loss(self, criterion, outputs, targets): method extract_features (line 442) | def extract_features(self, input): method parse_data_for_train (line 445) | def parse_data_for_train(self, data): method parse_data_for_eval (line 450) | def parse_data_for_eval(self, data): method two_stepped_transfer_learning (line 456) | def two_stepped_transfer_learning( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/engine/image/softmax.py class ImageSoftmaxEngine (line 9) | class ImageSoftmaxEngine(Engine): method __init__ (line 56) | def __init__( method forward_backward (line 78) | def forward_backward(self, data): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/engine/image/triplet.py class ImageTripletEngine (line 9) | class ImageTripletEngine(Engine): method __init__ (line 62) | def __init__( method forward_backward (line 93) | def forward_backward(self, data): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/engine/video/softmax.py class VideoSoftmaxEngine (line 7) | class VideoSoftmaxEngine(ImageSoftmaxEngine): method __init__ (line 60) | def __init__( method parse_data_for_train (line 80) | def parse_data_for_train(self, data): method extract_features (line 95) | def extract_features(self, input): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/engine/video/triplet.py class VideoTripletEngine (line 7) | class VideoTripletEngine(ImageTripletEngine): method __init__ (line 67) | def __init__( method parse_data_for_train (line 93) | def parse_data_for_train(self, data): method extract_features (line 108) | def extract_features(self, input): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/losses/__init__.py function DeepSupervision (line 7) | def DeepSupervision(criterion, xs, y): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/losses/cross_entropy_loss.py class CrossEntropyLoss (line 6) | class CrossEntropyLoss(nn.Module): method __init__ (line 29) | def __init__(self, num_classes, eps=0.1, use_gpu=True, label_smooth=Tr... method forward (line 36) | def forward(self, inputs, targets): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/losses/hard_mine_triplet_loss.py class TripletLoss (line 6) | class TripletLoss(nn.Module): method __init__ (line 18) | def __init__(self, margin=0.3): method forward (line 23) | def forward(self, inputs, targets): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/metrics/accuracy.py function accuracy (line 4) | def accuracy(output, target, topk=(1, )): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/metrics/distance.py function compute_distance_matrix (line 6) | def compute_distance_matrix(input1, input2, metric='euclidean'): function euclidean_squared_distance (line 49) | def euclidean_squared_distance(input1, input2): function cosine_distance (line 67) | def cosine_distance(input1, input2): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/metrics/rank.py function eval_cuhk03 (line 17) | def eval_cuhk03(distmat, q_pids, g_pids, q_camids, g_camids, max_rank): function eval_market1501 (line 94) | def eval_market1501(distmat, q_pids, g_pids, q_camids, g_camids, max_rank): function evaluate_py (line 156) | def evaluate_py( function evaluate_rank (line 169) | def evaluate_rank( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/metrics/rank_cylib/setup.py function numpy_include (line 7) | def numpy_include(): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/__init__.py function show_avai_models (line 81) | def show_avai_models(): function build_model (line 91) | def build_model( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/densenet.py class _DenseLayer (line 29) | class _DenseLayer(nn.Sequential): method __init__ (line 31) | def __init__(self, num_input_features, growth_rate, bn_size, drop_rate): method forward (line 60) | def forward(self, x): class _DenseBlock (line 69) | class _DenseBlock(nn.Sequential): method __init__ (line 71) | def __init__( class _Transition (line 83) | class _Transition(nn.Sequential): method __init__ (line 85) | def __init__(self, num_input_features, num_output_features): class DenseNet (line 102) | class DenseNet(nn.Module): method __init__ (line 116) | def __init__( method _construct_fc_layer (line 190) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 221) | def _init_params(self): method forward (line 240) | def forward(self, x): function init_pretrained_weights (line 262) | def init_pretrained_weights(model, model_url): function densenet121 (line 303) | def densenet121(num_classes, loss='softmax', pretrained=True, **kwargs): function densenet169 (line 319) | def densenet169(num_classes, loss='softmax', pretrained=True, **kwargs): function densenet201 (line 335) | def densenet201(num_classes, loss='softmax', pretrained=True, **kwargs): function densenet161 (line 351) | def densenet161(num_classes, loss='softmax', pretrained=True, **kwargs): function densenet121_fc512 (line 367) | def densenet121_fc512(num_classes, loss='softmax', pretrained=True, **kw... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/hacnn.py class ConvBlock (line 9) | class ConvBlock(nn.Module): method __init__ (line 22) | def __init__(self, in_c, out_c, k, s=1, p=0): method forward (line 27) | def forward(self, x): class InceptionA (line 31) | class InceptionA(nn.Module): method __init__ (line 33) | def __init__(self, in_channels, out_channels): method forward (line 54) | def forward(self, x): class InceptionB (line 63) | class InceptionB(nn.Module): method __init__ (line 65) | def __init__(self, in_channels, out_channels): method forward (line 83) | def forward(self, x): class SpatialAttn (line 91) | class SpatialAttn(nn.Module): method __init__ (line 94) | def __init__(self): method forward (line 99) | def forward(self, x): class ChannelAttn (line 115) | class ChannelAttn(nn.Module): method __init__ (line 118) | def __init__(self, in_channels, reduction_rate=16): method forward (line 124) | def forward(self, x): class SoftAttn (line 133) | class SoftAttn(nn.Module): method __init__ (line 141) | def __init__(self, in_channels): method forward (line 147) | def forward(self, x): class HardAttn (line 155) | class HardAttn(nn.Module): method __init__ (line 158) | def __init__(self, in_channels): method init_params (line 163) | def init_params(self): method forward (line 171) | def forward(self, x): class HarmAttn (line 180) | class HarmAttn(nn.Module): method __init__ (line 183) | def __init__(self, in_channels): method forward (line 188) | def forward(self, x): class HACNN (line 194) | class HACNN(nn.Module): method __init__ (line 210) | def __init__( method init_scale_factors (line 271) | def init_scale_factors(self): method stn (line 287) | def stn(self, x, theta): method transform_theta (line 297) | def transform_theta(self, theta_i, region_idx): method forward (line 307) | def forward(self, x): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/inceptionresnetv2.py class BasicConv2d (line 37) | class BasicConv2d(nn.Module): method __init__ (line 39) | def __init__(self, in_planes, out_planes, kernel_size, stride, padding... method forward (line 57) | def forward(self, x): class Mixed_5b (line 64) | class Mixed_5b(nn.Module): method __init__ (line 66) | def __init__(self): method forward (line 87) | def forward(self, x): class Block35 (line 96) | class Block35(nn.Module): method __init__ (line 98) | def __init__(self, scale=1.0): method forward (line 119) | def forward(self, x): class Mixed_6a (line 130) | class Mixed_6a(nn.Module): method __init__ (line 132) | def __init__(self): method forward (line 145) | def forward(self, x): class Block17 (line 153) | class Block17(nn.Module): method __init__ (line 155) | def __init__(self, scale=1.0): method forward (line 175) | def forward(self, x): class Mixed_7a (line 185) | class Mixed_7a(nn.Module): method __init__ (line 187) | def __init__(self): method forward (line 208) | def forward(self, x): class Block8 (line 217) | class Block8(nn.Module): method __init__ (line 219) | def __init__(self, scale=1.0, noReLU=False): method forward (line 241) | def forward(self, x): class InceptionResNetV2 (line 255) | class InceptionResNetV2(nn.Module): method __init__ (line 266) | def __init__(self, num_classes, loss='softmax', **kwargs): method load_imagenet_weights (line 309) | def load_imagenet_weights(self): method featuremaps (line 321) | def featuremaps(self, x): method forward (line 339) | def forward(self, x): function inceptionresnetv2 (line 357) | def inceptionresnetv2(num_classes, loss='softmax', pretrained=True, **kw... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/inceptionv4.py class BasicConv2d (line 37) | class BasicConv2d(nn.Module): method __init__ (line 39) | def __init__(self, in_planes, out_planes, kernel_size, stride, padding... method forward (line 57) | def forward(self, x): class Mixed_3a (line 64) | class Mixed_3a(nn.Module): method __init__ (line 66) | def __init__(self): method forward (line 71) | def forward(self, x): class Mixed_4a (line 78) | class Mixed_4a(nn.Module): method __init__ (line 80) | def __init__(self): method forward (line 95) | def forward(self, x): class Mixed_5a (line 102) | class Mixed_5a(nn.Module): method __init__ (line 104) | def __init__(self): method forward (line 109) | def forward(self, x): class Inception_A (line 116) | class Inception_A(nn.Module): method __init__ (line 118) | def __init__(self): method forward (line 138) | def forward(self, x): class Reduction_A (line 147) | class Reduction_A(nn.Module): method __init__ (line 149) | def __init__(self): method forward (line 161) | def forward(self, x): class Inception_B (line 169) | class Inception_B(nn.Module): method __init__ (line 171) | def __init__(self): method forward (line 206) | def forward(self, x): class Reduction_B (line 215) | class Reduction_B(nn.Module): method __init__ (line 217) | def __init__(self): method forward (line 237) | def forward(self, x): class Inception_C (line 245) | class Inception_C(nn.Module): method __init__ (line 247) | def __init__(self): method forward (line 279) | def forward(self, x): class InceptionV4 (line 300) | class InceptionV4(nn.Module): method __init__ (line 311) | def __init__(self, num_classes, loss, **kwargs): method forward (line 342) | def forward(self, x): function init_pretrained_weights (line 360) | def init_pretrained_weights(model, model_url): function inceptionv4 (line 376) | def inceptionv4(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/mlfn.py class MLFNBlock (line 16) | class MLFNBlock(nn.Module): method __init__ (line 18) | def __init__( method forward (line 64) | def forward(self, x): class MLFN (line 98) | class MLFN(nn.Module): method __init__ (line 109) | def __init__( method init_params (line 196) | def init_params(self): method forward (line 212) | def forward(self, x): function init_pretrained_weights (line 244) | def init_pretrained_weights(model, model_url): function mlfn (line 260) | def mlfn(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/mobilenetv2.py class ConvBlock (line 18) | class ConvBlock(nn.Module): method __init__ (line 33) | def __init__(self, in_c, out_c, k, s=1, p=0, g=1): method forward (line 40) | def forward(self, x): class Bottleneck (line 44) | class Bottleneck(nn.Module): method __init__ (line 46) | def __init__(self, in_channels, out_channels, expansion_factor, stride... method forward (line 59) | def forward(self, x): class MobileNetV2 (line 69) | class MobileNetV2(nn.Module): method __init__ (line 81) | def __init__( method _make_layer (line 128) | def _make_layer(self, block, t, c, n, s): method _construct_fc_layer (line 140) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 171) | def _init_params(self): method featuremaps (line 190) | def featuremaps(self, x): method forward (line 202) | def forward(self, x): function init_pretrained_weights (line 223) | def init_pretrained_weights(model, model_url): function mobilenetv2_x1_0 (line 239) | def mobilenetv2_x1_0(num_classes, loss, pretrained=True, **kwargs): function mobilenetv2_x1_4 (line 258) | def mobilenetv2_x1_4(num_classes, loss, pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/mudeep.py class ConvBlock (line 9) | class ConvBlock(nn.Module): method __init__ (line 22) | def __init__(self, in_c, out_c, k, s, p): method forward (line 27) | def forward(self, x): class ConvLayers (line 31) | class ConvLayers(nn.Module): method __init__ (line 34) | def __init__(self): method forward (line 40) | def forward(self, x): class MultiScaleA (line 47) | class MultiScaleA(nn.Module): method __init__ (line 50) | def __init__(self): method forward (line 67) | def forward(self, x): class Reduction (line 76) | class Reduction(nn.Module): method __init__ (line 79) | def __init__(self): method forward (line 89) | def forward(self, x): class MultiScaleB (line 97) | class MultiScaleB(nn.Module): method __init__ (line 100) | def __init__(self): method forward (line 120) | def forward(self, x): class Fusion (line 128) | class Fusion(nn.Module): method __init__ (line 131) | def __init__(self): method forward (line 142) | def forward(self, x1, x2, x3, x4): class MuDeep (line 151) | class MuDeep(nn.Module): method __init__ (line 162) | def __init__(self, num_classes, loss='softmax', **kwargs): method featuremaps (line 184) | def featuremaps(self, x): method forward (line 192) | def forward(self, x): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/nasnet.py class MaxPoolPad (line 52) | class MaxPoolPad(nn.Module): method __init__ (line 54) | def __init__(self): method forward (line 59) | def forward(self, x): class AvgPoolPad (line 66) | class AvgPoolPad(nn.Module): method __init__ (line 68) | def __init__(self, stride=2, padding=1): method forward (line 75) | def forward(self, x): class SeparableConv2d (line 82) | class SeparableConv2d(nn.Module): method __init__ (line 84) | def __init__( method forward (line 107) | def forward(self, x): class BranchSeparables (line 113) | class BranchSeparables(nn.Module): method __init__ (line 115) | def __init__( method forward (line 142) | def forward(self, x): class BranchSeparablesStem (line 157) | class BranchSeparablesStem(nn.Module): method __init__ (line 159) | def __init__( method forward (line 184) | def forward(self, x): class BranchSeparablesReduction (line 194) | class BranchSeparablesReduction(BranchSeparables): method __init__ (line 196) | def __init__( method forward (line 211) | def forward(self, x): class CellStem0 (line 223) | class CellStem0(nn.Module): method __init__ (line 225) | def __init__(self, stem_filters, num_filters=42): method forward (line 272) | def forward(self, x): class CellStem1 (line 300) | class CellStem1(nn.Module): method __init__ (line 302) | def __init__(self, stem_filters, num_filters): method forward (line 419) | def forward(self, x_conv0, x_stem_0): class FirstCell (line 458) | class FirstCell(nn.Module): method __init__ (line 460) | def __init__( method forward (line 536) | def forward(self, x, x_prev): class NormalCell (line 577) | class NormalCell(nn.Module): method __init__ (line 579) | def __init__( method forward (line 643) | def forward(self, x, x_prev): class ReductionCell0 (line 674) | class ReductionCell0(nn.Module): method __init__ (line 676) | def __init__( method forward (line 737) | def forward(self, x, x_prev): class ReductionCell1 (line 766) | class ReductionCell1(nn.Module): method __init__ (line 768) | def __init__( method forward (line 862) | def forward(self, x, x_prev): class NASNetAMobile (line 891) | class NASNetAMobile(nn.Module): method __init__ (line 902) | def __init__( method _init_params (line 1041) | def _init_params(self): method features (line 1060) | def features(self, input): method forward (line 1094) | def forward(self, input): function init_pretrained_weights (line 1110) | def init_pretrained_weights(model, model_url): function nasnetamobile (line 1126) | def nasnetamobile(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/osnet.py class ConvLayer (line 28) | class ConvLayer(nn.Module): method __init__ (line 31) | def __init__( method forward (line 57) | def forward(self, x): class Conv1x1 (line 64) | class Conv1x1(nn.Module): method __init__ (line 67) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 81) | def forward(self, x): class Conv1x1Linear (line 88) | class Conv1x1Linear(nn.Module): method __init__ (line 91) | def __init__(self, in_channels, out_channels, stride=1): method forward (line 98) | def forward(self, x): class Conv3x3 (line 104) | class Conv3x3(nn.Module): method __init__ (line 107) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 121) | def forward(self, x): class LightConv3x3 (line 128) | class LightConv3x3(nn.Module): method __init__ (line 134) | def __init__(self, in_channels, out_channels): method forward (line 151) | def forward(self, x): class ChannelGate (line 162) | class ChannelGate(nn.Module): method __init__ (line 165) | def __init__( method forward (line 208) | def forward(self, x): class OSBlock (line 223) | class OSBlock(nn.Module): method __init__ (line 226) | def __init__( method forward (line 262) | def forward(self, x): class OSNet (line 282) | class OSNet(nn.Module): method __init__ (line 291) | def __init__( method _make_layer (line 345) | def _make_layer( method _construct_fc_layer (line 370) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 391) | def _init_params(self): method featuremaps (line 413) | def featuremaps(self, x): method forward (line 422) | def forward(self, x, return_featuremaps=False): function init_pretrained_weights (line 441) | def init_pretrained_weights(model, key=''): function osnet_x1_0 (line 522) | def osnet_x1_0(num_classes=1000, pretrained=True, loss='softmax', **kwar... function osnet_x0_75 (line 537) | def osnet_x0_75(num_classes=1000, pretrained=True, loss='softmax', **kwa... function osnet_x0_5 (line 552) | def osnet_x0_5(num_classes=1000, pretrained=True, loss='softmax', **kwar... function osnet_x0_25 (line 567) | def osnet_x0_25(num_classes=1000, pretrained=True, loss='softmax', **kwa... function osnet_ibn_x1_0 (line 582) | def osnet_ibn_x1_0( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/osnet_ain.py class ConvLayer (line 26) | class ConvLayer(nn.Module): method __init__ (line 29) | def __init__( method forward (line 55) | def forward(self, x): class Conv1x1 (line 61) | class Conv1x1(nn.Module): method __init__ (line 64) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 78) | def forward(self, x): class Conv1x1Linear (line 84) | class Conv1x1Linear(nn.Module): method __init__ (line 87) | def __init__(self, in_channels, out_channels, stride=1, bn=True): method forward (line 96) | def forward(self, x): class Conv3x3 (line 103) | class Conv3x3(nn.Module): method __init__ (line 106) | def __init__(self, in_channels, out_channels, stride=1, groups=1): method forward (line 120) | def forward(self, x): class LightConv3x3 (line 126) | class LightConv3x3(nn.Module): method __init__ (line 132) | def __init__(self, in_channels, out_channels): method forward (line 149) | def forward(self, x): class LightConvStream (line 156) | class LightConvStream(nn.Module): method __init__ (line 159) | def __init__(self, in_channels, out_channels, depth): method forward (line 170) | def forward(self, x): class ChannelGate (line 177) | class ChannelGate(nn.Module): method __init__ (line 180) | def __init__( method forward (line 223) | def forward(self, x): class OSBlock (line 238) | class OSBlock(nn.Module): method __init__ (line 241) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 257) | def forward(self, x): class OSBlockINin (line 271) | class OSBlockINin(nn.Module): method __init__ (line 274) | def __init__(self, in_channels, out_channels, reduction=4, T=4, **kwar... method forward (line 291) | def forward(self, x): class OSNet (line 309) | class OSNet(nn.Module): method __init__ (line 318) | def __init__( method _make_layer (line 367) | def _make_layer(self, blocks, layer, in_channels, out_channels): method _construct_fc_layer (line 374) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 395) | def _init_params(self): method featuremaps (line 421) | def featuremaps(self, x): method forward (line 432) | def forward(self, x, return_featuremaps=False): function init_pretrained_weights (line 451) | def init_pretrained_weights(model, key=''): function osnet_ain_x1_0 (line 532) | def osnet_ain_x1_0( function osnet_ain_x0_75 (line 552) | def osnet_ain_x0_75( function osnet_ain_x0_5 (line 572) | def osnet_ain_x0_5( function osnet_ain_x0_25 (line 592) | def osnet_ain_x0_25( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/pcb.py function conv3x3 (line 17) | def conv3x3(in_planes, out_planes, stride=1): class BasicBlock (line 29) | class BasicBlock(nn.Module): method __init__ (line 32) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 42) | def forward(self, x): class Bottleneck (line 61) | class Bottleneck(nn.Module): method __init__ (line 64) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 85) | def forward(self, x): class DimReduceLayer (line 108) | class DimReduceLayer(nn.Module): method __init__ (line 110) | def __init__(self, in_channels, out_channels, nonlinear): method forward (line 127) | def forward(self, x): class PCB (line 131) | class PCB(nn.Module): method __init__ (line 143) | def __init__( method _make_layer (line 188) | def _make_layer(self, block, planes, blocks, stride=1): method _init_params (line 210) | def _init_params(self): method featuremaps (line 229) | def featuremaps(self, x): method forward (line 240) | def forward(self, x): function init_pretrained_weights (line 267) | def init_pretrained_weights(model, model_url): function pcb_p6 (line 283) | def pcb_p6(num_classes, loss='softmax', pretrained=True, **kwargs): function pcb_p4 (line 300) | def pcb_p4(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/resnet.py function conv3x3 (line 31) | def conv3x3(in_planes, out_planes, stride=1, groups=1, dilation=1): function conv1x1 (line 45) | def conv1x1(in_planes, out_planes, stride=1): class BasicBlock (line 52) | class BasicBlock(nn.Module): method __init__ (line 55) | def __init__( method forward (line 86) | def forward(self, x): class Bottleneck (line 105) | class Bottleneck(nn.Module): method __init__ (line 108) | def __init__( method forward (line 134) | def forward(self, x): class ResNet (line 157) | class ResNet(nn.Module): method __init__ (line 175) | def __init__( method _make_layer (line 257) | def _make_layer(self, block, planes, blocks, stride=1, dilate=False): method _construct_fc_layer (line 292) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 323) | def _init_params(self): method featuremaps (line 342) | def featuremaps(self, x): method forward (line 353) | def forward(self, x): function init_pretrained_weights (line 374) | def init_pretrained_weights(model, model_url): function resnet18 (line 393) | def resnet18(num_classes, loss='softmax', pretrained=True, **kwargs): function resnet34 (line 409) | def resnet34(num_classes, loss='softmax', pretrained=True, **kwargs): function resnet50 (line 425) | def resnet50(num_classes, loss='softmax', pretrained=True, **kwargs): function resnet101 (line 441) | def resnet101(num_classes, loss='softmax', pretrained=True, **kwargs): function resnet152 (line 457) | def resnet152(num_classes, loss='softmax', pretrained=True, **kwargs): function resnext50_32x4d (line 476) | def resnext50_32x4d(num_classes, loss='softmax', pretrained=True, **kwar... function resnext101_32x8d (line 494) | def resnext101_32x8d(num_classes, loss='softmax', pretrained=True, **kwa... function resnet50_fc512 (line 517) | def resnet50_fc512(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/resnet_ibn_a.py function conv3x3 (line 19) | def conv3x3(in_planes, out_planes, stride=1): class BasicBlock (line 31) | class BasicBlock(nn.Module): method __init__ (line 34) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 44) | def forward(self, x): class IBN (line 63) | class IBN(nn.Module): method __init__ (line 65) | def __init__(self, planes): method forward (line 73) | def forward(self, x): class Bottleneck (line 81) | class Bottleneck(nn.Module): method __init__ (line 84) | def __init__(self, inplanes, planes, ibn=False, stride=1, downsample=N... method forward (line 108) | def forward(self, x): class ResNet (line 131) | class ResNet(nn.Module): method __init__ (line 140) | def __init__( method _make_layer (line 183) | def _make_layer(self, block, planes, blocks, stride=1): method _construct_fc_layer (line 208) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method featuremaps (line 239) | def featuremaps(self, x): method forward (line 250) | def forward(self, x): function init_pretrained_weights (line 267) | def init_pretrained_weights(model, model_url): function resnet50_ibn_a (line 283) | def resnet50_ibn_a(num_classes, loss='softmax', pretrained=False, **kwar... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/resnet_ibn_b.py function conv3x3 (line 18) | def conv3x3(in_planes, out_planes, stride=1): class BasicBlock (line 30) | class BasicBlock(nn.Module): method __init__ (line 33) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 43) | def forward(self, x): class Bottleneck (line 62) | class Bottleneck(nn.Module): method __init__ (line 65) | def __init__(self, inplanes, planes, stride=1, downsample=None, IN=Fal... method forward (line 89) | def forward(self, x): class ResNet (line 114) | class ResNet(nn.Module): method __init__ (line 123) | def __init__( method _make_layer (line 170) | def _make_layer(self, block, planes, blocks, stride=1, IN=False): method _construct_fc_layer (line 193) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method featuremaps (line 224) | def featuremaps(self, x): method forward (line 235) | def forward(self, x): function init_pretrained_weights (line 252) | def init_pretrained_weights(model, model_url): function resnet50_ibn_b (line 268) | def resnet50_ibn_b(num_classes, loss='softmax', pretrained=False, **kwar... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/resnetmid.py function conv3x3 (line 17) | def conv3x3(in_planes, out_planes, stride=1): class BasicBlock (line 29) | class BasicBlock(nn.Module): method __init__ (line 32) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 42) | def forward(self, x): class Bottleneck (line 61) | class Bottleneck(nn.Module): method __init__ (line 64) | def __init__(self, inplanes, planes, stride=1, downsample=None): method forward (line 85) | def forward(self, x): class ResNetMid (line 108) | class ResNetMid(nn.Module): method __init__ (line 119) | def __init__( method _make_layer (line 158) | def _make_layer(self, block, planes, blocks, stride=1): method _construct_fc_layer (line 180) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 211) | def _init_params(self): method featuremaps (line 230) | def featuremaps(self, x): method forward (line 243) | def forward(self, x): function init_pretrained_weights (line 268) | def init_pretrained_weights(model, model_url): function resnet50mid (line 295) | def resnet50mid(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/senet.py class SEModule (line 91) | class SEModule(nn.Module): method __init__ (line 93) | def __init__(self, channels, reduction): method forward (line 105) | def forward(self, x): class Bottleneck (line 115) | class Bottleneck(nn.Module): method forward (line 120) | def forward(self, x): class SEBottleneck (line 143) | class SEBottleneck(Bottleneck): method __init__ (line 149) | def __init__( class SEResNetBottleneck (line 175) | class SEResNetBottleneck(Bottleneck): method __init__ (line 183) | def __init__( class SEResNeXtBottleneck (line 208) | class SEResNeXtBottleneck(Bottleneck): method __init__ (line 212) | def __init__( class SENet (line 246) | class SENet(nn.Module): method __init__ (line 262) | def __init__( method _make_layer (line 416) | def _make_layer( method _construct_fc_layer (line 453) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method featuremaps (line 485) | def featuremaps(self, x): method forward (line 493) | def forward(self, x): function init_pretrained_weights (line 514) | def init_pretrained_weights(model, model_url): function senet154 (line 530) | def senet154(num_classes, loss='softmax', pretrained=True, **kwargs): function se_resnet50 (line 549) | def se_resnet50(num_classes, loss='softmax', pretrained=True, **kwargs): function se_resnet50_fc512 (line 572) | def se_resnet50_fc512(num_classes, loss='softmax', pretrained=True, **kw... function se_resnet101 (line 595) | def se_resnet101(num_classes, loss='softmax', pretrained=True, **kwargs): function se_resnet152 (line 618) | def se_resnet152(num_classes, loss='softmax', pretrained=True, **kwargs): function se_resnext50_32x4d (line 641) | def se_resnext50_32x4d(num_classes, loss='softmax', pretrained=True, **k... function se_resnext101_32x4d (line 665) | def se_resnext101_32x4d( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/shufflenet.py class ChannelShuffle (line 16) | class ChannelShuffle(nn.Module): method __init__ (line 18) | def __init__(self, num_groups): method forward (line 22) | def forward(self, x): class Bottleneck (line 34) | class Bottleneck(nn.Module): method __init__ (line 36) | def __init__( method forward (line 78) | def forward(self, x): class ShuffleNet (line 101) | class ShuffleNet(nn.Module): method __init__ (line 112) | def __init__(self, num_classes, loss='softmax', num_groups=3, **kwargs): method forward (line 153) | def forward(self, x): function init_pretrained_weights (line 173) | def init_pretrained_weights(model, model_url): function shufflenet (line 189) | def shufflenet(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/shufflenetv2.py function channel_shuffle (line 24) | def channel_shuffle(x, groups): class InvertedResidual (line 39) | class InvertedResidual(nn.Module): method __init__ (line 41) | def __init__(self, inp, oup, stride): method depthwise_conv (line 101) | def depthwise_conv(i, o, kernel_size, stride=1, padding=0, bias=False): method forward (line 106) | def forward(self, x): class ShuffleNetV2 (line 118) | class ShuffleNetV2(nn.Module): method __init__ (line 131) | def __init__( method featuremaps (line 180) | def featuremaps(self, x): method forward (line 189) | def forward(self, x): function init_pretrained_weights (line 207) | def init_pretrained_weights(model, model_url): function shufflenet_v2_x0_5 (line 229) | def shufflenet_v2_x0_5(num_classes, loss='softmax', pretrained=True, **k... function shufflenet_v2_x1_0 (line 238) | def shufflenet_v2_x1_0(num_classes, loss='softmax', pretrained=True, **k... function shufflenet_v2_x1_5 (line 247) | def shufflenet_v2_x1_5(num_classes, loss='softmax', pretrained=True, **k... function shufflenet_v2_x2_0 (line 256) | def shufflenet_v2_x2_0(num_classes, loss='softmax', pretrained=True, **k... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/squeezenet.py class Fire (line 19) | class Fire(nn.Module): method __init__ (line 21) | def __init__( method forward (line 37) | def forward(self, x): class SqueezeNet (line 47) | class SqueezeNet(nn.Module): method __init__ (line 60) | def __init__( method _construct_fc_layer (line 118) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 149) | def _init_params(self): method forward (line 168) | def forward(self, x): function init_pretrained_weights (line 189) | def init_pretrained_weights(model, model_url): function squeezenet1_0 (line 205) | def squeezenet1_0(num_classes, loss='softmax', pretrained=True, **kwargs): function squeezenet1_0_fc512 (line 214) | def squeezenet1_0_fc512( function squeezenet1_1 (line 230) | def squeezenet1_1(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/models/xception.py class SeparableConv2d (line 26) | class SeparableConv2d(nn.Module): method __init__ (line 28) | def __init__( method forward (line 54) | def forward(self, x): class Block (line 60) | class Block(nn.Module): method __init__ (line 62) | def __init__( method forward (line 132) | def forward(self, inp): class Xception (line 145) | class Xception(nn.Module): method __init__ (line 156) | def __init__( method _construct_fc_layer (line 221) | def _construct_fc_layer(self, fc_dims, input_dim, dropout_p=None): method _init_params (line 252) | def _init_params(self): method featuremaps (line 271) | def featuremaps(self, input): method forward (line 302) | def forward(self, x): function init_pretrained_weights (line 323) | def init_pretrained_weights(model, model_url): function xception (line 339) | def xception(num_classes, loss='softmax', pretrained=True, **kwargs): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/optim/lr_scheduler.py function build_lr_scheduler (line 7) | def build_lr_scheduler( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/optim/optimizer.py function build_optimizer (line 11) | def build_optimizer( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/optim/radam.py class RAdam (line 19) | class RAdam(Optimizer): method __init__ (line 21) | def __init__( method __setstate__ (line 48) | def __setstate__(self, state): method step (line 51) | def step(self, closure=None): class PlainRAdam (line 134) | class PlainRAdam(Optimizer): method __init__ (line 136) | def __init__( method __setstate__ (line 163) | def __setstate__(self, state): method step (line 166) | def step(self, closure=None): class AdamW (line 233) | class AdamW(Optimizer): method __init__ (line 235) | def __init__( method __setstate__ (line 266) | def __setstate__(self, state): method step (line 269) | def step(self, closure=None): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/GPU-Re-Ranking/extension/adjacency_matrix/build_adjacency_matrix.cpp function build_adjacency_matrix (line 12) | at::Tensor build_adjacency_matrix(at::Tensor initial_rank) { function PYBIND11_MODULE (line 17) | PYBIND11_MODULE(TORCH_EXTENSION_NAME, m) { FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/GPU-Re-Ranking/extension/propagation/gnn_propagate.cpp function gnn_propagate (line 12) | at::Tensor gnn_propagate(at::Tensor A ,at::Tensor initial_rank, at::Tens... function PYBIND11_MODULE (line 19) | PYBIND11_MODULE(TORCH_EXTENSION_NAME, m) { FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/GPU-Re-Ranking/gnn_reranking.py function gnn_reranking (line 27) | def gnn_reranking(X_q, X_g, k1, k2): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/GPU-Re-Ranking/main.py function main (line 52) | def main(): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/GPU-Re-Ranking/utils.py function load_pickle (line 25) | def load_pickle(pickle_path): function save_pickle (line 31) | def save_pickle(pickle_path, data): function pairwise_squared_distance (line 36) | def pairwise_squared_distance(x): function pairwise_distance (line 45) | def pairwise_distance(x, y): function cosine_similarity (line 61) | def cosine_similarity(x, y): function evaluate_ranking_list (line 73) | def evaluate_ranking_list( function evaluate (line 97) | def evaluate(index, ql, qc, gl, gc): function compute_mAP (line 110) | def compute_mAP(index, good_index, junk_index): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/avgmeter.py class AverageMeter (line 8) | class AverageMeter(object): method __init__ (line 18) | def __init__(self): method reset (line 21) | def reset(self): method update (line 27) | def update(self, val, n=1): class MetricMeter (line 34) | class MetricMeter(object): method __init__ (line 49) | def __init__(self, delimiter='\t'): method update (line 53) | def update(self, input_dict): method __str__ (line 67) | def __str__(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/feature_extractor.py class FeatureExtractor (line 13) | class FeatureExtractor(object): method __init__ (line 59) | def __init__( method __call__ (line 109) | def __call__(self, input): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/loggers.py class Logger (line 11) | class Logger(object): method __init__ (line 29) | def __init__(self, fpath=None): method __del__ (line 36) | def __del__(self): method __enter__ (line 39) | def __enter__(self): method __exit__ (line 42) | def __exit__(self, *args): method write (line 45) | def write(self, msg): method flush (line 50) | def flush(self): method close (line 56) | def close(self): class RankLogger (line 62) | class RankLogger(object): method __init__ (line 108) | def __init__(self, sources, targets): method write (line 126) | def write(self, name, epoch, rank1): method show_summary (line 137) | def show_summary(self): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/model_complexity.py function _ntuple (line 14) | def _ntuple(n): function hook_convNd (line 32) | def hook_convNd(m, x, y): function hook_maxpool1d (line 47) | def hook_maxpool1d(m, x, y): function hook_maxpool2d (line 53) | def hook_maxpool2d(m, x, y): function hook_maxpool3d (line 62) | def hook_maxpool3d(m, x, y): function hook_avgpool1d (line 70) | def hook_avgpool1d(m, x, y): function hook_avgpool2d (line 76) | def hook_avgpool2d(m, x, y): function hook_avgpool3d (line 84) | def hook_avgpool3d(m, x, y): function hook_adapmaxpool1d (line 92) | def hook_adapmaxpool1d(m, x, y): function hook_adapmaxpool2d (line 101) | def hook_adapmaxpool2d(m, x, y): function hook_adapmaxpool3d (line 111) | def hook_adapmaxpool3d(m, x, y): function hook_adapavgpool1d (line 121) | def hook_adapavgpool1d(m, x, y): function hook_adapavgpool2d (line 130) | def hook_adapavgpool2d(m, x, y): function hook_adapavgpool3d (line 140) | def hook_adapavgpool3d(m, x, y): function hook_relu (line 155) | def hook_relu(m, x, y): function hook_leakyrelu (line 161) | def hook_leakyrelu(m, x, y): function hook_batchnormNd (line 173) | def hook_batchnormNd(m, x, y): function hook_instancenormNd (line 181) | def hook_instancenormNd(m, x, y): function hook_groupnorm (line 185) | def hook_groupnorm(m, x, y): function hook_layernorm (line 189) | def hook_layernorm(m, x, y): function hook_linear (line 202) | def hook_linear(m, x, y): function _get_flops_counter (line 255) | def _get_flops_counter(only_conv_linear): function compute_model_complexity (line 261) | def compute_model_complexity( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/reidtools.py function visualize_ranked_results (line 18) | def visualize_ranked_results( FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/rerank.py function re_ranking (line 31) | def re_ranking(q_g_dist, q_q_dist, g_g_dist, k1=20, k2=6, lambda_value=0... FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/tools.py function mkdir_if_missing (line 22) | def mkdir_if_missing(dirname): function check_isfile (line 32) | def check_isfile(fpath): function read_json (line 47) | def read_json(fpath): function write_json (line 54) | def write_json(obj, fpath): function set_random_seed (line 61) | def set_random_seed(seed): function download_url (line 68) | def download_url(url, dst): function read_image (line 98) | def read_image(path): function collect_env_info (line 122) | def collect_env_info(): function listdir_nohidden (line 133) | def listdir_nohidden(path, sort=False): FILE: asone/trackers/strong_sort/tracker/deep/reid/torchreid/utils/torchtools.py function save_checkpoint (line 20) | def save_checkpoint( function load_checkpoint (line 61) | def load_checkpoint(fpath): function resume_from_checkpoint (line 98) | def resume_from_checkpoint(fpath, model, optimizer=None, scheduler=None): function adjust_learning_rate (line 137) | def adjust_learning_rate( function set_bn_to_eval (line 163) | def set_bn_to_eval(m): function open_all_layers (line 172) | def open_all_layers(model): function open_specified_layers (line 184) | def open_specified_layers(model, open_layers): function count_num_param (line 225) | def count_num_param(model): function load_pretrained_weights (line 257) | def load_pretrained_weights(model, weight_path): FILE: asone/trackers/strong_sort/tracker/deep/reid_model_factory.py function show_downloadeable_models (line 98) | def show_downloadeable_models(): function get_model_url (line 103) | def get_model_url(model): function is_model_in_model_types (line 111) | def is_model_in_model_types(model): function get_model_name (line 119) | def get_model_name(model): FILE: asone/trackers/strong_sort/tracker/sort/detection.py class Detection (line 5) | class Detection(object): method __init__ (line 29) | def __init__(self, tlwh, confidence, feature): method to_tlbr (line 34) | def to_tlbr(self): method to_xyah (line 42) | def to_xyah(self): FILE: asone/trackers/strong_sort/tracker/sort/iou_matching.py function iou (line 7) | def iou(bbox, candidates): function iou_cost (line 42) | def iou_cost(tracks, detections, track_indices=None, FILE: asone/trackers/strong_sort/tracker/sort/kalman_filter.py class KalmanFilter (line 21) | class KalmanFilter(object): method __init__ (line 33) | def __init__(self): method initiate (line 49) | def initiate(self, measurement): method predict (line 79) | def predict(self, mean, covariance): method project (line 113) | def project(self, mean, covariance, confidence=.0): method update (line 144) | def update(self, mean, covariance, measurement, confidence=.0): method gating_distance (line 176) | def gating_distance(self, mean, covariance, measurements, FILE: asone/trackers/strong_sort/tracker/sort/linear_assignment.py function min_cost_matching (line 11) | def min_cost_matching( function matching_cascade (line 75) | def matching_cascade( function gate_cost_matrix (line 131) | def gate_cost_matrix( FILE: asone/trackers/strong_sort/tracker/sort/nn_matching.py function _pdist (line 8) | def _pdist(a, b): function _cosine_distance (line 31) | def _cosine_distance(a, b, data_is_normalized=False): function _nn_euclidean_distance (line 54) | def _nn_euclidean_distance(x, y): function _nn_cosine_distance (line 74) | def _nn_cosine_distance(x, y): class NearestNeighborDistanceMetric (line 95) | class NearestNeighborDistanceMetric(object): method __init__ (line 116) | def __init__(self, metric, matching_threshold, budget=None): method partial_fit (line 127) | def partial_fit(self, features, targets, active_targets): method distance (line 144) | def distance(self, features, targets): FILE: asone/trackers/strong_sort/tracker/sort/preprocessing.py function non_max_suppression (line 6) | def non_max_suppression(boxes, max_bbox_overlap, scores=None): FILE: asone/trackers/strong_sort/tracker/sort/track.py class TrackState (line 7) | class TrackState: class Track (line 22) | class Track: method __init__ (line 69) | def __init__(self, detection, track_id, class_id, conf, n_init, max_ag... method to_tlwh (line 91) | def to_tlwh(self): method to_tlbr (line 106) | def to_tlbr(self): method ECC (line 121) | def ECC(self, src, dst, warp_mode = cv2.MOTION_EUCLIDEAN, eps = 1e-5, method get_matrix (line 220) | def get_matrix(self, matrix): method camera_update (line 228) | def camera_update(self, previous_frame, next_frame): method increment_age (line 245) | def increment_age(self): method predict (line 249) | def predict(self, kf): method update (line 263) | def update(self, detection, class_id, conf): method mark_missed (line 286) | def mark_missed(self): method is_tentative (line 294) | def is_tentative(self): method is_confirmed (line 299) | def is_confirmed(self): method is_deleted (line 303) | def is_deleted(self): FILE: asone/trackers/strong_sort/tracker/sort/tracker.py class Tracker (line 10) | class Tracker: method __init__ (line 38) | def __init__(self, metric, max_iou_distance=0.9, max_age=30, n_init=3,... method predict (line 51) | def predict(self): method increment_ages (line 59) | def increment_ages(self): method camera_update (line 64) | def camera_update(self, previous_img, current_img): method update (line 68) | def update(self, detections, classes, confidences): method _full_cost_metric (line 101) | def _full_cost_metric(self, tracks, dets, track_indices, detection_ind... method _match (line 135) | def _match(self, detections): method _initiate_track (line 173) | def _initiate_track(self, detection, class_id, conf): FILE: asone/trackers/strong_sort/tracker/strong_sort.py function xyxy2xywh (line 17) | def xyxy2xywh(x): class StrongSORT (line 26) | class StrongSORT(object): method __init__ (line 27) | def __init__(self, method update (line 61) | def update(self, bbox_xywh, confs, classes, ori_img): method _xywh_to_tlwh (line 104) | def _xywh_to_tlwh(bbox_xywh): method _xywh_to_xyxy (line 113) | def _xywh_to_xyxy(self, bbox_xywh): method _tlwh_to_xyxy (line 121) | def _tlwh_to_xyxy(self, bbox_tlwh): method increment_ages (line 134) | def increment_ages(self): method _xyxy_to_tlwh (line 137) | def _xyxy_to_tlwh(self, bbox_xyxy): method _get_features (line 146) | def _get_features(self, bbox_xywh, ori_img): FILE: asone/trackers/strong_sort/tracker/utils/asserts.py function assert_in (line 4) | def assert_in(file, files_to_check): function assert_in_env (line 10) | def assert_in_env(check_list: list): FILE: asone/trackers/strong_sort/tracker/utils/draw.py function compute_color_for_labels (line 7) | def compute_color_for_labels(label): function draw_boxes (line 15) | def draw_boxes(img, bbox, identities=None, offset=(0,0)): FILE: asone/trackers/strong_sort/tracker/utils/evaluation.py class Evaluator (line 9) | class Evaluator(object): method __init__ (line 11) | def __init__(self, data_root, seq_name, data_type): method load_annotations (line 19) | def load_annotations(self): method reset_accumulator (line 26) | def reset_accumulator(self): method eval_frame (line 29) | def eval_frame(self, frame_id, trk_tlwhs, trk_ids, rtn_events=False): method eval_file (line 69) | def eval_file(self, filename): method get_summary (line 82) | def get_summary(accs, names, metrics=('mota', 'num_switches', 'idp', '... method save_summary (line 99) | def save_summary(summary, filename): FILE: asone/trackers/strong_sort/tracker/utils/io.py function write_results (line 8) | def write_results(filename, results, data_type): function read_results (line 57) | def read_results(filename, data_type: str, is_gt=False, is_ignore=False): function read_mot_results (line 84) | def read_mot_results(filename, is_gt, is_ignore): function unzip_objs (line 126) | def unzip_objs(objs): FILE: asone/trackers/strong_sort/tracker/utils/json_logger.py class JsonMeta (line 11) | class JsonMeta(object): class BaseJsonLogger (line 19) | class BaseJsonLogger(object): method dic (line 26) | def dic(self): method list (line 39) | def list(values): class Label (line 44) | class Label(BaseJsonLogger): method __init__ (line 49) | def __init__(self, category: str, confidence: float): class Bbox (line 54) | class Bbox(BaseJsonLogger): method __init__ (line 77) | def __init__(self, bbox_id, top, left, width, height): method add_label (line 85) | def add_label(self, category, confidence): method labels_full (line 89) | def labels_full(self, value): class Frame (line 93) | class Frame(BaseJsonLogger): method __init__ (line 110) | def __init__(self, frame_id: int, timestamp: float = None): method add_bbox (line 115) | def add_bbox(self, bbox_id: int, top: int, left: int, width: int, heig... method add_label_to_bbox (line 122) | def add_label_to_bbox(self, bbox_id: int, category: str, confidence: f... class BboxToJsonLogger (line 131) | class BboxToJsonLogger(BaseJsonLogger): method __init__ (line 175) | def __init__(self, top_k_labels: int = 1): method set_top_k (line 182) | def set_top_k(self, value): method frame_exists (line 185) | def frame_exists(self, frame_id: int) -> bool: method add_frame (line 195) | def add_frame(self, frame_id: int, timestamp: float = None) -> None: method bbox_exists (line 213) | def bbox_exists(self, frame_id: int, bbox_id: int) -> bool: method find_bbox (line 227) | def find_bbox(self, frame_id: int, bbox_id: int): method add_bbox_to_frame (line 245) | def add_bbox_to_frame(self, frame_id: int, bbox_id: int, top: int, lef... method add_label_to_bbox (line 273) | def add_label_to_bbox(self, frame_id: int, bbox_id: int, category: str... method add_video_details (line 293) | def add_video_details(self, frame_width: int = None, frame_height: int... method output (line 300) | def output(self): method json_output (line 306) | def json_output(self, output_name): method set_start (line 323) | def set_start(self): method schedule_output_by_time (line 326) | def schedule_output_by_time(self, output_dir=JsonMeta.PATH_TO_SAVE, ho... method schedule_output_by_frames (line 358) | def schedule_output_by_frames(self, frames_quota, frame_counter, outpu... method flush (line 368) | def flush(self, output_dir): FILE: asone/trackers/strong_sort/tracker/utils/log.py function get_logger (line 4) | def get_logger(name='root'): FILE: asone/trackers/strong_sort/tracker/utils/parser.py class YamlParser (line 6) | class YamlParser(edict): method __init__ (line 11) | def __init__(self, cfg_dict=None, config_file=None): method merge_from_file (line 23) | def merge_from_file(self, config_file): method merge_from_dict (line 28) | def merge_from_dict(self, config_dict): function get_config (line 32) | def get_config(config_file=None): FILE: asone/trackers/strong_sort/tracker/utils/tools.py function is_video (line 5) | def is_video(ext: str): function tik_tok (line 21) | def tik_tok(func): FILE: asone/trackers/tracker.py class Tracker (line 9) | class Tracker: method __init__ (line 10) | def __init__(self, tracker: int, detector: object, use_cuda=True) -> N... method _select_tracker (line 23) | def _select_tracker(self, tracker, detector, use_cuda): method detect_and_track (line 34) | def detect_and_track(self, image, config: dict): method get_tracker (line 38) | def get_tracker(self): FILE: asone/utils/classes.py function get_names (line 17) | def get_names(): FILE: asone/utils/colors.py function compute_color_for_labels (line 10) | def compute_color_for_labels(label): FILE: asone/utils/counting.py function estimateSpeed (line 3) | def estimateSpeed(location1, location2): function intersect (line 16) | def intersect(A, B, C, D): function ccw (line 20) | def ccw(A, B, C): FILE: asone/utils/download.py function exractfile (line 6) | def exractfile(file, dest): function download_weights (line 11) | def download_weights(weights): FILE: asone/utils/draw.py function draw_ui_box (line 13) | def draw_ui_box(x, img, label=None, color=None, line_thickness=None): function draw_border (line 34) | def draw_border(img, pt1, pt2, color, thickness, r, d): function draw_boxes (line 64) | def draw_boxes(img, bbox_xyxy, class_ids, identities=None, draw_trails=F... function drawtrails (line 110) | def drawtrails(data_deque, id, color, img): function draw_text (line 123) | def draw_text(img, results, offset=(0, 0), display: bool = False): class Colors (line 144) | class Colors: method __init__ (line 146) | def __init__(self): method __call__ (line 158) | def __call__(self, i, bgr=False): method hex2rgb (line 164) | def hex2rgb(h): # rgb order (PIL) function draw_kpts (line 171) | def draw_kpts(keypoints, image=None, shape=(640, 640), radius=5, kpt_lin... function plot_skeleton_kpts (line 227) | def plot_skeleton_kpts(im, kpts, steps, orig_shape=None): FILE: asone/utils/ponits_conversion.py function xyxy_to_xywh (line 1) | def xyxy_to_xywh(xyxy): function tlwh_to_xyxy (line 14) | def tlwh_to_xyxy(tlwh): function xyxy_to_tlwh (line 23) | def xyxy_to_tlwh(bbox_xyxy): FILE: asone/utils/pose_estimators_weights.py function get_weight_path (line 20) | def get_weight_path(model_flag): FILE: asone/utils/temp_loader.py function get_detector (line 19) | def get_detector(detector, use_cuda=True, use_onnx=False): function get_tracker (line 28) | def get_tracker(tracker, detector, use_cuda=True, use_onnx=False): FILE: asone/utils/utils.py class PathResolver (line 6) | class PathResolver: method __init__ (line 7) | def __init__(self, path: str = None) -> None: method __enter__ (line 16) | def __enter__(self): method __exit__ (line 19) | def __exit__(self, exc_type, exc_value, traceback): FILE: asone/utils/video_reader.py class VideoReader (line 4) | class VideoReader: method __init__ (line 5) | def __init__( method __len__ (line 20) | def __len__(self): method frame_counts (line 24) | def frame_counts(self): method fps (line 28) | def fps(self): method frame_size (line 32) | def frame_size(self): method __iter__ (line 38) | def __iter__(self): FILE: main.py function main (line 8) | def main(args): FILE: setup.py function setup_package (line 20) | def setup_package():