File size: 3,791 Bytes
113e8ae
 
 
 
 
 
5994469
 
113e8ae
 
 
 
 
 
 
 
 
 
 
 
 
 
ef5fb53
113e8ae
ef5fb53
 
 
113e8ae
ef5fb53
113e8ae
5994469
113e8ae
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
294b859
113e8ae
 
 
294b859
113e8ae
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
---
# For reference on dataset card metadata, see the spec: https://github.com/huggingface/hub-docs/blob/main/datasetcard.md?plain=1
# Doc / guide: https://huggingface.co/docs/hub/datasets-cards
{}
---

**Curated by:** [Andrew Rosemberg & Contributors]

# Dataset Card for Parametric Optimization Problems

<!-- Provide a quick summary of the dataset. -->
This dataset is a collection of parametrized optimization problems stored in [MathOptFormat](https://jump.dev/MathOptFormat/) (`.mof.json`) files. Each file encodes a mathematical optimization problem—its objective, constraints, and parameters—using a standardized data structure for portability and ease of parsing.

## Dataset Details

### Dataset Description

<!-- Provide a longer summary of what this dataset is. -->
Parametric optimization problems arise in scenarios where certain elements (e.g., coefficients, constraints) may vary according to problem parameters. This collection gathers different problem instances across various domains (e.g., power systems, control, resource allocation) in a uniform JSON-based format. Users can load, modify, and solve these problems with specialized libraries—particularly with the [LearningToOptimize.jl](https://github.com/andrewrosemberg/LearningToOptimize.jl) package in Julia.

A general form of a parameterized convex optimization problem is 

$$
\begin{aligned}
&\min_{x} \quad f(x; \theta) \\
&\text{subject to} \quad g_i(x; \theta) \leq 0, \quad i = 1,\dots, m \\
&\quad\quad\quad\quad A(\theta)x = b(\theta)
\end{aligned}
$$

where \\( \theta \\) is the parameter.

## Usage

Using the [LearningToOptimize.jl](https://github.com/andrewrosemberg/LearningToOptimize.jl) package in julia, 
users can generate problem variants by sampling parameter values follwing defined rules:

```julia
using LearningToOptimize

general_sampler(
    "PGLib/Load/ACPPowerModel/pglib_opf_case3_lmbd.m_ACPPowerModel_load.mof.json";
    samplers=[
        (original_parameters) -> scaled_distribution_sampler(original_parameters, 10000),
        (original_parameters) -> line_sampler(original_parameters, 1.01:0.01:1.25), 
        (original_parameters) -> box_sampler(original_parameters, 300),
    ],
)

```

where `scaled_distribution_sampler`, `line_sampler` and `box_sampler` are some examples of built in samplers.


### Outside Dataset Sources 

<!-- Provide the basic links for the dataset. -->
- **PGLib:** [power-grid-lib](https://github.com/power-grid-lib/pglib-opf)
- **JuMP** [JuMP Tutorials](https://github.com/jump-dev/JuMP.jl)

## Uses

<!-- Address questions around how the dataset is intended to be used. -->
### Direct Use
These problems can be directly used to:
- Test **solver performance** on a variety of instances.
- **Benchmark** machine learning models that learn optimization proxies.
- Generate **synthetic scenarios** by applying parametric samplers for stress-testing or research.

### Out-of-Scope Use
- The dataset is not intended for training general-purpose NLP or computer vision models.
- Direct personal or sensitive information is not included, so any privacy-infringing use does not apply.

## Dataset Structure

TBD

## File Structure
In a typical `.mof.json` file, you will find:
- **Objectives**: Specifies the optimization sense (e.g., `Min`, `Max`) and the functions to be optimized.
- **Variables**: A list of decision variables, potentially including parameters as special variable entries.
- **Constraints**: Each constraint references a function (made up of one or more variables) and a set specifying bounds, including `Parameter` sets for parametric variables.

An example snippet for a parameter:
```json
{
  "function": {
    "name": "name_of_parameter",
    "type": "Variable"
  },
  "set": {
    "type": "Parameter",
    "value": 1.0
  }
}