Warmup epochs with frozen pre-trained encoder weights to initialize decoder
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 2.1k
- Forks
- 385
- PR merge metrics
- No merged PRs in 30d
Description
At the moment we are using a pre-trained ResNet as an encoder in our encoder-decoder architecture:
https://github.com/mapbox/robosat/blob/8b7566e3b5de3583eb64fbb641ff18b9ff01f901/robosat/unet.py#L94-L100
https://github.com/mapbox/robosat/blob/8b7566e3b5de3583eb64fbb641ff18b9ff01f901/robosat/unet.py#L123-L134
We are currently training the model as is with all layers unfrozen.
We should investigate if freezing the ResNet encoder and running a few warmup epochs to initialize the decoder layers (then unfreezing parts or all of the ResNet) helps.
Here is how we can freeze the encoder - unfreezing works similarly:
```python3
def freeze(self):
for layer in (self.enc0, self.enc1, self.enc2, self.enc3, self.enc4):
for param in layer.parameters():
param.requires_grad = False
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in robosat/unet.py at lines 94-100 and 123-134, then review the encoder layers named enc0 through enc4 and the proposed freeze method. Compare training with frozen-encoder warmup epochs against later unfreezing; done means determining whether this improves decoder initialization.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- computer-vision, machine-learning
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100