LibMOON
is an open-source library built on PyTorch for gradient based MultiObjective (MOO). See the latest documentation for detailed introductions and API instructions.
Star or fork us on GitHub — it motivates us a lot!
-
[Sep 26 2024] LibMOON paper is accepted to NeurIPS 2024.
-
[Aug 27 2024] Added support for LoRA-PSL (ICML 2024). Many thanks to Weiyu Chen for his contribution.
-
[June 20 2024] Supports most popular gradient-based methods: MGDAUB, Random, EPO, PMGDA, Aggregation-based methods, PMTL, HVGrad, MOOSVGD ...
-
[April 20 2024] Supports PMTL (NeurIPS 2019), HvGrad (EMO 2022). Many thanks for Dr. Xi Lin's contribution and helpful communications from Dr. Hao Wang.
-
[March 17 2024] Supports three MOBO-PSL methods. Many thanks to Liang Zhao's contribution.
-
[March 10 2024] Supports hypernetwork-based Pareto set learning methods.
LibMOON supports a large number of synthetic problems, including ZDT, DTLZ, RE, MAF, WFG, Fi and UF problems.
Method | ||
---|---|---|
Fairness classification | Binary cross entropy | DEO |
Multiobjective classification | Cross entropy loss BR | Cross entropy loss UL |
MO machine learning | Mean square loss | Mean square loss |
MO distribution alignment | Similarity 1 | Similarity 2 |
Notes:
- DEO: Difference of Equality of Opportunity.
LibMOON includes a variety of solvers tailored for different needs as image below shows.
- GradAggSolver
- EPOSolver
- MOO-SVGDSolver
- MGDASolver
- PMGDASolver
- PMTLSolver
- HVGradSolver
Method | Property | Paper | Complexity |
---|---|---|---|
EPO (Mahapatra et al 2020) | Exact solutions | paper | |
MGDA-UB (Sener et al 2018) | Arbitrary solutions | paper | |
PMGDA (Zhang et al 2024) | Specific solutions | paper | |
Random (Lin et al 2021) | Arbitrary solutions | paper | |
MOO-SVGD (Liu et al 2021) | Diverse solutions | paper | |
PMTL (Lin et al 2019) | Sector solutions | paper | |
HVGrad (Deist et al 2021) | Maximal HV solutions | paper | |
Agg-LS (Miettinen et al 1999) | Convex hull solutions | book | |
Agg-Tche (Zhang et al 2007) | Exact solutions | paper | |
Agg-mTche (Ma et al 2017) | Exact solutions | paper | |
Agg-PBI (Zhang et al 2007) | Approximate exact solutions | paper | |
Agg-COSMOS (Ruchte et al 2007) | Approximate exact solutions | paper | |
Agg-SoftTche (Lin et al 2024) | Fast approximate exact solutions | paper |
Notations:
-
$m$ is the number of objectives. -
$K$ is the number of subproblems. -
$n$ is the number of decision variables.
In neural network methods,
LibMOON supports various models of PSL solvers, categorized as follows:
Method | Property | Paper |
---|---|---|
EPO-based PSL (Navon et al 2021) | Exact solutions | paper |
PMGDA-based PSL (Zhang et al 2024) | Specific solutions | paper |
Aggregation-baed PSL (Sener et al 2018) | Minimal aggregation function solutions | paper |
Evolutionary PSL (Sener et al 2018) | Mitigate local minimal by ES | paper |
LoRA PSL (Chen et al 2024) | Light model structure | paper |
- PSL-MONO
- PSL-DirHV-EI
- DirHV-EGO
Libmoon is available on PyPI. You can install it using pip:
pip install libmoon==0.1.11
- Example1: Finding a size-K (K=5) Pareto solutions with four lines of code.
from libmoon.solver.gradient.methods import EPOSolver
from libmoon.util.synthetic import synthetic_init
from libmoon.util.prefs import get_uniform_pref
from libmoon.util import get_problem
problem = get_problem(problem_name='ZDT1')
prefs = get_uniform_pref(n_prob=5, n_obj=problem.n_obj, clip_eps=1e-2)
solver = EPOSolver(step_size=1e-2, n_iter=1000, tol=1e-2, problem=problem, prefs=prefs)
res = solver.solve(x=synthetic_init(problem, prefs))
- Example2: PSL in a problem with three lines of solving problem and two lines of evaluating the results.
from libmoon.solver.psl.core_psl import BasePSLSolver
from libmoon.util import get_problem
from libmoon.util.prefs import get_uniform_pref
from torch import Tensor
problem = get_problem(problem_name='ZDT1')
# agg list [ ’ls ’, ’tche ’, ’mtche ’, ’pbi ’, ... ]
prefs = get_uniform_pref(n_prob=100, n_obj=problem.n_obj, clip_eps=1e-2)
solver = BasePSLSolver(problem, solver_name='agg_ls')
model, _ = solver.solve()
eval_y = problem.evaluate(model(Tensor(prefs).cuda()))
@article{zhang2024libmoon,
title={LibMOON: A Gradient-based MultiObjective OptimizatioN Library in PyTorch},
author={Xiaoyuan Zhang and Liang Zhao and Yingying Yu and Xi Lin and Yifan Chen and Han Zhao and Qingfu Zhang},
year={2024},
journal={Advances in Neural Information Processing Systems},
}
Name | Institution | Role |
---|---|---|
Xiaoyuan Zhang (*) | CityUHK | Pareto set learning/MOO solvers/Project lead |
Liang Zhao (*) | CityUHK | MOBO |
Yingying Yu (*) | CityUHK | Software design |
Xi Lin | CityUHK | Software design |
(*): The first three authors contribute equally to this work.
We sincernely thank the following contributors for their valuable contributions or feedbacks. We also want thanks for our collobrators from XDU, SZU, SUSTech, ECNU, NEU, SEU for their early use of our code.
We also espeically thank for the following contributors: Xuehai Pan, Hongzong Li, Zhe Zhao, Meitong Liu, Weiduo Liao, Baijiong Lin, Weiyu Chen, Prof. Jingda Deng, Prof. Yifan Chen, Prof. Ke Shang, Prof. Genghui Li, Prof. Han Zhao, Prof. Zhenkun Wang, Prof. Tao Qin, and Prof. Qingfu Zhang (Corresponding) .
(1) A telecommunication project.
(2) Two top conference papers recent submitted.
- Xiaoyuan Zhang [xzhang2523-c@my.cityu.edu.hk]
- QQ group:
- Wechat group:
- Slack group: https://cityu-hiv5987.slack.com/archives/C07GU3N2H2S
LibMOON is not allowed for commercial use without permission. For commerical use, please contact Xiaoyuan Zhang or Prof. Qingfu Zhang.