Software

Live MATLAB contest and judging platform

A MATLAB judge I built for our university contest, MATLAB Mania 2020. It judged the live contest for 200+ contestants and viewers.

  • 200+live users
  • parallelMATLAB workers

Architecture · block diagram

  • Main data path
  • Logic
  • Processor
  • Memory
  • Interconnect
  • Off-chip
Live MATLAB contest platform: forms and sheets into a Python judge, MATLAB engine workers, MySQL and a PHP live ranklistGoogle FormsubmissionsGoogle SheetsregistrationPython judge serverMATLAB enginePython · load balancingMATLAB workersparallel · backgroundMySQLPHP live ranklistcontestants + viewers200+ liveMATLAB APIAPI
FIG. 01

The story

Online judges for C++ and Python are widely available. For MATLAB Mania 2020 at KUET, we found no MATLAB judge that we could use. I was a judge and problem setter, and I built the platform. It takes submissions, runs them in MATLAB, and publishes results and a live ranklist for 200+ concurrent contestants and viewers.

What I built

Submissions arrive through a Google Form into Google Sheets, next to a registration form. A Python judge server picks them up and drives a Python MATLAB engine. The engine runs MATLAB workers in parallel in the background, on my own MATLAB subscription. Results go into MySQL. A PHP live ranklist answers real-time requests from contestants and viewers through a custom API.

The hardest problem

MATLAB has a long startup time, and contest traffic arrives in bursts. Persistent background MATLAB workers kept the judging latency low, and the server spread submissions across them. The judge engine also reported its own status and performance, so I could catch problems during the contest.

Result

The platform judged the live contest for 200+ contestants and viewers. Submissions, test runs and ranklist updates were automatic.

Original design diagram
Original design diagram of the live MATLAB judge: forms, sheets, Python judge server, MATLAB engine, MySQL, PHP ranklist
Where it's used

Where you'd find something like this

01

Programming contests and online assessments

02

Automated grading for engineering courses

Available · Asia/Dhaka (UTC+6)

Have hardware that needs to work?

Tell me what you're building. I'll come back with questions, a rough scope and an estimate, usually within 2 days.

PAD 01 · I/O