Spaces:
Sleeping
Sleeping
| title: MotionScope Pro | |
| emoji: π₯ | |
| colorFrom: blue | |
| colorTo: purple | |
| sdk: docker | |
| app_port: 7860 | |
| app_file: app.py | |
| pinned: false | |
| # β οΈ IMPORTANT SETUP STEP | |
| **If you see "Welcome to your static Space"**: | |
| 1. Go to the **Settings** tab above. | |
| 2. Scroll to **Select Space SDK**. | |
| 3. Change it from **Static** to **Docker**. | |
| 4. Click **Update Space**. | |
| The app will then build and start! | |
| # π₯ MotionScope Pro β Movement Detector | |
| A professional Streamlit application combining **MediaPipe hand tracking** and **background subtraction motion detection**. | |
| ## Features | |
| | Feature | Description | | |
| |---|---| | |
| | ποΈ Hand Tracking | Real-time MediaPipe hand landmark detection | | |
| | π Motion Detection | Background subtraction (MOG2) with contour filtering | | |
| | β‘ Combined Mode | Both hand tracking + motion detection simultaneously | | |
| | πΉ Video Upload | Upload MP4/AVI/MOV/MKV β process β download result | | |
| | π· Webcam Snapshot | Capture a photo and process it instantly | | |
| ## How to Download & Run | |
| ### Option 1: Run on Hugging Face Spaces | |
| Click the **App** tab above to use the application directly in your browser! | |
| ### Option 2: Run Locally | |
| 1. **Clone the repository:** | |
| ```bash | |
| git clone https://huggingface.co/spaces/Jack1808/MotionScope-Pro | |
| cd MotionScope-Pro | |
| ``` | |
| 2. **Create a virtual environment (recommended):** | |
| ```bash | |
| python -m venv venv | |
| source venv/bin/activate # On Windows: venv\Scripts\activate | |
| ``` | |
| 3. **Install dependencies:** | |
| ```bash | |
| pip install -r requirements.txt | |
| ``` | |
| 4. **Run the application:** | |
| - **Web Interface:** | |
| ```bash | |
| streamlit run app.py | |
| ``` | |
| - **Real-time Webcam Window:** | |
| ```bash | |
| python live_run.py | |
| ``` | |
| 1. **Sidebar** β choose detection mode and tune parameters (threshold, min area, confidence). | |
| 2. **Video Upload tab** β upload a video, click **Process Video**, watch the live preview, then download the result. | |
| 3. **Webcam Snapshot tab** β take a photo from your webcam and see the detected landmarks / motion overlay. | |
| ## Project Structure | |
| ``` | |
| motion_detector/ | |
| βββ app.py # Streamlit UI | |
| βββ detector.py # Core MovementDetector class | |
| βββ requirements.txt # Python dependencies | |
| βββ README.md # This file | |
| ``` | |
| ## Requirements | |
| - Python 3.10+ | |
| - A webcam (for the snapshot tab) | |