numpy
Here are 6,468 public repositories matching this topic...
-
Updated
Sep 27, 2020 - Jupyter Notebook
-
Updated
Jul 24, 2020 - Python
The main __init__.pyi file currently contains a module-level __getattr__() function and
,while quite convenient due to the incomplete nature of the stubs, its use is rather unsafe:
any getattr(numpy, str(...)) operation is currently considered valid by static type checkers.
For this reason a set of placeholder stubs was recently added to generic/ndarray (https://github.com/numpy/
-
Updated
Oct 19, 2019
-
Updated
Jul 9, 2020 - Python
-
Updated
Sep 27, 2019 - Jupyter Notebook
When merging a dask dataframe, the resulting index is duplicated - seems to be because of the number of partitions. See example below:
import pandas as pd
import dask.dataframe as dd
a = dd.from_pandas(pd.DataFrame({'a': [1,2,3,4]}), npartitions=2)
b = pd.DataFrame({'a': [1,2,3,4], 'b': [2,3,4,5]})
a.merge(b, on='a').compute()Returns
| a | b |
|---|
|
-
Updated
Sep 6, 2020 - Python
-
Updated
Sep 22, 2019 - Python
-
Updated
Jul 5, 2020 - Python
- I have tried using the latest released version of Numba
- I have included below a minimal working reproducer
In trying to replace numpy's setxor1d (which is unfortunately not supported by Numba), I came across an error that does occur for (integer) ndarrays but not for lists.
In my case the setxor1d can be replaced by [i for i in a if i not in b], but for the sake of testing, here i
-
Updated
Aug 17, 2020 - Python
-
Updated
Sep 28, 2020 - Python
-
Updated
Sep 28, 2020 - Python
-
Updated
Feb 6, 2020
Well, Gumbel Distribution is magical. Basically, given a sequence of K logits, i.e., "\log a_1, \log a_2, ..., \log a_K" and K independent gumbel random variables, i.e., "g_1, g_2, ..., g_K". We have
\argmax_i \log a_i + g_i ~ Categorical({a_i / sum(a)})
This gives you a very simple way to sampl
-
Updated
Sep 22, 2020 - C++
Support Series.median()
What happened:
xr.DataArray([1], coords=[('onecoord', [2])]).sel(onecoord=2).to_dataframe(name='name') raise an exception ValueError: no valid index for a 0-dimensional object
What you expected to happen:
the same behavior as: xr.DataArray([1], coords=[('onecoord', [2])]).to_dataframe(name='name')
Anything else we need to know?:
I see that the array after the select
-
Updated
Aug 10, 2020 - Jupyter Notebook
-
Updated
Feb 11, 2020 - Python
-
Updated
Sep 26, 2020 - Jupyter Notebook
-
Updated
Sep 11, 2020 - Python
Improve this page
Add a description, image, and links to the numpy topic page so that developers can more easily learn about it.
Add this topic to your repo
To associate your repository with the numpy topic, visit your repo's landing page and select "manage topics."
Compiling against the C++ API on macOS using GCC-9.3, and cmake seems to use a bad flag:
... -fopenmp -D_GLIBCXX_USE_CXX11_ABI= -std=c++14 ...-- note how it "blanks out" the_GLIBCXX_USE_CXX11_ABIvariable. This causes the compiler to fail in the stdlib: