ferhatbou/detect_English_language_speaking
0
1---2title: Video Accent Analyzer3emoji: ๐ง4colorFrom: green5colorTo: blue6sdk: gradio7sdk_version: 5.33.18app_file: app.py9pinned: false10---11 12Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference13 14# ๐ง Video Accent Analyzer15 16A sophisticated Python-based tool that analyzes English accents in videos using advanced machine learning techniques. Supports multiple video sources and provides detailed accent analysis with interactive visualizations.17 18## ๐ Features19 20### Video Support21- YouTube videos with browser cookie integration22- Loom recordings23- Direct MP4 video links24- Local video file uploads25 26### Accent Analysis27- Detects 6 distinct English accents:28 - ๐ฌ๐ง British English29 - ๐บ๐ธ American English30 - ๐ฆ๐บ Australian English31 - ๐จ๐ฆ Canadian English32 - ๐ฎ๐ณ Indian English33 - ๐ Neutral English34- Provides confidence scores for accent detection35- Assesses English proficiency level36- Analyzes audio quality metrics37 38### Technical Capabilities39- Automatic video download and processing40- Audio extraction and preprocessing41- Multi-chunk analysis for improved accuracy42- Real-time progress tracking43- Interactive Plotly visualizations44- Batch processing support45 46## ๐ Installation47 48```bash49pip install -r requirements.txt50 51```52# ๐ป Usage53Web Interface54Start the application:55python app.py56Open the provided URL in your browser57Enter a video URL or upload a video file58Adjust the maximum duration (10-120 seconds)59Click "Analyze Video"60 61# Python API62```from video_accent_analyzer import VideoAccentAnalyzer63 64# Initialize analyzer65analyzer = VideoAccentAnalyzer()66 67# Analyze video68results = analyzer.analyze_video_url("your_video_url", max_duration=30)69 70# Display results71analyzer.display_results(results) 72```73 74# โ๏ธ Technical Requirements75Python 3.7+76FFmpeg installed on system77Required Python packages:78gradio โฅ4.0.079plotly โฅ5.0.080torch81transformers82librosa83soundfile84yt-dlp85browser-cookie3 โฅ0.19.186 87## ๐ Results88๐ฏ Best Practices89- Use videos with clear audio and minimal background noise90For Best Results91Use videos under 2 minutes in length92Ensure clear audio quality93Single speaker per analysis94Continuous speech segments95Minimum background noise96Known Limitations97Multiple speakers may affect accuracy98Heavy background noise can impact results99Very short speech segments (<10s) may be less accurate100Some region-restricted videos might not be accessible101 102# ๐ง Development103The project consists of three main components: 104video_accent_analyzer.py: Core analysis engine105app.py: Gradio web interface106Supporting utilities for video processing