enthought/distarray — pull request #265 by kwmsmith (2014-04-01 03:26:43+00:00)
Title: Streamlines client-side array creation with `from_global_dim_data`

Adds a classmethod `from_global_dim_data` to `Context` that removes all duplication required for initialization. Covers all cases that `Context.from_dim_data` covered. Testsuite updated. ClientMaps updated.

Some small API changes here, besides the new global dim_data dictionaries. They're pretty simple. We can tweak and improve them as needed:

```python
{'dist_type': 'b',
'bounds': (0, 2, 3, 5, 10)}
# size = bounds[-1]
# proc_grid_size = len(bounds) - 1

{'dist_type': 'n',
'size': 10}

{'dist_type': 'c',
'size': 10,
'proc_grid_size': 4}

{'dist_type': 'u',
'indices': ((3, 2, 1,), (6, 5, 4), (9, 8, 7))}
```

@bgrant @markkness -- this is all motivated by the plotting exercises, which helped show the need for a simpler way to create `DistArray`s. Please review.