Thanks i run a code like this
import torch
Path to your .pth or .pt file
file_path = â/path_to_Pth_file/â
Load the model state dictionary
model_state_dict = torch.load(file_path)
Print keys in model_state_dict to see whatâs available
print(model_state_dict.keys())
Access and use model_state_dict as needed
and results was sth like this:
âtransformer.patch_embed.proj.biasâ, âtransformer.patch_embed.norm.weightâ, âtransformer.patch_embed.norm.biasâ, âtransformer.layers.0.blocks.0.norm1.weightâ, âtransformer.layers.0.blocks.0.norm1.biasâ, âtransformer.layers.0.blocks.0.attn.relative_position_bias_tableâ, âtransformer.layers.0.blocks.0.attn.relative_position_indexâ, âtransformer.layers.0.blocks.0.attn.qkv.weightâ, âtransformer.layers.0.blocks.0.attn.proj.weightâ, âtransformer.layers.0.blocks.0.attn.proj.biasâ, âtransformer.layers.0.blocks.0.norm2.weightâ, âtransformer.layers.0.blocks.0.norm2.biasâ, âtransformer.layers.0.blocks.0.mlp.fc1.weightâ, âtransformer.layers.0.blocks.0.mlp.fc1.biasâ, âtransformer.layers.0.blocks.0.mlp.fc2.weightâ, âtransformer.layers.0.blocks.0.mlp.fc2.biasâ, âtransformer.layers.0.blocks.1.norm1.weightâ, âtransformer.layers.0.blocks.1.norm1.biasâ, âtransformer.layers.0.blocks.1.attn.relative_position_bias_tableâ, âtransformer.layers.0.blocks.1.attn.relative_position_indexâ, âtransformer.layers.0.blocks.1.attn.qkv.weightâ, âtransformer.layers.0.blocks.1.attn.proj.weightâ, âtransformer.layers.0.blocks.1.attn.proj.biasâ, âtransformer.layers.0.blocks.1.norm2.weightâ, âtransformer.layers.0.blocks.1.norm2.biasâ, âtransformer.layers.0.blocks.1.mlp.fc1.weightâ, âtransformer.layers.0.blocks.1.mlp.fc1.biasâ, âtransformer.layers.0.blocks.1.mlp.fc2.weightâ, âtransformer.layers.0.blocks.1.mlp.fc2.biasâ, âtransformer.layers.0.downsample.reduction.weightâ, âtransformer.layers.0.downsample.norm.weightâ, âtransformer.layers.0.downsample.norm.biasâ, âtransformer.layers.1.blocks.0.norm1.weightâ, âtransformer.layers.1.blocks.0.norm1.biasâ, âtransformer.layers.1.blocks.0.attn.relative_position_bias_tableâ, âtransformer.layers.1.blocks.0.attn.relative_position_indexâ, âtransformer.layers.1.blocks.0.attn.qkv.weightâ, âtransformer.layers.1.blocks.0.attn.proj.weightâ, âtransformer.layers.1.blocks.0.attn.proj.biasâ, âtransformer.layers.1.blocks.0.norm2.weightâ, âtransformer.layers.1.blocks.0.norm2.biasâ, âtransformer.layers.1.blocks.0.mlp.fc1.weightâ, âtransformer.layers.1.blocks.0.mlp.fc1.biasâ, âtransformer.layers.1.blocks.0.mlp.fc2.weightâ, âtransformer.layers.1.blocks.0.mlp.fc2.biasâ, âtransformer.layers.1.blocks.1.norm1.weightâ, âtransformer.layers.1.blocks.1.norm1.biasâ, âtransformer.layers.1.blocks.1.attn.relative_position_bias_tableâ, âtransformer.layers.1.blocks.1.attn.relative_position_indexâ, âtransformer.layers.1.blocks.1.attn.qkv.weightâ, âtransformer.layers.1.blocks.1.attn.proj.weightâ, âtransformer.layers.1.blocks.1.attn.proj.biasâ, âtransformer.layers.1.blocks.1.norm2.weightâ, âtransformer.layers.1.blocks.1.norm2.biasâ, âtransformer.layers.1.blocks.1.mlp.fc1.weightâ, âtransformer.layers.1.blocks.1.mlp.fc1.biasâ, âtransformer.layers.1.blocks.1.mlp.fc2.weightâ, âtransformer.layers.1.blocks.1.mlp.fc2.biasâ, âtransformer.layers.1.downsample.reduction.weightâ, âtransformer.layers.1.downsample.norm.weightâ, âtransformer.layers.1.downsample.norm.biasâ, âtransformer.layers.2.blocks.0.norm1.weightâ, âtransformer.layers.2.blocks.0.norm1.biasâ, âtransformer.layers.2.blocks.0.attn.relative_position_bias_tableâ, âtransformer.layers.2.blocks.0.attn.relative_position_indexâ, âtransformer.layers.2.blocks.0.attn.qkv.weightâ, âtransformer.layers.2.blocks.0.attn.proj.weightâ, âtransformer.layers.2.blocks.0.attn.proj.biasâ, âtransformer.layers.2.blocks.0.norm2.weightâ, âtransformer.layers.2.blocks.0.norm2.biasâ, âtransformer.layers.2.blocks.0.mlp.fc1.weightâ, âtransformer.layers.2.blocks.0.mlp.fc1.biasâ, âtransformer.layers.2.blocks.0.mlp.fc2.weightâ, âtransformer.layers.2.blocks.0.mlp.fc2.biasâ, âtransformer.layers.2.blocks.1.norm1.weightâ, âtransformer.layers.2.blocks.1.norm1.biasâ, âtransformer.layers.2.blocks.1.attn.relative_position_bias_tableâ, âtransformer.layers.2.blocks.1.attn.relative_position_indexâ, âtransformer.layers.2.blocks.1.attn.qkv.weightâ, âtransformer.layers.2.blocks.1.attn.proj.weightâ, âtransformer.layers.2.blocks.1.attn.proj.biasâ, âtransformer.layers.2.blocks.1.norm2.weightâ, âtransformer.layers.2.blocks.1.norm2.biasâ, âtransformer.layers.2.blocks.1.mlp.fc1.weightâ, âtransformer.layers.2.blocks.1.mlp.fc1.biasâ, âtransformer.layers.2.blocks.1.mlp.fc2.weightâ, âtransformer.layers.2.blocks.1.mlp.fc2.biasâ, âtransformer.layers.2.blocks.2.norm1.weightâ, âtransformer.layers.2.blocks.2.norm1.biasâ, âtransformer.layers.2.blocks.2.attn.relative_position_bias_tableâ, âtransformer.layers.2.blocks.2.attn.relative_position_indexâ, âtransformer.layers.2.blocks.2.attn.qkv.weightâ, âtransformer.layers.2.blocks.2.attn.proj.weightâ, âtransformer.layers.2.blocks.2.attn.proj.biasâ, âtransformer.layers.2.blocks.2.norm2.weightâ, âtransformer.layers.2.blocks.2.norm2.biasâ, âtransformer.layers.2.blocks.2.mlp.fc1.weightâ, âtransformer.layers.2.blocks.2.mlp.fc1.biasâ, âtransformer.layers.2.blocks.2.mlp.fc2.weightâ, âtransformer.layers.2.blocks.2.mlp.fc2.biasâ, âtransformer.layers.2.blocks.3.norm1.weightâ, âtransformer.layers.2.blocks.3.norm1.biasâ, âtransformer.layers.2.blocks.3.attn.relative_position_bias_tableâ, âtransformer.layers.2.blocks.3.attn.relative_position_indexâ, âtransformer.layers.2.blocks.3.attn.qkv.weightâ, âtransformer.layers.2.blocks.3.attn.proj.weightâ, âtransformer.layers.2.blocks.3.attn.proj.biasâ, âtransformer.layers.2.blocks.3.norm2.weightâ, âtransformer.layers.2.blocks.3.norm2.biasâ, âtransformer.layers.2.blocks.3.mlp.fc1.weightâ, âtransformer.layers.2.blocks.3.mlp.fc1.biasâ, âtransformer.layers.2.blocks.3.mlp.fc2.weightâ, âtransformer.layers.2.blocks.3.mlp.fc2.biasâ, âtransformer.layers.2.downsample.reduction.weightâ, âtransformer.layers.2.downsample.norm.weightâ, âtransformer.layers.2.downsample.norm.biasâ, âtransformer.layers.3.blocks.0.norm1.weightâ, âtransformer.layers.3.blocks.0.norm1.biasâ, âtransformer.layers.3.blocks.0.attn.relative_position_bias_tableâ, âtransformer.layers.3.blocks.0.attn.relative_position_indexâ, âtransformer.layers.3.blocks.0.attn.qkv.weightâ, âtransformer.layers.3.blocks.0.attn.proj.weightâ, âtransformer.layers.3.blocks.0.attn.proj.biasâ, âtransformer.layers.3.blocks.0.norm2.weightâ, âtransformer.layers.3.blocks.0.norm2.biasâ, âtransformer.layers.3.blocks.0.mlp.fc1.weightâ, âtransformer.layers.3.blocks.0.mlp.fc1.biasâ, âtransformer.layers.3.blocks.0.mlp.fc2.weightâ, âtransformer.layers.3.blocks.0.mlp.fc2.biasâ, âtransformer.layers.3.blocks.1.norm1.weightâ, âtransformer.layers.3.blocks.1.norm1.biasâ, âtransformer.layers.3.blocks.1.attn.relative_position_bias_tableâ, âtransformer.layers.3.blocks.1.attn.relative_position_indexâ, âtransformer.layers.3.blocks.1.attn.qkv.weightâ, âtransformer.layers.3.blocks.1.attn.proj.weightâ, âtransformer.layers.3.blocks.1.attn.proj.biasâ, âtransformer.layers.3.blocks.1.norm2.weightâ, âtransformer.layers.3.blocks.1.norm2.biasâ, âtransformer.layers.3.blocks.1.mlp.fc1.weightâ, âtransformer.layers.3.blocks.1.mlp.fc1.biasâ, âtransformer.layers.3.blocks.1.mlp.fc2.weightâ, âtransformer.layers.3.blocks.1.mlp.fc2.biasâ, âtransformer.norm0.weightâ, âtransformer.norm0.biasâ, âtransformer.norm1.weightâ, âtransformer.norm1.biasâ, âtransformer.norm2.weightâ, âtransformer.norm2.biasâ, âtransformer.norm3.weightâ, âtransformer.norm3.biasâ, âup0.conv1.0.weightâ, âup0.conv2.0.weightâ, âup1.conv1.0.weightâ, âup1.conv2.0.weightâ, âup2.conv1.0.weightâ, âup2.conv2.0.weightâ, âup3.conv1.0.weightâ, âup3.conv2.0.weightâ, âup4.conv1.0.weightâ, âup4.conv2.0.weightâ, âc1.0.weightâ, âc2.0.weightâ, âreg_head.0.weightâ, âreg_head.0.biasâ, âspatial_trans.gridâ, âspatial_trans_seg.gridâ])
i am still wondering how can i plot loss from these keysâŚ