End of Summer

Hi everyone!

Summer of Code is finally coming to an end. The official “pencils down” date is the 29th, so a great deal of the work I’ve been doing this past week has been testing my code and creating documentation. You can find my final project at https://github.com/BoyDun/IBW_SBML_SBOL_Export. The Repressilator SBML model produces a nicely oscillating graph when simulated in iBioSim, and you can run it for yourself with the converted file I included in the “Example Conversions” folder. My repository contains every file in IBW that I’ve created or modified, but since Infobiotics Workbench will be open-source pending publication, my code isn’t runnable by itself. However, I’ve included a link to the IBW executable in the README, where you can run the compiled program and look for my feature under File->Export->SBML/SBOL.

The logical next step in a hypothetical extension to this project would be to allow for the import and conversion of SBOL and SBML models into IBL documents, but that would require implementing a function that can convert the Eclipse Modeling Framework IBL model back into a document. Another challenge would be to properly handle missing information from either the SBOL or SBML side since neither standard captures every aspect of IBL.

As for me, I’m hoping to present my work at COMBINE, an annual conference coordinating the development of systems biology standards. Additionally, after discussing with my mentors, I’m happy to say I will be continuing my work with the Infobiotics Workbench, although at a much reduced pace due to academic obligations during the school year.

And I think that about sums up my experience this summer – if you want to reach out for whatever reason, feel free to do so at bodun@stanford.edu. Other than that, see you maybe next summer 🙂

Regards,
Peter

Advertisements

Tidying Up Pt. 2

Hi everyone,

Today marks the penultimate week of GSoC, which means I’m wrapping things up. Aside from one small issue with SBML rate units, I’ve finished constructing my export functions and their corresponding user interface. My SBML cell molecules now properly replace their corresponding molecules in device input/output lists instead of the other way around, and I’ve included the proper unit-base Kinds in their corresponding unit definitions. I’ve also updated my JSBML package to the most recent snapshot, built straight from source. Although it may not be as well-supported at this point as their most recent stable release, it contains a bug patch that eliminates many of my SBML document validation errors regarding correctly set Port IDs.

The most challenging issue I worked on this week was setting up correct KineticLaws for my SBML Reactions. There isn’t much documentation describing how the string representation of the KineticLaw should be constructed, but I made it work through a mixture of looking through supporting code, guessing-and-checking, and asking my mentors. The forward and reverse rates must be added as LocalParameters before being referenced by their parameter IDs, whereas the reactants and products didn’t need to be added since they were already included in the Reaction as SpeciesReferences.

Finally, I added comment blocks documenting every function I wrote in IBW and a few additional in-line comments. Next steps include testing my functions with a variety of IBL models to ensure they are robust and creating any other documentation that is necessary.

Best,
Peter

Tidying Up

Hi all!

This week I mainly focused on updating and patching bugs in my UI implementation and interface between the UI and actual conversion function. I extended the export wizards to request a name to save the converted model to and automatically append the proper file extension when necessary. Within SBML specifically, I included the option of flattening the exported model – this is achieved by first flattening the EMF model before parsing it with my SBML export function.

Finally, one persistent bug I had was a null-pointer exception in IblResource, an object that I needed to fetch the EMF model. The object initialized as null upon startup and only acquired a value after the user clicked on the proper frame in IBW. To resolve this issue, I manually fetch the resource from the active frame if the user chooses to export to SBOL or SBML. Now, the user can immediately export from an IBL document upon first launching IBW.

In my export functions, I fixed my SBML ports and SBOL maptos that link cell components (compartment, species) to device components. Currently, I’m working on updating my SBML package to the most recent snapshot and fixing my unit definitions.

Until next week,
Peter

Google Summer of Code Final Phase!

Hi everyone!

This week marks the beginning of the final phase of Google Summer of Code. While I’m putting the finishing touches on my SBOL and SBML export functionalities, I’ve also constructed the UI interface for an export wizard started by another IBW contributor. By going to file→export→SBOL or file→export→SBML, the user can now explicitly choose to export his IBL model as SBOL or SBML without having to first biocompile his model. The SBOL interface lets the user choose to export a biocompiled or non-biocompiled model, and it also prompts for a namespace and a directory path. The SBML interface is a bit simpler and only requires a directory path.

Hooking the export functionalities into the wizard, which is located in a different package, generated a circular dependency that I resolved by eliminating my function’s call to the Biocompiler class. I now skip over device ruleLists and moleculeLists during SBOL export in order to produce a cleaner visualization, and I’ve integrated SBML export into IBW. Current issues I’m working on include fetching the correct Ibl resource to export without having to explicitly click on it and resolving my last few SBML design errors.

Best,

Peter

Further Updates on SBOL Export in IBW

Hi everyone!

I spent most of this week polishing up my SBOL export functionality in IBW. I also made a small tweak to the bypassGUI.xtend file to run on libSBOLj 2.1 and implemented sequence fetching from SynBioHub. This will allow users to include parts from SynBioHub’s virtual repository in their IBL document. I am currently attempting to fetch the hierarchical EMF model to export rather than the flattened model, which doesn’t allow me to access information such as the input and output molecules of devices.

The export function now takes in both the EMF model and an optional Biocompiler model since both contain relevant information that can populate the final SBOL model. On the frontend, users will have the option of choosing to export the SBOL model pre- or post-biocompilation, which dictates if the Biocompiler model will be included.

The user is now prompted for a namespace to use to generate the SBOL model rather than the default placeholder “file://dummy.org”. I model cell and device rules as interactions, and I include their reactants and products as participants. Finally, I restructured the way the IBL model is iterated through so that instead of using MapTos between DNA component definitions declared in the cell and device partList, I now define the DNA part in the cell and instantiate it in the device that declares it or the cell itself if no device declares it. I also account for the possibility that the DNA part is mentioned in a cell rule, in which case an error is thrown since that should not happen.

To fix my naming scheme, I first modified my check for uniqueness to match URIs rather than names, which can be duplicated in an IBL document. If a molecule’s URI is not matched or it doesn’t have a URI, I make the assumption that the molecule is unique and create a new component definition for it. My uniqification procedure includes attempting to fetch that molecule’s component definition by ID and incrementing a counter that I append to the end of the ID until I create a unique ID that doesn’t return a fetched component definition. To account for display IDs consisting of URLs, I only use the part of the ID after the last delimiter, which I consider to be “/”, “#”, or “:”.

Finally, I found and fixed a variety of bugs introduced into my code from my updates. For example, I realized that only DNA components declared at the cell level contain a URI; components at the device part list level do not. In addition, SBO URIs must be included from identifiers.org and cannot be from any other domain. That about sums up my work!

Until next week,

Peter

In-Environment Development

Hi all!

I spent most of my week debugging my SBOL export functionality to comply with the Infobiotics Workbench Eclipse environment. My mentors and I realized that the EMF model and compiled Biocompiler Model both store different information necessary for a complete SBOL model, which is why I’ve also begun extending my export function to optionally handle both models instead of just one. This will allow the user to convert just the hierarchical information from the pre-compilation EMF model or also obtain information post-compilation about sequences, ribosome binding sites, etc.

A few issues I faced this week included figuring out how to import an external dependency (SBOL) into an Eclipse RCP application and modeling components with missing IDs and other information in SBOL. The resulting SBOL document I created from an existing IBL toggle_switch example appears as expected when visualized in iBioSim, though there might be a better way to implement the placeholder names I designed for components that lacked IDs. My next step is to implement better names for objects that lack unique IDs, improve the way I iterate over DNA parts, and hash molecules with URL IDs correctly. I will test my final product with a suite of IBL documents and ensure that they are all modeled correctly.

Best,
Peter

Windows -> Linux

Hi everyone!

This week I shifted my entire workflow to Ubuntu so I can make use of better-supported software. I successfully converted my test SBOL model to SBML via the Linux version of iBioSim, and the Windows version is also now completely functional. The converted SBML document captured an approximate semblance of my original SBOL model, including compartments for the cells and separate models for each cell and device. However, the DNA sequences themselves could not be captured due to the nature of SBML, and the individual device parts were given some strange names. A list of parameters were created and populated by default, which is something I’ll have to consider in my own implementation.

I again extended my SBOL export code, this time to handle the existence of Regions and alternative methods of populating the Biocompiler Model. Regions are objects that store multiple cells each, and the overall model must store only regions, only cells, only devices, or only molecules. Delving further in, regions may store molecules instead of cells, and cells may store molecules and not devices.

I also reattempted the installation of IBW in my Linux environment, which proved successful. Aside from a few compiler warnings and null-pointer exceptions, the Linux version of IBW works perfectly fine for me. I’ve ported my SBOL export framework over to the IBW source code and solved most of the compatibility issues that arose. Next steps include solving the rest of the issues and porting my SBML code over too.

Until next week!

Peter