Skip to content

Commit 220126a

Browse files
author
Thomas Grainger
committed
cleanup headings from pandoc
1 parent 15ce036 commit 220126a

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

README.rst

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ Transforms are common image transforms. They can be chained together
201201
using ``transforms.Compose``
202202

203203
``transforms.Compose``
204-
~~~~~~~~~~~~~~~~~~~~~~
204+
^^^^^^^^^^^^^^^^^^^^^^
205205

206206
One can compose several transforms together. For example.
207207

@@ -216,10 +216,10 @@ One can compose several transforms together. For example.
216216
])
217217
218218
Transforms on PIL.Image
219-
-----------------------
219+
~~~~~~~~~~~~~~~~~~~~~~~
220220

221221
``Scale(size, interpolation=Image.BILINEAR)``
222-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
222+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
223223

224224
Rescales the input PIL.Image to the given 'size'. 'size' will be the
225225
size of the smaller edge.
@@ -229,14 +229,14 @@ height / width, size) - size: size of the smaller edge - interpolation:
229229
Default: PIL.Image.BILINEAR
230230

231231
``CenterCrop(size)`` - center-crops the image to the given size
232-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
232+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
233233

234234
Crops the given PIL.Image at the center to have a region of the given
235235
size. size can be a tuple (target\_height, target\_width) or an integer,
236236
in which case the target will be of a square shape (size, size)
237237

238238
``RandomCrop(size, padding=0)``
239-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
239+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
240240

241241
Crops the given PIL.Image at a random location to have a region of the
242242
given size. size can be a tuple (target\_height, target\_width) or an
@@ -245,13 +245,13 @@ If ``padding`` is non-zero, then the image is first zero-padded on each
245245
side with ``padding`` pixels.
246246

247247
``RandomHorizontalFlip()``
248-
~~~~~~~~~~~~~~~~~~~~~~~~~~
248+
^^^^^^^^^^^^^^^^^^^^^^^^^^
249249

250250
Randomly horizontally flips the given PIL.Image with a probability of
251251
0.5
252252

253253
``RandomSizedCrop(size, interpolation=Image.BILINEAR)``
254-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
254+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
255255

256256
Random crop the given PIL.Image to a random size of (0.08 to 1.0) of the
257257
original size and and a random aspect ratio of 3/4 to 4/3 of the
@@ -261,23 +261,23 @@ This is popularly used to train the Inception networks - size: size of
261261
the smaller edge - interpolation: Default: PIL.Image.BILINEAR
262262

263263
``Pad(padding, fill=0)``
264-
~~~~~~~~~~~~~~~~~~~~~~~~
264+
^^^^^^^^^^^^^^^^^^^^^^^^
265265

266266
Pads the given image on each side with ``padding`` number of pixels, and
267267
the padding pixels are filled with pixel value ``fill``. If a ``5x5``
268268
image is padded with ``padding=1`` then it becomes ``7x7``
269269

270270
Transforms on torch.\*Tensor
271-
----------------------------
271+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
272272

273273
``Normalize(mean, std)``
274-
~~~~~~~~~~~~~~~~~~~~~~~~
274+
^^^^^^^^^^^^^^^^^^^^^^^^
275275

276276
Given mean: (R, G, B) and std: (R, G, B), will normalize each channel of
277277
the torch.\*Tensor, i.e. channel = (channel - mean) / std
278278

279279
Conversion Transforms
280-
---------------------
280+
~~~~~~~~~~~~~~~~~~~~~
281281

282282
- ``ToTensor()`` - Converts a PIL.Image (RGB) or numpy.ndarray (H x W x
283283
C) in the range [0, 255] to a torch.FloatTensor of shape (C x H x W)
@@ -287,10 +287,10 @@ Conversion Transforms
287287
shape H x W x C to a PIL.Image of range [0, 255]
288288

289289
Generic Transofrms
290-
------------------
290+
~~~~~~~~~~~~~~~~~~
291291

292292
``Lambda(lambda)``
293-
~~~~~~~~~~~~~~~~~~
293+
^^^^^^^^^^^^^^^^^^
294294

295295
Given a Python lambda, applies it to the input ``img`` and returns it.
296296
For example:

0 commit comments

Comments
 (0)