Views
No views yet
state_dict) for a custom ForestFireCNN model trained to detect forest fires from ground-level images.state_dict). Before loading the weights, recreate the ForestFireCNN architecture using the provided forestfirecnn.py file.1import torch
2from forestfirecnn import ForestFireCNN
3
4# Create the model architecture
5model = ForestFireCNN(num_classes=2)
6
7# Load the state dictionary
8state_dict = torch.load(
9 "lightweightcnn.pt",
10 map_location="cpu"
11)
12
13model.load_state_dict(state_dict)
14model.eval()lightweightcnn.pt
forestfirecnn.py
README.md