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

Warnings in DirectionalVariogram #69

Open
mmaelicke opened this issue Feb 10, 2021 · 0 comments
Open

Warnings in DirectionalVariogram #69

mmaelicke opened this issue Feb 10, 2021 · 0 comments
Labels
Milestone

Comments

@mmaelicke
Copy link
Owner

mmaelicke commented Feb 10, 2021

Hey @redhog
I get some warnings in the new code in DirectionalVariogram

scikit-gstat/skgstat/DirectionalVariogram.py:343: RuntimeWarning: invalid value encountered in true_divide
  pos_angles = np.arccos(scalar / self._euclidean_dist)
scikit-gstat/skgstat/DirectionalVariogram.py:637: RuntimeWarning: invalid value encountered in greater
  absdiff = np.where(absdiff > np.pi, absdiff - np.pi, absdiff)
scikit-gstat/skgstat/DirectionalVariogram.py:638: RuntimeWarning: invalid value encountered in greater
  absdiff = np.where(absdiff > np.pi / 2, np.pi - absdiff, absdiff)
scikit-gstat/skgstat/DirectionalVariogram.py:640: RuntimeWarning: invalid value encountered in less_equal
  in_tol = absdiff <= np.radians(self.tolerance / 2)
scikit-gstat/skgstat/DirectionalVariogram.py:641: RuntimeWarning: invalid value encountered in greater_equal
  in_band = self.bandwidth / 2 >= np.abs(dists * np.sin(np.abs(angles + np.radians(self.azimuth))))

There seems to be a problem with either some undefined state, which we forgot to set in preprocessing, or a missing call to preprocessing.
The second option are np.NaN values somewhere in one of the strings.

The Warnings do not pop up if you run the init a second time.

Do you have any clue right now, where this could be caused?

Edit: From what I can tell, the instance is nevertheless working as expected...

@mmaelicke mmaelicke added the bug label Feb 10, 2021
@mmaelicke mmaelicke added this to the Version 0.4 milestone Feb 10, 2021
@mmaelicke mmaelicke modified the milestones: Version 0.5, Version 0.6 Apr 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant