Pickle error, vista 64, 2.61b

Jules Stevenson lists at js3d.co.uk
Fri Mar 20 17:30:37 CET 2009


Hi List,

I'm getting the following error from the pickle module:

F = os.path.join(render_map_path,'sizes.pkl')
Pickle_mat = pickle.load(f)

# ERROR : Traceback (most recent call last):
#   File "<Script Block >", line 398, in unity_bake_Execute
#     pickle_mat = pickle.load(f)
#   File "C:\Python26\Lib\pickle.py", line 1370, in load
#     return Unpickler(file).load()
#   File "C:\Python26\Lib\pickle.py", line 841, in __init__
#     self.readline = file.readline
# AttributeError: 'unicode' object has no attribute 'readline'


The contents of the pickle file look reasonable enough to me and are this:

(dp0
S'bush01'
p1
F306124.11115222942
sS'bush02'
p2
F826622.2397976605
sS'bullrushes'
p3
F0.00096709878539282879
sS'shed'
p4
F105053.3676265644
sS'fern'
p5
F354183.63406337635
sS'cone'
p6
F3069.3157248808811
sS'Oak_TexCB'
p7
F141267016.42824671
sS'ivy'
p8
F6007.0730751630317
sS'Overgrowth'
p9
F7447406.5150470743
sS'CowParsley'
p10
F302618.24888817599
sS'Ash_TexCB'
p11
F89057086.743352637
sS'dafodil'
p12
F26949.206947133262
sS'ChainFenceCB'
p13
F1293397.3884266701
sS'Cliff'
p14
F29430821.604373053
sS'bill02'
p15
F61971.92733123355
sS'Rock_nc'
p16
F546534.3371239237
sS'FenceTexCB'
p17
F90418.507786936025
sS'rock_moss'
p18
F647224.21912811685
sS'rock'
p19
F746967.91939543572
sS'grass'
p20
F123596.83454860286
sS'WussyAsh'
p21
F55487494.215827979
sS'Ground'
p22
F487982632.77081424
s.

This is using python 2.6b, active python via a 3d app [xsi].

Any help much appreciated

Jules




More information about the Python-list mailing list