diff --git a/README.md b/README.md index 58f4bce..33ece3e 100644 --- a/README.md +++ b/README.md @@ -21,15 +21,15 @@ Use the following to cite this repository: author = {Christopher Teubert and Jason Watkins and Katelyn Jarvis}, title = {Prognostics As-A-Service (PaaS) Sandbox}, month = May, - year = 2024, - version = {1.7}, + year = 2025, + version = {1.8}, url = {https://github.com/nasa/prog_server} } ``` The corresponding reference should look like this: -C. Teubert, J. Watkins, K. Jarvis, Prognostics As-A-Service (PaaS) Sandbox, v1.7, May 2024. URL https://github.com/nasa/prog_server. +C. Teubert, J. Watkins, K. Jarvis, Prognostics As-A-Service (PaaS) Sandbox, v1.8, May 2025. URL https://github.com/nasa/prog_server. ## Notices Copyright © 2021 United States Government as represented by the Administrator of the National Aeronautics and Space Administration. All Rights Reserved. diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..154d48e --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,55 @@ +[build-system] +requires = ["setuptools"] +build-backend = "setuptools.build_meta" + +[project] +name = "prog_server" +version = "1.8.0-pre" +dependencies = [ + 'progpy', + 'requests', + 'urllib3', + 'flask' + +] +requires-python = ">=3.9, <3.14" +authors = [ + {name = "Christopher Teubert", email = "christopher.a.teubert@nasa.gov"}, + {name = "Katelyn Griffith", email = "katelyn.j.griffith@nasa.gov"}, + {name = "Jason Watkins"} +] +maintainers = [ + {name = "Christopher Teubert", email = "christopher.a.teubert@nasa.gov"}, + {name = "Katelyn Griffith", email = "katelyn.j.griffith@nasa.gov"} +] +description = "The NASA Prognostics As-A-Service (PaaS) Sandbox (a.k.a. prog_server) is a simplified Software Oriented Architecture (SOA) for performing prognostics of engineering systems. The PaaS Sandbox is a wrapper around the Prognostics Algorithms and Models Packages, allowing 1+ users to access these packages features through a REST API. The package is intended to be used as a research tool to prototype and benchmark Prognostics As-A-Service (PaaS) architectures and work on the challenges facing such architectures." +readme = "README.md" +license = "NASA-1.3" +license-files = ["license.pdf",] +keywords = ['prognostics', 'diagnostics', 'fault detection', 'fdir', 'physics modeling', 'prognostics and health management', 'PHM', 'health management', 'prognostics as a service', 'ivhm'] +classifiers = [ + 'Development Status :: 5 - Production/Stable', + + 'Intended Audience :: Science/Research', + 'Intended Audience :: Developers', + 'Intended Audience :: Manufacturing', + + 'Topic :: Scientific/Engineering', + 'Topic :: Scientific/Engineering :: Artificial Intelligence', + 'Topic :: Scientific/Engineering :: Physics', + + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', + 'Programming Language :: Python :: 3.11', + 'Programming Language :: Python :: 3.12', + 'Programming Language :: Python :: 3.13', + 'Programming Language :: Python :: 3 :: Only' +] + +[project.urls] +Homepage = "https://nasa.github.io/progpy/" +Documentation = "https://nasa.github.io/progpy/" +Repository = "https://github.com/nasa/prog_server" +Issues = "https://github.com/nasa/prog_server/issues" +Organization = "https://www.nasa.gov/content/diagnostics-prognostics" diff --git a/setup.py b/setup.py deleted file mode 100644 index 82eb9fd..0000000 --- a/setup.py +++ /dev/null @@ -1,56 +0,0 @@ -# Copyright © 2021 United States Government as represented by the Administrator of the -# National Aeronautics and Space Administration. All Rights Reserved. - -from setuptools import setup, find_packages -import pathlib - -here = pathlib.Path(__file__).parent.resolve() - -# Get the long description from the README file -long_description = (here / 'README.md').read_text(encoding='utf-8') - -setup( - name='prog_server', - version='1.7.0', - description='The NASA Prognostics As-A-Service (PaaS) Sandbox (a.k.a. prog_server) is a simplified Software Oriented Architecture (SOA) for performing prognostics of engineering systems. The PaaS Sandbox is a wrapper around the Prognostics Algorithms and Models Packages, allowing 1+ users to access these packages features through a REST API. The package is intended to be used as a research tool to prototype and benchmark Prognostics As-A-Service (PaaS) architectures and work on the challenges facing such architectures', - long_description=long_description, - long_description_content_type='text/markdown', - url='https://nasa.github.com/progpy/prog_server_guide.html', - author='Christopher Teubert', - author_email='christopher.a.teubert@nasa.gov', - classifiers=[ - 'Development Status :: 4 - Beta', - 'Intended Audience :: Science/Research', - 'Intended Audience :: Developers', - 'Intended Audience :: Manufacturing', - 'Topic :: Scientific/Engineering', - 'Topic :: Scientific/Engineering :: Artificial Intelligence', - 'Topic :: Scientific/Engineering :: Physics', - 'License :: Other/Proprietary License ', - 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.7', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: 3.9', - 'Programming Language :: Python :: 3.10', - 'Programming Language :: Python :: 3.11', - 'Programming Language :: Python :: 3.12', - 'Programming Language :: Python :: 3 :: Only' - ], - keywords=['prognostics', 'diagnostics', 'fault detection', 'fdir', 'physics modeling', 'prognostics and health management', 'PHM', 'health management', 'prognostics as a service', 'ivhm'], - package_dir={"":"src"}, - packages=find_packages(where='src'), - python_requires='>=3.7, <3.13', - install_requires=[ - 'progpy', - 'requests', - 'urllib3', - 'flask' - ], - license='NOSA', - project_urls={ # Optional - 'Bug Reports': 'https://github.com/nasa/prog_server/issues', - 'Docs': 'https://nasa.github.io/progpy/prog_server_guide.html', - 'Organization': 'https://www.nasa.gov/content/diagnostics-prognostics', - 'Source': 'https://github.com/nasa/prog_server', - }, -) diff --git a/src/prog_client/__init__.py b/src/prog_client/__init__.py index 182aa7a..ab0bc68 100644 --- a/src/prog_client/__init__.py +++ b/src/prog_client/__init__.py @@ -2,4 +2,4 @@ # National Aeronautics and Space Administration. All Rights Reserved. from prog_client.session import Session -__version__ = '1.7.0' +__version__ = '1.8.0-pre' diff --git a/src/prog_server/__init__.py b/src/prog_server/__init__.py index fd5006a..2b971f6 100644 --- a/src/prog_server/__init__.py +++ b/src/prog_server/__init__.py @@ -4,7 +4,7 @@ from .models.prog_server import server import time -__version__ = '1.7.0' +__version__ = '1.8.0-pre' def run(**kwargs): """ @@ -14,10 +14,13 @@ def run(**kwargs): host (str, optional): Server host. Defaults to '127.0.0.1'. port (int, optional): Server port. Defaults to 8555. debug (bool, optional): If the server is started in debug mode + models (dict[str, PrognosticsModel]): a dictionary of extra models to consider. The key is the name used to identify it. + predictors (dict[str, predictors.Predictor]): a dictionary of extra predictors to consider. The key is the name used to identify it. + state_estimators (dict[str, state_estimators.StateEstimator]): a dictionary of extra estimators to consider. The key is the name used to identify it. """ server.run(**kwargs) -def start(timeout=10, **kwargs): +def start(timeout: float=10, **kwargs) -> None: """ Start the server (not blocking). @@ -28,16 +31,19 @@ def start(timeout=10, **kwargs): host (str, optional): Server host. Defaults to '127.0.0.1'. port (int, optional): Server port. Defaults to 8555. debug (bool, optional): If the server is started in debug mode + models (dict[str, PrognosticsModel]): a dictionary of extra models to consider. The key is the name used to identify it. + predictors (dict[str, predictors.Predictor]): a dictionary of extra predictors to consider. The key is the name used to identify it. + state_estimators (dict[str, state_estimators.StateEstimator]): a dictionary of extra estimators to consider. The key is the name used to identify it. """ server.start(**kwargs) - for i in range(timeout): + for _ in range(timeout): if server.is_running(): return time.sleep(1) server.stop() raise Exception("Server startup timeout") -def stop(timeout=10): +def stop(timeout: float=10) -> None: """ Stop the server. @@ -51,7 +57,7 @@ def stop(timeout=10): time.sleep(1) raise Exception("Server startup timeout") -def is_running(): +def is_running() -> bool: """ Check if the server is running. """