prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Fix imports in __init__ and add tests
  # Fix import errors
  
  Closes #213 
  
  I fixed the import errors, e.g. 
  ```
  import lightly
  lightly.data.LightlyDataset
  ```
  should work now. I also added tests for all import that I found important.
  
  Bumped the version number so we can quickly release this hotfix.
  
  Added SimSiam to the list of models in the description.
  
  </issue>
  <code>
  [start of lightly/__init__.py]
  1 """Lightly is a computer vision framework for self-supervised learning.
  2 
  3 With Lightly you can train deep learning models using
  4 self-supervision. This means, that you don't require
  5 any labels to train a model. Lightly has been built
  6 to help you understand and work with large unlabeled datasets.
  7 It is built on top of PyTorch and therefore fully compatible 
  8 with other frameworks such as Fast.ai.
  9 
  10 The framework is structured into the following modules:
  11 
  12 - **api**: 
  13 
  14   The lightly.api module handles communication with the Lightly web-app.
  15 
  16 - **cli**:
  17 
  18   The lightly.cli module provides a command-line interface for training 
  19   self-supervised models and embedding images. Furthermore, the command-line
  20   tool can be used to upload and download images from/to the Lightly web-app.
  21 
  22 - **core**:
  23 
  24   The lightly.core module offers one-liners for simple self-supervised learning.
  25 
  26 - **data**:
  27 
  28   The lightly.data module provides a dataset wrapper and collate functions. The
  29   collate functions are in charge of the data augmentations which are crucial for
  30   self-supervised learning.
  31 
  32 - **embedding**:
  33 
  34   The lightly.embedding module combines the self-supervised models with a dataloader,
  35   optimizer, and loss function to provide a simple pytorch-lightning trainable.
  36 
  37 - **loss**:
  38 
  39   The lightly.loss module contains implementations of popular self-supervised training
  40   loss functions.
  41 
  42 - **models**:
  43 
  44   The lightly.models module holds the implementation of the ResNet as well as self-
  45   supervised methods. Currently implements:
  46 
  47   - SimCLR
  48 
  49   - MoCo
  50 
  51 - **transforms**:
  52 
  53   The lightly.transforms module implements custom data transforms. Currently implements:
  54 
  55   - Gaussian Blur
  56 
  57   - Random Rotation
  58 
  59 - **utils**:
  60 
  61   The lightly.utils package provides global utility methods.
  62   The io module contains utility to save and load embeddings in a format which is
  63   understood by the Lightly library.
  64 
  65 """
  66 
  67 # Copyright (c) 2020. Lightly AG and its affiliates.
  68 # All Rights Reserved
  69 
  70 __name__ = 'lightly'
  71 __version__ = '1.1.0'
  72 
  73 
  74 try:
  75     # See (https://github.com/PyTorchLightning/pytorch-lightning)
  76     # This variable is injected in the __builtins__ by the build
  77     # process. It used to enable importing subpackages of skimage when
  78     # the binaries are not built
  79     __LIGHTLY_SETUP__
  80 except NameError:
  81     __LIGHTLY_SETUP__ = False
  82 
  83 
  84 if __LIGHTLY_SETUP__:
  85     # setting up lightly
  86     msg = f'Partial import of {__name__}=={__version__} during build process.' 
  87     print(msg)
  88 else:
  89     # see if prefetch_generator is available
  90     try:
  91         import prefetch_generator
  92     except ImportError:
  93         _prefetch_generator_available = False
  94     else:
  95         _prefetch_generator_available = True
  96 
  97     def _is_prefetch_generator_available():
  98         return _prefetch_generator_available
  99 
  100     # check for latest version
  101     from lightly.api.version_checking import get_latest_version, version_compare, pretty_print_latest_version
  102 
  103     latest_version = get_latest_version(__version__)
  104     if latest_version is not None:
  105         if version_compare(__version__, latest_version) < 0:
  106             # local version is behind latest version
  107             pretty_print_latest_version(latest_version)
  108
  [end of lightly/__init__.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/lightly/__init__.py b/lightly/__init__.py
  --- a/lightly/__init__.py
  +++ b/lightly/__init__.py
  @@ -48,6 +48,8 @@
   
     - MoCo
   
  +  - SimSiam
  +
   - **transforms**:
   
     The lightly.transforms module implements custom data transforms. Currently implements:
  @@ -68,7 +70,7 @@
   # All Rights Reserved
   
   __name__ = 'lightly'
  -__version__ = '1.1.0'
  +__version__ = '1.1.1'
   
   
   try:
  @@ -97,8 +99,22 @@
       def _is_prefetch_generator_available():
           return _prefetch_generator_available
   
  +    from lightly.core import *
  +    from lightly import active_learning
  +    from lightly import api
  +    from lightly import data
  +    from lightly import embedding
  +    from lightly import loss
  +    from lightly import models
  +    from lightly import openapi_generated
  +    from lightly import transforms
  +    from lightly import utils
  +
  +
       # check for latest version
  -    from lightly.api.version_checking import get_latest_version, version_compare, pretty_print_latest_version
  +    from lightly.api.version_checking import get_latest_version
  +    from lightly.api.version_checking import version_compare
  +    from lightly.api.version_checking import pretty_print_latest_version
   
       latest_version = get_latest_version(__version__)
       if latest_version is not None:
  
verification_info: {"golden_diff": "diff --git a/lightly/__init__.py b/lightly/__init__.py\n--- a/lightly/__init__.py\n+++ b/lightly/__init__.py\n@@ -48,6 +48,8 @@\n \n   - MoCo\n \n+  - SimSiam\n+\n - **transforms**:\n \n   The lightly.transforms module implements custom data transforms. Currently implements:\n@@ -68,7 +70,7 @@\n # All Rights Reserved\n \n __name__ = 'lightly'\n-__version__ = '1.1.0'\n+__version__ = '1.1.1'\n \n \n try:\n@@ -97,8 +99,22 @@\n     def _is_prefetch_generator_available():\n         return _prefetch_generator_available\n \n+    from lightly.core import *\n+    from lightly import active_learning\n+    from lightly import api\n+    from lightly import data\n+    from lightly import embedding\n+    from lightly import loss\n+    from lightly import models\n+    from lightly import openapi_generated\n+    from lightly import transforms\n+    from lightly import utils\n+\n+\n     # check for latest version\n-    from lightly.api.version_checking import get_latest_version, version_compare, pretty_print_latest_version\n+    from lightly.api.version_checking import get_latest_version\n+    from lightly.api.version_checking import version_compare\n+    from lightly.api.version_checking import pretty_print_latest_version\n \n     latest_version = get_latest_version(__version__)\n     if latest_version is not None:\n", "issue": "Fix imports in __init__ and add tests\n# Fix import errors\r\n\r\nCloses #213 \r\n\r\nI fixed the import errors, e.g. \r\n```\r\nimport lightly\r\nlightly.data.LightlyDataset\r\n```\r\nshould work now. I also added tests for all import that I found important.\r\n\r\nBumped the version number so we can quickly release this hotfix.\r\n\r\nAdded SimSiam to the list of models in the description.\n", "before_files": [{"content": "\"\"\"Lightly is a computer vision framework for self-supervised learning.\n\nWith Lightly you can train deep learning models using\nself-supervision. This means, that you don't require\nany labels to train a model. Lightly has been built\nto help you understand and work with large unlabeled datasets.\nIt is built on top of PyTorch and therefore fully compatible \nwith other frameworks such as Fast.ai.\n\nThe framework is structured into the following modules:\n\n- **api**: \n\n  The lightly.api module handles communication with the Lightly web-app.\n\n- **cli**:\n\n  The lightly.cli module provides a command-line interface for training \n  self-supervised models and embedding images. Furthermore, the command-line\n  tool can be used to upload and download images from/to the Lightly web-app.\n\n- **core**:\n\n  The lightly.core module offers one-liners for simple self-supervised learning.\n\n- **data**:\n\n  The lightly.data module provides a dataset wrapper and collate functions. The\n  collate functions are in charge of the data augmentations which are crucial for\n  self-supervised learning.\n\n- **embedding**:\n\n  The lightly.embedding module combines the self-supervised models with a dataloader,\n  optimizer, and loss function to provide a simple pytorch-lightning trainable.\n\n- **loss**:\n\n  The lightly.loss module contains implementations of popular self-supervised training\n  loss functions.\n\n- **models**:\n\n  The lightly.models module holds the implementation of the ResNet as well as self-\n  supervised methods. Currently implements:\n\n  - SimCLR\n\n  - MoCo\n\n- **transforms**:\n\n  The lightly.transforms module implements custom data transforms. Currently implements:\n\n  - Gaussian Blur\n\n  - Random Rotation\n\n- **utils**:\n\n  The lightly.utils package provides global utility methods.\n  The io module contains utility to save and load embeddings in a format which is\n  understood by the Lightly library.\n\n\"\"\"\n\n# Copyright (c) 2020. Lightly AG and its affiliates.\n# All Rights Reserved\n\n__name__ = 'lightly'\n__version__ = '1.1.0'\n\n\ntry:\n    # See (https://github.com/PyTorchLightning/pytorch-lightning)\n    # This variable is injected in the __builtins__ by the build\n    # process. It used to enable importing subpackages of skimage when\n    # the binaries are not built\n    __LIGHTLY_SETUP__\nexcept NameError:\n    __LIGHTLY_SETUP__ = False\n\n\nif __LIGHTLY_SETUP__:\n    #\u00a0setting up lightly\n    msg = f'Partial import of {__name__}=={__version__} during build process.' \n    print(msg)\nelse:\n    #\u00a0see if prefetch_generator is available\n    try:\n        import prefetch_generator\n    except ImportError:\n        _prefetch_generator_available = False\n    else:\n        _prefetch_generator_available = True\n\n    def _is_prefetch_generator_available():\n        return _prefetch_generator_available\n\n    # check for latest version\n    from lightly.api.version_checking import get_latest_version, version_compare, pretty_print_latest_version\n\n    latest_version = get_latest_version(__version__)\n    if latest_version is not None:\n        if version_compare(__version__, latest_version) < 0:\n            # local version is behind latest version\n            pretty_print_latest_version(latest_version)\n", "path": "lightly/__init__.py"}]}