Skip to content
Snippets Groups Projects
Commit 9a08a179 authored by indu's avatar indu
Browse files

chores: rename to hermes client

parent 9091421f
No related branches found
No related tags found
No related merge requests found
RT-RAMSIS Python Client HERMES Python Client
File moved
...@@ -6,7 +6,7 @@ import requests ...@@ -6,7 +6,7 @@ import requests
from hydws.parser import BoreholeHydraulics from hydws.parser import BoreholeHydraulics
from seismostats import Catalog from seismostats import Catalog
from ramsis_client.utils import (NoContent, RequestsError, make_request, from hermes_client.utils import (NoContent, RequestsError, make_request,
rates_to_seismostats) rates_to_seismostats)
...@@ -67,13 +67,13 @@ FORECAST_FIELDS = { ...@@ -67,13 +67,13 @@ FORECAST_FIELDS = {
'modelruns': 'modelruns'} 'modelruns': 'modelruns'}
class RamsisClient(BaseClient): class HermesClient(BaseClient):
def __init__(self, def __init__(self,
url: str, url: str,
timeout: int = None) -> None: timeout: int = None) -> None:
""" """
Initialize Class. Initialize Class.
:param url: URL of the ramsis webservice :param url: URL of the hermes webservice
:param timeout: after how long, contacting the webservice should :param timeout: after how long, contacting the webservice should
be aborted be aborted
""" """
...@@ -160,7 +160,7 @@ class ForecastSeriesClient(BaseClient): ...@@ -160,7 +160,7 @@ class ForecastSeriesClient(BaseClient):
timeout: int = None) -> None: timeout: int = None) -> None:
""" """
Initialize Class. Initialize Class.
:param url: URL of the ramsis webservice :param url: URL of the hermes webservice
:param timeout: after how long, contacting the webservice should :param timeout: after how long, contacting the webservice should
be aborted be aborted
""" """
......
...@@ -57,9 +57,9 @@ def make_request(request, url, params={}, timeout=None, ...@@ -57,9 +57,9 @@ def make_request(request, url, params={}, timeout=None,
def rates_to_seismostats(rates: list) -> ForecastGRRateGrid: def rates_to_seismostats(rates: list) -> ForecastGRRateGrid:
""" """
Convert rates from ramsis to seismostats rate grid. Convert rates from hermes to seismostats rate grid.
:param rates: rates from ramsis :param rates: rates from hermes
:return: seismostats rate grid :return: seismostats rate grid
""" """
df = pd.json_normalize(rates, sep='_') df = pd.json_normalize(rates, sep='_')
......
[metadata] [metadata]
name = ramsis-client name = hermes-client
author = Schmid Nicolas author = Schmid Nicolas
author_email = nicolas.schmid@sed.ethz.ch author_email = nicolas.schmid@sed.ethz.ch
version = 0.0.1 version = 0.0.1
description = Client Library for RT-RAMSIS description = Client Library for HERMES
long_description = file: README.md, LICENSE long_description = file: README.md, LICENSE
license = AGPL License license = AGPL License
classifiers = classifiers =
...@@ -20,7 +20,7 @@ install_requires = ...@@ -20,7 +20,7 @@ install_requires =
python_requires = >= 3.10 python_requires = >= 3.10
[options.packages.find] [options.packages.find]
include=ramsis_client* include=hermes_client*
[flake8] [flake8]
select = E,F,W select = E,F,W
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment