mirror of
https://github.com/wassname/scikit-image.git
synced 2026-06-28 22:37:50 +08:00
ENH: initialize AffineTransform to identity when no args are provided
This commit is contained in:
@@ -297,6 +297,11 @@ class AffineTransform(ProjectiveTransform):
|
||||
[ 0, 0, 1]
|
||||
])
|
||||
self._matrix[0:2, 2] = translation
|
||||
else:
|
||||
# -- Default to an identity transform
|
||||
self._matrix = np.asarray(
|
||||
[[1, 0, 0], [0, 1, 0], [0, 0, 0]],
|
||||
dtype='float64')
|
||||
|
||||
@property
|
||||
def scale(self):
|
||||
|
||||
Reference in New Issue
Block a user