• <xmp id="om0om">
  • <table id="om0om"><noscript id="om0om"></noscript></table>
  • Compute Graph Framework SDK Reference  5.22
    All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
    dwLidarPointCloudStitcherNode.hpp
    Go to the documentation of this file.
    1
    2//
    3// Notice
    4// ALL NVIDIA DESIGN SPECIFICATIONS AND CODE ("MATERIALS") ARE PROVIDED "AS IS" NVIDIA MAKES
    5// NO REPRESENTATIONS, WARRANTIES, EXPRESSED, IMPLIED, STATUTORY, OR OTHERWISE WITH RESPECT TO
    6// THE MATERIALS, AND EXPRESSLY DISCLAIMS ANY IMPLIED WARRANTIES OF NONINFRINGEMENT,
    7// MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
    8//
    9// NVIDIA CORPORATION & AFFILIATES assumes no responsibility for the consequences of use of such
    10// information or for any infringement of patents or other rights of third parties that may
    11// result from its use. No license is granted by implication or otherwise under any patent
    12// or patent rights of NVIDIA CORPORATION & AFFILIATES. No third party distribution is allowed unless
    13// expressly authorized by NVIDIA. Details are subject to change without notice.
    14// This code supersedes and replaces all information previously supplied.
    15// NVIDIA CORPORATION & AFFILIATES products are not authorized for use as critical
    16// components in life support devices or systems without express written approval of
    17// NVIDIA CORPORATION & AFFILIATES.
    18//
    19// SPDX-FileCopyrightText: Copyright (c) 2020-2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
    20// SPDX-License-Identifier: LicenseRef-NvidiaProprietary
    21//
    22// NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
    23// property and proprietary rights in and to this material, related
    24// documentation and any modifications thereto. Any use, reproduction,
    25// disclosure or distribution of this material and related documentation
    26// without an express license agreement from NVIDIA CORPORATION or
    27// its affiliates is strictly prohibited.
    28//
    30
    31#ifndef DWFRAMEWORK_DWNODES_DWLIDARPOINTCLOUDSTITCHERNODE_DWLIDARPOINTCLOUDSTITCHERNODE_HPP_
    32#define DWFRAMEWORK_DWNODES_DWLIDARPOINTCLOUDSTITCHERNODE_DWLIDARPOINTCLOUDSTITCHERNODE_HPP_
    33
    34#include <dw/pointcloudprocessing/stitcher/PointCloudStitcher.h>
    35#include <dwcgf/node/Node.hpp>
    39#include <dwcgf/port/Port.hpp>
    41#include <dwframework/dwnodes/common/PointCloudProcessingCommonTypes.hpp>
    42#include <dwframework/dwnodes/common/channelpackets/EgomotionState.hpp>
    43#include <dwframework/dwnodes/common/channelpackets/PointCloud.hpp>
    44#include <dwframework/dwnodes/common/channelpackets/LidarPointCloud.hpp>
    45#include <dwframework/dwnodes/common/channelpackets/SensorCommonTypes.hpp>
    46
    47namespace dw
    48{
    49namespace framework
    50{
    51
    53{
    54 bool enabledLidar[MAX_LIDAR_STITCHER_PORT_NUM];
    55 dwLidarProperties lidarProperties[MAX_LIDAR_STITCHER_PORT_NUM];
    56 dwTransformation3f lidar2RigDefault[MAX_LIDAR_STITCHER_PORT_NUM];
    57 dwMemoryType memoryType;
    58 dwPointCloudFormat outputFormat;
    59
    60 cudaStream_t stream;
    61};
    62
    63template <>
    64struct EnumDescription<dwPointCloudFormat>
    65{
    67 {
    68 return describeEnumeratorCollection<dwPointCloudFormat>(
    69 DW_DESCRIBE_C_ENUMERATOR(DW_POINTCLOUD_FORMAT_XYZI),
    70 DW_DESCRIBE_C_ENUMERATOR(DW_POINTCLOUD_FORMAT_RTHI));
    71 }
    72};
    73
    74template <>
    75struct EnumDescription<dwMemoryType>
    76{
    78 {
    79 return describeEnumeratorCollection<dwMemoryType>(
    80 DW_DESCRIBE_C_ENUMERATOR(DW_MEMORY_TYPE_CUDA),
    81 DW_DESCRIBE_C_ENUMERATOR(DW_MEMORY_TYPE_CPU),
    82 DW_DESCRIBE_C_ENUMERATOR(DW_MEMORY_TYPE_PINNED));
    83 }
    84};
    85
    90{
    91public:
    92 // TODO(csketch): FP -- This is used when the logger is called and not just at assignment.
    93 // coverity[autosar_cpp14_a0_1_1_violation] FP: nvbugs/2980283
    94 // coverity[autosar_cpp14_m0_1_4_violation] FP: nvbugs/2980283
    95 static constexpr char8_t LOG_TAG[]{"dwLidarPointCloudStitcherNode"};
    96
    97 // coverity[autosar_cpp14_a7_1_5_violation] RFD Accepted: TID-2201
    98 static constexpr auto describeInputPorts()
    99 {
    100 using namespace dw::framework;
    101 // TODO(csketch): RFD -- user defined literal being interpreted as c style cast.
    102 // coverity[autosar_cpp14_a5_2_2_violation] RFD Pending: TID-1983
    104 DW_DESCRIBE_PORT_ARRAY(dwLidarPointCloud, MAX_LIDAR_STITCHER_PORT_NUM, "LIDAR_POINT_CLOUD_COMPENSATED"_sv),
    105 DW_DESCRIBE_PORT_ARRAY(dwSensorNodeProperties, MAX_LIDAR_STITCHER_PORT_NUM, "LIDAR_EXTRINSICS"_sv),
    106 DW_DESCRIBE_PORT(dwEgomotionStateHandle_t, "EGOMOTION_STATE"_sv));
    107 };
    108
    109 // coverity[autosar_cpp14_a7_1_5_violation] RFD Accepted: TID-2201
    110 static constexpr auto describeOutputPorts()
    111 {
    112 using namespace dw::framework;
    113 // TODO(csketch): RFD -- user defined literal being interpreted as c style cast.
    114 // coverity[autosar_cpp14_a5_2_2_violation] RFD Pending: TID-1983
    116 DW_DESCRIBE_PORT(dwLidarPointCloud, "LIDAR_POINT_CLOUD_COMPENSATED_AGGREGATE"_sv, PortBinding::REQUIRED),
    117 DW_DESCRIBE_PORT(dwTime_t, "TARGET_TIMESTAMP"_sv, PortBinding::OPTIONAL));
    118 };
    119
    120 // coverity[autosar_cpp14_a7_1_5_violation] RFD Accepted: TID-2201
    121 static constexpr auto describePasses()
    122 {
    124 describePass(StringView{"SETUP"}, DW_PROCESSOR_TYPE_CPU),
    125 describePass(StringView{"PROCESS_GPU"}, DW_PROCESSOR_TYPE_GPU),
    126 describePass(StringView{"PROCESS_CPU"}, DW_PROCESSOR_TYPE_CPU),
    127 describePass(StringView{"TEARDOWN"}, DW_PROCESSOR_TYPE_CPU));
    128 };
    129
    130 static std::unique_ptr<dwLidarPointCloudStitcherNode> create(ParameterProvider& provider);
    131
    132 // coverity[autosar_cpp14_a7_1_5_violation] RFD Accepted: TID-2201
    133 static constexpr auto describeParameters()
    134 {
    135 // TODO(csketch): RFD -- user defined literal being interpreted as c style cast.
    136 // coverity[autosar_cpp14_a5_2_2_violation] RFD Pending: TID-1983
    138 describeConstructorArgument<dwLidarPointCloudStitcherNodeParams>(
    140 bool,
    142 MAX_LIDAR_STITCHER_PORT_NUM,
    145 dwLidarProperties,
    146 MAX_LIDAR_STITCHER_PORT_NUM,
    149 dwTransformation3f,
    151 MAX_LIDAR_STITCHER_PORT_NUM,
    154 dwMemoryType,
    155 "memoryType"_sv,
    158 dwPointCloudFormat,
    159 "outputFormat"_sv,
    162 cudaStream_t,
    163 "stream"_sv,
    165 describeConstructorArgument<dwContextHandle_t>(
    167 dwContextHandle_t)));
    168 }
    169
    171 dwContextHandle_t ctx);
    172};
    173}
    174}
    175
    176#endif // DWFRAMEWORK_DWNODES_DWLIDARPOINTCLOUDSTITCHERNODE_DWLIDARPOINTCLOUDSTITCHERNODE_HPP_
    #define DW_DESCRIBE_C_ENUMERATOR(NAME)
    Syntactic sugar calling describeEnumerator().
    #define DW_DESCRIBE_INDEX_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_UNNAMED_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_UNNAMED_ARRAY_PARAMETER_WITH_SEMANTIC(TYPE_NAME, SEMANTIC_TYPE_NAME, ARRAY_SIZE, args...)
    #define DW_DESCRIBE_UNNAMED_ARRAY_PARAMETER(TYPE_NAME, ARRAY_SIZE, args...)
    #define DW_DESCRIBE_PARAMETER(TYPE_NAME, args...)
    #define DW_DESCRIBE_PORT(TYPE_NAME, NAME, args...)
    #define DW_DESCRIBE_PORT_ARRAY(TYPE_NAME, ARRAYSIZE, NAME, args...)
    The interface to access parameter values identified by name and/or (semantic) type.
    dwLidarPointCloudStitcherNode(const dwLidarPointCloudStitcherNodeParams &, dwContextHandle_t ctx)
    static std::unique_ptr< dwLidarPointCloudStitcherNode > create(ParameterProvider &provider)
    dwLidarProperties lidarProperties[MAX_LIDAR_STITCHER_PORT_NUM]
    constexpr std::tuple describeConstructorArguments()
    dwTransformation3f lidar2RigDefault[MAX_LIDAR_STITCHER_PORT_NUM]
    constexpr PassDescriptorT< 0 > describePass(dw::core::StringView &&name, dwProcessorType processorType)
    constexpr auto describePassCollection(const Args &&... args) -> std::tuple< Args... >
    constexpr auto describePortCollection(Args &&... args) -> dw::core::Tuple< Args... >
    std::array< std::pair< dw::core::StringView, EnumT >, NumberOfEnumerators > EnumDescriptionReturnType
    Definition: Buffer.hpp:41
    static constexpr EnumDescriptionReturnType< dwMemoryType, 3 > get()
    static constexpr EnumDescriptionReturnType< dwPointCloudFormat, 2 > get()
    人人超碰97caoporen国产