Skip to content

HassanAlgoz/B5

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

113 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Instructions

Lab Setup

A. Local Setup

  1. Use git clone to clone the repository
  2. Use uv sync to install the dependencies in a virtual environment

How to run VS Code Notebooks

B. Colab Setup

  1. Open the notebook in Colab
  2. Use git clone to clone the repository (to get helper files, assets, and datasets)
  3. Run %cd <path to the repository>
  4. Sync dependencies from pyproject.toml into the Colab system environment: !uv sync --system (notice the ! prefix tells notebooks this is a shell command)

Remember to save your work. Any files created in Colab will be lost if you don't save them elsewhere (Download).

C. Code Locally, Run in Colab (Hybrid)

See: Connect notebooks to Colab servers>

How to Download Kaggle Dataset to Colab?

First, obtain your API token from Kaggle:

  1. Go to Kaggle Settings
  2. Scroll to the API section and click Create New Token
  3. Copy that token and insert it as a Colab secret under with the label KAGGLE_API_TOKEN
import os

# This reads your colab secrets
# and set the environment variables on them
from google.colab import userdata
os.environ['KAGGLE_KEY'] = userdata.get('KAGGLE_API_TOKEN')
os.environ['KAGGLE_USERNAME'] = "KAGGLE_COLAB"

# Example Dataset
dataset_name = "shuyangli94/food-com-recipes-and-user-interactions"
!kaggle datasets download -d {dataset_name} 

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors