Code Monkey home page Code Monkey logo

ocpkg's Introduction

OpenCog

CircleCI

This repo is no longer maintained! Please use the following, instead:

Obsolete! As of 2021, the most interesting and actively maintained parts of this git repo have been split off into their own distinct git repos. What is left here is a mish-mash of unmatained stuff that is in the process of bit-rotting. Some unit tests fail. Some unit tests won't run. Some code won't compile. Perhaps there's some good stuff in here. Perhaps it can be brought back to life and used for something or other. However... for the most part, it is obsolete.


This git repository contains the "OpenCog Framework", which has served as a (scientific, technical) laboratory for researching, exploring and learning how to integrate AI algorithms and systems into humanoid robotic systems. Most of the activity within this particular repo has focused on integrating natural language chat, common-sense reasoning, assorted learning algorithms, and motor control of humanoid robots.

A stated goal of the OpenCog project is to develop artificial general intelligence (AGI) systems. This is all and well; however, what can be found here, in this particular repo, is very far from that. The code here really is ... a laboratory for integrating various types of AI systems. As such, it is a compilation of several decades of work by a large and varying collection of students, researchers, professors and software engineers. As a laboratory, it is filled with all sorts of devices in varying states of working order, from well-polished to mostly-broken.

See also:

  • ROCCA - Rational OpenCog Controlled Agent. This is a different assemblage of assorted OpenCog components, so that they operate within Minecraft, in the OpenAI Gym. The focus is on learning with the pattern miner, and reasoning with PLN.

Overview

Most of the basic components used in OpenCog are distributed across various git repos, (mostly) grouped under https://github.com/opencog

This git repository contains a crude natural language processing pipeline, several embodied chatbots, and some control/action-selection mechanisms. These include:

  • Ghost, a Chatscript-compatible chatbot with additional capabilities for accepting visual sensory input, and for controlling robot movements.

  • OpenPsi, a model of psychological states. Its currently a mashup of two unrelated ideas: a generic rule-class action-selection and planning system, and a model of human psychological states. An open to-do item is to untangle these two.

  • An assortment of natural language processing subsystems, including:

    • Natural language generation (for expressing thoughts as sentences).
    • Natural language input (for reading and hearing).
    • Relex2logic, converting natural language to logic expressions.
    • Assorted chatbots, some of which are embodied.
    • A Lojban tool.

Prerequisites

To build and run the system here, the packages listed below are required. Users of Ubuntu may use the dependency installer from the /opencog/octool repository. Docker containers with OpenCog preconfigured can be found in the opencog/docker repo.

cogutil

Common OpenCog C++ utilities. https://github.com/opencog/cogutil It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

atomspace

OpenCog Atomspace, a sophisticated (hyper-)graph database. https://github.com/opencog/atomspace It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

cogserver

OpenCog CogServer Network Server. https://github.com/opencog/cogserver It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

attention

OpenCog Attention Allocation subsystem. https://github.com/opencog/attention It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

URE

OpenCog Unified Rule Engine. https://github.com/opencog/ure Required for PLN It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

pln

OpenCog Probabilistic Logic Networks reasoning system. https://github.com/opencog/pln It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

spacetime

OpenCog Spacetime Server - locations of objects in space and time. https://github.com/opencog/spacetime It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

ros-behavior-scripting

Visual and auditory senses, robot motor control. https://github.com/opencog/ros-behavior-scripting It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

lg-atomese

Natural Language Parser for English, Russian, other languages. Required for natural language generation, and the chatbot. https://github.com/opencog/lg-atomese It uses exactly the same build procedure as this package. Be sure to sudo make install at the end.

Building OpenCog

Perform the following steps at the shell prompt:

    cd to project root dir
    mkdir build
    cd build
    cmake ..
    make

Libraries will be built into subdirectories within build, mirroring the structure of the source directory root.

Unit tests

To build and run the unit tests, from the ./build directory enter (after building opencog as above):

    make test

ocpkg's People

Contributors

amberj avatar amebel avatar amoudgl avatar dagiopia avatar dancard avatar edguy3 avatar ehabnoreddin avatar elggem avatar frankg avatar githart avatar kidist-abraham avatar linas avatar marcospividori avatar ngeiswei avatar rtreutlein avatar tensae21 avatar vsbogd avatar wenwei-dev avatar yantrabuddhi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ocpkg's Issues

Trying to build opencog, getting error /usr/bin/ld: cannot find -lserver

Hi,

I'm trying to do an initial build of opencog on a new docker system.

I have tried both using cmake and using the ocpkg. The error happens immediately if I do ./octool -i, it happens midway through the build if I try and make opencog or if I do ./octool -b. In all 3 cases I am getting an error like this:

Any help on what dependency is needed for lserver would be greatly appreciated.

make[2]: Entering directory /home/opencog/opencog/build' [ 40%] Building CXX object opencog/attention/CMakeFiles/attention.dir/AttentionModule.cc.o [ 40%] Building CXX object opencog/attention/CMakeFiles/attention.dir/ForgettingAgent.cc.o [ 41%] Building CXX object opencog/attention/CMakeFiles/attention.dir/HebbianUpdatingAgent.cc.o [ 43%] Building CXX object opencog/attention/CMakeFiles/attention.dir/SimpleHebbianUpdatingAgent.cc.o [ 43%] Building CXX object opencog/attention/CMakeFiles/attention.dir/ImportanceSpreadingAgent.cc.o [ 45%] Building CXX object opencog/attention/CMakeFiles/attention.dir/ImportanceDiffusionAgent.cc.o [ 45%] Building CXX object opencog/attention/CMakeFiles/attention.dir/SimpleImportanceDiffusionAgent.cc.o [ 46%] Building CXX object opencog/attention/CMakeFiles/attention.dir/ImportanceUpdatingAgent.cc.o Linking CXX shared library libattention.so /usr/bin/ld: cannot find -lserver collect2: error: ld returned 1 exit status make[2]: *** [opencog/attention/libattention.so] Error 1 make[2]: Leaving directory/home/opencog/opencog/build'
make[1]: *** [opencog/attention/CMakeFiles/attention.dir/all] Error 2
make[1]: Leaving directory /home/opencog/opencog/build' make: *** [all] Error 2 make: Leaving directory/home/opencog/opencog/build'

missing octo dependencies in ocpkg for ubuntu 16.04

this may have been fixed with last ocpkg edit but when i ran ./octool -i it installed ros-lunar-octomap package and i had to install liboctomap-dev with dependency liboctomap1.6v5 to get cmake/make to build Spatial and SpaceTime. and then the associated unit tests fail:

	  2 - AtomSpacePublisherModuleUTest (OTHER_FAULT)
	 17 - AtomOcTreeUTest (SEGFAULT)
	 18 - TimeSpaceAtomUTest (SEGFAULT)
	 19 - AnaphoraTest (Failed)
	 22 - ChatlangUTest (Failed)
	 23 - MOSESPLNSynergyUTest (Failed)
	 31 - CythonSpatial (Failed)
	 32 - CythonSpacetime (SEGFAULT)
	 37 - PatternMinerUTest (Failed)
Errors while running CTest

what is the correct dependency?

octool workflow issues

can octool do a git clone of the repos instead of downloading a tar.gz of master ? this way you could then have octool update with git pull in each repo.

-w option should be more explicit , in that it says it will download data sets for use with opencog not the opencog data set , you can get confused into thinking this would download the opencog repo?

what is libjson-spirit-dev needed for?

Ubuntu xenial doesn't have it. As best as I can tell, its not needed for anything, but I am not quite sure ...

I suspect that this is a left-over from the old embodiment code ... but maybe its also used elsewhere, e.g by ZMQ?

OCaml integration broken.

As of today, there is an incompatibility between OCaml and ocpkg -rdpcav -l default.

In consequence, any ubuntu 22 system with ocaml installed from apt will fail to cooperate with ocpkg -rdpcav -l default. A workaround I use is to perform the invocation in an lxc container, as follows:

lxd init
lxc launch images:ubuntu/jammy/default opencog --vm -c limits.memory=4GiB
lxc exec opencog bash
passwd ubuntu
[enter password]
[Ctrl-D]
lxc console opencog
[enter username ubuntu and password]
apt install git
git clone https://github.com/opencog/ocpkg.git
cd ocpkg
./ocpkg -rdpcav -l default

This should unfold and build fine. But as ocaml is not installed, it is not detected, and the problem is bypassed. When ocaml is already installed as an ubuntu package, we get the following error:

[ 55%] Building CXX object opencog/ocaml/CMakeFiles/camlatoms.dir/CamlWrap.cc.o
/tmp/atomspace-master/opencog/ocaml/CamlWrap.cc:25:10: fatal error: caml/alloc.h: No such file or directory
   25 | #include <caml/alloc.h>
      |          ^~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/ocaml/CMakeFiles/camlatoms.dir/build.make:92: opencog/ocaml/CMakeFiles/camlatoms.dir/CamlWrap.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:4089: opencog/ocaml/CMakeFiles/camlatoms.dir/all] Error 2

Need newer version of guile

Currently, ocpkg calls for guile-1.8.8 to be installed; its probably time to move to guile-2.0.5 or newer (guile 2.0 is now 4 years old, and should be widely available; version 2.0.5 is what's on ubuntu precise 12.04 LTS)

Anyway, I'd recently fixed some UTF-8 bugs in one of the nlp scirpts, which requires rnrs which is provided by:

guile-2.0-libs: /usr/share/guile/2.0/rnrs

rnrs implements the r5rs and r6rs scheme standards. It doesn't exist in guile-1.8

ocpkg is missing a dependency for Flask or Flask-RESTful

@githart:
Buildbot skips the unit test for the Python REST API because there is a dependency missing on the machine:

Failure: SkipTest (ImportError exception: make sure the required dependencies are installed.) ... SKIP: ImportError exception: make sure the required dependencies are installed.

(you can search for that string in the logfile)

That means that ocpkg doesn't install all the required dependencies. Can you help add the missing dependency? It seems that it must be either Flask or Flask-RESTful:
https://github.com/opencog/opencog/blob/master/opencog/python/web/api/apimain.py#L3

You could check which one is missing:

sudo apt-get install python-pip
pip freeze

The unit test passes successfully locally. It would be helpful to have it pass on the Buildbot so that we can validate that new users who set up an environment using ocpkg will have all tests pass successfully.

fatal error: opencog/nlp/types/atom_types.h: No such file or directory

Hi , i am installing opencog into ubuntu , and i have installed every single dependencies , on last step while running these commands i am getting following error

Commands:
cd opencog
mkdir build
cd build
cmake ..
make -j6

Error :
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/EdgeThin.cc:12:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:63: opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeThin.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/root/OPENCOG/opencog/opencog/nlp/wsd/MihalceaEdge.cc:24:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
24 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:102: opencog/nlp/wsd/CMakeFiles/wsd.dir/MihalceaEdge.cc.o] Error 1
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/EdgeUtils.cc:10:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:76: opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeUtils.cc.o] Error 1
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/MihalceaLabel.cc:21:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/root/OPENCOG/opencog/opencog/nlp/wsd/Mihalcea.cc:14:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
14 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:115: opencog/nlp/wsd/CMakeFiles/wsd.dir/MihalceaLabel.cc.o] Error 1
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:89: opencog/nlp/wsd/CMakeFiles/wsd.dir/Mihalcea.cc.o] Error 1
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/NNAdjust.cc:19:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:128: opencog/nlp/wsd/CMakeFiles/wsd.dir/NNAdjust.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:815: opencog/nlp/wsd/CMakeFiles/wsd.dir/all] Error 2
make: *** [Makefile:152: all] Error 2
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# octool -cal
/usr/local/bin/octool: option requires an argument -- l
Usage: octool OPTION
-r Add software repositories
-d Install base/system build dependencies
-p Install python build dependencies
-s Install haskell build dependencies in user space. Don't use sudo
-i Install build-job artifacts
-c Install Cogutil
-a Install AtomSpace
-f Install from opencog github repo. Pass the name of the repo as an argument
-o Install OpenCog
-n Install notebook
-l {default|java} For installing Link Grammar with java binding '-l java' else '-l default'
-m Install MOSES
-g Install Guile 3.0.7
-b Build source code in git worktree found @ /root/OPENCOG/opencog/build
-e Build examples in git worktree found @ /root/OPENCOG/opencog/build
-t Run tests of source code in git worktree found @ /root/OPENCOG/opencog/build
-j [jobs] override number of auto-detected make jobs
-w download data for the opencog repo
-v Verbose output for 'apt-get' commands
-h This help message
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# octool -cal -- l
/usr/local/bin/octool: line 398: message: command not found
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# cd build
-bash: cd: build: No such file or directory
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# cmake ..
CMake Deprecation Warning at CMakeLists.txt:19 (CMAKE_POLICY):
The OLD behavior for policy CMP0037 will be removed from a future version
of CMake.

The cmake-policies(7) manual explains that the OLD behaviors of all
policies are deprecated and that a policy should be set to OLD only under
specific short-term circumstances. Projects should be ported to the NEW
behavior and not rely on setting a policy to OLD.

-- Build type: Release
-- CogUtil found.
-- AtomSpace found.
-- Could NOT find CogServer (missing: CogServer_DIR)
-- CogServer was not found.
-- Could NOT find AttentionBank (missing: AttentionBank_DIR)
-- AttentionBank was not found. OpenPsi and Ghost will not be built.
-- Could NOT find URE (missing: URE_DIR)
-- URE was not found. OpenPsi will not be built.
-- Could NOT find PLN (missing: PLN_DIR)
-- PLN was not found. Ghost will not be built.
-- Could NOT find LGAtomese (missing: LGAtomese_DIR)
-- LGAtomese was not found. Ghost will not be built.
-- GHC was found.
-- Stack found.
-- The Haskell Tool Stack found.
-- Guile (3.0.7 >= 2.2.2) was found.
-- Python 3.8.10 interpreter found.
-- Python 3.8.10 libraries found.
-- Cython ( 0.29.2 >= 0.24.0) found.
-- Python destination dir found: /root/dev3.8/lib/python3.8/site-packages
-- Python install dir: /root/dev3.8/lib/python3.8/site-packages/opencog
-- nosetests not found: needed for python tests
-- Valgrind Prefix:
-- Could NOT find VALGRIND (missing: VALGRIND_INCLUDE_DIR VALGRIND_PROGRAM)
-- VALGRIND missing: needed for thread debugging.
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Doxygen not found, you won't be able to generate API documentation.

Building for Ubuntu 20.04.3 LTS

The following components will be built:
Cython bindings - Cython (python) bindings.
Unit tests - Unit tests.

The following components WILL NOT be built:
Doxygen - Code documentation.
OpenPsi - MicroPsi OpenCog implementation.
Ghost - Ghost chatbot.
Haskell codes - Logic via Lojban.

-- Configuring done
-- Generating done
-- Build files have been written to: /root/OPENCOG/opencog/build
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# make -j$(nproc)
[ 10%] Built target neighbors
[ 10%] Built target SCM_CONFIG
[ 27%] Built target cogita
[ 27%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_scm
[ 27%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_sentiment
[ 31%] Built target nlp_oc_atom_types
[ 31%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_oc-types
[ 31%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_eva_model
[ 41%] Built target nlp-oc-types
[ 44%] Building CXX object opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeThin.cc.o
[ 44%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_eva_behavior
[ 55%] Built target nlp_oc_types_cython
[ 58%] Building CXX object opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeUtils.cc.o
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/EdgeUtils.cc:10:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:76: opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeUtils.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/EdgeThin.cc:12:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:63: opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeThin.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:815: opencog/nlp/wsd/CMakeFiles/wsd.dir/all] Error 2
make: *** [Makefile:152: all] Error 2
(dev3.8) root@ubuntu4:/OPENCOG/opencog/build# sudo make install
[ 0%] Built target SCM_CONFIG
[ 10%] Built target neighbors
[ 27%] Built target cogita
[ 27%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_scm
[ 27%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_sentiment
[ 27%] Built target COPY_TO_LOAD_PATH_IN_BUILD_DIR_FROM__root_OPENCOG_opencog_opencog_nlp_oc-types
[ 31%] Built target nlp_oc_atom_types
[ 41%] Built target nlp-oc-types
[ 44%] Building CXX object opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeThin.cc.o
In file included from /root/OPENCOG/opencog/opencog/nlp/wsd/EdgeThin.cc:12:
/root/OPENCOG/opencog/opencog/nlp/wsd/ForeachWord.h:23:10: fatal error: opencog/nlp/types/atom_types.h: No such file or directory
23 | #include <opencog/nlp/types/atom_types.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [opencog/nlp/wsd/CMakeFiles/wsd.dir/build.make:63: opencog/nlp/wsd/CMakeFiles/wsd.dir/EdgeThin.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:815: opencog/nlp/wsd/CMakeFiles/wsd.dir/all] Error 2
make: *** [Makefile:152: all] Error 2

i also installed lg-atomese library . please help me to fix this issue as soon as possible .

octool_rpi.sh broken

variables in src files set by cmake files disturb running when running on a pi.
this was a long running problem but since the focus was ghost there was no need for loading modules from the cogserver but now since ghost needs modules, this needs to be fixed.

oboslete packages: tcl tk

As best as I can tell, tcl and tk were used for the old embodiment code -- they are no longer needed. However, I am confused: I see python-tk and python-glade2 being installed .. this was never needed.
Also, to the best of my knowledge, these are also not needed:

ttf-lyx
krb5-multidev 
dpkg-dev
libdpkg-perl
libkadm5clnt-mit8
libkrb5-dev
libldap2-dev

and many others ...

hard-coded gcc version

I've been using gcc-4.8 (the default) on trusty, since forever. Thus I was surprised to see this hard-coded:

        g++-4.6 \
        gcc-4.6 \
        libstdc++6-4.6-dev \

The above prevent octool from working on Ubuntu xenial. Its enough to just install g++ and gcc -- and I am not convinced that libstdc++ needs to be specified; the correct version seems to get installed, automatically.

"./octool -rsdpcav -l default" on clean install of Ubuntu 18.04.2 gives "No package 'bdw-gc'"

A clean install of Ubuntu 18.04.2 seems to be missing bdw-gc. When running the "./octool -rsdpcav -l default" command listed in the "Building OpenCog (Hands On)" tutorial, an error is thrown during guile portion. "No package 'bdw-gc'"

A work around is to manually install with "apt-get install libgc-dev" before running the "./octool -rsdpcav -l default" command.

Adding an install for the garbage collector or a reference to manually install it in the error message might be useful, but this issue seems relatively unimportant. I have not had the same issue outside of clean installs of Ubuntu as bdw-gc seems to get installed by a number of common programs such as Inkscape.

ocpkg should include a dependency for a jdk package

Nils asked me to file an issue here, so I'm complying. I attempted to use ocpkg to install opencog on an ubuntu 16.04 VM and it failed with the following error:

BUILD FAILED
/tmp/link-grammar-5.4.2/build/bindings/java/build.xml:21: Unable to
find a javac compiler; com.sun.tools.javac.Main is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.
It is currently set to "/usr/lib/jvm/java-8-openjdk-amd64/jre"

Total time: 0 seconds
Makefile:588: recipe for target 'linkgrammar-5.4.2.jar' failed
make[2]: *** [linkgrammar-5.4.2.jar] Error 1
make[2]: Leaving directory '/tmp/link-grammar-5.4.2/build/bindings/java'
Makefile:438: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/tmp/link-grammar-5.4.2/build/bindings'
Makefile:535: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

After manually installing the openjdk-8-jdk package the install appeared to successfully complete. There may be alternative jdk packages available in ubuntu that would also satisfy this dependency though.

  best,
       ~c

OpenSSL error on Ubuntu 20.04 LTS while installing

I'm trying to install Link-Grammar using the command octool -rdcpav -l default that supposedly would install everything.

After build everything I guess, It starts to install Link-Grammar and that happens

[octool] Installing Link-Grammar....
--2020-06-13 10:09:36--  http://www.abisource.com/downloads/link-grammar/current/
Resolving www.abisource.com (www.abisource.com)... 130.89.149.216
Connecting to www.abisource.com (www.abisource.com)|130.89.149.216|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://www.abisource.com/downloads/link-grammar/current/ [following]
--2020-06-13 10:09:37--  https://www.abisource.com/downloads/link-grammar/current/
Connecting to www.abisource.com (www.abisource.com)|130.89.149.216|:443... connected.
OpenSSL: error:1425F102:SSL routines:ssl_choose_client_version:unsupported protocol
Unable to establish SSL connection.

I asked on StackOverflow here, but unfortunately, it didn't work.

What to do?

python3 source issue

I am attempting to create my first build of OpenCog, but running into an issue. I am completely new at this, and here is my best attempt to outline my experience in the hopes of resolving the issue.

It looks to me that the root of the issue is a failure to install Python 3 from the expected packages, which command appears to be rooted in this ocpkg script.

I am running:
MacOS MacOS 10.13.6
VirtualBox 6.1.22
Vagrant 2.2.16

Following instructions here:
https://wiki.opencog.org/w/Building_OpenCog_in_a_Linux_Virtual_Machine_on_Mac_OS_X

Here is my experience (I've done this 3 times now, same issues):
I am able to create the appropriate directory, opencog_repos, clone the GitHub file into it, and create the symbolic link to the vagrant box.

I am able to vagrant up, and the program successfully downloads and assigns the xenial64 vagrant box, creates the appropriate ssh key, mount shared folders.

The vagrant provisioner: shell initiates, and the inline script starts, and downloads the https://raw.githubusercontent.com/opencog/ocpkg/master/ocpkg

/tmp/octool successfully saves, and vagrant begin running the second provisioner: shell, and running the second inline script. It begins to add repositories, and I see this (issue toward the bottom):


    default: [octool] Adding software repositories...
    default: Hit:1 http://archive.ubuntu.com/ubuntu xenial InRelease
    default: Get:2 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security InRelease [7,503 B]
    default: Get:3 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
    default: Get:4 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates InRelease [7,475 B]
    default: Get:5 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main amd64 Packages [99.4 kB]
    default: Get:6 http://archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
    default: Get:7 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB]
    default: Get:8 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages [7,532 kB]
    default: Get:9 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 Packages [785 kB]
    default: Get:10 http://security.ubuntu.com/ubuntu xenial-security/universe Translation-en [225 kB]
    default: Get:11 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 Packages [7,864 B]
    default: Get:12 http://security.ubuntu.com/ubuntu xenial-security/multiverse Translation-en [2,672 B]
    default: Get:13 http://archive.ubuntu.com/ubuntu xenial/universe Translation-en [4,354 kB]
    default: Get:14 http://archive.ubuntu.com/ubuntu xenial/multiverse amd64 Packages [144 kB]
    default: Get:15 http://archive.ubuntu.com/ubuntu xenial/multiverse Translation-en [106 kB]
    default: Get:16 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [2,049 kB]
    default: Get:17 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [1,219 kB]
    default: Get:18 http://archive.ubuntu.com/ubuntu xenial-updates/universe Translation-en [358 kB]
    default: Get:19 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 Packages [22.6 kB]
    default: Get:20 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse Translation-en [8,476 B]
    default: Get:21 http://archive.ubuntu.com/ubuntu xenial-backports/main amd64 Packages [9,812 B]
    default: Get:22 http://archive.ubuntu.com/ubuntu xenial-backports/main Translation-en [4,456 B]
    default: Get:23 http://archive.ubuntu.com/ubuntu xenial-backports/universe amd64 Packages [11.3 kB]
    default: Get:24 http://archive.ubuntu.com/ubuntu xenial-backports/universe Translation-en [4,476 B]
    default: Fetched 17.3 MB in 7s (2,175 kB/s)
    default: Reading package lists...
    default: [octool] Installing python3 ....
    default: Reading package lists...
    default: Building dependency tree...
    default: Reading state information...
    default: E
    default: : 
    default: Unable to locate package python3.8-dev
    default: E
    default: : 
    default: Couldn't find any package by glob 'python3.8-dev'
    default: E
    default: : 
    default: Couldn't find any package by regex 'python3.8-dev'
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.

(The issue appears to me to stem from the command on line 909 of this ocpkg script; this command does not appear to execute as expected on my machine)

I am able to ssh into the vagrant machine, even after this fails; I can move around the directories, and everything appears to be in place. However, I am not able to cmake....I suspect the build did not finish after python did not successfully install.

I attempted to manually download a version of python 3.8, which got me further along the process, but then I ran into other issues, which I solved manually, and ran into still further issues. Again, I suspect it is because the build did not complete after the failure to load the python package expected, and so it was not a simple fix. I can describe those issues if it might help.

My entire terminal process, from start of directory build to cmake error is as follows (I've added some manual spacing, to hopefully make it easier to read):

bash-3.2$ mkdir opencog_repos
bash-3.2$ cd opencog_repos/
bash-3.2$ git clone https://github.com/opencog/opencog
Cloning into 'opencog'...
remote: Enumerating objects: 221451, done.
remote: Counting objects: 100% (325/325), done.
remote: Compressing objects: 100% (221/221), done.
remote: Total 221451 (delta 174), reused 188 (delta 100), pack-reused 221126
Receiving objects: 100% (221451/221451), 181.79 MiB | 4.48 MiB/s, done.
Resolving deltas: 100% (170413/170413), done.

bash-3.2$ ln -s $PWD/opencog/lib/Vagrantfile Vagrantfile

bash-3.2$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Preparing master VM for linked clones...
    default: This is a one time operation. Once the master VM is prepared,
    default: it will be used as a base for linked clones, making the creation
    default: of new VMs take milliseconds on a modern system.
==> default: Importing base box 'ubuntu/xenial64'...
==> default: Cloning VM...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'ubuntu/xenial64' version '20210623.0.0' is up to date...
==> default: Setting the name of the VM: opencog-dev
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
    default: Adapter 2: hostonly
==> default: Forwarding ports...
    default: 5000 (guest) => 5000 (host) (adapter 1)
    default: 17001 (guest) => 17001 (host) (adapter 1)
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection reset. Retrying...
    default: 
    default: Vagrant insecure key detected. Vagrant will automatically replace
    default: this with a newly generated keypair for better security.
    default: 
    default: Inserting generated public key within guest...
    default: Removing insecure key from the guest if it's present...
    default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
    default: The guest additions on this VM do not match the installed version of
    default: VirtualBox! In most cases this is fine, but in rare cases it can
    default: prevent things such as shared folders from working properly. If you see
    default: shared folder errors, please make sure the guest additions within the
    default: virtual machine match the version of VirtualBox you have installed on
    default: your host and reload your VM.
    default: 
    default: Guest Additions Version: 5.1.38
    default: VirtualBox Version: 6.1
==> default: Setting hostname...
==> default: Configuring and enabling network interfaces...
==> default: Mounting shared folders...
    default: /home/vagrant/opencog => /Users/bertbennett/opencog_repos
==> default: Running provisioner: shell...
    default: Running: inline script
    default: --2021-07-08 06:57:43--  https://raw.githubusercontent.com/opencog/ocpkg/master/ocpkg
    default: Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 
    default: 185.199.109.133
    default: , 
    default: 185.199.108.133
    default: , 
    default: 185.199.111.133
    default: , ...
    default: Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.199.109.133|:443... 
    default: connected.
    default: HTTP request sent, awaiting response... 
    default: 200 OK
    default: Length: 
    default: 40932
    default:  (40K)
    default:  [text/plain]
    default: Saving to: '/tmp/octool'
    default: 
    default:      0K
    default:  
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default:  
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default:  
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default:  
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default: .
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default:  
    default: 100%
    default:  1.63M
    default: =0.02s
    default: 
    default: 
    default: 2021-07-08 06:57:45 (1.63 MB/s) - '/tmp/octool' saved [40932/40932]
==> default: Running provisioner: shell...
    default: Running: inline script
    default: [octool] Adding software repositories...
    default: Hit:1 http://archive.ubuntu.com/ubuntu xenial InRelease
    default: Get:2 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security InRelease [7,503 B]
    default: Get:3 http://archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB]
    default: Get:4 https://esm.ubuntu.com/infra/ubuntu xenial-infra-updates InRelease [7,475 B]
    default: Get:5 https://esm.ubuntu.com/infra/ubuntu xenial-infra-security/main amd64 Packages [99.4 kB]
    default: Get:6 http://archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB]
    default: Get:7 http://security.ubuntu.com/ubuntu xenial-security InRelease [109 kB]
    default: Get:8 http://archive.ubuntu.com/ubuntu xenial/universe amd64 Packages [7,532 kB]
    default: Get:9 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 Packages [785 kB]
    default: Get:10 http://security.ubuntu.com/ubuntu xenial-security/universe Translation-en [225 kB]
    default: Get:11 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 Packages [7,864 B]
    default: Get:12 http://security.ubuntu.com/ubuntu xenial-security/multiverse Translation-en [2,672 B]
    default: Get:13 http://archive.ubuntu.com/ubuntu xenial/universe Translation-en [4,354 kB]
    default: Get:14 http://archive.ubuntu.com/ubuntu xenial/multiverse amd64 Packages [144 kB]
    default: Get:15 http://archive.ubuntu.com/ubuntu xenial/multiverse Translation-en [106 kB]
    default: Get:16 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [2,049 kB]
    default: Get:17 http://archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [1,219 kB]
    default: Get:18 http://archive.ubuntu.com/ubuntu xenial-updates/universe Translation-en [358 kB]
    default: Get:19 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse amd64 Packages [22.6 kB]
    default: Get:20 http://archive.ubuntu.com/ubuntu xenial-updates/multiverse Translation-en [8,476 B]
    default: Get:21 http://archive.ubuntu.com/ubuntu xenial-backports/main amd64 Packages [9,812 B]
    default: Get:22 http://archive.ubuntu.com/ubuntu xenial-backports/main Translation-en [4,456 B]
    default: Get:23 http://archive.ubuntu.com/ubuntu xenial-backports/universe amd64 Packages [11.3 kB]
    default: Get:24 http://archive.ubuntu.com/ubuntu xenial-backports/universe Translation-en [4,476 B]
    default: Fetched 17.3 MB in 7s (2,175 kB/s)
    default: Reading package lists...
    default: [octool] Installing python3 ....
    default: Reading package lists...
    default: Building dependency tree...
    default: Reading state information...
    default: E
    default: : 
    default: Unable to locate package python3.8-dev
    default: E
    default: : 
    default: Couldn't find any package by glob 'python3.8-dev'
    default: E
    default: : 
    default: Couldn't find any package by regex 'python3.8-dev'
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.
bash-3.2$ vagrant ssh
Welcome to Ubuntu 16.04.7 LTS (GNU/Linux 4.4.0-210-generic x86_64)

 * Documentation:  https://help.ubuntu.com
 * Management:     https://landscape.canonical.com
 * Support:        https://ubuntu.com/advantage

UA Infra: Extended Security Maintenance (ESM) is not enabled.

0 updates can be applied immediately.

20 additional security updates can be applied with UA Infra: ESM
Learn more about enabling UA Infra: ESM service for Ubuntu 16.04 at
https://ubuntu.com/16-04

New release '18.04.5 LTS' available.
Run 'do-release-upgrade' to upgrade to it.


vagrant@opencog:~$ pwd
/home/vagrant
vagrant@opencog:~$ ls
opencog
vagrant@opencog:~$ cd opencog
vagrant@opencog:~/opencog$ mkdir build
vagrant@opencog:~/opencog$ cd build
vagrant@opencog:~/opencog/build$ cmake ..
The program 'cmake' is currently not installed. To run 'cmake' please ask your administrator to install the package 'cmake'


Thank you for any time or attention you can point in this direction, to help me get up and going.

404 Error

I'm following the installing Opencog for noobs guide, but keep getting a 404 error when I run the command:
wget https://raw.github.com/opencog/ocpkg/master/ocpkg && chmod ugo+rx ocpkg && ./ocpkg -v

Here's the error:
Ign http://us.archive.ubuntu.com trusty-backports/universe Translation-en_US
Err http://ppa.launchpad.net trusty/main amd64 Packages
404 Not Found
Err http://ppa.launchpad.net trusty/main i386 Packages
404 Not Found
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Err http://ppa.launchpad.net trusty/main amd64 Packages
404 Not Found
Err http://ppa.launchpad.net trusty/main i386 Packages
404 Not Found
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Ign http://ppa.launchpad.net trusty/main Translation-en_US
Ign http://ppa.launchpad.net trusty/main Translation-en
Fetched 1,550 kB in 24s (62.6 kB/s)
W: Failed to fetch http://ppa.launchpad.net/chris-lea/cython/ubuntu/dists/trusty/main/binary-amd64/Packages 404 Not Found

W: Failed to fetch http://ppa.launchpad.net/chris-lea/cython/ubuntu/dists/trusty/main/binary-i386/Packages 404 Not Found

W: Failed to fetch http://ppa.launchpad.net/gandelman-a/test-catalog/ubuntu/dists/trusty/main/binary-amd64/Packages 404 Not Found

W: Failed to fetch http://ppa.launchpad.net/gandelman-a/test-catalog/ubuntu/dists/trusty/main/binary-i386/Packages 404 Not Found

E: Some index files failed to download. They have been ignored, or old ones used instead.
[ocpkg] Exiting ocpkg normally...

What can I do to solve this?

Install using 'octool -rdcpav -l default' on new ubuntu server install gives PyYAML install error

Running the script

octool -rdcpav -l default

runs and builds fine for a while then hits this when trying to install new PyYAML
Output:

Building wheels for collected packages: pyyaml, nltk
Running setup.py bdist_wheel for pyyaml ... done
Stored in directory: /root/.cache/pip/wheels/ad/da/0c/74eb680767247273e2cf2723482cb9c924fe70af57c334513f
Running setup.py bdist_wheel for nltk ... done
Stored in directory: /root/.cache/pip/wheels/d1/ab/40/3bceea46922767e42986aef7606a600538ca80de6062dc266c
Successfully built pyyaml nltk
Installing collected packages: pyyaml, nltk
Found existing installation: PyYAML 3.12
Cannot uninstall 'PyYAML'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

Please help!

Debian Jessie i386 CMake Error at CMakeDetermineCXXCompiler.cmake:56

user$ ./octool -rsdpcalv
...
cpprestsdk-2.9.0/license.txt
cpprestsdk-2.9.0/setup_ps_env_VS2013.ps1
cpprestsdk-2.9.0/setup_ps_env_VS2015.ps1
-- The C compiler identification is GNU 4.9.2
CMake Error at /usr/share/cmake-3.0/Modules/CMakeDetermineCXXCompiler.cmake:56 (message):
Could not find compiler set in environment variable CXX:

g++-4.8.

Call Stack (most recent call first):
CMakeLists.txt:3 (project)

CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER_ENV_VAR
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
CMAKE_CXX_COMPILER
CMake Error: Could not find cmake module file: /tmp/cpprestsdk-2.9.0/Release/build.release/CMakeFiles/3.0.2/CMakeCXXCompiler.cmake
CMake Error at CMakeLists.txt:3 (project):
No CMAKE_CXX_COMPILER could be found.

Tell CMake where to find the compiler by setting the CMake cache entry
CMAKE_CXX_COMPILER to the full path to the compiler, or to the compiler
name if it is in the PATH.

CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!
See also "/tmp/cpprestsdk-2.9.0/Release/build.release/CMakeFiles/CMakeOutput.log".
ponyatov@debian:~/opencog$ uname -a
Linux debian 3.16.0-4-586 #1 Debian 3.16.43-2 (2017-04-30) i686 GNU/Linux

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.