refactor: use characterizations to replace layer type hierarchy
check network topology for back-propagation
unit-test for network topology check