simoptlib 1.0.2__tar.gz → 1.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {simoptlib-1.0.2/simoptlib.egg-info → simoptlib-1.1.1}/PKG-INFO +134 -101
- {simoptlib-1.0.2 → simoptlib-1.1.1}/README.md +125 -98
- {simoptlib-1.0.2 → simoptlib-1.1.1}/pyproject.toml +10 -3
- simoptlib-1.1.1/simopt/GUI.py +30 -0
- simoptlib-1.1.1/simopt/__init__.py +1 -0
- simoptlib-1.1.1/simopt/__main__.py +12 -0
- simoptlib-1.1.1/simopt/base.py +1783 -0
- simoptlib-1.1.1/simopt/data_farming_base.py +1031 -0
- simoptlib-1.1.1/simopt/directory.py +199 -0
- simoptlib-1.1.1/simopt/experiment_base.py +6898 -0
- simoptlib-1.1.1/simopt/gui/data_farming_window.py +1397 -0
- simoptlib-1.1.1/simopt/gui/df_object.py +812 -0
- simoptlib-1.1.1/simopt/gui/experiment_window.py +4226 -0
- simoptlib-1.1.1/simopt/gui/main_menu.py +115 -0
- simoptlib-1.1.1/simopt/gui/new_experiment_window.py +6636 -0
- simoptlib-1.1.1/simopt/gui/plot_window.py +1108 -0
- simoptlib-1.1.1/simopt/gui/toplevel_custom.py +111 -0
- simoptlib-1.1.1/simopt/models/__init__.py +1 -0
- simoptlib-1.1.1/simopt/models/amusementpark.py +766 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/chessmm.py +200 -87
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/cntnv.py +209 -106
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/contam.py +328 -167
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/dualsourcing.py +270 -122
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/dynamnews.py +216 -100
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/example.py +157 -75
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/facilitysizing.py +332 -168
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/fixedsan.py +229 -126
- simoptlib-1.1.1/simopt/models/hotel.py +1105 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/ironore.py +367 -174
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/mm1queue.py +218 -110
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/network.py +294 -121
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/paramesti.py +185 -76
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/rmitd.py +254 -103
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/san.py +229 -92
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/sscont.py +293 -130
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/models/tableallocation.py +228 -99
- simoptlib-1.1.1/simopt/solvers/__init__.py +1 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/solvers/adam.py +164 -79
- simoptlib-1.1.1/simopt/solvers/aloe.py +406 -0
- simoptlib-1.1.1/simopt/solvers/astrodf.py +1102 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/solvers/neldmd.py +247 -85
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simopt/solvers/randomsearch.py +62 -23
- simoptlib-1.1.1/simopt/solvers/spsa.py +435 -0
- simoptlib-1.1.1/simopt/solvers/strong.py +1035 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1/simoptlib.egg-info}/PKG-INFO +134 -101
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simoptlib.egg-info/SOURCES.txt +8 -0
- simoptlib-1.0.2/simopt/GUI.py +0 -3522
- simoptlib-1.0.2/simopt/__init__.py +0 -0
- simoptlib-1.0.2/simopt/base.py +0 -926
- simoptlib-1.0.2/simopt/data_farming_base.py +0 -381
- simoptlib-1.0.2/simopt/directory.py +0 -144
- simoptlib-1.0.2/simopt/experiment_base.py +0 -2782
- simoptlib-1.0.2/simopt/models/__init__.py +0 -0
- simoptlib-1.0.2/simopt/models/amusementpark.py +0 -569
- simoptlib-1.0.2/simopt/models/hotel.py +0 -500
- simoptlib-1.0.2/simopt/solvers/__init__.py +0 -0
- simoptlib-1.0.2/simopt/solvers/aloe.py +0 -303
- simoptlib-1.0.2/simopt/solvers/astrodf.py +0 -538
- simoptlib-1.0.2/simopt/solvers/spsa.py +0 -279
- simoptlib-1.0.2/simopt/solvers/strong.py +0 -622
- {simoptlib-1.0.2 → simoptlib-1.1.1}/LICENSE +0 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/setup.cfg +0 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simoptlib.egg-info/dependency_links.txt +0 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simoptlib.egg-info/requires.txt +0 -0
- {simoptlib-1.0.2 → simoptlib-1.1.1}/simoptlib.egg-info/top_level.txt +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: simoptlib
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.1.1
|
|
4
4
|
Summary: A testbed for simulation-optimization experiments.
|
|
5
|
-
Author-email: David Eckman <eckman@tamu.edu>, Shane Henderson <sgh9@cornell.edu>, Sara Shashaani <sshasha2@ncsu.edu>
|
|
5
|
+
Author-email: David Eckman <eckman@tamu.edu>, Shane Henderson <sgh9@cornell.edu>, Sara Shashaani <sshasha2@ncsu.edu>, William Grochocinski <wagrocho@ncsu.edu>
|
|
6
6
|
License: MIT License
|
|
7
7
|
|
|
8
8
|
Copyright (c) 2019 simopt-admin
|
|
@@ -30,59 +30,91 @@ Project-URL: Documentation, https://simopt.readthedocs.io/en/latest/
|
|
|
30
30
|
Classifier: Programming Language :: Python :: 3
|
|
31
31
|
Classifier: License :: OSI Approved :: MIT License
|
|
32
32
|
Classifier: Operating System :: OS Independent
|
|
33
|
-
Requires-Python: >=3.
|
|
33
|
+
Requires-Python: >=3.8
|
|
34
34
|
Description-Content-Type: text/markdown
|
|
35
35
|
License-File: LICENSE
|
|
36
|
+
Requires-Dist: numpy>=1.21.6
|
|
37
|
+
Requires-Dist: scipy>=1.7.3
|
|
38
|
+
Requires-Dist: matplotlib>=3.2.2
|
|
39
|
+
Requires-Dist: pandas>=1.3.5
|
|
40
|
+
Requires-Dist: seaborn>=0.11.2
|
|
41
|
+
Requires-Dist: mrg32k3a>=1.0.0
|
|
36
42
|
|
|
37
|
-
|
|
43
|
+

|
|
38
44
|
|
|
45
|
+
## About the Project
|
|
39
46
|
SimOpt is a testbed of simulation-optimization problems and solvers. Its purpose is to encourage the development and constructive comparison of simulation-optimization (SO) solvers (algorithms). We are particularly interested in the finite-time performance of solvers, rather than the asymptotic results that one often finds in related literature.
|
|
40
47
|
|
|
41
|
-
The most-up-to-date publication about this library is [Eckman et al. (2021)](https://eckman.engr.tamu.edu/wp-content/uploads/sites/233/2022/01/SimOpt-software-paper.pdf).
|
|
42
|
-
|
|
43
|
-
|
|
44
48
|
For the purposes of this project, we define simulation as a very general technique for estimating statistical measures of complex systems. A system is modeled as if the probability distributions of the underlying random variables were known. Realizations of these random variables are then drawn randomly from these distributions. Each replication gives one observation of the system response, i.e., an evaluation of the objective function or stochastic constraints. By simulating a system in this fashion for multiple replications and aggregating the responses, one can compute statistics and use them for evaluation and design.
|
|
45
49
|
|
|
46
50
|
Several papers have discussed the development of SimOpt and experiments run on the testbed:
|
|
47
|
-
* [
|
|
48
|
-
* [
|
|
49
|
-
* [
|
|
51
|
+
* [Eckman et al. (2024)](https://ieeexplore.ieee.org/document/10408734) studies feasibility metrics for stochastically constrained simulation-optimization problems in preparation for introducing related metrics in SimOpt.
|
|
52
|
+
* [Shashaani et al. (2024)](https://dl.acm.org/doi/10.1145/3680282) conducts a large data-farming experiment over solver factors to learn relationships between their settings and a solver's finite-time performance.
|
|
53
|
+
* [Eckman et al. (2023)](https://pubsonline.informs.org/doi/10.1287/ijoc.2023.1273) is the most up-to-date publication about SimOpt and describes the code architecture and how users can interact with the library.
|
|
54
|
+
* [Eckman et al. (2023)](https://pubsonline.informs.org/doi/10.1287/ijoc.2022.1261) introduces the design of experiments for comparing solvers; this design has been implemented in the latest Python version of SimOpt. For detailed description of the terminology used in the library, e.g., factors, macroreplications, post-processing, solvability plots, etc., see this paper.
|
|
50
55
|
* [Eckman et al. (2019)](https://www.informs-sim.org/wsc19papers/374.pdf) describes in detail changes to the architecture of the MATLAB version of SimOpt and the control of random number streams.
|
|
51
|
-
* [
|
|
52
|
-
|
|
56
|
+
* [Dong et al. (2017)](https://www.informs-sim.org/wsc17papers/includes/files/179.pdf) conducts an experimental comparison of several solvers in SimOpt and analyzes their relative performance.
|
|
57
|
+
* [Pasupathy and Henderson (2011)](https://www.informs-sim.org/wsc11papers/363.pdf) describes an earlier interface for MATLAB implementations of problems and solvers.
|
|
58
|
+
* [Pasupathy and Henderson (2006)](https://www.informs-sim.org/wsc06papers/028.pdf) explains the original motivation for the testbed.
|
|
53
59
|
|
|
54
60
|
## Code
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
## Documentation
|
|
59
|
-
Full documentation for the source code can be found **[here](https://simopt.readthedocs.io/en/latest/index.html)**.
|
|
60
|
-
|
|
61
|
-
## Getting Started
|
|
62
|
-
The most straightforward way to interact with the library is to [clone](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) this repository. *(If you anticipate making improvements or contributions to SimOpt, you should first [fork](https://docs.github.com/en/get-started/quickstart/fork-a-repo) the repository so that you can later request your changes be integrated via GitHub's pull request feature.)* Alternatively, you can choose to install the library as a Python package; see the sections titled **Package** and **Basic Example** below for more details about this option.
|
|
63
|
-
|
|
64
|
-
Download a copy of the cloned repository to your local machine and navigate to the `simopt` folder in your preferred integrated development environment (IDE). You will need to make sure that you have the following dependencies installed: Python 3, `numpy`, `scipy`, `matplotlib`, `pandas`, `seaborn`, and `mrg32k3a`. Run the command ``` python -m pip install numpy scipy matplotlib pandas seaborn mrg32k3a``` to install them from the terminal.
|
|
65
|
-
|
|
66
|
-
The `demo` folder contains a handful of useful scripts that can be easily modified, as directed in the comments.
|
|
61
|
+
### Python
|
|
62
|
+
- The [`master branch`](https://github.com/simopt-admin/simopt/tree/master) contains the source code for the latest stable release of the testbed
|
|
63
|
+
- The [`development branch`](https://github.com/simopt-admin/simopt/tree/development) contains the latest code for the testbed, but may contain more bugs than the master branch
|
|
67
64
|
|
|
68
|
-
|
|
65
|
+
### Matlab
|
|
66
|
+
> ⚠️ MATLAB versions of this testbed are no longer supported
|
|
67
|
+
- The [`matlab branch`](https://github.com/simopt-admin/simopt/tree/matlab) contains a previous stable version of the testbed written in MATLAB
|
|
69
68
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
* `demo_problem_solver.py`: Run multiple macroreplications of a solver on a problem, save the outputs to a .pickle file in the `experiments/outputs` folder, and save plots of the results to .png files in the `experiments/plots` folder.
|
|
73
|
-
|
|
74
|
-
* `demo_problems_solvers.py`: Run multiple macroreplications of groups of problem-solver pairs and save the outputs and plots.
|
|
69
|
+
## Documentation
|
|
70
|
+
Full documentation for the source code can be found on our **[readthedocs page](https://simopt.readthedocs.io/en/latest/index.html)**.
|
|
75
71
|
|
|
76
|
-
|
|
72
|
+
[](https://simopt.readthedocs.io/en/latest/?badge=latest)
|
|
77
73
|
|
|
78
|
-
|
|
74
|
+
## Getting Started
|
|
75
|
+
### Requirements
|
|
76
|
+
- Python >= 3.8
|
|
77
|
+
- To check your Python version, open a terminal and run `python --version`. If you see a message along the lines of `Command not found`, then you likely don't have Python installed. If you know you have it installed but are getting a `Command not found` error, then you may need to [add Python to your PATH](https://realpython.com/add-python-to-path/).
|
|
78
|
+
- For new installs, [Miniconda or Anaconda](https://www.anaconda.com/download) is recommended ([read about the differences between Miniconda and Anaconda](https://docs.anaconda.com/distro-or-miniconda/)). If you already have a compatible IDE (such as VS Code), we've found that Miniconda will work fine at 1/10 of the size of Anaconda. It is ***highly recommended*** to check the box during installation to add Python/Miniconda/Anaconda to your system PATH.
|
|
79
|
+
- Ruby >= 2.5 (required for datafarming)
|
|
80
|
+
- Included on MacOS, but Windows users will need to grab it from [here](https://rubyinstaller.org/).
|
|
81
|
+
- `datafarming` gem < 2.0 (required for datafarming)
|
|
82
|
+
- This can be installed via `gem install datafarming -v 1.4` once Ruby is installed/configured.
|
|
83
|
+
- If experiencing issues, make sure that you are not using version 2.0 or later as those releases does not include the required files.
|
|
84
|
+
- Python packages for `numpy`, `scipy`, `matplotlib`, `pandas`, `seaborn`, `sphinx`, `mrg32k3a`, and `jupyter`.
|
|
85
|
+
- If using conda/miniconda, run `conda env create -f environment.yml` to create the `simopt` environment. Then run `conda activate simopt` to load the environment.
|
|
86
|
+
- Otherwise, run `pip install numpy scipy matplotlib pandas seaborn sphinx mrg32k3a jupyter`.
|
|
87
|
+
|
|
88
|
+
### Downloading Source Code
|
|
89
|
+
There are two ways to download a copy of the source code onto your machine:
|
|
90
|
+
1. Download the code in a zip file by clicking the green `<> Code` button above repo contents and clicking the `Download ZIP` option, then unzip the code to a folder on your computer. This does not require `git` to be installed but makes downloading updates to the repository more challenging.
|
|
91
|
+

|
|
92
|
+
|
|
93
|
+
3. [Clone](https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository) the branch you'd like to download to a folder on your computer. This requires `git` to be installed but makes downloading updates to the repository much easier.
|
|
94
|
+
|
|
95
|
+
If you do not need the source code for SimOpt, you may install the library as a Python package instead. See the [Package](#package) and [Basic Example](#basic-example) sections for more details about this option.
|
|
96
|
+
|
|
97
|
+
The `demo` folder contains a handful of useful scripts that can be easily modified, as directed in the comments:
|
|
98
|
+
|
|
99
|
+
| File | Description |
|
|
100
|
+
| ---------------------------------------- | ----------- |
|
|
101
|
+
| `demo_model.py` | Run multiple replications of a simulation model and report its responses |
|
|
102
|
+
| `demo_problem.py` | Run multiple replications of a given solution for an SO problem and report its objective function values and left-hand sides of stochastic constraints |
|
|
103
|
+
| `demo_problem_solver.py` | Run multiple macroreplications of a solver on a problem, save the outputs to a `.pickle` file in the `experiments/outputs` folder, and save plots of the results to `.png` files in the `experiments/plots` folder |
|
|
104
|
+
| `demo_problems_solvers.py` | Run multiple macroreplications of groups of problem-solver pairs and save the outputs and plots |
|
|
105
|
+
| `demo_data_farming_model.py` | Create a design over model factors, run multiple replications at each design point, and save the results to a comma separated value (`.csv`) file in the `data_farming_experiments` folder |
|
|
106
|
+
| `demo_san-sscont-ironorecont_experiment` | Run multiple solvers on multiple versions of (s, S) inventory, iron ore, and stochastic activiy network problems and produce plots |
|
|
79
107
|
|
|
80
108
|
## Graphical User Interface (GUI) - User Guide
|
|
81
109
|
|
|
82
|
-
###
|
|
83
|
-
To
|
|
110
|
+
### Main Menu
|
|
111
|
+
To open the GUI, run `python -m simopt`. This will launch the main menu. From the menu, you will be given 2 options:
|
|
112
|
+
1. Open the `Data Farm Models` window
|
|
113
|
+
2. Open the `Simulation Optimization Experiments` window ([read more](#simulation-optimization-experiments))
|
|
114
|
+
|
|
115
|
+
### Simulation Optimization Experiments
|
|
84
116
|
|
|
85
|
-
|
|
117
|
+
#### Overview
|
|
86
118
|
From the GUI, you can create a specified **problem-solver pair** or a **problem-solver group**, run macroreplications, and generate plots. The main page provides ways to create or continue working with experiments:
|
|
87
119
|
|
|
88
120
|
1. Create an individual **problem-solver pair** with customized problem and solver factors.
|
|
@@ -91,7 +123,6 @@ From the GUI, you can create a specified **problem-solver pair** or a **problem-
|
|
|
91
123
|
|
|
92
124
|
At the bottom of the main page, there is a workspace containing all **problem-solver pair**s and **problem-solver group**s. The first tab lists the **problem-solver pair**s ready to be run or post-replicated, the second tab lists the **problem-solver group**s made from the cross-design or by generating a **problem-solver group** from partial set of **problem-solver pair** in the first tab, and the third tab lists those **problem-solver pair**s that are ready to be post-normalized and prepared for plotting.
|
|
93
125
|
|
|
94
|
-
|
|
95
126
|
#### 1. Creating a **problem-solver pair**
|
|
96
127
|
This is the main way to add **problem-solver pair**s to the queue in the workspace.
|
|
97
128
|
1. First, select a solver from the "Solver" dropdown list. Each of the solvers has an abbreviation for the type of problems the solver can handle. Once a solver is selected, the "Problem" list will be sorted and show only the problems that work with the selected solver.
|
|
@@ -99,43 +130,18 @@ This is the main way to add **problem-solver pair**s to the queue in the workspa
|
|
|
99
130
|
3. All solvers with unique combinations of factors must have unique names, i.e., no two solvers can have the same name, but different factors. If you want to use the same solver twice for a problem but with different solver factors, make sure you change the name of the solver accordingly. For example, if you want to create two **problem-solver pair**s with the same problem and solver but with or without CRN for the solver, you can change the name of the solver of choice for each pair to reflect that. This name will appear in the queue within the workspace below.
|
|
100
131
|
4. Select a problem from the "Problem" dropdown list.
|
|
101
132
|
Each problem has an abbreviation indicating which types of solver is compatible to solve it. The letters in the abbreviation stand for:
|
|
102
|
-
<table>
|
|
103
|
-
<tr>
|
|
104
|
-
<th> Objective </th>
|
|
105
|
-
<th> Constraint </th>
|
|
106
|
-
<th> Variable </th>
|
|
107
|
-
<th> Direct Gradient Observations </th>
|
|
108
|
-
</tr>
|
|
109
|
-
<tr>
|
|
110
|
-
<td> Single (S) </td>
|
|
111
|
-
<td> Unconstrained (U) </td>
|
|
112
|
-
<td> Discrete (D) </td>
|
|
113
|
-
<td> Available (G) </td>
|
|
114
|
-
</tr>
|
|
115
|
-
<tr>
|
|
116
|
-
<td> Multiple (M) </td>
|
|
117
|
-
<td> Box (B) </td>
|
|
118
|
-
<td> Continuous (C) </td>
|
|
119
|
-
<td> Not Available (N) </td>
|
|
120
|
-
</tr>
|
|
121
|
-
<tr>
|
|
122
|
-
<td> </td>
|
|
123
|
-
<td> Deterministic (D) </td>
|
|
124
|
-
<td> Mixed (M) </td>
|
|
125
|
-
<td> </td>
|
|
126
|
-
</tr>
|
|
127
|
-
<tr>
|
|
128
|
-
<td> </td>
|
|
129
|
-
<td> Stochastic (S) </td>
|
|
130
|
-
<td> </td>
|
|
131
|
-
<td> </td>
|
|
132
|
-
</tr>
|
|
133
|
-
</table>
|
|
134
|
-
5. Change factors associated with the problem and model as necessary.
|
|
135
|
-
6. All problems with unique factors must have unique names, i.e., no two problems can have the same name, but different factors. If you want to use the same problem twice for a solver but with different problem or model factors, make sure you change the name of the problem accordingly. This name will appear in the queue within the workspace below.
|
|
136
|
-
7. The number of macroreplications can be modified in the top-left corner. The default is 10.
|
|
137
|
-
8. Select the "Add **problem-solver pair**" button, which only appears when a solver and problem is selected. The **problem-solver pair** will be added in the "Queue of **problem-solver pair**s."
|
|
138
133
|
|
|
134
|
+
| Objective | Constraint | Variable | Direct Gradient Observations |
|
|
135
|
+
| ------------ | ----------------- | -------------- | ---------------------------- |
|
|
136
|
+
| Single (S) | Unconstrained (U) | Discrete (D) | Available (G) |
|
|
137
|
+
| Multiple (M) | Box (B) | Continuous (C) | Not Available (N) |
|
|
138
|
+
| | Deterministic (D) | Mixed (M) | |
|
|
139
|
+
| | Stochastic (S) | | |
|
|
140
|
+
|
|
141
|
+
6. Change factors associated with the problem and model as necessary.
|
|
142
|
+
7. All problems with unique factors must have unique names, i.e., no two problems can have the same name, but different factors. If you want to use the same problem twice for a solver but with different problem or model factors, make sure you change the name of the problem accordingly. This name will appear in the queue within the workspace below.
|
|
143
|
+
8. The number of macroreplications can be modified in the top-left corner. The default is 10.
|
|
144
|
+
9. Select the "Add **problem-solver pair**" button, which only appears when a solver and problem is selected. The **problem-solver pair** will be added in the "Queue of **problem-solver pair**s."
|
|
139
145
|
|
|
140
146
|
#### 2. Loading a **problem-solver pair** from a file
|
|
141
147
|
Instead of creating a **problem-solver pair** from scratch, you can load one from a \*.pickle file:
|
|
@@ -159,7 +165,6 @@ The second is converting a list of **problem-solver pair**s into a **problem-sol
|
|
|
159
165
|
1. Select the **problem-solver pair**s of interest from the "Queue of **problem-solver pair**s".
|
|
160
166
|
2. Clicking the "Convert to a **problem-solver group**" button. This will complete the cross-design for the partial list and create a new row in the "Queue of **problem-solver group**s".
|
|
161
167
|
|
|
162
|
-
|
|
163
168
|
### Running a **problem-solver pair** or a **problem-solver group**
|
|
164
169
|
To run a **problem-solver pair** or a **problem-solver group**, click the "Run" button in the "Queue of **problem-solver pair**s" or "Queue of **problem-solver group**s". Once the **problem-solver pair** or **problem-solver group** has been run, the "Run" button becomes disabled.
|
|
165
170
|
**Note:** Running a **problem-solver pair** can take anywhere from a couple of seconds to a couple of minutes depending on the **problem-solver pair** and the number of macroreplications.
|
|
@@ -189,55 +194,60 @@ The type of plots that are currently available in the GUI are: Mean Progress Cur
|
|
|
189
194
|
6. To view one plot, click "View Plot." All plots can be viewed together by clicking "See All Plots" at the bottom of the page.
|
|
190
195
|
7. To return to the main page, click the red "x" in the top-left corner of the window.
|
|
191
196
|
|
|
192
|
-
## Contributing
|
|
193
|
-
You can contribute problems and solver to SimOpt by using [pull requests](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests) in GitHub or corresponding with the developers.
|
|
194
|
-
|
|
195
|
-
|
|
196
197
|
## Package
|
|
197
198
|
The `simoptlib` package is available to download through the Python Packaging Index (PyPI) and can be installed from the terminal with the following command:
|
|
198
|
-
|
|
199
|
-
|
|
199
|
+
```
|
|
200
|
+
python -m pip install simoptlib
|
|
201
|
+
```
|
|
200
202
|
|
|
201
203
|
## Basic Example
|
|
202
|
-
|
|
203
204
|
After installing `simoptlib`, the package's main modules can be imported from the Python console (or in code):
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
205
|
+
```
|
|
206
|
+
import simopt
|
|
207
|
+
from simopt import models, solvers, experiment_base
|
|
208
|
+
```
|
|
207
209
|
|
|
208
210
|
The following snippet of code will run 10 macroreplications of the Random Search solver ("RNDSRCH") on the Continuous Newsvendor problem ("CNTNEWS-1"):
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
211
|
+
```
|
|
212
|
+
myexperiment = simopt.experiment_base.ProblemSolver("RNDSRCH", "CNTNEWS-1")
|
|
213
|
+
myexperiment.run(n_macroreps=10)
|
|
214
|
+
```
|
|
212
215
|
|
|
213
216
|
The results will be saved to a .pickle file in a folder called `experiments/outputs`. To post-process the results, by taking, for example 200 postreplications at each recommended solution, run the following:
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
+
```
|
|
218
|
+
myexperiment.post_replicate(n_postreps=200)
|
|
219
|
+
simopt.experiment_base.post_normalize([myexperiment], n_postreps_init_opt=200)
|
|
220
|
+
```
|
|
217
221
|
|
|
218
222
|
A .txt file summarizing the progress of the solver on each macroreplication can be produced:
|
|
219
|
-
|
|
220
|
-
|
|
223
|
+
```
|
|
224
|
+
myexperiment.log_experiment_results()
|
|
225
|
+
```
|
|
221
226
|
|
|
222
227
|
A .txt file called `RNDSRCH_on_CNTNEWS-1_experiment_results.txt` will be saved in a folder called `experiments/logs`.
|
|
223
228
|
|
|
224
229
|
One can then plot the mean progress curve of the solver (with confidence intervals) with the objective function values shown on the y-axis:
|
|
225
|
-
|
|
226
|
-
|
|
230
|
+
```
|
|
231
|
+
simopt.experiment_base.plot_progress_curves(experiments=[myexperiment], plot_type="mean", normalize=False)
|
|
232
|
+
```
|
|
227
233
|
|
|
228
234
|
The Python scripts in the `demo` folder provide more guidance on how to run common experiments using the library.
|
|
229
235
|
|
|
230
236
|
One can also use the SimOpt graphical user interface by running the following from the terminal:
|
|
237
|
+
```
|
|
238
|
+
python -m simopt
|
|
239
|
+
```
|
|
240
|
+
|
|
241
|
+
## Contributing
|
|
242
|
+
You can contribute problems and solvers to SimOpt (or fix other coding bugs) by [forking](https://docs.github.com/en/get-started/quickstart/fork-a-repo) the repository and initiating [pull requests](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests) in GitHub to request that your changes be integrated.
|
|
231
243
|
|
|
232
|
-
python -m simopt.GUI
|
|
233
244
|
|
|
234
245
|
## Authors
|
|
235
246
|
The core development team currently consists of
|
|
236
|
-
|
|
237
247
|
- [**David Eckman**](https://eckman.engr.tamu.edu) (Texas A&M University)
|
|
238
248
|
- [**Sara Shashaani**](https://shashaani.wordpress.ncsu.edu) (North Carolina State University)
|
|
239
249
|
- [**Shane Henderson**](https://people.orie.cornell.edu/shane/) (Cornell University)
|
|
240
|
-
|
|
250
|
+
- [**William Grochocinski**](https://github.com/Grochocinski) (North Carolina State University)
|
|
241
251
|
|
|
242
252
|
## Citation
|
|
243
253
|
To cite this work, please use
|
|
@@ -245,15 +255,38 @@ To cite this work, please use
|
|
|
245
255
|
@misc{simoptgithub,
|
|
246
256
|
author = {D. J. Eckman and S. G. Henderson and S. Shashaani and R. Pasupathy},
|
|
247
257
|
title = {{SimOpt}},
|
|
248
|
-
year = {
|
|
258
|
+
year = {2024},
|
|
249
259
|
publisher = {GitHub},
|
|
250
260
|
journal = {GitHub repository},
|
|
251
261
|
howpublished = {\url{https://github.com/simopt-admin/simopt}},
|
|
252
|
-
commit = {
|
|
262
|
+
commit = {21802a685ec394fed048820e692209628f40dd4e}
|
|
253
263
|
}
|
|
254
264
|
```
|
|
255
265
|
|
|
256
266
|
## Acknowledgments
|
|
257
|
-
An earlier website for SimOpt
|
|
258
|
-
|
|
259
|
-
|
|
267
|
+
An earlier website for SimOpt ([http://www.simopt.org](http://www.simopt.org)) was developed through work supported by the following grants:
|
|
268
|
+
- National Science Foundation
|
|
269
|
+
- [DMI-0400287](https://www.nsf.gov/awardsearch/showAward?AWD_ID=0400287)
|
|
270
|
+
- [CMMI-0800688](https://www.nsf.gov/awardsearch/showAward?AWD_ID=0800688)
|
|
271
|
+
- [CMMI-1200315](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1200315)
|
|
272
|
+
|
|
273
|
+
Recent work on the development of SimOpt has been supported by the following grants
|
|
274
|
+
- National Science Foundation
|
|
275
|
+
- [IIS-1247696](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1247696)
|
|
276
|
+
- [CMMI-1254298](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1254298)
|
|
277
|
+
- [CMMI-1536895](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1536895)
|
|
278
|
+
- [CMMI-1537394](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1537394)
|
|
279
|
+
- [DGE-1650441](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1650441)
|
|
280
|
+
- [DMS-1839346](https://www.nsf.gov/awardsearch/showAward?AWD_ID=1839346) (TRIPODS+X)
|
|
281
|
+
- [CMMI-2206972](https://www.nsf.gov/awardsearch/showAward?AWD_ID=2206972)
|
|
282
|
+
- [OAC-2410948](https://www.nsf.gov/awardsearch/showAward?AWD_ID=2410948)
|
|
283
|
+
- [OAC-2410949](https://www.nsf.gov/awardsearch/showAward?AWD_ID=2410949)
|
|
284
|
+
- [OAC-2410950](https://www.nsf.gov/awardsearch/showAward?AWD_ID=2410950)
|
|
285
|
+
- Air Force Office of Scientific Research
|
|
286
|
+
- FA9550-12-1-0200
|
|
287
|
+
- FA9550-15-1-0038
|
|
288
|
+
- FA9550-16-1-0046
|
|
289
|
+
- Army Research Office
|
|
290
|
+
- W911NF-17-1-0094
|
|
291
|
+
|
|
292
|
+
*Any opinions, findings and conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect the views of the National Science Foundation (NSF).*
|