2016-08-23 51 views
4

我試圖按照brain observatory ipython notebook的示例。艾倫大腦研究所 - 大腦天文臺示例

但是,我被卡住加載下面的nwb文件。

from allensdk.core.brain_observatory_cache import BrainObservatoryCache 
boc = BrainObservatoryCache(manifest_file='boc/manifest.json') 

data_set = boc.get_ophys_experiment_data(501940850) # problem here 

因此,我打開nwb文件HDFview

所有的大腦天文臺nwb文件都沒有打開,除了502376461.nwb

當我試圖在allen的ipython筆記本例子中打開502376461.nwb時,它工作正常!但其他人(501940850,503820068 ...)失敗如上。

+2

它以什麼方式失敗? –

+0

錯誤消息,plz – Justas

+1

IOError:無法打開文件(截斷文件:eof = 82280448,sblock-> base_addr = 0,stored_eoa = 204046519) –

回答

2

從GitHub總結螺紋:

https://github.com/AllenInstitute/AllenSDK/issues/22

文件已部分下載的或以某種方式損壞。在下載過程中沒有報告任何異常,所以urllib一定沒有注意到問題。

AllenSDK開發人員正在研究某種文件一致性檢查和/或不同的HTTP庫。

https://github.com/AllenInstitute/AllenSDK/issues/28

如果別人遇到這種情況,您可以刪除錯誤的文件,並重新運行下載功能(BrainObservatoryCache.get_ophys_experiment_data)。文件被下載到BrainObservatoryCache manifest file的子目錄中,如果未指定,該目錄默認爲當前工作目錄。