Package: loudml-python
The Python client interface to the Loud ML model server.Installationloudml-python requires a running Loud MLmodel server. SeeLoud ML’s quickstartfor installation instructions.loudml-python can be installed usingpipsimilar to other Python packages. Do not usesudowithpip. It is usually good to work in avirtualenvorvenvto avoid conflicts with other package managers and Python projects. For a quick introduction seePython Virtual Environments in Five Minutes.To install loudml-python, simply:$pipinstallloudml-pythonor from source:$pythonsetup.pyinstallGetting StartedIf you’ve installedloudml-pythonlocally, theloudmlcommand should be available via the command line. Executing loudml will start the CLI and automatically connect to the local Loud ML model server instance (assuming you have already started the server withsystemctl start loudmldor by running loudmld directly). The output should look like this:$loudmlConnectedtolocalhost:8077version1.6.0-577c87deLoudMLshell1.6.0-42136d38>You can get a description of the available commands:>helpClient Classes: Loud and JobThe main helper in the Python client library is theLoudclass. You
can create an instance that connects to a remote Loud ML model server
and run queries.>>>fromloudml_py.clientimportLoud>>>loud=Loud(hosts=['localhost:8077'])>>>models=loud.models.get(model_names=['first_model'],
        fields=['settings', 'state'],
        include_fields=True,
    )>>>len(models)1>>>print(models[0]['state']){'trained': False}Long running commands eg training return a job name. Useloudml.jobs.id(job_name)to create a class instance and then
track the progress of the job or cancel it.loudmlusestqdmto display progress information.def cancel_job_handler(*args):
    job.cancel()
    print('Signal received. Canceled job: ', job.id)
    sys.exit()

signal.signal(signal.SIGINT, cancel_job_handler)

while not job.done():
    time.sleep(1)
    job.fetch()Data generator: loudml-waveTheloudml-wavetool is included in this package. You can use the
application to output time series data with a given pattern and write
the data to a bucket.The output should look like this:$loudml-wave-v-fnow-1h-tnow--shapesin--tagstag_one:foo,tag_two:baroutput_bucketINFO:root:generatingdatafrom2019-09-2107:23:51.350293to2019-09-2108:23:51.350316Connectedtolocalhost:8077version1.5.0.88.g5ad0216INFO:root:writing131pointstimestampvaluetags1569043431.3538369.884tag_one=foo,tag_two=bar1569043431.8570881.022tag_one=foo,tag_two=bar1569043491.3533949.816tag_one=foo,tag_two=bar1569043551.3530892.148tag_one=foo,tag_two=bar1569043551.683333210851.922tag_one=foo,tag_two=barYou can get a description of the available commands:$loudml-wave-hChange LogPlease seeCHANGELOG.md.Issue ReportingIf you have found a bug or if you have a feature request, please report them at this repository issues section.
Please do not report security vulnerabilities on the public GitHub issue tracker.AuthorLoud MLloudml-python is developed and maintained by Sebastien Leger (@regel).
It can be found here:https://github.com/loudml/loudml-pythonSpecial thanks to:Christophe Osuna (@osunac) for all the review and packaging support.LicenseThis project is licensed under the MIT license. See theLICENSEfile for more info.