@@ -70,13 +70,13 @@ the terms matrix and array will be used interchangeably.
70
70
71
71
::::::::::::::::::::::::::::::::::::::::::::::::::
72
72
73
- ## Working with Pixels
73
+ ## Working with pixels
74
74
75
75
As noted, in practice,
76
76
real-world images will typically be made up of a vast number of pixels,
77
77
and each of these pixels will be one of potentially millions of colours.
78
78
While we will deal with pictures of such complexity shortly,
79
- let's start our exploration with 15 pixels in a 5 X 3 matrix with 2 colours and
79
+ let's start our exploration with 15 pixels in a 5 x 3 matrix with 2 colours and
80
80
work our way up to that complexity.
81
81
82
82
First, the necessary imports:
@@ -96,7 +96,7 @@ enables us to read and write images.
96
96
97
97
:::::::::::::::::::::::::::::::::::::::: callout
98
98
99
- ## Import Statements in Python
99
+ ## Import statements in Python
100
100
101
101
In Python, the ` import ` statement is used to
102
102
load additional functionality into a program.
@@ -117,7 +117,7 @@ import skimage as ski # form 4, load all of skimage into an object call
117
117
118
118
:::::::::::::::: spoiler
119
119
120
- ## Further Explanation
120
+ ## Further explanation
121
121
122
122
In the example above, form 1 loads the entire scikit-image library into the
123
123
program as an object.
@@ -407,7 +407,7 @@ Here we only have a single channel in the data and utilize a grayscale color map
407
407
to represent the luminance, or intensity of the data and correspondingly
408
408
this channel is referred to as the luminance channel.
409
409
410
- ## Even More Colours
410
+ ## Even more colours
411
411
412
412
This is all well and good at this scale,
413
413
but what happens when we instead have a picture of a natural landscape that
@@ -421,7 +421,7 @@ for individual contributions to a pixel to be adjusted independently.
421
421
This ability to manipulate properties of groups of pixels separately will be
422
422
key to certain techniques explored in later chapters of this lesson.
423
423
To get started let's see an example of how different dimensions of information
424
- combine to produce a set of pixels using a 4 X 4 matrix with 3 dimensions
424
+ combine to produce a set of pixels using a 4 x 4 matrix with 3 dimensions
425
425
for the colours red, green, and blue.
426
426
Rather than loading it from a file, we will generate this example using NumPy.
427
427
@@ -524,7 +524,7 @@ When all three channels are combined though,
524
524
the blue light of those squares is being diluted by the relative strength
525
525
of red and green being mixed in with them.
526
526
527
- ## 24-bit RGB Colour
527
+ ## 24-bit RGB colour
528
528
529
529
This last colour model we used,
530
530
known as the * RGB (Red, Green, Blue)* model, is the most common.
@@ -846,7 +846,7 @@ JPEG images can be viewed and manipulated easily on all computing platforms.
846
846
## Examining actual image sizes (optional, not included in timing)
847
847
848
848
Let us see the effects of image compression on image size with actual images.
849
- The following script creates a square white image 5000 X 5000 pixels,
849
+ The following script creates a square white image 5000 x 5000 pixels,
850
850
and then saves it as a BMP and as a JPEG image.
851
851
852
852
``` python
0 commit comments