I'm trying to make a unicode friendly regexp to grab sentences
reasonably reliably for as many unicode languages as possible, focusing
on european languages first, hence it'd be useful to be able to refer
to any uppercase unicode character instead of just the typical [A-Z],
which doesn't include, f
I'm trying to make a unicode friendly regexp to grab sentences
reasonably reliably for as many unicode languages as possible, focusing
on european languages first, hence it'd be useful to be able to refer
to any uppercase unicode character instead of just the typical [A-Z],
which doesn't include, f
oh, right, i did only one eighth to check and see if it was scaling
near linearly, as i couldn't even run profiling without python dying.
i have 400mb ram and 2ghz processor, on freebsd, so it shouldn't be
performance. i'll try your suggestions and see how it works.
--
http://mail.python.org/ma
this code here:
def wordcount(lines):
for i in range(len(lines)/8):
words = lines[i].split(" ")
if not locals().has_key("frequency"):
frequency = {}
for word in words:
if frequency.has_key(word):
frequency[word] += 1
so obvious! thank you for helping me there. i knew it was simple, i
just couldn't catch it.
--
http://mail.python.org/mailman/listinfo/python-list
i was working on implementing the original supermemo algorithm (see
http://www.supermemo.com/english/ol/sm2.htm for a description of it) in
a class, and i'd just finished up the first draft. it works for
repetitions one and two, but on repetition three (you must manually
increment item.reps.) or h