diff --git a/examples/square.py b/examples/square.py index c61089cdb56c0f1f7472e4a22896befc2b37bf4b..580df113f33af5743bc32140a460aba003aa6ca8 100644 --- a/examples/square.py +++ b/examples/square.py @@ -9,6 +9,7 @@ from kwant.physics.leads import square_selfenergy __all__ = ['System'] + class Lead(object): def __init__(self, width, t, potential): self.width = width diff --git a/kwant/builder.py b/kwant/builder.py index b8a37d175cd53eb53ddc2d85b8d2d1df1e0c2c5d..cd83747df7112a8fb35169dd644db138050f5d89 100644 --- a/kwant/builder.py +++ b/kwant/builder.py @@ -6,8 +6,6 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - - __all__ = ['Builder', 'Site', 'SiteFamily', 'SimpleSiteFamily', 'Symmetry', 'HoppingKind', 'Lead', 'BuilderLead', 'SelfEnergyLead', 'ModesLead'] diff --git a/kwant/digest.py b/kwant/digest.py index 7d2d16d957acd9edb57281a9db511c583fcbc494..0b502d5f2992477ee12d721111a104b0fa481536 100644 --- a/kwant/digest.py +++ b/kwant/digest.py @@ -19,8 +19,6 @@ good enough to pass the "dieharder" battery of tests: see the function `test` of this module. """ - - from math import pi, log, sqrt, cos from hashlib import md5 from struct import unpack diff --git a/kwant/graph/tests/test_scotch.py b/kwant/graph/tests/test_scotch.py index ca7e25af34064e3bbb8ba0d7e891af82e1179611..2ded31ae2f863eceee4a371b0e2db6a35eb70788 100644 --- a/kwant/graph/tests/test_scotch.py +++ b/kwant/graph/tests/test_scotch.py @@ -17,9 +17,9 @@ def _DISABLED_test_bisect(): size = 5 graph = Graph() - for i in range(size-1): + for i in range(size - 1): offset = i * size - for j in range(size-1): + for j in range(size - 1): graph.add_edge(offset + j, offset + j + 1) graph.add_edge(offset + j + 1, offset + j) if i > 0: @@ -36,9 +36,9 @@ def _DISABLED_test_reset(): size = 5 graph = Graph() - for i in range(size-1): + for i in range(size - 1): offset = i * size - for j in range(size-1): + for j in range(size - 1): graph.add_edge(offset + j, offset + j + 1) graph.add_edge(offset + j + 1, offset + j) if i > 0: diff --git a/kwant/graph/tests/test_utils.py b/kwant/graph/tests/test_utils.py index ae7f3d2277505e016f62d777c7d9c8ad4b1f8343..0906765e5fd587dfe7fa2345bf06cb44c6dc8748 100644 --- a/kwant/graph/tests/test_utils.py +++ b/kwant/graph/tests/test_utils.py @@ -83,7 +83,7 @@ def test_induced_subgraph(): num_nodes = 6 graph = Graph() - for i in range(num_nodes-1): + for i in range(num_nodes - 1): graph.add_edge(i, i + 1) graph.add_edge(1, 0) g = graph.compressed() diff --git a/kwant/lattice.py b/kwant/lattice.py index ff74ecd28cbdf4440e424e97bb38645be89d3fd8..e93228980cc7392bcd5f9842f15bae745eb584eb 100644 --- a/kwant/lattice.py +++ b/kwant/lattice.py @@ -6,8 +6,6 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - - __all__ = ['TranslationalSymmetry', 'general', 'Polyatomic', 'Monatomic', 'chain', 'square', 'triangular', 'honeycomb', 'kagome'] diff --git a/kwant/linalg/lll.py b/kwant/linalg/lll.py index 9a29b473db3ca7ab36ffdd48f8a5fe37d4ff9943..c9f2540fc68056234bc03056ae3f89d862483590 100644 --- a/kwant/linalg/lll.py +++ b/kwant/linalg/lll.py @@ -6,13 +6,12 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - - __all__ = ['lll', 'cvp', 'voronoi'] import numpy as np from itertools import product + def gs_coefficient(a, b): """Gram-Schmidt coefficient.""" return np.dot(a, b) / np.linalg.norm(b)**2 diff --git a/kwant/rmt.py b/kwant/rmt.py index 1d307f66a54b7a518682d1da8664191747a16fff..6442fc0a90e220277086f35a9a07576f327e4299 100644 --- a/kwant/rmt.py +++ b/kwant/rmt.py @@ -6,8 +6,6 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - - __all__ = ['gaussian', 'circular'] import numpy as np diff --git a/kwant/system.py b/kwant/system.py index 45d0b473395b2a189ecf60de62078e815ebca4e8..ca541b4ad9c832d3971b75fe61afe707b7e27230 100644 --- a/kwant/system.py +++ b/kwant/system.py @@ -8,7 +8,6 @@ """Low-level interface of systems""" - __all__ = ['System', 'FiniteSystem', 'InfiniteSystem'] import abc diff --git a/kwant/tests/test_builder.py b/kwant/tests/test_builder.py index 920bc2ffa803b8a05b273484de461ae7e8b2a52b..11b95c4b3be0d1e0572ffee7f65d5eb8892a60f2 100644 --- a/kwant/tests/test_builder.py +++ b/kwant/tests/test_builder.py @@ -6,7 +6,6 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - import warnings from random import Random from nose.tools import assert_raises diff --git a/kwant/tests/test_lattice.py b/kwant/tests/test_lattice.py index a9f8a94ae489253789d89ec96d27faf270f35176..f2169863a75a48aa91fc6c7c2d3229433fec08ba 100644 --- a/kwant/tests/test_lattice.py +++ b/kwant/tests/test_lattice.py @@ -6,7 +6,6 @@ # the file AUTHORS.rst at the top-level directory of this distribution and at # http://kwant-project.org/authors. - from math import sqrt import numpy as np import tinyarray as ta