Hello
I have got a project in which I have to extract keywords given a URL. I would
like to know methods for extraction of keywords. Frequency of occurence is one;
but it seems naive. I would prefer something more robust. Please suggest.
Regards
Cross
--- news://freenews.netfront.net/ - comp
I'm just learning python. After changed it to a non-OOP program, it
works.
Thank you all for suggestions :)
On Mar 8, 1:38 pm, Benjamin Kaplan wrote:
> Is there any particular reason you're using processes and not threads?
> Functions that wait for stuff to happen in C land, such as I/O calls,
>
On Mon, Mar 7, 2011 at 8:32 PM, alex23 wrote:
> On Mar 8, 1:41 pm, alex23 wrote:
>> Good to see you finally admit that you're not a programmer. Have you
>> informed your clients yet? Or are you still learning Python on their
>> dime and crowd-sourcing the more difficult parts?
>
> I'd like to apo
On Mar 8, 1:41 pm, alex23 wrote:
> Good to see you finally admit that you're not a programmer. Have you
> informed your clients yet? Or are you still learning Python on their
> dime and crowd-sourcing the more difficult parts?
I'd like to apologise for this post. The OP is not the Victor I
though
Steven D'Aprano wrote:
> The question that needs to be asked is not "Is Python 3 fast?", but
> instead "Is Python 3 fast enough?".
I'm certainly not going to argue against that, I just don't find the
coding contortions used on sites like spoj.pl for performance gains to
be anything approximating
Victor Paraschiv wrote:
> What I conclude is that you, the programmers, don’t really care about
> those who are new to programming: for most people out of the
> programming world, I think it is simpler to be able to write: real(z),
> just as you write: sin(z), abs(z), (z)^2 etc.
Good to see you fi
On 08/03/2011 03:01, Tycho Andersen wrote:
Consider the following session:
Python 2.6.6 (r266:84292, Sep 15 2010, 16:22:56)
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
import re
p = re.compile("foo")
re.sub(p, "bar", "foobaz", flags=re.IGNORECASE
Consider the following session:
Python 2.6.6 (r266:84292, Sep 15 2010, 16:22:56)
[GCC 4.4.5] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import re
>>> p = re.compile("foo")
>>> re.sub(p, "bar", "foobaz", flags=re.IGNORECASE)
Traceback (most recent call las
Hi,
How do I make a downloaded file layerfx.py executable in Gimp? using
the Python console.
the layerfx.py is in the download folder
thanks
Francis
On 3/8/11, python-list-requ...@python.org
wrote:
> Send Python-list mailing list submissions to
> python-list@python.org
>
> To subscribe o
Hello, everyone:
I encouter a question when implementing a commmand line(shell).
I have implemented some commands, such as "start", "stop", "quit",
they are easily implemented by "do_start", "do_stop" and "do_quit".
there are no troubles.
But I want to implement some commands like these "
On Mon, Mar 7, 2011 at 7:47 PM, Vincent Ren wrote:
> Got it, thanks.
> But what should I do if I want to improve the efficiency of my
> program?
>
Is there any particular reason you're using processes and not threads?
Functions that wait for stuff to happen in C land, such as I/O calls,
release t
Steven D'Aprano writes:
>> L[0].append(5) # mutate L, in some reasonable sense of "mutate"
>
> You haven't mutated the tuple called "L". You've mutated its internal
> components, which are lists. If you wanted them to also be immutable, you
> should have used tuples :)
Obviously you are
On Mon, 07 Mar 2011 13:20:39 -0800, Paul Rubin wrote:
> Steven D'Aprano writes:
>> but I call that a feature, not a bug. If you want an immutable
>> constant, use a tuple, not a list.
>
> Nope:
>
> L = ([1,2],[3,4]) # tuple
> L[0].append(5) # mutate L, in some reasonable sense of "
Got it, thanks.
But what should I do if I want to improve the efficiency of my
program?
On Mar 8, 11:37 am, Robert Kern wrote:
> I'm afraid his response applies to this as well: you can't pass methods to
> pool.map() or any other such communication channel to your subprocesses.
--
http://mail
On 3/7/11 3:27 PM, Vincent Ren wrote:
On Mar 7, 9:21 pm, Jean-Michel Pichavant
wrote:
It's a mistake many beginners do, I don't understand why, but it's a
very common thing. RTFM should stand for "Read The Formidable (error)
Message" as well.
Your url is invalid, check your url definition.
JM
On 3/7/11 2:52 PM, Jon Herman wrote:
It really is exactly the same process, but sure. Below is my Matlab translation
of the python code I posted earlier, it functions at the increased accuracy I've
shown above.
k(:,1)=feval(deq, ti, x, mu);
for n = 2:1:13
nn=n-1;
@all and just in case.
Also see my TiRG project (since 2011-01-31):
http://sourceforge.net/projects/tirg/
It's for detecting and localizing textareas in raster graphics.
Among its files there is a python script -- absolutely working.
Enjoy to do with it whatever you like -- it's my public domain.
On Mon, Mar 7, 2011 at 6:12 PM, Danny Shevitz wrote:
>
>>
>> http://pypi.python.org/pypi/pymatlab/
>>
>> Cheers,
>> Chris
>
> I am on a mac. Does pymatlab support mac's? I tried the linux 64 bit egg
> (downloaded to my local machine) and got:
>
> macshevitz:~ dannyshevitz$ sudo easy_install
> pym
>
> http://pypi.python.org/pypi/pymatlab/
>
> Cheers,
> Chris
I am on a mac. Does pymatlab support mac's? I tried the linux 64 bit egg
(downloaded to my local machine) and got:
macshevitz:~ dannyshevitz$ sudo easy_install pymatlab-0.1.3-py2.6-linux-x86_64.
egg
Password:
Searching for pymatlab-
The main choices for arbitrary point precision seem to be mpmath (which is
pure python) and GMP (C++ but with python wrapper; GMP is heavily used in
academia)
Links:
http://code.google.com/p/mpmath/
http://gmpy.sourceforge.net/
Katie
--
CoderStack
http://www.coderstack.co.uk
The Software Devel
Now you're just muddying the terminology!
~/santa
On Mon, Mar 7, 2011 at 1:20 PM, Paul Rubin wrote:
> Steven D'Aprano writes:
> > but I call that a feature, not a bug. If you want an immutable constant,
> > use a tuple, not a list.
>
> Nope:
>
>L = ([1,2],[3,4]) # tuple
>L[0].append(
On Mon, Mar 7, 2011 at 1:58 PM, Danny Shevitz wrote:
> Howdy,
>
> I'm a long time python user but ran across something I have never needed to do
> before and don't know how to do it.
>
> The issue is that I need for my python script to call some matlab routines.
> Matlab is very expensive to start
Howdy,
I'm a long time python user but ran across something I have never needed to do
before and don't know how to do it.
The issue is that I need for my python script to call some matlab routines.
Matlab is very expensive to start running, so I only want to run it once. I also
want the changes
Thanks Terry! Of course, speed is not my main concern at this point and I'm
more worried about precision...would you have some input on this discussion?
:)
Jon
On Mon, Mar 7, 2011 at 2:35 PM, Terry Reedy wrote:
> On 3/7/2011 1:59 PM, Jon Herman wrote:
>
>> And for the sake of completeness, th
On 3/7/2011 1:59 PM, Jon Herman wrote:
And for the sake of completeness, the derivative function I am calling
from my integrator (this is the 3 body problem in astrodynamics):
def F(mu, X, ti):
r1= pow((pow(X[0]+mu,2)+pow(X[1],2)+pow(X[2],2)),0.5)
x0 = X[0]; x1 = X[1]; x2 = X[2]
On Mar 7, 9:21 pm, Jean-Michel Pichavant
wrote:
> It's a mistake many beginners do, I don't understand why, but it's a
> very common thing. RTFM should stand for "Read The Formidable (error)
> Message" as well.
> Your url is invalid, check your url definition.
>
> JM
I've fixed that problem. Bu
Steven D'Aprano writes:
> but I call that a feature, not a bug. If you want an immutable constant,
> use a tuple, not a list.
Nope:
L = ([1,2],[3,4]) # tuple
L[0].append(5) # mutate L, in some reasonable sense of "mutate"
--
http://mail.python.org/mailman/listinfo/python-list
On 3/7/2011 1:12 PM, Victor Paraschiv wrote:
Well, thank you all for being honest ☺
What I conclude is that you, the programmers, don’t really care about
those who are new to programming:
Whereas you exhibit your care for humanity by casually slandering those
who offer you a gift. Grow up. Se
On 3/7/2011 1:26 PM, Ian wrote:
On 06/03/2011 13:56, Victor Subervi wrote:
gmail, for whatever reason, filters out emails send to the same
address from which they are sent.
Its possibly a protection against circular forwarding.
Or spam. Many spam messages sent to me have me as sender.
--
Ter
On 7 Mar, 09:30, Chris Rebert wrote:
> You see a tree, I see a database
> (http://docs.python.org/library/sqlite3.html):
>
> +--+-+-+---+
> | Manufacturer | Model | MPG | Price |
> +--+-+-+---+
> | Ford | Taurus | ... | $... |
>
On 3/7/2011 12:49 PM, Mathew Coyle wrote:
Everything seems to roll along fine, a few tweaks are still needed, but
an issue I cannot resolve has come up. It seems that the checklist items
are being selected and added twice to the list, once for a mouse button
click, and again for a mouse button r
It really is exactly the same process, but sure. Below is my Matlab
translation of the python code I posted earlier, it functions at the
increased accuracy I've shown above.
k(:,1)=feval(deq, ti, x, mu);
for n = 2:1:13
nn=n-1;
Xtemp1 = 0.0;
for j = 1:1:
Is this the Jeff Collins that worked at the Skunk works in the early 1990s?
--
http://mail.python.org/mailman/listinfo/python-list
>>> On Fri, Mar 4, 2011 at 2:32 PM, Jon Herman wrote:
I am new to the Python language and writing a Runge-Kutta-Fellberg 7(8)
integrator in Python, which requires an extreme numerical precision for my
particular application. Unfortunately, I can not seem to attain it.
The
On 3/7/2011 11:43 AM, Victor Paraschiv wrote:
Hi and please help me understand if it is a bug, or..,as someone said,
there's a 'bug' in my understanding:
(Python 3.2 (r32:88445, Feb 20 2011, 21:29:02) [MSC v.1500 32 bit
(Intel)] on win32) (windows vista, the regular windows python installer)
It's
On 3/7/2011 4:50 AM, Bob Fnord wrote:
I want a portable data file (can be moved around the filesystem
or copied to another machine and used),
Used only by Python or by other software?
Would a database in a file have any advantages over a file made
by marshal or shelve?
If you have read the
On 3/7/2011 6:24 AM, southof40 wrote:
Hi - I've got some code which uses array (http://docs.python.org/
library/array.html) to store charcters read from a file (it's not my
code it comes from here http://sourceforge.net/projects/pygold/)
The read is done, in GrammarReader.py, like this ...
And for the sake of additional completeness (I'm sorry I didn't think of all
this in one go): my derivative function in Python produces results that
agree with MATLAB to order e-16 (machine precision), so the error is
definitely building up in my integrator.
On Mon, Mar 7, 2011 at 11:59 AM, Jon
And for the sake of completeness, the derivative function I am calling from
my integrator (this is the 3 body problem in astrodynamics):
def F(mu, X, ti):
r1= pow((pow(X[0]+mu,2)+pow(X[1],2)+pow(X[2],2)),0.5)
r2= pow((pow(X[0]+mu-1,2)+pow(X[1],2)+pow(X[2],2)),0.5)
Ax= X[0]+2*X[4]-(1-
On 06/03/2011 13:56, Victor Subervi wrote:
gmail, for whatever reason, filters out emails send to the same
address from which they are sent.
Its possibly a protection against circular forwarding.
Ian
--
http://mail.python.org/mailman/listinfo/python-list
Victor Paraschiv wrote:
Well, thank you all for being honest ☺
What I conclude is that you, the programmers, don’t really care about
those who are new to programming: for most people out of the
programming world, I think it is simpler to be able to write: real(z),
just as you write: sin(z
Sorry Robert, I'd missed your post when I just made my last one. The output
I am getting in Python looks as follows:
array([ 9.91565050e-01, 1.55680112e-05, -1.53258602e-05,
-5.75847623e-05, -9.64290960e-03, -8.26333458e-08])
This is the final state vector, consisting of 6 states (p
I'm starting to run out of ideas of what to do...I've imported the true
division (I'm using Python 2.7) to make sure I wasn't accidentally using any
integers but the results remain identical, so it's not a division problem.
I've copied the loop I'm running below, is there any mathematical operation
Well, thank you all for being honest ☺
What I conclude is that you, the programmers, don’t
really care about those who are new to programming: for most people out of the
programming world, I think it is simpler to be able to write: real(z), just as
you write: sin(z), abs(z), (z)^2 etc.
Hi all,
I am trying to create a checklist which allows users to select a specific
feature of a dataset in a database, and export that feature out of the database
to their PC. This is my first GUI attempt, and I don't imagine my issue is too
complicated, mostly just my inexperience.
Everything
Chris
2011/3/7 Rogério Luz
> Chris, Thanks a lot for your explanation, I got it
>
> class MyClass:
> #class variables
>
> teste = 0
> nome = None
> lista = ["default"]
>
> def __init__(self):
> #instance variables
> self.lista = MyClass.lista # if I still wa
On Mon, Mar 7, 2011 at 8:38 AM, Rogerio Luz wrote:
> Hi All
>
> I'd like to pickle an object instance with all values. So I
> instanciate myClass and set some values including a list with more
> values (in the __init__), then dump to file. I realized that the
> pickled object don't saved my new li
Hi and please help me understand if it is a bug, or..,as someone said, there's
a 'bug' in my understanding:
(Python 3.2 (r32:88445, Feb 20 2011, 21:29:02) [MSC v.1500 32 bit (Intel)] on
win32) (windows vista, the regular windows python installer)
It's about the following code:
while True:
s
Hi All
I'd like to pickle an object instance with all values. So I
instanciate myClass and set some values including a list with more
values (in the __init__), then dump to file. I realized that the
pickled object don't saved my new list values (saved only the
"default" value) but saved a String a
On 2011-03-05 12:05:43 -0800, Paul Rubin said:
Ravi writes:
I can extend dictionary to allow for the my own special look-up
tables. However now I want to be able to define multidimensional
dictionary which supports look-up like this:
d[1]['abc'][40] = 'dummy'
Why do that anyway? You can us
On 05/03/2011 01:56, Bob Fnord wrote:
Any comments, suggestions?
No but I have a bunch of pseudo-questions :-)
What version of python are you using? How about your OS and bitspace
(32/64)? Have you also tried using the non-c pickle module? If the data
is very simple in structure, perhaps s
There is also scikit learn, that isn't mentionned on that list. It has
a few clustering algorithms (k means, affinity propagation, mean
shift):
you can find the documentation here :
http://scikit-learn.sourceforge.net/modules/clustering.html
Thanks,
Nelle
On 7 March 2011 01:14, Miki Tebeka wrote
n00m wrote:
> But funny thing takes place.
> At first thought it's a false-positive: some modern South East
> Asian town and a lake somewhere in Russia, more than 100 years
> ago. Nothing similar in them?
>
> On both pics we see:
> -- a lot of water on foreground;
> -- a lot of blue sky at sunny
Bob Fnord wrote:
> I want a portable data file (can be moved around the filesystem
> or copied to another machine and used), so I don't want to use
> mysql or postgres. I guess the "sqlite" approach would work, but
> I think it would be difficult to turn the tuples of strings and
> lists of string
On Mar 7, 2011 6:35 AM, "Victor Paraschiv" wrote:
>
> Hi everyone
> i understood that the goal of Python is to make programing easy (of
course, powerful at the same time).
> I think one way to do it is to eliminate unnecessary syntax exceptions.
One is the following:
> for a complex number "z", to
On Mon, 2011-03-07 at 03:33 -0800, Victor Paraschiv wrote:
> Hi everyone
> i understood that the goal of Python is to make programing easy (of
> course, powerful at the same time).
> I think one way to do it is to eliminate unnecessary syntax
> exceptions. One is the following:
> for a complex numb
So, my current very strict definition of similarity is:
---
2 pics are similar if my script gives for them value < 20%,
otherwise the pics are not similar.
---
It is left to study possi
On Mar 7, 2:54 pm, Grigory Javadyan
wrote:
> Just admit that your algorithm doesn't work that well already :-)
> Or give a solid formal definition of "similarity" and prove that your
> algo works with that definition.
>
> On Mon, Mar 7, 2011 at 4:22 PM, n00m wrote:
>
> > In short,
> > the notion
Just admit that your algorithm doesn't work that well already :-)
Or give a solid formal definition of "similarity" and prove that your
algo works with that definition.
On Mon, Mar 7, 2011 at 4:22 PM, n00m wrote:
>
> In short,
> the notion of similarity can be speculated about just endlessly.
>
-
On Mar 6, 7:54 pm, n00m wrote:
> If someone will encounter 2 apparently unrelated pics
> but for which ImSim gives value of their mutual diff.
> *** less than 20% *** please emailed them to me.
Never mind, people.
I've found such a pair of images in my .zipped project.
It's "sky1.jpg" and "lake1.
On 07/03/2011 11:33, Victor Paraschiv wrote:
Hi everyone
i understood that the goal of Python is to make programing easy (of
course, powerful at the same time).
I think one way to do it is to eliminate unnecessary syntax
exceptions. One is the following:
for a complex number "z", to get the rea
southof40 wrote:
> ...
> result = array('u')
> ...
> ... and results in the error"TypeError: array item must be unicode
> character" is raised (full stack trace at bottom) .
> ...
> Can anyone make a suggestion as to the best way to allow the array
> object to accept what is in essence a bi
Hi everyone
i understood that the goal of Python is to make programing easy (of course,
powerful at the same time).
I think one way to do it is to eliminate unnecessary syntax exceptions. One is
the following:
for a complex number "z", to get the real and imaginary part, you type:
"z.real" and
Hi - I've got some code which uses array (http://docs.python.org/
library/array.html) to store charcters read from a file (it's not my
code it comes from here http://sourceforge.net/projects/pygold/)
The read is done, in GrammarReader.py, like this ...
def readString(self, maxsize = -1):
Manjunath N wrote:
> Hello users,
> I'm quite new to python programming. I need help in manually sorting
> a
> list which is shuffled. The problem i'm facing is with respect to last
> element in the list when checking the condition using if statement. Below
> I have pasted my code. The
Vincent Ren wrote:
Hello, everyone, recently I am trying to learn python's
multiprocessing, but
I got confused as a beginner.
[SNIP]
httplib.InvalidURL: nonnumeric port: ''
Regards
Vincent
It's a mistake many beginners do, I don't understand why, but it's a
very common thing. RTFM should
MRAB wrote:
> On 05/03/2011 01:56, Bob Fnord wrote:
> > I'm using python to do some log file analysis and I need to store
> > on disk a very large dict with tuples of strings as keys and
> > lists of strings and numbers as values.
> >
> > I started by using cPickle to save the instance of the cla
Manjunath N, 07.03.2011 09:48:
I'm quite new to python programming. I need help in manually sorting a
list which is shuffled.
Why do you want to do that? Is this a homework assignment, or are you just
looking for an example task to get used to the language?
The usual way to sort a lis
Hello users,
I'm quite new to python programming. I need help in manually sorting a
list which is shuffled. The problem i'm facing is with respect to last
element in the list when checking the condition using if statement. Below I
have pasted my code. The code is below is not yet done, at fi
On Sun, Mar 6, 2011 at 11:06 PM, Javier wrote:
> Looks a good idea. I use this kind of "recursive dicts" to represent
> tree like datastruct in python. Like:
>
> car["ford"]["taurus"]["price"]=...
> car["toyota"]["corolla"]["mpg"]=...
> car["toyota"]["corolla"]["price"]=...
>
> Does anybody hav
While some may see this thread as troll candy, others may not.
We want cake. And we need to eat it.
Doing a lot of instrument control and data acquisition stuff.
And a short dev period has same importance as short run time.
As for the safety of those that dwell under and walk over
bridges, y
Dan Stromberg, 07.03.2011 03:47:
On Sun, Mar 6, 2011 at 10:07 AM, Arthur Mc Coy wrote:
You know, they are still using SVN, they are
very loosely coupled to the past.
about SVN: I'm not sure it's really dying.
I hope it will.
Yes, a lot of distributed
development has moved off of SVN, and
72 matches
Mail list logo