EvoEulerAP: Evolving Area-Proportional Euler and Venn Diagrams with Specific Properties
To the best of our knowledge, EvoEulerAP is the first area-proportional Euler and Venn diagram generation method that returns a set of non-dominated solutions (diagrams). Before optimization, a single shape type (an ellipse or an arbitrary simple closed shape with smoothing applied where possible) has to be chosen as the curve shape for all diagrams. Each solution is evaluated with six objectives (stress, missing zone, unwanted zone, triple point, concurrency, and disconnected zone) that together minimize area error and violations of well-matchedness and well-formedness properties.
EvoEulerAP is available as a Python package with both a web interface and an application programming interface (API). It extends EvoEuler, which generates non-area-proportional Euler and Venn diagrams with specific properties.
Installation
Run the following command to install EvoEulerAP:
pip install evoeulerap
Web Interface
Run the following command to launch the web interface:
evoeulerap
API
The example below shows the use of all functions provided by the API.
The supported algorithms for the API are: NSGA-II and NSGA-III.
The supported shapes for the API are: ellipse and arbitrary_shape.
If n_process is not set, all available logical CPU cores are used for parallelization.
"""Search for area-proportional 3-set Euler diagrams with ellipses."""
import matplotlib.pyplot as plt
from evoeulerap import (
diagram,
metrics,
obj_values,
optimize,
pcp,
shape_params,
zone_info,
)
if __name__ == "__main__":
area_spec = {
"A": 0.205,
"B": 0.116,
"C": 0.292,
"A C": 0.104,
"B C": 0.146,
}
# Start an optimization.
result = optimize(
area_spec=area_spec,
shape="ellipse",
algorithm="NSGA-II",
n_gen=100,
n_process=1,
)
# Print the number of non-dominated solutions.
print(f"Number of non-dominated solutions: {len(result)}")
# Show the parallel coordinates plot that visualizes the set of
# non-dominated solutions.
fig = pcp(result)
fig.show()
solution_idx = 0 # Solution index
# Show the diagram of a non-dominated solution.
diagram(
result[solution_idx], show_target_areas=True, shade_unwanted_zones=True
)
plt.show()
# Print the objective values of a non-dominated solution.
print("Objective values:")
print(obj_values(result[solution_idx]))
# Print the metrics of a non-dominated solution.
print("Metrics:")
print(metrics(result[solution_idx]))
# Print the zone information of a non-dominated solution.
print("Zone info:")
print(zone_info(result[solution_idx]))
# Print the shape parameters of a non-dominated solution.
print("Shape params:")
print(shape_params(result[solution_idx]))
Examples
Some example scripts for searching area-proportional Euler or Venn diagrams are in ./examples.
Contact
If you have any questions, please contact Chi Ho Chan at c.chan3@napier.ac.uk.
Metadata
Release files for evoeulerap 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| evoeulerap-1.0.0.tar.gz | 32.7 kB | Without provenance | Details for evoeulerap-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| evoeulerap-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for evoeulerap-1.0.0-py3-none-any.whl |
Total release size: 68.4 kB
Release files / evoeulerap-1.0.0.tar.gz
| Download URL | evoeulerap-1.0.0.tar.gz |
|---|---|
| Size | 32.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
76d40e746828871d05be21727a539d022d63ee33564aa154786b787cf438ce30
|
|
BLAKE2b-256 checksum How to use checksums |
31d3a6697d117d799dba44d1ff11d17f34a8974a11ac41516e43358b7aee48ef
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.0
|
Release files / evoeulerap-1.0.0-py3-none-any.whl
| Download URL | evoeulerap-1.0.0-py3-none-any.whl |
|---|---|
| Size | 35.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
56229b2fbefd0f9ebb7f64c6fa3a71c5eb6047f2e3e14c84cdbd88a920fcc05c
|
|
BLAKE2b-256 checksum How to use checksums |
a3bee5a33f7df015feafa406b233c6a1386005901c8453c5d567145a8f82bbcd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.0
|
Security for evoeulerap 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.