{"cells":[{"metadata":{},"cell_type":"markdown","source":"# A simple method to install package that you wanna use offline"},{"metadata":{},"cell_type":"markdown","source":"During the game, we need a lot of packages, like numpy, pandas and so on. Most of them are pre-installed by kaggle, but some are not.\n\nAs we can't use the internet when submitting, we need to install them offline. \n\nHere I'll show you a simple example by installing face_recognition."},{"metadata":{},"cell_type":"markdown","source":"## First, switch internet on"},{"metadata":{"trusted":true},"cell_type":"code","source":"!pip install face_recognition","execution_count":null,"outputs":[]},{"metadata":{},"cell_type":"markdown","source":"As you can see, the face_recognition is based on dlib and face-recognition-models. So the kernel will download them first.\n### Download .whl file directly\nClick the link in the second line, and the .whl file for face_recognition will be downloaded in your PC.\n### Find compiled .tar.gz file\nInstalling tar.gz file is a little bit troublesome, but we can find the corresponding whl file in the `/tmp/.cache/pip/wheels/`"},{"metadata":{"trusted":true},"cell_type":"code","source":"!cp /tmp/.cache/pip/wheels/96/ac/11/8aadec62cb4fb5b264a9b1b042caf415de9a75f5e165d79a51/dlib-19.19.0-cp36-cp36m-linux_x86_64.whl /kaggle/working\n!cp /tmp/.cache/pip/wheels/d2/99/18/59c6c8f01e39810415c0e63f5bede7d83dfb0ffc039865465f/face_recognition_models-0.3.0-py2.py3-none-any.whl /kaggle/working","execution_count":null,"outputs":[]},{"metadata":{},"cell_type":"markdown","source":"Click the `Refresh` button next to the `/kaggle/working` and then you can download the .whl files"},{"metadata":{},"cell_type":"markdown","source":"## Upload the .whl files to your own dataset\nGo to https://www.kaggle.com/datasets and click `New dataset`. Now you can make your own dataset."},{"metadata":{},"cell_type":"markdown","source":"## Add Data and then install offline"},{"metadata":{"trusted":true},"cell_type":"code","source":"","execution_count":null,"outputs":[]}],"metadata":{"kernelspec":{"language":"python","display_name":"Python 3","name":"python3"},"language_info":{"pygments_lexer":"ipython3","nbconvert_exporter":"python","version":"3.6.4","file_extension":".py","codemirror_mode":{"name":"ipython","version":3},"name":"python","mimetype":"text/x-python"}},"nbformat":4,"nbformat_minor":1}