Top AI Repos β open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
A Pytorch Computer Vision template to quick start your next project! ππ
| Date | Stars |
|---|---|
| 2026-07-24 | 364 |
| 2026-07-25 | 364 |
| 2026-07-28 | 364 |
| 2026-07-30 | 364 |
| 2026-07-31 | 364 |
| 2026-08-06 | 364 |
Today
β stars today
This week
β stars this week
This month
β stars this month
Momentum
0.0
growth rate 0.00%/day
# Pytorch Deep Learning Template ### A clean and simple template to kick start your next dl project ππ *Francesco Saverio Zuppichini* In this article, we present you a deep learning template based on Pytorch. This template aims to make it easier for you to start a new deep learning computer vision project with PyTorch. The main features are: - modularity: we split each logic piece into a different python submodule - data-augmentation: we included [imgaug](https://imgaug.readthedocs.io/en/latest/) - ready to go: by using [poutyne](https://pypi.org/project/Poutyne/) a Keras-like framework you don't have to write any train loop. - [torchsummary](https://github.com/sksq96/pytorch-summary) to show a summary of your models - reduce the learning rate on a plateau - auto-saving the best model - experiment tracking with [comet](https://www.comet.ml/) - logging using python [logging](https://docs.python.org/3/library/logging.html) module - a playground notebook to quick test/play around ## Installation Clone the repo and go inside it. Then, run: ``` pip install -r requirements.txt ``` ### Motivation Let's face it, usually data scientists are not software engineers and they usually end up with spaghetti code, most of the time on a big unusable Jupiter-notebook. With this repo, I have proposed a clean example of how your code should be split and modularized to make scalability and sharability possible. In this example, we will try to classify Darth Vader and Luke Skywalker. We have 100 images per class gathered using google images. The dataset is [here](https://drive.google.com/open?id=1LyHJxUVjOgDIgGJL4MnDhA10xjejWuw7). You just have to extract it in this folder and run main.py. We are fine-tuning resnet18 and it should be able to reach > 90% accuracy in 5/10 epochs. ## Structure The template is inside `./template`. ``` . βββ callbacks // here you can create your custom callbacks βββ checkpoint // were we store the trained models βββ data // here we define our dataset β βββ transformation // custom transformation, e.g. resize and data augmentation βββ dataset // the data β βββ train β βββ val βββ logger.py // were we define our logger βββ losses // custom losses βββ main.py βββ models // here we create our models β βββ MyCNN.py β βββ resnet.py β βββ utils.py βββ playground.ipynb // a notebook that can be used to fast experiment with things βββ Project.py // a class that represents the project structure βββ README.md βββ requirements.txt βββ test // you should always perform some basic testing β βββ test_myDataset.py βββ utils.py // utilities functions ``` **We strongly encourage to play around with the template** ### Keep your structure clean and concise Every deep learning project has at least three mains steps: - data gathering/processing - modeling - training/evaluating ## Project One good idea is to store all the paths at an interesting location, e.g. the dataset folder, in a shared class that can be accessed by anyone in the folder. You should never hardcode any paths and always define them once and import them. So, if you later change your structure you will only have to modify one file. If we have a look at `Project.py` we can see how we defined the `data_dir` and the `checkpoint_dir` once for all. We are using the 'new' [Path](https://docs.python.org/3/library/pathlib.html) APIs that support different OS out of the box, and also makes it easier to join and concatenate paths.  For example, if we want to know the data location we canΒ : ```python3 from Project import Project project = Project() print(project.data_dir) # /foo/baa/β¦/dataset ``` ## Data In the `data` package you can define your own Dataset, as always by subclassing `torch.data.utils.Dataset`, exposing transformations and utilities to work with your data. In our example, we directly used `ImageDataset` from `torchvision` but we included a sk
Excerpt of 8,087 characters
Read on GitHubWould you bet a product on this? Bounded 0β100 and slow moving.
matched fp:2b930e6be4d12bb5, topic:deep-learning, topic:pytorch
matched fp:2b930e6be4d12bb5, topic:computer-vision, desc:computer vision, readme:computer vision