Stefan Petrov, Machine Learning Developer in Sofia, Bulgaria
Stefan Petrov

Machine Learning Developer in Sofia, Bulgaria

Member since October 8, 2019
Stefan has been fascinated by the potential of AI since high school. For the past several years, he’s been making a living as the primary developer of more than ten analytical products using R, Python, Mathematica, .NET, and Java. Recently, Stefans been focusing on operations research-type issues and using random forests, time series models, Keras, TensorFlow for neural nets, PyMC3, Stan for Bayesian models, and linear and MIP programming.
Stefan is now available for hire


  • Freelance
    Python, Machine Learning, Statistics, Reinforcement Learning...
  • Transmetrics
    Docker, TensorFlow, CPLEX, PostgreSQL, Python, R...
  • CommEq Asset Management
    R, MongoDB, Python, Natural Language Processing (NLP), Machine Learning...



Sofia, Bulgaria



Preferred Environment

PostgreSQL, JetBrains, RStudio

The most amazing...

...thing I've coded was a successive approximation algorithm for the optimal trucking schedule. We used a combination of column generation and L1 relaxation.


  • Machine Learning Engineer

    2019 - PRESENT
    • Developed machine learning algorithms for stock price prediction, resulting in Sharpe ratios of 3.2. Used an ensemble of ML, neural net, and traditional forecasting mechanisms. Created and developed an API and data pipeline using Google Cloud.
    • Worked on the analysis of news, processed through an NLP pipeline, to FOREX rate change predictions.
    • Did prediction and optimization of required inventory levels for inventory stock levels with many item types (>30000 SKU). Used ML classification and probabilistic programming, combined with operational research techniques.
    • Estimated type and severity of mental diseases from self-reported surveys (using NLP and ML techniques). Collaborated with a specializing doctor of medicine (psychiatry).
    • Worked on Spatio-temporal analysis of demographic data for income estimation on the fine-grained spatial scale (scale was different for different countries). Used particular Spatio-temporal statistical techniques.
    Technologies: Python, Machine Learning, Statistics, Reinforcement Learning, Natural Language Processing (NLP), Operations Research, Flask-RESTful, R, Julia
  • Head of Research

    2016 - PRESENT
    • Worked on one-to-three projects as the key analytical contributor on all matters analytical matters (e.g. anything requiring Optimization, statistical, ML, or AI ). projects.
    • Used ML, Statistical, and Deep Neural Network techniques for forecasting of demand time series.
    • Modeled and optimized problems transportation companies have, like: routing, network design, warehouse optimization, using ML, Linear Optimization, Approximation Algorithms MIP, CP, and Reinforcement Learning, and Probabilistic Programming.
    • Analyzed and negotiated business requirements and project directions, considering:. •data availability,. •business requirements,. •feasibility and technology to solve certain types of problems,. •performed a counterfactual analysis to prove value.
    • Businesses-collected operational data very well, but sometimes it didn't support analytical tasks so well (e.g., important data is only partially collected). Used ML, probabilistic programming, and convex optimization on such problems.
    • Performed code reviews, directed and facilitated the problem-solving process, read papers and disseminated knowledge throughout the org.
    • Worked on estimated time-of-return of rented assets, using survival analysis and other ML/statistical techniques.
    • Hired, interviewed, and mentored team members. Participated in product development and pre-sales.
    Technologies: Docker, TensorFlow, CPLEX, PostgreSQL, Python, R, Mixed-integer Linear Programming, Constraint Programming, Deep Neural Networks, Machine Learning, Statistics, Bayesian Statistics, Time Series Analysis, Team Leadership, Teamwork, IBM Watson
  • Quantitative Developer

    2016 - 2016
    CommEq Asset Management
    • Developed an algorithmic trading system with Python. Refactored the codebase to use six times fewer Lines of Code. Changed up the Machine Learning algorithm in question with one, performing better on the backtests.
    • Performed some natural language processing work for news classification and tagging (multi-label classification problem), significantly improving on the currently used models. The measurement was Hamming-Loss.
    • Worked on portfolio rebalancing part using Convex Optimization techniques.
    Technologies: R, MongoDB, Python, Natural Language Processing (NLP), Machine Learning, Time Series Analysis, Gradient Boosting, XGBoost, Convex Optimization
  • Quantitative Analyzer

    2013 - 2016
    Bwin.Party Digital Entertainment
    • Developed modules that determined the probabilities for events of interest (goals, points, and so on) and their prices (odds) for the sporting events, offered on the company sites. Used mostly Mathematica and F#.
    • Solved various BI questions (e.g., the impact of a new sports model release on revenue in that sport, customer classification, and others). Used ML and Statistical techniques, e.g. XGBoost classification, etc.
    • Revamped volleyball and a couple of other point sports models, boosting the P&L on them significantly. Used Numerical analysis algorithms, backtesting, and ML. Participated in basketball and tennis models, too.
    • Developed large parts of the currently used customer classification (dangerous or not, VIP or not, about to churn/not, and so on) models. Used Machine Learning, Deep Learning, and Probabilistic Programming Algorithms.
    • Handled pricing problems (pricing combos). Used Approximation algorithms for a nonlinear optimization problem for this.
    • Developed sports models libraries (directly deployed in production) and simple GUI clients (for Quality control by the traders) with F# and Mathematica.
    Technologies: Microsoft SQL Server, Teradata, R, Mathematica, F#, Tableau, Business Intelligence (BI), Data Science, Data Analysis, Probability Theory, Numerical Programming, Machine Learning, SQL, RStudio Shiny, Dashboards
  • Quantitative Developer

    2013 - 2013
    Blue Edge Bulgaria | Evolution Capital Management
    • Developed high-frequency trading strategies, aimed at trading in Japan, using specialized versions of PCA, ML, and optimization.
    • Implemented the main approach via technical trading-trying to identify persistent regimes in the market, based on detecting correlated quantities in the electronic trading book.
    • Worked on the backtesting/trading platform (C#, MS SQL stack).
    • Developed with R/Python for EDA and prototyping and estimation of upper bound of strategy performance before trading complications such as latency and transaction costs are considered.
    • Researched about order book dynamics (e.g., the expected lifetime of bids).
    Technologies: Microsoft SQL Server, R, Python, C#, Machine Learning, Mathematical Finance, Statistics, Time Series Analysis, Convex Optimization, Principal Component Analysis (PCA)
  • Quantitative and Back-end Developer

    2012 - 2012
    Cayetano Gaming
    • Developed a slot game with a game designer who would specify the game logic, what type of bonuses and mini-games existed, and provided the vision of how the game should "feel." This is expressed in terms of volatility of payout, bonus structure, bonus frequency, etc. For example, a "chill" could pay out small amounts very often, while a suspense-filled game might have less frequent larger payouts.
    • Worked in a team that was responsible for writing game logic and developing in-house combinatorial optimizer in order to find suitable symbol distribution so that the game "feel" and expected payout properties are satisfied.
    • Wrote three games, one of which was novel in that there was some strategy involved on the player side. This required different pricing techniques.
    • Implemented an ad-hoc statistical analysis for roulette behavior.
    Technologies: Java


  • High-frequency Backtesting Engine

    I developed a backtesting engine for semi high-frequency trading (1 minute) in R. The trading system achieved a Sharpe ratio of 1.85 in backtesting. I used R, XGBoost, regularized linear models, and an interface in Shiny.


  • Languages

    Python, Python 3, R, SQL, F#, Wolfram, Julia, C#, Scala, Java
  • Tools

    StatsModels, Mathematica, JetBrains, CPLEX, IBM Watson, Tableau
  • Paradigms

    Data Science, Linear Programming, Constraint Programming, Business Intelligence (BI), Anomaly Detection
  • Other

    Data Analytics, Algorithms, Applied Mathematics, Time Series Analysis, Forecasting, Linear Regression, Data Visualization, Graph Theory, Mathematical Modeling, Time Series, Machine Learning, Data Reporting, Product Analytics, Project Leadership, Data Mining, ARIMA Models, Statistical Modeling, Neural Networks, Natural Language Processing (NLP), Software Development, SaaS, Mathematical Finance, Statistics, Bayesian Statistics, Supply Chain Optimization, Mixed-integer Linear Programming, Gradient Boosted Trees, Customer Segmentation, Product Design, Spatial Analysis, Reinforcement Learning, Operations Research, Team Leadership, Teamwork, Gradient Boosting, Convex Optimization, Data Analysis, Probability Theory, Numerical Programming, Dashboards, Principal Component Analysis (PCA), Economics, Computer Engineering, Root Cause Analysis, Logistic Regression, Logistics, Deep Neural Networks, Recurrent Neural Networks, Random Forests, Support Vector Machines (SVM), Clustering Algorithms, Stochastic Modeling, Hierarchical Clustering, Google Data Studio
  • Frameworks

    RStudio Shiny, Apache Spark, .NET
  • Libraries/APIs

    Scikit-learn, SciPy, TensorFlow, Flask-RESTful, XGBoost
  • Platforms

    Jupyter Notebook, RStudio, Docker, Linux, Ubuntu, Google Cloud SDK
  • Storage

    MongoDB, Teradata, Microsoft SQL Server, PostgreSQL


  • Master's Degree in Mathematical Modeling in Economics
    2009 - 2012
    Sofia University - Sofia, Bulgaria
  • Bachelor's Degree in Computer Engineering
    2008 - 2012
    Nagoya Institute of Technology - Nagoya, Japan
  • Bachelor's Degree in Applied Mathematics
    2005 - 2009
    Sofia University - Sofia, Bulgaria
  • Certificate in Japanese Language Course
    2007 - 2008
    Tokyo University of Foreign Studies - Tokyo, Japan

To view more profiles

Join Toptal
Share it with others