simpeg/discretize: Discretize restructure
Creators
- Lindsey Heagy1
- Joseph Capriotti2
- Rowan Cockett3
- Gudni Karl Rosenkjaer
- dom
- SEOGI KANG4
- Bane Sullivan5
- David Marchant
- Devin C. Cowan
- Dieter Werthmüller6
- Michael Mitchell7
- Thibaut Astic4
- domfournier8
- Luz Angélica Caudillo Mata
- Brendan Smithyman9
- Franklin Koch10
- Blue Tyson
- Cody11
- Michael Wathen
- Christoph Gohlke12
- 1. @simpeg, @geoscixyz, @ubcgif
- 2. Colorado School of Mines - Geophysics - CGEM
- 3. @iooxa
- 4. University of British Columbia
- 5. @Kitware
- 6. TU Delft
- 7. USGS, California Volcano Observatory
- 8. Mira Geosciecne
- 9. Seequent
- 10. @seequent
- 11. QuantifiedCode
- 12. University of California, Irvine
Description
This minor release is intended to bring consistent pep8 style naming across all of discretize's classes and functions.
There are two major types of renaming, aliases and deprecations. We have chosen to move to more descriptive property names for classes, generally. For example, mesh.area
is deprecated and now is mesh.face_area
. Also properties like mesh.vnC
are now officially mesh.shape_cells
due to the more descriptive name, but can also be accessed as mesh.vnC
to speed up some code writing for users. We have included a full list of aliases and deprecations below. In PR #227 we have detailed our reasonings behind individual name choices.
The other big change that will likely cause previous code to break is that all of these mesh.shape_*
type properties are now explicitly tuple
-s, making them immutable. These properties could previously be modified which would result in undefined and unsafe behavoir. A side effect of this, is that any code that relied on these properties being numpy.ndarray
-s, will break. This is intentional.
There's a few internal changes as well, to reorganize the file structure. importing items in discretize.utils
from their individual module files is not recommended and might result in future broken code. Please only import these items from the discretize.utils
module.
We have also separated the matplotlib
plotting code into a separate module: discretize.utils.mixins.mpl_mod
. At the same time we have further improved the plotting speed of discretize.TreeMesh
and discretize.CurvilinearMesh
. This also allows all of these functions to have a unified calling convention.
Finally, we have removed assert errors in favor of throwing the proper exception when checking inputs. We have removed all references to __future__
and six
to clean up and drop python 2 compatibility.
Changes
For a full list of deprecations and aliases please visit the release notes in the documentation <a href=http://discretize.simpeg.xyz/en/master/release/0.6.0-notes.html>here</a>.
Files
simpeg/discretize-v0.6.0.zip
Files
(1.1 MB)
Name | Size | Download all |
---|---|---|
md5:a64699dd5c48a57223022a23b2351620
|
1.1 MB | Preview Download |
Additional details
Related works
- Is supplement to
- https://github.com/simpeg/discretize/tree/v0.6.0 (URL)