#!/bin/bash # Lockdrop Allocation Experimentation Launcher # This script automatically sets up the environment and launches the experimental notebook set -e echo "🚀 Starting Lockdrop Experimentation Environment..." # Check if Python 3 is available if ! command -v python3 &> /dev/null; then echo "❌ Python 3 is required but not installed. Please install Python 3." exit 1 fi # Create virtual environment if it doesn't exist if [ ! -d "venv" ]; then echo "📦 Creating Python virtual environment..." python3 -m venv venv fi # Activate virtual environment echo "🔧 Activating virtual environment..." source venv/bin/activate # Install/upgrade dependencies echo "📚 Installing dependencies..." pip install -q --upgrade pip pip install -q -r requirements.txt # Check if Jupyter is working if ! command -v jupyter &> /dev/null; then echo "❌ Jupyter installation failed. Please check your Python environment." exit 1 fi echo "✅ Environment ready!" echo "" echo "🎯 Opening lockdrop experimentation notebook..." echo " The notebook will open in your default browser at http://localhost:8888" echo "" echo "📝 To stop the notebook server later, press Ctrl+C in this terminal" echo "" # Launch Jupyter notebook jupyter notebook lockdrop-calculations.ipynb echo "" echo "👋 Experimentation session ended."