Skip to main content

mongo-tfrecords - Library that exports mongodb data to tensorflow files (tf-record)

Project description

mongo-tfrecords

mongo-tfrecords - Library that exports mongodb data to tensorflow files (tf-record)

Installation

pip install mongo-tfrecords

Usage examples

# from bash
python3 -m mongo_tfrecords 

# api docs
python3 -m mongo_tfrecords --help
# from python
from mongo_tfrecords import export

export(
    collection="test", 
    database="mongodb://user:password@hostname:27017/database_name?authSource=admin",
    path="/path/to/",
    files_template="{}.tfrecord",
    count_per_file=100000,  # count items per one file
    features=["field1", "field2"],  # fields [int, float, string, bytes, ...],
    skip=10,
    limit=10000,
    verbose=True,  # show progress bar
)

License

Apache License 2.0 (See LICENSE)

Copyright 2020, Vadim Sharay

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

mongo_tfrecords-0.0.2.tar.gz (8.9 kB view details)

Uploaded Source

Built Distribution

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

mongo_tfrecords-0.0.2-py3-none-any.whl (10.2 kB view details)

Uploaded Python 3

File details

Details for the file mongo_tfrecords-0.0.2.tar.gz.

File metadata

  • Download URL: mongo_tfrecords-0.0.2.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.2

File hashes

Hashes for mongo_tfrecords-0.0.2.tar.gz
Algorithm Hash digest
SHA256 50fc6d572211fb73906aef239d0d4ca7b2f1a9d659cf0765c56190d0b0880197
MD5 1aa7b59045f8d5ce756cd6043a9fd804
BLAKE2b-256 e38496c7874cefe68034a515c2434f8af42c9d305253741262ec29591ef2a7d0

See more details on using hashes here.

File details

Details for the file mongo_tfrecords-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: mongo_tfrecords-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 10.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.6.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.2

File hashes

Hashes for mongo_tfrecords-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 737af136036558039c17b1952204d8f729b6d893f91b305964c1dcadeb068811
MD5 7a5c85acafaafd276a42cc1d0978bdbd
BLAKE2b-256 366188e1b5bb670cb30f7f71f1af46dde712cb0c655185a8b5e6b16516e262f0

See more details on using hashes here.

Supported by

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