commit
stringlengths
40
40
subject
stringlengths
4
1.73k
repos
stringlengths
5
127k
old_file
stringlengths
2
751
new_file
stringlengths
2
751
new_contents
stringlengths
1
8.98k
old_contents
stringlengths
0
6.59k
license
stringclasses
13 values
lang
stringclasses
23 values
027632cbac1cfa42e2f66b53ae6c3f22bcce630e
Fix cdd package definition, dotted is a property (#2054)
tmerrick1/spack,iulian787/spack,EmreAtes/spack,matthiasdiener/spack,LLNL/spack,lgarren/spack,krafczyk/spack,EmreAtes/spack,skosukhin/spack,mfherbst/spack,mfherbst/spack,lgarren/spack,lgarren/spack,tmerrick1/spack,TheTimmy/spack,EmreAtes/spack,krafczyk/spack,krafczyk/spack,TheTimmy/spack,mfherbst/spack,TheTimmy/spack,mf...
var/spack/repos/builtin/packages/cdd/package.py
var/spack/repos/builtin/packages/cdd/package.py
############################################################################## # Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory. # # This file is part of Spack. # Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. # LLNL-CODE-64...
############################################################################## # Copyright (c) 2013-2016, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory. # # This file is part of Spack. # Created by Todd Gamblin, tgamblin@llnl.gov, All rights reserved. # LLNL-CODE-64...
lgpl-2.1
Python
59d7854b8988c6525df8eb1ef7f2cde58c63eb0a
add build_directory, remove old hack (#10112)
LLNL/spack,iulian787/spack,iulian787/spack,LLNL/spack,iulian787/spack,LLNL/spack,iulian787/spack,LLNL/spack,LLNL/spack,iulian787/spack
var/spack/repos/builtin/packages/clp/package.py
var/spack/repos/builtin/packages/clp/package.py
# Copyright 2013-2018 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * class Clp(AutotoolsPackage): """Clp (Coin-or linear programming) is an open-source linear ...
# Copyright 2013-2018 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * class Clp(AutotoolsPackage): """Clp (Coin-or linear programming) is an open-source linear ...
lgpl-2.1
Python
090ca0e14621d287e9f5d1d301589d99d95cd224
Remove unused function
frostidaho/dynmen
src/dynmen/cmd/__init__.py
src/dynmen/cmd/__init__.py
# -*- coding: utf-8 -*- from collections import namedtuple as _namedtuple ProcStatus = _namedtuple('ProcStatus', 'stdout stderr returncode')
# -*- coding: utf-8 -*- from collections import namedtuple as _namedtuple ProcStatus = _namedtuple('ProcStatus', 'stdout stderr returncode') def _to_bytes(obj, entry_sep=b''): if isinstance(obj, bytes): return obj return entry_sep.join(obj)
mit
Python
5fbb4ff5d3427c8f4050fc5b75d4a6a2c15351c6
Set pygments style to monokai.
donnemartin/outdated-donnemartin.github.io,donnemartin/outdated-donnemartin.github.io,donnemartin/outdated-donnemartin.github.io,donnemartin/outdated-donnemartin.github.io,donnemartin/outdated-donnemartin.github.io
pelicanconf.py
pelicanconf.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = 'Donne Martin' SITENAME = 'Donne Martin' SITEURL = '' PATH = 'content' TIMEZONE = 'America/New_York' DEFAULT_LANG = 'en' # Feed generation is usually not desired when developing FEED_ALL_ATOM = None CATEGORY_FEED_ATOM ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = 'Donne Martin' SITENAME = 'Donne Martin' SITEURL = '' PATH = 'content' TIMEZONE = 'America/New_York' DEFAULT_LANG = 'en' # Feed generation is usually not desired when developing FEED_ALL_ATOM = None CATEGORY_FEED_ATOM ...
mit
Python
cde48aff408c0d2c413e4316a1ef5c808d2f444c
add DISPLAY_NAVBAR to configuration
fly/burrito.sh,fly/burrito.sh,bsdlp/burrito.sh,bsdlp/burrito.sh
pelicanconf.py
pelicanconf.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = u'jchen' SITENAME = u'BURRITO 4 LYFE' SITEURL = '' TIMEZONE = 'ETC/UTC' DEFAULT_LANG = u'en' CSS_FILE = 'style.css' # theme stuff THEME = '/Users/jchen/git/pelican/burrito' # plugins PLUGIN_PATH = '/Users/jchen/git/pe...
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = u'jchen' SITENAME = u'BURRITO 4 LYFE' SITEURL = '' TIMEZONE = 'ETC/UTC' DEFAULT_LANG = u'en' CSS_FILE = 'style.css' # theme stuff THEME = '/Users/jchen/git/pelican/burrito' # plugins PLUGIN_PATH = '/Users/jchen/git/pe...
bsd-3-clause
Python
a6ea16ded53bb688113012114a25b7d75e6460c0
Fix PVM dependencies (#20951)
LLNL/spack,LLNL/spack,LLNL/spack,LLNL/spack,LLNL/spack
var/spack/repos/builtin/packages/pvm/package.py
var/spack/repos/builtin/packages/pvm/package.py
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * import subprocess class Pvm(MakefilePackage): """PVM (Parallel Virtual Machine) is a software pa...
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack import * import subprocess class Pvm(MakefilePackage): """PVM (Parallel Virtual Machine) is a software pa...
lgpl-2.1
Python
0ee55bd73369c69638a401f4beef551a79bc820c
remove unneeded conf options
fly/burrito.sh,bsdlp/burrito.sh,bsdlp/burrito.sh,fly/burrito.sh
pelicanconf.py
pelicanconf.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = u'jchen' SITENAME = u'BURRITO 4 LYFE' SITEURL = '' TIMEZONE = 'ETC/UTC' DEFAULT_LANG = u'en' CSS_FILE = 'style.css' # theme stuff THEME = '/Users/jchen/git/pelican/burrito' # plugins PLUGIN_PATH = '/Users/jchen/git/pe...
#!/usr/bin/env python # -*- coding: utf-8 -*- # from __future__ import unicode_literals AUTHOR = u'jchen' SITENAME = u'BURRITO 4 LYFE' SITEURL = '' TIMEZONE = 'ETC/UTC' DEFAULT_LANG = u'en' CSS_FILE = 'style.css' # theme stuff THEME = '/Users/jchen/git/pelican/burrito' # plugins PLUGIN_PATH = '/Users/jchen/git/pe...
bsd-3-clause
Python
41dea616b22379fa2b7c1d00e21fe0288dc61622
Fix whitespace incoherence, causing pylint errors.
riannucci/rietveldv2,riannucci/rietveldv2
codereview/middleware.py
codereview/middleware.py
# Copyright 2008 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
# Copyright 2008 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
apache-2.0
Python
5dc4641a40ff25b439541f6c3c02639a53346985
Fix name of 'Betty' comic
klette/comics,jodal/comics,jodal/comics,datagutten/comics,datagutten/comics,klette/comics,datagutten/comics,datagutten/comics,klette/comics,jodal/comics,jodal/comics
comics/crawlers/betty.py
comics/crawlers/betty.py
from comics.crawler.base import BaseComicsComComicCrawler from comics.crawler.meta import BaseComicMeta class ComicMeta(BaseComicMeta): name = 'Betty' language = 'en' url = 'http://comics.com/betty/' start_date = '1991-01-01' history_capable_date = '2008-10-13' schedule = 'Mo,Tu,We,Th,Fr,Sa,Su'...
from comics.crawler.base import BaseComicsComComicCrawler from comics.crawler.meta import BaseComicMeta class ComicMeta(BaseComicMeta): name = 'Get Fuzzy' language = 'en' url = 'http://comics.com/betty/' start_date = '1991-01-01' history_capable_date = '2008-10-13' schedule = 'Mo,Tu,We,Th,Fr,Sa...
agpl-3.0
Python
4180c1aa0314ee86356f99a7f209459189fb4a5d
Correct dicts comparison
pombredanne/django-jet,geex-arts/django-jet,geex-arts/django-jet,geex-arts/django-jet,pombredanne/django-jet,rcotrina94/django-jet,rcotrina94/django-jet,SalahAdDin/django-jet,rcotrina94/django-jet,pombredanne/django-jet,SalahAdDin/django-jet,SalahAdDin/django-jet
jet/tests/test_utils.py
jet/tests/test_utils.py
import json from django.test import TestCase from jet.tests.models import TestModel from jet.utils import JsonResponse, get_model_instance_label class UtilsTestCase(TestCase): def test_json_response(self): response = JsonResponse({'str': 'string', 'int': 1}) response_dict = json.loads(response.con...
from django.test import TestCase from jet.tests.models import TestModel from jet.utils import JsonResponse, get_model_instance_label class UtilsTestCase(TestCase): def test_json_response(self): response = JsonResponse({'str': 'string', 'int': 1}) self.assertEqual(response.content, '{"int": 1, "str...
agpl-3.0
Python
73866e1ea0066fe45fbbf8a654b438b554d18a26
update hedwig version
ofpiyush/hedwig-py
hedwig/__init__.py
hedwig/__init__.py
""" (@,@) _ _ /\ /\___ __| |_ _(_) __ _ / /_/ / _ \/ _` \ \ /\ / / |/ _` | / __ / __/ (_| |\ V V /| | (_| | \/ /_/ \___|\__,_| \_/\_/ |_|\__, | |___/ """ __title__ = 'Hedwig Python' __version__ = '0.1.6' __author__ = 'Piyush' # Version synonym VERSIO...
""" (@,@) _ _ /\ /\___ __| |_ _(_) __ _ / /_/ / _ \/ _` \ \ /\ / / |/ _` | / __ / __/ (_| |\ V V /| | (_| | \/ /_/ \___|\__,_| \_/\_/ |_|\__, | |___/ """ __title__ = 'Hedwig Python' __version__ = '0.1.5' __author__ = 'Piyush' # Version synonym VERSIO...
mit
Python
d8dda85c786c38ad2fbb2e40d44567b917431cb8
Update zero_one_normalization.py
greenelab/adage,greenelab/adage,greenelab/adage
Data_collection_processing/zero_one_normalization.py
Data_collection_processing/zero_one_normalization.py
''' Linearly scale the expression range of one gene to be between 0 and 1. If a reference dataset is provided, then the scaling of one gene in the target dataset in done using the minimun and range of that gene in the reference dataset. ''' import sys import argparse sys.path.insert(0, 'Data_collection_processing/') f...
''' Linearly scale the expression range of one gene to be between 0 and 1. If a reference dataset is provided, then the scaling of one gene in the target dataset in done using the minimun and range of that gene in the reference dataset. ''' import sys import argparse sys.path.insert(0, 'Data_collection_processing/') f...
bsd-3-clause
Python
3b212f6ea6ba1ed355250b587f3d1c1cc462c7ed
send ctrl+c signal
wufeifei/cobra,wufeifei/cobra,braveghz/cobra,LiGhT1EsS/cobra,LiGhT1EsS/cobra,wufeifei/cobra,wufeifei/cobra,40huo/cobra,40huo/cobra,40huo/cobra,wufeifei/cobra,40huo/cobra,wufeifei/cobra,LiGhT1EsS/cobra,LiGhT1EsS/cobra,LiGhT1EsS/cobra,braveghz/cobra,40huo/cobra,40huo/cobra,braveghz/cobra,LiGhT1EsS/cobra,braveghz/cobra,br...
tests/test_apiserver.py
tests/test_apiserver.py
# -*- coding: utf-8 -*- """ tests.apiserver ~~~~~~~~~~~~ Tests cobra.api :author: 40huo <git@40huo.cn> :homepage: https://github.com/wufeifei/cobra :license: MIT, see LICENSE for more details. :copyright: Copyright (c) 2017 Feei. All rights reserved """ import requests import json ...
# -*- coding: utf-8 -*- """ tests.apiserver ~~~~~~~~~~~~ Tests cobra.api :author: 40huo <git@40huo.cn> :homepage: https://github.com/wufeifei/cobra :license: MIT, see LICENSE for more details. :copyright: Copyright (c) 2017 Feei. All rights reserved """ import requests import json ...
mit
Python
759e50abb963fd854989cb79592f7cf6f9d0bc13
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/41b9d692dc31b2b95c47e8c56cb9cd4872adc511.
paolodedios/tensorflow,frreiss/tensorflow-fred,paolodedios/tensorflow,gautam1858/tensorflow,karllessard/tensorflow,gautam1858/tensorflow,frreiss/tensorflow-fred,yongtang/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_opt...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "41b9d692dc31b2b95c47e8c56cb9cd4872adc511" TFRT_SHA256 = "b7ba9c34b81e53428a745453dc0ae0108a9510c6a7bd25...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "cbc81d9ef4bcea56e841c1b8a84d07db04a926bf" TFRT_SHA256 = "804f98fab72aa814701e9bc2b56435fce5b0f64af01ccf...
apache-2.0
Python
b17700b9878a3999c2ad64f622d2ca8566043b2e
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/fb895960cc796437c6d516cc19027c94f2319b4d.
gautam1858/tensorflow,Intel-tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,karllessard/tensorflow,paolodedios/tensorflow,yongtang/tensorflow,tensorflow/tensorflow,frreiss/tensorflow-fred,Intel-tensorflow/tensorflow,frreiss/tensorflow-fred,gautam1858/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,t...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "fb895960cc796437c6d516cc19027c94f2319b4d" TFRT_SHA256 = "9c5c10fa7b516554c8a6725e13c3d959609ad5d8fab2c6...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "1b5317be3621f2f9b6415696edb912ef75f54187" TFRT_SHA256 = "7f430ad049f7270b7dad98787f04d1259b8b2cd1a068c5...
apache-2.0
Python
a3afc651ba0efeef17293fa1e688a901453e1f05
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/379d33d44c64d5bd83eb4ca4d7a0928eb79b5f54.
tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,karllessard/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,Intel-tensorflow/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_tf_optimizer,paolodedios/t...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "379d33d44c64d5bd83eb4ca4d7a0928eb79b5f54" TFRT_SHA256 = "7be6d4bc2d8ac5f2420249f2c2df645ad945ba5f51d2ef...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "ae8fb48248557568109089e96d1aaab760dada21" TFRT_SHA256 = "fd64d9151ce25cda33a12ad1addbf52e853d2d13a74058...
apache-2.0
Python
e6d4c2bb4ac83a5f573a2a6fc5ef77356cd70ef3
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/78c6401faaebc33df9cc2c78f21e5c235d1670f4.
tensorflow/tensorflow-pywrap_tf_optimizer,yongtang/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-pywrap_tf_optimizer,karllessard/tensorflow,tensorflow/tensorflow-pywrap_saved_model,paolodedios/tensorflow,tensorflow/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "78c6401faaebc33df9cc2c78f21e5c235d1670f4" TFRT_SHA256 = "6a17b2490d44b392ece0015bbc4d...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "6e9c9d0a5c1bea5568c7fd837da88da67e71e3c3" TFRT_SHA256 = "ec37cf4d732794f4a4032e5f25e9...
apache-2.0
Python
5c823e1197f73701811cf449337c0c8bb970bc5c
Improve readability of tests
timtroendle/pytus2000
tests/test_datadicts.py
tests/test_datadicts.py
"""Tests for autogenerated data dictionaries. A data dictionary contains the following: * Variable Enum: An enum that contains all variables of the data dict as its members. * Variable Value Enum: An enum containing all values of one variable. Only exists for variables with a closed set of valu...
import pytest from pytus2000 import diary, diaryepisode, individual, household, weightdiary, worksheet @pytest.fixture(params=[ diary, diaryepisode, individual, household, weightdiary, worksheet ]) def datadict_module(request): return request.param @pytest.fixture(params=[ diary, ...
mit
Python
89844b7615e704410a9fa0dc6ae4cfe61ab8fefe
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/24d3f64ad78415f008af4bdde57079e331545dbf.
tensorflow/tensorflow-pywrap_tf_optimizer,yongtang/tensorflow,paolodedios/tensorflow,karllessard/tensorflow,Intel-tensorflow/tensorflow,tensorflow/tensorflow,Intel-tensorflow/tensorflow,paolodedios/tensorflow,yongtang/tensorflow,paolodedios/tensorflow,karllessard/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-exp...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "24d3f64ad78415f008af4bdde57079e331545dbf" TFRT_SHA256 = "00afec2e99d50a817a9a3bdea6f7...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "af2213b972c9f736109d4249089c9398c09a8add" TFRT_SHA256 = "ce588cd5aa843316c6b759315cbc...
apache-2.0
Python
1ef4cc5ca233eabc8b7002b70b865aa0ed9ff409
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/f09caec27d101ea44157f209bcfdc62ab62da4e4.
karllessard/tensorflow,tensorflow/tensorflow-experimental_link_static_libraries_once,tensorflow/tensorflow,Intel-tensorflow/tensorflow,Intel-Corporation/tensorflow,gautam1858/tensorflow,Intel-tensorflow/tensorflow,Intel-Corporation/tensorflow,Intel-Corporation/tensorflow,gautam1858/tensorflow,karllessard/tensorflow,ten...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "f09caec27d101ea44157f209bcfdc62ab62da4e4" TFRT_SHA256 = "cda2b7652b72ecdd55f1a33a6c3126f403f3e0ac007014...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "ed84e5f6b49b52f7801e6030fb5ab26f41f2af28" TFRT_SHA256 = "080d122bb57e5b5b51a8c8f3b1916d2f7ea768e09d9a29...
apache-2.0
Python
d1bb3815f694da6bf867d7b171f02554f874a737
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/553df8c12e9ba5930b9b8065f1d012ea07c6044c.
tensorflow/tensorflow-pywrap_saved_model,yongtang/tensorflow,karllessard/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,karllessard/tensorflow,tensorflow/tensorflow,paolodedios/tensorflow,karllessard/tensorflow,yongtang/tensorflow,tensorflow/tensor...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "553df8c12e9ba5930b9b8065f1d012ea07c6044c" TFRT_SHA256 = "477d0374b044c60cd018fdb17e7c...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "2db6a815bd262da6d96d2398c4049230548d8c33" TFRT_SHA256 = "dcc0b3bc54740cabb370d0d773d8...
apache-2.0
Python
c4a4776a78b9f59bc52e799ffe28d17d0340278f
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/0af176c97ea8e57671df14444c4c759211c70b1a.
tensorflow/tensorflow-pywrap_saved_model,Intel-tensorflow/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow-pywrap_saved_model,Intel-tensorflow/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow-pywrap_saved_model,paolodedios/tensorflow,karllessard/tensorflow,yongtang/tensorflow,tensorflow/tensorflow-pywrap_t...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "0af176c97ea8e57671df14444c4c759211c70b1a" TFRT_SHA256 = "be0251342fe9408261e10638787b...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "2f6de37d68a4c69e2ff9eec3cebbf1369e496940" TFRT_SHA256 = "cf180c95c54d1132366996482a5c...
apache-2.0
Python
f56dd27d3e94d15af6ca82e3e5a5c4fbaf34771d
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/d543fafbb8dfa546945c5eced829accec1b70b46.
tensorflow/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow,tensorflow/tensorflow,karllessard/tensorflow,tensorflow/tensorflow-pywrap_saved_model,karllessard/tensorflow,Intel-tensorflow/tensorflow,karllessard/tensorflow,paolodedios/tensorflow,tensorflow/tensorflow,yongtang/tensorflow,karllessard/tensorflow,tenso...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "d543fafbb8dfa546945c5eced829accec1b70b46" TFRT_SHA256 = "370f57dc668b4a44b7a0caa6a078...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "8678704dfcf48b2a7039e56fde0e9bd58bce7828" TFRT_SHA256 = "46cd465aab34eec5f21f1ff74607...
apache-2.0
Python
4e0e42544237ce612d5ec3e4dc6a6a8ab8e58df2
Update TFRT dependency to use revision http://github.com/tensorflow/runtime/commit/06855ca4832377a2bdc8fdb3200415a219906c02.
tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,tensorflow/tensorflow-pywrap_saved_model,paolodedios/tensorflow,tensorflow/tensorflow,Intel-tensorflow/tensorflow,Intel-tensorflow/tensorflow,Intel-tensorflow/tensorflow,Intel-tensorflow/tensorflow...
third_party/tf_runtime/workspace.bzl
third_party/tf_runtime/workspace.bzl
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "06855ca4832377a2bdc8fdb3200415a219906c02" TFRT_SHA256 = "e0ca743f255e4f24e1a84b0fe60f...
"""Provides the repository macro to import TFRT.""" load("//third_party:repo.bzl", "tf_http_archive", "tf_mirror_urls") def repo(): """Imports TFRT.""" # Attention: tools parse and update these lines. TFRT_COMMIT = "f66f87bad3576356f286662b0f4a742ffed33c0d" TFRT_SHA256 = "b35a52bcd37a7aca08b0446b96eb...
apache-2.0
Python
190b9ac1aa92c172b102ae7b0d6ff06b823c5a78
add missing imports
schriftgestalt/NotePalettes
FontNote.glyphsPalette/Contents/Resources/plugin.py
FontNote.glyphsPalette/Contents/Resources/plugin.py
# encoding: utf-8 ####################################################################################### # # Palette Plugin # # Read the docs: # https://github.com/schriftgestalt/GlyphsSDK/tree/master/Python%20Templates/Palette # ####################################################################################### ...
# encoding: utf-8 ####################################################################################### # # Palette Plugin # # Read the docs: # https://github.com/schriftgestalt/GlyphsSDK/tree/master/Python%20Templates/Palette # ####################################################################################### ...
apache-2.0
Python
1759e2bec03935e33fe15950e0b5457a0001aaa5
fix conflict
Fresnoy/kart,Fresnoy/kart
school/migrations/0005_studentapplication.py
school/migrations/0005_studentapplication.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations import sortedm2m.fields class Migration(migrations.Migration): dependencies = [ ('assets', '0001_initial'), ('people', '0002_updatefresnoyprofile'), ('school', '0004_rename_newstudent...
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations import sortedm2m.fields class Migration(migrations.Migration): dependencies = [ ('assets', '0001_initial'), ('people', '0002_updatefresnoyprofile'), ('people', '0001_initial'), ...
agpl-3.0
Python
fbdaeff6f01ffaf0ac4f9a0d0d962a19c2865b32
Add docstring documenting the intended use of LabHubApp.
jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab
jupyterlab/labhubapp.py
jupyterlab/labhubapp.py
import os from traitlets import default from .labapp import LabApp try: from jupyterhub.singleuser import SingleUserNotebookApp except ImportError: SingleUserLabApp = None raise ImportError('You must have jupyterhub installed for this to work.') else: class SingleUserLabApp(SingleUserNotebookApp, Lab...
import os import warnings from traitlets import default from .labapp import LabApp try: from jupyterhub.singleuser import SingleUserNotebookApp except ImportError: SingleUserLabApp = None raise ImportError('You must have jupyterhub installed for this to work.') else: class SingleUserLabApp(SingleUser...
bsd-3-clause
Python
8cf24b479ca3602ac4471d29f90821c4edc56ad7
Update CondenseLabel.py
DigitalSlideArchive/HistomicsTK,DigitalSlideArchive/HistomicsTK
histomicstk/segmentation/label/CondenseLabel.py
histomicstk/segmentation/label/CondenseLabel.py
import numpy as np import scipy.ndimage.measurements as ms def CondenseLabel(Label): """ Shifts labels in a label image to fill in gaps corresponding to missing values. Parameters ---------- Label : array_like A label image generated by segmentation methods. Returns ------- ...
import numpy as np from skimage import measure as ms def CondenseLabel(Label): """ Shifts labels in a label image to fill in gaps corresponding to missing values. Parameters ---------- Label : array_like A label image generated by segmentation methods. Returns ------- Con...
apache-2.0
Python
87f1f5c5198ae8511c7936130f27b0361c5b3187
Update logging.py
MCPEBukkit/Python_PE,MCPEBukkit/Python_PE
src/logging.py
src/logging.py
import logging class logger(object): def info(self, message): logging.info("[INFO] "+message) def warning(self, message): logging.warning("[WARNING] "+message) def error(self, message): logging.error("[ERROR] "+message) def debug(self, message): logging.debug("[DEBUG] "+message) def critical(self,...
import logging class logger: def info(message): logging.info("[INFO] "+message) def warning(message): logging.warning("[WARNING] "+message) def error(message): logging.error("[ERROR] "+message) def debug(message): logging.debug("[DEBUG] "+message) def critical(message) logging.critical("[CRITICA...
mit
Python
de9f9c07c6f1dde8d7ad314b6a6fb58a963e1558
Return as many results as possible
6/GeoDJ,6/GeoDJ
geodj/youtube.py
geodj/youtube.py
from gdata.youtube.service import YouTubeService, YouTubeVideoQuery from django.utils.encoding import smart_str import re class YoutubeMusic: def __init__(self): self.service = YouTubeService() def search(self, artist): query = YouTubeVideoQuery() query.vq = artist query.orderb...
from gdata.youtube.service import YouTubeService, YouTubeVideoQuery from django.utils.encoding import smart_str import re class YoutubeMusic: def __init__(self): self.service = YouTubeService() def search(self, artist): query = YouTubeVideoQuery() query.vq = artist query.orderb...
mit
Python
3eb9891b4671900b90a400c0b18513c2964d22fe
Add check to detect if a buildbot slave is running.
eunchong/build,eunchong/build,eunchong/build,eunchong/build
scripts/tools/swarm_bootstrap/start_slave.py
scripts/tools/swarm_bootstrap/start_slave.py
# Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Returns a swarming bot dimensions and setups automatic startup if needed. This file is uploaded the swarming server so the swarming bots can declare thei...
# Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Returns a swarming bot dimensions and setups automatic startup if needed. This file is uploaded the swarming server so the swarming bots can declare thei...
bsd-3-clause
Python
498be7a6d3700322aa470a00791a8b0be849cf0c
Fix shebang declaration.
zolech/zabbix-mesos-template
getMesosStats.py
getMesosStats.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import urllib2 import json import argparse def get_metric(host, port, metric): response = urllib2.urlopen( 'http://' + host + ':' + port + '/metrics/snapshot') data = json.load(response) # print json.dumps(data, indent=4, sort_keys=Tru...
#!/usr/bin/python # -*- coding: utf-8 -*- import urllib2 import json import argparse def get_metric(host, port, metric): response = urllib2.urlopen( 'http://' + host + ':' + port + '/metrics/snapshot') data = json.load(response) # print json.dumps(data, indent=4, sort_keys=True) ...
mit
Python
c49cf131ddb16157ea1a1663eef63133efe0068d
Implement read operations for queue.file
tilezen/tilequeue,mapzen/tilequeue
tilequeue/queue/file.py
tilequeue/queue/file.py
from tilequeue.tile import serialize_coord class OutputFileQueue(object): def __init__(self, fp): self.fp = fp def enqueue(self, coord): payload = serialize_coord(coord) self.fp.write(payload + '\n') def enqueue_batch(self, coords): n = 0 for coord in coords: ...
from tilequeue.tile import serialize_coord class OutputFileQueue(object): def __init__(self, fp): self.fp = fp def enqueue(self, coord): payload = serialize_coord(coord) self.fp.write(payload + '\n') def enqueue_batch(self, coords): n = 0 for coord in coords: ...
mit
Python
5418907b13d6a00190cd85c5b9b73d4053be34ed
Add licence
sunliwen/alfred-mailto,deanishe/alfred-mailto,deanishe/alfred-mailto,sunliwen/alfred-mailto,deanishe/alfred-mailto,sunliwen/alfred-mailto
src/compose.py
src/compose.py
#!/usr/bin/env python # encoding: utf-8 # # Copyright © 2013 deanishe@deanishe.net. # # MIT Licence. See http://opensource.org/licenses/MIT # # Created on 2013-11-01 # """ Compose new email to specified recipients (if any) in selected client. Client is selected using mailto.py """ from __future__ import print_functi...
#!/usr/bin/env python # encoding: utf-8 """ Compose new email to specified recipients (if any) in selected client. Client is selected using mailto.py """ from __future__ import print_function import sys import os from subprocess import check_call import alfred from mailto import MailApps from contacts import get_c...
mit
Python
d8b163a58941b130ba9903ab26463716d52eeaa0
Fix running on patchlevel versions below the highest of that minor version
github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql,github/codeql
java/kotlin-extractor/kotlin_plugin_versions.py
java/kotlin-extractor/kotlin_plugin_versions.py
import platform import re import subprocess import sys def is_windows(): '''Whether we appear to be running on Windows''' if platform.system() == 'Windows': return True if platform.system().startswith('CYGWIN'): return True return False many_versions = [ '1.4.32', '1.5.31', '1.6.10', '...
import platform import re import subprocess import sys def is_windows(): '''Whether we appear to be running on Windows''' if platform.system() == 'Windows': return True if platform.system().startswith('CYGWIN'): return True return False many_versions = [ '1.4.32', '1.5.31', '1.6.10', '...
mit
Python
39a9131a0d0ce1d59c970b089acc1da4af006b2b
bump version number
Jackevansevo/taggy,Jackevansevo/taggy
taggy/__init__.py
taggy/__init__.py
__version__ = "0.2.1"
__version__ = "0.2.0"
mit
Python
dfec00fb9d14ec0689dd0378793c4dcaac071c6e
Optimize imports
bit0001/trajectory_tracking,bit0001/trajectory_tracking
src/control.py
src/control.py
#!/usr/bin/env python import rospy from gazebo_msgs.msg import ModelStates from geometry_msgs.msg import Twist from constants import DELTA_T, STEPS from controller import create_controller from plotter import Plotter def get_pose(message): global current_pose current_pose = message.pose[2] def compute_cont...
#!/usr/bin/env python import rospy from gazebo_msgs.msg import ModelStates from geometry_msgs.msg import Twist, Pose from constants import DELTA_T, STEPS from controller import EulerMethodController, create_controller from plotter import Plotter def get_pose(message): global current_pose current_pose = messa...
mit
Python
bec7885f9ab3314e8627f6b3c384a9dc457fca0f
Update markdown to fix /r/RivenMains
festinuz/cmcb,festinuz/cmcb
cmcb/static_data.py
cmcb/static_data.py
SECOND = 1 MINUTE = 60*SECOND HOUR = 60*MINUTE DAY = 24*HOUR WEEK = 7*DAY REDDIT_UPDATE_TIMEOUT = MINUTE LEAGUE_UPDATE_TIMEOUT = HOUR TEXT_HEAD = ''' Hello, /r/{subreddit}! This post updates automatically to help you find desired club or fill your club with some folks! You can find additional info at the end of the p...
SECOND = 1 MINUTE = 60*SECOND HOUR = 60*MINUTE DAY = 24*HOUR WEEK = 7*DAY REDDIT_UPDATE_TIMEOUT = MINUTE LEAGUE_UPDATE_TIMEOUT = HOUR TEXT_HEAD = ''' Hello, /r/{subreddit}! This post updates automatically to help you find desired club or fill your club with some folks! You can find additional info at the end of the p...
mit
Python
b4e765a674b5ecaa10d233cd7dca8696bc381589
Add default tensorboard docker image
polyaxon/polyaxon,polyaxon/polyaxon,polyaxon/polyaxon
polyaxon/polyaxon/config_settings/spawner.py
polyaxon/polyaxon/config_settings/spawner.py
# -*- coding: utf-8 -*- from __future__ import absolute_import, division, print_function from polyaxon.utils import config # Roles ROLE_LABELS_WORKER = config.get_string('POLYAXON_ROLE_LABELS_WORKER') ROLE_LABELS_DASHBOARD = config.get_string('POLYAXON_ROLE_LABELS_DASHBOARD') ROLE_LABELS_LOG = config.get_string('POLY...
# -*- coding: utf-8 -*- from __future__ import absolute_import, division, print_function from polyaxon.utils import config # Roles ROLE_LABELS_WORKER = config.get_string('POLYAXON_ROLE_LABELS_WORKER') ROLE_LABELS_DASHBOARD = config.get_string('POLYAXON_ROLE_LABELS_DASHBOARD') ROLE_LABELS_LOG = config.get_string('POLY...
apache-2.0
Python
db1653c551f71092a7eca96e6a4d1c96ef17e06a
Remove unused attributes; also, empty responses after it's flushed.
rapidsms/rapidsms-legacy,rapidsms/rapidsms-legacy,rapidsms/rapidsms-legacy
lib/rapidsms/message.py
lib/rapidsms/message.py
#!/usr/bin/env python # vim: ai ts=4 sts=4 et sw=4 import copy class Message(object): def __init__(self, backend, caller=None, text=None): self._backend = backend self.caller = caller self.text = text self.responses = [] def __unicode__(self): return self.text ...
#!/usr/bin/env python # vim: ai ts=4 sts=4 et sw=4 import copy class Message(object): def __init__(self, backend, caller=None, text=None): self._backend = backend self.caller = caller self.text = text # initialize some empty attributes self.received = None ...
bsd-3-clause
Python
2b299ea1a62c61dbabbe7e27e75d7a566c138e9e
remove onchange and set compute right. (#1327)
avanzosc/odoo-addons,avanzosc/odoo-addons
product_vat_price/models/product_template.py
product_vat_price/models/product_template.py
# Copyright 2021 Berezi - AvanzOSC # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from odoo import models, fields, api class ProductTemplate(models.Model): _inherit = 'product.template' vat_price = fields.Float(string='VAT price', compute='_compute_vat_price') @api.depends("list_p...
# Copyright 2021 Berezi - AvanzOSC # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from odoo import models, fields, api class ProductTemplate(models.Model): _inherit = 'product.template' vat_price = fields.Float(string='VAT price', compute='_compute_vat_price') @api.depends("list_p...
agpl-3.0
Python
8fe0ec8f85e933d9aa64ff619937aba52945ea6e
add LOGGING_LEVEL settings
reorx/torext,reorx/torext
torext/base_settings.py
torext/base_settings.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # variables in this module are essential basements of settings, # the priority sequence of base_settings.py, settings.py(in project), and cmd options is:: # 1. commandline arguments # 2. settings.py # 3. base_settings.py ############# # essential # ############# ...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # variables in this module are essential basements of settings, # the priority sequence of base_settings.py, settings.py(in project), and cmd options is:: # 1. commandline arguments # 2. settings.py # 3. base_settings.py ############# # essential # ############# ...
mit
Python
388653366ee4db58ed8ce8a9c8ab071593b9fc53
Use correct default SSH port
GaretJax/lancet,GaretJax/lancet
lancet/contrib/dploi.py
lancet/contrib/dploi.py
from shlex import quote import click @click.command() @click.option('-p', '--print/--exec', 'print_cmd', default=False, help='Print the command instead of executing it.') @click.argument('environment') @click.pass_obj def ssh(lancet, print_cmd, environment): """ SSH into the given environment, ...
from shlex import quote import click @click.command() @click.option('-p', '--print/--exec', 'print_cmd', default=False, help='Print the command instead of executing it.') @click.argument('environment') @click.pass_obj def ssh(lancet, print_cmd, environment): """ SSH into the given environment, ...
mit
Python
d859bfde2fb6aca986857d4e0460a65e24ee6029
fix remaining tests to reflect new behavior of sign(nan)
chadnetzer/numpy-gaurdro,teoliphant/numpy-refactor,illume/numpy3k,teoliphant/numpy-refactor,jasonmccampbell/numpy-refactor-sprint,efiring/numpy-work,efiring/numpy-work,jasonmccampbell/numpy-refactor-sprint,illume/numpy3k,efiring/numpy-work,chadnetzer/numpy-gaurdro,Ademan/NumPy-GSoC,teoliphant/numpy-refactor,Ademan/NumP...
numpy/lib/tests/test_ufunclike.py
numpy/lib/tests/test_ufunclike.py
""" >>> import numpy.core as nx >>> import numpy.lib.ufunclike as U Test fix: >>> a = nx.array([[1.0, 1.1, 1.5, 1.8], [-1.0, -1.1, -1.5, -1.8]]) >>> U.fix(a) array([[ 1., 1., 1., 1.], [-1., -1., -1., -1.]]) >>> y = nx.zeros(a.shape, float) >>> U.fix(a, y) array([[ 1., 1., 1., 1.], [-1., -1., -1., -...
""" >>> import numpy.core as nx >>> import numpy.lib.ufunclike as U Test fix: >>> a = nx.array([[1.0, 1.1, 1.5, 1.8], [-1.0, -1.1, -1.5, -1.8]]) >>> U.fix(a) array([[ 1., 1., 1., 1.], [-1., -1., -1., -1.]]) >>> y = nx.zeros(a.shape, float) >>> U.fix(a, y) array([[ 1., 1., 1., 1.], [-1., -1., -1., -...
bsd-3-clause
Python
83e2d010ff2c05ddc172ccfa0caf1efe941f3184
Update combine module namespace
redmatter/combine
combine/__init__.py
combine/__init__.py
# Copyright (c) 2010 John Reese # Licensed under the MIT license class CombineError(Exception): def __init__(self, value): self.value = value def __str__(self): return repr(self.value) from combine.formats import Archive, File from combine.config import Config from combine.package import Pack...
# Copyright (c) 2010 John Reese # Licensed under the MIT license class CombineError(Exception): def __init__(self, value): self.value = value def __str__(self): return repr(self.value) from combine.manifest import Manifest from combine.diff import Diff
mit
Python
9b603d07df9be3cbac32d08d0e17ae5c5f9c76ae
Update sphinx_runner to use Sphinx >= 2
allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/intellij-community,allotria/int...
python/helpers/rest_runners/sphinx_runner.py
python/helpers/rest_runners/sphinx_runner.py
if __name__ == "__main__": import sys try: import sphinx except ImportError: raise NameError("Cannot find sphinx in selected interpreter.") version = sphinx.version_info if (version[0] >= 1 and version[1] >= 7) or version[0] >= 2: from sphinx.cmd import build build...
if __name__ == "__main__": import sys try: import sphinx except ImportError: raise NameError("Cannot find sphinx in selected interpreter.") version = sphinx.version_info if version[0] >= 1 and version[1] >= 7: from sphinx.cmd import build build.main(sys.argv[1:]) ...
apache-2.0
Python
bc837143d79faca5de0d1919dd63ceb3800c68e3
Fix the memory function: remove 'X'.
AngelTerrones/Algol,AngelTerrones/Algol
Algol/memIO.py
Algol/memIO.py
#!/usr/bin/env python # Copyright (c) 2015 Angel Terrones (<angelterrones@gmail.com>) # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the r...
#!/usr/bin/env python # Copyright (c) 2015 Angel Terrones (<angelterrones@gmail.com>) # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the r...
mit
Python
332e4a8a35e065fd5535cab716f4e9009ea0bcd1
Set default filter backend for rest framework
bjoernricks/trex,bjoernricks/trex
trex/settings_global.py
trex/settings_global.py
# -*- coding: utf-8 -*- # # (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com> # # See LICENSE comming with the source of 'trex' for details. # """ Django settings for trex project. For more information on this file, see https://docs.djangoproject.com/en/1.7/topics/settings/ For the full list of settings and their values...
# -*- coding: utf-8 -*- # # (c) 2014 Bjoern Ricks <bjoern.ricks@gmail.com> # # See LICENSE comming with the source of 'trex' for details. # """ Django settings for trex project. For more information on this file, see https://docs.djangoproject.com/en/1.7/topics/settings/ For the full list of settings and their values...
mit
Python
e4cff9c25bb768f0068e9e007e919ba52d7efb6f
Fix name prefix for host builds (#8767)
nestlabs/connectedhomeip,project-chip/connectedhomeip,project-chip/connectedhomeip,nestlabs/connectedhomeip,project-chip/connectedhomeip,nestlabs/connectedhomeip,project-chip/connectedhomeip,nestlabs/connectedhomeip,nestlabs/connectedhomeip,project-chip/connectedhomeip,nestlabs/connectedhomeip,project-chip/connectedhom...
scripts/build/builders/host.py
scripts/build/builders/host.py
# Copyright (c) 2021 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
# Copyright (c) 2021 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in ...
apache-2.0
Python
e13be048b4a1582b3579a7d007f06c5c2b98a664
Fix whitespace incoherence, causing pylint errors.
ligthyear/quick-check,ligthyear/quick-check
codereview/middleware.py
codereview/middleware.py
# Copyright 2008 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
# Copyright 2008 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
apache-2.0
Python
ed38e4b98b3a5a06761aecb6a977958a2fdd892e
Increment version number.
rinman24/ucsd_ch
coimbra_chamber/__version__.py
coimbra_chamber/__version__.py
VERSION = (0, 0, 4) __version__ = '.'.join(map(str, VERSION))
VERSION = (0, 0, 3) __version__ = '.'.join(map(str, VERSION))
mit
Python
7d34b407a35fe917e919fc01b3a6c736a7bdc372
Remove admin prefix from url
rosti-cz/django-emailsupport
helpdesk/urls.py
helpdesk/urls.py
from django.conf.urls import patterns, include, url from django.contrib import admin urlpatterns = patterns('', # Examples: # url(r'^$', 'helpdesk.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r'', include(admin.site.urls)), )
from django.conf.urls import patterns, include, url from django.contrib import admin urlpatterns = patterns('', # Examples: # url(r'^$', 'helpdesk.views.home', name='home'), # url(r'^blog/', include('blog.urls')), url(r'^admin/', include(admin.site.urls)), )
mit
Python
e2018c1c344e9482a99a3d187d740b32c0fdd7ec
Update server.py
mikelambson/tcid,mikelambson/tcid,mikelambson/tcid,mikelambson/tcid
src/server.py
src/server.py
#Import flask libraries import json, re, os, datetime, logging;#Import general libraries from flask import Flask, jsonify, request, render_template, send_from_directory, redirect; from flask_socketio import SocketIO, send, emit, join_room, leave_room, close_room; from flask_mail import Mail, Message; from flask_socketi...
#Import flask libraries import json, re, os, datetime, logging;#Import general libraries from flask import Flask, jsonify, request, render_template, send_from_directory, redirect; from flask_socketio import SocketIO, send, emit, join_room, leave_room, close_room; from flask_mail import Mail, Message; from flask_socketi...
bsd-3-clause
Python
566f30b14f018b66fe800cdb56dfb3e52b7c15c9
Update ipc_lista1.13.py
any1m1c/ipc20161
lista1/ipc_lista1.13.py
lista1/ipc_lista1.13.py
#ipc_lista1.13 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # #Tendo como dados de entrada a altura e o sexo de uma pessoa, constru um algoritmo que calcule seu peso ideal, utilizando as seguintes fórmulas: #Para homens: (72.7*h) - 58 #Para mulheres: (62.1*h) - 44.7 (h = altura) #Peça o peso da pe...
#ipc_lista1.13 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # #Tendo como dados de entrada a altura e o sexo de uma pessoa, constru um algoritmo que calcule seu peso ideal, utilizando as seguintes fórmulas: #Para homens: (72.7*h) - 58 #Para mulheres: (62.1*h) - 44.7 (h = altura) #Peça o peso da pe...
apache-2.0
Python
801d2847631daa21325cfbb49e5315e903fcbeb1
Update ipc_lista1.14.py
any1m1c/ipc20161
lista1/ipc_lista1.14.py
lista1/ipc_lista1.14.py
#ipc_lista1.14 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # # #João Papo-de-Pescador, homem de bem, comprou um microcomputador para controlar o rendimento diário de seu trabalho. Toda vez que ele traz um peso de peixes maior que o estabelecido pelo regulamento de pesca do estado de São Paulo (50...
#ipc_lista1.14 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # # #João Papo-de-Pescador, homem de bem, comprou um microcomputador para controlar o rendimento diário de seu trabalho. Toda vez que ele traz um peso de peixes maior que o estabelecido pelo regulamento de pesca do estado de São Paulo (50...
apache-2.0
Python
cd2b1d7b062d292182df1dde57637878cc5b3cb6
Update ipc_lista2.01.py
any1m1c/ipc20161
lista2/ipc_lista2.01.py
lista2/ipc_lista2.01.py
#ipc_lista2.1 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # #Faça um programa que peça dois números e imprima o maior deles. num1 = float(input("Informe um número: "
#ipc_lista2.1 #Professor: Jucimar Junior #Any Mendes Carvalho - 1615310044 # # # # #Faça um programa que peça dois números e imprima o maior deles. num1 = float(input("Informe um número
apache-2.0
Python
d7091b43fd483de9f6993a070698f24067bebbba
Update ipc_lista4.08.py
any1m1c/ipc20161
lista4/ipc_lista4.08.py
lista4/ipc_lista4.08.py
""" lista 4 questao 8: Faça um Programa que peça a idade e a altura de 5 pessoas, armazene cada informação no seu respectivo vetor. Imprima a idade e a altura na ordem inversa a ordem lida. """ # EQUIPE 2 #ANA BEATRIZ FROTA - 1615310027 # # # # # #Luiz Gustavo Rocha Melo - 1615310015 altura = [] #ve...
""" lista 4 questao 8: Faça um Programa que peça a idade e a altura de 5 pessoas, armazene cada informação no seu respectivo vetor. Imprima a idade e a altura na ordem inversa a ordem lida. """ # EQUIPE 2 #ANA BEATRIZ FROTA - 1615310027 # # #Luiz Gustavo Rocha Melo - 1615310015 altura = [] #vetor para altu...
apache-2.0
Python
90a9cee8349ccc9ec024b25f17f7d29f75c70524
Bump version number
TheKysek/MiNode,TheKysek/MiNode
src/shared.py
src/shared.py
# -*- coding: utf-8 -*- import logging import os import queue import threading listening_port = 8444 send_outgoing_connections = True data_directory = 'minode_data/' source_directory = os.path.dirname(os.path.realpath(__file__)) log_level = logging.DEBUG magic_bytes = b'\xe9\xbe\xb4\xd9' protocol_version = 3 service...
# -*- coding: utf-8 -*- import logging import os import queue import threading listening_port = 8444 send_outgoing_connections = True data_directory = 'minode_data/' source_directory = os.path.dirname(os.path.realpath(__file__)) log_level = logging.DEBUG magic_bytes = b'\xe9\xbe\xb4\xd9' protocol_version = 3 service...
mit
Python
d2ac7fdc28d3aeede4021fad6b9f51a8d79fe0a9
add pre-save check
mylokin/mongoext
mongoext/models.py
mongoext/models.py
from __future__ import absolute_import import mongoext.collection import mongoext.fields class MetaModel(type): def __new__(cls, name, bases, attrs): fields = {} for base in bases: for attr, obj in vars(base).iteritems(): if issubclass(type(obj), mongoext.fields.Field)...
from __future__ import absolute_import import mongoext.collection import mongoext.fields class MetaModel(type): def __new__(cls, name, bases, attrs): fields = {} for base in bases: for attr, obj in vars(base).iteritems(): if issubclass(type(obj), mongoext.fields.Field)...
mit
Python
c97abd1aca254b1ede05ef33ecefa8402fdcb0ac
add message for notice types creation
SoPR/horas,SoPR/horas,SoPR/horas,SoPR/horas
apps/core/management/commands/create_notice_types.py
apps/core/management/commands/create_notice_types.py
from django.core.management.base import BaseCommand from django.utils.translation import ugettext_noop as _ from django.db.models import signals from notification import models as notification class Command(BaseCommand): def handle(self, *args, **options): notification.create_notice_type("create_meeting_...
from django.core.management.base import BaseCommand from django.utils.translation import ugettext_noop as _ from django.db.models import signals from notification import models as notification class Command(BaseCommand): def handle(self, *args, **options): notification.create_notice_type("create_meeting_...
mit
Python
9befb6021a55cdf584c39a3f5e9fa3191a415a50
Fix code health issues reported by Landscape.io
lukeyeager/compare-versions,lukeyeager/compare-versions
compare_versions/core.py
compare_versions/core.py
from . import schemes VALID_COMPARISONS=['eq','ne','gt','lt','ge','le'] def is_valid(version): try: schemes.schemes['semver'](version) except schemes.InvalidVersionError: return False return True def verify_list(versions, comparison='lt', scheme='semver'): """ Verify that a list o...
from . import schemes VALID_COMPARISONS=['eq','ne','gt','lt','ge','le'] def is_valid(version): try: schemes.schemes['semver'](version) except schemes.InvalidVersionError: return False return True def verify_list(versions, comparison='lt', scheme='semver'): """ Verify that a list o...
mit
Python
7568b5c4869a5ab4c5e483393f901b77b70ebced
Fix typo in word API test.
PhilHarnish/forge,PhilHarnish/forge,PhilHarnish/forge,PhilHarnish/forge,PhilHarnish/forge,PhilHarnish/forge
spec/data/word_api/wordnet/_word_api_spec.py
spec/data/word_api/wordnet/_word_api_spec.py
from data.word_api import word_api from spec.mamba import * _word_api = None with _description('_word_api'): with before.all: global _word_api _word_api = word_api.get_api('wordnet') with description('base_form'): with it('handles plurals'): expect(_word_api.base_form('snails')).to(equal('snail...
from data.word_api import word_api from spec.mamba import * _word_api = None with _description('_word_api'): with before.all: global _word_api _word_api = word_api.get_api('wordnet') with description('base_form'): with it('handles plurals'): expect(_word_api.base_form('snails')).to(equal('snail...
mit
Python
e5c81f533099fc21d1da67ffdd91a2dafda08429
fix for both envs?
ibiwan/ibcomics,ibiwan/ibcomics
ibcomics/wsgi.py
ibcomics/wsgi.py
""" WSGI config for ibcomics project. This module contains the WSGI application used by Django's development server and any production WSGI deployments. It should expose a module-level variable named ``application``. Django's ``runserver`` and ``runfcgi`` commands discover this application via the ``WSGI_APPLICATION``...
""" WSGI config for ibcomics project. This module contains the WSGI application used by Django's development server and any production WSGI deployments. It should expose a module-level variable named ``application``. Django's ``runserver`` and ``runfcgi`` commands discover this application via the ``WSGI_APPLICATION``...
apache-2.0
Python
4af2d1286a6a6b8d6bf91f0d5f707b3d999b53d7
Set null in the "Elevation" field
nkoech/csacompendium,nkoech/csacompendium,nkoech/csacompendium
csacompendium/locations/models.py
csacompendium/locations/models.py
from __future__ import unicode_literals from django.conf import settings from django.contrib.contenttypes.fields import GenericForeignKey from django.contrib.contenttypes.models import ContentType from django.db import models # from django.db.models.signals import pre_save # from django.dispatch import receiver # from...
from __future__ import unicode_literals from django.conf import settings from django.contrib.contenttypes.fields import GenericForeignKey from django.contrib.contenttypes.models import ContentType from django.db import models # from django.db.models.signals import pre_save # from django.dispatch import receiver # from...
mit
Python
0079d87a51267e73d1083c339f10df8f31712968
Fix Python 2
rollforbugs/cscslackbot,rollforbugs/cscslackbot
cscslackbot/logconfig/__init__.py
cscslackbot/logconfig/__init__.py
import logging import logging.config import logging.handlers import six import sys from ..utils import from_human_readable def configure(config): format = config.get('format', None) datefmt = config.get('datefmt', None) fmtstyle = config.get('fmtstyle', '%') if six.PY2: formatter = logging.Fo...
import logging import logging.config import logging.handlers import sys from ..utils import from_human_readable def configure(config): format = config.get('format', None) datefmt = config.get('datefmt', None) fmtstyle = config.get('fmtstyle', '%') formatter = logging.Formatter(format, datefmt, fmtsty...
mit
Python
0275ababbed41a6c051938f8cf3a2defe1962fe1
Fix wrong finally clause
znerol/py-idlk
idlk/__init__.py
idlk/__init__.py
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals import os import sys import idlk.base41 if sys.version_info[0] == 3: _get_byte = lambda c: c else: _get_byte = ord def hash_macroman(data): h = 0 for c in data: h = ((h << 8) + h) + ...
from __future__ import absolute_import from __future__ import division from __future__ import unicode_literals import os import sys import idlk.base41 if sys.version_info[0] == 3: _get_byte = lambda c: c else: _get_byte = ord def hash_macroman(data): h = 0 for c in data: h = ((h << 8) + h) + ...
mit
Python
d6caf2f1eb407eb63e0e6dc7e1375a81fcd5ff81
Implement data coordinator in CalFlora
jnfrye/local_plants_book
scripts/observations/scrape/CalFloraScraper.py
scripts/observations/scrape/CalFloraScraper.py
from selenium import webdriver import pandas as pd import argparse import PyFloraBook.web.communication as scraping import PyFloraBook.input_output.data_coordinator as dc # ---------------- INPUT ---------------- # Parse arguments parser = argparse.ArgumentParser( description='Scrape CalFlora for species counts...
from selenium import webdriver import pandas as pd import argparse import PyFloraBook.web.communication as scraping # ---------------- INPUT ---------------- # Parse arguments parser = argparse.ArgumentParser( description='Scrape CalFlora for species counts for given family') parser.add_argument("-f", "--familie...
mit
Python
b1e35e8eea2e91013967b0544088036d56014c34
fix style errors
trbs/bucky,trbs/bucky,jsiembida/bucky3
contrib/statsd_perfomance_test.py
contrib/statsd_perfomance_test.py
#!/usr/bin/env python import multiprocessing import bucky.statsd import time import timeit l10 = range(10) l100 = range(100) l1000 = range(1000) # try: # import queue # except ImportError: # import Queue as queue queue = multiprocessing.Queue() handler = bucky.statsd.StatsDHandler(queue, bucky.cfg) def f...
#!/usr/bin/env python import multiprocessing import bucky.statsd import time import timeit l10 = range(10) l100 = range(100) l1000 = range(1000) # try: # import queue # except ImportError: # import Queue as queue queue = multiprocessing.Queue() handler = bucky.statsd.StatsDHandler(queue, bucky.cfg) def f...
apache-2.0
Python
52d76647b1fa50a2649335b65f22f88d7877e9d3
Return to old setting of repetitions for fast testing
bees4ever/spotpy,bees4ever/spotpy,thouska/spotpy,thouska/spotpy,bees4ever/spotpy,thouska/spotpy
spotpy/unittests/test_fast.py
spotpy/unittests/test_fast.py
import unittest try: import spotpy except ImportError: import sys sys.path.append(".") import spotpy from spotpy.examples.spot_setup_hymod_python import spot_setup class TestFast(unittest.TestCase): def setUp(self): self.spot_setup = spot_setup() self.rep = 200 # REP must be a...
import unittest try: import spotpy except ImportError: import sys sys.path.append(".") import spotpy from spotpy.examples.spot_setup_hymod_python import spot_setup class TestFast(unittest.TestCase): def setUp(self): self.spot_setup = spot_setup() self.rep = 200 # REP must be a...
mit
Python
06ef27c5767947c324d787c23c0acb887ea7f914
Remove an useless shebang form non-executable file (#1073)
PKRoma/httpie,PKRoma/httpie,jakubroztocil/httpie,jakubroztocil/httpie,jakubroztocil/httpie,jkbrzt/httpie,jkbrzt/httpie,jkbrzt/httpie
httpie/__main__.py
httpie/__main__.py
"""The main entry point. Invoke as `http' or `python -m httpie'. """ import sys def main(): try: from httpie.core import main exit_status = main() except KeyboardInterrupt: from httpie.status import ExitStatus exit_status = ExitStatus.ERROR_CTRL_C sys.exit(exit_status.val...
#!/usr/bin/env python """The main entry point. Invoke as `http' or `python -m httpie'. """ import sys def main(): try: from httpie.core import main exit_status = main() except KeyboardInterrupt: from httpie.status import ExitStatus exit_status = ExitStatus.ERROR_CTRL_C sy...
bsd-3-clause
Python
0afb9c02a63a4d96fa21f825a98139878df06dfc
add a-game-of-stones
EdisonCodeKeeper/hacker-rank,EdisonCodeKeeper/hacker-rank,zeyuanxy/hacker-rank,EdisonAlgorithms/HackerRank,zeyuanxy/hacker-rank,EdisonCodeKeeper/hacker-rank,zeyuanxy/hacker-rank,EdisonAlgorithms/HackerRank,EdisonCodeKeeper/hacker-rank,zeyuanxy/hacker-rank,EdisonAlgorithms/HackerRank,EdisonAlgorithms/HackerRank,zeyuanxy...
contest/5-days-of-game-theory/a-game-of-stones/a-game-of-stones.py
contest/5-days-of-game-theory/a-game-of-stones/a-game-of-stones.py
# -*- coding: utf-8 -*- # @Author: Zeyuan Shang # @Date: 2016-05-13 13:42:03 # @Last Modified by: Zeyuan Shang # @Last Modified time: 2016-05-13 13:42:08 T = input() for _ in xrange(T): n = input() dp = [False] * (n + 1) for i in xrange(n + 1): res = False for j in [2, 3, 5]: ...
mit
Python
5c91a2c8dda69d37fd3cd0989ff6c3883851eaef
Introduce templatetag for fetching image thumbnails
tfroehlich82/saleor,itbabu/saleor,UITools/saleor,maferelo/saleor,tfroehlich82/saleor,tfroehlich82/saleor,car3oon/saleor,KenMutemi/saleor,KenMutemi/saleor,jreigel/saleor,maferelo/saleor,car3oon/saleor,KenMutemi/saleor,mociepka/saleor,car3oon/saleor,HyperManTT/ECommerceSaleor,HyperManTT/ECommerceSaleor,maferelo/saleor,UI...
saleor/product/templatetags/product_images.py
saleor/product/templatetags/product_images.py
import logging import warnings from django.template.context_processors import static from django import template from django.conf import settings logger = logging.getLogger(__name__) register = template.Library() # cache available sizes at module level def get_available_sizes(): all_sizes = set() keys = set...
bsd-3-clause
Python
304e8d68e114eda8fe420e64f0255a816fbc5009
Add a very basic test, #1
lord63/py-spin
test_pyspin.py
test_pyspin.py
#!/usr/bin/env python # -*- coding: utf-8 -*- import time from pyspin import spin def test_spinner(): spinner = spin.Spinner(spin.Spin9) assert spinner.length == 4 assert spinner.frames == spin.Spin9 assert spinner.current() == u'←' assert spinner.next() == u'←' assert spinner.next() == u'...
mit
Python
9c1ee652684fec9dc3b9ed487bfd980e886ec9fc
Add regression test for #1698
explosion/spaCy,spacy-io/spaCy,explosion/spaCy,recognai/spaCy,aikramer2/spaCy,spacy-io/spaCy,honnibal/spaCy,recognai/spaCy,spacy-io/spaCy,explosion/spaCy,recognai/spaCy,aikramer2/spaCy,honnibal/spaCy,spacy-io/spaCy,recognai/spaCy,explosion/spaCy,aikramer2/spaCy,recognai/spaCy,honnibal/spaCy,spacy-io/spaCy,honnibal/spaC...
spacy/tests/regression/test_issue1698.py
spacy/tests/regression/test_issue1698.py
# coding: utf8 from __future__ import unicode_literals import pytest @pytest.mark.parametrize('text', ['test@example.com', 'john.doe@example.co.uk']) def test_issue1698(en_tokenizer, text): doc = en_tokenizer(text) assert len(doc) == 1 assert not doc[0].like_url
mit
Python
42a18ef9030f883563c4459aec46563877274794
Add test for #1868: Vocab.__contains__ with ints
honnibal/spaCy,explosion/spaCy,aikramer2/spaCy,aikramer2/spaCy,spacy-io/spaCy,spacy-io/spaCy,explosion/spaCy,recognai/spaCy,aikramer2/spaCy,spacy-io/spaCy,honnibal/spaCy,explosion/spaCy,aikramer2/spaCy,spacy-io/spaCy,explosion/spaCy,honnibal/spaCy,aikramer2/spaCy,recognai/spaCy,explosion/spaCy,spacy-io/spaCy,honnibal/s...
spacy/tests/regression/test_issue1868.py
spacy/tests/regression/test_issue1868.py
'''Test Vocab.__contains__ works with int keys''' from __future__ import unicode_literals from ... vocab import Vocab def test_issue1868(): vocab = Vocab() lex = vocab['hello'] assert lex.orth in vocab assert lex.orth_ in vocab assert 'some string' not in vocab int_id = vocab.strings.add('some...
mit
Python
2a5b8283bf653e7691b91217c2fe225ab0699571
update finalization rainfall
spatialexplore/idn_vam_wfp
python/finalization_shp_dbf.py
python/finalization_shp_dbf.py
# sample input = python finalization_shp_dbf.py /var/lib/opengeo/geoserver/data/IDN_GIS/05_Analysis/03_Early_Warning/Rainfall_Anomaly_test/ 2016-07 import shapefile import sys import datetime import dbf location_geoserver = str(sys.argv[1]) filename = location_geoserver.split('/')[-2] period = str(sys.argv[2]) period...
mit
Python
39e31d6dd129d4acd9adc95ce0bb7a5c9c45dd42
Create Dictionary_example.py
Jeevan-J/Python_Funcode
Python3-5/Dictionary_example.py
Python3-5/Dictionary_example.py
#With a given integral number n, write a program to generate a dictionary that contains (i, i*i) such that is an integral number between 1 and n (both included). and then the program should print the dictionary. n=int(input("Please enter a number")); # takes an integer from user d=dict(); ...
bsd-2-clause
Python
cf8744e8f9d3f4d77093ecf1cce119161f395b78
add tests
iDevy/rdp,mznkcyr/rdp,fhirschmann/rdp
tests.py
tests.py
import unittest import numpy as np from numpy.testing import assert_array_equal as assertAE from rdp import rdp class RDPTest(unittest.TestCase): def test_two(self): assertAE(rdp(np.array([[0, 0], [4, 4]])), np.array([[0, 0], [4, 4]])) def test_hor(self): assertAE(rdp(np.arr...
mit
Python
a7bff3fdc7e328fb0c11fbf0450db78997d2e307
Create contour.py
metissec/contour
contour.py
contour.py
#!/usr/bin/python import matplotlib import matplotlib.pyplot as plt import numpy as np import geotiler from scipy.stats import gaussian_kde class Contour(): def __init__(self, in_f,pix_size=2000,inch_size=10,dpi=200,zoom=14): #init varibles self.in_f = in_f self.np = np self.plt...
mit
Python
bb197fcee1c809e377d235346fcb0a670f35d918
Create counter.py
praveendareddy21/my-repo,praveendareddy21/my-repo
counter.py
counter.py
from collections import Counter l=[12,3,4,2,4,2,4,23,4,1,2] c=Counter(iterable=l) print c.most_common(2) print list(c.elements()) c.clear()
mit
Python
cb85810364a235426147a440da797d35d114c5a6
Test Commit
SharedKnowledge/SharkPython,SharedKnowledge/SharkPython,SharedKnowledge/SharkPython
raspberry/asip/RelationSemanticTag.py
raspberry/asip/RelationSemanticTag.py
from SemanticTag import * #Test
agpl-3.0
Python
ef335362b5f601da41377984b8d9cc675d9ed669
Create ddns_sync.py
sachiel/devops-tools
ddns_sync.py
ddns_sync.py
#!/usr/bin/env python3 import boto3 from get import getjson query = "http://evolutiva.mx/getip/" data = getjson(query) if not data: exit() new_ip = dict(data)['ip'] old_ip = None r53 = boto3.client('route53') #.connect_to_region('us-west-2') try: for res in r53.list_resource_record_sets(HostedZoneId='/hos...
mit
Python
5cf79e395802ae5db7d21d07cb6e8042793f5c26
Add easycrud versions of generic views
dekkers/django-easycrud,dekkers/django-easycrud
easycrud/views.py
easycrud/views.py
from django.views.generic import (ListView as DjangoListView, DetailView as DjangoDetailView, UpdateView as DjangoUpdateView, CreateView as DjangoCreateView, DeleteView as DjangoDeleteView) from django.contrib.auth.decorators import login_required fro...
bsd-2-clause
Python
bc68c04b9be33329e4c28689053300360b6393b4
create Clusters class
jesford/cluster-lensing
clusters.py
clusters.py
import numpy as np import pandas as pd from astropy.cosmology import Planck13 as cosmo from astropy import units import sys sys.path.insert(1,'/Users/jesford/astrophysics/cofm') #temporary path adjust from cofm import c_DuttonMaccio try: from IPython.display import display notebook_display = True except: ...
mit
Python
8821fd5e4678dd8a2baf78d3ed068b652a10d1cd
Add initial games unit
Harmon758/Harmonbot,Harmon758/Harmonbot
units/games.py
units/games.py
import random def eightball(): responses = ["It is certain", "It is decidedly so", "Without a doubt", "Yes, definitely", "You may rely on it", "As I see it, yes", "Most likely", "Outlook good", "Yes", "Signs point to yes", "Reply hazy try again", "Ask again later", "Better not tell you now", "Cannot predict now", "C...
mit
Python
0420aa1bf7bb8027379de52de783da87ce253f62
add batch upload script
ViDA-NYU/genotet,ViDA-NYU/genotet,ViDA-NYU/genotet,ViDA-NYU/genotet,ViDA-NYU/genotet
uploadBatch.py
uploadBatch.py
# This is a python script for uploading batch data to Genotet server. # The user may write a *.tsv file, with each line as: # file_path data_name file_type description # The command line would be: # python uploadBatch.py username *.tsv # And then enter your password for Genotet. from requests_toolbelt impo...
apache-2.0
Python
22ae0ef7d2dfe793c9deb7b6c2027d5b5f69b3e0
add lamper script to control colors
nuxis/lamper,nuxis/lamper
lamper.py
lamper.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import requests import os import sys global url #url = '' url = os.environ['LAMPER_URL'] global universe universe = '1' def web_post(url, payload): r = requests.post( url, data=payload, headers={'Content-Type': 'application/x-www-form-urlen...
mit
Python
da373b924cf4dffe639e29543b5fc0e728be1ed9
Add orgviz.randomnodes
tkf/orgviz
orgviz/randomnodes.py
orgviz/randomnodes.py
import random import datetime class RandomDatetime(object): def __init__(self, datewidth=7): self.datewidth = datewidth self.now = datetime.datetime.now() def datetime(self): delta = datetime.timedelta(random.randrange(- self.datewidth, ...
mit
Python
a5bffdaa29d2f270a6f8781c34a2756a66a00a87
Bump version
tobinjt/Flexget,Danfocus/Flexget,JorisDeRieck/Flexget,gazpachoking/Flexget,Flexget/Flexget,Flexget/Flexget,crawln45/Flexget,malkavi/Flexget,ianstalk/Flexget,Danfocus/Flexget,tobinjt/Flexget,Danfocus/Flexget,Flexget/Flexget,malkavi/Flexget,malkavi/Flexget,malkavi/Flexget,Flexget/Flexget,Danfocus/Flexget,crawln45/Flexget...
flexget/_version.py
flexget/_version.py
""" Current FlexGet version. This is contained in a separate file so that it can be easily read by setup.py, and easily edited and committed by release scripts in continuous integration. Should (almost) never be set manually. The version should always be set to the <next release version>.dev The jenkins release job wi...
""" Current FlexGet version. This is contained in a separate file so that it can be easily read by setup.py, and easily edited and committed by release scripts in continuous integration. Should (almost) never be set manually. The version should always be set to the <next release version>.dev The jenkins release job wi...
mit
Python
6b5c46238975eb63b36f43eb79002946a744fd68
Prepare v2.10.47.dev
LynxyssCZ/Flexget,crawln45/Flexget,LynxyssCZ/Flexget,OmgOhnoes/Flexget,JorisDeRieck/Flexget,qk4l/Flexget,gazpachoking/Flexget,Flexget/Flexget,ianstalk/Flexget,LynxyssCZ/Flexget,ianstalk/Flexget,ianstalk/Flexget,JorisDeRieck/Flexget,tobinjt/Flexget,crawln45/Flexget,LynxyssCZ/Flexget,Danfocus/Flexget,malkavi/Flexget,craw...
flexget/_version.py
flexget/_version.py
""" Current FlexGet version. This is contained in a separate file so that it can be easily read by setup.py, and easily edited and committed by release scripts in continuous integration. Should (almost) never be set manually. The version should always be set to the <next release version>.dev The jenkins release job wi...
""" Current FlexGet version. This is contained in a separate file so that it can be easily read by setup.py, and easily edited and committed by release scripts in continuous integration. Should (almost) never be set manually. The version should always be set to the <next release version>.dev The jenkins release job wi...
mit
Python
ea41e4cdc515ca8514c3613a1f474fb3627b7dda
Remove autosynth / tweaks for 'README.rst' / 'setup.py'. (#5957)
tswast/google-cloud-python,jonparrott/google-cloud-python,dhermes/google-cloud-python,GoogleCloudPlatform/gcloud-python,GoogleCloudPlatform/gcloud-python,tswast/google-cloud-python,googleapis/google-cloud-python,jonparrott/gcloud-python,jonparrott/gcloud-python,dhermes/gcloud-python,tseaver/gcloud-python,tseaver/google...
tasks/synth.py
tasks/synth.py
# Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
# Copyright 2018 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, s...
apache-2.0
Python
761ec2bd6492b041eb658ee836a63ffb877469d5
Add management command to load all version fixtures
refreshoxford/django-cbv-inspector,refreshoxford/django-cbv-inspector,refreshoxford/django-cbv-inspector,refreshoxford/django-cbv-inspector
cbv/management/commands/load_all_django_versions.py
cbv/management/commands/load_all_django_versions.py
import os import re from django.conf import settings from django.core.management import call_command, BaseCommand class Command(BaseCommand): """Load the Django project fixtures and all version fixtures""" def handle(self, **options): fixtures_dir = os.path.join(settings.DIRNAME, 'cbv', 'fixtures') ...
bsd-2-clause
Python
9e2fe5de082c736ec44dbf150d8350a0e164d2ae
Create beta_which_operator.py
Orange9000/Codewars,Orange9000/Codewars
Solutions/beta/beta_which_operator.py
Solutions/beta/beta_which_operator.py
def whichOper(a, b, oper): return {'a':lambda x,y: x+y, 's':lambda x,y: x-y, 'm':lambda x,y: x*y, 'd':lambda x,y: x/y}[oper[0]](a,b)
mit
Python
e3dcc7ef44bbc8772fd5ad4f0941e5d98bf1ccdd
add migration
citationfinder/scholarly_citation_finder
scholarly_citation_finder/apps/tasks/migrations/0003_auto_20160224_1349.py
scholarly_citation_finder/apps/tasks/migrations/0003_auto_20160224_1349.py
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('tasks', '0002_task_starttime'), ] operations = [ migrations.RemoveField( model_name='task', name='ta...
mit
Python
0711b2eee10e5e48186d78144697a35640a33cb1
Add a passthrough manager
educreations/django-mysql-fuzzycount
mysql_fuzzycount/managers.py
mysql_fuzzycount/managers.py
from model_utils.managers import PassThroughManager from mysql_fuzzycount.queryset import FuzzyCountQuerySet FuzzyCountManager = PassThroughManager.for_queryset_class(FuzzyCountQuerySet)
mit
Python
56b2897655940962a8cfa06cc8a9fcfe22262412
Create config_local.py
jancelin/geo-poppy,jancelin/geo-poppy
pgadmin4/config_local.py
pgadmin4/config_local.py
# -*- coding: utf-8 -*- ########################################################################## # # pgAdmin 4 - PostgreSQL Tools # # Copyright (C) 2013 - 2016, The pgAdmin Development Team # This software is released under the PostgreSQL Licence # # config_local.py - Core application configuration settings # ######...
agpl-3.0
Python
1de5b9746c33add889837e5e0feaf1796fb00eb8
add script to generate breakseq index
bioinform/breakseq2
scripts/breakseq2_gen_bplib.py
scripts/breakseq2_gen_bplib.py
#!/usr/bin/env python import argparse from breakseq2 import breakseq_index, _version if __name__ == "__main__": parser = argparse.ArgumentParser(description="Generate breakpoint library FASTA from breakpoint GFF", formatter_class=argparse.ArgumentDefaultsHelpFormatter) bre...
bsd-2-clause
Python
4dde2e3718ecd2e3e8b0ffc7e38433e3a9cda546
add beta_vae script
probml/pyprobml,probml/pyprobml,probml/pyprobml,probml/pyprobml
scripts/vae/models/beta_vae.py
scripts/vae/models/beta_vae.py
# -*- coding: utf-8 -*- import torch import torch.nn as nn import torch.nn.functional as F from typing import Optional def kl_divergence(mean, logvar): return -0.5 * torch.mean(1 + logvar - torch.square(mean) - torch.exp(logvar)) def loss(config, x, x_hat, z, mu, logvar): recons_loss = F.mse_loss(x_hat, x, reduc...
mit
Python
33f455cba56c7ae557cfe9f5494b6a045c68f1d2
add simple hello world
benoitc/flower,benoitc/flower
examples/hello.py
examples/hello.py
from flower import run, schedule, tasklet def say(s): for i in range(5): schedule() print(s) def main(): tasklet(say)("world") say("hello") run() if __name__ == '__main__': main()
mit
Python
152dafeeb35647dbcfb25549f7f1e73a397428a0
Add urls for the demo
django-blog-zinnia/zinnia-url-shortener-bitly
demo_zinnia_bitly/urls.py
demo_zinnia_bitly/urls.py
"""Urls for the zinnia-bitly demo""" from django.conf import settings from django.contrib import admin from django.conf.urls import url from django.conf.urls import include from django.conf.urls import patterns from django.views.generic.base import RedirectView from zinnia.sitemaps import TagSitemap from zinnia.sitema...
bsd-3-clause
Python