application will allow users to share and dereference ML models.
Project description
airML
Distributed and Decentralized Deployment of ML models at scale
This package is created to distribute KBox, which allow users to share and dereference ML models.
-
Download the library here
-
Install using pip
pip install airML
Use it in from your terminal
Once you install the airML package, you can directly execute the commands from the terminal. You don't need to open up a python environment to use the airML package.
Open a terminal and execute KBox commands in python with airML package as below,
airML list -o json
**Note: Here the -o json
is an optional parameter. If you want to get the output as a json message, you should use this.
Otherwise, use the command without -o json
.
{
"status_code": 200,
"message": "visited all KNs.",
"results": [
{
"name": "http://purl.org/pcp-on-web/dbpedia",
"format": "kibe",
"version": "c9a618a875c5d46add88de4f00b538962f9359ad"
},
{
"name": "http://purl.org/pcp-on-web/ontology",
"format": "kibe",
"version": "c9a618a875c5d46add88de4f00b538962f9359ad"
},
{
"name": "http://purl.org/pcp-on-web/dataset",
"format": "kibe",
"version": "dd240892384222f91255b0a94fd772c5d540f38b"
}
]
}
Like the above command, you can use all other KBox commands with airML package. You can refer to the document here to get a good understanding of other KBox commands as well.
Use it in your python application.
execute(command)
Description: Execute the provided command in the KBox.jar
Args:
command: 'string', KBox command which should be exectue in KBox.
Returns:
string
If you want to use the airML inside your python application, you can follow these instructions,
-
Import the airML package (
from airML import airML
). -
Execute any KBox command with execute() function as follows.
airML.execute('KBox_Command')
**Note: execute()
method will return a string output which contains the result of the executed command.
Other than the execute command you can use following methods directly,
list(kns=False)
Description: List all available models(kns=False) or list all KNS services(kns=True).
Args:
kns:'boolean',defines whether to list only the KNS services or not
Returns:
Results from the KBox as JSON String
install(modelID, format=None, version=None):
Description: Install the a model by given modelID
Args:
modelID: 'string', url of the model hosted in a public repository.
format: 'string', format of the model.
version: 'string' specific version to be installed of the the model.
Returns:
Results from the kbox as JSON String
Example:
install("http://nspm.org/art","NSPM","0")
getInfo(model):
Description: Gives the information about a specific model.
Args:
model: url of the model.
Return:
Results from the kbox as JSON String
locate(modelID, format, version=None):
Description: Returns the local address of the given model.
Args:
modelID: 'string',url of the model to be located.
format: 'string',format of the model.
version: 'string',version of the model.
Returns:
Results from the kbox as JSON String
search(pattern, format, version=None):
Description: Search for all model-ids containing a given pattern.
Args:
pattern: 'string',pattern of the url of the models.
format: 'string',format of the model.
version: 'string',version of the model.
Returns:
Search Result from the KBox as a JSON String
Source URLs
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
Built Distribution
File details
Details for the file airML-0.0.3.tar.gz
.
File metadata
- Download URL: airML-0.0.3.tar.gz
- Upload date:
- Size: 4.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7bc24ce13549b0c56903682aef0c96fefa6b2883c78a1d13f27aba0b10b72b9b |
|
MD5 | 06ee3a9cfccb2cdbe25d9d16c6fd4aaf |
|
BLAKE2b-256 | 5edd532238ecae59f39b4f7a8341f3fc89696827fb027d04f9eac5a5574dc681 |
File details
Details for the file airML-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: airML-0.0.3-py3-none-any.whl
- Upload date:
- Size: 19.6 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.6.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.6.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 372fdbffbfca6216ecf3ba705c43c124001acea5ac278d3ca0eb702e0ed19043 |
|
MD5 | a8cba0445fca31482fc5feb3e97d601f |
|
BLAKE2b-256 | d66fc17cceea169a1c0f0862fbe1d1e04701deb2f17ba4024c7ea2edcdb98a45 |