Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump the torch group in /requirements with 2 updates #2353

Merged
merged 2 commits into from
Oct 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion experiments/torchgeo/benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def main(args: argparse.Namespace) -> None:

criterion = nn.CrossEntropyLoss()
params = model.parameters()
optimizer = optim.SGD(params, lr=0.0001) # type: ignore[attr-defined]
optimizer = optim.SGD(params, lr=0.0001)

device = torch.device('cuda' if torch.cuda.is_available() else 'cpu', args.device)
model = model.to(device)
Expand Down
4 changes: 2 additions & 2 deletions requirements/required.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ rtree==1.3.0
segmentation-models-pytorch==0.3.4
shapely==2.0.6
timm==0.9.7
torch==2.4.1
torch==2.5.0
torchmetrics==1.4.3
torchvision==0.19.1
torchvision==0.20.0
2 changes: 1 addition & 1 deletion torchgeo/trainers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

import lightning
from lightning.pytorch import LightningModule
from torch.optim import AdamW # type: ignore[attr-defined]
from torch.optim import AdamW
from torch.optim.lr_scheduler import ReduceLROnPlateau


Expand Down
2 changes: 1 addition & 1 deletion torchgeo/trainers/iobench.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import lightning
import torch
from torch import Tensor
from torch.optim import SGD # type: ignore[attr-defined]
from torch.optim import SGD

from .base import BaseTask

Expand Down
2 changes: 1 addition & 1 deletion torchgeo/trainers/moco.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from lightly.models.utils import deactivate_requires_grad, update_momentum
from lightly.utils.scheduler import cosine_schedule
from torch import Tensor
from torch.optim import SGD, AdamW, Optimizer # type: ignore[attr-defined]
from torch.optim import SGD, AdamW, Optimizer
from torch.optim.lr_scheduler import (
CosineAnnealingLR,
LinearLR,
Expand Down