some deep network fixes