Skip to main content

Modelmanager api

Project description

Welcome to Modelmanager-api!

This is a api model for interacting with modelmanager.

Note:

  • Example files are are in example_script directory.
  • Example assets are in api_assets directory.
  • It contains scripts for different actions(Add, Update, Delete).
  • EXAMPLE SCRIPTS - add_model.py - add_project.py - update_model.py - update_project.py - delete_model.py - delete_project.py
  • EXAMPLE ASSETS - Project Assets - Model Assets

Example Codes

###Add_Project###
from modelmanager_api.modelmanager_api import Usecase
secret_key = 'Secret-Key'
url = 'URL'
data = {
		"name": "UsecaseName",
		"author": "AuthorName",
		"description": "UsecaseDescription",
		"source": "UsecasSource",
		"contributor": "UsecaseContributor",
		"image": 'image.jpg' , #path to image file
		"banner": 'banner.jpg' , #path to banner file
	}
Usecase(secret_key, url).post_usecase(data) 
###Update_Project###
from modelmanager_api.modelmanager_api import Usecase
secret_key = 'Secret-Key'
url = 'URL'
project_id = Project_id #use model_id number to update
data = {
		"author": "AuthorName",
		"description": "UsecaseDescription",
		"source": "UsecasSource",
		"contributor": "UsecaseContributor",
		"image": 'image.jpg' , #path to image file
		"banner": 'banner.jpg' , #path to banner file
	}
Usecase(secret_key, url).patch_usecase(data, project_id)
###Delete_Project###
from modelmanager_api.modelmanager_api import Usecase
secret_key = 'Secret-Key'
url = 'URL'
project_id = Project_id #use project_id number to delete
Usecase(secret_key,url).delete_usecase(project_id)
###Add_Model### 
from modelmanager_api.modelmanager_api import Model
secret_key = 'Secret-Key'
url = 'URL'
data = {
		"project":Project_ID, #model add to which project
		"transformerType": "logistic",
		"target_column": "id",
		"note": "api script Model",
		"model_area": "api script Model",
		"model_dependencies": "api script Model",
		"model_usage": "api script Model",
		"model_audjustment": "api script Model",
		"model_developer": "api script Model",
		"model_approver": "api script Model",
		"model_maintenance": "api script Model",
		"documentation_code": "api script Model",
		"implementation_plateform": "api script Model",
		"training_dataset": "train.csv", #path to csv file
		"pred_dataset": "submissionsample.csv", #path to csv file
		"actual_dataset": "truth.csv", #path to csv file
		"test_dataset": "test.csv", #path to csv file
	}
Model(secret_key, url).post_model(data)
###Update_Model### 
from modelmanager_api.modelmanager_api import Model
secret_key = 'Secret-Key'
url = 'URL'
model_id = Model_id #use model_id number to update
data = {
		"project":Project_ID,
		"transformerType": "logistic",
		"target_column": "id",
		"note": "api script Model",
		"model_area": "api script Model",
		"model_dependencies": "api script Model",
		"model_usage": "api script Model",
		"model_audjustment": "api script Model",
		"model_developer": "api script Model",
		"model_approver": "api script Model",
		"model_maintenance": "api script Model",
		"documentation_code": "api script Model",
		"implementation_plateform": "api script Model",
		"training_dataset": "train.csv", #path to csv file
		"pred_dataset": "submissionsample.csv", #path to csv file
		"actual_dataset": "truth.csv", #path to csv file
		"test_dataset": "test.csv", #path to csv file
	}
Model(secret_key, url).patch_model(data, model_id)
###Delete_Model###
from modelmanager_api.modelmanager_api import Model
secret_key = 'Secret-Key'
url = 'URL'
model_id = Model_id #use model_id number to delete
Model(secret_key,url).delete_model(model_id)

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

modelmanager_api-2.0.5-py3-none-any.whl (577.5 kB view details)

Uploaded Python 3

File details

Details for the file modelmanager_api-2.0.5-py3-none-any.whl.

File metadata

  • Download URL: modelmanager_api-2.0.5-py3-none-any.whl
  • Upload date:
  • Size: 577.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/39.2.0 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.6.5

File hashes

Hashes for modelmanager_api-2.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 13a75ef3d07d814bd1c57898418ca990d0509db834897981d9d3d34b9e10fa77
MD5 ed0f96aeb906175877cc955407150912
BLAKE2b-256 1b69d1570a2b35c5e4f1b55903d64bac5bedb03e82949002bfc9caf70c4b76a4

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