Repository: dask/dask

Issue:
Applying da.std to numpy array yields keyword error
When applying `da.std` to a numpy array it yields a Keyword error, while all other combinations of numpy and dask arrays and functions do work. 

Admittedly this is a bit of pathetic use case / anti-pattern, but should be easy to fix. 

Would there be some more general way to test for this kind of errors?

```python
np.random.seed(10)
npdat = np.random.random(5)
dadat = da.from_array(npdat)
da.std(dadat).compute(), np.std(npdat), np.std(dadat).compute()  # all work
da.std(npdat)
```

> TypeError                                 Traceback (most recent call last)
> <ipython-input-130-a1acaa3fc2bb> in <module>
>       1 np.random.seed(10)
>       2 npdat = np.random.random(5) #+ 1j*np.random.random(5)
> ----> 3 da.std(npdat)
> 
> C:\ProgramData\Anaconda3\lib\site-packages\dask\array\reductions.py in std(a, axis, dtype, keepdims, ddof, split_every, out)
>     820             ddof=ddof,
>     821             split_every=split_every,
> --> 822             out=out,
>     823         )
>     824     )
> 
> TypeError: _var() got an unexpected keyword argument 'split_every'

Discussion:
jrbourbeau: cc @TAdeJong 
jcrist: Thanks @jrbourbeau. Closing.

Patch:
diff --git a/dask/array/reductions.py b/dask/array/reductions.py
index 9bbdc11c5..5dfda7af7 100644
--- a/dask/array/reductions.py
+++ b/dask/array/reductions.py
@@ -813,7 +813,8 @@ with ignoring(AttributeError):
 @wraps(chunk.std)
 def std(a, axis=None, dtype=None, keepdims=False, ddof=0, split_every=None, out=None):
     result = sqrt(
-        a.var(
+        var(
+            a,
             axis=axis,
             dtype=dtype,
             keepdims=keepdims,


Test patch:
diff --git a/dask/array/tests/test_reductions.py b/dask/array/tests/test_reductions.py
index b0254f859..8c241c178 100644
--- a/dask/array/tests/test_reductions.py
+++ b/dask/array/tests/test_reductions.py
@@ -49,6 +49,9 @@ def test_numel(dtype, keepdims):
 
 def reduction_1d_test(da_func, darr, np_func, narr, use_dtype=True, split_every=True):
     assert_eq(da_func(darr), np_func(narr))
+    assert_eq(
+        da_func(narr), np_func(narr)
+    )  # Ensure Dask reductions work with NumPy arrays
     assert_eq(da_func(darr, keepdims=True), np_func(narr, keepdims=True))
     assert_eq(da_func(darr, axis=()), np_func(narr, axis=()))
     assert same_keys(da_func(darr), da_func(darr))