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

UserWarning: Warning: converting a masked element to nan. #134

Open
fbenghi opened this issue Sep 17, 2018 · 1 comment
Open

UserWarning: Warning: converting a masked element to nan. #134

fbenghi opened this issue Sep 17, 2018 · 1 comment

Comments

@fbenghi
Copy link

fbenghi commented Sep 17, 2018

Hello Peter,

I train the SOM and when I call view_component_planes(), the figures are completely blank an the console prints the following warnings:

matplotlib\image.py:405: UserWarning: Warning: converting a masked element to nan.
dv = (np.float64(self.norm.vmax) -
matplotlib\image.py:406: UserWarning: Warning: converting a masked element to nan.
np.float64(self.norm.vmin))
matplotlib\image.py:413: UserWarning: Warning: converting a masked element to nan.
a_min = np.float64(newmin)
matplotlib\image.py:418: UserWarning: Warning: converting a masked element to nan.
a_max = np.float64(newmax)
matplotlib\colors.py:916: UserWarning: Warning: converting a masked element to nan.
dtype = np.min_scalar_type(value)
\numpy\ma\core.py:716: UserWarning: Warning: converting a masked element to nan.
data = np.array(a, copy=False, subok=subok)

I followed the Planar Maps example, only changing the original dataset for my own data and even so it doesn't work. My dataset has 268 columns.

When I try to run it with only three columns (as in the example, it worked)

Is there any known issue related to the number of columns?

@peterwittek
Copy link
Owner

This should work, but bear in mind that you will have 268 component planes (assuming you mean features by columns).

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

No branches or pull requests

2 participants