Skip to content

Commit

Permalink
HOTFIX: Missing cmap_name from masked images
Browse files Browse the repository at this point in the history
  • Loading branch information
patricksnape committed Mar 25, 2015
1 parent 542dca0 commit f3f3f0f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 deletions.
8 changes: 4 additions & 4 deletions menpo/image/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -531,8 +531,8 @@ def _view_2d(self, figure_id=None, new_figure=False, channels=None,
{none, nearest, bilinear, bicubic, spline16, spline36,
hanning, hamming, hermite, kaiser, quadric, catrom, gaussian,
bessel, mitchell, sinc, lanczos}
cmap_name: `Colormap name`, optional,
If None, single channel and three channel images default
cmap_name: `str`, optional,
If ``None``, single channel and three channel images default
to greyscale and rgb colormaps respectively.
alpha : `float`, optional
The alpha blending value, between 0 (transparent) and 1 (opaque).
Expand Down Expand Up @@ -654,8 +654,8 @@ def _view_landmarks_2d(self, channels=None, group=None,
hamming, hermite, kaiser, quadric, catrom, gaussian, bessel,
mitchell, sinc, lanczos}
cmap_name: `Colormap name`, optional,
If None, single channel and three channel images default
cmap_name: `str`, optional,
If ``None``, single channel and three channel images default
to greyscale and rgb colormaps respectively.
alpha : `float`, optional
The alpha blending value, between 0 (transparent) and 1 (opaque).
Expand Down
19 changes: 13 additions & 6 deletions menpo/image/masked.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,8 +312,8 @@ def from_vector_inplace(self, vector, copy=True):
copy=copy)

def _view_2d(self, figure_id=None, new_figure=False, channels=None,
masked=True, interpolation="bilinear", alpha=1.,
render_axes=False, axes_font_name='sans-serif',
masked=True, interpolation='bilinear', cmap_name=None,
alpha=1., render_axes=False, axes_font_name='sans-serif',
axes_font_size=10, axes_font_style='normal',
axes_font_weight='normal', axes_x_limits=None,
axes_y_limits=None, figure_size=(10, 8)):
Expand Down Expand Up @@ -344,6 +344,9 @@ def _view_2d(self, figure_id=None, new_figure=False, channels=None,
hanning, hamming, hermite, kaiser, quadric, catrom, gaussian,
bessel, mitchell, sinc, lanczos}
cmap_name: `str`, optional,
If ``None``, single channel and three channel images default
to greyscale and rgb colormaps respectively.
alpha : `float`, optional
The alpha blending value, between 0 (transparent) and 1 (opaque).
render_axes : `bool`, optional
Expand Down Expand Up @@ -389,12 +392,13 @@ def _view_2d(self, figure_id=None, new_figure=False, channels=None,
axes_y_limits=axes_y_limits,
figure_size=figure_size,
interpolation=interpolation,
cmap_name=cmap_name,
alpha=alpha)

def _view_landmarks_2d(self, channels=None, masked=True, group=None,
with_labels=None, without_labels=None,
figure_id=None, new_figure=False,
interpolation='bilinear', alpha=1.,
interpolation='bilinear', cmap_name=None, alpha=1.,
render_lines=True, line_colour=None, line_style='-',
line_width=1, render_markers=True, marker_style='o',
marker_size=20, marker_face_colour=None,
Expand Down Expand Up @@ -455,6 +459,9 @@ def _view_landmarks_2d(self, channels=None, masked=True, group=None,
hamming, hermite, kaiser, quadric, catrom, gaussian, bessel,
mitchell, sinc, lanczos}
cmap_name: `str`, optional,
If ``None``, single channel and three channel images default
to greyscale and rgb colormaps respectively.
alpha : `float`, optional
The alpha blending value, between 0 (transparent) and 1 (opaque).
render_lines : `bool`, optional
Expand Down Expand Up @@ -620,9 +627,9 @@ def _view_landmarks_2d(self, channels=None, masked=True, group=None,
from menpo.visualize import view_image_landmarks
return view_image_landmarks(
self, channels, masked, group, with_labels, without_labels,
figure_id, new_figure, interpolation, alpha, render_lines,
line_colour, line_style, line_width, render_markers, marker_style,
marker_size, marker_face_colour, marker_edge_colour,
figure_id, new_figure, interpolation, cmap_name, alpha,
render_lines, line_colour, line_style, line_width, render_markers,
marker_style, marker_size, marker_face_colour, marker_edge_colour,
marker_edge_width, render_numbering, numbers_horizontal_align,
numbers_vertical_align, numbers_font_name, numbers_font_size,
numbers_font_style, numbers_font_weight, numbers_font_colour,
Expand Down

0 comments on commit f3f3f0f

Please sign in to comment.