You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using NumPy 1.18.4 and Matplotlib 3.2.1. Python version is 3.8.3. Mac OS X Catalina although I doubt this issue is platform dependent.
This looks like the derived value for num, using x_div+1, causes the error, likely because x_div is a float. NumPy is probably no longer doing an automatic type conversion. Anyhow, that's an assumption at this point.
~/fusion/prod/lib/python3.8/site-packages/smithplot/smithaxes.py in cla(self)
475
476 for grid in ['major', "minor"]:
--> 477 self.grid(b=self._get_key("grid.%s.enable" % grid), which=grid)
478
479 def _set_lim_and_transforms(self):
~/fusion/prod/lib/python3.8/site-packages/smithplot/smithaxes.py in grid(self, b, which, fancy, dividers, threshold, **kwargs)
1062 x_div, y_div = d_mat[i, k]
1063
-> 1064 for xs in np.linspace(x0, x1, x_div + 1)[1:]:
1065 x_lines.append([xs, y0, y1])
1066 x_lines.append([xs, -y1, -y0])
<__array_function__ internals> in linspace(*args, **kwargs)
~/fusion/prod/lib/python3.8/site-packages/numpy-1.18.4-py3.8-macosx-10.15-x86_64.egg/numpy/core/function_base.py in linspace(start, stop, num, endpoint, retstep, dtype, axis)
117 num = operator.index(num)
118 except TypeError:
--> 119 raise TypeError(
120 "object of type {} cannot be safely interpreted as an integer."
121 .format(type(num)))
TypeError: object of type <class 'numpy.float64'> cannot be safely interpreted as an integer.
The text was updated successfully, but these errors were encountered:
This is the bug fixed both with PR #27 and #28.
If you want to use it, since it was not merged, you can install it from my github branch (where I applied #27 ).
Using NumPy 1.18.4 and Matplotlib 3.2.1. Python version is 3.8.3. Mac OS X Catalina although I doubt this issue is platform dependent.
This looks like the derived value for num, using x_div+1, causes the error, likely because x_div is a float. NumPy is probably no longer doing an automatic type conversion. Anyhow, that's an assumption at this point.
The text was updated successfully, but these errors were encountered: