Operation docs update (#154)

* Operation Interface Enhancement + Clarification
- added set notation to all the geometry operations
- added a warning to say sample_surface=True doesn't work

* minor fix docs

* fix operation_interface.py doc

---------

Co-authored-by: Dario Coscia <dariocoscia@Dario-Coscia.local>
Co-authored-by: Dario Coscia <93731561+dario-coscia@users.noreply.github.com>
This commit is contained in:
Kush
2023-07-12 15:49:37 +02:00
committed by Nicola Demo
parent 2d0256a179
commit 0ea17d8ff4
5 changed files with 52 additions and 8 deletions

View File

@@ -7,21 +7,28 @@ import random
class OperationInterface(Location, metaclass=ABCMeta):
"""PINA Operation Interface"""
def __init__(self, geometries):
"""
Abstract Operation class.
Any geometry operation entity must inherit from this class.
.. warning::
The ``sample_surface=True`` option is not implemented yet
for Difference, Intersection, and Exclusion. The usage will
result in unwanted behaviour.
:param list geometries: A list of geometries from 'pina.geometry'
such as 'EllipsoidDomain' or 'CartesianDomain'.
"""
# check consistency geometries
check_consistency(geometries, Location)
# check we are passing always different
# check we are passing always different
# geometries with the same labels.
self._check_dimensions(geometries)
# assign geometries
self._geometries = geometries