Skip to content

ChannelsLast Callback Improvements, Additional Documentation, & Bug Fix#3876

Merged
jph00 merged 1 commit into
fastai:masterfrom
warner-benjamin:channels_last
Feb 15, 2023
Merged

ChannelsLast Callback Improvements, Additional Documentation, & Bug Fix#3876
jph00 merged 1 commit into
fastai:masterfrom
warner-benjamin:channels_last

Conversation

@warner-benjamin

Copy link
Copy Markdown
Collaborator

This PR upstreams my ChannelsLast callback from fastxtend. This version of the callback is simpler, and it fixes the current ChannelsLast callback bug of adding the labels to the model input batch.

The new Channels Last notebook adds two convenience methods for enabling and disabling channels last (to_channelslast and to_contiguous), adding MixedPrecision by default for best channels last performance. It also expands the channels last documentation and adds a test to make sure model outputs are in channels last format.

Keeping with the current MixedPrecision behavior, I modified load_learner to remove the ChannelsLast and MixedPrecison callbacks.

I also moved the Mixed Precision and Channels Last notebooks under the Training sidebar header for easier visibility, since they struck me as more similar to the Distributed Trainer notebook, which is directly under Training, than other callbacks.

@review-notebook-app

Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@jph00 jph00 merged commit e7c86fe into fastai:master Feb 15, 2023
@jph00

jph00 commented Feb 15, 2023

Copy link
Copy Markdown
Member

Many thanks!

@warner-benjamin warner-benjamin deleted the channels_last branch February 27, 2023 05:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants