Tag Archives: debug

SSL_ERROR_SYSCALL in connection to github.com:443

Project scenario:

Mac uses git push or hexo deploy to push GitHub

Problem Description:

Bug contains

LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443

Cause analysis:

Because the agent is attached locally, you can clone
but when pushing, you need to attach the agent to the terminal


Solution:

vim ~/.gitconfig

View the port of the native agent and replace the following XXXX

[http]
	proxy = socks5://127.0.0.1:xxxx
[https]
	proxy = socks5://127.0.0.1:xxxx

You can also push by turning off the agent and accessing it normally

onnx-tensorrt/builtin_op_importers.cpp:766:12: error: ‘class nvinfer1::IDeconvolutionLayer’ has no m

When compiling the onnxruntime source code, an error is reported:

/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:766:12: error: ‘class nvinfer1::IDeconvolutionLayer’ has no member named ‘setDilationNd’
     layer->setDilationNd(dilations);
            ^~~~~~~~~~~~~
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp: In function ‘onnx2trt::NodeImportResult onnx2trt::{anonymous}::importGemm(onnx2trt::IImporterContext*, const onnx::NodeProto&, std::vector<onnx2trt::TensorOrWeights>&)’:
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:1250:18: error: ‘class nvinfer1::IShuffleLayer’ has no member named ‘setZeroIsPlaceholder’
         squeeze->setZeroIsPlaceholder(false);
                  ^~~~~~~~~~~~~~~~~~~~
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp: In function ‘onnx2trt::NodeImportResult onnx2trt::{anonymous}::importGRU(onnx2trt::IImporterContext*, const onnx::NodeProto&, std::vector<onnx2trt::TensorOrWeights>&)’:
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:1536:20: error: ‘class nvinfer1::IShuffleLayer’ has no member named ‘setZeroIsPlaceholder’
         unsqueeze->setZeroIsPlaceholder(false);
                    ^~~~~~~~~~~~~~~~~~~~
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp: In function ‘onnx2trt::NodeImportResult onnx2trt::{anonymous}::importLSTM(onnx2trt::IImporterContext*, const onnx::NodeProto&, std::vector<onnx2trt::TensorOrWeights>&)’:
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:2051:22: error: ‘class nvinfer1::IShuffleLayer’ has no member named ‘setZeroIsPlaceholder’
         reshapeBias->setZeroIsPlaceholder(false);
                      ^~~~~~~~~~~~~~~~~~~~
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp: In function ‘onnx2trt::NodeImportResult onnx2trt::{anonymous}::importRNN(onnx2trt::IImporterContext*, const onnx::NodeProto&, std::vector<onnx2trt::TensorOrWeights>&)’:
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:3202:22: error: ‘class nvinfer1::IShuffleLayer’ has no member named ‘setZeroIsPlaceholder’
         reshapeBias->setZeroIsPlaceholder(false);
                      ^~~~~~~~~~~~~~~~~~~~
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp: In function ‘onnx2trt::NodeImportResult onnx2trt::{anonymous}::importTRT_Shuffle(onnx2trt::IImporterContext*, const onnx::NodeProto&, std::vector<onnx2trt::TensorOrWeights>&)’:
/home/zxq/cxx/onnxruntime/cmake/external/onnx-tensorrt/builtin_op_importers.cpp:4219:12: error: ‘class nvinfer1::IShuffleLayer’ has no member named ‘setZeroIsPlaceholder’
     layer->setZeroIsPlaceholder(zeroIsPlaceholder);
            ^~~~~~~~~~~~~~~~~~~~
external/onnx-tensorrt/CMakeFiles/nvonnxparser_static.dir/build.make:103: recipe for target 'external/onnx-tensorrt/CMakeFiles/nvonnxparser_static.dir/builtin_op_importers.cpp.o' failed
make[2]: *** [external/onnx-tensorrt/CMakeFiles/nvonnxparser_static.dir/builtin_op_importers.cpp.o] Error 1
CMakeFiles/Makefile2:2581: recipe for target 'external/onnx-tensorrt/CMakeFiles/nvonnxparser_static.dir/all' failed
make[1]: *** [external/onnx-tensorrt/CMakeFiles/nvonnxparser_static.dir/all] Error 2
Makefile:165: recipe for target 'all' failed
make: *** [all] Error 2
Traceback (most recent call last):
  File "/home/zxq/cxx/onnxruntime/tools/ci_build/build.py", line 1986, in <module>
    sys.exit(main())
  File "/home/zxq/cxx/onnxruntime/tools/ci_build/build.py", line 1921, in main
    build_targets(args, cmake_path, build_dir, configs, num_parallel_jobs, args.target)
  File "/home/zxq/cxx/onnxruntime/tools/ci_build/build.py", line 1007, in build_targets
    run_subprocess(cmd_args, env=env)
  File "/home/zxq/cxx/onnxruntime/tools/ci_build/build.py", line 528, in run_subprocess
    return run(*args, cwd=cwd, capture_stdout=capture_stdout, shell=shell, env=my_env)
  File "/home/zxq/cxx/onnxruntime/tools/python/util/run.py", line 41, in run
    completed_process = subprocess.run(
  File "/home/zxq/anaconda3/lib/python3.8/subprocess.py", line 512, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['/usr/local/bin/cmake', '--build', '/home/zxq/cxx/onnxruntime/build/Linux/Release', '--config', 'Release']' returned non-zero exit status 2.

reason:

From the error message, we can see that it is related to the third-party package external/onnx tensorrt of oonnxruntime, and then we can see that

Onnx runtime – rel-1.7.2 is the third-party package onnx tensorrt. This package depends on tensorrt version 7.2.2, but I installed 7.0.0, which is too low.

The reason why I installed 7.0.0 is that I installed CUDA 10.0 before, and CUDA 10.0 supports tensorrt 7.0.0 at most.

terms of settlement:

(1) Download the appropriate version of onnxruntime again. The download is too slow and the time cost is too high.

(2) Update CUDA 11.0, CUDA 11.0 can support the latest tensorrt 7.2.3, re install CUDA and tensorrt reference tutorial.

 

Clion breakpoint not triggered debugging no response to solve the problem

When using clion to debug C + + code, there is no response when debugging after adding breakpoints, and breakpoints are not triggered. After checking some materials, we found that there was a problem. When compiling, we need to set the debug mode in cmakelists. The solution is to add the following code to cmakelists:

set(CMAKE_BUILD_TYPE Debug)

When recompiling and debugging, breakpoints can be triggered normally.

Solution to the problem of spring boot running test class error creating bean with name ‘serverendpoint exporter’ defined

There are many problems in spring boot unit test. When I use websocket, I will run the test class and report an error: error creating bean with name ‘serverendpoint exporter’ defined in class path resource [COM/Jacklin/config]/ WebSocketConfig.class ]Here I introduce the annotation @ serverendpoint:

There are two ways to solve this problem

Method 1: remove the @ runwith of the test class( SpringRunner.class ), but this method will have limitations. For example, when you want a @ authwired class below, you will report an error. I can’t do it here, according to your code situation.

The second way: add webenvironment after springboottest= SpringBootTest.WebEnvironment.RANDOM_ Port means to create a web application context (response based or servlet based). Reason: websocket depends on the startup of Tomcat and other containers. So in the process of testing, we need to really start a Tomcat as a container.

Run after adding, no more error!!

Keyerror: “year not in index”

During learning, when writing Python code, the following error was reported: “keyerror” [‘year ‘] not in index “.

Problem description

When learning data visualization, the pandas package is called, and the code runs with an error. The error prompt is as follows

KeyError: "['year'] not in index"

Key error: ‘[‘year’] is not in index ‘

problem analysis

Check the code and find that the front and the back are inconsistent, and there are some problems when you write your own code

Solution
delete “1” and solve the problem

OK, keep learning.

[error handling] idea error reporting com.alibaba.druid . pool.DruidDataSource error

Screenshot of error reporting part:

version at the time of error reporting:

jdk1.8   
mysql 8.0.17  
idea2018.3.6 
mysql-connector-java-5.1.37-bin.jar
1.0.9Druid

Error reason:
when an error is reported, the MySQL driver is 5, but the MySQL version is 8, which does not match

Solution:
after changing the MySQL driver to 8.0.16,
then com.mysql.jdbc . driver to com.mysql.cj . jdbc.Driver ,
add after Druid configuration

filters=stat
timeBetweenEvictionRunsMillis=60000
minEvictableIdleTimeMillis=300000
validationQuery=SELECT 1
testWhileIdle=true
testOnBorrow=false
testOnReturn=false
poolPreparedStatements=false
maxPoolPreparedStatementPerConnectionSize=200

Problem solving.

PS: if you have a similar problem, you can communicate with qq2287015934.

There is a problem of DLL when executing G + + compile command in sublime text editor

Sublime Text sets GCC and g++ (g++ is a superset of GCC, so just g++), most commonly the Mingw folder in dev-cpp.
The problem is as follows:
contains the source file for the input function, which can be compiled in Devc, and a popup window in the sublime text environment shows that the file entry cannot be found and the program input point __gxx_personality_v0 cannot be located in the dynamic link library.

Dynamic Link Library problem caused by DLL files.
Return to the Mingw file where the environment variable was imported and copy the libstdc++6.dll from the lib file.

br>

(Suggestions)
② Paste into the directory where the source file is located.
If there are mistakes, please correct them.

Opencv: the application can’t start normally

Compiling environment:
Operating system: Win8.1 64-bit
IDE Platform: Visual Studio 2013 Ultimate

Today on opening the.exe file generated by VS: The application cannot start properly 0xc000007b solution
It seems that the configured x86 OpenCV file may not run under x64 system (I am not sure whether this is the reason, because I have been doing this before without any problems).
Finally, it is possible to run the generated executable with the following method:
(1) Change x86 in the previously configured OpenCV path to x64
Debug:
1. Project ->; Configure properties ->; Conventional – & gt; Use of MFC: Use MFC in static libraries.
2. Project ->; Configure properties ->; C/C++-> Code generation ->; Runtime: Select multithreaded debugging (/MT).
3. When compiling, select Release, x64
Release:

1. Project ->; Configure properties ->; Conventional – & gt; Use of MFC: Use MFC in static libraries
2. Project ->; Configure properties ->; C/C++-> Code generation ->; Runtime: Select multi-threaded debugging (/ MTD).
3. When compiling, select Debug and Win32