Python utility tools for research
Project description
ToolMan: Python utility functions for R&D
See the source for this project here
Modules:
misc_utils.py:
miscellaneous utility functions including data I/O and processing
a) Read/write different formats of files in one function:
import toolman as tm
data = tm.misc_utils.load_file(file_name)
tm.misc_utils.save_file(file_name, data)
Currently support extensions including: .npy
, .pkl
, .txt
, .csv
, .json
and commonly used image formats.
b) Argument parser, parse nested argument list:
import sys
import argparse
import toolman as tm
parser = argparse.ArgumentParser()
args, extras = parser.parse_known_args(sys.argv[1:])
cfg_dict = tm.misc_utils.parse_args(extras)
vis_utils.py:
Matplotlib utility functions for visualization
a) Display images in side by side with axis linked
import toolman as tm
fig1 = tm.misc_utils.load_file(img_name_1)
fig2 = tm.misc_utils.load_file(img_name_1)
tm.vis_utils.compare_figures([fig1, fig2], (1, 2), fig_size=(12, 5))
img_utils:
image specific utility functions
pytorch_utils:
pytorch specific utility functions
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
toolman-0.1.2.tar.gz
(8.0 kB
view hashes)