Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/AhmedZgaren/Save
/ functions
Functions
163 in github.com/AhmedZgaren/Save
⨍
Functions
163
◇
Types & classes
40
↓ 15 callers
Method
to
Sends the model to the given device. Args: device (str): device
model/backbone.py:201
↓ 12 callers
Method
info
Prints model information Args: verbose (bool): if True, prints out the model information. Defaults to False
utils/tasks.py:137
↓ 6 callers
Method
__init__
(self, inplace: bool = False)
model/activations.py:39
↓ 4 callers
Method
__init__
(self, inplace: bool = False)
model/activations_jit.py:41
↓ 4 callers
Method
__init__
(self, inplace: bool = False)
model/activations_me.py:89
↓ 4 callers
Method
_check_is_pytorch_model
Raises TypeError is model is not a PyTorch model
model/backbone.py:153
↓ 4 callers
Function
guess_model_task
(model)
utils/tasks.py:470
↓ 4 callers
Function
is_no_jit
()
model/config.py:25
↓ 4 callers
Method
load
Load the weights into the model. Args: weights (dict) or (torch.nn.Module): The pre-trained weights to be loaded.
utils/tasks.py:166
↓ 4 callers
Function
random_crop_savebboxes
Implement random crop image image_name: for example img_0.jpg image_dir: original image directory label_dir: orri
utils/augment.py:26
↓ 3 callers
Function
GET_BLOCKS
(N)
model/aggregation_zeropad.py:17
↓ 3 callers
Method
_forward_once
Perform a forward pass through the network. Args: x (torch.Tensor): The input tensor to the model profi
utils/tasks.py:50
↓ 3 callers
Function
aggregation_zeropad
(input, weight, kernel_size=3, stride=1, padding=0, dilation=1)
model/aggregation_zeropad.py:188
↓ 3 callers
Function
load_kernel
(kernel_name, code, **kwargs)
model/utils.py:15
↓ 2 callers
Function
Dtype
(t)
model/utils.py:8
↓ 2 callers
Method
__init__
(self, d_model,h, d_ff, num_layers, enc_in, drop = 0.1)
model/transformer.py:15
↓ 2 callers
Function
attempt_load_one_weight
Loads a single model weights.
utils/tasks.py:335
↓ 2 callers
Method
forward
Run forward pass on input image(s) with optional augmentation and profiling.
utils/tasks.py:213
↓ 2 callers
Method
fuse
Fuse the `Conv2d()` and `BatchNorm2d()` layers of the model into a single layer, in order to improve the computation efficiency.
utils/tasks.py:99
↓ 2 callers
Function
get_act_layer
Activation Layer Factory Fetching activation layers by name with this function allows export or torch script friendly functions to be returne
model/create_act.py:108
↓ 2 callers
Function
is_exportable
()
model/config.py:44
↓ 2 callers
Function
is_scriptable
()
model/config.py:63
↓ 2 callers
Function
letterbox
Resize and pad image while meeting stride-multiple constraints.
utils/utils.py:157
↓ 2 callers
Function
torch_safe_load
This function attempts to load a PyTorch model with the torch.load() function. If a ModuleNotFoundError is raised, it catches the error, lo
utils/tasks.py:260
↓ 2 callers
Function
yaml_model_load
Load a YOLOv8 model from a YAML file.
utils/tasks.py:438
↓ 1 callers
Method
__init__
(self, nc=80, ch=())
utils/tasks.py:499
↓ 1 callers
Method
_clip_augmented
Clip YOLOv5 augmented inference tails.
utils/tasks.py:245
↓ 1 callers
Method
_descale_pred
De-scale predictions following augmented inference (inverse operation).
utils/tasks.py:235
↓ 1 callers
Method
_forward_augment
Perform augmentations on input image x and return augmented inference and train outputs.
utils/tasks.py:219
↓ 1 callers
Method
_new
Initializes a new model and infers the task type from the model definitions. Args: cfg (str): model configuration fi
model/backbone.py:111
↓ 1 callers
Method
_profile_one_layer
Profile the computation time and FLOPs of a single layer of the model on a given input. Appends the results to the provided list.
utils/tasks.py:74
↓ 1 callers
Method
backward
(ctx, grad_output)
model/activations_me.py:79
↓ 1 callers
Method
bias_init
Initialize Detect() biases, WARNING: requires stride availability.
utils/tasks.py:533
↓ 1 callers
Function
cfg2task
Guess from YAML dictionary.
utils/tasks.py:472
↓ 1 callers
Function
check_source
Check source type and return corresponding flag values.
utils/utils.py:97
↓ 1 callers
Function
clamp_bbox
Clamps bounding box coordinates to be within image boundaries [0, dim).
utils/augment.py:14
↓ 1 callers
Function
clamp_keypoints
Clamps keypoint coordinates to be within image boundaries [0, dim).
utils/augment.py:5
↓ 1 callers
Method
forward
(self, x)
model/trcount.py:29
↓ 1 callers
Function
guess_model_scale
Takes a path to a YOLO model's YAML file as input and extracts the size character of the model's scale. The function uses regular expressio
utils/tasks.py:454
↓ 1 callers
Function
hard_mish
Hard Mish Experimental, based on notes by Mish author Diganta Misra at https://github.com/digantamisra98/H-Mish/blob/0da20d4bc58e696b6803f2
model/activations.py:104
↓ 1 callers
Function
hard_mish_jit
Hard Mish Experimental, based on notes by Mish author Diganta Misra at https://github.com/digantamisra98/H-Mish/blob/0da20d4bc58e696b6803f2
model/activations_jit.py:77
↓ 1 callers
Function
hard_mish_jit_bwd
(x, grad_output)
model/activations_me.py:174
↓ 1 callers
Function
hard_mish_jit_fwd
(x)
model/activations_me.py:169
↓ 1 callers
Function
hard_sigmoid
(x, inplace: bool = False)
model/activations.py:88
↓ 1 callers
Function
hard_sigmoid_jit
(x, inplace: bool = False)
model/activations_jit.py:49
↓ 1 callers
Function
hard_sigmoid_jit_bwd
(x, grad_output)
model/activations_me.py:102
↓ 1 callers
Function
hard_sigmoid_jit_fwd
(x, inplace: bool = False)
model/activations_me.py:97
↓ 1 callers
Function
hard_swish
(x, inplace: bool = False)
model/activations.py:74
↓ 1 callers
Function
hard_swish_jit
(x, inplace: bool = False)
model/activations_jit.py:63
↓ 1 callers
Function
hard_swish_jit_bwd
(x, grad_output)
model/activations_me.py:137
↓ 1 callers
Function
hard_swish_jit_fwd
(x)
model/activations_me.py:132
↓ 1 callers
Method
is_fused
Check if the model has less than a certain threshold of BatchNorm layers. Args: thresh (int, optional): The threshol
utils/tasks.py:124
↓ 1 callers
Function
mish
Mish: A Self Regularized Non-Monotonic Neural Activation Function - https://arxiv.org/abs/1908.08681 NOTE: I don't have a working inplace variant
model/activations.py:29
↓ 1 callers
Function
mish_jit
Mish: A Self Regularized Non-Monotonic Neural Activation Function - https://arxiv.org/abs/1908.08681
model/activations_jit.py:26
↓ 1 callers
Function
mish_jit_bwd
(x, grad_output)
model/activations_me.py:63
↓ 1 callers
Function
mish_jit_fwd
(x)
model/activations_me.py:58
↓ 1 callers
Function
parse_model
(d, ch, verbose=True)
utils/tasks.py:362
↓ 1 callers
Function
pre_transform
Pre-tranform input image before inference. Args: im (List(np.ndarray)): (N, 3, h, w) for tensor, [(h, w, 3) x N] for list.
utils/utils.py:53
↓ 1 callers
Function
swish
Swish - Described in: https://arxiv.org/abs/1710.05941
model/activations.py:14
↓ 1 callers
Function
swish_jit
Swish - Described in: https://arxiv.org/abs/1710.05941
model/activations_jit.py:19
↓ 1 callers
Function
swish_jit_bwd
(x, grad_output)
model/activations_me.py:23
↓ 1 callers
Function
swish_jit_fwd
(x)
model/activations_me.py:18
↓ 1 callers
Function
test_aggregation_zeropad
()
model/aggregation_zeropad.py:238
↓ 1 callers
Function
test_aggregation_zeropad_ks1
()
model/aggregation_zeropad.py:266
↓ 1 callers
Function
train_one_epoch
()
train.py:25
↓ 1 callers
Function
validate
()
train.py:58
↓ 1 callers
Function
validate
()
valid.py:25
Method
__call__
(self, img)
utils/augmentation.py:46
Method
__call__
Calls the 'predict' function with given arguments to perform object detection.
model/backbone.py:106
Method
__enter__
(self)
model/config.py:35
Method
__enter__
(self)
model/config.py:54
Method
__enter__
(self)
model/config.py:73
Method
__enter__
(self)
model/config.py:106
Method
__exit__
(self, *args: Any)
model/config.py:38
Method
__exit__
(self, *args: Any)
model/config.py:57
Method
__exit__
(self, *args: Any)
model/config.py:76
Method
__exit__
(self, *args: Any)
model/config.py:109
Method
__getitem__
(self, idx)
utils/utils.py:135
Method
__init__
(self)
utils/augmentation.py:7
Method
__init__
(self, annotations_file, img_dir, size = None, transform=None, target_transform=None)
utils/utils.py:122
Method
__init__
(self, cfg='yolov8n.yaml', ch=3, nc=None, verbose=True)
utils/tasks.py:184
Method
__init__
(self, mode: bool)
model/config.py:30
Method
__init__
(self, mode: bool)
model/config.py:49
Method
__init__
(self, mode: bool)
model/config.py:68
Method
__init__
( self, scriptable: Optional[bool] = None, exportable: Optional[bool] = No
model/config.py:86
Method
__init__
(self, inplace: bool = False)
model/activations_jit.py:33
Method
__init__
(self, inplace: bool = False)
model/activations_jit.py:55
Method
__init__
(self, inplace: bool = False)
model/activations_jit.py:69
Method
__init__
(self, inplace: bool = False)
model/activations_jit.py:86
Method
__init__
(self, inplace: bool = False)
model/activations_me.py:50
Method
__init__
(self, inplace: bool = False)
model/activations_me.py:124
Method
__init__
(self, inplace: bool = False)
model/activations_me.py:161
Method
__init__
(self, inplace: bool = False)
model/activations_me.py:201
Method
__init__
( self, in_channels: int, out_channels: int, kernel_size: int, stride:
model/aggregation_zeropad.py:200
Method
__init__
(self,d_model, dropout = 0.1)
model/regressor.py:13
Method
__init__
(self, inplace: bool = False)
model/activations.py:21
Method
__init__
(self, inplace: bool = False)
model/activations.py:52
Method
__init__
(self, inplace: bool = False)
model/activations.py:66
Method
__init__
(self, inplace: bool = False)
model/activations.py:80
Method
__init__
(self, inplace: bool = False)
model/activations.py:96
next →
1–100 of 163, ranked by callers