bkchem-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bkchem-user] Using BKChem as a library for generation of 2D structu


From: Noel O'Boyle
Subject: Re: [Bkchem-user] Using BKChem as a library for generation of 2D structure images
Date: Thu, 27 Mar 2008 15:22:55 +0000

On 27/03/2008, Beda Kosata <address@hidden> wrote:
> Hi Noel,
>  I am just testing Pybel with the intention to use it in BKChem :) Thanks
>  for the work you are putting into it.
Well, likewise :-)

>  As for your question, yes it is possible. For this you could use either
>  a bkchem batch script (http://bkchem.zirael.org/batch_mode_en.html) or
>  (in case you could do with uglier picture, but need it fast) you could
>  use only the underlying oasa library which has support for exporting
>  PNGs on its own.
>
>  The first thing could be done with a script sm2png_batch.py (just a
>  quick hack, I could elaborate more if needed). You can run the script
>  like this:
>
>  bkchem -b sm2png_batch.py c1ccccc1

Hmm...it seems that it's necessary to start the Application. Do you
have any plans to separate some of the functionality into a library
that could be accessed without starting the App? For example, I simply
want to (1) build a molecule (using the information in the connection
table of a pybel molecule), (2) generate 2D layout, (3) create an
image (preferably stored in a string, rather than in a file).

It would be great to have this as a library, not just for Pybel.
According to today's write up on Depth First, BKChem is one of only 4
available structure diagram generators...and the only one in Python
(see 
http://depth-first.com/articles/2008/03/26/five-open-tools-for-2d-structure-layout-aka-structure-diagram-generation)

My other question is how stable is the BKChem API?

Noel

>
>         Best regards
>
>                 Beda
>
>
>
>  Noel O'Boyle wrote:
>  > Hello Beda,
>  >
>  > I'm working on Pybel (OpenBabel Python wrapper) and am looking into
>  > ways of generating a quick view of the structure of a molecule. Is it
>  > possible to use BKChem to generate an image of a molecule from the
>  > Python prompt which I can then display?
>  >
>  > I don't want to start BKChem itself, although that is another
>  > possibility (but that is a different problem). I just want to display
>  > a simple 2D view of a molecule.
>  >
>  > If this is possible, I would appreciate some pointers on how to do this.
>  >
>  > Regards,
>  >    Noel (O'Boyle)
>  >
>  >
>
> > _______________________________________________
>  > Bkchem-user mailing list
>  > address@hidden
>  > http://lists.nongnu.org/mailman/listinfo/bkchem-user
>  >
>
>
>
>  --
>  Bedrich Kosata
>  Laboratory of Informatics and Chemistry
>  ICT Prague
>  Czech Republic
>
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]