This comprehensive setup guide will help you get all PlotSenseAI demo projects running on your system.
- Python: 3.8 or higher
- Operating System: Windows 10+, macOS 10.14+, or Linux
- Memory: 4GB RAM minimum (8GB recommended)
- Storage: 2GB free space
- Python Package Manager: pip (comes with Python)
- Version Control: Git
- Code Editor: VS Code, PyCharm, or Jupyter Lab (recommended)
# Download from python.org or use winget
winget install Python.Python.3.11# Using Homebrew (recommended)
brew install python@3.11
# Or download from python.orgsudo apt update
sudo apt install python3.11 python3.11-pip python3.11-venvwinget install Git.Git# Git comes with Xcode Command Line Tools
xcode-select --install
# Or using Homebrew
brew install gitsudo apt install gitpython --version # Should show Python 3.8+
pip --version # Should show pip version
git --version # Should show git versiongit clone https://github.com/Havilah-Blockchain-Studios/PlotSenseAI-Hackathon-Demo-Projects.git
cd PlotSenseAI-Hackathon-Demo-ProjectsWe strongly recommend using a virtual environment to avoid dependency conflicts:
# Create virtual environment
python -m venv plotsense-env
# Activate virtual environment
# On Windows:
plotsense-env\Scripts\activate
# On macOS/Linux:
source plotsense-env/bin/activateYou should see (plotsense-env) in your terminal prompt when activated.
# Install PlotSenseAI
pip install plotsense
# Install common dependencies
pip install pandas numpy matplotlib jupytercd project_one
# Install additional dependencies
pip install ucimlrepo scikit-learn
# Start Jupyter Notebook
jupyter notebook ml_explainability_demo.ipynbVerification: The notebook should open in your browser at http://localhost:8888
cd project_two
# Install dependencies
pip install -r requirements.txt
# Run tests to verify installation
python -m pytest tests/test_detection.py
# Run demo
python examples/demo_anomaly_detection.pyExpected Output: Console output showing detected anomalies and a visualization.
cd project_three
# Install dependencies
pip install -r requirements.txt
# Run the Streamlit app
streamlit run app.pyExpected Output: Browser opens to http://localhost:8501 with the interactive app.
- Create Account: Visit Groq Console
- Generate Key: Navigate to API Keys section
- Copy Key: Format:
gsk_xxxxxxxxxxxxx - Use in App: Enter in the sidebar of Project Three
# Set environment variable
export PLOTSENSE_API_KEY="your_api_key_here"
# Or add to your shell profile (.bashrc, .zshrc)
echo 'export PLOTSENSE_API_KEY="your_key"' >> ~/.bashrcCreate a file test_installation.py:
# Test basic imports
try:
import plotsense
import pandas as pd
import numpy as np
import matplotlib.pyplot as plt
print("β
All core packages imported successfully!")
except ImportError as e:
print(f"β Import error: {e}")
# Test PlotSenseAI
try:
from plotsense import recommender
print("β
PlotSenseAI imported successfully!")
except ImportError as e:
print(f"β PlotSenseAI import error: {e}")
print("π Installation verification complete!")Run the test:
python test_installation.py# Run as administrator or use --user flag
pip install --user plotsense# Try using python3 instead of python
python3 --version
python3 -m pip install plotsense# Deactivate and recreate
deactivate
rm -rf plotsense-env
python -m venv plotsense-env
source plotsense-env/bin/activate # or plotsense-env\Scripts\activate on Windows# Install jupyter explicitly
pip install jupyter
# Or use JupyterLab
pip install jupyterlab
jupyter lab# Use different port
streamlit run app.py --server.port 8502# Create fresh environment
pip freeze > old_requirements.txt
deactivate
rm -rf plotsense-env
python -m venv plotsense-env
source plotsense-env/bin/activate
pip install plotsenseIf you encounter issues not covered here:
- Check the logs: Look for detailed error messages
- Update packages:
pip install --upgrade plotsense - Search issues: Check our GitHub Issues
- Ask for help: Create a new issue with:
- Your operating system
- Python version
- Error message
- Steps to reproduce
Once your environment is set up:
- Read the tutorials: Check out TUTORIALS.md
- Explore projects: Start with Project One for PlotSenseAI basics
- Join the community: Participate in discussions and contribute
- Build something awesome: Use these demos as inspiration for your own projects!
- PlotSenseAI Documentation
- Python Virtual Environments Guide
- Jupyter Notebook Documentation
- Streamlit Documentation
- Git Handbook
Happy coding! π