Skip to main content

GDMO native classes for standardized interaction with data objects within Azure Databricks. Contains TimeSeriesForecasting, APIRequest, Landing, and Delta functions.

Project description

gdmo

PyPI Tests Changelog License

GDMO native classes for standardized interaction with data objects within Azure Databricks

This custom library allows our engineering team to use standardized packages that strip away a load of administrative and repetitive tasks from their daily object interactions. The current classes supported (V0.1.0) are:

Installation

Install this library using pip:

pip install gdmo

Usage

Forecast - Forecast

Standardized way of forecasting a dataset. Input a dataframe with a Series, a Time, and a Value column, and see the function automatically select the right forecasting model and generate an output.

Example usage:

from gdmo import TimeSeriesForecast
forecaster = TimeSeriesForecast(spark, 'Invoiced Revenue')\
                    .set_columns('InvoiceDate', 'ProductCategory', 'RevenueUSD')\
                    .set_forecast_length(forecast_length)\
                    .set_last_data_point(lastdatamonth)\
                    .set_input(df)\
                    .set_growth_cap(0.02)\
                    .set_use_cap_growth(True)\
                    .set_modelselection_breakpoints(12, 24)\
                    .set_track_outcome(False)\
                    .build_forecast()

forecaster.inspect_forecast()

API - APIRequest

Class to perform a standard API Request using the request library, which allows a user to just add their endpoint / authentication / method data, and get the data returned without the need of writing error handling or need to understand how to properly build a request.

Example usage:

request = APIRequest(uri)\
            .set_content_type('application/json') \
            .set_header('bearer xxxxx') \
            .set_method('GET') \
            .set_parameters({"Month": "2024-01-01"})\
            .make_request()

response = request.get_json_response()
display(response)

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

gdmo-0.0.19.tar.gz (27.6 kB view details)

Uploaded Source

Built Distribution

gdmo-0.0.19-py3-none-any.whl (27.6 kB view details)

Uploaded Python 3

File details

Details for the file gdmo-0.0.19.tar.gz.

File metadata

  • Download URL: gdmo-0.0.19.tar.gz
  • Upload date:
  • Size: 27.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for gdmo-0.0.19.tar.gz
Algorithm Hash digest
SHA256 6460d49d7de5ed3ce102f8af1bd3ed1a8f6a2cfd4d1dfefbbd2cb5e13c1ef1e5
MD5 a5fea2cc794526cbd5759ddf895abaeb
BLAKE2b-256 426813b297634e016d2a5abb8a88bdc162cad4bb2d58a5fc769e4efcf6612b9a

See more details on using hashes here.

File details

Details for the file gdmo-0.0.19-py3-none-any.whl.

File metadata

  • Download URL: gdmo-0.0.19-py3-none-any.whl
  • Upload date:
  • Size: 27.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for gdmo-0.0.19-py3-none-any.whl
Algorithm Hash digest
SHA256 c0ac185d83ce886d5b292aab4ac9776b32540ffde9f23619d6fda8e76a9ec286
MD5 5e1e4dc987f916aec1d7f7e21b24bb8a
BLAKE2b-256 f4499e79c0a19f23b7e9585294db28717264e75b8d2be42b3eb0ea2b94e1468e

See more details on using hashes here.

Supported by

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