Skip to main content

Load Aspect Models based on the Semantic Aspect Meta Model

Project description

The Aspect Model Loader as part of the Python SDK provided by the Eclipse Semantic Modeling Framework.

An Aspect of the Meta Model

The esmf-aspect-model-loader package provides the Python implementation for the SAMM Aspect Meta Model, or SAMM. Each Meta Model element and each Characteristic class is represented by an interface with a corresponding implementation.

Usage

An Aspect of the Meta Model can be created as follows using the provided AspectInstantiator.

aspect_loader = AspectLoader()
aspect = aspect_loader.load_aspect_model("absolute/path/to/turtle.ttl");

or

aspect_loader = AspectLoader()
aspect = aspect_loader.load_aspect_model_from_multiple_files(["list/of/absolute/paths/to/turtles.ttl"], "aspect_urn");

Automatic Deployment

A GitHub action called 'Release' has been set up for the esmf-aspect-model-loader. This action checks the code quality by running tests, the static type checker MyPy and the code formatter 'Black'.

Set Up SAMM Aspect Meta Model for development

In order to download the SAMM sources, it is required to run poetry install once in the esmf-aspect-model-loader module. There are two possibilities to download the SAMM files and extract the Turtle sources for the Meta Model.

Possibility 1 (downloading a release)

The download_samm_release script may be executed with

poetry run download-samm-release

It downloads a release JAR-file from GitHub and extracts the SAMM Files. The version is specified in the python script.

Link to all Releases: https://github.com/eclipse-esmf/esmf-semantic-aspect-meta-model/releases

Possibility 2 (downloading from the repository)

It may happen that there is no .jar file that is up to date with the changes of the SAMM. This script is an alternative to the download_samm_release.py and extracts the files from the repository directly instead of using the newest release.

The script uses the GitHub API and downloads the files from the main branch. If the script is run in a pipeline, it uses a GitHub token to authorize. If the script is run locally, the API is called without a token. This may cause problems because unauthorized API calls are limited.

This script can be executed with

poetry run download-samm-branch

to download and start working with the Aspect Model Loader.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

test_esmf_loader-0.0.2.tar.gz (328.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

test_esmf_loader-0.0.2-py3-none-any.whl (455.2 kB view details)

Uploaded Python 3

File details

Details for the file test_esmf_loader-0.0.2.tar.gz.

File metadata

  • Download URL: test_esmf_loader-0.0.2.tar.gz
  • Upload date:
  • Size: 328.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.11.3 Windows/10

File hashes

Hashes for test_esmf_loader-0.0.2.tar.gz
Algorithm Hash digest
SHA256 c1825b4e556575f2dbb7d1c123e1ba36a9fc3ed5e5c3be74467c251c1d0ddfca
MD5 934ffd06d30a1809229c6bd4e82cf8eb
BLAKE2b-256 9e1b1611969ebe34bf2c584a1f46e80550af02861d3bf98d11cb9aaabc528376

See more details on using hashes here.

File details

Details for the file test_esmf_loader-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: test_esmf_loader-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 455.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.11.3 Windows/10

File hashes

Hashes for test_esmf_loader-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b13ce5298ccbf44403bfe360895cc9c548784e1b9f1486f46ff4dbad4f8eaca2
MD5 27a6720ec8ac6dc43f1f1ef9deeb0c44
BLAKE2b-256 9353bd1481f28c9d2a2b4ef3c9f9ece31c9730172c8ec9c663e9af22d9bfc00d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page