So, I've gotten the mapping to work, but only sometimes? The code is here (http://kmdaily.pastebin.com/m6d4a86c3) that I'm running.
I'm checking the length of the Mapping when I'm done loading all the things to map (its ~9000), adding it to worldbase, and checking the length again (still 9000). Then, the code exits, and I try to load it on the command line or use it again, and it has a 0 length. I look at the file that its writing to, and I can see the data in it (the keys and values of the objects from the AnnotationDBs that I added). The object loads fine, and it accesses the database backend fine as well (watching the db connections shows it connecting). Any suggestions how to track the problem? Thanks! Kenny On Jun 8, 3:49 pm, Kenny Daily <kmda...@gmail.com> wrote: > Thanks, works great. I can't wait to apply this in so many other areas > where I've been manually loading in 3-4 different datasets that are > related to each other. > > On Jun 8, 3:11 pm, Christopher Lee <l...@chem.ucla.edu> wrote: > > > On Jun 8, 2009, at 2:59 PM, Kenny Daily wrote: > > > > I'm running this line that should give > > > me this: > > > > schema = metabase.OneToManyRelation(annotdb1, annotdb2, bindAttrs= > > > ('ltrs', 'genes')) > > > > Where annotdb1 are the genes, and annotdb2 are the repeats. > > > > Any suggestions on how to troubleshoot this problem? An full example > > > is available athttp://kmdaily.pastebin.com/m5f21ff52. Thanks! > > > Hi Kenny, > > use the worldbase.add_schema() method, not add_resource(). I.e. > > instead of > > > worldbase.add_resource("schema.%s" % resource_string, schema) > > > use > > > worldbase.add_schema(resource_string, schema) > > > -- Chris --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pygr-dev" group. To post to this group, send email to pygr-dev@googlegroups.com To unsubscribe from this group, send email to pygr-dev+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/pygr-dev?hl=en -~----------~----~----~----~------~----~------~--~---