route_eeg_activity.svg 12 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <?xml version="1.0" encoding="UTF-8" standalone="no"?><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" contentStyleType="text/css" height="905px" preserveAspectRatio="none" style="width:545px;height:905px;background:#FFFFFF;" version="1.1" viewBox="0 0 545 905" width="545px" zoomAndPan="magnify"><defs/><g><ellipse cx="304.25" cy="20" fill="#222222" rx="10" ry="10" style="stroke:#222222;stroke-width:1.0;"/><rect fill="none" height="546.2295" style="stroke:#000000;stroke-width:1.5;" width="523.25" x="11" y="40"/><path d="M77,40 L77,52.1201 L67,62.1201 L11,62.1201 " fill="none" style="stroke:#000000;stroke-width:1.5;"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="56" x="14" y="57.0439">获取波形</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="360" x="124.25" y="79.1201"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="340" x="134.25" y="102.8721">脑电设备连接【连接后,默认是波形模式】(eeg_device_connect)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="439" x="84.75" y="135.5088"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="419" x="94.75" y="159.2607">开始获取数据到后端buffer【每次拿delay_milliseconds】(start_receive_wave)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="440" x="84.25" y="191.8975"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="420" x="94.25" y="215.6494">开始从buffer拿数据【此api持续返回数据,每次拿1s】(get_wave_from_buffer)</text><polygon fill="#F1F1F1" points="290.25,248.2861,318.25,248.2861,330.25,260.2861,318.25,272.2861,290.25,272.2861,278.25,260.2861,290.25,248.2861" style="stroke:#181818;stroke-width:0.5;"/><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacing" textLength="28" x="290.25" y="265.3806">训练?</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacing" textLength="18" x="260.25" y="257.8691">yes</text><text fill="#000000" font-family="sans-serif" font-size="11" lengthAdjust="spacing" textLength="12" x="330.25" y="257.8691">no</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="274" x="53.5" y="282.2861"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="254" x="63.5" y="306.0381">设置输出bdf, 以保存数据(eeg_edf_set_header)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="296" x="42.5" y="338.6748"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="276" x="52.5" y="362.4268">前60s(resting_state_process),每次调用自动打标签</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="335" x="23" y="395.0635"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="315" x="33" y="418.8154">60~90s(eeg_psd_clf_and_csp_train),每次调用自动打标签</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="254" x="63.5" y="451.4521"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="234" x="73.5" y="475.2041">90s以后(eeg_csp_clf), 每次调用自动打标签</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="80" x="378" y="282.2861"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="60" x="388" y="306.0381">不保存数据</text><polygon fill="#F1F1F1" points="304.25,493.8408,316.25,505.8408,304.25,517.8408,292.25,505.8408,304.25,493.8408" style="stroke:#181818;stroke-width:0.5;"/><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="221" x="193.75" y="537.8408"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="201" x="203.75" y="561.5928">脑电数据模式关闭(eeg_mode_close)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="80" x="264.25" y="606.2295"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="60" x="274.25" y="629.9814">最好等一下</text><rect fill="none" height="200.2861" style="stroke:#000000;stroke-width:1.5;" width="283" x="162.75" y="652.6182"/><path d="M228.75,652.6182 L228.75,664.7383 L218.75,674.7383 L162.75,674.7383 " fill="none" style="stroke:#000000;stroke-width:1.5;"/><text fill="#000000" font-family="sans-serif" font-size="14" lengthAdjust="spacing" textLength="56" x="165.75" y="669.6621">获取阻抗</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="263" x="172.75" y="691.7383"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="243" x="182.75" y="715.4902">切换到阻抗模式(impedance_mode_connect)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="186" x="211.25" y="748.127"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="166" x="221.25" y="771.8789">获取阻抗数据(get_impedance)</text><rect fill="#F1F1F1" height="36.3887" rx="12.5" ry="12.5" style="stroke:#181818;stroke-width:0.5;" width="238" x="185.25" y="804.5156"/><text fill="#000000" font-family="sans-serif" font-size="12" lengthAdjust="spacing" textLength="218" x="195.25" y="828.2676">阻抗模式关闭(impedance_mode_close)</text><ellipse cx="304.25" cy="883.9043" fill="none" rx="11" ry="11" style="stroke:#222222;stroke-width:1.0;"/><ellipse cx="304.25" cy="883.9043" fill="#222222" rx="6" ry="6" style="stroke:#111111;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="115.5088" y2="135.5088"/><polygon fill="#181818" points="300.25,125.5088,304.25,135.5088,308.25,125.5088,304.25,129.5088" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="171.8975" y2="191.8975"/><polygon fill="#181818" points="300.25,181.8975,304.25,191.8975,308.25,181.8975,304.25,185.8975" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="190.5" y1="318.6748" y2="338.6748"/><polygon fill="#181818" points="186.5,328.6748,190.5,338.6748,194.5,328.6748,190.5,332.6748" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="190.5" y1="375.0635" y2="395.0635"/><polygon fill="#181818" points="186.5,385.0635,190.5,395.0635,194.5,385.0635,190.5,389.0635" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="190.5" y1="431.4521" y2="451.4521"/><polygon fill="#181818" points="186.5,441.4521,190.5,451.4521,194.5,441.4521,190.5,445.4521" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="278.25" x2="190.5" y1="260.2861" y2="260.2861"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="190.5" y1="260.2861" y2="282.2861"/><polygon fill="#181818" points="186.5,272.2861,190.5,282.2861,194.5,272.2861,190.5,276.2861" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="330.25" x2="418" y1="260.2861" y2="260.2861"/><line style="stroke:#181818;stroke-width:1.0;" x1="418" x2="418" y1="260.2861" y2="282.2861"/><polygon fill="#181818" points="414,272.2861,418,282.2861,422,272.2861,418,276.2861" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="190.5" y1="487.8408" y2="505.8408"/><line style="stroke:#181818;stroke-width:1.0;" x1="190.5" x2="292.25" y1="505.8408" y2="505.8408"/><polygon fill="#181818" points="282.25,501.8408,292.25,505.8408,282.25,509.8408,286.25,505.8408" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="418" x2="418" y1="318.6748" y2="505.8408"/><line style="stroke:#181818;stroke-width:1.0;" x1="418" x2="316.25" y1="505.8408" y2="505.8408"/><polygon fill="#181818" points="326.25,501.8408,316.25,505.8408,326.25,509.8408,322.25,505.8408" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="228.2861" y2="248.2861"/><polygon fill="#181818" points="300.25,238.2861,304.25,248.2861,308.25,238.2861,304.25,242.2861" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="517.8408" y2="537.8408"/><polygon fill="#181818" points="300.25,527.8408,304.25,537.8408,308.25,527.8408,304.25,531.8408" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="30" y2="79.1201"/><polygon fill="#181818" points="300.25,69.1201,304.25,79.1201,308.25,69.1201,304.25,73.1201" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="574.2295" y2="606.2295"/><polygon fill="#181818" points="300.25,596.2295,304.25,606.2295,308.25,596.2295,304.25,600.2295" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="728.127" y2="748.127"/><polygon fill="#181818" points="300.25,738.127,304.25,748.127,308.25,738.127,304.25,742.127" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="784.5156" y2="804.5156"/><polygon fill="#181818" points="300.25,794.5156,304.25,804.5156,308.25,794.5156,304.25,798.5156" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="642.6182" y2="691.7383"/><polygon fill="#181818" points="300.25,681.7383,304.25,691.7383,308.25,681.7383,304.25,685.7383" style="stroke:#181818;stroke-width:1.0;"/><line style="stroke:#181818;stroke-width:1.0;" x1="304.25" x2="304.25" y1="840.9043" y2="872.9043"/><polygon fill="#181818" points="300.25,862.9043,304.25,872.9043,308.25,862.9043,304.25,866.9043" style="stroke:#181818;stroke-width:1.0;"/><!--MD5=[6200e9217fc6eb72f84346e732e57400]
  2. @startuml
  3. start
  4. group 获取波形
  5. :脑电设备连接【连接后,默认是波形模式】(eeg_device_connect);
  6. :开始获取数据到后端buffer【每次拿delay_milliseconds】(start_receive_wave);
  7. :开始从buffer拿数据【此api持续返回数据,每次拿1s】(get_wave_from_buffer);
  8. if (训练?) then (yes)
  9. :设置输出bdf, 以保存数据(eeg_edf_set_header);
  10. :前60s(resting_state_process),每次调用自动打标签;
  11. :60~90s(eeg_psd_clf_and_csp_train),每次调用自动打标签;
  12. :90s以后(eeg_csp_clf), 每次调用自动打标签;
  13. else (no)
  14. :不保存数据;
  15. endif
  16. :脑电数据模式关闭(eeg_mode_close);
  17. end group
  18. :最好等一下;
  19. group 获取阻抗
  20. :切换到阻抗模式(impedance_mode_connect);
  21. :获取阻抗数据(get_impedance);
  22. :阻抗模式关闭(impedance_mode_close);
  23. end group
  24. stop
  25. @enduml
  26. PlantUML version 1.2022.7(Tue Aug 23 01:01:30 CST 2022)
  27. (GPL source distribution)
  28. Java Runtime: Java(TM) SE Runtime Environment
  29. JVM: Java HotSpot(TM) 64-Bit Server VM
  30. Default Encoding: GBK
  31. Language: zh
  32. Country: CN
  33. --></g></svg>