Yeah, right. I didn't think about that. I'll check in the source how the data
is stored.
Thanks for helping sort it all out.
--
http://mail.python.org/mailman/listinfo/python-list
I am using the nltk.classify.MaxEntClassifier. This object has a set of labels,
and a set of probabilities: P(label | features). It modifies this probability
given data. SO for example, if you tell this object that the label L appears
60% of the time with the feature F, then P(L | F) = 0.6.
Omer Korat animus.partum.univer...@gmail.com wrote:
I am using the nltk.classify.MaxEntClassifier. This object has a set of
labels, and a set of probabilities: P(label | features). It modifies
this probability given data. SO for example, if you tell this object
that the label L appears 60% of
Omer Korat animus.partum.univer...@gmail.com wrote:
So it means pickle doesn't ever save the object's values, only how it was
created?
You say that as though there were a difference between the two. There
isn't. An object is just a dictionary of values. If you set an object
member to a
Hi all,
I'm working on a project in Python 2.7. I have a few large objects, and I want
to save them for later use, so that it will be possible to load them whole from
a file, instead of creating them every time anew. It is critical that they be
transportable between platforms. Problem is,
Omer Korat wrote:
I'm working on a project in Python 2.7. I have a few large objects, and I
want to save them for later use, so that it will be possible to load them
whole from a file, instead of creating them every time anew. It is
critical that they be transportable between platforms.
You're probably right in general, for me the 3.3 and 2.7 pickles definitely
don't work the same:
3.3:
type(pickle.dumps(1))
type 'bytes'
2.7:
type(pickle.dumps(1, pickle.HIGHEST_PROTOCOL))
type 'str'
As you can see, in 2.7 when I try to dump something, I get useless string. Look
what I gen
On 12/27/2012 07:05 AM, Omer Korat wrote:
You're probably right in general, for me the 3.3 and 2.7 pickles definitely
don't work the same:
3.3:
type(pickle.dumps(1))
type 'bytes'
2.7:
type(pickle.dumps(1, pickle.HIGHEST_PROTOCOL))
type 'str'
That is the same. In 2.7, str is made up of
I see. In that case, all I have to do is make sure NLTK is available when I
load the pickled objects. That pretty much solves my problem. Thanks!
So it means pickle doesn't ever save the object's values, only how it was
created?
Say I have a large object that requires a lot of time to train on
On Fri, Dec 28, 2012 at 12:16 AM, Omer Korat
animus.partum.univer...@gmail.com wrote:
I see. In that case, all I have to do is make sure NLTK is available when I
load the pickled objects. That pretty much solves my problem. Thanks!
So it means pickle doesn't ever save the object's values, only
On 12/27/2012 7:34 AM, Dave Angel wrote:
Perhaps you'd rather see it in the Python docs.
http://docs.python.org/2/library/pickle.html
http://docs.python.org/3.3/library/pickle.html
pickle http://docs.python.org/2/library/pickle.html#module-picklecan
save and restore class instances
11 matches
Mail list logo