ixxi-dante/nw2vec

View on GitHub
projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py

Summary

Maintainability
B
4 hrs
Test Coverage

File scenarios-exploration-asymmetric-n_nodes=1000.py has 253 lines of code (exceeds 250 allowed). Consider refactoring.
Open

# Explore the effect of overlap size in slicing embeddings for scenarios having different network-feature correlation

##
## Imports and setup
##
Severity: Minor
Found in projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py - About 2 hrs to fix

    Function make_train_vae has 6 arguments (exceeds 4 allowed). Consider refactoring.
    Open

    def make_train_vae(dims, q_overlap, p_ξ_slices, skey, with_progress=True):
    Severity: Minor
    Found in projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py - About 45 mins to fix

      Avoid deeply nested control flow statements.
      Open

                      for model_type in tqdm([MODEL_OVERLAP, MODEL_NOOVERLAP]):
                          if model_type == MODEL_OVERLAP:
                              dim_ξ_adj = dim_ξ_ov_adj
                              dim_ξ_v = dim_ξ_ov_v
                              q_overlap = ov
      Severity: Major
      Found in projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py - About 45 mins to fix

        Function make_vae has 5 arguments (exceeds 4 allowed). Consider refactoring.
        Open

        def make_vae(n_nodes, dims, q_overlap, p_ξ_slices):
        Severity: Minor
        Found in projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py - About 35 mins to fix

          Function train has 5 arguments (exceeds 4 allowed). Consider refactoring.
          Open

          def train(model, A, labels, features, with_progress=True):
          Severity: Minor
          Found in projects/behaviour/scenarios-exploration-asymmetric-n_nodes=1000.py - About 35 mins to fix

            Too many leading '#' for block comment
            Open

            ## Creating the scenarios

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (94 > 79 characters)
            Open

                     + (.13 - π_gap) * (np.ones((n_clusters, n_clusters)) - np.diag(np.ones(n_clusters))))

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (91 > 79 characters)
            Open

                    # used behind the scenes by Model.predict_minibatches() and Model.fit_minibatches()

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def train(model, A, labels, features, with_progress=True):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (99 > 79 characters)
            Open

                # which might use memory. I know, it's an open issue on GitHub, but it's not a problem for now.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines after class or function definition, found 1
            Open

            submitted = {}

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Expected 2 blank lines, found 1
            Open

            def scenario_from_aid_cid(aid, cid, n_nodes=N_NODES, n_clusters=N_CLUSTERS):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (110 > 79 characters)
            Open

                For non-binary features, we use a Gaussian distribution for feature prediction, so the output for features

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (106 > 79 characters)
            Open

                    # item defines the input to feature decoding. In this case they overlap with `overlap` dimensions.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (98 > 79 characters)
            Open

                    In the fullbatch setting all this is constant and equal to the values of the full dataset.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (90 > 79 characters)
            Open

                    # are picklable, so travel without problem across processes and across the network

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Too many leading '#' for block comment
            Open

            ## Build the VAEs

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (106 > 79 characters)
            Open

                from which you sample to create a prediction. For the adjacency, they would be numbers between 0 and 1

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Too many leading '#' for block comment
            Open

            ## Actual training

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (90 > 79 characters)
            Open

                            + '-n_alphas={n_alphas}-n_models={n_models}-n_clusterings={n_clusterings}'

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Too many leading '#' for block comment
            Open

            ## Imports and setup

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (108 > 79 characters)
            Open

                                               n_alphas=N_ALPHAS, n_models=N_MODEL_SAMPLES, n_clusterings=N_CLUSTERINGS,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines after class or function definition, found 1
            Open

            n_ξ_samples = 5  # Number of embeddings sampled at the embedding layer.

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (103 > 79 characters)
            Open

                    In the minibatch setting, `required_nodes` is usually the 2-hop neighbourhood of `final_nodes`.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def make_vae(n_nodes, dims, q_overlap, p_ξ_slices):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (108 > 79 characters)
            Open

                    # is used for feature prediction. After sampling of embedding values (using the parameters output by

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (86 > 79 characters)
            Open

                    # so we have one entry per output/loss in the model. Each entry must also have

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (199 > 79 characters)
            Open

            # * Decoding seems to be much better with an intermediate dense layer (i.e. `with_l1=True`) before the final dense layer for feature reconstruction and the bilinear layer for adjacency reconstruction

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (240 > 79 characters)
            Open

            # This section generates VAE models with different overlap values for each of the STBM scenarios, and trains them on the distributed Dask cluster. It recovers the history of the losses during training, and the weights of the trained models.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (98 > 79 characters)
            Open

                        batcher_kws={'adj': A, 'features': features, 'target_func': make_target_func(labels)},

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (104 > 79 characters)
            Open

            # `target_func` is given to the training function (in fact it's given as a parameter to the fullbatcher,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (82 > 79 characters)
            Open

                """Build a VAE, train it, and return the training history and trained weights.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (92 > 79 characters)
            Open

                    # the `utils.expand_dims_tile()` calls: the target value is the same for each of the

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            At least two spaces before inline comment
            Open

                        np.zeros(1), # ignored

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (90 > 79 characters)
            Open

                    # Note that keras models can't be sent easily across the network, as pickling them

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (81 > 79 characters)
            Open

                            + '/S2_S3-ov_noov_asym-n_nodes={n_nodes}-n_clusters={n_clusters}'

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (114 > 79 characters)
            Open

                is a cross-entropy loss, and the combination of these two is not numerically stable (it easily vanishes to 0).

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (101 > 79 characters)
            Open

                where sigmoid and cross-entropy are combined into a numerically stable operation), such that what

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (102 > 79 characters)
            Open

                the `vae` outputs for the adj and feature predictions is the values that should go into a sigmoid.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (108 > 79 characters)
            Open

                    """Create training targets given the batch's adjacency matrix, the subset of nodes it used as input,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (86 > 79 characters)
            Open

                Note that the fullbatcher takes care of normalising and centring the input labels,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (106 > 79 characters)
            Open

            # the targets are always the same, but the way it's coded is unchanged so we're left with a bit of useless

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def get_loss_weights(n_nodes, dims, q_overlap):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (100 > 79 characters)
            Open

                In the original model, the adj and feature outputs of `vae` would be parameters to distributions

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (82 > 79 characters)
            Open

                        # Keras feeds this to the embedding-gaussian divergence loss function,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (96 > 79 characters)
            Open

                        # kwargs sent to the fullbatch generator. See `nw2vec.batching.fullbatches()` to see

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (130 > 79 characters)
            Open

            # We're now in a position to generate a range of models (different overlaps for each scenario) and train them on the Dask cluster.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def make_target_func(labels):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (106 > 79 characters)
            Open

                # Ignore warnings here: TensorFlow always complains that we convert a sparse matrix to a dense matrix,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (90 > 79 characters)
            Open

                    Dict associating loss name to the history of that loss value during model training

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (105 > 79 characters)
            Open

                So instead, we push the sigmoid operation into the loss computation (implemented in the codec object,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (89 > 79 characters)
            Open

                    # used behind the scenes by Model.predict_fullbatch() and Model.fit_fullbatches()

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (91 > 79 characters)
            Open

            # The target values also depend on the STBM scenario used, so here we make a function which

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (93 > 79 characters)
            Open

                # there is a different session for each worker (which is where tensor values are stored),

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (98 > 79 characters)
            Open

                But! The last operation on these layers would be a sigmoid, and the loss we compute downstream

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (99 > 79 characters)
            Open

                # Build a function which, given an input (which would be the embeddings, i.e. the output of the

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (110 > 79 characters)
            Open

                    # The output of the model for the features is therefore passed to the nw2vec.codecs.SoftmaxMultinomial

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (80 > 79 characters)
            Open

                    # we want to inspect on the receiver end, i.e. in this notebook process.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Inline comment should start with '# '
            Open

                for (skey, mkey), history in submitted.items():#tqdm(submitted.items()):

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Inline comment should start with '# '
            Open

                for cid in [1]:#tqdm(range(N_CLUSTERINGS)):

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (80 > 79 characters)
            Open

                        # or Dask would just assume the different samples are the same task.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (100 > 79 characters)
            Open

                                                  slice(dim_ξ_adj - q_overlap, dim_ξ_adj - q_overlap + dim_ξ_v)]

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def submit_training(**kws):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Expected an indented block (comment)
            Open

                        #for dim_ξ in tqdm(range(max_dim_ξ, max_dim_ξ // 2 - 1, -2)):

            Use indent_size (PEP8 says 4) spaces per indentation level.

            For really old code that you don't want to mess up, you can continue
            to use 8-space tabs.
            
            Okay: a = 1
            Okay: if a == 0:\n    a = 1
            E111:   a = 1
            E114:   # a = 1
            
            Okay: for item in items:\n    pass
            E112: for item in items:\npass
            E115: for item in items:\n# Hi\n    pass
            
            Okay: a = 1\nb = 2
            E113: a = 1\n    b = 2
            E116: a = 1\n    # b = 2

            Line too long (83 > 79 characters)
            Open

                        # Don't show progress bars for these tasks, there are hundreds of them.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Too many leading '#' for block comment
            Open

            ## Gather successful tasks and save to disk

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (96 > 79 characters)
            Open

                    used to interpret the output of `q_model`. Currently this list has always a single item.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (113 > 79 characters)
            Open

                would be the μ values and values of the diagonal of log(Σ) (just like the parametrisation of the embeddings).

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (112 > 79 characters)
            Open

            # through an argument to the training function) and generates the values against which training loss is computed

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Block comment should start with '# '
            Open

                        #for dim_ξ in tqdm(range(max_dim_ξ, max_dim_ξ // 2 - 1, -2)):

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (94 > 79 characters)
            Open

                                    print("Skipped skey = {}, mkey = {}, already present in saved results"

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (101 > 79 characters)
            Open

                    The list of codec names used to interpret the output of `vae`. The output of `vae` is made of

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (109 > 79 characters)
            Open

                (parameters to a Bernoulli distribution for each value in the matrix). The same goes for binary features.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (92 > 79 characters)
            Open

            # We start by defining the training parameters, and some helpers for the loops further down.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def make_train_vae(dims, q_overlap, p_ξ_slices, skey, with_progress=True):

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (94 > 79 characters)
            Open

                    history = dict((title, np.array(values)) for title, values in history.history.items())

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (85 > 79 characters)
            Open

                                    'dim_l1': dim_l1, 'dim_ξ_adj': dim_ξ_adj, 'dim_ξ_v': dim_ξ_v,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (81 > 79 characters)
            Open

            π_gap_range = np.linspace(start=.075, stop=.12, num=N_CLUSTERINGS, endpoint=True)

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (109 > 79 characters)
            Open

                    # Slices used to separate what part of the embeddings is used for adjacency prediction from what part

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (107 > 79 characters)
            Open

                    # the encoder), the first item in this list defines the input to adjacency decoding, and the second

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (102 > 79 characters)
            Open

                # Build the actual VAE. This takes the encoder, adds a sampling layer, puts that into the decoder,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (102 > 79 characters)
            Open

                    # Weights used in computing the total final loss of the model. The three values are applied to

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines after class or function definition, found 1
            Open

            n_epochs = 1000

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (109 > 79 characters)
            Open

            # minibatch (which is why we need a function to create the targets for each minibatch). In the fullbatch case

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (106 > 79 characters)
            Open

                # This function runs in Dask workers, i.e. in another process on another machine. We need to make sure

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (92 > 79 characters)
            Open

                    # requires many hacks. Instead we just transport the weights, and recreate any model

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (88 > 79 characters)
            Open

            dim_l1 = max(max_dim_ξ, int(np.round(np.exp(np.mean(np.log([max_dim_ξ, N_CLUSTERS]))))))

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines, found 1
            Open

            def get_statuses():

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            At least two spaces before inline comment
            Open

                for (skey, mkey), history in submitted.items():#tqdm(submitted.items()):

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Statement ends with a semicolon
            Open

                gc.collect();

            Compound statements (on the same line) are generally discouraged.

            While sometimes it's okay to put an if/for/while with a small body
            on the same line, never do this for multi-clause statements.
            Also avoid folding such long lines!
            
            Always use a def statement instead of an assignment statement that
            binds a lambda expression directly to a name.
            
            Okay: if foo == 'blah':\n    do_blah_thing()
            Okay: do_one()
            Okay: do_two()
            Okay: do_three()
            
            E701: if foo == 'blah': do_blah_thing()
            E701: for x in lst: total += x
            E701: while t < 10: t = delay()
            E701: if foo == 'blah': do_blah_thing()
            E701: else: do_non_blah_thing()
            E701: try: something()
            E701: finally: cleanup()
            E701: if foo == 'blah': one(); two(); three()
            E702: do_one(); do_two(); do_three()
            E703: do_four();  # useless semicolon
            E704: def f(x): return 2*x
            E731: f = lambda x: 2*x

            Line too long (117 > 79 characters)
            Open

            # Explore the effect of overlap size in slicing embeddings for scenarios having different network-feature correlation

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (151 > 79 characters)
            Open

            # The rest of the notebook generates VAE models for the different scenarios and different overlaps. This section defines the model-generating function.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (112 > 79 characters)
            Open

                    # If `with_l1=True`, this defines whether the adjacency flow and the feature flow share the same weights

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (83 > 79 characters)
            Open

                    # embedding-gaussian divergence scales with number of embedding dimensions,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (109 > 79 characters)
            Open

            # for each batch. The complexity of this comes from the fact that for minibatches, the targets change at each

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (81 > 79 characters)
            Open

                    # but we also don't want it to overpower the other losses, hence the 1e-2

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (89 > 79 characters)
            Open

                    # a shape which is compatible with the corresponding output, which is why we have

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (84 > 79 characters)
            Open

                    The list of codec names (corresponding to subclasses of nw2vec.codecs.Codec)

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (108 > 79 characters)
            Open

                    the output of `q_model` (so that the first codec name her is always the single codec in `q_codecs`),

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (97 > 79 characters)
            Open

                        utils.expand_dims_tile(utils.expand_dims_tile(batch_adj + np.eye(batch_adj.shape[0]),

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (195 > 79 characters)
            Open

            # * The weights for this layer should NOT be shared between adj and feature tracks (i.e. `shared_l1=False`), since this would re-create a dependency between the separated parts of the embeddings.

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (86 > 79 characters)
            Open

                model_key = (kws['model_type'], kws['spill_v2adj'], kws['ov'], kws['sampling_id'])

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Too many leading '#' for block comment
            Open

            ## Train

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (109 > 79 characters)
            Open

                        # They key uniquely identifies a task in Dask, so it's important we include the sampling id here,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Missing whitespace around operator
            Open

                config.gpu_options.allow_growth=True

            Surround operators with a single space on either side.

            - Always surround these binary operators with a single space on
              either side: assignment (=), augmented assignment (+=, -= etc.),
              comparisons (==, <, >, !=, <=, >=, in, not in, is, is not),
              Booleans (and, or, not).
            
            - If operators with different priorities are used, consider adding
              whitespace around the operators with the lowest priorities.
            
            Okay: i = i + 1
            Okay: submitted += 1
            Okay: x = x * 2 - 1
            Okay: hypot2 = x * x + y * y
            Okay: c = (a + b) * (a - b)
            Okay: foo(bar, key='word', *args, **kwargs)
            Okay: alpha[:-i]
            
            E225: i=i+1
            E225: submitted +=1
            E225: x = x /2 - 1
            E225: z = x **y
            E225: z = 1and 1
            E226: c = (a+b) * (a-b)
            E226: hypot2 = x*x + y*y
            E227: c = a|b
            E228: msg = fmt%(errno, errmsg)

            Line too long (97 > 79 characters)
            Open

                    # Massage the output history and return both history and model weights. Both these values

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            At least two spaces before inline comment
            Open

                for cid in [1]:#tqdm(range(N_CLUSTERINGS)):

            Separate inline comments by at least two spaces.

            An inline comment is a comment on the same line as a statement.
            Inline comments should be separated by at least two spaces from the
            statement. They should start with a # and a single space.
            
            Each line of a block comment starts with a # and a single space
            (unless it is indented text inside the comment).
            
            Okay: x = x + 1  # Increment x
            Okay: x = x + 1    # Increment x
            Okay: # Block comment
            E261: x = x + 1 # Increment x
            E262: x = x + 1  #Increment x
            E262: x = x + 1  #  Increment x
            E265: #Block comment
            E266: ### Block comment

            Line too long (81 > 79 characters)
            Open

                        # Loop over all overlap values: 0 up to maximum overlap by steps of 2

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Expected 2 blank lines after class or function definition, found 1
            Open

            gathered = {}

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Expected 2 blank lines after class or function definition, found 1
            Open

            statuses = get_statuses()

            Separate top-level function and class definitions with two blank lines.

            Method definitions inside a class are separated by a single blank
            line.
            
            Extra blank lines may be used (sparingly) to separate groups of
            related functions.  Blank lines may be omitted between a bunch of
            related one-liners (e.g. a set of dummy implementations).
            
            Use blank lines in functions, sparingly, to indicate logical
            sections.
            
            Okay: def a():\n    pass\n\n\ndef b():\n    pass
            Okay: def a():\n    pass\n\n\nasync def b():\n    pass
            Okay: def a():\n    pass\n\n\n# Foo\n# Bar\n\ndef b():\n    pass
            Okay: default = 1\nfoo = 1
            Okay: classify = 1\nfoo = 1
            
            E301: class Foo:\n    b = 0\n    def bar():\n        pass
            E302: def a():\n    pass\n\ndef b(n):\n    pass
            E302: def a():\n    pass\n\nasync def b(n):\n    pass
            E303: def a():\n    pass\n\n\n\ndef b(n):\n    pass
            E303: def a():\n\n\n\n    pass
            E304: @decorator\n\ndef a():\n    pass
            E305: def a():\n    pass\na()
            E306: def a():\n    def b():\n        pass\n    def c():\n        pass

            Line too long (128 > 79 characters)
            Open

                print("{}: gathered newly finished tasks (+{}, total {})".format(datetime.datetime.utcnow(), newly_gathered, len(gathered)))

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            Line too long (84 > 79 characters)
            Open

                        make_train_vae, dims, kws['q_overlap'], kws['p_ξ_slices'], scenario_key,

            Limit all lines to a maximum of 79 characters.

            There are still many devices around that are limited to 80 character
            lines; plus, limiting windows to 80 characters makes it possible to
            have several windows side-by-side.  The default wrapping on such
            devices looks ugly.  Therefore, please limit all lines to a maximum
            of 79 characters. For flowing long blocks of text (docstrings or
            comments), limiting the length to 72 characters is recommended.
            
            Reports error E501.

            There are no issues that match your filters.

            Category
            Status