EEGrunt:未定义错误名称

2024-05-14 09:42:56 发布

您现在位置:Python中文网/ 问答频道 /正文

这可能是一个非常初级的错误。你知道吗

上面写着:

 NameError in line 16 that'start' is not defined.

我正在为OpenBCI运行一个名为EEGrunt的代码,用于分析脑电图数据。我不知道该如何定义这个特定程序的开始或停止

import EEGrunt
source = 'openbci'
path = 'C:/Users/Vedant/Desktop/Pygaze/OpenBCI_2/application.windows64/SavedData/'
filename = 'OpenBCI-RAW-2016-11-28_16-23-14.txt'
session_title = "OpenBCI EEGrunt Test Data"
EEG = EEGrunt.EEGrunt(path, filename, source, session_title)
EEG.plot = 'show'
EEG.load_data()
for channel in EEG.channels:
   EEG.load_channel(channel)
   print("Processing channel "+ str(EEG.channel))
   EEG.remove_dc_offset()
   EEG.notch_mains_interference()
   EEG.signalplot()
   EEG.get_spectrum_data()
   EEG.data = EEG.bandpass(start, stop)
   EEG.spectrogram()
   EEG.plot_band_power(8,12,"Alpha")
   EEG.plot_spectrum_avg_fft()
   EEG.showplots()

Tags: pathinsourcedataplottitlesessionchannel
1条回答
网友
1楼 · 发布于 2024-05-14 09:42:56

我也有同样的问题。据项目业主介绍:

That line should be commented out by default.

The bandpass function takes the data and applies a butterworth bandpass filter. The start and stop arguments set the frequency range to bandpass, in Hertz. But it’s optional: most of the time it’s not used, and it shouldn’t stop the program from running.

https://github.com/curiositry/EEGrunt/issues/11

相关问题 更多 >

    热门问题