Menu

Speeding Up CreateFromDocument?

Help
2010-05-18
2013-03-06
  • Aoriste Boutade

    Aoriste Boutade - 2010-05-18

    CreateFromDocument() takes upwards of 20 minutes to finish processing a 240 line xml document whose tree depth never exceeds 6.  The function also seems to be a voracious consumer of memory, sucking down hundreds of megs during the course of its operation - this seemed fishy to me, so I thought I'd ask if I should be expecting any differently.  Should I be?

    Oh, Also:
    I am running on a 3.6GHz machine with 3.5 GB of memory.  The schema for which I have generated bindings can be found here: http://cse.unl.edu/~bkutsch/3_0_Final.xsd

    Thanks for any assistance.  Also, if this does turn out to be a bug, I will certainly submit a ticket.

     
  • Peter A. Bigot

    Peter A. Bigot - 2010-05-18

    Just glancing at your xsd, I expect you're running into this one.  If this seems plausible to you, please add a comment to that ticket, especially providing information on your need for a solution (importance to you and when you need a working solution).  Fixing this won't take more than a day or two, but right now I'm caught up in real work for which I'm sorta getting paid, so that's taking priority.

     
  • Peter A. Bigot

    Peter A. Bigot - 2010-05-30

    Version 1.1.1:

    pyxb[91]$ sh test.sh
    urn:uuid:07f553ca-6c01-11df-9271-001636553c48
    Python for AbsentNamespace0 requires 1 modules
    Saved binding source to ./airs.py
    pyxb[92]$ python -O rdairs.py
    Read took 0.00099802 seconds
    Conversion took 183.381 seconds
    Conversion took 182.048 seconds
    Conversion took 180.356 seconds
    pyxb[93]$
    

    Version 1.1.2:

    pyxb[109]$ sh test.sh
    urn:uuid:5adfb5a2-6c02-11df-81df-001636553c48
    Python for AbsentNamespace0 requires 1 modules
    Saved binding source to ./airs.py
    pyxb[110]$ python -O rdairs.py
    Read took 0.00171113 seconds
    Conversion took 0.298372 seconds
    Conversion took 0.125777 seconds
    Conversion took 0.128435 seconds
    pyxb[111]$
    

    I'm pretty happy.

     
    • jaroslaw

      jaroslaw - 2017-01-25

      Hi Peter, I would like to ask about https://sourceforge.net/p/pyxb/tickets/66/ status. I can see that is scheduled for PyXB 2.0, but you already posted some significant improvements here. Do you have a patch for these changes?
      Regards,
      jaroslaw

       
      • Peter A. Bigot

        Peter A. Bigot - 2017-01-25

        That was scheduled for 2.0 seven years ago. It didn't make the cut when unfinished but still potential tickets were transferred to Github over three years ago. There are no global performance improvements coming, and an API change away from properties is certainly not going to happen.

         

Log in to post a comment.

MongoDB Logo MongoDB