# util

`pyviennacl.util.``backend_finish`()

  Block until any computation active on the compute backend is finished.

`pyviennacl.util.``from_ndarray`(obj)

  Convert a NumPy `ndarray` into a PyViennaCL object of appropriate dimensionality.

  obj : array-like

  new : {Vector, Matrix}
    `Vector` if `obj` has 1 dimension; `Matrix` if 2.
  AttributeError
    If `obj` has less than 1 or more than 2 dimensions.