Skip to content

bkusuma/kaggle-competition-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Kaggle Competition Template

Here is a template you can use for managing your work and submissions for Kaggle competitions.

This project is based on the kaggle_filestructure repository from mikezawitkowski but with tweaks by me, an increased folder depth, and, most importantly, the ability to "Create a new repository" using this template!

Directory Structure

.. 
└── kaggle
     ├── input                      <- data files for the competition 
     │    └── {competition-slug}
     │          ├── test.csv        <- example data
     │          └── train.csv       <- example data
     ├── src                        <- source scripts
     ├── working                    <- the working directory
     │    ├── notebook.ipynb        <- example Jupyter notebook
     │    └── submission.csv        <- example submission
     ├── Original_README.md         <- from kaggle.com/competitions/predict-west-nile-virus
     └── README.md                  <- what you're reading right now
  • Above the file list, click Use this template.
  • Then, select Create a new repository.

Screenshot of the "Use this template" button and the dropdown menu expanded to show the "Open in a codespace" option.

  • After using the template and cloning the repo, replace {competition-slug} in the input directory with the slug from the competition you're working on
  • Since the GitHub structure doesn't perfectly line up with Kaggle's, you will need to prepend filepath with "../.."
    • e.g. '/kaggle/input/titanic/train.csv' from a Kaggle notebook becomes '../../kaggle/input/titanic/train.csv' for a Jupyter notebook in the "working" directory.

A copy of the Original_README is in the repository as well but please note it was last updated 2015/05/04