视觉SLAM十四讲 ch4 trajectoryError.cpp报错问题和解决_革Mean君的博客-程序员信息网

技术标签: slam  c++  ubuntu  ros  linux  

首先来看一下我的CMakelist文件:

cmake_minimum_required(VERSION 3.0)
project(trajectoryError)
# 在cmake脚本中,设置编译选项可以通过add_compile_options命令,也可以通过set命令修改CMAKE_CXX_FLAGS或CMAKE_C_FLAGS。
# add_compile_options(-std=c++11) # 这句话的意思是在make时让编译器(g++)自动添加C++11的性质 -> 设置编译选项

option(USE_UBUNTU_20 "Set to ON if you are using Ubuntu 20.04" ON)
find_package(Pangolin REQUIRED)
if(USE_UBUNTU_20)
    message("You are using Ubuntu 20.04, fmt::fmt will be linked")
    find_package(fmt REQUIRED)
    set(FMT_LIBRARIES fmt::fmt)
endif()
include_directories(${Pangolin_INCLUDE_DIRS})
add_executable(trajectoryError trajectoryError.cpp)
target_link_libraries(trajectoryError ${FMT_LIBRARIES})
target_link_libraries(trajectoryError ${Pangolin_LIBRARIES})

set(CMAKE_BUILD_TYPE "Release")
set(Sophus_LIBRARIES  "/usr/local/lib/libSophus.so")
find_package(Sophus REQUIRED)
include_directories( ${Sophus_INCLUDE_DIRS} )
target_link_libraries(trajectoryError ${Sophus_LIBRARIES})

修改了cmakelist文件可以解决大部分的由于库链接出现问题所导致的报错。
然后再看一下代码的需要修改的地方:
请添加图片描述
请添加图片描述
我们需要把头文件对应起来,原来的头文件需要与安装在本地(sophus支持带模板的,可以选择不安装)的文件名字对应,具体是后缀为.h还是.hpp需要根据自己的电脑对应起来。
修改完之后大部分的错误可以解决了。
请添加图片描述
请添加图片描述
如果cmake时遇到了这样的错误的话:

[ 50%] Building CXX object CMakeFiles/trajectoryError.dir/trajectoryError.cpp.o
In file included from /usr/local/include/pangolin/utils/signal_slot.h:3,
                 from /usr/local/include/pangolin/windowing/window.h:35,
                 from /usr/local/include/pangolin/display/display.h:34,
                 from /usr/local/include/pangolin/pangolin.h:38,
                 from /home/hbt/文档/slambook2/ch4/example/trajectoryError.cpp:4:
/usr/local/include/sigslot/signal.hpp:109:79: error: ‘decay_t’ is not a member of ‘std’; did you mean ‘decay’?
  109 | constexpr bool is_weak_ptr_compatible_v = detail::is_weak_ptr_compatible<std::decay_t<P>>::value;
      |                                                                               ^~~~~~~
      |                                                                               decay
/usr/local/include/sigslot/signal.hpp:109:79: error: ‘decay_t’ is not a member of ‘std’; did you mean ‘decay’?
  109 | constexpr bool is_weak_ptr_compatible_v = detail::is_weak_ptr_compatible<std::decay_t<P>>::value;
      |                                                                               ^~~~~~~
      |                                                                               decay
/usr/local/include/sigslot/signal.hpp:109:87: error: template argument 1 is invalid
  109 | constexpr bool is_weak_ptr_compatible_v = detail::is_weak_ptr_compatible<std::decay_t<P>>::value;
      |                                                                                       ^
/usr/local/include/sigslot/signal.hpp:109:92: error: ‘::value’ has not been declared
  109 | constexpr bool is_weak_ptr_compatible_v = detail::is_weak_ptr_compatible<std::decay_t<P>>::value;
      |                                                                                            ^~~~~
/usr/local/include/sigslot/signal.hpp:132:53: error: ‘remove_pointer_t’ is not a member of ‘std’; did you mean ‘remove_pointer’?
  132 |                                                std::remove_pointer_t<T>>::value;
      |                                                     ^~~~~~~~~~~~~~~~
      |                                                     remove_pointer
/usr/local/include/sigslot/signal.hpp:132:53: error: ‘remove_pointer_t’ is not a member of ‘std’; did you mean ‘remove_pointer’?
  132 |                                                std::remove_pointer_t<T>>::value;
      |                                                     ^~~~~~~~~~~~~~~~
      |                                                     remove_pointer
/usr/local/include/sigslot/signal.hpp:132:70: error: template argument 2 is invalid
  132 |                                                std::remove_pointer_t<T>>::value;
      |                                                                      ^
/usr/local/include/sigslot/signal.hpp:132:75: error: ‘::value’ has not been declared
  132 |                                                std::remove_pointer_t<T>>::value;
      |                                                                           ^~~~~
/usr/local/include/sigslot/signal.hpp:223:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  223 | struct function_traits<T, std::enable_if_t<trait::is_func_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:223:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  223 | struct function_traits<T, std::enable_if_t<trait::is_func_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:223:62: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::function_traits’
  223 | struct function_traits<T, std::enable_if_t<trait::is_func_v<T>>> {
      |                                                              ^~
/usr/local/include/sigslot/signal.hpp:223:62: note:   expected a type, got ‘(<expression error> < is_func_v<T>)’
/usr/local/include/sigslot/signal.hpp:223:64: error: expected unqualified-id before ‘>’ token
  223 | struct function_traits<T, std::enable_if_t<trait::is_func_v<T>>> {
      |                                                                ^
/usr/local/include/sigslot/signal.hpp:233:33: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  233 | struct function_traits<T*, std::enable_if_t<trait::is_func_v<T>>> {
      |                                 ^~~~~~~~~~~
      |                                 enable_if
/usr/local/include/sigslot/signal.hpp:233:33: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  233 | struct function_traits<T*, std::enable_if_t<trait::is_func_v<T>>> {
      |                                 ^~~~~~~~~~~
      |                                 enable_if
/usr/local/include/sigslot/signal.hpp:233:63: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::function_traits’
  233 | struct function_traits<T*, std::enable_if_t<trait::is_func_v<T>>> {
      |                                                               ^~
/usr/local/include/sigslot/signal.hpp:233:63: note:   expected a type, got ‘(<expression error> < is_func_v<T>)’
/usr/local/include/sigslot/signal.hpp:233:65: error: expected unqualified-id before ‘>’ token
  233 | struct function_traits<T*, std::enable_if_t<trait::is_func_v<T>>> {
      |                                                                 ^
/usr/local/include/sigslot/signal.hpp:243:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  243 | struct function_traits<T, std::enable_if_t<trait::is_pmf_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:243:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  243 | struct function_traits<T, std::enable_if_t<trait::is_pmf_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:243:61: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::function_traits’
  243 | struct function_traits<T, std::enable_if_t<trait::is_pmf_v<T>>> {
      |                                                             ^~
/usr/local/include/sigslot/signal.hpp:243:61: note:   expected a type, got ‘(<expression error> < is_pmf_v<T>)’
/usr/local/include/sigslot/signal.hpp:243:63: error: expected unqualified-id before ‘>’ token
  243 | struct function_traits<T, std::enable_if_t<trait::is_pmf_v<T>>> {
      |                                                               ^
/usr/local/include/sigslot/signal.hpp:254:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  254 | struct function_traits<T, std::enable_if_t<trait::has_call_operator_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:254:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  254 | struct function_traits<T, std::enable_if_t<trait::has_call_operator_v<T>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:254:72: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::function_traits’
  254 | struct function_traits<T, std::enable_if_t<trait::has_call_operator_v<T>>> {
      |                                                                        ^~
/usr/local/include/sigslot/signal.hpp:254:72: note:   expected a type, got ‘(<expression error> < has_call_operator_v<T>)’
/usr/local/include/sigslot/signal.hpp:254:74: error: expected unqualified-id before ‘>’ token
  254 | struct function_traits<T, std::enable_if_t<trait::has_call_operator_v<T>>> {
      |                                                                          ^
/usr/local/include/sigslot/signal.hpp: In function ‘sigslot::detail::func_ptr sigslot::detail::get_function_ptr(const T&)’:
/usr/local/include/sigslot/signal.hpp:269:26: error: ‘decay_t’ is not a member of ‘std’; did you mean ‘decay’?
  269 |     function_traits<std::decay_t<T>>::ptr(t, d);
      |                          ^~~~~~~
      |                          decay
/usr/local/include/sigslot/signal.hpp:269:26: error: ‘decay_t’ is not a member of ‘std’; did you mean ‘decay’?
  269 |     function_traits<std::decay_t<T>>::ptr(t, d);
      |                          ^~~~~~~
      |                          decay
/usr/local/include/sigslot/signal.hpp:269:34: error: template argument 1 is invalid
  269 |     function_traits<std::decay_t<T>>::ptr(t, d);
      |                                  ^
/usr/local/include/sigslot/signal.hpp:269:35: error: expected unqualified-id before ‘>’ token
  269 |     function_traits<std::decay_t<T>>::ptr(t, d);
      |                                   ^~
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:291:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  291 | struct object_pointer<T*, std::enable_if_t<trait::is_pointer_v<T*>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:291:32: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  291 | struct object_pointer<T*, std::enable_if_t<trait::is_pointer_v<T*>>> {
      |                                ^~~~~~~~~~~
      |                                enable_if
/usr/local/include/sigslot/signal.hpp:291:66: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::object_pointer’
  291 | struct object_pointer<T*, std::enable_if_t<trait::is_pointer_v<T*>>> {
      |                                                                  ^~
/usr/local/include/sigslot/signal.hpp:291:66: note:   expected a type, got ‘(<expression error> < is_pointer_v<T*>)’
/usr/local/include/sigslot/signal.hpp:291:68: error: expected unqualified-id before ‘>’ token
  291 | struct object_pointer<T*, std::enable_if_t<trait::is_pointer_v<T*>>> {
      |                                                                    ^
/usr/local/include/sigslot/signal.hpp:298:31: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  298 | struct object_pointer<T, std::enable_if_t<trait::is_weak_ptr_v<T>>> {
      |                               ^~~~~~~~~~~
      |                               enable_if
/usr/local/include/sigslot/signal.hpp:298:31: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  298 | struct object_pointer<T, std::enable_if_t<trait::is_weak_ptr_v<T>>> {
      |                               ^~~~~~~~~~~
      |                               enable_if
/usr/local/include/sigslot/signal.hpp:298:65: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::object_pointer’
  298 | struct object_pointer<T, std::enable_if_t<trait::is_weak_ptr_v<T>>> {
      |                                                                 ^~
/usr/local/include/sigslot/signal.hpp:298:65: note:   expected a type, got ‘(<expression error> < is_weak_ptr_v<T>)’
/usr/local/include/sigslot/signal.hpp:298:67: error: expected unqualified-id before ‘>’ token
  298 | struct object_pointer<T, std::enable_if_t<trait::is_weak_ptr_v<T>>> {
      |                                                                   ^
/usr/local/include/sigslot/signal.hpp:306:31: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  306 | struct object_pointer<T, std::enable_if_t<!trait::is_pointer_v<T> &&
      |                               ^~~~~~~~~~~
      |                               enable_if
/usr/local/include/sigslot/signal.hpp:306:31: error: ‘enable_if_t’ is not a member of ‘std’; did you mean ‘enable_if’?
  306 | struct object_pointer<T, std::enable_if_t<!trait::is_pointer_v<T> &&
      |                               ^~~~~~~~~~~
      |                               enable_if
/usr/local/include/sigslot/signal.hpp:308:76: error: type/value mismatch at argument 2 in template parameter list for ‘template<class T, class> struct sigslot::detail::object_pointer’
  308 |                                           trait::is_weak_ptr_compatible_v<T>>>
      |                                                                            ^~
/usr/local/include/sigslot/signal.hpp:308:76: note:   expected a type, got ‘(((<expression error> < (! is_pointer_v<T>)) && (! is_weak_ptr_v<T>)) && is_weak_ptr_compatible_v<T>)’
/usr/local/include/sigslot/signal.hpp:308:78: error: expected unqualified-id before ‘>’ token
  308 |                                           trait::is_weak_ptr_compatible_v<T>>>
      |                                                                              ^
/usr/local/include/sigslot/signal.hpp:398:41: error: ‘std::enable_if_t’ has not been declared
  398 |     explicit copy_on_write(U && x, std::enable_if_t<!std::is_same<std::decay_t<U>,
      |                                         ^~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp:398:52: error: expected ‘,’ or ‘...’ before ‘<’ token
  398 |     explicit copy_on_write(U && x, std::enable_if_t<!std::is_same<std::decay_t<U>,
      |                                                    ^
/usr/local/include/sigslot/signal.hpp:532:5: error: ‘index’ function uses ‘auto’ type specifier without trailing return type
  532 |     auto index() const {
      |     ^~~~
/usr/local/include/sigslot/signal.hpp:532:5: note: deduced return type only available with ‘-std=c++14’ or ‘-std=gnu++14’
/usr/local/include/sigslot/signal.hpp:536:5: error: ‘index’ function uses ‘auto’ type specifier without trailing return type
  536 |     auto& index() {
      |     ^~~~
/usr/local/include/sigslot/signal.hpp:536:5: note: deduced return type only available with ‘-std=c++14’ or ‘-std=gnu++14’
/usr/local/include/sigslot/signal.hpp:793:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
  793 |     std::enable_if_t<function_traits<C>::must_check_object, bool>
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:799:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
  799 |     std::enable_if_t<!function_traits<C>::must_check_object, bool>
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:876:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  876 |     std::decay_t<Func> func;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot<Func, Args>::slot(sigslot::detail::cleanable&, F&&, Gid)’:
/usr/local/include/sigslot/signal.hpp:858:11: error: class ‘sigslot::detail::slot<Func, Args>’ does not have any field named ‘func’
  858 |         , func{std::forward<F>(f)} {}
      |           ^~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot<Func, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:866:33: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
  866 |         return get_function_ptr(func);
      |                                 ^~~~
      |                                 Func
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot<Func, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:871:23: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
  871 |         return typeid(func);
      |                       ^~~~
      |                       Func
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:908:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  908 |     std::decay_t<Func> func;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot_extended<Func, Args>::slot_extended(sigslot::detail::cleanable&, F&&, sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:888:11: error: class ‘sigslot::detail::slot_extended<Func, Args>’ does not have any field named ‘func’
  888 |         , func{std::forward<F>(f)} {}
      |           ^~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot_extended<Func, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:898:33: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
  898 |         return get_function_ptr(func);
      |                                 ^~~~
      |                                 Func
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot_extended<Func, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:903:23: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
  903 |         return typeid(func);
      |                       ^~~~
      |                       Func
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:945:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  945 |     std::decay_t<Pmf> pmf;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp:946:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  946 |     std::decay_t<Ptr> ptr;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot_pmf<Pmf, Ptr, Args>::slot_pmf(sigslot::detail::cleanable&, F&&, P&&, sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:922:11: error: class ‘sigslot::detail::slot_pmf<Pmf, Ptr, Args>’ does not have any field named ‘pmf’
  922 |         , pmf{std::forward<F>(f)}
      |           ^~~
/usr/local/include/sigslot/signal.hpp:923:11: error: class ‘sigslot::detail::slot_pmf<Pmf, Ptr, Args>’ does not have any field named ‘ptr’
  923 |         , ptr{std::forward<P>(p)} {}
      |           ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::detail::slot_pmf<Pmf, Ptr, Args>::call_slot(Args ...)’:
/usr/local/include/sigslot/signal.hpp:927:12: error: ‘ptr’ was not declared in this scope; did you mean ‘Ptr’?
  927 |         ((*ptr).*pmf)(args...);
      |            ^~~
      |            Ptr
/usr/local/include/sigslot/signal.hpp:927:18: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  927 |         ((*ptr).*pmf)(args...);
      |                  ^~~
      |                  Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot_pmf<Pmf, Ptr, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:931:33: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  931 |         return get_function_ptr(pmf);
      |                                 ^~~
      |                                 Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘const void* sigslot::detail::slot_pmf<Pmf, Ptr, Args>::get_object() const’:
/usr/local/include/sigslot/signal.hpp:935:31: error: ‘ptr’ was not declared in this scope; did you mean ‘Ptr’?
  935 |         return get_object_ptr(ptr);
      |                               ^~~
      |                               Ptr
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot_pmf<Pmf, Ptr, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:940:23: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  940 |         return typeid(pmf);
      |                       ^~~
      |                       Pmf
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:982:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  982 |     std::decay_t<Pmf> pmf;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp:983:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
  983 |     std::decay_t<Ptr> ptr;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>::slot_pmf_extended(sigslot::detail::cleanable&, F&&, P&&, sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:958:11: error: class ‘sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>’ does not have any field named ‘pmf’
  958 |         , pmf{std::forward<F>(f)}
      |           ^~~
/usr/local/include/sigslot/signal.hpp:959:11: error: class ‘sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>’ does not have any field named ‘ptr’
  959 |         , ptr{std::forward<P>(p)} {}
      |           ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>::call_slot(Args ...)’:
/usr/local/include/sigslot/signal.hpp:965:12: error: ‘ptr’ was not declared in this scope; did you mean ‘Ptr’?
  965 |         ((*ptr).*pmf)(conn, args...);
      |            ^~~
      |            Ptr
/usr/local/include/sigslot/signal.hpp:965:18: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  965 |         ((*ptr).*pmf)(conn, args...);
      |                  ^~~
      |                  Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:969:33: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  969 |         return get_function_ptr(pmf);
      |                                 ^~~
      |                                 Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘const void* sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>::get_object() const’:
/usr/local/include/sigslot/signal.hpp:972:31: error: ‘ptr’ was not declared in this scope; did you mean ‘Ptr’?
  972 |         return get_object_ptr(ptr);
      |                               ^~~
      |                               Ptr
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot_pmf_extended<Pmf, Ptr, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:977:23: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
  977 |         return typeid(pmf);
      |                       ^~~
      |                       Pmf
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:1032:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
 1032 |     std::decay_t<Func> func;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp:1033:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
 1033 |     std::decay_t<WeakPtr> ptr;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot_tracked<Func, WeakPtr, Args>::slot_tracked(sigslot::detail::cleanable&, F&&, P&&, sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:997:11: error: class ‘sigslot::detail::slot_tracked<Func, WeakPtr, Args>’ does not have any field named ‘func’
  997 |         , func{std::forward<F>(f)}
      |           ^~~~
/usr/local/include/sigslot/signal.hpp:998:11: error: class ‘sigslot::detail::slot_tracked<Func, WeakPtr, Args>’ does not have any field named ‘ptr’
  998 |         , ptr{std::forward<P>(p)}
      |           ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘bool sigslot::detail::slot_tracked<Func, WeakPtr, Args>::connected() const’:
/usr/local/include/sigslot/signal.hpp:1002:17: error: ‘ptr’ was not declared in this scope
 1002 |         return !ptr.expired() && slot_state::connected();
      |                 ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::detail::slot_tracked<Func, WeakPtr, Args>::call_slot(Args ...)’:
/usr/local/include/sigslot/signal.hpp:1007:19: error: ‘ptr’ was not declared in this scope
 1007 |         auto sp = ptr.lock();
      |                   ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot_tracked<Func, WeakPtr, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:1018:33: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
 1018 |         return get_function_ptr(func);
      |                                 ^~~~
      |                                 Func
/usr/local/include/sigslot/signal.hpp: In member function ‘const void* sigslot::detail::slot_tracked<Func, WeakPtr, Args>::get_object() const’:
/usr/local/include/sigslot/signal.hpp:1022:31: error: ‘ptr’ was not declared in this scope
 1022 |         return get_object_ptr(ptr);
      |                               ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot_tracked<Func, WeakPtr, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:1027:23: error: ‘func’ was not declared in this scope; did you mean ‘Func’?
 1027 |         return typeid(func);
      |                       ^~~~
      |                       Func
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:1082:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
 1082 |     std::decay_t<Pmf> pmf;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp:1083:10: error: ‘decay_t’ in namespace ‘std’ does not name a template type; did you mean ‘decay’?
 1083 |     std::decay_t<WeakPtr> ptr;
      |          ^~~~~~~
      |          decay
/usr/local/include/sigslot/signal.hpp: In constructor ‘constexpr sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::slot_pmf_tracked(sigslot::detail::cleanable&, F&&, P&&, sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:1047:11: error: class ‘sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>’ does not have any field named ‘pmf’
 1047 |         , pmf{std::forward<F>(f)}
      |           ^~~
/usr/local/include/sigslot/signal.hpp:1048:11: error: class ‘sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>’ does not have any field named ‘ptr’
 1048 |         , ptr{std::forward<P>(p)}
      |           ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘bool sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::connected() const’:
/usr/local/include/sigslot/signal.hpp:1052:17: error: ‘ptr’ was not declared in this scope
 1052 |         return !ptr.expired() && slot_state::connected();
      |                 ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::call_slot(Args ...)’:
/usr/local/include/sigslot/signal.hpp:1057:19: error: ‘ptr’ was not declared in this scope
 1057 |         auto sp = ptr.lock();
      |                   ^~~
/usr/local/include/sigslot/signal.hpp:1063:21: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
 1063 |             ((*sp).*pmf)(args...);
      |                     ^~~
      |                     Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::detail::func_ptr sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::get_callable() const’:
/usr/local/include/sigslot/signal.hpp:1068:33: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
 1068 |         return get_function_ptr(pmf);
      |                                 ^~~
      |                                 Pmf
/usr/local/include/sigslot/signal.hpp: In member function ‘const void* sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::get_object() const’:
/usr/local/include/sigslot/signal.hpp:1072:31: error: ‘ptr’ was not declared in this scope
 1072 |         return get_object_ptr(ptr);
      |                               ^~~
/usr/local/include/sigslot/signal.hpp: In member function ‘const std::type_info& sigslot::detail::slot_pmf_tracked<Pmf, WeakPtr, Args>::get_callable_type() const’:
/usr/local/include/sigslot/signal.hpp:1077:23: error: ‘pmf’ was not declared in this scope; did you mean ‘Pmf’?
 1077 |         return typeid(pmf);
      |                       ^~~
      |                       Pmf
/usr/local/include/sigslot/signal.hpp: At global scope:
/usr/local/include/sigslot/signal.hpp:1115:27: error: ‘conditional_t’ in namespace ‘std’ does not name a template type; did you mean ‘conditional’?
 1115 |     using cow_type = std::conditional_t<is_thread_safe<L>::value,
      |                           ^~~~~~~~~~~~~
      |                           conditional
/usr/local/include/sigslot/signal.hpp:1119:32: error: ‘conditional_t’ in namespace ‘std’ does not name a template type; did you mean ‘conditional’?
 1119 |     using cow_copy_type = std::conditional_t<is_thread_safe<L>::value,
      |                                ^~~~~~~~~~~~~
      |                                conditional
/usr/local/include/sigslot/signal.hpp:1201:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1201 |     std::enable_if_t<trait::is_callable_v<arg_list, Callable>, connection>
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1221:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1221 |     std::enable_if_t<trait::is_callable_v<ext_arg_list, Callable>, connection>
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1241:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1241 |     std::enable_if_t<trait::is_callable_v<arg_list, Pmf, Ptr> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1261:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1261 |     std::enable_if_t<trait::is_callable_v<arg_list, Pmf, Ptr> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1281:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1281 |     std::enable_if_t<trait::is_callable_v<ext_arg_list, Pmf, Ptr> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1310:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1310 |     std::enable_if_t<!trait::is_callable_v<arg_list, Pmf> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1340:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1340 |     std::enable_if_t<trait::is_callable_v<arg_list, Callable> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1376:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1376 |     std::enable_if_t<(trait::is_callable_v<arg_list, Callable> ||
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1399:10: error: ‘enable_if_t’ in namespace ‘std’ does not name a template type; did you mean ‘enable_if’?
 1399 |     std::enable_if_t<!trait::is_callable_v<arg_list, Obj> &&
      |          ^~~~~~~~~~~
      |          enable_if
/usr/local/include/sigslot/signal.hpp:1522:12: error: ‘cow_copy_type’ does not name a type
 1522 |     inline cow_copy_type<list_type, Lockable> slots_reference() {
      |            ^~~~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp:1529:12: error: ‘make_slot’ function uses ‘auto’ type specifier without trailing return type
 1529 |     inline auto make_slot(A && ...a) {
      |            ^~~~
/usr/local/include/sigslot/signal.hpp:1529:12: note: deduced return type only available with ‘-std=c++14’ or ‘-std=gnu++14’
/usr/local/include/sigslot/signal.hpp:1589:5: error: ‘cow_type’ does not name a type; did you mean ‘lock_type’?
 1589 |     cow_type<list_type, Lockable> m_slots;
      |     ^~~~~~~~
      |     lock_type
/usr/local/include/sigslot/signal.hpp: In constructor ‘sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::signal_base(sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >&&)’:
/usr/local/include/sigslot/signal.hpp:1146:14: error: ‘m_slots’ was not declared in this scope
 1146 |         swap(m_slots, o.m_slots);
      |              ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >& sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::operator=(sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >&&)’:
/usr/local/include/sigslot/signal.hpp:1155:14: error: ‘m_slots’ was not declared in this scope
 1155 |         swap(m_slots, o.m_slots);
      |              ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::operator()(U&& ...)’:
/usr/local/include/sigslot/signal.hpp:1180:9: error: ‘cow_copy_type’ was not declared in this scope
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |         ^~~~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp:1180:32: error: expected primary-expression before ‘,’ token
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                ^
/usr/local/include/sigslot/signal.hpp:1180:42: error: expected primary-expression before ‘>’ token
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                          ^
/usr/local/include/sigslot/signal.hpp:1180:44: error: ‘ref’ was not declared in this scope; did you mean ‘std::ref’?
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                            ^~~
      |                                            std::ref
In file included from /usr/include/c++/9/functional:58,
                 from /usr/local/include/pangolin/utils/type_convert.h:33,
                 from /usr/local/include/pangolin/utils/params.h:31,
                 from /usr/local/include/pangolin/display/display.h:33,
                 from /usr/local/include/pangolin/pangolin.h:38,
                 from /home/hbt/文档/slambook2/ch4/example/trajectoryError.cpp:4:
/usr/include/c++/9/bits/refwrap.h:370:5: note: ‘std::ref’ declared here
  370 |     ref(reference_wrapper<_Tp> __t) noexcept
      |     ^~~
In file included from /usr/local/include/pangolin/utils/signal_slot.h:3,
                 from /usr/local/include/pangolin/windowing/window.h:35,
                 from /usr/local/include/pangolin/display/display.h:34,
                 from /usr/local/include/pangolin/pangolin.h:38,
                 from /home/hbt/文档/slambook2/ch4/example/trajectoryError.cpp:4:
/usr/local/include/sigslot/signal.hpp:1180:50: error: there are no arguments to ‘slots_reference’ that depend on a template parameter, so a declaration of ‘slots_reference’ must be available [-fpermissive]
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                                  ^~~~~~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp:1180:50: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
/usr/local/include/sigslot/signal.hpp: In member function ‘size_t sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::disconnect(const Callable&, const Obj&)’:
/usr/local/include/sigslot/signal.hpp:1423:41: error: use of ‘auto’ in lambda parameter declaration only available with ‘-std=c++14’ or ‘-std=gnu++14’
 1423 |         return disconnect_if([&] (const auto &s) {
      |                                         ^~~~
/usr/local/include/sigslot/signal.hpp: In lambda function:
/usr/local/include/sigslot/signal.hpp:1424:21: error: base operand of ‘->’ is not a pointer
 1424 |             return s->has_object(obj) && s->has_callable(c);
      |                     ^~
/usr/local/include/sigslot/signal.hpp:1424:43: error: base operand of ‘->’ is not a pointer
 1424 |             return s->has_object(obj) && s->has_callable(c);
      |                                           ^~
/usr/local/include/sigslot/signal.hpp: In member function ‘size_t sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::disconnect(sigslot::group_id)’:
/usr/local/include/sigslot/signal.hpp:1439:46: error: ‘m_slots’ was not declared in this scope
 1439 |         for (auto &group : detail::cow_write(m_slots)) {
      |                                              ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘size_t sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::slot_count()’:
/usr/local/include/sigslot/signal.hpp:1486:9: error: ‘cow_copy_type’ was not declared in this scope
 1486 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |         ^~~~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp:1486:32: error: expected primary-expression before ‘,’ token
 1486 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                ^
/usr/local/include/sigslot/signal.hpp:1486:42: error: expected primary-expression before ‘>’ token
 1486 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                          ^
/usr/local/include/sigslot/signal.hpp:1486:44: error: ‘ref’ was not declared in this scope; did you mean ‘std::ref’?
 1486 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                            ^~~
      |                                            std::ref
In file included from /usr/include/c++/9/functional:58,
                 from /usr/local/include/pangolin/utils/type_convert.h:33,
                 from /usr/local/include/pangolin/utils/params.h:31,
                 from /usr/local/include/pangolin/display/display.h:33,
                 from /usr/local/include/pangolin/pangolin.h:38,
                 from /home/hbt/文档/slambook2/ch4/example/trajectoryError.cpp:4:
/usr/include/c++/9/bits/refwrap.h:370:5: note: ‘std::ref’ declared here
  370 |     ref(reference_wrapper<_Tp> __t) noexcept
      |     ^~~
In file included from /usr/local/include/pangolin/utils/signal_slot.h:3,
                 from /usr/local/include/pangolin/windowing/window.h:35,
                 from /usr/local/include/pangolin/display/display.h:34,
                 from /usr/local/include/pangolin/pangolin.h:38,
                 from /home/hbt/文档/slambook2/ch4/example/trajectoryError.cpp:4:
/usr/local/include/sigslot/signal.hpp:1486:50: error: there are no arguments to ‘slots_reference’ that depend on a template parameter, so a declaration of ‘slots_reference’ must be available [-fpermissive]
 1486 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                                  ^~~~~~~~~~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::clean(sigslot::detail::slot_state*)’:
/usr/local/include/sigslot/signal.hpp:1504:46: error: ‘m_slots’ was not declared in this scope
 1504 |         for (auto &group : detail::cow_write(m_slots)) {
      |                                              ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::add_slot(sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::slot_ptr&&)’:
/usr/local/include/sigslot/signal.hpp:1538:42: error: ‘m_slots’ was not declared in this scope
 1538 |         auto &groups = detail::cow_write(m_slots);
      |                                          ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘size_t sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::disconnect_if(Cond&&)’:
/usr/local/include/sigslot/signal.hpp:1560:42: error: ‘m_slots’ was not declared in this scope
 1560 |         auto &groups = detail::cow_write(m_slots);
      |                                          ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In member function ‘void sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::clear()’:
/usr/local/include/sigslot/signal.hpp:1584:27: error: ‘m_slots’ was not declared in this scope
 1584 |         detail::cow_write(m_slots).clear();
      |                           ^~~~~~~
/usr/local/include/sigslot/signal.hpp: In instantiation of ‘void sigslot::signal_base< <template-parameter-1-1>, <template-parameter-1-2> >::operator()(U&& ...) [with U = {pangolin::VarState::Event}; Lockable = std::mutex; T = {pangolin::VarState::Event}]’:
/usr/local/include/pangolin/var/varstate.h:264:23:   required from ‘std::map<std::__cxx11::basic_string<char>, std::shared_ptr<pangolin::VarValueGeneric> >::iterator pangolin::VarState::AddUpgradedVar(const std::shared_ptr<pangolin::VarValue<T> >&, const iterator&, bool) [with T = bool; std::map<std::__cxx11::basic_string<char>, std::shared_ptr<pangolin::VarValueGeneric> >::iterator = std::_Rb_tree_iterator<std::pair<const std::__cxx11::basic_string<char>, std::shared_ptr<pangolin::VarValueGeneric> > >]’
/usr/local/include/pangolin/var/varstate.h:205:13:   required from ‘std::shared_ptr<pangolin::VarValueGeneric> pangolin::VarState::GetOrCreateVar(const T&, const pangolin::VarMeta&) [with T = bool]’
/usr/local/include/pangolin/var/var.h:83:50:   required from ‘pangolin::Var<T>::Var(const T&, const pangolin::VarMeta&) [with T = bool]’
/usr/local/include/pangolin/var/var.h:88:35:   required from ‘pangolin::Var<T>::Var(const string&, const T&) [with T = bool; std::string = std::__cxx11::basic_string<char>]’
/usr/local/include/pangolin/display/widgets.h:153:50:   required from here
/usr/local/include/sigslot/signal.hpp:1180:65: error: ‘slots_reference’ was not declared in this scope
 1180 |         cow_copy_type<list_type, Lockable> ref = slots_reference();
      |                                                  ~~~~~~~~~~~~~~~^~
make[2]: *** [CMakeFiles/trajectoryError.dir/build.make:63:CMakeFiles/trajectoryError.dir/trajectoryError.cpp.o] 错误 1
make[1]: *** [CMakeFiles/Makefile2:76:CMakeFiles/trajectoryError.dir/all] 错误 2
make: *** [Makefile:84:all] 错误 2

大部分的原因就是CMakelist文件没有把库链接进来,所以只需要修改cmakelist文件为文章开头那样即可。
然后运行效果如图:
请添加图片描述
参考文章:
《视觉SLAM十四讲》第二版源码slambook2编译调试
[cmake:设置编译选项的讲究(add_compile_options和CMAKE_CXX_FLAGS的区别) 转自CSDN](https://blog.csdn.net/bianchengjingling22/article/details/88794329?ops_request_misc=&request_id=&biz_id=102&utm_term=add_compile_options(-std=c++11&utm_medium=distribute.pc_search_result.none-task-blog-2allsobaiduweb~default-0-88794329.first_rank_v2_pc_rank_v29&spm=1018.2226.3001.4187)
(.text.startup+0x102):对‘Sophus::SO3::operator*(Sophus::SO3 const&) const’未定义的引用

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/m0_53683803/article/details/123063029

智能推荐

opencv3_java 提取图像的RGB三原色分割图像Split Core.split_橘子派的博客-程序员信息网

提取图像的RGB三原色分割图像Split Core.splitpackage opencv_java_demo;import java.util.List;import org.opencv.core.*;import org.opencv.imgcodecs.*;public class Split { public static void main(String[

连接LDAP服务器用户,使用 LDAP 服务器进行连接_Reinhardt Jin的博客-程序员信息网

使用 LDAP 服务器进行连接如果使用的是 Windows(Windows Mobile 除外)或 Unix 平台,则可以指定一个中央 LDAP 服务器来跟踪企业中的所有数据库服务器。如果数据库服务器在 LDAP 服务器中自行注册,客户端便可以查询 LDAP 服务器,找到其要查找的数据库服务器,无论这些服务器是在WAN、LAN 上还是位于防火墙的后面。客户端不需要指定 IP 地址 (HOST=)。...

知识图谱入门视频(二)_追赶早晨的博客-程序员信息网_dbpedia怎么读

学习内容小象学院 b站 第二章第二部 典型知识库项目简介CYC(读音: 赛克)CYC: 1984年由Douglas Lenat开始创建,最初的目标是建立人类最大的常识知识库。该知识库主要由术语Terms和断言Assertions组成。Cyc的主要特点是基于形式化的知识表示方法来刻画知识。形式化的优势是可以支持复杂的推理。但过于形式化也导致知识库的扩展性和应用的灵活性不够。Cyc提供开放版本的OpenCycWordnetWordNet是最著名的词典(lexical)知识库,

Oracle发布Oracle数据库的官方Node.js驱动node-oracledb_weixin_34362875的博客-程序员信息网

node-oracledb是一个Oracle数据库的Node.js驱动,由Oracle官方基于Apache License V2.0开源协议发布和维护,其代码托管在GitHub上。Oracle官方声称能够支持高性能的Node.js应用。目前该驱动的最新版本是0.2预览版。目前,开发团队还在不断完善相关功能。\\Node-oracledb 0.2预览版已实现了所支持的基本和高级的Oracle特性,具...

Mybatis in 条件传参三种实现方法(直接$,List,[])_wh445306的博客-程序员信息网_mybatis中in传参数

第一种方法:in 条件为拼接好的字符串 如果直接传入拼接好的where in 条件, 比如('111','222','333'),则需要使用${idlist}传参,即绝对引用,而不能使用# 如果使用#传参会被mybatis当成字符串再添加一层''引号,导致错误,优点:简单方便,高效,缺点:不能防止SQL注入第二种方法:in 条件为List对象 in条件直接传入List对象,让mybatis再去拼接生成in条件,这个很麻烦,但是可以防止SQL注入第三种方法:in 条件为Strin...

你不知道这份超详细JVM内存结构?成功拿下大厂offer_普通网友的博客-程序员信息网

前言在学习Java基础的过程中,泛型绝对算得上是一个比较难理解的知识点,尤其对于初学者而言,而且就算是已经有基础的Java程序员,可能对泛型的理解也不是那么透彻,属于那种看了明白,时间长了就忘的那种,究其根本,还是对泛型不够理解。大部分人对泛型的认识:“基础知识,但是比较模糊”为什么要用多线程任何一项技术的出现都是为了解决现有问题。之前的互联网大多是单机服务,体量小;而现在的更多是集群服务,同一时刻有多个用户同时访问服务器,那么会有很多线程并发访问。比如在电商系统里,同一时刻比如整点抢购时,大量

随便推点

PHP利用Java+JasperReport生成PDF快递单_Lazy_Sleep的博客-程序员信息网

文章目录一、前言二、方案选择三、开发需要的四、.....一、前言系统主要使用PHP作为开发语言,有一个需求是实时生成快递面单并且以PDF格式保存。多种方案的实现都不理想,最后选择使用Java生成PDF,然后PHP再调用Java得到PDF。记录解决方案二、方案选择  一开始使用Html编写快递面单样式,运行时修改为实际数据后再转为PDF。但是写Html过于麻烦,生成的PDF与网页显示的有偏差...

pkg_resources.resources.filename(manager,resource_name)函数_One Bird的博客-程序员信息网_pkg-resources

pkg_resources.resources.filename(manager,resource_name)函数先看官方文档介绍吧:大致意思就是返回packge里file的绝对路径,get_resource_filename(manager, resource_name)Return a true filesystem path for resource_name, coordinating the extraction with manager, if the resource must be u

C#上位机设计项目实战——02 汉字GB2312转码器_YU___________的博客-程序员信息网_c# gb2312

汉字GB2312转码器辅助以后单片机和12864oled的设计。注意点:汉字 转UTF-8 再转化为 GB2312 //字符转编码 private byte[] StringToBytes(string TheString) //utf8编码转GB2132编码 { Encoding FromEcoding = Encoding.GetEncoding("UTF-8"); //UTF8编码

org.mozilla.javascript.EcmaError: TypeError: Cannot read property &quot;value&quot; from null_翱翔天地的博客-程序员信息网

1、错误描述version: 2017-09-14 16:13:04packageinfo: Branch_SmartbiV702_20170818 Java查询对象类错误 at smartbi.freequery.querydata.store.DBSQLResultStore.executeInJavaQuery(DBSQLResultStore.java:1924) at ......

c语言ik,C语言入门 - osc_xgq4n4ik的个人空间 - OSCHINA - 中文开源技术交流社区_彭英韬的博客-程序员信息网

学完java和py再学这个感觉真的是不爽,前面的还好,基本都直接上手了,但是还是记录一下吧,毕竟学不会得挂科呀hello#include int main(){printf("hello,world");return 0;}一、变量定义变量定义的形式一般就是: 类型名称 变量名称int price;int amount;int price,amount#include int main(){pri...

推荐文章

热门文章

相关标签