Skip to main content

Download THOR files, run ECL scripts and download their results.

Project description

img/logo.jpg

The hpycc package is intended to simplify the use of data stored on HPCC and make it easily available to both users and other servers through basic Python calls. Its long-term goal is to make access to and manipulation of HPCC data as quick and easy as any other type system.

Documentation

The below readme and package documentation is available at http://hpycc.readthedocs.io

The package’s github is available at: https://github.com/OdinProAgrica/hpycc

This package is released under GNU GPLv3 Licence: https://www.gnu.org/licenses/gpl-3.0.en.html

Want to use this in R? Then the reticulate package is your friend! Just save as a CSV and read back in. That or you can use an R notebook with a Python chunk.

Installation

Install with:

pip install git+git://github.com/OdinProAgrica/hpycc

Current Status

Tested and working on HPCC v6.4.2 and python 3.5.2 under windows 10. Has been used on Linux systems but not extensively tested.

Dependencies

The package itself mainly uses core Python, Pandas is needed for outputting dataframes.

There is a dependency for client tools to run ECL scripts (you need ecl.exe and eclcc.exe). Make sure you install the right client tools for your HPCC version and add the dir to your system path, e.g. C:Program Files (x86)HPCCSystemsX.X.Xclienttoolsbin.

Tests require docker to spin up HPCC test environments.

Main Functions

Below summarises the key functions and non-optional parameters. For specific arguments see the relevant function’s documentation. Note that while retrieving a file is a multi-thread process, running a script and getting the results is not. Therefore if your file is quite big you may be better off saving the results of a script using run_script_internal() with a thor file output then downloading the file with get_file_internal().

get_output(script, server…) & save_output(script, server, path…)

Run a given ECL script and either return the first result as a pandas dataframe or save it to file.

get_outputs(script, server…) & save_outputs(script, server…)

Run a given ECL script and return all results as a dict of pandas dataframes or save them to files.

get_file_internal(logical_file, server…) & save_file(logical_file, path, server…)

Get a logical file and either return as a pandas dataframe or save it to file.

run_script_internal(script, server…)

Run a given ECL script. 10 rows will be returned but they will be dumped, no output is given.

Frequently Used Arguments

See function documentation for full list but those of note include:

  • Specifying a local ECL repository for scripts (repo=…)

  • Allowing files to be overridden when saving (refresh=…)

  • Altering the default HPCC port (port=…)

  • Adding usernames (username=…) and passwords (password=…)

  • Suppressing all but essential messages (silent=…)

Examples

TODO but check the tests directory for some example ECL scripts and calls.

Issues, Bugs, Comments?

Please use the package’s github: https://github.com/OdinProAgrica/hpycc

Any contributions are also welcome.

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

hpycc-0.1.4.tar.gz (34.6 kB view details)

Uploaded Source

Built Distribution

hpycc-0.1.4-py3-none-any.whl (63.1 kB view details)

Uploaded Python 3

File details

Details for the file hpycc-0.1.4.tar.gz.

File metadata

  • Download URL: hpycc-0.1.4.tar.gz
  • Upload date:
  • Size: 34.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.0.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.6

File hashes

Hashes for hpycc-0.1.4.tar.gz
Algorithm Hash digest
SHA256 03eac4ba442e521c2c14cf225eb15bbad011c3062735628e7c6f104ab7a9fc03
MD5 9a70318df5cf2598bacc8b19c99b5f17
BLAKE2b-256 5d971c72aa773ac5e0e69d1e6338a8951b005bcae5a11d4f78c4efe53c8b7710

See more details on using hashes here.

File details

Details for the file hpycc-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: hpycc-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 63.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.11.0 pkginfo/1.4.2 requests/2.19.1 setuptools/40.0.0 requests-toolbelt/0.8.0 tqdm/4.24.0 CPython/3.6.6

File hashes

Hashes for hpycc-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 4137198126bde46486160996ed57dc756f060f2c580c8fb29feb1b84fdffc5a5
MD5 209c8cb2208100024db3415472e9cfa8
BLAKE2b-256 45b17d787b795e69c3ef6a54a9fc640de158a273212a6c2e912d0a898b858f5c

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