Skip to main content

rct-modelpool

Installation

You can git install rctmodelpool via pip:

pip install git+https://github.com/rct-ai/rct-modelpool

or

pip install rctmodelpool

Usage

You can import the rctmodelpool.modelpool from the package like so:

sync_model

from rctmodelpool import modelpool

path = modelpool.sync_model("rcthub://CPM.csv")
print(path)

sync tgz

import os
import tarfile
from rctmodelpool import modelpool
from pathlib import Path

local_path = modelpool.sync_model("rcthub://"+config.bert_model_path)
parent_path = Path(local_path).parent
print("rcthub sync:",local_path)
modeltar = tarfile.open(local_path)
inside_folder = os.path.commonprefix(modeltar.getnames())
real_model_path = os.path.join(parent_path, inside_folder)
print('model folder:', real_model_path)
if not os.path.exists(real_model_path):
    modeltar.extractall(parent_path)
    print('tar extraction:', parent_path, local_path)

Download files

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

Source Distribution

rctmodelpool-0.1.9.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rctmodelpool-0.1.9-py3-none-any.whl (8.4 kB view details)

Uploaded Python 3

File details

Details for the file rctmodelpool-0.1.9.tar.gz.

File metadata

  • Download URL: rctmodelpool-0.1.9.tar.gz
  • Upload date:
  • Size: 6.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.0.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.7.9

File hashes

Hashes for rctmodelpool-0.1.9.tar.gz
Algorithm Hash digest
SHA256 08234411664f3a593019bd8c166880b91f677aa7ba7dc6b851f2ca023397efb0
MD5 8a8a4c077ea21d3fecc701adeba985c3
BLAKE2b-256 f4f352dd68777467fc833bb883cad18577ecdb1114927fbcaafa5379def622a8

See more details on using hashes here.

File details

Details for the file rctmodelpool-0.1.9-py3-none-any.whl.

File metadata

  • Download URL: rctmodelpool-0.1.9-py3-none-any.whl
  • Upload date:
  • Size: 8.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.0.1 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.7.9

File hashes

Hashes for rctmodelpool-0.1.9-py3-none-any.whl
Algorithm Hash digest
SHA256 d86ae55c76f380d5bfa2ad143232e5b0109e2e23b90a5be3e320a3bcf19105bc
MD5 e08160531f47f832ae51ff420e9750d6
BLAKE2b-256 118a7caefd0aff4378888b7bdcbbd0e67e30dd48535f0b39fce81c0533a29696

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.9 This release

2 files

0.1.8

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page