[BGL] Problem when compiling bgl with boost1.37

Hi, I have a problem when trying to compile bgl and boost, maybe someone can help, thanks in advance. I am trying to install boost (boost1.37) and bgl python bindings (bgl-python-0.9) in some machines and it gives me an error when compiling: etch-386:/usr/src/bgl-python-0.9# /usr/src/boost_1_37_0/tools/jam/src/bin.linuxx86/bjam --pythonlibdir=/usr/lib/python2.4/site-packages/ --exec-prefix=/usr/ install error: Could not find parent for project at '.' error: Did not find Jamfile.jam or Jamroot.jam in any parent directory. I have used these versions before and everything was fine, I have no clue why now it doesn't work, the new machines are 64 bits, perhaps that is the clue? In order to solve the problem I tryied to compile boost_1_37_0 and another version of bgl: bgl-python from subversion (svn co https://svn.osl.iu.edu/svn/projects_viz/bgl-python) Everything was fine here at this step but when running my scripts they give me an error in the generation of the Graph object: ERROR: Traceback (most recent call last): File "testing_bgl.py", line 403, in ? sh_xml = run_shortest_paths_file(intfile,limit,proteins) File "testing_bgl.py", line 320, in run_shortest_paths_file interactome = Interactome() File "testing_bgl.py", line 23, in __init__ self.weights = self.graph.edge_properties['weight'] = self.graph.edge_property_map('float') AttributeError: 'Graph' object has no attribute 'edge_property_map' This script was working before, any idea of why the edge_property_map attribute cannot be set up in this version of bgl?? So, concluding, any clues for solving either the compilation problem or the python error??? Many thanks!! Pablo -- --------------------------------------------- Pablo Mínguez Paniagua PhD Student Bioinformatics Departament Centro de Investigación Príncipe Felipe (CIPF). Av. Autopista del Saler 16, 46013, Valencia, Spain Phone: +34 96 328 96 80 ext:1021 http://bioinfo.cipf.es/

Pablo Minguez wrote:
Hi,
I have a problem when trying to compile bgl and boost, maybe someone can help, thanks in advance.
I am trying to install boost (boost1.37) and bgl python bindings (bgl-python-0.9) in some machines and it gives me an error when compiling:
etch-386:/usr/src/bgl-python-0.9# /usr/src/boost_1_37_0/tools/jam/src/bin.linuxx86/bjam --pythonlibdir=/usr/lib/python2.4/site-packages/ --exec-prefix=/usr/ install error: Could not find parent for project at '.' error: Did not find Jamfile.jam or Jamroot.jam in any parent directory.
Your source directory has a file called Jamfile. In Boost.Build, this means this source directory is not a standalone -- it should have a parent project in some parent directory. In other words, your /usr/src/bgl-python-0.9 directory is busted.
I have used these versions before and everything was fine, I have no clue why now it doesn't work, the new machines are 64 bits, perhaps that is the clue?
In order to solve the problem I tryied to compile boost_1_37_0 and another version of bgl: bgl-python from subversion (svn co https://svn.osl.iu.edu/svn/projects_viz/bgl-python) Everything was fine here at this step but when running my scripts they give me an error in the generation of the Graph object:
ERROR: Traceback (most recent call last): File "testing_bgl.py", line 403, in ? sh_xml = run_shortest_paths_file(intfile,limit,proteins) File "testing_bgl.py", line 320, in run_shortest_paths_file interactome = Interactome() File "testing_bgl.py", line 23, in __init__ self.weights = self.graph.edge_properties['weight'] = self.graph.edge_property_map('float') AttributeError: 'Graph' object has no attribute 'edge_property_map'
This script was working before, any idea of why the edge_property_map attribute cannot be set up in this version of bgl??
I don't know -- boost.graph experts have to say. - Volodya

Everything was fine here at this step but when running my scripts they give me an error in the generation of the Graph object:
ERROR: Traceback (most recent call last): File "testing_bgl.py", line 403, in ? sh_xml = run_shortest_paths_file(intfile,limit,proteins) File "testing_bgl.py", line 320, in run_shortest_paths_file interactome = Interactome() File "testing_bgl.py", line 23, in __init__ self.weights = self.graph.edge_properties['weight'] = self.graph.edge_property_map('float') AttributeError: 'Graph' object has no attribute 'edge_property_map'
This script was working before, any idea of why the edge_property_map attribute cannot be set up in this version of bgl??
I don't know -- boost.graph experts have to say.
It looks like your graph doesn't have an edge property map :) I've never actually used the Python bindings, so this might not translate too well. You have to create your graphs with all of the properties that they're going to use later. My guess is that you're not explicitly creating an edge weight property with the graph, which would lead to this exception. As a caveat... I don't know if the Python bindings are actively maintained - I'd guess no. It may be tough to get good answers to your questions. Andrew Sutton andrew.n.sutton@gmail.com

Thanks Andrew and Volodya, I finally fixed the problem of the compilation with Volodya advice and my scripts work fine with bgl-python-0.9, so don't think I'll go into the other proble by now :) Thanks again! On Thursday 13 November 2008 15:22:25 Andrew Sutton wrote:
Everything was fine here at this step but when running my scripts they
give me
an error in the generation of the Graph object:
ERROR: Traceback (most recent call last): File "testing_bgl.py", line 403, in ? sh_xml = run_shortest_paths_file(intfile,limit,proteins) File "testing_bgl.py", line 320, in run_shortest_paths_file interactome = Interactome() File "testing_bgl.py", line 23, in __init__ self.weights = self.graph.edge_properties['weight'] = self.graph.edge_property_map('float') AttributeError: 'Graph' object has no attribute 'edge_property_map'
This script was working before, any idea of why the edge_property_map attribute cannot be set up in this version of bgl??
I don't know -- boost.graph experts have to say.
It looks like your graph doesn't have an edge property map :) I've never actually used the Python bindings, so this might not translate too well. You have to create your graphs with all of the properties that they're going to use later. My guess is that you're not explicitly creating an edge weight property with the graph, which would lead to this exception.
As a caveat... I don't know if the Python bindings are actively maintained - I'd guess no. It may be tough to get good answers to your questions.
Andrew Sutton andrew.n.sutton@gmail.com
-- --------------------------------------------- Pablo Mínguez Paniagua PhD Student Bioinformatics Departament Centro de Investigación Príncipe Felipe (CIPF). Av. Autopista del Saler 16, 46013, Valencia, Spain Phone: +34 96 328 96 80 ext:1021 http://bioinfo.cipf.es/
participants (3)
-
Andrew Sutton
-
Pablo Minguez
-
Vladimir Prus