Dockerfile

This commit is contained in:
Mateusz 2024-04-01 16:52:51 +02:00
parent 1f518e4c14
commit 52be040de8
1 changed files with 3 additions and 0 deletions

View File

@ -1,4 +1,5 @@
import os
import sys
from kaggle.api.kaggle_api_extended import KaggleApi
import pandas as pd
import numpy as np
@ -10,6 +11,8 @@ from sklearn.model_selection import train_test_split
def download_kaggle_dataset():
print(f'Kaggle API key: {os.environ["KAGGLE_KEY"]}')
os.environ["KAGGLE_USERNAME"] = sys.argv[1]
os.environ["KAGGLE_KEY"] = sys.argv[2]
kaggle = KaggleApi()
kaggle.authenticate()
kaggle.dataset_download_files("mlg-ulb/creditcardfraud", path="./", unzip=True)