segmentation-models-pytorch · PyPI
pypi.org › project › segmentation-models-pytorchNov 18, 2021 · Depth parameter specify a number of downsampling operations in encoder, so you can make your model lighter if specify smaller depth. model = smp. Unet ('resnet34', encoder_depth = 4) 🛠 Installation . PyPI version: $ pip install segmentation-models-pytorch Latest version from source: $ pip install git+https://github.com/qubvel/segmentation_models.pytorch
segmentation-models-pytorch · PyPI
https://pypi.org/project/segmentation-models-pytorch18.11.2021 · Segmentation model is just a PyTorch nn.Module, which can be created as easy as: import segmentation_models_pytorch as smp model = smp.Unet( encoder_name="resnet34", # choose encoder, e.g. mobilenet_v2 or efficientnet-b7 encoder_weights="imagenet", # use `imagenet` pre-trained weights for encoder initialization in_channels=1, # model input ...