DAPPER (Document Analysis, Processing, and Pattern Extraction Repository)
Statistical Learning Final Project for Document Classification
 
Loading...
Searching...
No Matches
models Namespace Reference

Classes

class  BaseModel
 

Functions

nn.Module get_model (str model_name, int num_classes, bool pretrained=True, bool freeze_backbone=False, **kwargs)
 

Function Documentation

◆ get_model()

nn.Module models.get_model ( str  model_name,
int  num_classes,
bool   pretrained = True,
bool   freeze_backbone = False,
**  kwargs 
)
Get a model by name.

Args:
    model_name: Name of the model to get
    num_classes: Number of classes to classify
    pretrained: Whether to use pre-trained weights
    freeze_backbone: Whether to freeze the backbone
    **kwargs: Additional arguments to pass to the model
    
Returns:
    The requested model