Skip to content

Commit

Permalink
Change samples directory structure
Browse files Browse the repository at this point in the history
Signed-off-by: Rajeev Rao <[email protected]>
  • Loading branch information
kevinch-nv authored and rajeevsrao committed Aug 5, 2021
1 parent 0b65abf commit 8c1e9c6
Show file tree
Hide file tree
Showing 138 changed files with 75 additions and 91 deletions.
28 changes: 27 additions & 1 deletion samples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,30 @@

add_custom_target(samples)

add_subdirectory(opensource)
set(OPENSOURCE_SAMPLES_LIST
sampleAlgorithmSelector
sampleCharRNN
sampleDynamicReshape
sampleFasterRCNN
sampleGoogleNet
sampleINT8
sampleINT8API
sampleMLP
sampleMNIST
sampleMNISTAPI
sampleNMT
sampleOnnxMNIST
sampleReformatFreeIO
sampleSSD
sampleUffFasterRCNN
sampleUffMaskRCNN
sampleUffMNIST
sampleUffPluginV2Ext
sampleUffSSD
sampleOnnxMnistCoordConvAC
trtexec
)

foreach(SAMPLE_ITER ${OPENSOURCE_SAMPLES_LIST})
add_subdirectory(${SAMPLE_ITER})
endforeach(SAMPLE_ITER)
2 changes: 1 addition & 1 deletion samples/CMakeSamplesTemplate.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ set_ifndef(SAMPLE_PARSERS "none")

set(TARGET_DIR ${CMAKE_CURRENT_SOURCE_DIR})

get_filename_component(SAMPLES_DIR ../../ ABSOLUTE)
get_filename_component(SAMPLES_DIR ../ ABSOLUTE)
get_filename_component(SAMPLE_DIR_NAME ${TARGET_DIR} NAME)

set_ifndef(CUDA_INSTALL_DIR /usr/local/cuda)
Expand Down
42 changes: 21 additions & 21 deletions samples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,27 @@

| Sample | Language | Format | Description |
|---|---|---|---|
| [sampleAlgorithmSelector](opensource/sampleAlgorithmSelector) | C++ | Caffe | Algorithm Selection API usage |
| [sampleCharRNN](opensource/sampleCharRNN) | C++ | INetwork | Building An RNN Network Layer By Layer |
| [sampleDynamicReshape](opensource/sampleDynamicReshape) | C++ | ONNX | Digit Recognition With Dynamic Shapes In TensorRT |
| [sampleFasterRCNN](opensource/sampleFasterRCNN) | C++ | Caffe | Object Detection With Faster R-CNN |
| [sampleGoogleNet](opensource/sampleGoogleNet) | C++ | Caffe | Building And Running GoogleNet In TensorRT |
| [sampleINT8](opensource/sampleINT8) | C++ | Caffe | Building And Running GoogleNet In TensorRT |
| [sampleINT8API](opensource/sampleINT8API) | C++ | Caffe | Performing Inference In INT8 Precision |
| [sampleMLP](opensource/sampleMLP) | C++ | INetwork | “Hello World” For Multilayer Perceptron (MLP) |
| [sampleMNIST](opensource/sampleMNIST) | C++ | Caffe | “Hello World” For TensorRT |
| [sampleMNISTAPI](opensource/sampleMNISTAPI) | C++ | INetwork | Building a Simple MNIST Network Layer by Layer |
| [sampleNMT](opensource/sampleNMT) | C++ | INetwork | Neural Machine Translation Using A seq2seq Model |
| [sampleOnnxMNIST](opensource/sampleOnnxMNIST) | C++ | ONNX | “Hello World” For TensorRT With ONNX |
| [sampleOnnxMnistCoordConvAC](opensource/sampleOnnxMnistCoordConvAC) | C++ | ONNX | Implementing CoordConv with a custom plugin |
| [sampleReformatFreeIO](opensource/sampleReformatFreeIO) | C++ | Caffe | Specifying I/O Formats Via Reformat-Free-I/O API |
| [sampleSSD](opensource/sampleSSD) | C++ | Caffe | Object Detection With SSD |
| [sampleUffFasterRCNN](opensource/sampleUffFasterRCNN) | C++ | UFF | Object Detection With A TensorFlow FasterRCNN Network |
| [sampleUffMNIST](opensource/sampleUffMNIST) | C++ | UFF | Import A TensorFlow Model And Run Inference |
| [sampleUffMaskRCNN](opensource/sampleUffMaskRCNN) | C++ | UFF | Object Detection And Instance Segmentation With MasK R-CNN Network |
| [sampleUffPluginV2Ext](opensource/sampleUffPluginV2Ext) | C++ | UFF | Adding A Custom Layer That Supports INT8 I/O To Your Network |
| [sampleUffSSD](opensource/sampleUffSSD) | C++ | UFF | Object Detection With A TensorFlow SSD Network |
| [trtexec](opensource/trtexec) | C++ | All | TensorRT Command-Line Wrapper: trtexec |
| [sampleAlgorithmSelector](sampleAlgorithmSelector) | C++ | Caffe | Algorithm Selection API usage |
| [sampleCharRNN](sampleCharRNN) | C++ | INetwork | Building An RNN Network Layer By Layer |
| [sampleDynamicReshape](sampleDynamicReshape) | C++ | ONNX | Digit Recognition With Dynamic Shapes In TensorRT |
| [sampleFasterRCNN](sampleFasterRCNN) | C++ | Caffe | Object Detection With Faster R-CNN |
| [sampleGoogleNet](sampleGoogleNet) | C++ | Caffe | Building And Running GoogleNet In TensorRT |
| [sampleINT8](sampleINT8) | C++ | Caffe | Building And Running GoogleNet In TensorRT |
| [sampleINT8API](sampleINT8API) | C++ | Caffe | Performing Inference In INT8 Precision |
| [sampleMLP](sampleMLP) | C++ | INetwork | “Hello World” For Multilayer Perceptron (MLP) |
| [sampleMNIST](sampleMNIST) | C++ | Caffe | “Hello World” For TensorRT |
| [sampleMNISTAPI](sampleMNISTAPI) | C++ | INetwork | Building a Simple MNIST Network Layer by Layer |
| [sampleNMT](sampleNMT) | C++ | INetwork | Neural Machine Translation Using A seq2seq Model |
| [sampleOnnxMNIST](sampleOnnxMNIST) | C++ | ONNX | “Hello World” For TensorRT With ONNX |
| [sampleOnnxMnistCoordConvAC](sampleOnnxMnistCoordConvAC) | C++ | ONNX | Implementing CoordConv with a custom plugin |
| [sampleReformatFreeIO](sampleReformatFreeIO) | C++ | Caffe | Specifying I/O Formats Via Reformat-Free-I/O API |
| [sampleSSD](sampleSSD) | C++ | Caffe | Object Detection With SSD |
| [sampleUffFasterRCNN](sampleUffFasterRCNN) | C++ | UFF | Object Detection With A TensorFlow FasterRCNN Network |
| [sampleUffMNIST](sampleUffMNIST) | C++ | UFF | Import A TensorFlow Model And Run Inference |
| [sampleUffMaskRCNN](sampleUffMaskRCNN) | C++ | UFF | Object Detection And Instance Segmentation With MasK R-CNN Network |
| [sampleUffPluginV2Ext](sampleUffPluginV2Ext) | C++ | UFF | Adding A Custom Layer That Supports INT8 I/O To Your Network |
| [sampleUffSSD](sampleUffSSD) | C++ | UFF | Object Detection With A TensorFlow SSD Network |
| [trtexec](trtexec) | C++ | All | TensorRT Command-Line Wrapper: trtexec |
| [efficientdet](python/efficientdet) | Python | ONNX | EfficientDet Object Detection with TensorRT |
| [efficientnet](python/efficientnet) | Python | ONNX | EfficientNet V1 and V2 Classification with TensorRT |
| [end_to_end_tensorflow_mnist](python/end_to_end_tensorflow_mnist) | Python | UFF | “Hello World” For TensorRT Using TensorFlow |
Expand Down
42 changes: 0 additions & 42 deletions samples/opensource/CMakeLists.txt

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
#
SET(SAMPLE_SOURCES
sampleCharRNN.cpp
../../common/sampleEngines.cpp
../common/sampleEngines.cpp
)
# Required due to inclusion of sampleEnines.h
SET(SAMPLE_PARSERS "uff" "caffe" "onnx")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ SET(SAMPLE_SOURCES
sampleDynamicReshape.cpp
)
set(SAMPLE_PARSERS "onnx")
include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES
set(SAMPLE_PARSERS "caffe")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES
set(SAMPLE_PARSERS "caffe")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "onnx")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ set(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ SET(SAMPLE_SOURCES
sampleNMT.cpp
trtUtil.cpp
)
include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)

# define SAMPLE_NMT_DATA_SOURCES and SAMPLE_NMT_MODEL_SOURCES
set(SAMPLE_NMT_MODEL_SOURCES
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "onnx")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES
set(SAMPLE_PARSERS "onnx")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "caffe")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES
set(SAMPLE_PARSERS "caffe")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ SET(SAMPLE_SOURCES
set(SAMPLE_PARSERS "uff")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "uff")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ set(SAMPLE_SOURCES
set(SAMPLE_PARSERS "uff")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ SET(SAMPLE_SOURCES

set(SAMPLE_PARSERS "uff")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ set(SAMPLE_SOURCES
set(SAMPLE_PARSERS "uff")
set(PLUGINS_NEEDED ON)

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
# limitations under the License.
#
SET(SAMPLE_SOURCES
../../common/sampleEngines.cpp
../../common/sampleInference.cpp
../../common/sampleOptions.cpp
../../common/sampleReporting.cpp
../common/sampleEngines.cpp
../common/sampleInference.cpp
../common/sampleOptions.cpp
../common/sampleReporting.cpp
trtexec.cpp
)

set(SAMPLE_PARSERS "caffe" "uff" "onnx")

include(../../CMakeSamplesTemplate.txt)
include(../CMakeSamplesTemplate.txt)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 8c1e9c6

Please sign in to comment.