Mask shape: (360, 480)
/cu128_env\lib\site-packages\albumentations\core\validation.py:114: UserWarning: ShiftScaleRotate is a special case of Affine transform. Please use Affine transform instead.
original_init(self, **validated_kwargs)
/segmentation_models_pytorch_codes\train2.py:178: UserWarning: Argument(s) 'always_apply' are not valid for transform PadIfNeeded
A.PadIfNeeded(min_height=320, min_width=320, always_apply=True),
/segmentation_models_pytorch_codes\train2.py:179: UserWarning: Argument(s) 'always_apply' are not valid for transform RandomCrop
A.RandomCrop(height=320, width=320, always_apply=True),
Mask shape: (320, 320)
[ 0 1 2 3 4 5 6 7 9 10]
Mask shape: (320, 320)
[ 0 1 2 3 4 5 6 7 9 10]
Mask shape: (320, 320)
[ 0 1 2 3 4 5 6 7 9 10]
W0413 16:12:17.647000 29688 Lib\site-packages\torch\utils\flop_counter.py:29] triton not found; flop counting will not work for triton kernels
GPU available: True (cuda), used: True
TPU available: False, using: 0 TPU cores
💡 Tip: For seamless cloud logging and experiment tracking, try installing [litlogger](https://pypi.org/project/litlogger/) to enable LitLogger, which logs metrics and artifacts automatically to the Lightning Experiments platform.
💡 Tip: For seamless cloud uploads and versioning, try installing [litmodels](https://pypi.org/project/litmodels/) to enable LitModelCheckpoint, which syncs automatically with the Lightning model registry.
LOCAL_RANK: 0 - CUDA_VISIBLE_DEVICES: [0]
┏━━━┳━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━┳━━━━━━━┳━━━━━━━┓
┃ ┃ Name ┃ Type ┃ Params ┃ Mode ┃ FLOPs ┃
┡━━━╇━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━╇━━━━━━━╇━━━━━━━┩
│ 0 │ model │ FPN │ 25.6 M │ train │ 0 │
│ 1 │ loss_fn │ DiceLoss │ 0 │ train │ 0 │
└───┴─────────┴──────────┴────────┴───────┴───────┘
Trainable params: 25.6 M
Non-trainable params: 0
Total params: 25.6 M
Total estimated model params size (MB): 102
Modules in train mode: 210
Modules in eval mode: 0
Total FLOPs: 0
/cu128_env\lib\site-packages\pytorch_lightning\utilities\_pytree.py:21: `isinstance(treespec, LeafSpec)` is deprecated, use
`isinstance(treespec, TreeSpec) and treespec.is_leaf()` instead.
/cu128_env\lib\site-packages\pytorch_lightning\trainer\connectors\data_connector.py:434: The 'val_dataloader' does not have
many workers which may be a bottleneck. Consider increasing the value of the `num_workers` argument` to `num_workers=15` in the `DataLoader` to improve performance.
/cu128_env\lib\site-packages\pytorch_lightning\trainer\connectors\data_connector.py:434: The 'train_dataloader' does not have
many workers which may be a bottleneck. Consider increasing the value of the `num_workers` argument` to `num_workers=15` in the `DataLoader` to improve performance.
Epoch 49/49 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 92/92 0:00:37 • 0:00:00 2.49it/s v_num: 1.000 valid_per_image_iou: 0.462 valid_dataset_iou: 0.461
train_per_image_iou: 0.469 train_dataset_iou: 0.459
Epoch 49/49 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 92/92 0:00:37 • 0:00:00 2.49it/s v_num: 1.000 valid_per_image_iou: 0.462 valid_dataset_iou: 0.461
train_per_image_iou: 0.469 train_dataset_iou: 0.459
LOCAL_RANK: 0 - CUDA_VISIBLE_DEVICES: [0]
Validation ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 26/26 0:00:05 • 0:00:00 4.85it/s
[{'valid_per_image_iou': 0.46198970079421997, 'valid_dataset_iou': 0.4605414569377899}]
LOCAL_RANK: 0 - CUDA_VISIBLE_DEVICES: [0]
/cu128_env\lib\site-packages\pytorch_lightning\trainer\connectors\data_connector.py:434: The 'test_dataloader' does not have many workers which may be a bottleneck. Consider increasing the value of the `num_workers` argument` to `num_workers=15` in the `DataLoader` to improve performance.
Testing ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 59/59 0:00:12 • 0:00:00 4.59it/s
[{'test_per_image_iou': 0.46282604336738586, 'test_dataset_iou': 0.4600731134414673}]
Hello, sir, please tell me why I use the example code? The training result is so much lower than the sample code? What's the main reason? Is there any solution?