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
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
mongo_tfrecords-0.0.2.tar.gz
(8.9 kB
view hashes)
Built Distribution
Close
Hashes for mongo_tfrecords-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 737af136036558039c17b1952204d8f729b6d893f91b305964c1dcadeb068811 |
|
MD5 | 7a5c85acafaafd276a42cc1d0978bdbd |
|
BLAKE2b-256 | 366188e1b5bb670cb30f7f71f1af46dde712cb0c655185a8b5e6b16516e262f0 |