fmu-manipulation-toolbox 1.9.2rc1__tar.gz → 1.9.2rc2__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.
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/PKG-INFO +1 -1
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/__version__.py +1 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/container.py +49 -14
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/gui/__init__.py +0 -0
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/gui/gui.py +749 -0
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/gui/gui_style.py +252 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/darwin64/container.dylib +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/linux32/client_sm.so +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/linux64/client_sm.so +0 -0
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/resources/linux64/container.so +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/win32/client_sm.dll +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/win32/server_sm.exe +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/win64/client_sm.dll +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/win64/container.dll +0 -0
- fmu_manipulation_toolbox-1.9.2rc2/fmu_manipulation_toolbox/resources/win64/server_sm.exe +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/PKG-INFO +1 -1
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/SOURCES.txt +3 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/setup.py +1 -1
- fmu_manipulation_toolbox-1.9.2rc1/fmu_manipulation_toolbox/__version__.py +0 -1
- fmu_manipulation_toolbox-1.9.2rc1/fmu_manipulation_toolbox/resources/linux64/container.so +0 -0
- fmu_manipulation_toolbox-1.9.2rc1/fmu_manipulation_toolbox/resources/win64/server_sm.exe +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/LICENSE.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/README.md +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/__init__.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/__main__.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/assembly.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/checker.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/__init__.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/datalog2pcap.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/fmucontainer.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/fmusplit.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/fmutool.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/cli/utils.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/help.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/ls.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/operations.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/remoting.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-checked-disabled.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-checked-hover.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-checked.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-unchecked-disabled.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-unchecked-hover.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/checkbox-unchecked.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/container.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/drop_fmu.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Annotation.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2AttributeGroups.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2ModelDescription.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2ScalarVariable.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Type.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2Unit.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-2.0/fmi2VariableDependency.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3Annotation.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3AttributeGroups.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3BuildDescription.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3InterfaceType.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3LayeredStandardManifest.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3ModelDescription.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3Terminal.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3TerminalsAndIcons.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3Type.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3Unit.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3Variable.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmi-3.0/fmi3VariableDependency.xsd +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmu.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/fmu_manipulation_toolbox.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/help.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/icon-round.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/icon.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/icon_fmu.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/license.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/linux32/server_sm +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/linux64/server_sm +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/mask.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/resources/model.png +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/split.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/terminals.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox/version.py +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/dependency_links.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/entry_points.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/requires.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/fmu_manipulation_toolbox.egg-info/top_level.txt +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/setup.cfg +0 -0
- {fmu_manipulation_toolbox-1.9.2rc1 → fmu_manipulation_toolbox-1.9.2rc2}/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.9.
|
|
3
|
+
Version: 1.9.2rc2
|
|
4
4
|
Summary: FMU Manipulation Toolbox is a python package which helps to analyze, modify or combine Functional Mock-up Units (FMUs) without recompilation.
|
|
5
5
|
Home-page: https://github.com/grouperenault/fmu_manipulation_toolbox/
|
|
6
6
|
Author: Nicolas.LAURENT@Renault.com
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
'V1.9.2rc2'
|
|
@@ -196,6 +196,7 @@ class EmbeddedFMU(OperationAbstract):
|
|
|
196
196
|
self.model_identifier = None
|
|
197
197
|
self.guid = None
|
|
198
198
|
self.fmi_version = None
|
|
199
|
+
self.platforms = set()
|
|
199
200
|
self.ports: Dict[str, EmbeddedFMUPort] = {}
|
|
200
201
|
|
|
201
202
|
self.has_event_mode = False
|
|
@@ -240,6 +241,22 @@ class EmbeddedFMU(OperationAbstract):
|
|
|
240
241
|
port = EmbeddedFMUPort(fmu_port.fmi_type, fmu_port, fmi_version=self.fmi_version)
|
|
241
242
|
self.ports[port.name] = port
|
|
242
243
|
|
|
244
|
+
def closure(self):
|
|
245
|
+
osname = {
|
|
246
|
+
"win64": "Windows",
|
|
247
|
+
"linux64": "Linux",
|
|
248
|
+
"darwin64": "Darwin",
|
|
249
|
+
"x86_64-windows": "Windows",
|
|
250
|
+
"x86_64-linux": "Linux",
|
|
251
|
+
"aarch64-darwin": "Darwin"
|
|
252
|
+
}
|
|
253
|
+
try:
|
|
254
|
+
for directory in (Path(self.fmu.tmp_directory) / "binaries").iterdir():
|
|
255
|
+
if directory.is_dir() and str(directory.stem) in osname:
|
|
256
|
+
self.platforms.add(osname[str(directory.stem)])
|
|
257
|
+
except FileNotFoundError:
|
|
258
|
+
pass # no binaries
|
|
259
|
+
|
|
243
260
|
def __repr__(self):
|
|
244
261
|
properties = f"{len(self.ports)} variables, ts={self.step_size}s"
|
|
245
262
|
if len(self.terminals) > 0:
|
|
@@ -1218,7 +1235,20 @@ class FMUContainer:
|
|
|
1218
1235
|
logger.debug(f"Copying {origin} in {destination}")
|
|
1219
1236
|
shutil.copy(origin, destination)
|
|
1220
1237
|
|
|
1221
|
-
def get_bindir_and_suffixe(self) -> Tuple[str, str, str]:
|
|
1238
|
+
def get_bindir_and_suffixe(self) -> Generator[Tuple[str, str, str], Any, None]:
|
|
1239
|
+
fmu_iter = iter(self.involved_fmu.values())
|
|
1240
|
+
try:
|
|
1241
|
+
fmu = next(fmu_iter)
|
|
1242
|
+
except StopIteration:
|
|
1243
|
+
raise FMUContainerError("No fmu declared in this container.")
|
|
1244
|
+
|
|
1245
|
+
os_list = fmu.platforms
|
|
1246
|
+
logger.debug(f"FMU '{fmu.name}' OS support: {', '.join(fmu.platforms)}.")
|
|
1247
|
+
|
|
1248
|
+
for fmu in fmu_iter:
|
|
1249
|
+
logger.debug(f"FMU '{fmu.name}' OS support: {', '.join(fmu.platforms)}.")
|
|
1250
|
+
os_list &= fmu.platforms
|
|
1251
|
+
|
|
1222
1252
|
suffixes = {
|
|
1223
1253
|
"Windows": "dll",
|
|
1224
1254
|
"Linux": "so",
|
|
@@ -1240,11 +1270,16 @@ class FMUContainer:
|
|
|
1240
1270
|
else:
|
|
1241
1271
|
target_bindirs = origin_bindirs
|
|
1242
1272
|
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1273
|
+
if os_list:
|
|
1274
|
+
logger.info(f"Container will be built for {', '.join(os_list)}.")
|
|
1275
|
+
else:
|
|
1276
|
+
logger.critical("No common OS found for embedded FMU. Try to re-run with '-debug'. Container won't be runnable.")
|
|
1277
|
+
|
|
1278
|
+
for os_name in os_list:
|
|
1279
|
+
try:
|
|
1280
|
+
yield origin_bindirs[os_name], suffixes[os_name], target_bindirs[os_name]
|
|
1281
|
+
except KeyError:
|
|
1282
|
+
raise FMUContainerError(f"OS '{os_name}' is not supported.")
|
|
1248
1283
|
|
|
1249
1284
|
def make_fmu_skeleton(self, base_directory: Path) -> Path:
|
|
1250
1285
|
logger.debug(f"Initialize directory '{base_directory}'")
|
|
@@ -1264,14 +1299,14 @@ class FMUContainer:
|
|
|
1264
1299
|
|
|
1265
1300
|
self.copyfile(origin / "model.png", base_directory)
|
|
1266
1301
|
|
|
1267
|
-
origin_bindir, suffixe, target_bindir
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1302
|
+
for origin_bindir, suffixe, target_bindir in self.get_bindir_and_suffixe():
|
|
1303
|
+
library_filename = origin / origin_bindir / f"container.{suffixe}"
|
|
1304
|
+
if library_filename.is_file():
|
|
1305
|
+
binary_directory = binaries_directory / target_bindir
|
|
1306
|
+
binary_directory.mkdir(exist_ok=True)
|
|
1307
|
+
self.copyfile(library_filename, binary_directory / f"{self.identifier}.{suffixe}")
|
|
1308
|
+
else:
|
|
1309
|
+
logger.critical(f"File {library_filename} not found.")
|
|
1275
1310
|
|
|
1276
1311
|
for i, fmu in enumerate(self.involved_fmu.values()):
|
|
1277
1312
|
shutil.copytree(self.long_path(fmu.fmu.tmp_directory),
|
|
File without changes
|