I am a fourth-year PhD candidate at Mila and DIRO, supervised by Simon Lacoste-Julien.
I am currently seeking internships for 2026. My CV is available here.
I work in constrained learning: developing scalable algorithms that make deep learning models more reliable and controllable. Constrained optimization provides a principled way to enforce requirements in modern AI systems—such as fairness, sparsity, and safety. Highlights of my work can be found in the Featured Projects section below.
Research interests: Constrained Deep Learning and Applications, Feasible Learning.
Contact: juan.ramirez@mila.quebec
How can we reliably enforce requirements like fairness and safety in deep learning?
In this position paper, we argue against enforcing requirements on models through penalty terms, an approach that is often unreliable. Instead, we advocate for tailored constrained optimization algorithms, which provide a more robust framework for ensuring desirable properties.
How can researchers easily apply constrained optimization in their work?
I co-develop Cooper, an open-source library for non-convex constrained optimization. It is designed to integrate seamlessly into existing PyTorch workflows, facilitating the wider adoption of constrained methods. [Documentation] [Accompanying Paper]
Machine learning beyond optimizing for average performance.
The deployment of AI in high-stakes scenarios demands models that satisfy strict performance criteria on individual samples. This work introduces a novel learning paradigm where a model is trained to meet a target performance on each training sample, rather than optimizing an average metric.
Sep 29: New preprint! Check out Dual Optimistic Ascent (PI Control) is the Augmented Lagrangian Method in Disguise, where we show that the popular PI controller for updating Lagrange multipliers in constrained optimization is equivalent to the method of multipliers.
July 4: We are organizing a NeurIPS 2025 workshop on Constrained Optimization for Machine Learning! See you in San Diego!
May 31: We released a preprint of our position paper Position: Adopt Constraints Over Penalties in Deep Learning.
Apr 1: We just released version 1.0.0 of Cooper, a PyTorch library for non-convex constrained optimization, along with a companion paper.
Jan 22: Our latest paper Feasible Learning has been accepted at AISTATS 2025! Feasible Learning is a novel sample-centric learning paradigm where models are trained by solving a feasibility problem that bounds the loss for each training sample.
Jan 1: Elated to server as Associate Program co-Chair for ICML 2025.
Nov 1: I have been awarded the Excellence Scholarship by the Association des Diplômés de l'Université de Montréal.
Sep 6: I succeded in my predoctoral exam. I am now a PhD candidate!
Sep 1: I will be a TA for Simon Lacoste-Julien's course on Probabilistic Graphical Models for a second time.
May 1: On PI Controllers for Updating Lagrange Multipliers in Constrained Optimization has been accepted at ICML 2024! Vienna, here we come again.
Mar 04: Delighted to receive Université de Montréal's AI scholarship 2023-2024!
Jan 29: Excited to be a TA at the first edition of the Tropical Probabilistic AI School in Rio de Janeiro, Brazil! I am happy to see more AI events popping up around Latin America.
Jan 16: Balancing Act: Constraining Disparate Impact in Sparse Models has been accepted at ICLR 2024! Vienna, here we come.
Jan 12: Quentin Bertrand and I will be TAing Gauthier Gidel's Adversarial Machine Learning course at Mila and the University of Montreal.
Dec 7: Excited to give a talk at Montréal Machine Learning and Optimization (MTL MLOpt) about our recent work Balancing Act: Constraining Disparate Impact in Sparse Models.
Sep 4: Together with António Góis, I will be TAing Simon Lacoste-Julien's graduate course on Probabilistic Graphical Models at Mila.
Jul 23: Arriving in Honolulu, Hawaii, where I will have the pleasure to present Omega: Optimistic EMA Gradients. Omega, our method for stochastic min-max optimization, was awarded an oral at the LatinX in AI workshop at ICML 2023!
Jan 27: I will attend Khipu 2023 in Montevideo, Uruguay. Glad to be a part of the Latin American AI community.
Oct 14: See you at the PyTorch conference 2022 in New Orleans! Cooper will be making an appearance (poster).
Sep 14: I will be presenting my first NeurIPS paper: Controlled Sparsity via Constrained Optimization or: How I Learned to Stop Tuning Penalties and Love Constraints in New Orleans.
Sep 05: Excited to start a PhD in Artificial Intelligence under the supervision of Simon Lacoste-Julien at Mila and the University of Montreal.
Jul 8: Attending the Sparsity in Neural Networks workshop. We are presenting our latest work on implicit neural representations: L0onie: Compressing COINs with L0-constraints.
Dec 17: Flexible Learning of Sparse Neural Networks via Constrained L0 Regularization, won the best poster award at the LatinX in AI Workshop @ NeurIPS 2021!
Nov 1: Starting an internship at Mila. I will join Simon Lacoste-Julien's group under the supervision of Jose Gallego-Posada.
Jul 1: I graduated from the BSc in Mathematical Engineering at Universidad EAFIT! Plus, got a mention for my contributions to the student organization. Check out my Linkedin post about it.
Jan 14: I am auditing Ioannis Mitliagkas' graduate course on Deep Learning Theory at Université de Montréal.
Jul 2020: Jose Gallego-Posada, PhD student at Mila will be my supervisor for my undergraduate thesis. I will be working on deep generative models.
Jun 2019: Now part of McKinsey & Co. in Belgium as a research intern. Working with Antoine Stevens and Patrick Dehout in ML for the agricultural and chemical industries.
Jan 2019: Arrived in Louvain-la-Neuve, Belgium for an exchange semestrer at Université Catholique de Louvain.
Nov 2017: I have been appointed as president of CIGMA-OE, the Mathematical Engineering chapter of the Student Organization at Universidad EAFIT.
Dec 2015: I was awarded a full scholarship for the Bachelor's degree in Mathematical Engineering at Universidad EAFIT.
Dec 2015: Scored amongst the best 0.1% on the Colombian high school examination ICFES.
Dec 2015: Ranked first in the National Chemistry Olympiads of Universidad de Antioquia.
* denotes equal contribution. ^ denotes equal supervision.
J. Gallego-Posada*, Juan Ramirez*, M. Hashemizadeh* and S. Lacoste-Julien. Cooper: A Library for Constrained Optimization in Deep Learning. arXiv preprint at arXiv:2504.01212, 2025.
Juan Ramirez*, I. Hounie*, J. Elenter*, J. Gallego-Posada*, M. Hashemizadeh, A. Ribeiro^ and S. Lacoste-Julien^. Feasible Learning. In AISTATS, 2025.
M. Sohrabi*, Juan Ramirez*, T. H. Zhang, S. Lacoste-Julien and J. Gallego-Posada. On PI Controllers for Updating Lagrange Multipliers in Constrained Optimization. In ICML, 2024.
M. Hashemizadeh*, Juan Ramirez*, R. Sukumaran, G. Farnadi, S. Lacoste-Julien and J. Gallego-Posada. Balancing Act: Constraining Disparate Impact in Sparse Models. In ICLR, 2024.
J. Gallego-Posada, Juan Ramirez, A. Erraqabi, Y. Bengio and S. Lacoste-Julien. Controlled Sparsity via Constrained Optimization or: How I Learned to Stop Tuning Penalties and Love Constraints. In NeurIPS, 2022.
Juan Ramirez, R. Sukumaran, Q. Bertrand and G. Gidel. Omega: Optimistic EMA Gradients. LatinX in AI workshop at ICML, 2023.
Juan Ramirez and J. Gallego-Posada. L0onie: Compressing COINs with L0-constraints. Sparsity in Neural Networks Workshop, 2022.
J. Gallego-Posada, Juan Ramirez and A. Erraqabi.
Flexible Learning of Sparse Neural Networks via Constrained L0 Regularization.
LatinX in AI Workshop at NeurIPS, 2021.
Fall 23 and 24: Probabilistic Graphical Models by Simon Lacoste-Julien.
Winter 24: Adversarial Machine Learning by Gauthier Gidel.
Summer schools: Tropical Probabilistic AI School (2024), Lisbon Machine Learning School (2024).
Associate Program co-Chair for ICML 2025.
Organizer of the first Constrained Optimization for Machine Learning workshop at NeurIPS 2025.
Reviewer for TMLR, ICLR 2026, ICML 2025, AISTATS 2025, and NeurIPS 2024. Reviewer for the LatinX in AI workshops at NeurIPS 2024, ICML 2024, and ICML 2023.
Social chair for the LatinX in AI workshop at NeurIPS 2024 and visa chair for the LatinX in AI workshop at ICML 2024.
Juan Ramirez © - Last updated on