6a289fefd72f038c8cc14826f63624950f5de1f8,gensim/models/lda_worker.py,,main,#,117

Before Change



    program = os.path.basename(sys.argv[0])
    // make sure we have enough cmd line parameters
    if len(sys.argv) < 1:
        print(globals()["__doc__"] % locals())
        sys.exit(1)

    utils.pyro_daemon("gensim.lda_worker", Worker(), random_suffix=True)

    logger.info("finished running %s" % program)

After Change




def main():
    parser = argparse.ArgumentParser(description=__doc__)
    parser.add_argument("--host", help="Nameserver hostname (default: %(default)s)", default=None)
    parser.add_argument("--port", help="Nameserver port (default: %(default)s)", default=None, type=int)
    parser.add_argument("--no-broadcast", help="Disable broadcast (default: %(default)s)",
                        action="store_const", default=True, const=False)
    parser.add_argument("--hmac", help="Nameserver hmac key (default: %(default)s)", default=None)
    parser.add_argument("-v", "--verbose", help="Verbose flag", action="store_const", dest="loglevel",
                        const=logging.INFO, default=logging.WARNING)
    args = parser.parse_args()

    logging.basicConfig(format="%(asctime)s : %(levelname)s : %(message)s", level=args.loglevel)
    logger.info("running %s", " ".join(sys.argv))

    ns_conf = {"broadcast": args.no_broadcast,
               "host": args.host,
               "port": args.port,
               "hmac_key": args.hmac}

    utils.pyro_daemon(LDA_WORKER_PREFIX, Worker(), random_suffix=True, ns_conf=ns_conf)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 12

Instances


Project Name: RaRe-Technologies/gensim
Commit Name: 6a289fefd72f038c8cc14826f63624950f5de1f8
Time: 2016-07-13
Author: menshikh.iv@gmail.com
File Name: gensim/models/lda_worker.py
Class Name:
Method Name: main


Project Name: pyinstaller/pyinstaller
Commit Name: c2b11cd70fc5a9f64750e80845990cc715cb3d12
Time: 2015-10-20
Author: h.goebel@crazy-compilers.com
File Name: PyInstaller/utils/cliutils/set_version.py
Class Name:
Method Name: run


Project Name: RaRe-Technologies/gensim
Commit Name: 6a289fefd72f038c8cc14826f63624950f5de1f8
Time: 2016-07-13
Author: menshikh.iv@gmail.com
File Name: gensim/models/lda_worker.py
Class Name:
Method Name: main


Project Name: pyinstaller/pyinstaller
Commit Name: 2bb844445fc39ea4062164df027280516cd281a2
Time: 2015-10-20
Author: h.goebel@crazy-compilers.com
File Name: PyInstaller/utils/cliutils/grab_version.py
Class Name:
Method Name: run