improved exporter for caffe output