Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/csslc/PiSA-SR
/ functions
Functions
373 in github.com/csslc/PiSA-SR
⨍
Functions
373
◇
Types & classes
67
Method
forward
Args: x: input features with shape of (num_windows*B, N, C) mask: (0/-inf) mask with shape of (num_windows, Wh*Ww, Wh
ram/models/swin_transformer.py:116
Method
forward
(self, x, condition=None)
ram/models/swin_transformer.py:247
Method
forward
x: B, H*W, C
ram/models/swin_transformer.py:347
Method
forward
(self, x, condition=None)
ram/models/swin_transformer.py:428
Method
forward
(self, x)
ram/models/swin_transformer.py:480
Method
forward
(self, x, idx_to_group_img=None, image_atts=None, condition=None, **kwargs)
ram/models/swin_transformer.py:599
Method
forward
call function as forward Args: image: type: torch.Tensor shape: batch_size * 3 * 384 * 384 caption: type: l
ram/models/tag2text_lora.py:141
Method
forward
(self, x)
ram/models/swin_transformer_lora.py:31
Method
forward
Args: x: input features with shape of (num_windows*B, N, C) mask: (0/-inf) mask with shape of (num_windows, Wh*Ww, Wh
ram/models/swin_transformer_lora.py:122
Method
forward
(self, x)
ram/models/swin_transformer_lora.py:242
Method
forward
x: B, H*W, C
ram/models/swin_transformer_lora.py:316
Method
forward
(self, x)
ram/models/swin_transformer_lora.py:397
Method
forward
(self, x)
ram/models/swin_transformer_lora.py:449
Method
forward
(self, x, idx_to_group_img=None, image_atts=None, **kwargs)
ram/models/swin_transformer_lora.py:568
Method
fuse_qkv_projections
Enables fused QKV projections. For self-attention modules, all projection matrices (i.e., query, key, value) are fused. For cross-att
src/models/autoencoder_kl.py:453
Method
fuse_qkv_projections
Enables fused QKV projections. For self-attention modules, all projection matrices (i.e., query, key, value) are fused. For cross-att
src/models/unet_2d_condition.py:803
Method
generate
(self, image, sample=False, num_beams=3, m
ram/models/tag2text_lora.py:280
Method
generate_image_embeds
(self, image, condition=False )
ram/models/tag2text.py:230
Method
generate_image_embeds
(self, image, condition=False )
ram/models/ram_lora.py:183
Method
generate_image_embeds
(self, image, condition=False )
ram/models/tag2text_lora.py:230
Method
generate_tag
(self, image, threshold=0.68, tag_input=None,
ram/models/ram_lora.py:192
Method
generate_tag_openset
(self, image, threshold=0.68, tag_input=None,
ram/models/ram_lora.py:283
Function
get_PR
( pred_file: str, gt_file: str, taglist: List[str] )
ram/utils/metrics.py:61
Method
get_attention_map
(self)
ram/models/bert_lora.py:189
Method
get_attention_map
(self)
ram/models/vit.py:67
Method
get_attention_map
(self)
ram/models/bert.py:184
Method
get_attn_gradients
(self)
ram/models/bert_lora.py:183
Method
get_attn_gradients
(self)
ram/models/vit.py:61
Method
get_attn_gradients
(self)
ram/models/bert.py:178
Function
get_device_for
(task)
src/my_utils/devices.py:37
Method
get_input_embeddings
(self)
ram/models/bert_lora.py:674
Method
get_input_embeddings
(self)
ram/models/bert.py:669
Function
get_mAP
( preds: ndarray, gt_file: str, taglist: List[str] )
ram/utils/metrics.py:7
Method
get_output_embeddings
(self)
ram/models/bert_lora.py:903
Method
get_output_embeddings
(self)
ram/models/bert.py:898
Function
get_transform
(image_size=384)
ram/transform.py:7
Method
group_norm_func
(x, mean=mean, var=var, weight=weight, bias=bias)
src/my_utils/vaehook.py:531
Function
inference_ram
(image, model)
ram/inference.py:33
Function
inference_ram_openset
(image, model)
ram/inference.py:41
Function
inference_tag2text
(image, model, input_tag="None")
ram/inference.py:8
Function
inplace_nonlinearity
(x)
src/my_utils/vaehook.py:129
Function
interpolate_relative_pos_embed
(rel_pos_bias, dst_num_pos, param_name='')
ram/models/swin_transformer_lora.py:602
Function
load_checkpoint_swinlarge_condition
(model, url_or_filename, kwargs)
ram/models/utils.py:204
Method
load_pretrained
(self, checkpoint_path, prefix='')
ram/models/vit.py:197
Method
merge_and_unload
( self, progressbar: bool = False, safe_merge: bool = False, adapter_names: Optional[list[str]] = None
src/models/unet_2d_condition.py:1216
Method
no_weight_decay
(self)
ram/models/vit.py:177
Method
no_weight_decay
(self)
ram/models/swin_transformer.py:592
Method
no_weight_decay
(self)
ram/models/swin_transformer_lora.py:561
Method
no_weight_decay_keywords
(self)
ram/models/swin_transformer.py:596
Method
no_weight_decay_keywords
(self)
ram/models/swin_transformer_lora.py:565
Function
perfcount
(fn)
src/my_utils/vaehook.py:431
Method
prepare_inputs_for_generation
(self, input_ids, past=None, attention_mask=None, **model_kwargs)
ram/models/bert_lora.py:1015
Method
prepare_inputs_for_generation
(self, input_ids, past=None, attention_mask=None, **model_kwargs)
ram/models/bert.py:1010
Function
ram
(pretrained='', pretrained_condition='', **kwargs)
ram/models/ram_lora.py:328
Function
randn
(seed, shape)
src/my_utils/devices.py:83
Function
randn_without_seed
(shape)
src/my_utils/devices.py:88
Method
save_attn_gradients
(self, attn_gradients)
ram/models/bert_lora.py:180
Method
save_attn_gradients
(self, attn_gradients)
ram/models/vit.py:58
Method
save_attn_gradients
(self, attn_gradients)
ram/models/bert.py:175
Method
set_default_attn_processor
Disables custom attention processors and sets the default attention implementation.
src/models/autoencoder_kl.py:221
Method
set_default_attn_processor
Disables custom attention processors and sets the default attention implementation.
src/models/unet_2d_condition.py:687
Method
set_input_embeddings
(self, value)
ram/models/bert_lora.py:677
Method
set_input_embeddings
(self, value)
ram/models/bert.py:672
Method
set_output_embeddings
(self, new_embeddings)
ram/models/bert_lora.py:906
Method
set_output_embeddings
(self, new_embeddings)
ram/models/bert.py:901
Function
tag2text
(pretrained='', **kwargs)
ram/models/tag2text.py:409
Function
tag2text
(pretrained='', **kwargs)
ram/models/tag2text_lora.py:409
Function
test_for_nans
(x, where)
src/my_utils/devices.py:107
Function
torch_gc
()
src/my_utils/devices.py:41
Method
unfuse_qkv_projections
Disables the fused QKV projection if enabled. <Tip warning={true}> This API is 🧪 experimental. </Tip>
src/models/autoencoder_kl.py:477
Method
unfuse_qkv_projections
Disables the fused QKV projection if enabled. <Tip warning={true}> This API is 🧪 experimental. </Tip>
src/models/unet_2d_condition.py:826
Function
without_autocast
(disable=False)
src/my_utils/devices.py:99
Function
wrapper
(*args, **kwargs)
src/my_utils/vaehook.py:432
← previous
301–373 of 373, ranked by callers