Hi.
The following text contains sample data. I'm simply trying to parse it
using libxml2dom as the lib to extract data.
As an example, to get the name/desc
test data
d = libxml2dom.parseString(s, html=1)
p1="//department/name"
p2="//department/desc"
pcount_ = d.xpath(p1)
ok Peter Otten code works (very fast),
and this is the profile
Sat Apr 12 11:15:39 2014restats
92834776 function calls in 6218.782 seconds
Ordered by: internal time
List reduced from 41 to 20 due to restriction <20>
ncalls tottime percall cumtime percall filename:lineno
Ok, i just run Peter's code and it seems really faster...I hope to don't
mistake this time!
Thanks
Gabriele
sent from Samsung Mobile
Il giorno 12/apr/2014 08:22, "Gabriele Brambilla" <
gb.gabrielebrambi...@gmail.com> ha scritto:
> Ok guys,
> I'm not expert about profile but help me to look at i
Ok guys,
I'm not expert about profile but help me to look at it.
this one is for 715853 elements (to multiply by 5, and for each of this N*5
there is a loop of 200 times)
Sat Apr 12 04:58:50 2014restats
9636507991 function calls in 66809.764 seconds
Ordered by: internal time
L
Gabriele Brambilla wrote:
> Ok guys, when I wrote that email I was excited for the apparent speed
> increasing (it was jumping the bottleneck for loop for the reason peter
> otten outlined).
> Now, instead the changes, the speed is not improved (the code still
> running from this morning and it's