[visionegg] newby questions

  • From: keith godfrey <keithgodfrey@xxxxxxxxxxxxxxxxxxxxx>
  • To: visionegg@xxxxxxxxxxxxx
  • Date: Mon, 16 Aug 2004 12:46:29 -0700

Greetings,
I'm trying to customize the EPhys client/server to accommodate some in-house feature requests and have run into what appears to be a bug. Additionally, I continue to scratch my head on how to accomplish something under Ephys that was trivial to accomplish in the stand-alone scripts. Any feedback would be appreciated. If these issues have been addressed before, please forgive my use of bandwidth.


The "bug":
What I'm trying to do is save a configuration file that has sequence information in it. While I am able to save configuration files w/o sequence information, when I add a sequence and then try to save, whether it's a single sequence or a series of them, I get an error about "a class that defines __slots__ without defining __getstate__ cannot be pickled" (an entire traceback is listed below - this trace is from linux, but an equivalent is produced on Win2K). Being new to Python, I really don't know how much work is involved in "fixing" this. Is this fixable? Is this a fact of life? How can one save a configuration file with this type of information embedded?


The "scratch my head" issue:
I've created an m-sequence generator using the demo script visual_jitter.py as a template and this worked fine. Unfortunately, none of the EPhys stimuli are based on drawing images based on pixel data, and I've as yet been unable to "steal" the methods used in visual_jitter and apply them to the EPhys framework. If anyone has any suggestions or demo code that might accomplish this, I'd be forever grateful (well, maybe not forever grateful, but at least grateful for a long time :-)


Many thanks,
Keith

---------------------------------

Traceback (most recent call last):
File "/usr/lib/python2.3/lib-tk/Tkinter.py", line 1345, in __call__
return self.func(*args)
File "/usr/lib/python2.3/site-packages/VisionEgg/PyroApps/EPhysGUI.py", line 1083, in save_config
pickle.dump( save_dict, fd )
File "/usr/lib/python2.3/pickle.py", line 1382, in dump
Pickler(file, protocol, bin).dump(obj)
File "/usr/lib/python2.3/pickle.py", line 231, in dump
self.save(obj)
File "/usr/lib/python2.3/pickle.py", line 293, in save
f(self, obj) # Call unbound method with explicit self
File "/usr/lib/python2.3/pickle.py", line 663, in save_dict
self._batch_setitems(obj.iteritems())
File "/usr/lib/python2.3/pickle.py", line 677, in _batch_setitems
save(v)
File "/usr/lib/python2.3/pickle.py", line 293, in save
f(self, obj) # Call unbound method with explicit self
File "/usr/lib/python2.3/pickle.py", line 614, in save_list
self._batch_appends(iter(obj))
File "/usr/lib/python2.3/pickle.py", line 629, in _batch_appends
save(x)
File "/usr/lib/python2.3/pickle.py", line 293, in save
f(self, obj) # Call unbound method with explicit self
File "/usr/lib/python2.3/pickle.py", line 739, in save_inst
save(stuff)
File "/usr/lib/python2.3/pickle.py", line 293, in save
f(self, obj) # Call unbound method with explicit self
File "/usr/lib/python2.3/pickle.py", line 663, in save_dict
self._batch_setitems(obj.iteritems())
File "/usr/lib/python2.3/pickle.py", line 677, in _batch_setitems
save(v)
File "/usr/lib/python2.3/pickle.py", line 313, in save
rv = reduce(self.proto)
File "/usr/lib/python2.3/copy_reg.py", line 76, in _reduce_ex
raise TypeError("a class that defines __slots__ without "
TypeError: a class that defines __slots__ without defining __getstate__ cannot be pickled


======================================
The Vision Egg mailing list
Archives: //www.freelists.org/archives/visionegg
Website: http://www.visionegg.org/mailinglist.html

Other related posts: