{"id":27258676,"url":"https://github.com/macromrit/air-flick","last_synced_at":"2026-04-09T12:53:04.219Z","repository":{"id":287044360,"uuid":"963398188","full_name":"macromrit/Air-Flick","owner":"macromrit","description":"Transfer files through the air with just a gesture. Push. Pull. Done.","archived":false,"fork":false,"pushed_at":"2025-04-10T12:57:06.000Z","size":3857,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-11T03:49:32.148Z","etag":null,"topics":["css","cv2","fastapi","html","js","media-pipe","peer2peer","python","random-forest-classifier","restful-api","scikit-learn","websockets"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/macromrit.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-04-09T16:09:49.000Z","updated_at":"2025-04-10T12:57:09.000Z","dependencies_parsed_at":"2025-04-09T18:03:01.919Z","dependency_job_id":null,"html_url":"https://github.com/macromrit/Air-Flick","commit_stats":null,"previous_names":["macromrit/air-flick"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macromrit%2FAir-Flick","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macromrit%2FAir-Flick/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macromrit%2FAir-Flick/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macromrit%2FAir-Flick/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/macromrit","download_url":"https://codeload.github.com/macromrit/Air-Flick/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248339267,"owners_count":21087214,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["css","cv2","fastapi","html","js","media-pipe","peer2peer","python","random-forest-classifier","restful-api","scikit-learn","websockets"],"created_at":"2025-04-11T03:49:36.224Z","updated_at":"2025-12-30T23:05:08.487Z","avatar_url":"https://github.com/macromrit.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"readme-assets/banner.png\" alt=\"Air Flick Banner\" width=\"100%\" /\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003eAir Flick ✋\u003c/h1\u003e\n\n\u003e A gesture-based file transfer system — no wires, no taps, just air. \n\u003e This project was inspired by Huawei's gesture-based file transfer mechanism.\n\n---\n\n## 🎥 Demo Video - Click on it\n\n\n\u003cdiv align=\"center\"\u003e\n\n[![Watch the Demo](https://img.youtube.com/vi/4BMhGjixC2U/0.jpg)](https://www.youtube.com/shorts/4BMhGjixC2U)\n\n\u003c/div\u003e\n\n\n\n---\n\n## 🌬️ About the Project\n\n**Air Flick** is a system that allows users to **transfer images between two devices** using simple hand gestures. With a swipe of your hand, files are lifted into the \"air\", and with another gesture, they are delivered to a nearby device — **completely touchless**.\n\nAir Flick redefines the concept of file sharing by combining:\n- **Machine Learning gesture detection**\n- **Peer-to-peer communication**\n- **Real-time WebSocket connections**\n- **REST API-based communication**  \nAll within a **shared local network (subnet)**.\n\n---\n\n## 🛠️ How It Works\n\n1. **Pull Gesture** 🤲  \n   The user performs a **pull gesture**, recognized using **MediaPipe**, triggering the system to **select and lift** a file (image) into the air (internal buffer or shared state).\n\n2. **Push Gesture** ✋➡️  \n   The user then performs a **push gesture** toward a nearby device. The system detects the nearest peer (based on ping response time) and **drops the file** into that device.\n\n3. **Communication**  \n   - **Zeroconf** for peer discovery within subnet  \n   - **WebSockets** for real-time gesture triggers  \n   - **REST API** to send and receive images  \n\n---\n\n## 📦 Tech Stack\n\n| Component        | Technology |\n|------------------|------------|\n| Gesture Detection| MediaPipe, OpenCV, Custom ML pipeline |\n| Networking       | Zeroconf, WebSockets, HTTP (FastAPI) |\n| Frontend         | HTML, JS (with dynamic image rendering) |\n| Backend          | FastAPI (Python) |\n| Communication    | Peer-to-peer within same subnet |\n\n---\n\n## 🚀 Getting Started\n\n### 🔁 Clone the Repository\n\n```bash\ngit clone https://github.com/macromrit/Air-Flick.git\ncd Air-Flick\n```\n\n### 📦 Install Dependencies\n\n```bash\npip install -r requirements.txt\n```\n\n---\n\n## ▶️ Running the Application\n\n### Step 1: Start Peer Advertisement\n\nOpen your terminal and navigate to the `p2p` folder:\n\n```bash\ncd p2p\npython advertiser.py\n```\n\nThis script uses Zeroconf to broadcast your device's availability to other devices on the same subnet.\n\n---\n\n### Step 2: Start FastAPI Backend\n\nOpen a **new terminal window**, go to the app folder, and run the FastAPI server:\n\n```bash\ncd ../app\nuvicorn main:app --host 0.0.0.0 --reload\n```\n\nThe backend will be available at: `http://\u003cyour-ip\u003e:8000`\n\n---\n\n### Step 3: Launch the Interface\n\nOpen `webpage/index.html` in a web browser (on the same subnet as the other devices):\n\n```bash\n# For example, on most systems\nopen webpage/index.html      # macOS\nstart webpage/index.html     # Windows\nxdg-open webpage/index.html  # Linux\n```\n\nThis UI allows you to perform gesture-based file transfers.\n\n---\n\n## 🧯 Windows-Specific Fix\n\nIf **communication issues** occur on **Windows OS** (e.g., peer not detected or ping failing), follow these steps:\n\n1. Open **Windows Defender Firewall**.\n2. Click on **Advanced Settings**.\n3. Go to **Inbound Rules**.\n4. Find the rule:  \n   **File and Printer Sharing (Echo Request - ICMPv4-In)**.\n5. **Right-click** on it and **enable the rule**.\n\n✅ This allows ping (ICMP) messages required for peer ranking via latency.\n\n\u003c!-- ---\n\n## 📸 Screenshots\n\n\u003e _Add UI screenshots, gesture demo, or peer-to-peer success shots here_ --\u003e\n\n---\n\n## 📄 License\n\nThis project is licensed under the MIT License. See the [LICENSE](./LICENSE) file for details.\n\n---\n\n## 🙌 Built With\n\n- ❤️ FastAPI\n- 👋 MediaPipe\n- 📡 Zeroconf\n- 🌐 WebSockets\n- 🎯 OpenCV\n\n---\n\n## 🤝 Contributions Welcome\n\nWant to improve Air Flick or add more gesture actions and file types? Feel free to fork and open a PR. Let's make file transfers cooler than ever.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacromrit%2Fair-flick","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmacromrit%2Fair-flick","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacromrit%2Fair-flick/lists"}