-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Tutorials : Pretraining VGG from Scrtach #2971
base: main
Are you sure you want to change the base?
Conversation
saving and loading a general checkpoint.py \n intial -> initial
toctree : Image and Video Pretraining Vgg from scratch
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/tutorials/2971
Note: Links to docs will display an error until the docs builds have been completed. This comment was automatically generated by Dr. CI and updates every 15 minutes. |
@@ -0,0 +1,643 @@ | |||
""" | |||
In this tutorial, we will embark on an exciting journey to build and |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please follow this template . Your tutorials should have: Title, a short abstract, Author, Overview, Steps, and Conclusion. Please maintain a third-person narrative throughout the document. Avoid using first-person pronouns like "I" and instead use "we". Use active voice where possible.
Follow Pytorch Tutorial convetion Modify I -> We
Add More things to try , Conclusion , Further Reading
Hi @svekars, could you please help to take a look of this PR? |
pyspell fixed
add packagge install code
add packagge install code
Hi @svekars, could you please help to take a look of this PR again? |
remove tqdm
pyspell check,add albumentations installation code
Hi @svekars , could you please help to take a look of this PR again? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR!
@svekars are you okay with handling review for the polish needed for this tutorial? (e.g. grammar / punctuation / spacing). I added several comments regarding this but it's incomplete and I shifted to focusing on the ML component of the tutorial.
Made a pass but haven't spent a ton of time verifying the code logic yet. I can take another look once some of these issues are addressed.
|
||
|
||
###################################################################### | ||
# Worth point of this tutorial |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# Worth point of this tutorial | |
# Purpose of this tutorial |
train a VGG network from scratch using Python and popular deep learning | ||
libraries such as PyTorch. We will dive into the details of the VGG |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
train a VGG network from scratch using Python and popular deep learning | |
libraries such as PyTorch. We will dive into the details of the VGG | |
train a VGG network from scratch using PyTorch. We will dive into the details of the VGG |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A better intro would be:
VGG (Visual Geometry Group) is a convolutional neural network architecture that is particularly
efficient in image classification tasks. In this tutorial, we will guide you through building
and training a VGG network from scratch using Python and PyTorch. We will dive into the details of the VGG
architecture, understanding its components and the rationale behind its
design.
|
||
|
||
###################################################################### | ||
# | If your GPU memory is 24GB ,The maximum batch size is 128. But, if you |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# | If your GPU memory is 24GB ,The maximum batch size is 128. But, if you | |
# | If your GPU memory is 24GB, the maximum batch size is 128. But if you |
|
||
###################################################################### | ||
# | If your GPU memory is 24GB ,The maximum batch size is 128. But, if you | ||
# use Colab , We recommend using 32 . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# use Colab , We recommend using 32 . | |
# use Colab, we recommend using 32GB. |
|
||
|
||
###################################################################### | ||
# We use ``CIFAR100`` Dataset in this tutorial. In VGG paper , the authors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# We use ``CIFAR100`` Dataset in this tutorial. In VGG paper , the authors | |
# We use the ``CIFAR100`` dataset in this tutorial. In VGG paper, the authors |
# When training VGG , the authors first train model A , then initialized | ||
# the weights of other models with the weights of model A. Waiting for | ||
# Model A to be trained takes a long time . The authors mention how to | ||
# train with ``xavier`` initialization rather than initializing with the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
capitalization nit: xavier -> Xavier throughout
# When training VGG , the authors first train model A , then initialized | ||
# the weights of other models with the weights of model A. Waiting for |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# When training VGG , the authors first train model A , then initialized | |
# the weights of other models with the weights of model A. Waiting for | |
# When training VGG, the authors first train model A, then continue training from | |
# the resultant weights for other variants. Waiting for |
# ------------------- | ||
# | ||
|
||
class Cusotm_ImageNet(ImageNet) : |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
class Cusotm_ImageNet(ImageNet) : | |
class Custom_ImageNet(ImageNet) : |
###################################################################### | ||
# Conclusion | ||
# ---------- | ||
# We have seen how ``pretraining`` VGG from scratch . This Tutorial will be helpful to reproduce another Foundation Model . |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this needs to be expanded a bit, and I'm not sure what is meant by the Foundation Model
comment
# - Trying On ImageNet | ||
# - Try All version of Model | ||
# - Try All evaluation method in VGG paper |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
# - Trying On ImageNet | |
# - Try All version of Model | |
# - Try All evaluation method in VGG paper | |
# - Apply model to ImageNet | |
# - Try all model variants | |
# - Try additional evaluation methods |
@jbschlosser yes, I will do the editorial pass as long as we align on the overall technical content. |
Lint and Technical Details and flexible code style
@svekars Sorry for being late. I've been busy with lab work. I've made some revisions based on the feedback I received. Could you check again? |
There is a build error related to the code. |
Editorial and formatting fixes
Co-authored-by: Joel Schlosser <[email protected]>
* Complete the `Learn the Basics tutorials <https://pytorch.org/tutorials/beginner/basics/intro.html>`__ | ||
* Familiarity with basic machine learning concepts and terms | ||
|
||
If you are running this in Google Colab, install albumentations |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you are running this in Google Colab, install albumentations | |
If you are running this in Google Colab, install albumentations by running the following command: | |
.. code-block:: py | |
!pip install albumentations |
train loader fail
train loader fail
feedback accepted Re PullRequest because of network issue
Co-authored-by: Joel Schlosser <[email protected]>
@svekars Are there any other things I need to fix? |
Fixes #ISSUE_NUMBER
Description
I make a new tutorial training VGG from scratch . There are no tutorials traning Vgg from scratch.
Checklist
cc @subramen @albanD