flamapy-fw 2.0.0.dev4__tar.gz → 2.0.0.dev6__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.
Files changed (49) hide show
  1. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/PKG-INFO +5 -3
  2. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/README.md +4 -2
  3. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/metrics_operation.py +34 -25
  4. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/metamodels/configuration_metamodel/transformations/configuration_basic_reader.py +3 -1
  5. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/PKG-INFO +5 -3
  6. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/setup.py +1 -1
  7. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/__init__.py +0 -0
  8. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/config.py +0 -0
  9. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/discover.py +0 -0
  10. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/exceptions.py +0 -0
  11. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/models/__init__.py +0 -0
  12. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/models/ast.py +0 -0
  13. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/models/variability_model.py +0 -0
  14. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/__init__.py +0 -0
  15. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/abstract_operation.py +0 -0
  16. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/atomic_sets.py +0 -0
  17. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/average_branching_factor.py +0 -0
  18. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/commonality.py +0 -0
  19. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/configurations.py +0 -0
  20. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/configurations_number.py +0 -0
  21. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/core_features.py +0 -0
  22. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/count_leafs.py +0 -0
  23. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/dead_features.py +0 -0
  24. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/error_detection.py +0 -0
  25. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/error_diagnosis.py +0 -0
  26. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/estimated_configurations_number.py +0 -0
  27. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/false_optional_features.py +0 -0
  28. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/filter.py +0 -0
  29. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/sampling.py +0 -0
  30. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/satisfiable.py +0 -0
  31. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/satisfiable_configuration.py +0 -0
  32. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/operations/variability.py +0 -0
  33. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/plugins.py +0 -0
  34. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/transformations/__init__.py +0 -0
  35. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/transformations/abstract_transformation.py +0 -0
  36. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/transformations/model_to_model.py +0 -0
  37. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/transformations/model_to_text.py +0 -0
  38. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/transformations/text_to_model.py +0 -0
  39. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/core/utils.py +0 -0
  40. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/metamodels/configuration_metamodel/__init__.py +0 -0
  41. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/metamodels/configuration_metamodel/models/__init__.py +0 -0
  42. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/metamodels/configuration_metamodel/models/configuration.py +0 -0
  43. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy/metamodels/configuration_metamodel/transformations/__init__.py +0 -0
  44. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/SOURCES.txt +0 -0
  45. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/dependency_links.txt +0 -0
  46. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/entry_points.txt +0 -0
  47. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/requires.txt +0 -0
  48. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/flamapy_fw.egg-info/top_level.txt +0 -0
  49. {flamapy-fw-2.0.0.dev4 → flamapy-fw-2.0.0.dev6}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: flamapy-fw
3
- Version: 2.0.0.dev4
3
+ Version: 2.0.0.dev6
4
4
  Summary: Flamapy is a Python-based AAFM framework that takes into consideration previous AAFM tool designs and enables multi-solver and multi-metamodel support for the integration of AAFM tooling on the Python ecosystem.
5
5
  Home-page: https://github.com/flamapy/core
6
6
  Author: Flamapy
@@ -24,8 +24,10 @@ The main features of the framework are:
24
24
  * Support multiple operations. It is developed, having in mind multi-model operations such as those depicted by Familiar and single-model operations.
25
25
 
26
26
  ## Available plugins
27
- [flamapy-fm](https://github.com/flamapy/fm_metamodel)
28
- [flamapy-sat](https://github.com/flamapy/pysat_metamodel)
27
+ [flamapy](https://github.com/flamapy/flamapy). This is a meta-package that installs all plugins for feature modelling analysis and the CLI and Python interfaces.
28
+ [flamapy-fm](https://github.com/flamapy/fm_metamodel) This is a plugin that provides support for feature modelling. Include several readers/writers from different formats.
29
+ [flamapy-sat](https://github.com/flamapy/pysat_metamodel) This plugin enable different analysis operations that require sat as backend.
30
+ [flamapy-bdd](https://github.com/flamapy/bdd_metamodel) This plugin enable different analysis operations that require bdd as backend.
29
31
 
30
32
  ## Documentation
31
33
 
@@ -8,8 +8,10 @@ The main features of the framework are:
8
8
  * Support multiple operations. It is developed, having in mind multi-model operations such as those depicted by Familiar and single-model operations.
9
9
 
10
10
  ## Available plugins
11
- [flamapy-fm](https://github.com/flamapy/fm_metamodel)
12
- [flamapy-sat](https://github.com/flamapy/pysat_metamodel)
11
+ [flamapy](https://github.com/flamapy/flamapy). This is a meta-package that installs all plugins for feature modelling analysis and the CLI and Python interfaces.
12
+ [flamapy-fm](https://github.com/flamapy/fm_metamodel) This is a plugin that provides support for feature modelling. Include several readers/writers from different formats.
13
+ [flamapy-sat](https://github.com/flamapy/pysat_metamodel) This plugin enable different analysis operations that require sat as backend.
14
+ [flamapy-bdd](https://github.com/flamapy/bdd_metamodel) This plugin enable different analysis operations that require bdd as backend.
13
15
 
14
16
  ## Documentation
15
17
 
@@ -20,11 +20,6 @@ class Metrics(Operation, metaclass=ABCMeta):
20
20
  filter: Optional[list[str]] = None
21
21
  result: list[dict[str, Any]] = []
22
22
 
23
- @property
24
- @abstractmethod
25
- def model_type_extension(self) -> str:
26
- """Return the model type extension for the specific metric."""
27
-
28
23
  def __init__(self) -> None:
29
24
  self.model: Optional[VariabilityModel] = None
30
25
 
@@ -32,6 +27,11 @@ class Metrics(Operation, metaclass=ABCMeta):
32
27
  def calculate_metamodel_metrics(self, model: VariabilityModel) -> list[dict[str, Any]]:
33
28
  """Return a list of metrics for each metamodel."""
34
29
 
30
+ @property
31
+ @abstractmethod
32
+ def model_type_extension(self) -> str:
33
+ """Return the model type extension for the specific metric."""
34
+
35
35
  def only_these_metrics(self, filter_metrics: list[str]) -> None:
36
36
  self.filter = filter_metrics
37
37
 
@@ -43,6 +43,7 @@ class Metrics(Operation, metaclass=ABCMeta):
43
43
  # We first have to identify the metamodels that are being used and
44
44
  # transform this model to the correspointing metamodel
45
45
  metrics_operation = subclass() # type: ignore
46
+
46
47
  if self.model.__class__.get_extension() == metrics_operation.model_type_extension:
47
48
  # If its the metamodel that math the model, calculate the metrics
48
49
  # Then we calculate the metrics for each metamodel
@@ -88,26 +89,34 @@ class Metrics(Operation, metaclass=ABCMeta):
88
89
  return float(round(len(collection1) / len(collection2), precision))
89
90
 
90
91
  @staticmethod
91
- def construct_result(name: Optional[str] = None,
92
- doc: Optional[str] = None,
93
- result: Optional[Any] = None,
94
- size: Optional[int] = None,
95
- ratio: Optional[float] = None
96
- ) -> dict[str, Any]:
97
- """Constructs a dictionary with named keys from the provided list and other arguments.
98
-
99
- property name: The property name.
100
- description: The description of the property
101
- value (optional): the list of abstract features.
102
- size (optional): the length of the list.
103
- ratio (optional): the percentage of abstract features with regards the total number
104
- of features.
92
+ def construct_result(name: str,
93
+ doc: str,
94
+ result: Any,
95
+ size: int = 0,
96
+ ratio: float = 0.0,
97
+ parent: Optional[Any] = None,
98
+ level: int = 0
99
+ ) -> dict[str, Any]:
100
+ # pylint: disable=too-many-arguments
101
+ """Constructs a dictionary with named keys from the provided values.
102
+
103
+ Arguments:
104
+ name: The property name.
105
+ doc: The description of the property.
106
+ result: The value(s).
107
+ size (optional): The length of the values (number of values).
108
+ ratio (optional): The percentage of values with regards the total number of possible
109
+ values.
110
+ parent (optional): The parent metrics of which this metric is based on
111
+ (for organization purposes).
112
+ level (optional): The number of ancestors of this metrics (for organization purposes).
105
113
  """
106
-
107
114
  return {
108
- "name": name or "Default Name", # Using a default value if name is None
109
- "documentation": doc or "Default Documentation",
110
- "result": result or [],
111
- "size": size or 0,
112
- "ratio": ratio or 0.0
115
+ "name": name,
116
+ "documentation": doc,
117
+ "result": result,
118
+ "size": size,
119
+ "ratio": ratio,
120
+ "parent": parent,
121
+ "level": level
113
122
  }
@@ -19,7 +19,9 @@ class ConfigurationBasicReader(TextToModel):
19
19
  csv_reader = self.get_configuration_from_csv(self._path)
20
20
  elements = {}
21
21
  for row in csv_reader:
22
- elements[row[0]] = True
22
+ # Assuming that row[1] is supposed to represent a boolean value
23
+ # Convert 'true'/'false' strings to actual boolean values
24
+ elements[row[0]] = row[1].lower() == 'true'
23
25
  return Configuration(elements)
24
26
 
25
27
  def get_configuration_from_csv(self, path: str) -> list[list[str]]:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: flamapy-fw
3
- Version: 2.0.0.dev4
3
+ Version: 2.0.0.dev6
4
4
  Summary: Flamapy is a Python-based AAFM framework that takes into consideration previous AAFM tool designs and enables multi-solver and multi-metamodel support for the integration of AAFM tooling on the Python ecosystem.
5
5
  Home-page: https://github.com/flamapy/core
6
6
  Author: Flamapy
@@ -24,8 +24,10 @@ The main features of the framework are:
24
24
  * Support multiple operations. It is developed, having in mind multi-model operations such as those depicted by Familiar and single-model operations.
25
25
 
26
26
  ## Available plugins
27
- [flamapy-fm](https://github.com/flamapy/fm_metamodel)
28
- [flamapy-sat](https://github.com/flamapy/pysat_metamodel)
27
+ [flamapy](https://github.com/flamapy/flamapy). This is a meta-package that installs all plugins for feature modelling analysis and the CLI and Python interfaces.
28
+ [flamapy-fm](https://github.com/flamapy/fm_metamodel) This is a plugin that provides support for feature modelling. Include several readers/writers from different formats.
29
+ [flamapy-sat](https://github.com/flamapy/pysat_metamodel) This plugin enable different analysis operations that require sat as backend.
30
+ [flamapy-bdd](https://github.com/flamapy/bdd_metamodel) This plugin enable different analysis operations that require bdd as backend.
29
31
 
30
32
  ## Documentation
31
33
 
@@ -13,7 +13,7 @@ dev_requirements = read_requirements("requirements-dev.txt")
13
13
 
14
14
  setuptools.setup(
15
15
  name="flamapy-fw",
16
- version="2.0.0.dev4",
16
+ version="2.0.0.dev6",
17
17
  author="Flamapy",
18
18
  author_email="flamapy@us.es",
19
19
  description="Flamapy is a Python-based AAFM framework that takes into consideration previous AAFM tool designs and enables multi-solver and multi-metamodel support for the integration of AAFM tooling on the Python ecosystem.",