etaler / Etaler

A flexable HTM (Hierarchical Temporal Memory) framework with full GPU support.
BSD 3-Clause "New" or "Revised" License
89 stars 14 forks source link

compile with LayerVisualizer??? #110

Closed Thanh-Binh closed 4 years ago

Thanh-Binh commented 4 years ago

Hi Martin, I am trying now to test visualization, but not able to compile it because ImGui-members are not found. cmake .. -DETALER_ENABLE_OPENCL=ON -DETALER_BUILD_EXAMPLE_VISUALIZER=ON

I think, the 3rd party SW like LayerVisualization, Easy3D should not in examples-folder ... Thanks

######################### /tmp/ccfxlQ3V.ltrans0.ltrans.o::function easy3d::ViewerImGui::post_resize(int, int): error: undefined reference to 'ImGui::GetIO()' /tmp/ccfxlQ3V.ltrans0.ltrans.o::function easy3d::ViewerImGui::post_resize(int, int): error: undefined reference to 'ImGui::GetIO()' /tmp/ccfxlQ3V.ltrans0.ltrans.o::function easy3d::ViewerImGui::pre_draw(): error: undefined reference to 'ImGui_ImplOpenGL3_NewFrame()'

marty1885 commented 4 years ago

Hi, again thanks for reporting.

My you provide information about your environment? Compiler version, OS, etc... It'll help me diagnose the issue.

I think, the 3rd party SW like LayerVisualization, Easy3D should not in examples-folder ...

It doesn't. Easy3D is pulled in by alior101/LayersVisualizer. Which is a part of the visualization example.

Thanh-Binh commented 4 years ago

@marty1885 I use gcc 7.3.0, Ubuntu LTS18.04

about structure of your folder: Etaler/examples/visualize/LayersVisualizer Etaler/examples/visualize/LayersVisualizer/Easy3D/3rd_party/

I think LayersVisualizer should be in the same level as example folder, i.e. Etaler/LayersVisualizer

marty1885 commented 4 years ago

Sorry for the delayed reply. I was busy dealing conscription in my country.

Interesting. I organized 3rd party dependency by putting them into their own folder under where they are used. So the CMake script is easier to write and the dependency is clearer. The RNG and FP16 is thus put into Etaler/3rdparty to indicate they are used by the core library. And LayerVisualizer is under the visualize example (since it is used no where else) What would be the up side of putting all 3rd party SW in the project root?

Thanh-Binh commented 4 years ago

For me, ít ít nice if I can compile and can run it well

Thanh-Binh commented 4 years ago

I found the compile Problem is the missing of library „Imgui“ in CMakefile

marty1885 commented 4 years ago

I see the problem.

  1. The original source code was developed for a older version of Easy3D (And I didn't add a commit id for the dependency)
  2. imgui is missing from cmake

I'll make a PR for that

marty1885 commented 4 years ago

A patch in on the way. I'm ill right now... I'll push the PR in a few day.