cleaning up conv net implementation