fmu-manipulation-toolbox 1.8.2.2__tar.gz → 1.8.3__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 (59) hide show
  1. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/PKG-INFO +1 -1
  2. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/README.md +1 -1
  3. fmu_manipulation_toolbox-1.8.3/fmu_manipulation_toolbox/__version__.py +1 -0
  4. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/fmu_container.py +12 -11
  5. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/win32/client_sm.dll +0 -0
  6. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/win32/server_sm.exe +0 -0
  7. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/win64/client_sm.dll +0 -0
  8. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/win64/container.dll +0 -0
  9. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/win64/server_sm.exe +0 -0
  10. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/PKG-INFO +1 -1
  11. fmu_manipulation_toolbox-1.8.2.2/fmu_manipulation_toolbox/__version__.py +0 -1
  12. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/LICENSE.txt +0 -0
  13. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/__init__.py +0 -0
  14. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/__main__.py +0 -0
  15. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/assembly.py +0 -0
  16. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/checker.py +0 -0
  17. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/cli.py +0 -0
  18. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/fmu_operations.py +0 -0
  19. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/gui.py +0 -0
  20. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/gui_style.py +0 -0
  21. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/help.py +0 -0
  22. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-checked-disabled.png +0 -0
  23. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-checked-hover.png +0 -0
  24. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-checked.png +0 -0
  25. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-unchecked-disabled.png +0 -0
  26. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-unchecked-hover.png +0 -0
  27. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/checkbox-unchecked.png +0 -0
  28. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/container.png +0 -0
  29. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/drop_fmu.png +0 -0
  30. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Annotation.xsd +0 -0
  31. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2AttributeGroups.xsd +0 -0
  32. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2ModelDescription.xsd +0 -0
  33. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2ScalarVariable.xsd +0 -0
  34. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Type.xsd +0 -0
  35. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Unit.xsd +0 -0
  36. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2VariableDependency.xsd +0 -0
  37. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmu.png +0 -0
  38. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/fmu_manipulation_toolbox.png +0 -0
  39. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/help.png +0 -0
  40. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/icon-round.png +0 -0
  41. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/icon.png +0 -0
  42. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/icon_fmu.png +0 -0
  43. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/license.txt +0 -0
  44. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/linux32/client_sm.so +0 -0
  45. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/linux32/server_sm +0 -0
  46. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/linux64/client_sm.so +0 -0
  47. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/linux64/container.so +0 -0
  48. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/linux64/server_sm +0 -0
  49. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/mask.png +0 -0
  50. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/resources/model.png +0 -0
  51. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox/version.py +0 -0
  52. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/SOURCES.txt +0 -0
  53. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/dependency_links.txt +0 -0
  54. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/entry_points.txt +0 -0
  55. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/requires.txt +0 -0
  56. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/fmu_manipulation_toolbox.egg-info/top_level.txt +0 -0
  57. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/setup.cfg +0 -0
  58. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/setup.py +0 -0
  59. {fmu_manipulation_toolbox-1.8.2.2 → fmu_manipulation_toolbox-1.8.3}/tests/test_suite.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fmu_manipulation_toolbox
3
- Version: 1.8.2.2
3
+ Version: 1.8.3
4
4
  Summary: FMU Manipulation Toobox is a python application which help to modify a Functional Mock-up Units (FMUs) without recompilation or to group them into FMU Containers
5
5
  Home-page: https://github.com/grouperenault/fmu_manipulation_toolbox/
6
6
  Author: Nicolas.LAURENT@Renault.com
@@ -6,7 +6,7 @@ without recompilation. It is highly customizable. It can even modify the `modelD
6
6
  Manipulating the `modelDescription.xml` can be a dangerous thing! Communicating with the FMU-developer and adapting
7
7
  the way the FMU is generated, is preferable when possible.
8
8
 
9
- FMU Manipulation Toolbox also allows to group FMU's inside FMU Containers. (see [container/README.md](container/README.md))
9
+ FMU Manipulation Toolbox also allows to group FMU's inside FMU Containers. (see [doc/container.md](doc/container.md))
10
10
 
11
11
  ## Installation
12
12
 
@@ -146,7 +146,7 @@ class ContainerPort:
146
146
  return f"Port {self.fmu.name}/{self.port.name}"
147
147
 
148
148
  def __hash__(self):
149
- return hash(f"{self.fmu.name}/{self.port.name}")
149
+ return hash("{self.fmu.name}/{self.port.name}")
150
150
 
151
151
  def __eq__(self, other):
152
152
  return str(self) == str(other)
@@ -300,13 +300,14 @@ class FMUContainer:
300
300
 
301
301
  self.start_values[cport] = value
302
302
 
303
- def find_input(self, port_to_connect: FMUPort) -> Optional[ContainerPort]:
303
+ def find_inputs(self, port_to_connect: FMUPort) -> List[ContainerPort]:
304
+ candidates = []
304
305
  for fmu in self.execution_order:
305
306
  for port in fmu.ports.values():
306
307
  if (port.causality == 'input' and port.name == port_to_connect.name
307
308
  and port.type_name == port_to_connect.type_name):
308
- return ContainerPort(fmu, port.name)
309
- return None
309
+ candidates.append(ContainerPort(fmu, port.name))
310
+ return candidates
310
311
 
311
312
  def add_implicit_rule(self, auto_input=True, auto_output=True, auto_link=True, auto_parameter=False,
312
313
  auto_local=False):
@@ -321,14 +322,14 @@ class FMUContainer:
321
322
  self.inputs[parameter_name] = cport
322
323
  self.mark_ruled(cport, 'PARAMETER')
323
324
  elif cport.port.causality == 'output':
324
- candidate_cport = self.find_input(cport.port)
325
- if auto_link and candidate_cport:
326
- local = Local(cport)
327
- local.add_target(candidate_cport)
328
- logger.info(f"AUTO LINK: {cport} -> {candidate_cport}")
325
+ candidates_cport_list = self.find_inputs(cport.port)
326
+ if auto_link and candidates_cport_list:
327
+ self.locals[cport] = Local(cport)
329
328
  self.mark_ruled(cport, 'LINK')
330
- self.mark_ruled(candidate_cport, 'LINK')
331
- self.locals[cport] = local
329
+ for candidate_cport in candidates_cport_list:
330
+ self.locals[cport].add_target(candidate_cport)
331
+ self.mark_ruled(candidate_cport, 'LINK')
332
+ logger.info(f"AUTO LINK: {cport} -> {candidate_cport}")
332
333
  elif auto_output:
333
334
  self.mark_ruled(cport, 'OUTPUT')
334
335
  self.outputs[port_name] = cport
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fmu_manipulation_toolbox
3
- Version: 1.8.2.2
3
+ Version: 1.8.3
4
4
  Summary: FMU Manipulation Toobox is a python application which help to modify a Functional Mock-up Units (FMUs) without recompilation or to group them into FMU Containers
5
5
  Home-page: https://github.com/grouperenault/fmu_manipulation_toolbox/
6
6
  Author: Nicolas.LAURENT@Renault.com