This repository is a python-package that allows to fit a deep learning model predicting the price of a taxi course using the TaxiFare dataset.
- Open colab.research.google.com
- Create a new collab notebook, and change the runtime to GPU
- Pip-install this repo (which is a package) directly from within your collab notebook, by running this cell below
! pip install --quiet git+https://github.com/lewagon/taxi-fare-deepYou can now try to fit and predict using the following basic workflow
# Import Trainer class
from taxifare_deep.trainer import Trainer
# Download a sub-sample of rows to train on
trainer = Trainer(nrows=10000)
# Clean data
trainer.clean()
# Preprocess data and create train/test/split
trainer.preproc(test_size=0.3)
# Fit neural network and show training performance
trainer.fit(plot_history=True, verbose=1)
# evaluate on test set (by default the holdout from train/test/split)
trainer.evaluate(X_test=None, y_test=None)- Feel free to fork this repo to your own github account, and clone it to your local hard drive
- Try to understand how the code works, following basic workflow above (you can run it on a local notebook after doing
pip install -e .from the root folder) - Feel free to improve it as you see fit