[![Documentation Status](https://readthedocs.org/projects/simphony/badge/?version=latest)](https://simphony.readthedocs.io/en/latest/?badge=latest)
![](https://github.com/simphony/osp-core/workflows/CI/badge.svg)
# OSP core
Native implementation of the core cuds object and the class generation
by the SimPhoNy team at Fraunhofer IWM. Builds up on the previous
version, simphony-common (SimPhoNy, EU FP7 Project (Nr. 604005)
www.simphony-project.eu).
## Requirements
- PyYaml (on Windows, use <https://stackoverflow.com/a/33673823>) for parsing yaml files
- numpy for vector attributes of cuds
- websockets for the transport layer
- requests for sending CUDS to a server
- tox to run unittests
- unittest2 to run unittests
- pympler for the performance test
- responses for unittesting requests
## Installation
OSP-core is available on PyPI, so it can be installed using `pip`
```shell
pip install osp-core
```
For more detailed instructions, see [https://simphony.readthedocs.io/en/latest/installation.html](https://simphony.readthedocs.io/en/latest/installation.html).
## Visualization of ontologies
We provide the tool `ontology2dot` to visualize your ontologies. You can visualize installed namespaces together with non-installed yaml files (requires Graphviz https://graphviz.gitlab.io/):
```sh
ontology2dot <installed-namespace-1> ... <installed-namespace-n> <path/to/ontology-1.yml> ... <path/to/ontology-m.yml>
# Alternative
python -m osp.core.tools.ontology2dot <installed-namespace-1> ... <installed-namespace-n> <path/to/ontology-1.yml> ... <path/to/ontology-m.yml>
```
You can use parameter `-g` to group the namespaces. Use `-o` to change the filename of the resulting png file.
## Testing
Testing is done using tox (`pip install tox`):
```sh
# run tests automatically in different environments
tox
# run tests in your current environment (you must manually install unittest2, responses for that)
python -m unittest -v
```
## Documentation
Our documentation is located at <https://simphony.readthedocs.io>.
If you want to build the documentation locally, refer to our [documentation repostitory](https://github.com/simphony/docs).
### Examples
Further examples can be found in the /examples folder. There the usage of wrappers is explained.
## Troubleshooting
If installation fails, try to install the dependencies one by one before installing osp-core.
The dependencies are listed at the top of this readme file.
On Windows, unittests can fail when you use a virtual environment.
For testing the transport layer, we start a transport layer server using pythons subprocess package.
It can happen, that the started subprocess does not pick up the correct virtual environment, causing the server to crash and the corresponding tests to fail.
From our experience, this will not happen if you use the virtual environements of conda.
### Directory structure
- osp/core -- The source code
- tools -- various tools to work with osp-core.
- ontology -- the parser and generation of the entities and classes.
- yml -- The supplied ontology files
- session -- Different abstract classes for wrappers.
- examples -- examples of usage.
- tests -- unittesting of the code
## Acknowledgements
The OSP-core Python package originates from the European Project [SimPhoNy](https://www.simphony-project.eu/) (Project Nr. 604005). We would like to acknowledge and thank our project partners, especially [Enthought, Inc](https://www.enthought.com/), [Centre Internacional de Mètodes Numèrics a l'Enginyeria (CIMNE)](https://cimne.com/) and the [University of Jyväskylä](https://www.jyu.fi/en), for their important contributions to some of the core concepts of OSP-core, which were originally demonstrated under the project https://github.com/simphony/simphony-common.
Raw data
{
"_id": null,
"home_page": "https://github.com/simphony",
"name": "osp-core",
"maintainer": "Fraunhofer IWM",
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": "simphony@iwm.fraunhofer.de",
"keywords": "owl ontology interoperability materials-science osp simphony wrappers cuds open-simulation-platform",
"author": "SimPhoNy, EU FP7 Project (Nr. 604005)",
"author_email": "",
"download_url": "https://files.pythonhosted.org/packages/70/25/9dd44f264ef1eb5fad52dc0144e82e7846302fb27b419c35cbbbeb48da4e/osp-core-3.9.0.tar.gz",
"platform": null,
"description": "[![Documentation Status](https://readthedocs.org/projects/simphony/badge/?version=latest)](https://simphony.readthedocs.io/en/latest/?badge=latest)\n![](https://github.com/simphony/osp-core/workflows/CI/badge.svg)\n\n# OSP core\n\nNative implementation of the core cuds object and the class generation\nby the SimPhoNy team at Fraunhofer IWM. Builds up on the previous\nversion, simphony-common (SimPhoNy, EU FP7 Project (Nr. 604005)\nwww.simphony-project.eu).\n\n## Requirements\n\n- PyYaml (on Windows, use <https://stackoverflow.com/a/33673823>) for parsing yaml files\n- numpy for vector attributes of cuds\n- websockets for the transport layer\n- requests for sending CUDS to a server\n- tox to run unittests\n- unittest2 to run unittests\n- pympler for the performance test\n- responses for unittesting requests\n\n## Installation\n\nOSP-core is available on PyPI, so it can be installed using `pip`\n\n```shell\npip install osp-core\n```\n\nFor more detailed instructions, see [https://simphony.readthedocs.io/en/latest/installation.html](https://simphony.readthedocs.io/en/latest/installation.html).\n\n## Visualization of ontologies\n\nWe provide the tool `ontology2dot` to visualize your ontologies. You can visualize installed namespaces together with non-installed yaml files (requires Graphviz https://graphviz.gitlab.io/):\n\n```sh\nontology2dot <installed-namespace-1> ... <installed-namespace-n> <path/to/ontology-1.yml> ... <path/to/ontology-m.yml>\n\n# Alternative\npython -m osp.core.tools.ontology2dot <installed-namespace-1> ... <installed-namespace-n> <path/to/ontology-1.yml> ... <path/to/ontology-m.yml>\n```\n\nYou can use parameter `-g` to group the namespaces. Use `-o` to change the filename of the resulting png file.\n\n## Testing\n\nTesting is done using tox (`pip install tox`):\n\n```sh\n# run tests automatically in different environments\ntox\n\n# run tests in your current environment (you must manually install unittest2, responses for that)\npython -m unittest -v\n```\n\n## Documentation\n\nOur documentation is located at <https://simphony.readthedocs.io>.\n\nIf you want to build the documentation locally, refer to our [documentation repostitory](https://github.com/simphony/docs).\n\n### Examples\n\nFurther examples can be found in the /examples folder. There the usage of wrappers is explained.\n\n## Troubleshooting\n\nIf installation fails, try to install the dependencies one by one before installing osp-core.\nThe dependencies are listed at the top of this readme file.\n\nOn Windows, unittests can fail when you use a virtual environment.\nFor testing the transport layer, we start a transport layer server using pythons subprocess package.\nIt can happen, that the started subprocess does not pick up the correct virtual environment, causing the server to crash and the corresponding tests to fail.\nFrom our experience, this will not happen if you use the virtual environements of conda.\n\n### Directory structure\n\n- osp/core -- The source code\n - tools -- various tools to work with osp-core.\n - ontology -- the parser and generation of the entities and classes.\n - yml -- The supplied ontology files\n - session -- Different abstract classes for wrappers.\n- examples -- examples of usage.\n- tests -- unittesting of the code\n\n## Acknowledgements\n\nThe OSP-core Python package originates from the European Project [SimPhoNy](https://www.simphony-project.eu/) (Project Nr. 604005). We would like to acknowledge and thank our project partners, especially [Enthought, Inc](https://www.enthought.com/), [Centre Internacional de M\u00e8todes Num\u00e8rics a l'Enginyeria (CIMNE)](https://cimne.com/) and the [University of Jyv\u00e4skyl\u00e4](https://www.jyu.fi/en), for their important contributions to some of the core concepts of OSP-core, which were originally demonstrated under the project https://github.com/simphony/simphony-common.\n",
"bugtrack_url": null,
"license": "BSD-3-Clause",
"summary": "The native implementation of the SimPhoNy CUDS objects",
"version": "3.9.0",
"split_keywords": [
"owl",
"ontology",
"interoperability",
"materials-science",
"osp",
"simphony",
"wrappers",
"cuds",
"open-simulation-platform"
],
"urls": [
{
"comment_text": "",
"digests": {
"md5": "b86bcebd82e6ca53087d7150fea82fc6",
"sha256": "89f7fb3adc74fde9e05808d449af4a0cf069e60d4b950412d8e7313be2e9fb03"
},
"downloads": -1,
"filename": "osp_core-3.9.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "b86bcebd82e6ca53087d7150fea82fc6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 153746,
"upload_time": "2022-12-07T14:27:08",
"upload_time_iso_8601": "2022-12-07T14:27:08.468546Z",
"url": "https://files.pythonhosted.org/packages/0b/e8/de723d25b09043ce645e3902bc1aadc22a08d79525b008765056ba3ea213/osp_core-3.9.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"md5": "f27d39b7d39f52c497dd9abe73319271",
"sha256": "3fce5c50e95b1cad22a1fb4091294b07ae8b0050030b3ffff9ca94af2cdcdb1b"
},
"downloads": -1,
"filename": "osp-core-3.9.0.tar.gz",
"has_sig": false,
"md5_digest": "f27d39b7d39f52c497dd9abe73319271",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 123674,
"upload_time": "2022-12-07T14:27:10",
"upload_time_iso_8601": "2022-12-07T14:27:10.634108Z",
"url": "https://files.pythonhosted.org/packages/70/25/9dd44f264ef1eb5fad52dc0144e82e7846302fb27b419c35cbbbeb48da4e/osp-core-3.9.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2022-12-07 14:27:10",
"github": false,
"gitlab": false,
"bitbucket": false,
"lcname": "osp-core"
}