can not find local path of re_comm package (error in environmental variable ROS_ROOT )
Hi :D,
I try to download a recipe from RoboEarth, but system does not find path to re_comm package !! I do not understand what is the error related to ?!
I run this in a terminal roslaunch re_comm re_comm_knowrob.launch
and this in other one
rosrun rosprolog rosprolog re_comm
then visualisation_canvas(_), planvis_create(_).
then
re_download_action_recipe('serve a drink', pr2:'PR2Robot1', Recipe), re_generate_cpl_plan(Recipe, CplPlan),planvis_load(Recipe,_).
amal@amal-HP-G62-Notebook-PC:~$ rosrun rosprolog rosprolog re_comm
% library(swi_hooks) compiled into pce_swi_hooks 0.00 sec, 2,224 bytes
% library(error) compiled into error 0.00 sec, 10,220 bytes
% library(lists) compiled into lists 0.00 sec, 25,320 bytes
% library(shlib) compiled into shlib 0.00 sec, 37,148 bytes
% library(option) compiled into swi_option 0.01 sec, 8,468 bytes
% library(process) compiled into process 0.01 sec, 55,748 bytes
% /opt/ros/fuerte/stacks/knowrob/rosprolog/prolog/init.pl compiled 0.01 sec, 60,268 bytes
% library(jpl) compiled into jpl 0.02 sec, 173,204 bytes
% library(sgml) compiled into sgml 0.00 sec, 24,636 bytes
% library(quintus) compiled into quintus 0.00 sec, 11,676 bytes
% rewrite compiled into rewrite 0.00 sec, 19,416 bytes
% library(uri) compiled into uri 0.00 sec, 8,048 bytes
% library(record) compiled into record 0.00 sec, 19,232 bytes
% rdf_parser compiled into rdf_parser 0.00 sec, 86,224 bytes
% library(gensym) compiled into gensym 0.00 sec, 2,580 bytes
% rdf_triple compiled into rdf_triple 0.00 sec, 21,820 bytes
% library(rdf) compiled into rdf 0.02 sec, 152,096 bytes
% library(debug) compiled into prolog_debug 0.00 sec, 12,180 bytes
% library(assoc) compiled into assoc 0.00 sec, 19,484 bytes
% library(sgml_write) compiled into sgml_write 0.01 sec, 67,520 bytes
% library(nb_set) compiled into nb_set 0.00 sec, 3,400 bytes
% library(utf8) compiled into utf8 0.01 sec, 7,108 bytes
% library(url) compiled into url 0.01 sec, 63,108 bytes
% rdf_cache compiled into rdf_cache 0.01 sec, 9,016 bytes
% library(semweb/rdf_db) compiled into rdf_db 0.06 sec, 393,328 bytes
% comp_similarity compiled into comp_similarity 0.06 sec, 409,756 bytes
% /opt/ros/fuerte/stacks/knowrob/ias_prolog_addons/prolog/init.pl compiled 0.07 sec, 410,444 bytes
% library(broadcast) compiled into broadcast 0.00 sec, 4,156 bytes
% library(semweb/rdf_edit) compiled into rdf_edit 0.01 sec, 48,484 bytes
% library(semweb/rdfs) compiled into rdfs 0.00 sec, 14,256 bytes
% library(semweb/owl) compiled into t20_owl 0.01 sec, 37,936 bytes
% library(socket) compiled into socket 0.00 sec, 7,036 bytes
% library(base64) compiled into base64 0.00 sec, 9,640 bytes
% library(http/http_open.pl) compiled into http_open 0.01 sec, 59,684 bytes
% library(thea/owl_parser) compiled into owl_parser 0.02 sec, 106,936 bytes
% library(odbc) compiled into odbc 0.00 sec, 21,616 bytes
% library(semweb/rdfs_computable) compiled into rdfs_computable 0.01 sec, 58,008 bytes
% /opt/ros/fuerte/stacks/knowrob/semweb/prolog/init.pl compiled 0.14 sec, 905,000 bytes
% library(tf_prolog) compiled into tf_prolog 0.00 sec, 12,800 bytes
% /opt/ros/fuerte/stacks/knowrob/tf_prolog/prolog/init.pl compiled 0.01 sec, 15,060 bytes
% library(knowrob_owl) compiled into knowrob_owl 0.00 sec, 7,420 bytes
% library(knowrob_perception) compiled into knowrob_perception 0.01 sec, 13,176 bytes
% Parsed "knowrob_objects.owl" in 0.00 sec; 202 triples
Warning: /opt/ros/fuerte/stacks/knowrob/knowrob_objects/prolog/knowrob_objects.pl:84:
Goal (directive) failed: knowrob_objects:owl_parser:owl_parse(../owl/knowrob_objects.owl,false,false,true)
% library(knowrob_objects) compiled into knowrob_objects 0.03 sec, 107,596 bytes
% library(owl_export) compiled into owl_export 0.00 sec, 11,636 bytes
% library(knowrob_coordinates) compiled into knowrob_coordinates 0.01 sec, 22,548 bytes
% /opt/ros/fuerte/stacks/knowrob/knowrob_objects/prolog/init.pl compiled 0.05 sec, 161,872 bytes
% /opt/ros/fuerte/stacks/knowrob/knowrob_common/prolog/init.pl compiled 0.05 sec, 175,044 bytes
% library(knowrob_actions) compiled into knowrob_actions 0.00 sec, 7,012 bytes
% /opt/ros/fuerte/stacks/knowrob/knowrob_actions/prolog/init.pl compiled 0.05 sec, 196,556 bytes
% library(util) compiled into util 0.00 sec, 15,440 bytes
% library(classifiers) compiled into classifiers 0.01 sec, 29,432 bytes
% library(jython) compiled into jython 0.00 sec, 13,348 bytes
% Parsed "owl.owl" in 0.01 sec; 169 triples
Warning: /opt/ros/fuerte/stacks/knowrob/ias_knowledge_base/prolog/init.pl:35:
Goal (directive) failed: user:owl_parser:owl_parse(/opt/ros/fuerte/stacks/knowrob/ias_knowledge_base/owl/owl.owl,false,false,true)
% Parsed "knowrob.owl" in 0.11 sec; 3,763 triples
Warning: /opt/ros/fuerte/stacks/knowrob/ias_knowledge_base/prolog/init.pl:36:
Goal (directive) failed: user:owl_parser:owl_parse(/opt/ros/fuerte/stacks/knowrob/ias_knowledge_base/owl/knowrob.owl,false,false,true)
% /opt/ros/fuerte/stacks/knowrob/ias_knowledge_base/prolog/init.pl compiled 0.32 sec, 1,367,236 bytes
% library(comp_cop) compiled into comp_cop 0.01 sec, 17,912 bytes
% Parsed "comp_cop.owl" in 0.01 sec; 161 triples
Warning: /opt/ros/fuerte/stacks/knowrob/comp_cop/prolog/init.pl:30:
Goal (directive) failed: user:owl_parser:owl_parse(/opt/ros/fuerte/stacks/knowrob/comp_cop/owl/comp_cop.owl,false,false,true)
% /opt/ros/fuerte/stacks/knowrob/comp_cop/prolog/init.pl compiled 0.02 sec, 30,328 bytes
% Parsed "srdl2-action.owl" in 0.01 sec; 78 triples
Warning: /opt/ros/fuerte/stacks/knowrob/mod_srdl/prolog/srdl2.pl:39:
Goal (directive) failed: srdl2:owl_parser:owl_parse(../owl/srdl2-action.owl,false,false,true)
% Parsed "PR2.owl" in 0.02 sec; 771 triples
Warning: /opt/ros/fuerte/stacks/knowrob/mod_srdl/prolog/srdl2.pl:40:
Goal (directive) failed: srdl2:owl_parser:owl_parse(../owl/PR2.owl,false,false,true)
% library(srdl2) compiled into srdl2 0.04 sec, 52,308 bytes
% /opt/ros/fuerte/stacks/knowrob/mod_srdl/prolog/init.pl compiled 0.04 sec, 54,660 bytes
% Parsed "comp_temporal.owl" in 0.01 sec; 164 triples
Warning: /opt/ros/fuerte/stacks/knowrob/comp_temporal/prolog/comp_temporal.pl:74:
Goal (directive) failed: comp_temporal:owl_parser:owl_parse(../owl/comp_temporal.owl,false,false,true)
% library(comp_temporal) compiled into comp_temporal 0.01 sec, 22,952 bytes
Warning: /opt/ros/fuerte/stacks/knowrob/comp_temporal/prolog/init.pl:30:
Goal (directive) failed: user:owl_parser:owl_parse(/opt/ros/fuerte/stacks/knowrob/comp_temporal/owl/comp_temporal.owl,false,false,true)
% /opt/ros/fuerte/stacks/knowrob/comp_temporal/prolog/init.pl compiled 0.01 sec, 26,348 bytes
% Parsed "comp_spatial.owl" in 0.00 sec; 52 triples
Warning: /opt/ros/fuerte/stacks/knowrob/comp_spatial/prolog/comp_spatial.pl:51:
Goal (directive) failed: comp_spatial:owl_parser:owl_parse(../owl/comp_spatial.owl,false,false,true)
% library(comp_spatial) compiled into comp_spatial 0.01 sec, 24,936 bytes
Warning: /opt/ros/fuerte/stacks/knowrob/comp_spatial/prolog/init.pl:32:
Goal (directive) failed: user:owl_parser:owl_parse(/opt/ros/fuerte/stacks/knowrob/comp_spatial/owl/comp_spatial.owl,false,false,true)
% /opt/ros/fuerte/stacks/knowrob/comp_spatial/prolog/init.pl compiled 0.02 sec, 73,440 bytes
% comp_re_vision compiled into comp_re_vision 0.00 sec, 6,204 bytes
% Parsed "roboearth.owl" in 0.00 sec; 151 triples
Warning: /home/amal/ros/stacks/roboearth/re_ontology/prolog/init.pl:41:
Goal (directive) failed: user:owl_parser:owl_parse(/home/amal/ros/stacks/roboearth/re_ontology/owl/roboearth.owl,false,false,true)
% Parsed "amigo.owl" in 0.02 sec; 731 triples
Warning: /home/amal/ros/stacks/roboearth/re_ontology/prolog/init.pl:63:
Goal (directive) failed: user:owl_parser:owl_parse(../owl/amigo.owl,false,false,true)
% /home/amal/ros/stacks/roboearth/re_ontology/prolog/init.pl compiled 0.10 sec, 213,232 bytes
% library(mod_vis) compiled into mod_vis 0.01 sec, 24,164 bytes
% /opt/ros/fuerte/stacks/knowrob/mod_vis/prolog/init.pl compiled 0.02 sec, 26,720 bytes
% library(knowrob_cad_models) compiled into knowrob_cad_models 0.00 sec, 2,632 bytes
% /opt/ros/fuerte/stacks/knowrob/knowrob_cad_models/prolog/init.pl compiled 0.00 sec, 5,572 bytes
[rospack] Error: stack/package re_wm_to_knowrob not found
[rospack] Error: stack/package re_wm_to_knowrob not found
% library(comp_roboearth) compiled into comp_roboearth 0.01 sec, 26,068 bytes
% /home/amal/ros/stacks/roboearth/re_comm/prolog/init.pl compiled 0.49 sec, 1,790,112 bytes
?- visualisation_canvas(_), planvis_create(_).
ControlP5 0.5.4 infos, comments, questions at http://www.sojamo.de/libraries/controlP5
PeasyCam v105
lights() is not available with this renderer.
Nov 24, 2012 9:50:51 PM controlP5.ControlWindow init
INFO: You are using renderer processing.core.PGraphics3D.
In order to render controlP5 elements you need to call the ControlP5's draw() manually.
Suggestion is to put controlP5.draw(); at the bottom of the draw function of your sketch.
Semantic map not found
item null not found
item null not found
item null not found
true.
?- re_download_action_recipe('serve a drink', pr2:'PR2Robot1', Recipe), re_generate_cpl_plan(Recipe, CplPlan),planvis_load(Recipe,_).
Downloading recipe for command:serve a drink
log4j:WARN No appenders could be found for logger (org.apache.http.impl.conn.SingleClientConnManager).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
java.io.IOException: Cannot run program "/opt/ros/fuerte/share/ros/bin/rospack": java.io.IOException: error=2, No such file or directory
at java.lang.ProcessBuilder.start(ProcessBuilder.java:475)
at roboearth.wp5.util.Util.getLocalRosPackagePath(Util.java:285)
at roboearth.wp5.util.Util.<clinit>(Util.java:94)
at roboearth.wp5.REClients.downloadRecipeFrom(REClients.java:261)
Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory
at java.lang.UNIXProcess.<init>(UNIXProcess.java:164)
at java.lang.ProcessImpl.start(ProcessImpl.java:81)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:468)
... 3 more
Couldn't find local path of re_comm package. (Is environmental variable ROS_ROOT set correctly?)
(((2))) that is in .bashrc
fi
source /opt/ros/fuerte/setup.bash
source /opt/ros/fuerte/setup.bash
JAVA_HOME=/usr/lib/jvm/default-java export JAVA_HOME PATH=$PATH:$JAVA_HOME/bin export PATH
export ROS_PACKAGE_PATH=/opt/ros/fuerte/share:/opt/ros/fuerte/stacks:/home/amal/ros
export PATH=.:/opt/ros/fuerte/bin:/opt/ros/fuerte/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/bin
export PATH=.:/opt/ros/fuerte/bin:/opt/ros/fuerte/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/bin
export PATH=.:/opt/ros/fuerte/bin:/opt/ros/fuerte/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/bin
export PATH=.:.:/opt/ros/fuerte/bin:/opt/ros/fuerte/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/bin
(((3))) when I require the recipe the system get out from
rosrun rosprolog rosprolog re_comm
Terminal
?- visualisation_canvas(_), planvis_create(_).
ControlP5 0.5.4 infos, comments, questions at http://www.sojamo.de/libraries/controlP5
PeasyCam v105
lights() is not available with this renderer.
Nov 29, 2012 8:55:16 PM controlP5.ControlWindow init
INFO: You are using renderer processing.core.PGraphics3D.
In order to render controlP5 elements you need to call the ControlP5's draw() manually.
Suggestion is to put controlP5.draw(); at the bottom of the draw function of your sketch.
Semantic map not found
true.
?- re_download_action_recipe('serve a drink', pr2:'PR2Robot1', Recipe).
Downloading recipe for command:serve a drink
log4j:WARN No appenders could be found for logger (org.apache.http.impl.conn.SingleClientConnManager).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
java.io.IOException: Cannot run program "/opt/ros/fuerte/share/ros/bin/rospack": java.io.IOException: error=2, No such file or directory
at java.lang.ProcessBuilder.start(ProcessBuilder.java:475)
at roboearth.wp5.util.Util.getLocalRosPackagePath(Util.java:285)
at roboearth.wp5.util.Util.<clinit>(Util.java:94)
at roboearth.wp5.REClients.downloadRecipeFrom(REClients.java:261)
Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory
at java.lang.UNIXProcess.<init>(UNIXProcess.java:164)
at java.lang.ProcessImpl.start(ProcessImpl.java:81)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:468)
... 3 more
Couldn't find local path of re_comm package. (Is environmental variable ROS_ROOT set correctly?)
amal@amal-HP-G62-Notebook-PC:~/ros/sandbox/amigro$ env | grep ROS
ROS_ROOT=/opt/ros/fuerte/share/ros
ROSLISP_PACKAGE_DIRECTORY=/opt/ros/fuerte/share/common-lisp/ros
ROS_PACKAGE_PATH=/opt/ros/fuerte/share:/opt/ros/fuerte/stacks:/home/amal/ros
ROS_MASTER_URI=http://localhost:11311
ROS_DISTRO=fuerte
ROS_ETC_DIR=/opt/ros/fuerte/etc/ros
Thanks,
Asked by Amal on 2012-11-24 09:11:40 UTC
Answers
Your environment looks wrong. It should be more like this:
ROS_ROOT=/opt/ros/fuerte/share/ros
ROS_PACKAGE_PATH=/opt/ros/fuerte/share:/opt/ros/fuerte/stacks:/home/amal/ros
Are you sourcing /opt/ros/fuerte/setup.bash
in your shell somewhere?
EDIT: Your ~/.bashrc
should probably look more like this:
source /opt/ros/fuerte/setup.bash
export JAVA_HOME=/usr/lib/jvm/default-java
export PATH=$PATH:$JAVA_HOME/bin
export ROS_PACKAGE_PATH=$ROS_PACKAGE_PATH:/home/amal/ros
I would not recommend repeating the source
line.
EDIT 2: I know nothing about java, but those log4j messages are warnings. You should probably follow that link to http://logging.apache.org/log4j/1.2/faq.html#noconfig, and try to eliminate the warning. But, I doubt that is the root problem.
The more serious error is that some java program is looking for rospack
in the wrong place. It should be /opt/ros/fuerte/bin/rospack, not /opt/ros/fuerte/share/ros/bin/rospack, which looks similar to the rospack path for Electric.
Maybe something has not yet been updated to work with Fuerte? This looks like a bug to me.
Asked by joq on 2012-11-26 09:45:08 UTC
Comments
That is in bash file, What is Wrong ?!
fi
source /opt/ros/fuerte/setup.bash
source /opt/ros/fuerte/setup.bash
JAVA_HOME=/usr/lib/jvm/default-java export JAVA_HOME PATH=$PATH:$JAVA_HOME/bin export PATH export ROS_PACKAGE_PATH=/opt/ros/fuerte/share:/opt/ros/fuerte/stacks:/home/amal/ros
Asked by Amal on 2012-11-26 10:17:38 UTC
I do not understand why It must looks as You say, what is the error with me and how I make it looks as You say ?!
Thanks
Asked by Amal on 2012-11-26 16:19:46 UTC
You sourced /opt/ros/fuerte/setup.bash twice. That may or may not work, but is definitely unnecessary. Your other commands are improperly formatted (at least as shown here). Please edit your original question and paste in exactly the last few commands in your .bashrc.
Asked by joq on 2012-11-26 16:28:36 UTC
You can try replacing them with the examples in my answer.
Asked by joq on 2012-11-26 16:29:24 UTC
Ok I edit The Q
Asked by Amal on 2012-11-26 16:54:03 UTC
It still looks mangled. Would you try pasting the four lines from the answer above in place of everything following the fi
? After editing .bashrc
you must open a new shell or terminal for the changes to take effect.
Asked by joq on 2012-11-27 03:05:09 UTC
I take ur answer in .bashrc but do no difference ?!!
Asked by Amal on 2012-11-29 07:39:43 UTC
What does env | grep ROS
display now?
Asked by joq on 2012-11-29 07:55:46 UTC
I do it in edit (((3)))
Asked by Amal on 2012-11-29 08:09:21 UTC
OK, your environment looks good now. I presume you installed the roboearth sources somewhere in /home/amal/ros. What does rospack find re_comm
show now?
Asked by joq on 2012-11-29 10:20:31 UTC
amal@amal-HP-G62-Notebook-PC:~$ rospack find re_comm
/home/amal/ros/stacks/roboearth/re_comm
Asked by Amal on 2012-11-29 21:35:30 UTC
seems that the problem is in (( log4j ))
Asked by Amal on 2012-11-29 22:18:09 UTC
"/opt/ros/fuerte/bin/rospack, not /opt/ros/fuerte/share/ros/bin/rospack, which looks similar to the rospack path for Electric"
Waht I have to do for this error ?!
Asked by Amal on 2012-11-30 07:10:28 UTC
I think roboearth.wp5.util.Util.getLocalRosPackagePath() has probably not yet been ported to Fuerte. You need to report that to the roboearth developers. I am not sure how to do that, maybe via http://www.roboearth.org/.
Asked by joq on 2012-12-01 04:31:15 UTC
OK thanks a lot for ur help :)
Asked by Amal on 2012-12-01 14:57:23 UTC
getLocalRosPackagePath does not specify any global path, but calls the rospack utility via the shell, i.e. it uses the one that is in your path. I am not sure about your setup, but I doubt this is a bug in the RoboEarth/re_comm package.
Asked by moritz on 2012-12-09 22:22:09 UTC
Comments
What ROS distro are you using? What operating system? What does
echo $ROS_ROOT
print?Asked by joq on 2012-11-26 06:11:44 UTC
I am using fuerte ros in ubuntu 10.04. that is /opt/ros/fuerte/share:/opt/ros/fuerte/stacks:/home/amal/ros for echo $ROS_ROOT
Asked by Amal on 2012-11-26 08:25:56 UTC