Skip to content
This repository has been archived by the owner on Nov 17, 2020. It is now read-only.

Latest commit

 

History

History
50 lines (35 loc) · 1.07 KB

README.md

File metadata and controls

50 lines (35 loc) · 1.07 KB

DummyPy

afpro's python library for dummies, include

  • python common utils (eg. lazy property)
  • tensorflow utils (eg. load/save, gpu growth config)
  • common models (eg. google attention model)

usage:

# normal
pip install dummy_py

# install tensorflow as dependency
pip install dummy_py[tf]

# install tensorflow-gpu as dependency
pip install dummy_py[tf_gpu]

dummy_py.common

common python utils

  • lazy property
  • io utils
  • simplify map/filter method as Sequence class
  • simple orm between OrmObject and dict

dummy_py.tf_utils

include tensorflow util codes

  • load checkpoint
  • save checkpoint
  • create tf.ConfigProto for gpu memory growth support
  • create multi layer LSTM rnn cell
  • create embedding lookup structure
  • calculate cross entropy with sequence length support
  • general attention calculation
  • numpy softmax implements
  • tensorflow while loop abstraction as Loop class
  • tf_session_fn decorator

dummy_py.tf_parts

include tensorflow model elements