Sign inSign up

anquev/datascience-container

By anquev

•Updated over 1 year ago

Python environment configuration for data science projects

Image
Developer tools
Data science
0

161

anquev/datascience-container repository overview

⁠Data Science DevContainer

A lightweight development environment for data science projects using uv for dependency management and ruff for linting.

⁠Quick Start

⁠Prerequisites
⁠Starting the DevContainer
  1. Clone this repository
  2. Open the project folder in VS Code
  3. When prompted, click "Reopen in Container" or press F1 and select "Remote-Containers: Reopen in Container"
  4. Wait for the container to build (this may take a few minutes the first time)
⁠Working with the Environment
  • The Python virtual environment is automatically activated in terminal sessions
  • All dependencies from pyproject.toml are pre-installed
  • Jupyter notebooks can be created and run directly in VS Code
⁠Project Structure

By default, the following structure is created:

.
├── .devcontainer/     # Container configuration
├── data/              # Store your datasets here
├── notebooks/         # Jupyter notebooks
├── src/               # Source code
└── pyproject.toml     # Project dependencies
⁠Managing Dependencies

Add new dependencies to pyproject.toml and run:

uv pip install -e .
⁠Running Python Scripts
python your_script.py

⁠Features

  • Python 3.12 environment
  • Data science packages (numpy, pandas, polars, scikit-learn, duckdb)
  • Visualization tools (matplotlib, seaborn)
  • Jupyter notebooks support
  • Fast dependency management with uv
  • Code linting with ruff

⁠Troubleshooting

If you encounter issues with missing packages:

  1. Verify you're using the correct Python interpreter:

    which python
    

    Should point to /home/vscode/.venv/bin/python

  2. Reinstall dependencies:

    uv pip install -e .
    
  3. Check VS Code Python interpreter settings (F1 → "Python: Select Interpreter")

Enjoy coding 😎

Tag summary

Content type

Image

Digest

sha256:f2ca6a55a…

Size

451.9 MB

Last updated

over 1 year ago

docker pull anquev/datascience-container:1.1