Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to run the simple example due to missing variable declartion inside Metric.h #9

Open
parajav opened this issue Mar 31, 2023 · 0 comments

Comments

@parajav
Copy link

parajav commented Mar 31, 2023

I have both the CUDA, cuda driver and cuDNN installed in my ubuntu system. Followed the instructions in c3sr/go-onnxruntime repo for installation

  • Successfully installed ONNXRUntime C++ API(built from src with cuda-- built and installed successfully)

  • nvidia-smi and nvcc --version works

  • can compile the acuda file and run from NVIDIA test example

  • g++ version and gcc version are same.

  • g++ (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0

  • gcc (Ubuntu 11.3.0-1ubuntu1~22.04) 11.3.0
    Example code that i run is this
    I am continuously getting this error below.
    Undefined variable"NVPA_RawMetricsConfigOptions" in Metric.h
    Am i missing something?
    ` $ go run main.go

    (github.com/c3sr/go-cupti)

In file included from utils.cpp:17:
../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Metric.h: In function ‘bool NV::Metric::Config::GetConfigImage(std::string, std::vector<std::__cxx11::basic_string >, std::vector&, const uint8_t*)’:
../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Metric.h:68:17: error: ‘NVPA_RawMetricsConfigOptions’ was not declared in this scope; did you mean ‘NVPA_RawMetricsConfig’?
68 | NVPA_RawMetricsConfigOptions metricsConfigOptions = { NVPA_RAW_METRICS_CONFIG_OPTIONS_STRUCT_SIZE };
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
| NVPA_RawMetricsConfig
../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Metric.h:69:17: error: ‘metricsConfigOptions’ was not declared in this scope
69 | metricsConfigOptions.activityKind = NVPA_ACTIVITY_KIND_PROFILER;
| ^~~~~~~~~~~~~~~~~~~~
In file included from ../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Metric.h:4,
from utils.cpp:17:
../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Metric.h:72:45: error: ‘NVPA_RawMetricsConfig_Create’ was not declared in this scope; did you mean ‘NVPW_CUDA_RawMetricsConfig_Create’?
72 | RETURN_IF_NVPW_ERROR(false, NVPA_RawMetricsConfig_Create(&metricsConfigOptions, &pRawMetricsConfig));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../go/pkg/mod/github.com/c3sr/go-cupti@v1.1.1/csrc/Utils.h:7:26: note: in definition of macro ‘RETURN_IF_NVPW_ERROR’
7 | NVPA_Status status = actual; `

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant