Skip to content

Commit 0acd655

Browse files
committed
Upload and adjustments to Pypi
1 parent 8bf53e5 commit 0acd655

24 files changed

+689
-206
lines changed

Diff for: .gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
git
22
.github/workflows/python-unittest.yml_unused
33
_build
4+
dist
45

56
# Byte-compiled / optimized / DLL files
67
__pycache__/

Diff for: README.md

+32-16
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,25 @@
11
# Algorithm Configuration for the AIPlan4EU Unified Planning
22

3-
Use algorithm configuration on several planners within the unified planning framework to enhance their performance. Development is conducted by the Decision and Operation Technologies group from Bielefeld University (https://github.com/DOTBielefeld).
3+
Use algorithm configuration on several planners within the unified planning framework to enhance their performance. Find the documentation at (https://up-ac.readthedocs.io/en/latest/). Development is conducted by the Decision and Operation Technologies group from Bielefeld University (https://github.com/DOTBielefeld).
44

55
# Installation
66

7-
At the moment an installation is only possible via
7+
You need to first install Unified Planning before installing up_ac. It is highly recommended to use a separate virtual environment for up_ac.
8+
9+
## Unified Planning
10+
11+
This project was developed in Python 3.8.5. The integrated version of Unified Planning is 1.1.0.113.dev1. The easiest way to install Unified Planning with all available engines is via
812

913
```
10-
pip install git+https://github.com/DimitriWeiss/up-ac.git
14+
pip install --pre unified-planning[engines]==1.1.0.113.dev1
1115
```
1216

13-
# Planning engines
17+
## up_ac
1418

15-
If a planning engine which is integrated in this algorithm configuration extension is not available on your system, you can install it via
19+
You can then install up_ac via
1620

1721
```
18-
pip install --pre unified-planning[<engine_name>]
22+
pip install up_ac
1923
```
2024

2125
## Planning engines integrated in the algorithm configuration
@@ -33,7 +37,7 @@ It is possible to adjust the configuration space of each engine according to you
3337

3438
# Automated Algorithm Configuration methods
3539

36-
There are three methods currently integrated in this implementation. It is possible to integrate further algorithm configuration methods using the classes
40+
There are four methods currently integrated in this implementation. It is possible to integrate further algorithm configuration methods using the classes
3741
```
3842
up_ac.configurators.Configurator
3943
```
@@ -52,36 +56,47 @@ Smac can be installed via
5256
pip install smac==2.0.1
5357
```
5458

55-
. For further details refer to (https://automl.github.io/SMAC3/main/).
59+
For further details refer to (https://automl.github.io/SMAC3/main/).
5660

5761
## Optano Algorithm Tuner (OAT)
5862

59-
To use OAT, run the following two functions after installation of up_ac.
63+
To use OAT, run the following in Python after installation of up_ac.
6064

6165
```
62-
up_ac.utils.download_OAT.get_OAT()
63-
up_ac.utils.download_OAT.copy_call_engine_OAT()
66+
from up_ac.utils.download_OAT import get_OAT, copy_call_engine_OAT
67+
68+
get_OAT()
69+
copy_call_engine_OAT()
6470
```
6571

6672
The first function generates a directory for OAT, downloads compiled code for OAT and saves it in the up_ac directory. The second function moves code to the OAT directory. Once you have run these functions, you do not need to run them again, except if you have removed the OAT directory.
6773

6874
To remove the OAT directory run:
6975

7076
```
71-
up_ac.utils.download_OAT.delete_OAT()
77+
from up_ac.utils.download_OAT import delete_OAT
78+
79+
delete_OAT()
7280
```
7381

7482
For further details on OAT refer to (https://docs.optano.com/algorithm.tuner/current/).
7583

7684
## Irace
7785

78-
In order to use Irace you need to install R on your system. After that you need to install the R package for irace from the R console by:
86+
In order to use Irace you need to have R on your system. You also need to install the R packages 'remotes' and 'irace' from the R console by:
87+
88+
```
89+
install.packages("remotes")
90+
remotes::install_version("irace", version = "3.5", repos = "https://cloud.r-project.org")
91+
```
92+
93+
After that you need to leave the R terminal and install the Irace Python package via
7994

8095
```
81-
install.packages("irace", repos = "https://cloud.r-project.org")
96+
pip install git+https://github.com/DimitriWeiss/up-iracepy@main
8297
```
8398

84-
The algorithm configuration implementation will then access irace via the python package rpy2.
99+
It is the Irace version implemented in up_ac and secured on this account for that reason. The algorithm configuration implementation will then access irace via the python package rpy2.
85100

86101
For further details on Irace refer to (https://github.com/cran/irace) and the python implementation of irace (https://github.com/auto-optimization/iracepy).
87102

@@ -90,10 +105,11 @@ For further details on Irace refer to (https://github.com/cran/irace) and the py
90105
Selector can be installed via
91106

92107
```
108+
pip install swig
93109
pip install selector-ac
94110
```
95111

96-
Selector is an ensemble-based automated algorithm configurator and incorporates functionalities and models from CPPL, GGA and SMAC. Since Selector is implemented with a different version of SMAC than the one used for the SMAC configurator in this library, you should use a separate environment/ virtual environment to configure planners with Selector. For further details on Selector refer to (https://github.com/dotbielefeld/selector).
112+
Preinstalling swig may be necessary, depending on your Python interpreter. Selector is an ensemble-based automated algorithm configurator and incorporates functionalities and models from CPPL, GGA and SMAC. Since Selector is implemented with a different version of SMAC than the one used for the SMAC configurator in this library, you should use a separate environment/ virtual environment to configure planners with Selector. For further details on Selector refer to (https://github.com/dotbielefeld/selector).
97113

98114
## Acknowledgments
99115

Diff for: ac_tools.rst

+32-8
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,21 @@ Then install the irace R package via the R console by running:
1414

1515
.. code-block:: R
1616
17-
install.packages("irace", repos = "https://cloud.r-project.org")
17+
install.packages("remotes")
18+
install.packages("irace", version = "3.5", repos = "https://cloud.r-project.org")
1819
1920
20-
The algorithm configuration implementation will then access irace via the python package rpy2.
21+
After that you need to leave the R terminal and install the Irace Python package via
22+
23+
.. code-block:: python
24+
25+
pip install git+https://github.com/DimitriWeiss/up-iracepy@main
26+
2127
22-
For further details on Irace refer to the `irace GitHub <https://github.com/cran/irace>`_ and the `python implementation of irace <https://github.com/auto-optimization/iracepy>`_.
2328
29+
The algorithm configuration implementation will then access irace via the python package rpy2.
2430

31+
For further details on Irace refer to the `irace GitHub <https://github.com/cran/irace>`_ and the `python implementation of irace <https://github.com/auto-optimization/iracepy>`_.
2532

2633

2734
.. automodule:: up_ac.Irace_configurator
@@ -38,10 +45,12 @@ The Optano algorithm tuner (OAT) executes tuning on optimization functions using
3845
While it is able to run on a single computing node it also supports multiple workers.
3946
Before being able to use OAT first execute the following code after having installed up-ac.
4047

41-
.. code-block:: bash
48+
.. code-block:: python
49+
50+
from up_ac.utils.download_OAT import get_OAT, copy_call_engine_OAT, delete_OAT
4251
43-
up_ac.utils.download_OAT.get_OAT()
44-
up_ac.utils.download_OAT.copy_call_engine_OAT()
52+
get_OAT()
53+
copy_call_engine_OAT()
4554
4655
4756
The first function generates a directory for OAT, downloads compiled code for OAT and saves it in the up_ac directory.
@@ -50,9 +59,9 @@ Once you have run these functions, you do not need to run them again, except if
5059

5160
To remove the OAT directory run:
5261

53-
.. code-block:: bash
62+
.. code-block:: python
5463
55-
up_ac.utils.download_OAT.delete_OAT()
64+
delete_OAT()
5665
5766
For more details on OAT refer to `the documentation <https://docs.optano.com/algorithm.tuner/current/>`_.
5867

@@ -71,8 +80,16 @@ SMAC3 (Sequential Model-Based Algorithm Configuration) optimizes algorithm param
7180
It then uses an aggressive racing mechanism to efficiently compare configurations and iteratively refine the model, directing the search towards regions of the space where better configurations are likely to be found.
7281
In the autoconfiguration Smac can also make use of instance features to improve the predictions.
7382

83+
You can install it via
84+
85+
.. code-block:: bash
86+
87+
pip install smac==2.0.1
88+
89+
7490
For more details on SMAC refer to `the SMAC3 GitHub <https://automl.github.io/SMAC3/main/>`_.
7591

92+
7693
.. automodule:: up_ac.Smac_configurator
7794
:members:
7895

@@ -88,6 +105,13 @@ Selector is an ensemble-based automated algorithm configurator. The current impl
88105

89106
For more details on Selector refer to `the Selector GitHub <https://github.com/dotbielefeld/selector>`_.
90107

108+
You can install Selector via
109+
110+
.. code-block:: bash
111+
112+
pip install swig
113+
pip install selector-ac
114+
91115
92116
.. automodule:: up_ac.Selector_configurator
93117
:members:

Diff for: engines.rst

+5-3
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
Planning engines
44
==================
55

6+
Except for Tamer and Pyperplan and anytime plan quality, you can configure all planning engines listed here for runtime, plan quality and anytime plan quality regarding your instance set.
7+
68
LPG
79
---
810
**Support Features:**
@@ -44,15 +46,15 @@ EnhSP
4446

4547
- Optimality only assured for specific PDDL+ fragments (simple numeric planning problems)​
4648

47-
symk
49+
SymK
4850
----
4951

5052
**Support Features:**
5153

5254
- State-of-the-art classical optimal and top-k planner based on symbolic search extending Fast Downward. It can find a single optimal plan or a set of k different best plans with the lowest cost for a given planning task.
5355
- Supported in the Oneshot and Anytime Planners in both quality and runtime modes.
5456

55-
tamer
57+
Tamer
5658
------
5759

5860
Tamer is a temporal planner that supports temporal action-based problems.
@@ -62,7 +64,7 @@ Tamer is a temporal planner that supports temporal action-based problems.
6264
- Supported in the Oneshot Planner in the runtime mode.
6365

6466

65-
pyperplan
67+
Pyperplan
6668
---------
6769

6870
**Support Features:**

0 commit comments

Comments
 (0)