General utilities
Project description
reinautils
The Utilities included are:
Parameters
Parameters (**kargs)
A splecial class whos atributes can be referenced as attributs or as dictionaty keys
device_by_name
device_by_name (name:str)
Return reference to cuda device by using Part of it’s name
Args: name: part of the cuda device name (shuuld be distinct)
Return: Reference to cuda device
Updated: Yuval 12/10/19
DatasetCat
DatasetCat (*datasets)
Concatenate datasets for Pytorch dataloader
The normal pytorch implementation does it only for raws. this is a “column” implementation
Arges: datasets: list of datasets, of the same length
Updated: Yuval 12/10/2019
Install
pip install reinautils
How to use
Parameters
You can create a Parameters class from dict
params=Parameters(first=1,second='A')
print(params.first)
1
You can also creat a Parameters class and populate it from a json file
params2=Parameters().from_json('config_demo.json')
print(params2)
Parameters:
path : Parameters:
data : /workspace/hd/
tmp : /workspace/hd/tmp/
features : /workspace/nvme/features/
train : /workspace/nvme/train/
models : /workspace/hd/models/
output : /workspace/hd/outputs/
test : /workspace/nvme/test/
platform : myserver
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
reinautils-0.0.2.tar.gz
(15.8 kB
view hashes)
Built Distribution
Close
Hashes for reinautils-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 464c68075c2963661eca5a8c7bac61d0554e90a3aa67254469f6c6e7ece14d64 |
|
MD5 | f3e93bbf6bcec956e9af8031f2a40a38 |
|
BLAKE2b-256 | dcd1d9438d11810fc6b2636d40e4ffee43555cc2fd3e63352f739cd8c781e90e |