mirror of
https://github.com/wassname/simpeg.git
synced 2026-07-17 11:32:59 +08:00
Documentation updates.
This commit is contained in:
+15
-7
@@ -21,15 +21,23 @@ class TensorView(object):
|
||||
|
||||
Input:
|
||||
|
||||
I - scalar field (np.array)
|
||||
:param numpy.array I: scalar field
|
||||
|
||||
Optional Input:
|
||||
|
||||
imageType - type of image ('CC','N','Fx','Fy','Fz','Ex','Ey','Ez')
|
||||
figNum - number of figure to plot to
|
||||
ax - axis to plot to
|
||||
direction - 3D only. slice dimensions
|
||||
numbering - 3D only. show numbering of slices
|
||||
:param str imageType: type of image ('CC','N','Fx','Fy','Fz','Ex','Ey','Ez')
|
||||
:param int figNum: number of figure to plot to
|
||||
:param matplotlib.axes.Axes ax: axis to plot to
|
||||
:param str direction: slice dimensions, 3D only ('x', 'y', 'z')
|
||||
:param bool numbering: show numbering of slices, 3D only
|
||||
:param str annotationColor: color of annotation, e.g. 'w', 'k', 'b'
|
||||
:param bool showIt: call plt.show()
|
||||
|
||||
.. plot:: examples/mesh/plot_image_2D.py
|
||||
:include-source:
|
||||
|
||||
.. plot:: examples/mesh/plot_image_3D.py
|
||||
:include-source:
|
||||
"""
|
||||
assert type(I) == np.ndarray, "I must be a numpy array"
|
||||
assert type(numbering) == bool, "numbering must be a bool"
|
||||
@@ -154,6 +162,7 @@ class TensorView(object):
|
||||
gyY = np.c_[gy, gy, gy+np.nan].ravel()
|
||||
ax.plot(gxX, gxY, annotationColor+'-', linewidth=2)
|
||||
ax.plot(gyX, gyY, annotationColor+'-', linewidth=2)
|
||||
ax.axis('tight')
|
||||
|
||||
if numbering:
|
||||
pad = np.sum(self.hx)*0.04
|
||||
@@ -170,7 +179,6 @@ class TensorView(object):
|
||||
def plotGrid(self, showIt=False):
|
||||
"""Plot the nodal, cell-centered and staggered grids for 1,2 and 3 dimensions.
|
||||
|
||||
|
||||
.. plot:: examples/mesh/plot_grid_2D.py
|
||||
:include-source:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user