Commit 773648ca authored by Oleg Dzhimiev's avatar Oleg Dzhimiev
Browse files

standalone code

parent d8533f78
Loading
Loading
Loading
Loading

BatchStreamPPM.h

deleted100644 → 0
+0 −204
Original line number Diff line number Diff line
#ifndef BATCH_STREAM_PPM_H
#define BATCH_STREAM_PPM_H
#include <vector>
#include <assert.h>
#include <algorithm>
#include <iomanip>
#include <fstream>
#include "NvInfer.h"
#include "common.h"

std::string locateFile(const std::string& input);

static constexpr int INPUT_C = 3;
static constexpr int INPUT_H = 300;
static constexpr int INPUT_W = 300;

extern const char* INPUT_BLOB_NAME;

class BatchStream
{
public:
	BatchStream(int batchSize, int maxBatches) : mBatchSize(batchSize), mMaxBatches(maxBatches)
	{
		mDims = nvinfer1::DimsNCHW{batchSize, 3, 300, 300 };
		mImageSize = mDims.c() * mDims.h() * mDims.w();
		mBatch.resize(mBatchSize * mImageSize, 0);
		mLabels.resize(mBatchSize, 0);
		mFileBatch.resize(mDims.n() * mImageSize, 0);
		mFileLabels.resize(mDims.n(), 0);
		reset(0);
	}

	void reset(int firstBatch)
	{
		mBatchCount = 0;
		mFileCount = 0;
		mFileBatchPos = mDims.n();
		skip(firstBatch);
	}

	bool next()
	{
		if (mBatchCount == mMaxBatches)
			return false;

		for (int csize = 1, batchPos = 0; batchPos < mBatchSize; batchPos += csize, mFileBatchPos += csize)
		{
			assert(mFileBatchPos > 0 && mFileBatchPos <= mDims.n());
			if (mFileBatchPos == mDims.n() && !update())
				return false;

			// copy the smaller of: elements left to fulfill the request, or elements left in the file buffer.
			csize = std::min(mBatchSize - batchPos, mDims.n() - mFileBatchPos);
			std::copy_n(getFileBatch() + mFileBatchPos * mImageSize, csize * mImageSize, getBatch() + batchPos * mImageSize);
		}
		mBatchCount++;
		return true;
	}

	void skip(int skipCount)
	{
		if (mBatchSize >= mDims.n() && mBatchSize % mDims.n() == 0 && mFileBatchPos == mDims.n())
		{
			mFileCount += skipCount * mBatchSize / mDims.n();
			return;
		}

		int x = mBatchCount;
		for (int i = 0; i < skipCount; i++)
			next();
		mBatchCount = x;
	}

	float *getBatch() { return mBatch.data(); }
	float *getLabels() { return mLabels.data(); }
	int getBatchesRead() const { return mBatchCount; }
	int getBatchSize() const { return mBatchSize; }
	nvinfer1::DimsNCHW getDims() const { return mDims; }
private:
	float* getFileBatch() { return mFileBatch.data(); }
	float* getFileLabels() { return mFileLabels.data(); }

	bool update()
	{
        std::vector<std::string> fNames;

	    std::ifstream file(locateFile("list.txt"));
        if(file)
        {
            std::cout  << "Batch #" << mFileCount << "\n";
            file.seekg(mCurPos);
        }
        for(int i = 1; i <= mBatchSize; i++)
        {
            std::string sName;
            std::getline(file, sName);
            sName = sName + ".ppm";

            std::cout << "Calibrating with file " << sName << std::endl;
            fNames.emplace_back(sName);
        }
        mCurPos = file.tellg();
        mFileCount++;

        std::vector<samplesCommon::PPM<INPUT_C, INPUT_H, INPUT_W>> ppms(fNames.size());
        for (uint32_t i = 0; i < fNames.size(); ++i)
        {
            readPPMFile(locateFile(fNames[i]), ppms[i]);
        }
        std::vector<float> data(samplesCommon::volume(mDims));

        long int volChl = mDims.h() * mDims.w();

        for (int i = 0, volImg = mDims.c() * mDims.h() * mDims.w(); i < mBatchSize; ++i)
        {
            for (int c = 0; c < mDims.c(); ++c)
            {
                for (int j = 0; j < volChl; ++j)
                {
                    data[i * volImg + c * volChl + j] = (2.0 / 255.0) * float(ppms[i].buffer[j * mDims.c() + c]) - 1.0;
                }
            }
        }

        std::copy_n(data.data(), mDims.n() * mImageSize, getFileBatch());

		mFileBatchPos = 0;
		return true;
	}

	int mBatchSize{0};
	int mMaxBatches{0};
	int mBatchCount{0};

	int mFileCount{0}, mFileBatchPos{0};
	int mImageSize{0};
    int mCurPos{0};

	nvinfer1::DimsNCHW mDims;
	std::vector<float> mBatch;
	std::vector<float> mLabels;
	std::vector<float> mFileBatch;
	std::vector<float> mFileLabels;
};

class Int8EntropyCalibrator : public nvinfer1::IInt8EntropyCalibrator
{
public:
    Int8EntropyCalibrator(BatchStream& stream, int firstBatch, std::string calibrationTableName, bool readCache = true)
        : mStream(stream),
        mCalibrationTableName(std::move(calibrationTableName)),
        mReadCache(readCache)
    {
    	nvinfer1::DimsNCHW dims = mStream.getDims();
        mInputCount = samplesCommon::volume(dims);
        CHECK_TRT(cudaMalloc(&mDeviceInput, mInputCount * sizeof(float)));
        mStream.reset(firstBatch);
    }

    virtual ~Int8EntropyCalibrator()
    {
        CHECK_TRT(cudaFree(mDeviceInput));
    }

    int getBatchSize() const override { return mStream.getBatchSize(); }

    bool getBatch(void* bindings[], const char* names[], int nbBindings) override
    {
        if (!mStream.next())
            return false;

        CHECK_TRT(cudaMemcpy(mDeviceInput, mStream.getBatch(), mInputCount * sizeof(float), cudaMemcpyHostToDevice));
        assert(!strcmp(names[0], INPUT_BLOB_NAME));
        bindings[0] = mDeviceInput;
        return true;
    }

    const void* readCalibrationCache(size_t& length) override
    {
        mCalibrationCache.clear();
        std::ifstream input(mCalibrationTableName, std::ios::binary);
        input >> std::noskipws;
        if (mReadCache && input.good())
            std::copy(std::istream_iterator<char>(input), std::istream_iterator<char>(), std::back_inserter(mCalibrationCache));
        length = mCalibrationCache.size();
        return length ? mCalibrationCache.data() : nullptr;
    }

    void writeCalibrationCache(const void* cache, size_t length) override
    {
        std::ofstream output(mCalibrationTableName, std::ios::binary);
        output.write(reinterpret_cast<const char*>(cache), length);
    }

private:
    BatchStream mStream;
    std::string mCalibrationTableName;
    bool mReadCache{true};

    size_t mInputCount;
    void* mDeviceInput{nullptr};
    std::vector<char> mCalibrationCache;
};
#endif
+13 −34
Original line number Diff line number Diff line
cmake_minimum_required(VERSION 3.16)

set(ENV{CUDACXX} /usr/local/cuda/bin/nvcc)

project(tf_detector_example LANGUAGES CXX CUDA)
project(tf-gpu-feed LANGUAGES CXX CUDA)

cmake_policy(SET CMP0074 OLD)

set(CMAKE_CXX_STANDARD 11)

# CUDA for cudacodec ops
set(CUDACXX /usr/local/cuda/bin/nvcc)

find_package(CUDA 9.0 REQUIRED)

set(SOURCE_FILES
    main.cpp
    utils.cpp 
    utils.h 
    dynlink_nvcuvid.cpp
    infer_with_trt.cpp
    inference_base.cpp 
    inference_tf.cpp
    channel_first.cu
    array.cu
    )

# Tensorflow directories and libraries
set(TENSORFLOW_LIBS libtensorflow_cc.so libtensorflow_framework.so)
set(MYHOME $ENV{HOME})

message("-- Home set to: " ${MYHOME})
link_directories("/usr/local/tensorflow/lib")

add_executable(tf_detector_example ${SOURCE_FILES})
set_target_properties(tf_detector_example PROPERTIES CUDA_SEPARABLE_COMPILATION ON)

# OpenCV libs
find_package(OpenCV REQUIRED)
add_executable(tf-gpu-feed ${SOURCE_FILES})
set_target_properties(tf-gpu-feed PROPERTIES CUDA_SEPARABLE_COMPILATION ON)

include_directories(${OpenCV_INCLUDE_DIRS} ${CUDA_INCLUDE_DIRS})

# ==================== PATHS TO SPECIFY! ==================== #
include_directories(${CUDA_INCLUDE_DIRS})

# TensorFlow headers
include_directories("/usr/local/tensorflow/include/tensorflow/")
include_directories("/usr/local/tensorflow/include/third-party/")
include_directories("/usr/local/tensorflow/include/")

# IMPORTANT: Protobuf includes. Depends on the anaconda path
# This is Azure DLVM (not sure if DSVM is the same)
#include_directories("/data/anaconda/envs/py36/lib/python3.6/site-packages/tensorflow/include/")
# This is a standard install of Anaconda with p36 environment
#include_directories("${MYHOME}/anaconda3/envs/py36/lib/python3.6/site-packages/tensorflow/include/")

target_link_libraries(tf_detector_example
target_link_libraries(tf-gpu-feed
    ${CUDA_LIBRARIES}
    cuda
    cublas
@@ -60,5 +40,4 @@ target_link_libraries(tf_detector_example
    nvinfer_plugin
    nvonnxparser
    ${CMAKE_DL_LIBS}
    ${OpenCV_LIBS} 
    ${TENSORFLOW_LIBS})

CalibrationTableSSD

deleted100644 → 0
+0 −293
Original line number Diff line number Diff line
1
(Unnamed ITensor* 9): 3d418f1e
Input: 3c010a14
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_3/AvgPool_0a_3x3/AvgPool: 3d205fca
(Unnamed ITensor* 225): 3d368720
(Unnamed ITensor* 412): 3d418f1e
(Unnamed ITensor* 195): 3dafce6e
(Unnamed ITensor* 138): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/MaxPool_3a_3x3/MaxPool: 3d418f1e
(Unnamed ITensor* 463): 3d418f1e
(Unnamed ITensor* 75): 3d2dcb21
(Unnamed ITensor* 157): 3d418f1e
BoxPredictor_3/ClassPredictor/BiasAdd: 3c8c8ef8
FeatureExtractor/InceptionV2/InceptionV2/Conv2d_2c_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/MaxPool_2a_3x3/MaxPool: 3d418f1e
(Unnamed ITensor* 61): 3d418f1e
(Unnamed ITensor* 462): 3d3d75f1
(Unnamed ITensor* 156): 3d618943
(Unnamed ITensor* 24): 3d913052
(Unnamed ITensor* 32): 3d6533f9
(Unnamed ITensor* 83): 3d3ca52c
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 118): 3d4aef99
(Unnamed ITensor* 485): 3d1d4f1e
BoxPredictor_4/BoxEncodingPredictor/BiasAdd: 3ca49bb9
(Unnamed ITensor* 84): 3d418f1e
(Unnamed ITensor* 160): 3d418f1e
BoxPredictor_5/ClassPredictor/BiasAdd: 3c773985
(Unnamed ITensor* 316): 3d63dc8a
FeatureExtractor/InceptionV2/InceptionV2/Conv2d_1a_7x7/separable_conv2d/depthwise: 3de7428e
(Unnamed ITensor* 90): 3d73f085
(Unnamed ITensor* 91): 3d418f1e
(Unnamed ITensor* 419): 3d418f1e
(Unnamed ITensor* 374): 3d59dbf2
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_0/Conv2d_0a_1x1/Relu6: 3d3c8d1a
FeatureExtractor/InceptionV2/Mixed_5c_1_Conv2d_5_1x1_64/Relu6: 3d17eae6
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_1/Conv2d_1a_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 507): 3d418f1e
(Unnamed ITensor* 2): 3c010a14
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 112): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 126): 3d20913a
(Unnamed ITensor* 104): 3d80ab32
(Unnamed ITensor* 134): 3d8dd320
(Unnamed ITensor* 324): 3d418f1e
(Unnamed ITensor* 135): 3d418f1e
(Unnamed ITensor* 628): 3d9d9605
(Unnamed ITensor* 449): 3d418f1e
(Unnamed ITensor* 119): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 513): 3d5e275c
(Unnamed ITensor* 164): 3d946ceb
Squeeze_2: 3cc8bb82
(Unnamed ITensor* 167): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_2/Conv2d_0a_1x1/Relu6: 3d2d4927
(Unnamed ITensor* 541): 3d37a99c
(Unnamed ITensor* 143): 3d418f1e
(Unnamed ITensor* 240): 3d418f1e
(Unnamed ITensor* 150): 3d418f1e
(Unnamed ITensor* 165): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 310): 3d418f1e
(Unnamed ITensor* 260): 3d60aac4
(Unnamed ITensor* 405): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_3/Conv2d_0b_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 105): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 382): 3d1e3cff
(Unnamed ITensor* 550): 3d418f1e
(Unnamed ITensor* 391): 3d418f1e
FeatureExtractor/InceptionV2/Mixed_5c_1_Conv2d_2_1x1_256/Relu6: 3d37a347
(Unnamed ITensor* 448): 3d6ab083
(Unnamed ITensor* 142): 3dd08cf3
(Unnamed ITensor* 595): 3d418f1e
BoxPredictor_1/ClassPredictor/BiasAdd: 3e194e24
concat_box_conf: 3e1bb222
(Unnamed ITensor* 594): 3d4ff643
(Unnamed ITensor* 602): 3d418f1e
BoxPredictor_5/Reshape_1: 3c773985
concat_box_loc: 3de14ea0
BoxPredictor_4/ClassPredictor/BiasAdd: 3ca5201c
Squeeze_4: 3ca49bb9
(Unnamed ITensor* 621): 3d418f1e
(Unnamed ITensor* 624): 3d17eae6
BoxPredictor_2/ClassPredictor/BiasAdd: 3e1ec6c2
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_3/Conv2d_0b_1x1/Relu6: 3d156ede
(Unnamed ITensor* 33): 3d418f1e
(Unnamed ITensor* 500): 3d418f1e
BoxPredictor_2/Reshape_1: 3e1ec6c2
FeatureExtractor/InceptionV2/Mixed_5c_2_Conv2d_5_3x3_s2_128/Relu6: 3d418f1e
BoxPredictor_5/BoxEncodingPredictor/BiasAdd: 3cdbc092
GridAnchor_1: 3a500341
(Unnamed ITensor* 569): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_0/Conv2d_1a_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 620): 3d17eae6
(Unnamed ITensor* 418): 3d91976a
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 111): 3d85a99e
(Unnamed ITensor* 575): 3dc8e55f
(Unnamed ITensor* 601): 3d8b91c4
BoxPredictor_1/Reshape_1: 3e194e24
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_1/Conv2d_0a_1x1/Relu6: 3d433d97
(Unnamed ITensor* 545): 3d37a347
BoxPredictor_3/Reshape_1: 3c8c8ef8
(Unnamed ITensor* 347): 3d418f1e
(Unnamed ITensor* 568): 3d1c5b35
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_3/AvgPool_0a_3x3/AvgPool: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 471): 3d418f1e
(Unnamed ITensor* 455): 3d500012
(Unnamed ITensor* 303): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_3/Conv2d_0b_1x1/Relu6: 3d20913a
BoxPredictor_4/Reshape_1: 3ca5201c
GridAnchor_4 copy: 3c3aa18a
FeatureExtractor/InceptionV2/Mixed_5c_2_Conv2d_3_3x3_s2_256/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_3/Conv2d_0b_1x1/Relu6: 3d1e3cff
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_2/MaxPool_1a_3x3/MaxPool: 3d418f1e
GridAnchor_5 copy: 3c2b37e3
(Unnamed ITensor* 331): 3d3ca1fe
NMS_1: 1
BoxPredictor_3/BoxEncodingPredictor/BiasAdd: 3cafbf65
(Unnamed ITensor* 188): 3dc61b5c
(Unnamed ITensor* 196): 3d418f1e
(Unnamed ITensor* 209): 3dc05776
GridAnchor_2 copy: 3c2c4ae8
(Unnamed ITensor* 367): 3d7bf53d
(Unnamed ITensor* 361): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_1/Conv2d_0b_3x3/Relu6: 3d3ceddc
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_0/Conv2d_0a_1x1/Relu6: 3d3772e6
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_3/Conv2d_0b_1x1/Relu6: 3d31060c
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 411): 3d836c20
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 18): 3d418f1e
(Unnamed ITensor* 390): 3d9a604f
(Unnamed ITensor* 346): 3d67b7ae
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
BoxPredictor_2/BoxEncodingPredictor/BiasAdd: 3cc8bb82
(Unnamed ITensor* 217): 3d4cf10e
FeatureExtractor/InceptionV2/Mixed_5c_2_Conv2d_2_3x3_s2_512/Relu6: 3d418f1e
(Unnamed ITensor* 233): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 542): 3d418f1e
(Unnamed ITensor* 67): 3d8e8123
(Unnamed ITensor* 247): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_3/AvgPool_0a_3x3/AvgPool: 3d1d88d2
(Unnamed ITensor* 302): 3daf4176
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 239): 3d4f00df
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 514): 3d418f1e
(Unnamed ITensor* 435): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 317): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 289): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 478): 3d3244f6
(Unnamed ITensor* 549): 3dbeda4a
(Unnamed ITensor* 261): 3d418f1e
(Unnamed ITensor* 492): 3d9e1645
(Unnamed ITensor* 441): 3d15c098
(Unnamed ITensor* 479): 3d418f1e
(Unnamed ITensor* 493): 3d418f1e
BoxPredictor_0/Reshape_1: 3e13296c
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_3/AvgPool_0a_3x3/AvgPool: 3d258e36
(Unnamed ITensor* 339): 3d5f2411
FeatureExtractor/InceptionV2/Mixed_5c_2_Conv2d_4_3x3_s2_256/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_1/Conv2d_1a_3x3/Relu6: 3d418f1e
Squeeze_1: 3d2f0384
GridAnchor: 3a4f5b62
(Unnamed ITensor* 368): 3d418f1e
Squeeze: 3df34968
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 375): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_3/MaxPool_0a_3x3/MaxPool: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_3/AvgPool_0a_3x3/AvgPool: 3d18b9fa
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_2/MaxPool_1a_3x3/MaxPool: 3d418f1e
(Unnamed ITensor* 253): 3d92390f
(Unnamed ITensor* 210): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_3/Conv2d_0b_1x1/Relu6: 3d4af27d
Squeeze_3: 3cafbf65
(Unnamed ITensor* 340): 3d418f1e
(Unnamed ITensor* 11): 3d418f1e
(Unnamed ITensor* 295): 3d9c64d4
FeatureExtractor/InceptionV2/Mixed_5c_1_Conv2d_3_1x1_128/Relu6: 3d1c5b35
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_1/Conv2d_0b_3x3/Relu6: 3d15c098
(Unnamed ITensor* 323): 3d5d9fd1
GridAnchor_4: 3c3aa18a
(Unnamed ITensor* 360): 3d88c0ec
(Unnamed ITensor* 25): 3d418f1e
(Unnamed ITensor* 288): 3d6b9ef7
(Unnamed ITensor* 226): 3d418f1e
(Unnamed ITensor* 456): 3d418f1e
(Unnamed ITensor* 46): 3d86ba82
BoxPredictor_0/BoxEncodingPredictor/BiasAdd: 3df34968
(Unnamed ITensor* 232): 3ddb36a3
(Unnamed ITensor* 521): 3cb42ac7
GridAnchor_3 copy: 3c348982
(Unnamed ITensor* 296): 3d418f1e
BoxPredictor_0/ClassPredictor/BiasAdd: 3e13296c
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_3/Conv2d_0b_1x1/Relu6: 3d2dcb21
(Unnamed ITensor* 202): 3d87a00a
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 269): 3d418f1e
GridAnchor_3: 3c348982
(Unnamed ITensor* 218): 3d418f1e
(Unnamed ITensor* 203): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4c/Branch_2/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 486): 3d418f1e
(Unnamed ITensor* 268): 3d0e4f64
Squeeze_5: 3cdbc092
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 254): 3d418f1e
(Unnamed ITensor* 182): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4d/Branch_3/AvgPool_0a_3x3/AvgPool: 3cb90e57
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 175): 3d418f1e
(Unnamed ITensor* 98): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_3/AvgPool_0a_3x3/AvgPool: 3d04ebdf
(Unnamed ITensor* 354): 3d418f1e
(Unnamed ITensor* 181): 3d8ef349
(Unnamed ITensor* 353): 3d3ce1d6
(Unnamed ITensor* 174): 3d5b5745
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_1/Conv2d_0b_3x3/Relu6: 3d418f1e
GridAnchor_1 copy: 3a500341
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_3/Conv2d_0b_1x1/Relu6: 3cb42ac7
(Unnamed ITensor* 149): 3d869442
(Unnamed ITensor* 68): 3d418f1e
(Unnamed ITensor* 17): 3d9d3367
(Unnamed ITensor* 404): 3d9d92ab
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4e/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 309): 3d8ac690
BoxPredictor_1/BoxEncodingPredictor/BiasAdd: 3d2f0384
(Unnamed ITensor* 60): 3d74b08e
(Unnamed ITensor* 189): 3d418f1e
(Unnamed ITensor* 97): 3d3f7d2c
(Unnamed ITensor* 53): 3d7e3945
(Unnamed ITensor* 8): 3e350553
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
GridAnchor_5: 3c2b37e3
(Unnamed ITensor* 76): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3c/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 522): 3d418f1e
(Unnamed ITensor* 39): 3da0973e
(Unnamed ITensor* 127): 3d418f1e
(Unnamed ITensor* 54): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4b/Branch_2/Conv2d_0b_3x3/Relu6: 3d418f1e
(Unnamed ITensor* 576): 3d418f1e
(Unnamed ITensor* 332): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Conv2d_2b_1x1/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_3b/Branch_1/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 47): 3d418f1e
(Unnamed ITensor* 40): 3d418f1e
(Unnamed ITensor* 246): 3d7bd2d9
FeatureExtractor/InceptionV2/InceptionV2/Conv2d_1a_7x7/Relu6: 3d418f1e
(Unnamed ITensor* 398): 3d418f1e
(Unnamed ITensor* 383): 3d418f1e
(Unnamed ITensor* 427): 3d541a3f
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
(Unnamed ITensor* 397): 3d523857
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5a/Branch_0/Conv2d_1a_3x3/Relu6: 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_0/Conv2d_0a_1x1/Relu6: 3d333265
(Unnamed ITensor* 442): 3d418f1e
(Unnamed ITensor* 470): 3d71a2ed
(Unnamed ITensor* 499): 3d2d4927
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5b/Branch_2/Conv2d_0c_3x3/Relu6: 3d3d75f1
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_1/Conv2d_0a_1x1/Relu6: 3d1d4f1e
(Unnamed ITensor* 434): 3d439787
(Unnamed ITensor* 629): 3d418f1e
(Unnamed ITensor* 506): 3d74b7dd
(Unnamed ITensor* 428): 3d418f1e
FeatureExtractor/InceptionV2/InceptionV2/Mixed_5c/Branch_2/Conv2d_0c_3x3/Relu6: 3d418f1e
GridAnchor_2: 3c2c4ae8
FeatureExtractor/InceptionV2/InceptionV2/Mixed_4a/Branch_0/Conv2d_0a_1x1/Relu6: 3d418f1e
NMS: 3da1a245
GridAnchor copy: 3a4f5b62
FeatureExtractor/InceptionV2/Mixed_5c_1_Conv2d_4_1x1_128/Relu6: 3d418f1e

LICENSE

deleted100644 → 0
+0 −21
Original line number Diff line number Diff line
MIT License

Copyright (c) 2019 Boris

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+8 −11
Original line number Diff line number Diff line
# tensorflow-feed-from-gpu

Simple TF test

## Setup in Eclipse

From **Eclipse (2019-12)**:
* File > Open Projects from File System...
* Directory... > navigate to project's root > Finish

Tried importing a few times - indexer does not work sometimes.
# Run

```
mkdir build
cd build
cmake ..
./tf-gpu-feed
```
 No newline at end of file
Loading