Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Visualization class: FC/PSD/TS/etc. #76

Open
tmorshed opened this issue Jun 7, 2023 · 8 comments
Open

Visualization class: FC/PSD/TS/etc. #76

tmorshed opened this issue Jun 7, 2023 · 8 comments
Assignees
Labels
feature Adding new functionality

Comments

@tmorshed
Copy link
Member

tmorshed commented Jun 7, 2023

Figure out the data structure.

  • Physiological analytics

  • Phase plane analysis

  • PLS method

@Andrew-Clappison
Copy link
Collaborator

Andrew-Clappison commented Aug 11, 2023

#101 was done
figure out if we want a plotting object or append as method to other object
next step is a proposed API for plotting

@P-Oveisi
Copy link
Collaborator

We can approach it in two ways:

  1. The visualization functions would be extra methods that we can add to data objects
  2. We could define a visualization object which would take in the data obj to be plotted + the representation we want (e.g., time series, PSD, FC mat, etc.) and the viz object will do the plotting.

I think the first option would make more sense if the data to be plotted isn't too complex. This would be similar to mne.evoked.plot() method in the MNE library.

In the case of more complex plots (for example 3D source localization) the second way would be more ideal. This is similar to the Brain object in mne (mne.viz.Brain).

What are people's thoughts? How do you think we should proceed?

@Andrew-Clappison
Copy link
Collaborator

John Recommendation: For simpler figures taking only a few lines of code then write them explicitly in examples, for more complex plots with many lines then have them encapsulated in methods/functions

@Andrew-Clappison
Copy link
Collaborator

Current focus to improve the figures in eg 003r and eg 004r

@P-Oveisi
Copy link
Collaborator

To do for Parsa

  1. look at the examples -> decide which ones need improvement
  2. Implement improvements as codes within the notebook itself
  3. Then determine which visualizations merit from being packaged as extra methods for each objects
  • (focus on example 3 and 4 visualizations)

@P-Oveisi
Copy link
Collaborator

Will make into MNE object to use MNE visualization funcitons.

Can also add the montage data to use .plot_joint() more comprehensive plots.

@P-Oveisi
Copy link
Collaborator

Added some code to generate clean-up visualizations:
image
image
image

However, having issues when trying to build the html files:


Extension error:
Here is a summary of the problems encountered when running the examples

Unexpected failing examples:
/external/rprshnas01/netdata_kcni/jglab/MemberSpaces/po/lab/repos/whobpyt_po_fork/examples/eg004r__fitting_JR_example.py failed leaving traceback:
Traceback (most recent call last):
  File "/external/rprshnas01/netdata_kcni/jglab/MemberSpaces/po/lab/repos/whobpyt_po_fork/examples/eg004r__fitting_JR_example.py", line 58, in <module>
    eeg_data_all = np.load(eeg_file)
  File "/external/rprshnas01/netdata_kcni/jglab/MemberSpaces/po/lab/envs/whobpyt/lib/python3.8/site-packages/numpy/lib/npyio.py", line 405, in load
    fid = stack.enter_context(open(os_fspath(file), "rb"))
FileNotFoundError: [Errno 2] No such file or directory: '../Tepit/eeg_data.npy'

Which seems to happen because the example data is being downloaded from a gdrive which doesn't have public access:
image

I think the folder is owned by @JohnWangDataAnalyst . Can you adjust the access please?

@Davi1990
Copy link
Collaborator

@P-Oveisi is going to submit the PR #135 on Wed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Adding new functionality
Projects
None yet
Development

No branches or pull requests

4 participants