Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

python-multiobjective-optimization

БесплатноБез исполняемых скриптовНе проверен

Expert guidance for multiobjective optimization in Python - Pareto optimality, evolutionary algorithms (NSGA-II, NSGA-III, MOEA/D), scalarization methods…

jkitchinот jkitchin★ 45 звёзд на GitHub11 установок в других каталогах

Об этом скилле

Python Multiobjective Optimization

Overview

Master multiobjective optimization where you must simultaneously optimize multiple conflicting objectives. Unlike single-objective optimization that finds one optimal solution, multiobjective optimization discovers a Pareto front - a set of trade-off solutions where improving one objective worsens another.

Core value: Find optimal trade-offs between competing objectives (cost vs. performance, risk vs. return, speed vs. accuracy) and enable informed decision-making across the Pareto frontier.

When to Use

Use multiobjective optimization when:

  • Optimizing multiple conflicting objectives simultaneously
  • Need trade-off analysis between competing goals
  • Decision-makers must choose from Pareto-optimal alternatives
  • No single "best" solution exists without preference information

Examples:

  • Portfolio optimization: maximize return, minimize risk
  • Engineering design: minimize cost, maximize performance, minimize weight
  • Manufacturing: maximize throughput, minimize defects, minimize energy
  • Drug design: maximize efficacy, minimize toxicity, maximize bioavailability
  • Vehicle routing: minimize distance, minimize time, minimize vehicles

Don't use when:

  • Only one objective exists (use single-objective optimization)
  • Objectives can be combined into single metric with known weights
  • One objective is vastly more important than others

Key Concepts

Pareto Dominance

Solution x dominates solution y if:

  1. x is no worse than y in all objectives
  2. x is strictly better than y in at least one objective
def dominates(obj_x, obj_y, minimize=True):
    """
    Check if obj_x dominates obj_y (for minimization).

    Returns True if obj_x dominates obj_y.
    """
    if minimize:
        # For minimization: x dominates y if all x_i <= y_i and at least one x_i < y_i
        better_or_equal = all(x <= y for x, y in zip(obj_x, obj_y))
        strictly_better = any(x < y for x, y in zip(obj_x, obj_y))
    else:
        # For maximization: x dominates y if all x_i >= y_i and at least one x_i > y_i
        better_or_equal = all(x >= y for x, y in zip(obj_x, obj_y))
        strictly_better = any(x > y for x, y in zip(obj_x, obj_y))

    return better_or_equal and strictly_better

Pareto Front (Pareto Frontier)

The Pareto front is the set of all non-dominated solutions - solutions where you cannot improve one objective without worsening another.

Properties:

  • All points on the Pareto front are equally "optimal" from mathematical perspective
  • Choosing among Pareto solutions requires preference information
  • Moving along the front trades one objective for another

Utopia and Nadir Points

  • Utopia point: Best possible value for each objective (usually infeasible)
  • Nadir point: Worst value among Pareto-optimal solutions for each objective

Methods Overview

Scalarization Approaches

Convert multiobjective problem to series of single-objective problems.

1. Weighted Sum

  • Combine objectives with weights: minimize w₁f₁(x) + w₂f₂(x)
  • Pros: Simple, uses any single-objective solver
  • Cons: Cannot find non-convex Pareto fronts, sensitive to scaling

2. Weighted Metrics (Lp-norm)

  • Minimize ||f(x) - ideal||ₚ with weights
  • Pros: Can find non-convex fronts (p=∞)
  • Cons: Requires ideal point estimation

3. ε-Constraint Method

  • Minimize one objective, constrain others: min f₁(x) s.t. f₂(x) ≤ ε
  • Pros: Finds entire Pareto front including non-convex regions
  • Cons: Many single-objective solves, requires constraint bounds

4. Goal Programming

  • Minimize deviation from target goals
  • Pros: Intuitive when targets known
  • Cons: Requires setting goals

Evolutionary Algorithms

Population-based metaheuristics that evolve Pareto front approximations.

1. NSGA-II (Non-dominated Sorting Genetic Algorithm II)

  • Most popular multiobjective evolutionary algorithm
  • Fast non-dominated sorting + crowding distance
  • Pros: Robust, well-tested, handles 2-3 objectives well
  • Cons: Degrades with many objectives (>3)

2. NSGA-III

  • Extension of NSGA-II for many objectives (4+)
  • Reference point-based selection
  • Pros: Scales to many objectives
  • Cons: More complex parameter tuning

3. MOEA/D (Multiobjective Evolutionary Algorithm based on Decomposition)

  • Decomposes problem into scalar subproblems
  • Pros: Efficient, good for many objectives
  • Cons: Requires careful decomposition setup

4. Other Algorithms

  • SPEA2, PAES, GDE3, SMS-EMOA, etc.

Comparison

Method Objectives Pareto Front Type Pros Cons
Weighted Sum 2-3 Convex only Simple, fast Misses non-convex regions
ε-Constraint 2-3 Any Complete coverage Many solves needed
NSGA-II 2-3 Any Robust, popular Poor for many objectives
NSGA-III 4+ Any Handles many objectives Complex tuning
MOEA/D 4+ Any Ef
Полный SKILL.md на GitHub

Установить python-multiobjective-optimization в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

*

FAQ

Что делает скилл python-multiobjective-optimization?

Expert guidance for multiobjective optimization in Python - Pareto optimality, evolutionary algorithms (NSGA-II, NSGA-III, MOEA/D), scalarization methods, Pareto front analysis, and implementation with pymoo, platypus, and DEAP

Как установить скилл python-multiobjective-optimization?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл python-multiobjective-optimization запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить python-multiobjective-optimization с