__init__.py 335 B

12345678910
  1. import glob
  2. import os.path as osp
  3. # Create a list consisting of all attack classes names in this package
  4. __all__ = []
  5. modules = glob.glob(osp.dirname(__file__) + "/*.py")
  6. for m in modules:
  7. c = str(osp.basename(m)[:-3])
  8. if not c.startswith('__') and not c.startswith('Base') and c.endswith('Attack'):
  9. __all__.append(c)