Open liulangdiqiu2027 opened 6 months ago
我也遇到了这个问题,你解决这个问题了吗?希望能分享一下解决办法
把3.7的python换成python2.7版本就没问题了,咱们的版本太高了。
---Original--- From: @.> Date: Tue, Apr 2, 2024 15:21 PM To: @.>; Cc: @.**@.>; Subject: Re: [taoxugit/AttnGAN] TypeError: Cannot handle this data type: (1,1, 48), |u1 (Issue #114)
我也遇到了这个问题,你解决这个问题了吗?希望能分享一下解决办法
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
run with python3.7
Traceback (most recent call last): File "pretrain_DAMSM.py", line 279, in
dataset.ixtoword, image_dir)
File "pretrain_DAMSM.py", line 130, in train
ixtoword, attn_maps, att_sze)
File "/home/chenxi/YQG/SCMC-master/AttnGAN-master/code/miscc/utils.py", line 147, in build_super_images
PIL_att = Image.fromarray(np.uint8(one_map))
File "/home/chenxi/.conda/envs/lxtpytorch/lib/python3.7/site-packages/PIL/Image.py", line 3083, in fromarray
raise TypeError(msg) from e
TypeError: Cannot handle this data type: (1, 1, 48), |u1
这个是python版本问题吗,请问有人知道如何解决吗 Is this a python version issue and does anyone know how to fix it?