Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove 'dont import from this module' messages #539

Merged
merged 1 commit into from Jan 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 10 additions & 0 deletions changelogs/master/changed/20191230_dont_import_msgs.md
@@ -0,0 +1,10 @@
# Removed Outdated "Don't Import from this Module" Messages #539

The docstring of each module in ``imgaug.augmenters`` previously included a
suggestion to not directly import from that module, but instead use
``imgaug.augmenters.<AugmenterName>``. That was due to the categorization
still being unstable. As the categorization has now been fairly stable
for a long time, the suggestion was removed from all modules. Calling
``imgaug.augmenters.<AugmenterName>`` instead of
``imgaug.augmenters.<ModuleName>.<AugmenterName>`` is however still the
preferred way.
9 changes: 0 additions & 9 deletions imgaug/augmenters/arithmetic.py
@@ -1,15 +1,6 @@
"""
Augmenters that perform simple arithmetic changes.

Do not import directly from this file, as the categorization is not final.
Use instead::

from imgaug import augmenters as iaa

and then e.g.::

seq = iaa.Sequential([iaa.Add((-5, 5)), iaa.Multiply((0.9, 1.1))])

List of augmenters:

* Add
Expand Down
2 changes: 1 addition & 1 deletion imgaug/augmenters/artistic.py
@@ -1,5 +1,5 @@
"""
Augmenters that perform apply artistic image filters.
Augmenters that apply artistic image filters.

List of augmenters:

Expand Down
11 changes: 0 additions & 11 deletions imgaug/augmenters/blend.py
@@ -1,17 +1,6 @@
"""
Augmenters that blend two images with each other.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Alpha(0.5, iaa.Add((-5, 5)))
])

List of augmenters:

* Alpha
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/blur.py
@@ -1,18 +1,6 @@
"""
Augmenters that blur images.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.GaussianBlur((0.0, 3.0)),
iaa.AverageBlur((2, 5))
])

List of augmenters:

* GaussianBlur
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/color.py
@@ -1,18 +1,6 @@
"""
Augmenters that affect image colors or image colorspaces.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Grayscale((0.0, 1.0)),
iaa.AddToHueAndSaturation((-10, 10))
])

List of augmenters:

* InColorspace (deprecated)
Expand Down
9 changes: 0 additions & 9 deletions imgaug/augmenters/contrast.py
@@ -1,15 +1,6 @@
"""
Augmenters that perform contrast changes.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([iaa.GammaContrast((0.5, 1.5))])

List of augmenters:

* GammaContrast
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/convolutional.py
@@ -1,18 +1,6 @@
"""
Augmenters that are based on applying convolution kernels to images.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Sharpen((0.0, 1.0)),
iaa.Emboss((0.0, 1.0))
])

List of augmenters:

* Convolve
Expand Down
11 changes: 0 additions & 11 deletions imgaug/augmenters/debug.py
@@ -1,16 +1,5 @@
"""Augmenters that help with debugging.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.SaveDebugImageEveryNBatches(...)
])

List of augmenters:
* SaveDebugImageEveryNBatches

Expand Down
15 changes: 3 additions & 12 deletions imgaug/augmenters/edges.py
@@ -1,22 +1,13 @@
"""
Augmenters that deal with edge detection.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Canny()
])

List of augmenters:

* Canny

EdgeDetect and DirectedEdgeDetect are currently still in `convolutional.py`.
:class:`imgaug.augmenters.convolutional.EdgeDetect` and
:class:`imgaug.augmenters.convolutional.DirectedEdgeDetect` are currently
still in ``convolutional.py``.

"""
from __future__ import print_function, division, absolute_import
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/flip.py
@@ -1,18 +1,6 @@
"""
Augmenters that apply mirroring/flipping operations to images.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Fliplr((0.0, 1.0)),
iaa.Flipud((0.0, 1.0))
])

List of augmenters:

* Fliplr
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/geometric.py
@@ -1,17 +1,5 @@
"""Augmenters that apply affine or similar transformations.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Affine(...),
iaa.PerspectiveTransform(...)
])

List of augmenters:
* Affine
* ScaleX
Expand Down
9 changes: 0 additions & 9 deletions imgaug/augmenters/meta.py
Expand Up @@ -2,15 +2,6 @@
Augmenters that don't apply augmentations themselves, but are needed
for meta usage.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([...])

List of augmenters:

* Augmenter (base class for all augmenters)
Expand Down
11 changes: 0 additions & 11 deletions imgaug/augmenters/pooling.py
@@ -1,17 +1,6 @@
"""
Augmenters that apply pooling operations to images.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.AveragePooling((1, 3))
])

List of augmenters:

* AveragePooling
Expand Down
11 changes: 0 additions & 11 deletions imgaug/augmenters/segmentation.py
@@ -1,17 +1,6 @@
"""
Augmenters that apply changes to images based on segmentation methods.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Superpixels(...)
])

List of augmenters:

* Superpixels
Expand Down
12 changes: 0 additions & 12 deletions imgaug/augmenters/size.py
@@ -1,18 +1,6 @@
"""
Augmenters that somehow change the size of the images.

Do not import directly from this file, as the categorization is not final.
Use instead ::

from imgaug import augmenters as iaa

and then e.g. ::

seq = iaa.Sequential([
iaa.Resize({"height": 32, "width": 64})
iaa.Crop((0, 20))
])

List of augmenters:

* Resize
Expand Down
9 changes: 0 additions & 9 deletions imgaug/augmenters/weather.py
@@ -1,15 +1,6 @@
"""
Augmenters that create weather effects.

Do not import directly from this file, as the categorization is not final.
Use instead::

from imgaug import augmenters as iaa

and then e.g.::

seq = iaa.Sequential([iaa.Snowflakes()])

List of augmenters:

* FastSnowyLandscape
Expand Down