100% found this document useful (2 votes)
32 views

Download Full Image Analysis, Classification, and Change Detection in Remote Sensing: With Algorithms for Python 4th Edition Morton John Canty PDF All Chapters

Detection

Uploaded by

thonggaterhz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (2 votes)
32 views

Download Full Image Analysis, Classification, and Change Detection in Remote Sensing: With Algorithms for Python 4th Edition Morton John Canty PDF All Chapters

Detection

Uploaded by

thonggaterhz
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 55

Download the Full Version of textbook for Fast Typing at textbookfull.

com

Image Analysis, Classification, and Change


Detection in Remote Sensing: With Algorithms for
Python 4th Edition Morton John Canty

https://textbookfull.com/product/image-analysis-
classification-and-change-detection-in-remote-sensing-with-
algorithms-for-python-4th-edition-morton-john-canty/

OR CLICK BUTTON

DOWNLOAD NOW

Download More textbook Instantly Today - Get Yours Now at textbookfull.com


Recommended digital products (PDF, EPUB, MOBI) that
you can download immediately if you are interested.

Image analysis, classification and change detection in


remote sensing: with algorithms for Python Fourth Edition
Canty
https://textbookfull.com/product/image-analysis-classification-and-
change-detection-in-remote-sensing-with-algorithms-for-python-fourth-
edition-canty/
textboxfull.com

Fuzzy Machine Learning Algorithms for Remote Sensing Image


Classification 1st Edition Anil Kumar

https://textbookfull.com/product/fuzzy-machine-learning-algorithms-
for-remote-sensing-image-classification-1st-edition-anil-kumar/

textboxfull.com

Biota Grow 2C gather 2C cook Loucas

https://textbookfull.com/product/biota-grow-2c-gather-2c-cook-loucas/

textboxfull.com

Image processing and GIS for remote sensing : techniques


and applications Second Edition Liu

https://textbookfull.com/product/image-processing-and-gis-for-remote-
sensing-techniques-and-applications-second-edition-liu/

textboxfull.com
Introductory digital image processing: A remote sensing
perspective John R. Jensen & Dr. Kalmesh Lulla

https://textbookfull.com/product/introductory-digital-image-
processing-a-remote-sensing-perspective-john-r-jensen-dr-kalmesh-
lulla/
textboxfull.com

Multisensor Image Fusion and Data Mining for Environmental


Remote Sensing First Edition Bai

https://textbookfull.com/product/multisensor-image-fusion-and-data-
mining-for-environmental-remote-sensing-first-edition-bai/

textboxfull.com

Remote sensing of vegetation. Hyperspectral indices and


image classifications for agriculture and vegetation
Second Edition Huete
https://textbookfull.com/product/remote-sensing-of-vegetation-
hyperspectral-indices-and-image-classifications-for-agriculture-and-
vegetation-second-edition-huete/
textboxfull.com

Hyperspectral Imaging Remote Sensing Physics Sensors and


Algorithms 1st Edition Dimitris G. Manolakis

https://textbookfull.com/product/hyperspectral-imaging-remote-sensing-
physics-sensors-and-algorithms-1st-edition-dimitris-g-manolakis/

textboxfull.com

Data Structures & Algorithms in Python John Canning

https://textbookfull.com/product/data-structures-algorithms-in-python-
john-canning/

textboxfull.com
Image Analysis,
Classification, and Change
Detection in Remote
Sensing
With Algorithms for Python
Fourth edition
Image Analysis,
Classification, and Change
Detection in Remote
Sensing
With Algorithms for Python
Fourth edition

Morton John Canty


CRC Press
Taylor & Francis Group
6000 Broken Sound Parkway NW, Suite 300
Boca Raton, FL 33487-2742

© 2019 by Taylor & Francis Group, LLC


CRC Press is an imprint of Taylor & Francis Group, an Informa business

No claim to original U.S. Government works

Printed on acid-free paper


Version Date: 20190130

International Standard Book Number-13: 978-1-138-61322-5 (Hardback)

This book contains information obtained from authentic and highly regarded sources. Reasonable
efforts have been made to publish reliable data and information, but the author and publisher cannot
assume responsibility for the validity of all materials or the consequences of their use. The authors and
publishers have attempted to trace the copyright holders of all material reproduced in this publication
and apologize to copyright holders if permission to publish in this form has not been obtained. If any
copyright material has not been acknowledged please write and let us know so we may rectify in any
future reprint.
Except as permitted under U.S. Copyright Law, no part of this book may be reprinted, reproduced,
transmitted, or utilized in any form by any electronic, mechanical, or other means, now known or
hereafter invented, including photocopying, microfilming, and recording, or in any information
storage or retrieval system, without written permission from the publishers.

For permission to photocopy or use material electronically from this work, please access
www.copyright.com (http://www.copyright.com/) or contact the Copyright Clearance Center, Inc.
(CCC), 222 Rosewood Drive, Danvers, MA 01923, 978-750-8400. CCC is a not-for-profit organization
that provides licenses and registration for a variety of users. For organizations that have been granted
a photocopy license by the CCC, a separate system of payment has been arranged.

Trademark Notice: Product or corporate names may be trademarks or registered trademarks, and
are used only for identification and explanation without intent to infringe.

Library of Congress Cataloging-in-Publication Data

Names: Canty, Morton John, author.


Title: Image analysis, classification and change detection in remote sensing
: with algorithms for Python / by Morton J. Canty.
Description: Fourth edition. | Boca Raton, FL : CRC Press/Taylor & Francis
Group, 2019. | Includes bibliographical references and index.
Identifiers: LCCN 2018051975| ISBN 9781138613225 (hardback : acid-free paper)
| ISBN 9780429464348 (ebook)
Subjects: LCSH: Remote sensing--Mathematics. | Image analysis--Mathematics. |
Image analysis--Data processing. | Python (Computer program language)
Classification: LCC G70.4 .C36 2019 | DDC 621.36/70285--dc23
LC record available at https://lccn.loc.gov/2018051975

Visit the Taylor & Francis Web site at


http://www.taylorandfrancis.com
and the CRC Press Web site at
http://www.crcpress.com
Contents

Preface to the First Edition xiii

Preface to the Second Edition xv

Preface to the Third Edition xvii

Preface to the Fourth Edition xx

Author Biography xxi

1 Images, Arrays, and Matrices 1


1.1 Multispectral satellite images . . . . . . . . . . . . . . . . . . 4
1.2 Synthetic aperture radar images . . . . . . . . . . . . . . . . . 7
1.3 Algebra of vectors and matrices . . . . . . . . . . . . . . . . . 10
1.3.1 Elementary properties . . . . . . . . . . . . . . . . . . 11
1.3.2 Square matrices . . . . . . . . . . . . . . . . . . . . . . 13
1.3.3 Singular matrices . . . . . . . . . . . . . . . . . . . . . 15
1.3.4 Symmetric, positive definite matrices . . . . . . . . . . 15
1.3.5 Linear dependence and vector spaces . . . . . . . . . . 16
1.4 Eigenvalues and eigenvectors . . . . . . . . . . . . . . . . . . 17
1.5 Singular value decomposition . . . . . . . . . . . . . . . . . . 19
1.6 Finding minima and maxima . . . . . . . . . . . . . . . . . . 21
1.7 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27

2 Image Statistics 31
2.1 Random variables . . . . . . . . . . . . . . . . . . . . . . . . . 31
2.1.1 Discrete random variables . . . . . . . . . . . . . . . . 32
2.1.2 Continuous random variables . . . . . . . . . . . . . . 33
2.1.3 Random vectors . . . . . . . . . . . . . . . . . . . . . 36
2.1.4 The normal distribution . . . . . . . . . . . . . . . . . 39
2.1.5 The gamma distribution and its derivatives . . . . . . 41
2.2 Parameter estimation . . . . . . . . . . . . . . . . . . . . . . . 44
2.2.1 Random samples . . . . . . . . . . . . . . . . . . . . . 44
2.2.2 Sample distributions and interval estimators . . . . . . 47
2.3 Multivariate distributions . . . . . . . . . . . . . . . . . . . . 50
2.3.1 Vector sample functions and the data matrix . . . . . 51
2.3.2 Provisional means . . . . . . . . . . . . . . . . . . . . 53

v
vi Image Analysis, Classification, and Change Detection in Remote Sensing

2.3.3 Real and complex multivariate sample distributions . . 55


2.4 Bayes’ Theorem, likelihood and classification . . . . . . . . . 57
2.5 Hypothesis testing . . . . . . . . . . . . . . . . . . . . . . . . 60
2.6 Ordinary linear regression . . . . . . . . . . . . . . . . . . . . 65
2.6.1 One independent variable . . . . . . . . . . . . . . . . 65
2.6.2 Coefficient of determination (R2 ) . . . . . . . . . . . . 67
2.6.3 More than one independent variable . . . . . . . . . . 68
2.6.4 Regularization, duality and the Gram matrix . . . . . 72
2.7 Entropy and information . . . . . . . . . . . . . . . . . . . . . 73
2.7.1 Kullback–Leibler divergence . . . . . . . . . . . . . . . 75
2.7.2 Mutual information . . . . . . . . . . . . . . . . . . . . 76
2.8 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77

3 Transformations 83
3.1 The discrete Fourier transform . . . . . . . . . . . . . . . . . 83
3.2 The discrete wavelet transform . . . . . . . . . . . . . . . . . 88
3.2.1 Haar wavelets . . . . . . . . . . . . . . . . . . . . . . . 89
3.2.2 Image compression . . . . . . . . . . . . . . . . . . . . 93
3.2.3 Multiresolution analysis . . . . . . . . . . . . . . . . . 96
3.3 Principal components . . . . . . . . . . . . . . . . . . . . . . 103
3.3.1 Principal components on the GEE . . . . . . . . . . . 105
3.3.2 Image compression and reconstruction . . . . . . . . . 107
3.3.3 Primal solution . . . . . . . . . . . . . . . . . . . . . . 111
3.3.4 Dual solution . . . . . . . . . . . . . . . . . . . . . . . 111
3.4 Minimum noise fraction . . . . . . . . . . . . . . . . . . . . . 112
3.4.1 Additive noise . . . . . . . . . . . . . . . . . . . . . . . 113
3.4.2 Minimum noise fraction via PCA . . . . . . . . . . . . 116
3.5 Spatial correlation . . . . . . . . . . . . . . . . . . . . . . . . 117
3.5.1 Maximum autocorrelation factor . . . . . . . . . . . . 117
3.5.2 Noise estimation . . . . . . . . . . . . . . . . . . . . . 119
3.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123

4 Filters, Kernels, and Fields 127


4.1 The Convolution Theorem . . . . . . . . . . . . . . . . . . . . 127
4.2 Linear filters . . . . . . . . . . . . . . . . . . . . . . . . . . . 132
4.3 Wavelets and filter banks . . . . . . . . . . . . . . . . . . . . 135
4.3.1 One-dimensional arrays . . . . . . . . . . . . . . . . . 136
4.3.2 Two-dimensional arrays . . . . . . . . . . . . . . . . . 141
4.4 Kernel methods . . . . . . . . . . . . . . . . . . . . . . . . . . 144
4.4.1 Valid kernels . . . . . . . . . . . . . . . . . . . . . . . 144
4.4.2 Kernel PCA . . . . . . . . . . . . . . . . . . . . . . . . 149
4.5 Gibbs–Markov random fields . . . . . . . . . . . . . . . . . . 152
4.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
Contents vii

5 Image Enhancement and Correction 159


5.1 Lookup tables and histogram functions . . . . . . . . . . . . . 159
5.2 High-pass spatial filtering and feature extraction . . . . . . . 161
5.2.1 Sobel filter . . . . . . . . . . . . . . . . . . . . . . . . 161
5.2.2 Laplacian-of-Gaussian filter . . . . . . . . . . . . . . . 164
5.2.3 OpenCV and GEE algorithms . . . . . . . . . . . . . . 166
5.2.4 Invariant moments . . . . . . . . . . . . . . . . . . . . 171
5.3 Panchromatic sharpening . . . . . . . . . . . . . . . . . . . . 177
5.3.1 HSV fusion . . . . . . . . . . . . . . . . . . . . . . . . 178
5.3.2 Brovey fusion . . . . . . . . . . . . . . . . . . . . . . . 179
5.3.3 PCA fusion . . . . . . . . . . . . . . . . . . . . . . . . 179
5.3.4 DWT fusion . . . . . . . . . . . . . . . . . . . . . . . . 180
5.3.5 À trous fusion . . . . . . . . . . . . . . . . . . . . . . . 181
5.3.6 A quality index . . . . . . . . . . . . . . . . . . . . . . 184
5.4 Radiometric correction of polarimetric SAR imagery . . . . . 185
5.4.1 Speckle statistics . . . . . . . . . . . . . . . . . . . . . 185
5.4.2 Multi-look data . . . . . . . . . . . . . . . . . . . . . . 188
5.4.3 Speckle filtering . . . . . . . . . . . . . . . . . . . . . . 193
5.5 Topographic correction . . . . . . . . . . . . . . . . . . . . . . 200
5.5.1 Rotation, scaling and translation . . . . . . . . . . . . 201
5.5.2 Imaging transformations . . . . . . . . . . . . . . . . . 202
5.5.3 Camera models and RFM approximations . . . . . . . 203
5.5.4 Stereo imaging and digital elevation models . . . . . . 205
5.5.5 Slope and aspect . . . . . . . . . . . . . . . . . . . . . 210
5.5.6 Illumination correction . . . . . . . . . . . . . . . . . . 211
5.6 Image–image registration . . . . . . . . . . . . . . . . . . . . 216
5.6.1 Frequency domain registration . . . . . . . . . . . . . 217
5.6.2 Feature matching . . . . . . . . . . . . . . . . . . . . . 219
5.6.3 Re-sampling with ground control points . . . . . . . . 223
5.7 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225

6 Supervised Classification Part 1 231


6.1 Maximizing the a posteriori probability . . . . . . . . . . . . 233
6.2 Training data and separability . . . . . . . . . . . . . . . . . . 234
6.3 Maximum likelihood classification . . . . . . . . . . . . . . . . 239
6.3.1 Naive Bayes on the GEE . . . . . . . . . . . . . . . . . 240
6.3.2 Python scripts for supervised classification . . . . . . . 241
6.4 Gaussian kernel classification . . . . . . . . . . . . . . . . . . 245
6.5 Neural networks . . . . . . . . . . . . . . . . . . . . . . . . . . 248
6.5.1 The neural network classifier . . . . . . . . . . . . . . 253
6.5.2 Cost functions . . . . . . . . . . . . . . . . . . . . . . 256
6.5.3 Backpropagation . . . . . . . . . . . . . . . . . . . . . 258
6.5.4 A deep learning network . . . . . . . . . . . . . . . . . 264
6.5.5 Overfitting and generalization . . . . . . . . . . . . . . 268
6.6 Support vector machines . . . . . . . . . . . . . . . . . . . . . 270
viii Image Analysis, Classification, and Change Detection in Remote Sensing

6.6.1 Linearly separable classes . . . . . . . . . . . . . . . . 270


6.6.2 Overlapping classes . . . . . . . . . . . . . . . . . . . . 276
6.6.3 Solution with sequential minimal optimization . . . . . 278
6.6.4 Multiclass SVMs . . . . . . . . . . . . . . . . . . . . . 279
6.6.5 Kernel substitution . . . . . . . . . . . . . . . . . . . . 280
6.7 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284

7 Supervised Classification Part 2 289


7.1 Postprocessing . . . . . . . . . . . . . . . . . . . . . . . . . . 289
7.1.1 Majority filtering . . . . . . . . . . . . . . . . . . . . . 290
7.1.2 Probabilistic label relaxation . . . . . . . . . . . . . . 290
7.2 Evaluation and comparison of classification accuracy . . . . . 293
7.2.1 Accuracy assessment . . . . . . . . . . . . . . . . . . . 293
7.2.2 Accuracy assessment on the GEE . . . . . . . . . . . . 298
7.2.3 Cross-validation on parallel architectures . . . . . . . . 299
7.2.4 Model comparison . . . . . . . . . . . . . . . . . . . . 302
7.3 Adaptive boosting . . . . . . . . . . . . . . . . . . . . . . . . 306
7.4 Classification of polarimetric SAR imagery . . . . . . . . . . . 312
7.5 Hyperspectral image analysis . . . . . . . . . . . . . . . . . . 314
7.5.1 Spectral mixture modeling . . . . . . . . . . . . . . . . 314
7.5.2 Unconstrained linear unmixing . . . . . . . . . . . . . 317
7.5.3 Intrinsic end-members and pixel purity . . . . . . . . . 318
7.5.4 Anomaly detection: The RX algorithm . . . . . . . . . 319
7.5.5 Anomaly detection: The kernel RX algorithm . . . . . 322
7.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326

8 Unsupervised Classification 329


8.1 Simple cost functions . . . . . . . . . . . . . . . . . . . . . . . 330
8.2 Algorithms that minimize the simple cost functions . . . . . . 332
8.2.1 K-means clustering . . . . . . . . . . . . . . . . . . . . 333
8.2.2 Kernel K-means clustering . . . . . . . . . . . . . . . . 338
8.2.3 Extended K-means clustering . . . . . . . . . . . . . . 341
8.2.4 Agglomerative hierarchical clustering . . . . . . . . . . 344
8.2.5 Fuzzy K-means clustering . . . . . . . . . . . . . . . . 347
8.3 Gaussian mixture clustering . . . . . . . . . . . . . . . . . . . 349
8.3.1 Expectation maximization . . . . . . . . . . . . . . . . 350
8.3.2 Simulated annealing . . . . . . . . . . . . . . . . . . . 353
8.3.3 Partition density . . . . . . . . . . . . . . . . . . . . . 353
8.3.4 Implementation notes . . . . . . . . . . . . . . . . . . 354
8.4 Including spatial information . . . . . . . . . . . . . . . . . . 354
8.4.1 Multiresolution clustering . . . . . . . . . . . . . . . . 354
8.4.2 Spatial clustering . . . . . . . . . . . . . . . . . . . . . 357
8.5 A benchmark . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
8.6 The Kohonen self-organizing map . . . . . . . . . . . . . . . . 362
8.7 Image segmentation and the mean shift . . . . . . . . . . . . 366
Contents ix

8.8 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368

9 Change Detection 375


9.1 Naive methods . . . . . . . . . . . . . . . . . . . . . . . . . . 376
9.2 Principal components analysis (PCA) . . . . . . . . . . . . . 378
9.2.1 Iterated PCA . . . . . . . . . . . . . . . . . . . . . . . 380
9.2.2 Kernel PCA . . . . . . . . . . . . . . . . . . . . . . . . 382
9.3 Multivariate alteration detection (MAD) . . . . . . . . . . . . 384
9.3.1 Canonical correlation analysis (CCA) . . . . . . . . . . 385
9.3.2 Orthogonality properties . . . . . . . . . . . . . . . . . 388
9.3.3 Iteratively re-weighted MAD . . . . . . . . . . . . . . 389
9.3.4 Scale invariance . . . . . . . . . . . . . . . . . . . . . . 391
9.3.5 Correlation with the original observations . . . . . . . 392
9.3.6 Regularization . . . . . . . . . . . . . . . . . . . . . . 394
9.3.7 Postprocessing . . . . . . . . . . . . . . . . . . . . . . 396
9.4 Unsupervised change classification . . . . . . . . . . . . . . . 397
9.5 iMAD on the Google Earth Engine . . . . . . . . . . . . . . . 399
9.6 Change detection with polarimetric SAR imagery . . . . . . . 401
9.6.1 Scalar imagery: the gamma distribution . . . . . . . . 402
9.6.2 Polarimetric imagery: the complex Wishart distribu-
tion . . . . . . . . . . . . . . . . . . . . . . . . . . . . 405
9.6.3 Python software . . . . . . . . . . . . . . . . . . . . . 409
9.6.4 SAR change detection on the Google Earth Engine . . 413
9.7 Radiometric normalization of visual/infrared images . . . . . 415
9.7.1 Scatterplot matching . . . . . . . . . . . . . . . . . . . 416
9.7.2 Automatic radiometric normalization . . . . . . . . . . 419
9.8 RESTful change detection on the GEE . . . . . . . . . . . . . 422
9.9 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 422

A Mathematical Tools 427


A.1 Cholesky decomposition . . . . . . . . . . . . . . . . . . . . . 427
A.2 Vector and inner product spaces . . . . . . . . . . . . . . . . 429
A.3 Complex numbers, vectors and matrices . . . . . . . . . . . . 430
A.4 Least squares procedures . . . . . . . . . . . . . . . . . . . . . 432
A.4.1 Recursive linear regression . . . . . . . . . . . . . . . . 432
A.4.2 Orthogonal linear regression . . . . . . . . . . . . . . . 434
A.5 Proof of Theorem 7.1 . . . . . . . . . . . . . . . . . . . . . . . 437

B Efficient Neural Network Training Algorithms 441


B.1 The Hessian matrix . . . . . . . . . . . . . . . . . . . . . . . . 441
B.1.1 The R-operator . . . . . . . . . . . . . . . . . . . . . . 442
B.1.2 Calculating the Hessian . . . . . . . . . . . . . . . . . 445
B.2 Scaled conjugate gradient training . . . . . . . . . . . . . . . 447
B.2.1 Conjugate directions . . . . . . . . . . . . . . . . . . . 447
B.2.2 Minimizing a quadratic function . . . . . . . . . . . . 449
x Image Analysis, Classification, and Change Detection in Remote Sensing

B.2.3 The algorithm . . . . . . . . . . . . . . . . . . . . . . . 451


B.3 Extended Kalman filter training . . . . . . . . . . . . . . . . . 455
B.3.1 Linearization . . . . . . . . . . . . . . . . . . . . . . . 456
B.3.2 The algorithm . . . . . . . . . . . . . . . . . . . . . . . 457

C Software 463
C.1 Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463
C.2 Command line utilities . . . . . . . . . . . . . . . . . . . . . . 464
C.2.1 gdal . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
C.2.2 earthengine . . . . . . . . . . . . . . . . . . . . . . . . 464
C.2.3 ipcluster . . . . . . . . . . . . . . . . . . . . . . . . . . 465
C.3 Source code . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
C.4 Python scripts . . . . . . . . . . . . . . . . . . . . . . . . . . 465
C.4.1 adaboost.py . . . . . . . . . . . . . . . . . . . . . . . . 466
C.4.2 atwt.py . . . . . . . . . . . . . . . . . . . . . . . . . . 466
C.4.3 c corr.py . . . . . . . . . . . . . . . . . . . . . . . . . . 467
C.4.4 classify.py . . . . . . . . . . . . . . . . . . . . . . . . . 467
C.4.5 crossvalidate.py . . . . . . . . . . . . . . . . . . . . . . 468
C.4.6 ct.py . . . . . . . . . . . . . . . . . . . . . . . . . . . . 469
C.4.7 dispms.py . . . . . . . . . . . . . . . . . . . . . . . . . 469
C.4.8 dwt.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 470
C.4.9 eeMad.py . . . . . . . . . . . . . . . . . . . . . . . . . 470
C.4.10 eeSar seq.py . . . . . . . . . . . . . . . . . . . . . . . . 471
C.4.11 eeWishart.py . . . . . . . . . . . . . . . . . . . . . . . 471
C.4.12 ekmeans.py . . . . . . . . . . . . . . . . . . . . . . . . 472
C.4.13 em.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 472
C.4.14 enlml.py . . . . . . . . . . . . . . . . . . . . . . . . . . 473
C.4.15 gamma filter.py . . . . . . . . . . . . . . . . . . . . . . 473
C.4.16 hcl.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 474
C.4.17 iMad.py . . . . . . . . . . . . . . . . . . . . . . . . . . 474
C.4.18 iMadmap.py . . . . . . . . . . . . . . . . . . . . . . . . 475
C.4.19 kkmeans.py . . . . . . . . . . . . . . . . . . . . . . . . 475
C.4.20 kmeans.py . . . . . . . . . . . . . . . . . . . . . . . . . 476
C.4.21 kpca.py . . . . . . . . . . . . . . . . . . . . . . . . . . 476
C.4.22 krx.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 477
C.4.23 mcnemar.py . . . . . . . . . . . . . . . . . . . . . . . . 477
C.4.24 meanshift.py . . . . . . . . . . . . . . . . . . . . . . . 477
C.4.25 mmse filter.py . . . . . . . . . . . . . . . . . . . . . . . 478
C.4.26 mnf.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
C.4.27 pca.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
C.4.28 plr.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 479
C.4.29 radcal.py . . . . . . . . . . . . . . . . . . . . . . . . . 479
C.4.30 readshp.py . . . . . . . . . . . . . . . . . . . . . . . . . 480
C.4.31 registerms.py . . . . . . . . . . . . . . . . . . . . . . . 480
C.4.32 registersar.py . . . . . . . . . . . . . . . . . . . . . . . 481
Contents xi

C.4.33 rx.py . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482


C.4.34 sar seq.py . . . . . . . . . . . . . . . . . . . . . . . . . 482
C.4.35 scatterplot.py . . . . . . . . . . . . . . . . . . . . . . . 483
C.4.36 som.py . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
C.4.37 subset.py . . . . . . . . . . . . . . . . . . . . . . . . . 484
C.5 JavaScript on the GEE Code Editor . . . . . . . . . . . . . . 484
C.5.1 imad run . . . . . . . . . . . . . . . . . . . . . . . . . 484
C.5.2 omnibus run . . . . . . . . . . . . . . . . . . . . . . . 484
C.5.3 omnibus view . . . . . . . . . . . . . . . . . . . . . . . 485
C.5.4 imad . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485
C.5.5 omnibus . . . . . . . . . . . . . . . . . . . . . . . . . . 485
C.5.6 utilities . . . . . . . . . . . . . . . . . . . . . . . . . . 485

Mathematical Notation 487

References 489

Index 501
Preface to the First Edition

This textbook had its beginnings as a set of notes to accompany seminars and
lectures conducted at the Geographical Institute of Bonn University and at its
associated Center for Remote Sensing of Land Cover. Lecture notes typically
continue to be refined and polished over the years until the question inevitably
poses itself: “Why not have them published?” The answer of course is “By all
means, if they contribute something new and useful.”
So what is “new and useful” here? This is a book about remote sensing
image analysis with a distinctly mathematical-algorithmic-computer-oriented
flavor, intended for graduate-level teaching and with, to borrow from the re-
mote sensing jargon, a rather restricted FOV. It does not attempt to match
the wider fields of view of existing texts on the subject, such as Schowengerdt
(1997), Richards (2012), Jensen (2005) and others. However, the topics that
are covered are dealt with in considerable depth, and I believe that this cov-
erage fills an important gap. Many aspects of the analysis of remote sensing
data are quite technical and tend to be intimidating to students with moder-
ate mathematical backgrounds. At the same time, one often witnesses a desire
on the part of students to apply advanced methods and to modify them to
fit their particular research problems. Fulfilling the latter wish, in particular,
requires more than superficial understanding of the material.
The focus of the book is on pixel-oriented analysis of visual/infrared Earth
observation satellite imagery. Among the topics that get the most attention
are the discrete wavelet transform, image fusion, supervised classification with
neural networks, clustering algorithms and statistical change detection meth-
ods. The first two chapters introduce the mathematical and statistical tools
necessary in order to follow later developments. Chapters 3 and 4 deal with
spatial/spectral transformations, convolutions and filtering of multispectral
image arrays. Chapter 5 treats image enhancement and some of the prepro-
cessing steps that precede classification and change detection. Chapters 6 and
7 are concerned, respectively, with supervised and unsupervised land cover
classification. The last chapter is about change detection with heavy emphasis
on the use of canonical correlation analysis. Each of the 8 chapters concludes
with exercises, some of which are small programming projects, intended to
illustrate or justify the foregoing development. Solutions to the exercises are
included in a separate booklet. Appendix A provides some additional mathe-
matical/statistical background and Appendix B develops two efficient training
algorithms for neural networks. Finally, Appendix C describes the installation
and use of the many computer programs introduced in the course of the book.

xiii
xiv Image Analysis, Classification and Change Detection in Remote Sensing

I’ve made considerable effort to maintain a consistent, clear mathemati-


cal style throughout. Although the developments in the text are admittedly
uncompromising, there is nothing that, given a little perseverance, cannot
be followed by a reader who has grasped the elementary matrix algebra and
statistical concepts explained in the first two chapters. If the student has am-
bitions to write his or her own image analysis programs, then he or she must
be prepared to “get the maths right” beforehand. There are, heaven knows,
enough pitfalls to worry about thereafter.
All of the illustrations and applications in the text are programmed in RSI’s
ENVI/IDL. The software is available for download at the publisher’s website:
http://www.crcpress.com/e products/downloads/default.asp
Given the plethora of image analysis and geographic information system (GIS)
software systems on the market or available under open source license, one
might think that the choice of computer environment would have been diffi-
cult. It wasn’t. IDL is an extremely powerful, array- and graphics-oriented,
universal programming language with a versatile interface (ENVI) for im-
porting and analyzing remote sensing data — a peerless combination for my
purposes. Extending the ENVI interface in IDL in order to implement new
methods and algorithms of arbitrary sophistication is both easy and fun.
So, apart from some exposure to elementary calculus (and the aforesaid
perseverance), the only other prerequisites for the book are a little familiarity
with the ENVI environment and the basic knowledge of IDL imparted by such
excellent introductions as Fanning (2000) or Gumley (2002). For everyday
problems with IDL at any level from “newbie” on upward, help and solace are
available at the newsgroup
comp.lang.idl-pvwave
frequented by some of the friendliest and most competent gurus on the net.
I would like to express my thanks to Rudolf Avenhaus and Allan Nielsen
for their many comments and suggestions for improvement of the manuscript
and to CRC Press for competent assistance in its preparation. Part of the
software documented in the text was developed within the Global Monitor-
ing for Security and Stability (GMOSS) network of excellence funded by the
European Commission.

Morton Canty
Preface to the Second Edition

Shortly after the manuscript for the first edition of this book went to the
publisher, ENVI 4.3 appeared along with, among other new features, a support
vector machine classifier. Although my decision not to include the SVM in
the original text was a conscious one (I balked at the thought of writing my
own IDL implementation), this event did point to a rather glaring omission
in a book purporting to be partly about land use/land cover classification.
So, almost immediately, I began to dream of a Revised Second Edition and
to pester CRC Press for a contract. This was happily forthcoming and the
present edition now has a fairly long section on supervised classification with
support vector machines.
The SVM is just one example of so-called kernel methods for nonlinear
data analysis, and I decided to make kernelization one of the themes of the
revised text. The treatment begins with a dual formulation for ridge regression
in Chapter 2 and continues through kernel principal components analysis in
Chapters 3 and 4, support vector machines in Chapter 6, kernel K-means clus-
tering in Chapter 8 and nonlinear change detection in Chapter 9. Other new
topics include entropy and mutual information (Chapter 1), adaptive boosting
(Chapter 7) and image segmentation (Chapter 8). In order to accommodate
the extended material on supervised classification, discussion is now spread
over the two Chapters 6 and 7. The exercises at the end of each chapter have
been extended and re-worked and, as for the first edition, a solutions manual
is provided.
I have written several additional IDL extensions to ENVI to accompany the
new themes, which are available, together with updated versions of previous
programs, for download on the Internet. In order to accelerate some of the
more computationally intensive routines for users with access to CUDA (par-
allel processing on NVIDIA graphics processors), code is included which can
make use of the IDL bindings to CUDA provided by Tech-X Corporation in
their GPULib product:
http://gpulib.txcorp.com
Notwithstanding the revisions, the present edition remains a monograph
on pixel-oriented analysis of intermediate-resolution remote sensing imagery
with emphasis on the development and programming of statistically moti-
vated, data-driven algorithms. Important topics such as object-based feature
analysis (for high-resolution imagery), or the physics of the radiation/surface
interaction (for example, in connection with hyperspectral sensing) are only

xv
xvi Image Analysis, Classification and Change Detection in Remote Sensing

touched upon briefly, and the huge field of radar remote sensing is left out
completely. Nevertheless, I hope that the in-depth focus on the topics covered
will continue to be of use both to practitioners as well as to teachers.
I would like to express my appreciation to Peter Reinartz and the German
Aerospace Center for permission to use the traffic scene images in Chapter 9
and to NASA’s Land Processes Distributed Active Archive Center for free and
uncomplicated access to archived ASTER imagery. Thanks also go to Peter
Messmer and Michael Galloy, Tech-X Corp., for their prompt responses to my
many cries for help with GPULib. I am especially grateful to my colleagues
Harry Vereecken and Allan Nielsen, the former for generously providing me
with the environment and resources needed to complete this book, the latter
for the continuing inspiration of our friendship and long-time collaboration.

Morton Canty
Preface to the Third Edition

A main incentive for me to write a third edition of this book stemmed from my
increasing enthusiasm for the Python programming language. I began to see
the advantage of illustrating the many image processing algorithms covered
in earlier editions of the text not only in the powerful and convenient, but
not inexpensive, ENVI/IDL world, but also on a widely available open source
platform. Python, together with the NumPy and Scipy packages, can hold its
own with any commercial array processing software system. Furthermore, the
Geospatial Data Abstraction Library (GDAL) and its Python wrappers allow
for great versatility and convenience in reading, writing and manipulating dif-
ferent image formats. This was enough to get me going on a revised textbook,
one which I hope will have appeal beyond the ENVI/IDL community.
Another incentive for a new edition was hinted at in the preface to the
previous edition, namely the lack of any discussion of the vast and increas-
ingly important field of radar remote sensing. Obviously this would be a topic
for (at least) a whole new book, so I have included material only on a very
special aspect of particular interest to me, namely multivariate statistical clas-
sification and change detection algorithms applied to polarimetric synthetic
aperture radar (polSAR) data. Up until recently, not many researchers or
practitioners have had access to this kind of data. However with the advent of
several spaceborne polarimetric SAR instruments such as the Japanese ALOS,
the Canadian Radarsat-2, the German TerraSAR-X and the Italian COSMO-
SkyMed missions, the situation has greatly improved. Chapters 5, 7 and 9
now include treatments of speckle filtering, image co-registration, supervised
classification and multivariate change detection with multi-look polSAR data.
The software associated with the present edition includes, along with the
ENVI/IDL extensions, Python scripts for all of the main processing, classifi-
cation and change detection algorithms. In addition, many examples discussed
in the text are illustrated with Python scripts as well as in IDL. The Appen-
dices C and D separately document the installation and use of the ENVI/IDL
and Python code. For readers who wish to use the Eclipse/Pydev development
environment (something which I highly recommend), the Python scripts are
provided in the form of a Pydev project.
What is missing in the Python world, of course, is the slick GUI provided
by ENVI. I have made no attempt to mimic an ENVI graphical environment
in Python, and the scripts provided content themselves with reading imagery
from, and writing results to, the file system. A rudimentary command line
script for RGB displays of multispectral band combinations in different his-

xvii
xviiiImage Analysis, Classification and Change Detection in Remote Sensing

togram enhancement modes is included.


For an excellent introduction to scientific computing in Python see Lang-
tangen (2009). The book by Westra (2013) provides valuable tips on geospatial
development in Python, including GDAL programming. The definitive refer-
ence on IDL is now certainly Galloy (2011), an absolute must for anyone who
uses the language professionally.
With version 5.0, a new ENVI graphics environment and associated API has
appeared which has a very different look and feel to the old “ENVI Classic”
environment, as it is officially referred to. Fortunately the classic environment
is still available and, for reasons of compatibility with previous versions, the
IDL programming examples in the text use the classic interface and its asso-
ciated syntax. Most of the ENVI/IDL extensions as documented in Appendix
C are provided both for the new as well as for the classic GUI/API.
I would like to express my appreciation to the German Aerospace Center
for permission to use images from the TerraSAR-X platform and to Henning
Skriver, DTU Space Denmark, for allowing me to use his EMISAR polari-
metric data. My special thanks go to Allan Nielsen and Frank Thonfeld for
acquainting me with SAR imagery analysis and to Rudolf Avenhaus for his
many helpful suggestions in matters statistical.

Morton Canty
Preface to the Fourth Edition

The fourth revision marks the completion of a transition, begun in the pre-
ceding edition, from ENVI/IDL to the Python language for implementing the
algorithms discussed in the text. It was with some hesitation that I abandoned
the comfort and convenience of the powerful ENVI/IDL environment and ven-
tured into the raw world of open source. But it has become apparent that open
source software is the future for scientific computing in general and for geo-
spatial analysis in particular. The popularity of R, JavaScript or Python in
the remote sensing community, the potential of machine learning software
such as TensorFlow for object recognition, the Python and JavaScript APIs
to the wonderful Google Earth Engine, the many open source mapping plat-
forms and servers like Mapbox, OpenLayers, Leaflet or the OpenStreetMap
project, the elegance of Jupyter notebooks for interactive and collaborative
development, the power of container technology like Docker for painless distri-
bution of scientific software, all of the advantages of these languages, tools and
platforms are freely available and under continual development by a gigantic
community of software engineers, both commercial and voluntary.
So I have jumped off the fence and onto the open source bandwagon in order
to ensure that the computer code used in the present version of the book will
be not only in line with the current trend, but also accessible to anyone,
student or scientist, with a computer and an Internet connection. Each of the
nine chapters of the text is now accompanied by its own Jupyter notebook
illustrating all, or almost all, of the concepts and algorithms presented in that
chapter. The Python scripts are uniformly command-line oriented so as to be
able to be started easily from within a notebook input cell. All of the software
is packaged into a single Docker container which, when run on the user’s
machine, serves the Jupyter notebooks to his or her favorite web browser.
The necessary packages and modules, including the Google Earth Engine and
TensorFlow APIs, are already built into the container so that there is no need
to install anything at all, apart from the Docker engine. This is of course great
for the reader, and for me it means no longer worrying about 32-bit vs. 64-
bit Windows vs. Linux vs. MacOS, or who has what pre-installed version of
which Python package. The container is pulled from DockerHub automatically
when run for the first time, and the source software can be cloned/forked from
GitHub. The details are all given in an appendix.
Had I approached this revision just a couple of years ago, I would have had
some misgivings about retaining the long and rigorous descriptions of neural
network training algorithms in Chapter 6 and Appendix B. Neural network

xix
xx Image Analysis, Classification and Change Detection in Remote Sensing

land cover classifiers had until recently gone somewhat out of fashion, giv-
ing way to random forests, support vector machines and the like. However,
given the present artificial intelligence craze, the mathematical detail in the
text should help to provide a solid background for anyone interested in un-
derstanding and exploiting deep learning techniques.
Like the earlier editions, this is not a text on programming or on the in-
tricacies of the various packages, tools and APIs referred to in the text. As
a solid introduction to scientific computing with Python, I would still recom-
mend Langtangen (2009) and, for TensorFlow, the book by Géron (2017). I
expect that I’m not alone in hoping for a good textbook on the Google Earth
Engine API. Fortunately the on-line documentation is excellent.
Apart from taking advantage of many of these exciting advances in open
source computing, the revised text continues to concentrate on an in-depth
treatment of pixel-oriented, data-driven, statistical methods for remote sens-
ing image processing and interpretation. The choice of topics and algorithms
is by no means all-encompassing and reflects strongly the author’s personal in-
terests and experience. Those topics chosen, however, are presented in depth
and from first principles. Chapters 1 and 2 on linear algebra and statistics
continue to be pretty much essential for an understanding of the rest of the
material. Especially new in the present edition is the discussion of an ele-
gant sequential change detection method for polarimetric synthetic aperture
radar imagery developed by Knut Conradsen and his colleagues at the Danish
Technical University. It has been a pleasure for me to be involved in its imple-
mentation, both in “conventional” Python and for the Google Earth Engine
Python and JavaScript APIs.
I would like to thank my editor Irma Shagla Britton at CRC Press for
waking me up to the idea of a fourth edition, and to give a big thank you to
the friendly, competent and infinitely patient GEE development team.

Morton Canty
Author Biography

Morton John Canty, now semi-retired, was a senior research scientist in the
Institute for Bio- and Geosciences at the Jülich Research Center in Germany.
He received his PhD in Nuclear Physics in
1969 at the University of Manitoba, Canada
and, after post-doctoral positions in Bonn,
Groningen and Marburg, began work in Jülich
in 1979. There, his principal interests have
been the development of statistical and game-
theoretical models for the verification of inter-
national treaties and the use of remote sensing
data for monitoring global treaty compliance.
He has served on numerous advisory bodies to
the German Federal Government and to the
International Atomic Energy Agency in Vi-
enna and was a coordinator within the Euro-
pean Network of Excellence on Global Mon-
itoring for Security and Stability, funded by
the European Commission. Morton Canty is the author of three monographs
in the German language: on the subject of non-linear dynamics (Chaos und
Systeme, Vieweg, 1995), neural networks for classification of remote sensing
data (Fernerkundung mit neuronalen Netzen, Expert, 1999) and algorithmic
game theory (Konfliktlösungen mit Mathematica, Springer 2000). The lat-
ter text has appeared in a revised English version (Resolving Conflicts with
Mathematica, Academic Press, 2003). He is co-author of a monograph on
mathematical methods for treaty verification (Compliance Quantified, Cam-
bridge University Press, 1996). He has published many papers on the sub-
jects of experimental nuclear physics, nuclear safeguards, applied game theory
and remote sensing and has lectured on nonlinear dynamical growth models
and remote sensing digital image analysis at Universities in Bonn, Berlin,
Freiberg/Saxony and Rome.

xxi
1
Images, Arrays, and Matrices

There are many Earth observation satellite-based sensors, both active and
passive, currently in orbit or planned for the near future. Representative of
these, we describe briefly the multispectral ASTER system (Abrams et al.,
1999) and the TerraSAR-X synthetic aperture radar satellite (Pitz and Miller,
2010). See Jensen (2018), Richards (2012) and Mather and Koch (2010) for
overviews of remote sensing satellite platforms.
The Advanced Spaceborne Thermal Emission and Reflectance Radiometer
(ASTER) instrument was launched in December 1999 on the Terra space-
craft. It is being used to obtain detailed maps of land surface temperature,
reflectance and elevation and consists of sensors to measure reflected solar
radiance and thermal emission in three spectral intervals:

• VNIR: Visible and near-infrared bands 1, 2, 3N, and 3B, in the spectral
region between 0.52 and 0.86 µm (four arrays of charge-coupled detectors
(CCDs) in pushbroom scanning mode).
• SWIR: Short wavelength infrared bands 4 to 9 in the region between
1.60 and 2.43 µm (six cooled PtSi-Si Schottky barrier arrays, pushbroom
scanning).
• TIR: Thermal infrared bands 10 to 14 covering a spectral range from 8.13
to 11.65 µm (cooled HgCdTe detector arrays, whiskbroom scanning).

The altitude of the spacecraft is 705 km. The across- and in-track ground
sample distances (GSDs), i.e., the detector widths projected through the sys-
tem optics onto the Earth’s surface, are 15 m (VNIR), 30 m (SWIR) and
90 m (TIR).∗ The telescope associated with the 3B sensors is back-looking at
an angle of 27.6o to provide, together with the 3N sensors, along-track stereo
image pairs. In addition, the VNIR camera can be rotated from straight down
(nadir) to ± 24o across-track. The SWIR and TIR instrument mirrors can be
pointed to ± 8.5o across-track. Like most platforms in this ground resolution
category, the orbit is near polar, sun-synchronous. Quantization levels are 8
bits for VNIR and SWIR and 12 bits for TIR. The sensor systems have an

∗ At the time of writing, both the VNIR and TIR systems are still producing good data.

The SWIR sensor was declared to be unusable in 2008.

1
2 Images, Arrays, and Matrices

FIGURE 1.1
ASTER color composite image (1000 × 1000 pixels) of VNIR bands 1 (blue),
2 (green), and 3N (red) over the town of Jülich in Germany, acquired on May
1, 2007. The bright areas are open cast coal mines.

average duty cycle of 8% per orbit (about 650 scenes per day, each 60×60 km2
in area) with revisit times between 4 and 16 days.
Figure 1.1 shows a spatial/spectral subset of an ASTER scene. The image is
a UTM (Universal Transverse Mercator) projection oriented along the satel-
lite path (rotated approximately 16.4o from north) and orthorectified using a
digital terrain model generated from the stereo bands.
Unlike passive multi- and hyperspectral imaging sensors, which measure
reflected solar energy or the Earth’s thermal radiation, synthetic aperture
radar (SAR) airborne and satellite platforms supply their own microwave
radiation source, allowing observations which are independent of time of day
3

FIGURE 1.2
A 5000×5000-pixel spatial subset of the HH polarimetric band of a TerraSAR-
X quad polarimetric image acquired over the Rhine River, Germany, in so-
called Stripmap mode. The data are slant-range, single-look, complex. The
gray-scale values correspond to the magnitudes of the complex pixel values.

or cloud cover. The radar antenna on the TerraSAR-X satellite, launched in


June, 2007, emits and receives X-band radar (9.65 GHz) in both horizontal and
vertical polarizations to provide surface imaging with a geometric resolution
from about 18 m (scanSAR mode, 10 km×150 km swath) down to 1 m (high-
resolution Spotlight mode, 10 km×5 km swath). It flies in a sun-synchronous,
near-polar orbit at an altitude of 514 km with a revisit time for points on
the equator of 11 days. Figure 1.2 shows a TerraSAR-X HH polarimetric
band (horizontally polarized radiation emitted and detected) acquired over
the Rhine River, Germany, in April, 2010. The data are at the single-look,
slant-range complex (SLC) processing level, and are not map-projected.
4 Images, Arrays, and Matrices

1.1 Multispectral satellite images


A multispectral, optical/infrared image such as that shown in Figure 1.1 may
be represented as a three-dimensional array of gray-scale values or pixel in-
tensities
gk (i, j), 1 ≤ i ≤ c, 1 ≤ j ≤ r, 1 ≤ k ≤ N,

where c is the number of pixel columns (also called samples) and r is the
number of pixel rows (or lines). The index k denotes the spectral band, of
which there are N in all. For data at an early processing stage a pixel may be
stored as a digital number (DN), often in a single byte so that 0 ≤ gk ≤ 255.
This is the case for the ASTER VNIR and SWIR bands at processing level L1A
(unprocessed reconstructed instrument data), whereas the L1A TIR data are
quantized to 12 bits (as unsigned integers) and thus stored as digital numbers
from 0 to 212 − 1 = 4095. Processed image data may of course be stored in
byte, integer or floating point format and can have negative or even complex
values.
The gray-scale values in the various bands encode measurements of the
radiance L∆λ (x, y) in wavelength interval ∆λ due to sunlight reflected from
some point (x, y) on the Earth’s surface, or due to thermal emission from
that surface, and focused by the instrument’s optical system along the array
of sensors. Ignoring all absorption and scattering effects of the intervening
atmosphere, the at-sensor radiance available for measurement from reflected
sunlight from a horizontal, Lambertian surface, i.e., a surface which scatters
reflected radiation uniformly in all directions, is given by

L∆λ (x, y) = E∆λ · cos θz · R∆λ (x, y)/π. (1.1)

The units are [W/(m2 · sr · µm)], E∆λ is the average spectral solar irradiance
in the spectral band ∆λ, θz is the solar zenith angle, R∆λ (x, y) is the surface
reflectance at coordinates (x, y), a number between 0 and 1, and π accounts
for the upper hemisphere of solid angle. The conversion between DN and
at-sensor radiance is determined by the sensor calibration as measured (and
maintained) by the satellite image provider. For example, for ASTER VNIR
and SWIR L1A data,

L∆λ (x, y) = A · DN/G + D.

The quantities A (linear coefficient), G (gain), and D (offset) are tabulated


for each of the detectors in the arrays and included with each acquisition.
Atmospheric scattering and absorption models may be used to deduce at-
surface radiance, surface temperature and emissivity or surface reflectance
from the observed radiance at the sensor. Reflectance and emissivity are di-
rectly related to the physical properties of the surface being imaged. See
Multispectral satellite images 5

Schowengerdt (2006) for a thorough discussion of atmospheric effects and their


correction.
Various conventions are used for storing the image array gk (i, j) in computer
memory or other storage media. In band interleaved by pixel (BIP) format, for
example, a two-channel, 3 × 3 pixel image would be stored as
g1 (1, 1) g2 (1, 1) g1 (2, 1) g2 (2, 1) g1 (3, 1) g2 (3, 1)
g1 (1, 2) g2 (1, 2) g1 (2, 2) g2 (2, 2) g1 (3, 2) g2 (3, 2)
g1 (1, 3) g2 (1, 3) g1 (2, 3) g2 (2, 3) g1 (3, 3) g2 (3, 3),
whereas in band interleaved by line (BIL) it would be stored as
g1 (1, 1) g1 (2, 1) g1 (3, 1) g2 (1, 1) g2 (2, 1) g2 (3, 1)
g1 (1, 2) g1 (2, 2) g1 (3, 2) g2 (1, 2) g2 (2, 2) g2 (3, 2)
g1 (1, 3) g1 (2, 3) g1 (3, 3) g2 (1, 3) g2 (2, 3) g2 (3, 3),
and in band sequential (BSQ) format as
g1 (1, 1) g1 (2, 1) g1 (3, 1)
g1 (1, 2) g1 (2, 2) g1 (3, 2)
g1 (1, 3) g1 (2, 3) g1 (3, 3)
g2 (1, 1) g2 (2, 1) g2 (3, 1)
g2 (1, 2) g2 (2, 2) g2 (3, 2)
g2 (1, 3) g2 (2, 3) g2 (3, 3).
In the computer language Python, augmented with the numerical package
NumPy, so-called row major indexing is used for arrays and the elements in
an array are numbered from zero. This means that, if a gray-scale image g
is assigned to a Python array variable g, then the intensity value g(i, j) is
addressed as g[j-1,i-1]. An N -band multispectral image is stored in BIP
format as an r × c × N array in NumPy, in BIL format as an r × N × c and in
BSQ format as an N × r × c array. So, for example, in BIP format the value
gk (i, j) is stored at g[j-1,i-1,k-1].
Auxiliary information, such as image acquisition parameters and georef-
erencing, is sometimes included with the image data on the same file, and
the format may or may not make use of compression algorithms. Examples
are the GeoTIFF∗ file format used, for instance, by Space Imaging Inc. for
distributing Carterra c imagery and which includes lossless compression, the
HDF-EOS (Hierarchical Data Format-Earth Observing System) files in which
ASTER images are distributed, and the PCIDSK format employed by PCI
Geomatics c with its image processing software, in which auxiliary informa-
tion is in plain ASCII and the image data are not compressed. ENVI ( c Harris
Geospatial Solutions) uses a simple “flat binary” file structure with an addi-
tional ASCII header file.

∗ GeoTIFF is an open source specification and refers to TIFF files which have geographic

(or cartographic) data embedded as tags within the file. The geographic data can be used
to position the image in the correct location and geometry on the screen of a geographic
information display.
6 Images, Arrays, and Matrices

Listing 1.1: Reading and displaying an image band in Python.


1 # !/ usr / bin / env python
2 # Name : ex1_1 . py
3 import numpy as np
4 import sys
5 from osgeo import gdal
6 from osgeo . gdalconst import GA_ReadOnly
7 import matplotlib . pyplot as plt
8
9 def disp ( infile , bandnumber ):
10 gdal . AllRegister ()
11 inDataset = gdal . Open ( infile , GA_ReadOnly )
12 cols = inDataset . RasterXSize
13 rows = inDataset . RasterYSize
14 bands = inDataset . RasterCount
15
16 image = np . zeros (( bands , rows , cols ))
17 f o r b i n range( bands ):
18 band = inDataset . GetRasterBand ( b +1)
19 image [b ,: ,:]= band . ReadAsArray (0 ,0 , cols , rows )
20 inDataset = None
21
22 # display NIR band
23 band = image [ bandnumber -1 ,: ,:]
24 mn = np . amin ( band )
25 mx = np . amax ( band )
26 plt . imshow (( band - mn )/( mx - mn ) , cmap = ’ gray ’)
27 plt . show ()
28
29 i f __name__ == ’ __main__ ’:
30 infile = sys . argv [1]
31 bandnumber = i n t ( sys . argv [2])
32 disp ( infile , bandnumber )

Listing 1.1 is a simple and fairly self-explanatory Python script which reads
a multispectral image into a Python/NumPy array in BSQ interleave format
with the aid of GDAL (the Geospatial Data Abstraction Library) and then
displays a spectral band using the matplotlib.pyplot package. The script
takes two arguments, the image filename and the band number to be displayed
and is run from the command prompt in Windows or from a console window
on Unix-like systems with the command python ex1 1.py *args. In the Unix
case, the “shebang” #! in the first line allows it to be run simply by typing
the filename, assuming the path to the env utility is /usr/bin/env. In this
book we will prefer to work almost exclusively from within Jupyter notebooks,
where the script can be executed with the so-called line magic %run without
Other documents randomly have
different content
am not, however, obliged to return it. No code of honor can compel
me to fire upon my Margaret’s father,” thought Ralph. Then aloud he
said:
“Very well, sir; my brother Frank has doubtless by this time reached
home, and will, with any friend whom you may appoint, arrange the
terms of the meeting;” and, lifting his hat, Ralph Houston, “more in
sorrow than in anger,” turned away.
“There is no honorable way of escaping it, Frank, else be sure that I
should not give him this meeting. As it is, I must receive his fire; but,
so help me Heaven; nothing shall induce me to return it,” said
Captain Houston, as he talked over the matter with his brother that
evening in the private parlor of the little inn at Belleview.
“Then, without a thought of defending yourself, you will stand up as a
mark to be shot at by the best marksman in the country? You will be
murdered! just simply murdered!” replied the younger man, in sorrow
and disgust.
“There is no help for it, Frank. I must meet him, must receive his fire,
and will not return it!”
“You will fall,” said the youth, in a voice of despair.
“Probably. And if I do, Frank, go to my dearest Margaret and bear to
her my last words. Tell her that I never so sinned against our mutual
faith as for one instant to doubt her perfect purity; tell her that I was
on my way to take her to my heart, to give her my name and to
defend her against the world, when this fatal quarrel was forced
upon me; tell her that I never fired upon her father, but that I died
with her name upon my lips and her love within my heart. If I fall, as I
probably shall, will you tell my widowed bride this?”
“I will! I will!” exclaimed Frank, in a voice of deep emotion.
Meanwhile the innocent and most unhappy cause of the impending
duel had passed a miserable week on the solitary island, in dread
anticipation of her father’s and her lover’s return, and with no one
near her to breathe one hopeful, comforting, or sustaining word to
her fainting heart.
It was late on the evening of the day of her father’s arrival that she
sat alone on the front piazza of her solitary dwelling, wrapped in
despairing thought, yet with every nerve acute with involuntary
vigilance, when, amid the low, musical semi-silence of the autumnal
night, the sound of a boat, pushed gratingly up upon the gravelly
beach, reached her listening ear.
And while she still watched and waited in breathless anxiety, she
perceived by the clear starlight the tall figure of a man, dressed in
the blue and buff uniform of an American officer, and in whose
stature, air, and gait she recognized her father, approaching the
house.
In joy, but still more in fear, she arose and hurried to meet him. But
so terrible was the trouble of her mind and the agitation of her frame,
that she could scarcely falter forth her inaudible words of welcome
before she sank exhausted in his arms.
In silence the soldier lifted her up, noticing even then how very light
was her wasted frame; in silence he kissed her cold lips, and bore
her onward to the house, and into her mother’s favorite parlor which
was already lighted up, and where he placed her in an easy-chair.
She sank back half fainting, while he stood and looked upon her, and
saw how changed she was.
Her attenuated form, her emaciated face, with its cavernous eyes,
hollow cheeks and temples, and pallid forehead, in fearful contrast
with her flowing black locks and mourning dress, gave her the
appearance of a girl in the very last stage of consumption. Yet this
was the work only of calumny, persecution, and abandonment.
Some one should write a book on Unindicted Homicides.
While Major Helmstedt gazed in bitterness of heart upon this
beautiful wreck of his fair, only daughter, she fixed her despairing
eyes upon him, and said:
“My father, do you wonder to find me here!”
For answer, he stooped and kissed her forehead.
“Father, my heart bleeds for you. This is a sorrowful welcome home
for the returning soldier.”
“Trouble not yourself about me, my child. Your own wrongs are
enough, and more than enough, to engage your thoughts. I know
those wrongs, and, by the soul of your mother, they shall be terribly
avenged!” said Major Helmstedt, in a low, deep, stern voice of
relentless determination.
“Father, oh, God! what do you mean?” exclaimed Margaret, in alarm.
“I mean, my much injured child, that every tear they have caused
you to shed, shall be balanced by a drop of heart’s blood, though it
should drain the veins of all who bear the name of Houston!”
“Oh, Heaven of heavens, my father!” cried Margaret, wringing her
pale hands in the extremity of terror. Then suddenly catching the first
hope that came, she said:
“But you cannot war upon women.”
“Upon all men that bear the name of Houston, then! Yet did not they
spare to war upon women—or rather worse, upon one poor,
defenseless girl! Enough! they shall bitterly repay it!”
“But father! my father! it was not the men; they were ever kind to me.
It was the women of the family, and even they were deceived by
appearances,” pleaded Margaret.
“It is you who are deceived! Mrs. Houston acted in concert with her
husband and his son!”
“Ralph? never, never, my father. My life, my soul, upon Ralph’s
fidelity!” exclaimed Margaret, as a warm glow of loving faith flowed
into and transfigured to angelic beauty her pale face.
“Miss Helmstedt, you are a fond and foolish girl, with all your sex’s
weak credulity. It is precisely Ralph Houston whom I shall hold to be
the most responsible party in this affair!”
“Oh! my God!”
These words were wailed forth in such a tone of utter despair, and
were accompanied by such a sudden blanching and sharpening of
all her features, that Major Helmstedt in his turn became alarmed,
and with what diplomacy he was master of, endeavored to modify
the impression that he had given. But his palpable efforts only
confirmed Margaret in her suspicion that he intended to challenge
Ralph, and made her more wary and watchful to ascertain if this
really were his purpose, so that, if possible, she might prevent this
meeting. That the challenge had been already given she did not
even suspect.
But from this moment the father and daughter were secretly arrayed
against each other; he to conceal from her the impending duel; she
to discover and prevent the meeting. And while he talked to her with
a view of gradually doing away the impression that his first violent
words had made upon her mind, she watched his countenance
narrowly, keeping the while her own counsel. But it was not entirely
the wish to conceal her own anguish of doubt and anxiety, but
affectionate interest in him, that caused her at length to say:
“But, my dear father, you are just off a long, harassing journey; you
are, indeed, greatly exhausted; your countenance is quite haggard;
you are needing rest and refreshment. Let me go now and give the
orders, while you occupy my sofa. Say, what shall I bring you, dear
father?”
“Nothing, nothing, Margaret; I cannot——” began Major Helmstedt;
but then suddenly reflecting, he said: “Yes, you may send me up a
cup of coffee, and any trifle with it that may be at hand. No, I thank
you, Margaret, you need not draw the sofa forward. I am going to my
study, where I have letters to write. Send the refreshments thither.
And send—let me see—yes! send Forrest to me.”
“Very well, my dear father,” replied the maiden, leaving the room.
“‘Letters to write!’ ‘letters to write!’ and ‘send Forrest.’ So late at
night, and just as he has returned home, oh, my soul!” she cried,
within herself, as she went into the kitchen to give her orders.
When the tray was ready, Forrest was told to take it up to his
master’s study.
Margaret, after a little hesitation, drawn by her strong anxiety,
followed, her light footsteps on the stairs and through the hall waking
no echo. As she approached the door of her father’s study, she
heard the words:
“Forrest, take this case of pistols downstairs and thoroughly clean
them; let no one see what you are about. Then have a boat—the
soundest in the fleet—ready to take me to the landing below the
burial ground, at Plover’s Point. Do you prepare to go with me, and—
listen farther. At about daybreak to-morrow, a gentleman will arrive
hither. Be on the watch, and quietly bring him to this room. Have
breakfast served for us here, and the boat ready for our departure
when we rise from the table. And mind, execute all these orders in
strict privacy, and breathe no word of their purport to any living
creature. Do you understand?”
“I think I do, sir,” replied the astonished negro, who imperfectly
comprehended the affair.
Margaret knew all now. Her father had challenged her betrothed. The
only two beings whom she loved supremely on this earth, were in a
few hours hence to meet in mortal combat.
With a heart that seemed paralyzed within her suffocating bosom,
she crept, reeling, to her own chamber, and with the habitual instinct
of soliciting Divine counsel and assistance, she sank upon her knees
beside the bed. But no petition escaped her icy lips, or even took the
form of words in her paralyzed brain; her intellect seemed frozen
with horror; and her only form of prayer was the eloquent, mute
attitude, and the intense yearning of the suffering heart after the All
Merciful’s help and pity. She remained many minutes in this posture
of silent prayer, before the power of reflection and of language
returned to her, and even then her only cry was:
“Oh, God of pity, have mercy on them! Oh, God of strength, help and
save!”
Then still looking to the Lord for guidance, she tried to think what
was best to be done. It was now ten o’clock. Day would break at
four. There were but six hours of a night to do all, if anything could
be done. But what, indeed, could she do? Cut off by the bay from all
the rest of the world, and with fifteen miles of water between herself
and the nearest magistrate, what could the miserable maiden do to
prevent this duel between her father and her lover? To a religious
heart filled to overflowing with love and grief, and resolved upon
risking everything for the safety of the beloved, almost all things are
possible. Her first resolution was the nearly hopeless one of going to
her father and beseeching him to abandon his purpose. And if that
failed, she had in reverse a final, almost desperate determination.
But there was not a moment to be lost.
Still mentally invoking Divine aid, she arose and went to the door of
her father’s study. It was closed; but turning the latch very softly, she
entered unperceived.
Major Helmstedt sat at his table, so deeply absorbed in writing as not
to be conscious of her presence, although his face was toward the
door. That face was haggard with care, and those keen, strong eyes
that followed the rapid gliding of his pen over the paper were
strained with anxiety. So profound was his absorption in his work that
the candles remained unsnuffed and burning with a murky and lurid
light, and the cup of coffee on his table sat cold and untouched.
Margaret approached and looked over his shoulder.
It was his last will and testament that he was engaged in preparing.
The sight thrilled his daughter with a new horror. Meekly she crept to
his side and softly laid her hand upon his shoulder, and gently
murmured:
“Father, my dear father!”
He looked up suddenly, and in some confusion.
“What, Margo! not asleep yet, my girl? This is a late hour for young
eyes to be open. And yet I am glad that you came to bid me good-
night before retiring. It was affectionate of you, Margo,” he said,
laying down his pen, putting a blotter over his writing, and then
drawing her to his side in a close embrace—“yes, it was affectionate
of you, Margo; but ah, little one, no daughter loves as a true wife
does. I have been thinking of your mother, dear.”
“Think of her still, my father,” replied the maiden, in a voice of thrilling
solemnity.
Major Helmstedt’s countenance changed, but, controlling himself, he
pressed a kiss upon his daughter’s brow, and said:
“Well, well, I will not keep you up. God bless you, my child, though I
cannot. Good-night!” and with another kiss he would have dismissed
her. But, softly laying her hand upon his right hand, she asked, in a
voice thrilling with earnestness:
“Oh, my father, what is this that you are about to do?”
“Margaret, no prying into my private affairs—I will not suffer it!”
exclaimed Major Helmstedt, in disturbed voice.
“My father, there is no need of prying; I know all! Providence, for His
good purposes, has given the knowledge into my hands. Oh, did you
think that He would permit this terrible thing to go on uninterruptedly
to its bloody termination?”
“What mean you, girl?”
“Father, forgive me; but I overheard and understood your orders to
Forrest.”
“By my soul, Margaret, this is perfectly insufferable!” exclaimed
Major Helmstedt, starting up, and then sinking back into his chair.
But softly and suddenly Margaret dropped at his feet, clasped his
knees, and in a voice freighted with her heart’s insupportable
anguish, cried:
“Father! my father! hear me! hear me! hear your own lost
Marguerite’s heartbroken child, and do not make her orphaned and
widowed in one hour!”
“Orphaned and widowed in one hour!”
“Yes, yes, and most cruelly so, by the mutual act of her father and
her husband.”
“By her father and husband?”
“Yes, yes. Am I not Ralph Houston’s promised, sworn wife? Oh, my
father!”
“Death, girl! You call yourself his promised wife; you pray me to stay
my hand, nor avenge your wrongs, nor vindicate my own honor; you
who have been calumniated, insulted, and expelled from his house?”
“Not by him, father! not with his knowledge or consent! Oh, never!
never! My life, my soul, upon his stainless faith!”
“My daughter, rise and leave, I command you,” said Major
Helmstedt, giving his hand to assist her.
But she clung to his knees and groveled at his feet, crying:
“Father! father! pardon and hear me; hear me for my dead mother’s
sake! hear your Marguerite’s orphan girl! do not make her a widow
before she is a wife! My father, do not, oh, do not meet my betrothed
in a duel! He was your oldest friend, your brother-in-arms, your
promised son; he has stood by your side in many a well-fought
battle; in camp and field you two have shared together the dangers
and glories of the war. How can you meet as mortal foes? Crowned
with victory, blessed with peace, you were both coming home—you
to your only daughter, he to his promised bride—both to a devoted
girl, who would have laid out her life to make your mutual fireside
happy; but whose heart you are about to break! Oh, how can you do
this most cruel deed? Oh! it is so horrible! so horrible, that you two
should thus meet. Dueling is wicked, but this is worse than dueling!
Murder is atrocious, but this is worse than murder! This is parricide!
this is the meeting of a father and son, armed each against the
other’s life! A father and a son!”
“Son! no son or son-in-law of mine, if that is what you mean.”
“Father, father, do not say so! He is the sworn husband of your only
child. My hand, with your consent, was placed in his by my dying
mother’s hand. He clasped my fingers closely, promising never to
forsake me! A promise made to the living in the presence of the
dying! A promise that he has never retracted, and wishes never to
retract. My soul’s salvation upon Ralph Houston’s honor!”
“Margaret Helmstedt! put the last seal to my mortification, and tell me
that you love this man—this man whose family has spurned you!”
“I love him—for life, and death, and eternity!” she replied, in a tone
vibrating with earnestness.
“You speak your own degradation, miserable girl.”
“This is no time, Heaven knows, for the cowardice of girlish shame.
Father, I love him! For three long years I have believed myself his
destined wife. Long before our betrothal, as far back, or farther,
perhaps, than memory reaches, I loved him, and knew that he loved
me, and felt that in some strange way I belonged finally to him. Long,
long before I ever heard of courtship, betrothal, or marriage, I felt in
my deepest heart—and knew he felt it too—that Ralph was my final
proprietor and prince, that I, at last and forever, was his own little
Margaret—ay! as your Marguerite was yours, my father. And always
and ever, in all the changes of our life, in joy and in sorrow, in
presence and in absence, I seemed to repose sweetly in his heart as
a little bird in its nest, loving him too quietly and securely to know
how deeply and strongly. But oh, my father, it has remained for the
anguish of this day to teach me how, above all creatures, I love my
promised husband, even as my mother loved hers. The blow that
reaches Ralph’s heart would break my own. Father, I can conceive
this globe upon which we live, with all its seas and continents, its
mountains, plains and cities, its whole teeming life, collapsing and
sinking out of sight through space, and yet myself continuing to live,
somewhere, in some sphere of being; but, my father, I cannot
conceive of Ralph’s death and my own continued life, anywhere, as
possible! for there, at that point, all sinks into darkness, chaos,
annihilation! Swift madness or death would follow his loss! Oh, my
father, say, is he not my husband? Oh, my father, will you make your
child a widow, a widow by her father’s hand?”
“Margaret, this is the very infatuation of passion!”
“Passion! Well, since grief and terror and despair have made my
bosom so stormy, you may call it so! else never should my lifelong,
quiet, contented attachment to Ralph be termed a passion, as if it
were the feverish caprice of yesterday. But oh, Heaven! all this time
you are not answering me. You do not promise that you will not meet
him. Father, I cannot die of grief, else had I long since been lying
beside your other Marguerite! But I feel that I may go mad, and that
soon. Already reason reels with dwelling on this impending duel! with
the thought that a few hours hence——! Father, if you would not
have your Marguerite’s child go mad, curse the author of her being,
and lay desperate hands upon her own life, forgo this duel! do not
make her a widowed bride!”
“Wretched girl, it were better that you were dead, for come what may,
Margaret, honor must be saved.”
“Then you will kill him! My father will kill my husband!”
“Why do you harp upon this subject forever? Shall I not equally risk
my own life?”
“No, no, no! he will never risk hurting a hair of your head. My life and
soul upon it, he will fire into the air! I know and feel what he will do,
here, deep in my heart. I know and feel what has been done. Father,
you met him in your blind rage, you gave him no chance of
explanation, but goaded and taunted, and drove him to the point of
accepting your challenge. You will meet him, you will murder him!
and I, oh, I shall go mad, and curse the father that gave me life, and
him death!” she said, starting up and wildly traversing the floor.
“‘Still waters run deep!’ Who would have supposed this quiet maiden
had inherited all Marguerite De Lancie’s strength of feeling?” thought
Major Helmstedt, as in a deep trouble he watched his daughter’s
distracted walk.
Suddenly, as that latent and final resolution, before mentioned,
recurred to her mind, she paused, and came up to her father’s side,
and said:
“Father, this thing must go no farther!”
“What mean you, Margaret?”
“This duel must not take place.”
“What absurdity—it must come off! Let all be lost so honor is saved!”
“Then listen well to me, my father,” she said, in the long, deep, quiet
tone of fixed determination; “this duel shall not take place!”
“Girl, you are mad. ‘Shall not?’”
“Shall not, my father!”
“What preposterous absurdity! Who will prevent it?”
“I will!”
“You! Come, that is best of all. How do you propose to do it, fair
daughter?”
“I shall lay the whole matter before the nearest magistrate!”
“Poor girl, if I did not pity you so deeply, I should smile at your folly.
Why, Margaret, the nearest magistrate is fifteen miles off. It is now
eleven o’clock at night, and the proposed meeting takes place at five
in the morning!”
“Then the more reason for haste, my father, to save you from a
crime. I will order a boat and depart immediately,” said Margaret,
going to the bell-rope and giving it a sudden peremptory pull.
“Oh, then I see that this will not do. You are desperate, you are
dangerous, you must be restrained,” said Major Helmstedt, rising
and approaching his daughter.
“Father, what mean you now? You would not—you, a gentleman, an
officer, would not lay violent hands on your daughter?” she said,
shrinking away in amazement.
“In an exigency of this kind my daughter leaves me no alternative.”
“No, no! You would not use force to hinder me in the discharge of a
sacred duty?”
“Margaret, no more words. Come to your room,” he said, taking her
by the arm, and with gentle force conducting her to the door of her
own chamber, in which he locked her securely.
Knowing resistance to be both vain and unbecoming, Margaret had,
for the time, quietly submitted. She remained sitting motionless in the
chair in which he had placed her, until she heard his retreating
footsteps pause at the door of his study, and heard him enter and
lock the door behind him.
Then she arose and stepped lightly over the carpeted floor, and
looked from the front window out upon the night.
A dark, brilliant starlight night, with a fresh wind that swayed the
branches of the trees.
Almost omnipotent is the religious heart; willing to sink all things for
the salvation of the beloved.
The means of escape, and of preventing the duel, were quickly
devised by her suggestive mind. Her chamber was on the second
floor front. A grape vine of nearly twenty years’ growth reached her
window, and climbed up its side and over its top. The intertwined and
knotted branches, thick as a man’s wrist, and strong as a cable,
presented a means of descent safe and easy as that of a staircase.
And once free of the house, the course of the brave girl was clear.
There was no time to be lost. It was now half-past eleven o’clock.
The household, except her father and the servant whom he had
ordered to watch with him, was wrapped in sleep. Her father she
knew to be deeply engaged in writing his will in the study. Forrest
she supposed to be employed in cleaning the pistols in the back
kitchen.
There was nothing then to interrupt her escape but the dogs, who
before recognizing would surely break out upon her. But there was
little to dread from that circumstance. The barking of the dogs was
no unusual event of the night. Any noise in nature, the footstep of a
negro walking out, the spring of a startled squirrel, the falling of a nut
or a pine cone, was frequently enough to arouse their jealous
vigilance, and provoke a canine concert. Only when the barking was
very prolonged was attention usually aroused. Of this contingency
there was no danger. They would probably break out in a furious
onslaught, recognize her and be still.
But there was another serious difficulty. Margaret was very feeble;
weeks of mental anguish, with the consequent loss of appetite and
loss of sleep, had so exhausted her physical nature that not all the
proverbial power of the mind over the body, the spirit over the flesh,
could impart to her sufficient strength for an undertaking, that, in her
stronger days, would have taxed her energies to the utmost. A
restorative was absolutely necessary. A few drops of distilled
lavender water—a favorite country cordial—gave her a fictitious
strength.
Then tying on her black velvet hood, and her short black camlet
riding cloak, she prepared to depart. First, she bolted the door on the
inside that her father might not enter her room to ascertain her
absence. Then she softly hoisted the window, and with perfect ease
crossed the low sill and stepped upon the friendly vine, where she
remained standing while she let down the window and closed the
blinds.
Thus having restored everything to its usual order, she commenced
her descent. Holding to the vines, stepping cautiously, and letting
herself down slowly, she at length reached the ground safely.
Now for the dogs. But they were quiet. Their quick instincts were
truer than her fears, and she passed on undisturbed.
How still and brilliant the starlight night. No sound but the sighing of
the wind in the trees, and the trilling of the insects that wake at eve
to chirp till day; and all distinctly, yet darkly visible, like a scene
clearly drawn in Indian ink upon a gray ground.
She passed down through the garden, the orchard, and the stubble
field to the beach, where her little sailboat, The Pearl Shell, lay.
For the trip that she contemplated of fifteen miles up the mouth of
the river, a rowboat would have been far the safer. But Margaret was
too weak for such prolonged labor as the management of the oar for
two or three hours must necessitate. The sailboat would only require
the trifling exertion of holding the tiller, and occasionally shifting the
sails. Happily, the tide was in and just about to turn; the boat was,
therefore, afloat, though chained to the boathouse, and so needed
no exertion to push her off. Margaret went on board, untied the tiller,
hoisted the sails, unlocked the chain and cast loose. She had but
time to spring and seize the tiller before the wind filled the sails and
the boat glided from the shore.
So far all had gone marvelously well. Let who would discover her
escape now, she was safe from pursuit. Let who would follow, she
could not be overtaken. Her boat was beyond measure the swiftest
sailer of the island fleet. True, before this fresh wind the boat might
capsize, especially as there was no one to manage it except herself,
who to shift the sails must sometimes let go the tiller. But Margaret
was without selfish, personal fear; her purpose was high, and had
been so far providentially favored; she would, therefore, believe in no
accidents, but trust in God.
And what a strange scene was this, in which the solitary girl-mariner
was out upon the lonely sea.
The broad canopy of heaven, of that deep, dark, intense blue of
cloudless night, was thickly studded with myriads of stars, whose
reflection in the mirror of the sea seemed other living stars disporting
themselves amid the waves. Far away over the wide waters, darker
lines upon the dark sea suggested the distant shores and headlands
of the main. Straight before her flying boat, two black points, miles
apart, indicated the entrance to the mouth of the Potomac River. She
steered for the lower, or Smith’s Point.
Under happier circumstances, the lonely night ride over the dark
waters would have charmed the fancy of the fearless and
adventurous girl. Now her only emotion was one of anxiety and
haste. Taking Smith’s Point for her “polar star,” she gave all her sail
to the wind. The boat flew over the water. I dare scarcely say in how
marvelously short a time she reached this cape. This was the
longest part of her voyage.
Hugging the Northumberland coast, she soon reached and doubled
Plover’s Point, and ran up into the little cove, the usual landing
place, and pushed her boat upon the sands.
She next sprang out, secured the boat to a post, and began to climb
the steep bank, that was thickly covered with a growth of pines, from
which the place took its name.
Here danger of another and more appalling form threatened her.
Fugitive slaves, than whom a more dangerous banditti can nowhere
be found, were known to infest this coast, where by day they hid in
caves and holes, and by night prowled about like wild beasts in
search of food or prey. More than to meet the wildcat or the wolf, that
were not yet banished from these woods, the maiden dreaded to
encounter one of these famished and desperate human beasts!
Lifting her heart in prayer to God for assistance, she passed
courageously on her dark and dangerous way; starting at the sound
of her own light footsteps upon some crackling, fallen branch, and
holding her breath at the slight noise made by the moving of a rabbit
or a bird in the foliage. At last she reached the summit of the wooded
hill, and came out of the pine thicket on to the meadow. Then there
was a fence to climb, a field to cross, and a gate to open before she
reached the wooded lawn fronting the house. There the last peril,
that of the watchdogs, awaited her. One mastiff barked furiously as
she approached the gate; as she opened it, the whole pack broke in
full cry upon her.
She paused and stood still, holding out one hand, and saying, gently:
“Why, Ponto! Why, Fido! What is the matter, good boys?”
The two foremost recognized and fawned upon her, and under their
protection, as it were, she walked on through the excited pack, that,
one by one, dropped gently under her influence, and walked quietly
by her side.
So she reached the front of the house, passed up the piazza, and
rang the bell. Peal upon peal she rung before she could make any
one in that quiet house hear.
At last, however, an upper window was thrown up, and the voice of
Dr. Hartley asked:
“Who’s there?”
“It is I, Dr. Hartley. It is I, Margaret Helmstedt! come to you on a
matter of life and death!”
“You! You, Margaret! You, at this hour! I am lost in wonder!”
“Oh, come down, quickly, quickly, or it will be too late!”
Evidently believing this to be an imminent necessity for his
professional services, the doctor drew in his head, let down the
window, hastily donned his apparel, and came down to admit his
visitor.
Leading her into the sitting-room, he said:
“Now, my dear, who is ill? And what, in the name of all the saints,
was the necessity of your coming out at this time of night with the
messenger?”
“Dr. Hartley, look at me well. I came with no messenger. I left the
island at midnight, and crossed the bay, and came up the river
alone.”
“Good Heaven, Miss Helmstedt! Margaret! what is it you tell me?
What has happened?” he asked, terrified at the strange words and
the ghastly looks of the girl.
“Dr. Hartley, my father has challenged Ralph Houston. They meet
this morning, in the woods above the family burial ground. I escaped
from the room in which my father had locked me, and came to give
information to the authorities, that they may, if possible, stop this
duel. What I desire particularly of your kindness is that you will go
with me to Squire Johnson’s, that I may lodge the necessary
complaint. I regret to ask you to take this trouble; but I myself do not
know the way to Squire Johnson’s house.”
“Margaret, my dear, I am exceedingly grieved to hear what you have
told me. How did this happen? What was the occasion of it?”
“Oh, sir, spare me! in mercy spare me! There is, indeed, no time to
tell you now. What we are to do should be done quickly. They meet
very, very early this morning.”
“Very well, Margaret. There is no necessity for your going to Squire
Johnson’s, for, indeed, you are too much exhausted for the ride. And
I am now suffering too severely with rheumatism to bear the journey.
But I will do better. I will put a servant on a swift horse, and dispatch
a note that will bring Mr. Johnson hither. We can go hence to the
dueling ground and prevent the meeting. Will not that be best?”
“So that we are in time—anything, sir.”
Dr. Hartley then went out to rouse the boy whom he purposed to
send, and after a few moments returned, and while the latter was
saddling the horse, he wrote the note, so that in ten minutes the
messenger was dispatched on his errand.
Day was now breaking, and the house servants were all astir. One of
them came in to make the fire in the parlor fireplace, and Dr. Hartley
gave orders for an early breakfast to be prepared for his weary
guest.
Missing Clare from her customary morning haunts, Margaret
ventured to inquire if she were in good health.
At the mention of his daughter’s name, Dr. Hartley recollected now,
for the first time, that there might be some good reason for treating
his young visitor with rebuking coldness, and he answered, with
distant politeness, that Clare had gone to pay her promised visit to
her friends at Fort Warburton.
Margaret bore this change of manner in her host with her usual
patient resignation. And when the cloth was laid, and breakfast was
placed upon the table, and the doctor, with professional authority
rather than with hospitable kindness, insisted that the exhausted girl
should partake of some refreshment, she meekly complied, and
forced herself to swallow a cup of coffee, though she could constrain
nature no farther.
They had scarcely risen from the table, before the messenger
returned with the news that Squire Johnson had left home for
Washington City, and would be absent for several days.
“Oh, Heaven of heavens! What now can be done?” exclaimed
Margaret, in anguish.
“Nothing can be done by compulsion, of course, but something may
be accomplished by persuasion. I will go with you, Miss Helmstedt,
to the ground, and use every friendly exertion to effect an adjustment
of the difficulties between these antagonists,” said Dr. Hartley.
“Oh, then, sir, let us hasten at once. No time is to be lost!” cried
Margaret, in the very extremity of anxiety.
“It is but a short distance, Miss Helmstedt. Doubtless we shall be in
full time,” replied the doctor, buttoning up, his coat and taking down
his hat from the peg.
Margaret had already, with trembling fingers, tied on her hood.
They immediately left the house.
“What time did you say they met, Miss Helmstedt?”
“I said, ‘very early,’ sir. Alas, I do not know the time to the hour. I fear,
I fear—oh, let us hasten, sir.”
“It is but five o’clock, Margaret, and the distance is short,” said the
doctor, beginning to pity her distress.
“Oh, God! perhaps it was at five they were to meet. Oh, hasten!”
Their way was first through the lawn, then through the stubble field,
then into the copse wood that gradually merged in the thick forest
behind the burial ground.
“Do you know the exact spot of the purposed meeting, Margaret?”
inquired the doctor.
“Oh, no, sir, I do not. I only know that my father gave orders for the
boat to be in readiness to take him (and his second, of course) to the
beach below the burial ground at this point. Now, as the beach is
narrow, and the burial ground too sacred a place for such a purpose,
I thought of these woods above it.”
“Exactly; and there is a natural opening, a sort of level glade, on the
top of this wooded hill, that I think likely to be the place selected. We
will push forward to that spot.”
They hurried on. A walk of five minutes brought them to within the
sound of voices, that convinced them that they were near the dueling
ground.
A few more rapid steps led them to a small, level, open glade, on the
summit of the wooded hill.
Oh, Heaven of heavens! What a sight to meet the eyes of a daughter
and a promised wife!
The ground was already marked off. In the drawing of the lots it
seemed that the best position had fallen to her father, for he stood
with his back to the rising sun, which shone full into the face of
Ralph, at the same time dazzling his eyes, and making him the
fairest mark for the best marksman in the country.
At right angles with the principals stood the seconds, one of them
having a handkerchief held in his hand, while the other prepared to
give the word.
Margaret had not seen her betrothed for three years, and now, oh,
agony insupportable, to meet him thus!
So absorbed were the duelists in the business upon which they met,
and so quietly had she and her escort stolen upon the scene, that
the antagonists had perceived no addition to their party, but went on
with their bloody purpose.
At the very entrance of the newcomers upon the scene, the second
of Major Helmstedt gave the word:
“One—two—three—fire!” Frank Houston dropped the handkerchief,
Ralph fired into the air, and Margaret, springing forward, struck up
the pistol of her father, so that it was discharged harmlessly into the
upper branches of an old tree.
All this transpired in a single instant of time, so suddenly and
unexpectedly, that until it was over no one knew what had happened.
Then followed a scene of confusion difficult or impossible to
describe.
Major Helmstedt was the first to speak. Shaking Margaret’s hand
from his arm, he demanded, in a voice of concentrated rage:
“Miss Helmstedt, what is the meaning of this? How durst you come
hither?”
Margaret, dropping upon her knees between the combatants and
lifting up both arms, exclaimed:
“Oh, father! father! Oh, Ralph! Ralph! bury your bullets in this broken
heart if you will, but do not point your weapons against each other!”
“Margaret, my beloved!” began Ralph Houston, springing to raise
her, but before he could effect his purpose, Major Helmstedt had
caught up his daughter, and with extended hands, exclaimed:
“Off, sir! How durst you? Touch her not! Address her not at your peril!
Dr. Hartley, since you attended this self-willed girl hither, pray do me
the favor to lead her from the scene. Gentlemen, seconds, I look to
you to restore order, that the business of our meeting may proceed.”
“Father, father!” cried Margaret, clasping his knees in an agony of
prayer.
“Degenerate child, release me and begone! Dr. Hartley, will you
relieve me of this girl?”
“Major Helmstedt, your daughter and myself came hither in the hope
of mediating between yourself and your antagonist.”
“Mediating! Sir, there is no such thing as mediation in a quarrel like
this! Since you brought my daughter hither, will you take her off, sir, I
ask you?” thundered Major Helmstedt, striving to unrivet the clinging
arms of his child.
“Father, father! Hear me, hear me!” she cried.
“Peace, girl, I command you. Fool that you are, not to see that this is
a mortal question, that can only be resolved in a death meeting
between us. Girl, girl, girl! are you a Helmstedt? Do you know that
the family of this man have made dishonoring charges upon you?
Charges that, by the Heaven above, can be washed out only in life’s
blood? Take her away, Hartley.”
“Father, father! Oh, God! the charges! the charges that they have
made! they are true! they are true!” cried Margaret, clinging to his
arms, while she hid her face upon his bosom.
Welcome to our website – the ideal destination for book lovers and
knowledge seekers. With a mission to inspire endlessly, we offer a
vast collection of books, ranging from classic literary works to
specialized publications, self-development books, and children's
literature. Each book is a new journey of discovery, expanding
knowledge and enriching the soul of the reade

Our website is not just a platform for buying books, but a bridge
connecting readers to the timeless values of culture and wisdom. With
an elegant, user-friendly interface and an intelligent search system,
we are committed to providing a quick and convenient shopping
experience. Additionally, our special promotions and home delivery
services ensure that you save time and fully enjoy the joy of reading.

Let us accompany you on the journey of exploring knowledge and


personal growth!

textbookfull.com

You might also like