前言
簡述:因?yàn)樯w樓失敗導(dǎo)致代碼跑不出來,直接借用了別人的代碼,發(fā)現(xiàn)問題更多,于是踏入了解決環(huán)境配置的不歸路。目前決定先挖坑,記錄下來,以備日后使用。
原始目標(biāo):Adversarial Autoencoder 論文學(xué)習(xí)+代碼實(shí)現(xiàn)
遇到的問題:下載了兩份代碼(來源不同),但是都跑不出來,問題各異。
問題1(解決)
代碼來源:代碼1
問題描述:執(zhí)行代碼后python返回錯(cuò)誤
python錯(cuò)誤信息:‘TypeError: unsupported operand type(s) for +: "int" and "NoneType" while run python train.py
解決方法:見開發(fā)者github的issues
說明:將Lasagne更新到開發(fā)版本(0.2.dev1)即可
操作:按照官網(wǎng)的方法更新到Bleeding-edge version
簡要步驟說明:
在conda目錄下更新Theano和Lasagne
pip install --upgrade https://github.com/Theano/Theano/archive/master.zip
pip install --upgrade https://github.com/Lasagne/Lasagne/archive/master.zip
問題2(未解決)
代碼來源:代碼2
問題描述:缺少chainer模塊
當(dāng)前問題:安裝chainer模塊失敗。安裝使用命令:
pip install chainer -vvvv
安裝完成后,在控制臺下執(zhí)行python -c "import chainer"后,python直接顯示終止運(yùn)行(難以理解的bug)。
說明:這份代碼比較全,建議使用。