Skip to content

A comprehensive Python-based web application that analyzes coding profiles from various competitive programming platforms (Codeforces, LeetCode, CodeChef) and calculates a unified normalized rating. The system also features course bonus calculation from Coursera profiles and displays coding activity through interactive heatmaps.

Notifications You must be signed in to change notification settings

Aksh-Agrawal/normalization_main

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

32 Commits
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿ† Unified Ranking System

Version Python Database Last Updated

๐ŸŽ‰ NEW: Enhanced Database System v2.0 - Production-ready architecture with advanced analytics and user management!

A comprehensive coding skills assessment platform that integrates multiple programming platforms with educational achievements to provide unified rankings.

๐ŸŒŸ Complete Overview

The Unified Ranking System is a sophisticated Python application that revolutionizes how programmers track and assess their coding skills across multiple platforms. By combining competitive programming ratings, educational achievements, and activity patterns, it provides a holistic view of your programming prowess.

๐ŸŽฏ What It Does

  • ๐Ÿ“Š Multi-Platform Integration: Automatically fetches ratings from CodeForces, LeetCode, CodeChef, and AtCoder
  • ๐ŸŽ“ Educational Tracking: Scrapes Coursera profiles to extract course completions and calculate intelligent bonus points
  • ๐Ÿ“ˆ Activity Visualization: Generates GitHub-style heatmaps showing coding consistency across platforms
  • ๐Ÿ”ข Unified Rankings: Uses sophisticated algorithms to combine platform ratings with educational bonuses
  • ๐Ÿ‘ฅ Multi-User Support: Secure authentication system supporting multiple users with persistent data
  • ๐Ÿ’พ Data Persistence: SQLite database stores all user data locally with encrypted passwords

๐Ÿš€ Key Features

๐Ÿ… Platform Rating Integration

  • CodeForces (Max: 3000) - Competitive programming excellence
  • LeetCode (Max: 2500) - Interview preparation mastery
  • CodeChef (Max: 1800) - Programming contest proficiency
  • AtCoder (Max: 2800) - Japanese competitive programming platform

Smart Auto-Fetch System:

  • ๐Ÿ”„ Automatic rating retrieval via official APIs
  • ๐Ÿ”„ Real-time data validation and error handling
  • ๐Ÿ”„ Intelligent fallback to manual entry when needed

๐ŸŽ“ Educational Bonus System

Coursera Profile Scraping:

  • ๐Ÿ“š Automatic extraction of completed courses from public profiles
  • ๐Ÿ›๏ธ Institution recognition (Harvard, Stanford, MIT get premium scores)
  • ๐Ÿ“… Completion date tracking for timeline analysis
  • ๐Ÿงฎ AI-powered bonus calculation based on multiple factors

Intelligent Bonus Calculation (Max: 45 points per course):

  • Institution Factor (0-10): University prestige and global ranking
  • Duration Factor (0-5): Course depth, specialization length
  • Field Factor (0-10): Relevance to tech industry (AI, Data Science, Programming)
  • Skills Factor (0-20): Market demand analysis and salary impact

๐Ÿ“ˆ Advanced Analytics

GitHub-Style Activity Heatmaps:

  • ๐ŸŸฉ Daily coding activity visualization across all platforms
  • ๐Ÿ“Š Combined activity metrics from multiple sources
  • ๐ŸŽจ Beautiful visual progress representation
  • ๐Ÿ“… Yearly overview with streak tracking

Sophisticated Ranking Algorithm:

  • โš–๏ธ Weighted platform scores based on difficulty
  • ๐Ÿ“Š Normalized rating scales for fair comparison
  • ๐ŸŽฏ Platform difficulty consideration in weighting
  • ๐ŸŽ“ Seamless educational bonus integration
  • ๐Ÿ“ˆ Final unified ranking calculation

๐Ÿ—„๏ธ Enhanced Database System v2.0

๐Ÿš€ Production-Ready Architecture

The system now features a comprehensive, normalized database schema designed for scalability and performance:

๐Ÿ”’ Enhanced Security & Authentication

  • bcrypt password hashing (upgraded from SHA-256)
  • Session management with tracking and analytics
  • Email verification system (ready for activation)
  • Rich user profiles with timezone, language preferences

๐Ÿ“Š Advanced Data Management

  • 15 specialized tables with proper relationships
  • Foreign key constraints ensuring data integrity
  • Strategic indexes for optimal query performance
  • Generated columns for automatic calculations

๐Ÿ† Comprehensive Tracking

  • Platform Management: 6 pre-configured platforms with auto-fetch
  • Course Intelligence: 12 top institutions + 14 smart categories
  • Achievement System: Badges, milestones, and gamification
  • Analytics Engine: System-wide insights and reporting

๐Ÿ› ๏ธ Database Management Tools

# System health check
python db_analyzer.py

# Generate analytics report
python db_manager.py report

# Create backup
python db_manager.py backup

# Export data
python db_manager.py export

๐ŸŽฎ Three Application Modes

1. ๐Ÿ”ง Simple Version (Recommended)

Perfect for: Beginners, most users, systems with compatibility issues

  • โœ… Visible password input (universal compatibility)
  • โœ… Complete feature set with intuitive interface
  • โœ… Automatic platform rating fetching
  • โœ… Full Coursera integration and bonus calculation
  • โœ… Heatmap generation and user profiles

2. ๐Ÿ›ก๏ธ Advanced Version (Secure)

Perfect for: Security-conscious users, advanced developers

  • โœ… Hidden password input with enhanced security
  • โœ… All Simple Version features plus security enhancements
  • โœ… Advanced error handling and logging
  • โœ… Object-oriented architecture for maintainability
  • โœ… Enhanced data validation and sanitization

3. ๐Ÿ“Š Original Single-User Version

Perfect for: Quick testing, demonstration, single-session use

  • โœ… No registration required - immediate access
  • โœ… Direct platform input and instant calculations
  • โœ… Full ranking computation and heatmap generation
  • โš ๏ธ No data persistence between sessions
  • โš ๏ธ Single user only (no authentication system)

๐Ÿš€ Quick Start

Prerequisites

  • Python 3.7+ installed on your system
  • Internet connection for API calls and web scraping
  • Public profiles on coding platforms (for auto-fetch)
  • Public Coursera profile (optional, for course bonus)

Installation & Launch

  1. Download/Clone this repository
  2. Navigate to the backend folder
  3. Double-click start.bat (Windows) or run from command line

The intelligent launcher will:

  • โœ… Automatically detect Python installation
  • ๐Ÿ“ฆ Install required packages if missing
  • ๐ŸŽฏ Present you with three version options
  • ๐Ÿ› ๏ธ Handle errors and provide guidance

๐Ÿ“Š How It Works

๐Ÿ”ข Ranking Calculation

Total Score = (Weighted Platform Score) + (Course Bonus Points)

Where:
- Weighted Platform Score = ฮฃ(Platform Rating ร— Platform Weight)
- Course Bonus Points = ฮฃ(Individual Course Bonuses)
- Platform Weights = Dynamic based on difficulty and participation

๐ŸŽ“ Course Bonus Examples

  • Stanford Machine Learning: ~40-45 points (top-tier institution + high-demand field)
  • MIT Computer Science: ~35-40 points (prestigious institution + core programming)
  • Google Data Analytics: ~25-30 points (industry recognition + practical skills)
  • Harvard CS50: ~30-35 points (prestigious + comprehensive programming)

๐Ÿ“ˆ Platform Weighting

  • Difficulty Assessment: Harder platforms receive higher weights
  • Participation Analysis: Active user bases get consideration
  • Rating Distribution: Normalized across different rating scales
  • Industry Recognition: Platform reputation in hiring processes

๐Ÿ› ๏ธ Technical Architecture

๐Ÿ—๏ธ Core Components

  • Authentication System: Secure user management with bcrypt password hashing
  • API Integration Layer: Robust web scraping and API calls with error handling
  • Ranking Engine: Sophisticated algorithms for unified score calculation
  • Visualization Engine: Beautiful heatmap generation with statistical analysis
  • Data Persistence: SQLite database with optimized queries and data integrity

๐Ÿ”ง Platform APIs

  • CodeForces API: Official REST API for contest and user data
  • LeetCode GraphQL: Advanced querying for comprehensive profile data
  • CodeChef Web Scraping: Intelligent parsing with rate limiting
  • Coursera Profile Scraping: Selenium-based extraction with mock data fallback

๐Ÿ“ฑ User Experience Features

๐ŸŽฏ Smart Auto-Detection

  • Platform Profile Validation: Real-time verification of usernames
  • Rating Verification: Cross-reference with platform data
  • Course Certificate Validation: Only certified completions count
  • Error Recovery: Intelligent fallbacks and user guidance

๐Ÿ“Š Rich Analytics

  • Progress Tracking: Historical rating changes over time
  • Activity Patterns: Peak coding times and consistency metrics
  • Achievement Insights: Course completion impact on overall ranking
  • Comparative Analysis: Performance across different platforms

๐Ÿ”’ Privacy & Security

  • Local Data Storage: All information stays on your machine
  • No Cloud Dependencies: Complete offline functionality
  • Encrypted Credentials: Secure password storage with bcrypt
  • Ethical Scraping: Respectful rate limiting and public data only

๐Ÿ“š Full Documentation

For complete setup instructions, troubleshooting, and advanced usage:

๐Ÿ“– Complete README.md

๐Ÿ“‚ Project Structure

normalization_main/
โ”œโ”€โ”€ backend/                        # ๐ŸŽฏ Main application directory
โ”‚   โ”œโ”€โ”€ start.bat                   # ๐Ÿš€ Universal launcher
โ”‚   โ”œโ”€โ”€ main_simple.py             # ๐Ÿ”ง Simple version
โ”‚   โ”œโ”€โ”€ main_oop_fixed.py          # ๐Ÿ›ก๏ธ Advanced version
โ”‚   โ”œโ”€โ”€ main.py                    # ๐Ÿ“Š Original single-user
โ”‚   โ”œโ”€โ”€ README.md                  # ๐Ÿ“– Complete documentation
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ services/                  # ๐Ÿ—๏ธ Core business logic
โ”‚   โ”‚   โ”œโ”€โ”€ auth_service.py        #   ๐Ÿ‘ค User authentication
โ”‚   โ”‚   โ”œโ”€โ”€ ranking_service.py     #   ๏ฟฝ Rating calculations
โ”‚   โ”‚   โ””โ”€โ”€ input_handlers/        #   ๐ŸŽฎ User interface logic
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ rating_scraper_api/        # ๐Ÿ”Œ Platform integrations
โ”‚   โ”‚   โ”œโ”€โ”€ CodeForces_api.py      #   ๐ŸŸฆ CodeForces API
โ”‚   โ”‚   โ”œโ”€โ”€ leetcode_api.py        #   ๐ŸŸจ LeetCode GraphQL
โ”‚   โ”‚   โ””โ”€โ”€ CodeChef_api.py        #   ๏ฟฝ CodeChef scraping
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ cousera/                   # ๐ŸŽ“ Educational features
โ”‚   โ”‚   โ””โ”€โ”€ coursera_scraper.py    #   ๐Ÿ•ท๏ธ Profile extraction
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ bonus_calculatorF/         # ๐Ÿงฎ Bonus calculation
โ”‚   โ”‚   โ””โ”€โ”€ bonus_calculator.py    #   ๐Ÿ’ฐ Intelligent scoring
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ heatmap/                   # ๐Ÿ“ˆ Visualization
โ”‚   โ”‚   โ””โ”€โ”€ heat_map.py            #   ๐ŸŽจ GitHub-style graphs
โ”‚   โ”‚
โ”‚   โ”œโ”€โ”€ logic_formulas/            # ๐Ÿ”ข Ranking algorithms
โ”‚   โ”‚   โ”œโ”€โ”€ formula_main.py        #   โš–๏ธ Core ranking logic
โ”‚   โ”‚   โ””โ”€โ”€ ranking_platform.py    #   ๐Ÿ—๏ธ Platform management
โ”‚   โ”‚
โ”‚   โ””โ”€โ”€ [additional modules]       # ๐Ÿ”ง Supporting functionality
โ”‚
โ””โ”€โ”€ README.md                      # ๐Ÿ“„ This overview file

๐ŸŽ‰ Success Stories & Use Cases

๐ŸŽฏ Career Development

"Used the unified ranking to showcase my skills during job interviews. The combination of competitive programming ratings and educational certificates gave recruiters a complete picture of my abilities."

๐Ÿ“ˆ Progress Tracking

"The heatmap visualization motivated me to code more consistently. Seeing my activity patterns helped me identify and fix gaps in my practice routine."

๐ŸŽ“ Educational Impact

"Adding my Coursera certifications boosted my ranking significantly. The intelligent bonus system recognized the value of my Stanford ML course and Google certificates."

๐Ÿ† Competitive Analysis

"Compared my performance across platforms and identified where to focus my efforts. The weighted scoring system showed that improving my CodeForces rating had the biggest impact."

๐Ÿš€ Getting Started

Ready to unify your coding achievements? Here's how:

๐ŸŽฏ Immediate Use

  1. Download or clone this repository
  2. Open the backend folder
  3. Run start.bat (Windows) or execute from terminal
  4. Choose your preferred version (Simple recommended for first-time users)
  5. Follow the guided setup process

๐Ÿ“Š First Steps

  1. Register your account (Simple/Advanced versions)
  2. Add your coding platform usernames
  3. Connect your Coursera profile (optional but recommended)
  4. Generate your first unified ranking
  5. Explore heatmaps and analytics

๐ŸŽ“ Maximizing Your Score

  • Optimize Platform Performance: Focus on platforms with higher weights
  • Strategic Course Selection: Choose high-value courses from prestigious institutions
  • Consistent Activity: Maintain regular coding practice for better heatmap metrics
  • Profile Optimization: Keep platform profiles public for automatic data fetching

<<<<<<< HEAD ๐Ÿ† Transform how you track and showcase your programming journey. Start building your unified coding profile today!

About

A comprehensive Python-based web application that analyzes coding profiles from various competitive programming platforms (Codeforces, LeetCode, CodeChef) and calculates a unified normalized rating. The system also features course bonus calculation from Coursera profiles and displays coding activity through interactive heatmaps.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published