hexsha string | size int64 | ext string | lang string | max_stars_repo_path string | max_stars_repo_name string | max_stars_repo_head_hexsha string | max_stars_repo_licenses list | max_stars_count int64 | max_stars_repo_stars_event_min_datetime string | max_stars_repo_stars_event_max_datetime string | max_issues_repo_path string | max_issues_repo_name string | max_issues_repo_head_hexsha string | max_issues_repo_licenses list | max_issues_count int64 | max_issues_repo_issues_event_min_datetime string | max_issues_repo_issues_event_max_datetime string | max_forks_repo_path string | max_forks_repo_name string | max_forks_repo_head_hexsha string | max_forks_repo_licenses list | max_forks_count int64 | max_forks_repo_forks_event_min_datetime string | max_forks_repo_forks_event_max_datetime string | content string | avg_line_length float64 | max_line_length int64 | alphanum_fraction float64 | qsc_code_num_words_quality_signal int64 | qsc_code_num_chars_quality_signal float64 | qsc_code_mean_word_length_quality_signal float64 | qsc_code_frac_words_unique_quality_signal float64 | qsc_code_frac_chars_top_2grams_quality_signal float64 | qsc_code_frac_chars_top_3grams_quality_signal float64 | qsc_code_frac_chars_top_4grams_quality_signal float64 | qsc_code_frac_chars_dupe_5grams_quality_signal float64 | qsc_code_frac_chars_dupe_6grams_quality_signal float64 | qsc_code_frac_chars_dupe_7grams_quality_signal float64 | qsc_code_frac_chars_dupe_8grams_quality_signal float64 | qsc_code_frac_chars_dupe_9grams_quality_signal float64 | qsc_code_frac_chars_dupe_10grams_quality_signal float64 | qsc_code_frac_chars_replacement_symbols_quality_signal float64 | qsc_code_frac_chars_digital_quality_signal float64 | qsc_code_frac_chars_whitespace_quality_signal float64 | qsc_code_size_file_byte_quality_signal float64 | qsc_code_num_lines_quality_signal float64 | qsc_code_num_chars_line_max_quality_signal float64 | qsc_code_num_chars_line_mean_quality_signal float64 | qsc_code_frac_chars_alphabet_quality_signal float64 | qsc_code_frac_chars_comments_quality_signal float64 | qsc_code_cate_xml_start_quality_signal float64 | qsc_code_frac_lines_dupe_lines_quality_signal float64 | qsc_code_cate_autogen_quality_signal float64 | qsc_code_frac_lines_long_string_quality_signal float64 | qsc_code_frac_chars_string_length_quality_signal float64 | qsc_code_frac_chars_long_word_length_quality_signal float64 | qsc_code_frac_lines_string_concat_quality_signal float64 | qsc_code_cate_encoded_data_quality_signal float64 | qsc_code_frac_chars_hex_words_quality_signal float64 | qsc_code_frac_lines_prompt_comments_quality_signal float64 | qsc_code_frac_lines_assert_quality_signal float64 | qsc_codepython_cate_ast_quality_signal float64 | qsc_codepython_frac_lines_func_ratio_quality_signal float64 | qsc_codepython_cate_var_zero_quality_signal bool | qsc_codepython_frac_lines_pass_quality_signal float64 | qsc_codepython_frac_lines_import_quality_signal float64 | qsc_codepython_frac_lines_simplefunc_quality_signal float64 | qsc_codepython_score_lines_no_logic_quality_signal float64 | qsc_codepython_frac_lines_print_quality_signal float64 | qsc_code_num_words int64 | qsc_code_num_chars int64 | qsc_code_mean_word_length int64 | qsc_code_frac_words_unique null | qsc_code_frac_chars_top_2grams int64 | qsc_code_frac_chars_top_3grams int64 | qsc_code_frac_chars_top_4grams int64 | qsc_code_frac_chars_dupe_5grams int64 | qsc_code_frac_chars_dupe_6grams int64 | qsc_code_frac_chars_dupe_7grams int64 | qsc_code_frac_chars_dupe_8grams int64 | qsc_code_frac_chars_dupe_9grams int64 | qsc_code_frac_chars_dupe_10grams int64 | qsc_code_frac_chars_replacement_symbols int64 | qsc_code_frac_chars_digital int64 | qsc_code_frac_chars_whitespace int64 | qsc_code_size_file_byte int64 | qsc_code_num_lines int64 | qsc_code_num_chars_line_max int64 | qsc_code_num_chars_line_mean int64 | qsc_code_frac_chars_alphabet int64 | qsc_code_frac_chars_comments int64 | qsc_code_cate_xml_start int64 | qsc_code_frac_lines_dupe_lines int64 | qsc_code_cate_autogen int64 | qsc_code_frac_lines_long_string int64 | qsc_code_frac_chars_string_length int64 | qsc_code_frac_chars_long_word_length int64 | qsc_code_frac_lines_string_concat null | qsc_code_cate_encoded_data int64 | qsc_code_frac_chars_hex_words int64 | qsc_code_frac_lines_prompt_comments int64 | qsc_code_frac_lines_assert int64 | qsc_codepython_cate_ast int64 | qsc_codepython_frac_lines_func_ratio int64 | qsc_codepython_cate_var_zero int64 | qsc_codepython_frac_lines_pass int64 | qsc_codepython_frac_lines_import int64 | qsc_codepython_frac_lines_simplefunc int64 | qsc_codepython_score_lines_no_logic int64 | qsc_codepython_frac_lines_print int64 | effective string | hits int64 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
942fffbcdd4519ebeab883f5ff40dfd48aca5c11 | 1,618 | py | Python | chrome_tracing_for_several_executions/server.py | majid3612/chrome-tracing | f0a4e123ff2c783524077861f9fd783b27470821 | [
"MIT"
] | null | null | null | chrome_tracing_for_several_executions/server.py | majid3612/chrome-tracing | f0a4e123ff2c783524077861f9fd783b27470821 | [
"MIT"
] | null | null | null | chrome_tracing_for_several_executions/server.py | majid3612/chrome-tracing | f0a4e123ff2c783524077861f9fd783b27470821 | [
"MIT"
] | 1 | 2020-01-27T16:37:51.000Z | 2020-01-27T16:37:51.000Z | import argparse
import BaseHTTPServer
import cgi
import os
import socket
import SocketServer
import uuid
PORT = 8080
TRACE_FIELD = 'trace'
class HTTPUploadHandler(BaseHTTPServer.BaseHTTPRequestHandler):
def do_POST(self):
form = cgi.FieldStorage(
fp=self.rfile,
headers=self.headers,
... | 24.892308 | 77 | 0.656984 | 192 | 1,618 | 5.369792 | 0.484375 | 0.067895 | 0.038797 | 0.050436 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.011281 | 0.233004 | 1,618 | 64 | 78 | 25.28125 | 0.8195 | 0 | 0 | 0.039216 | 0 | 0 | 0.15204 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.019608 | 0.137255 | null | null | 0.098039 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9430c72a3907a919203c0f5fddf70901111dbb07 | 1,167 | py | Python | seg_liver_test.py | OpenVessel/liverseg-2017-nipsws | 2a9f42219d4618665c9c17ff356f16e9a4704ee4 | [
"MIT"
] | 3 | 2021-01-23T15:42:19.000Z | 2021-02-19T01:27:46.000Z | seg_liver_test.py | OpenVessel/liverseg-2017-nipsws | 2a9f42219d4618665c9c17ff356f16e9a4704ee4 | [
"MIT"
] | 10 | 2021-02-03T16:52:28.000Z | 2021-03-29T18:28:01.000Z | seg_liver_test.py | OpenVessel/liverseg-2017-nipsws | 2a9f42219d4618665c9c17ff356f16e9a4704ee4 | [
"MIT"
] | null | null | null | """
Original code from OSVOS (https://github.com/scaelles/OSVOS-TensorFlow)
Sergi Caelles (scaelles@vision.ee.ethz.ch)
Modified code for liver and lesion segmentation:
Miriam Bellver (miriam.bellver@bsc.es)
"""
import os
import sys
import tensorflow as tf
slim = tf.contrib.slim
import numpy as np
import seg_liver as ... | 27.139535 | 99 | 0.742074 | 164 | 1,167 | 5 | 0.414634 | 0.04878 | 0.036585 | 0.043902 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001021 | 0.161097 | 1,167 | 42 | 100 | 27.785714 | 0.836568 | 0.208226 | 0 | 0 | 0 | 0 | 0.052928 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.045455 | false | 0 | 0.318182 | 0 | 0.363636 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
94342ab53b7f4df20ee4d868c01af1e9de860aa6 | 740 | py | Python | Distributed/ProcessThread/LocalPoolQueue.py | dltech-xyz/PythonSkillTree | 88fad516b22811205a49b6438d48a6535e8a5441 | [
"Apache-2.0"
] | 26 | 2016-07-11T00:54:39.000Z | 2022-01-11T13:41:47.000Z | Distributed/ProcessThread/LocalPoolQueue.py | w4n9H/PythonSkillTree | 88fad516b22811205a49b6438d48a6535e8a5441 | [
"Apache-2.0"
] | null | null | null | Distributed/ProcessThread/LocalPoolQueue.py | w4n9H/PythonSkillTree | 88fad516b22811205a49b6438d48a6535e8a5441 | [
"Apache-2.0"
] | 7 | 2016-07-14T08:02:37.000Z | 2020-06-28T15:27:21.000Z | # !/usr/bin/env python
# -*- coding: utf-8 -*-
"""
@author: mango
@contact: w4n9@sina.com
@create: 16/7/1
hail hydra!
"""
__author__ = "mango"
__version__ = "0.1"
from multiprocessing import Manager, Pool
def process(q, name):
"""
test process
"""
q.put(1)
def main():
"""
main process
... | 14.8 | 44 | 0.505405 | 90 | 740 | 3.966667 | 0.611111 | 0.067227 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.026804 | 0.344595 | 740 | 49 | 45 | 15.102041 | 0.709278 | 0.056757 | 0 | 0 | 0 | 0 | 0.037234 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.038462 | null | null | 0.115385 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
943a1e6750a5cfee1fef5d8c62c46dfef19e9240 | 5,161 | py | Python | autorest/tests.py | gregschmit/django-autorest | 9c2065ec6871fde1b26d72d9285ad2c3b240dff7 | [
"MIT"
] | 2 | 2020-01-11T02:08:16.000Z | 2020-08-16T08:22:16.000Z | autorest/tests.py | gregschmit/django-autorest | 9c2065ec6871fde1b26d72d9285ad2c3b240dff7 | [
"MIT"
] | null | null | null | autorest/tests.py | gregschmit/django-autorest | 9c2065ec6871fde1b26d72d9285ad2c3b240dff7 | [
"MIT"
] | null | null | null | """
Unit tests
"""
from django.contrib.auth.models import User
from django.test import TestCase
from django.urls import reverse
from rest_framework import status
from rest_framework.test import APIRequestFactory, APITestCase
from . import wsgi
from .api.url_inflect import url_deviations
from .api.views import ModelVi... | 32.872611 | 87 | 0.633404 | 576 | 5,161 | 5.447917 | 0.234375 | 0.050988 | 0.033142 | 0.055449 | 0.460803 | 0.43276 | 0.388145 | 0.284895 | 0.264818 | 0.227852 | 0 | 0.00467 | 0.253246 | 5,161 | 156 | 88 | 33.083333 | 0.809549 | 0.035264 | 0 | 0.271186 | 0 | 0 | 0.156791 | 0.03706 | 0 | 0 | 0 | 0 | 0.169492 | 1 | 0.110169 | false | 0.144068 | 0.076271 | 0 | 0.220339 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
943d6686a13f1577ba30c3a2d02d9946f1b0c9bc | 263 | py | Python | execicios/ex112/utilidadescev/dados/__init__.py | Israel97f/Exercicios-de-Python | 5d3054187977deeb3fadbd7bb1cdee035c609a61 | [
"MIT"
] | null | null | null | execicios/ex112/utilidadescev/dados/__init__.py | Israel97f/Exercicios-de-Python | 5d3054187977deeb3fadbd7bb1cdee035c609a61 | [
"MIT"
] | null | null | null | execicios/ex112/utilidadescev/dados/__init__.py | Israel97f/Exercicios-de-Python | 5d3054187977deeb3fadbd7bb1cdee035c609a61 | [
"MIT"
] | null | null | null | def leiadinheiro(txt):
while True:
din = str(input(f'{txt}')).replace(',', '.').strip()
if din.isalpha() or din == '':
print(f'\033[31mErro! "{din}" é um preço invalido\033[m')
else:
break
return float(din)
| 29.222222 | 69 | 0.505703 | 33 | 263 | 4.030303 | 0.787879 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.043716 | 0.304183 | 263 | 8 | 70 | 32.875 | 0.68306 | 0 | 0 | 0 | 0 | 0 | 0.205323 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0 | 0 | 0.25 | 0.125 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
943f51121776dc4d98da68a7a5bd40e49c5bc9c7 | 12,218 | py | Python | bfillings/cd_hit.py | gregcaporaso/burrito-fillings | a7b3b4db0d20b4baa064d447033782969f491622 | [
"BSD-3-Clause"
] | null | null | null | bfillings/cd_hit.py | gregcaporaso/burrito-fillings | a7b3b4db0d20b4baa064d447033782969f491622 | [
"BSD-3-Clause"
] | null | null | null | bfillings/cd_hit.py | gregcaporaso/burrito-fillings | a7b3b4db0d20b4baa064d447033782969f491622 | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
#-----------------------------------------------------------------------------
# Copyright (c) 2013--, biocore development team.
#
# Distributed under the terms of the Modified BSD License.
#
# The full license is in the file COPYING.txt, distributed with this software.
#-------------------------... | 35.517442 | 82 | 0.628908 | 1,568 | 12,218 | 4.789541 | 0.237883 | 0.022636 | 0.010253 | 0.020772 | 0.468043 | 0.411585 | 0.392144 | 0.334887 | 0.324767 | 0.30972 | 0 | 0.017434 | 0.25356 | 12,218 | 343 | 83 | 35.620991 | 0.806031 | 0.273613 | 0 | 0.377483 | 0 | 0 | 0.081397 | 0.011086 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.05298 | null | null | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
943fbdc865f3ad73926d7e7208a824193fa17527 | 839 | py | Python | resources/scenes/jvm_inject.py | jw10041229/space-capsule | 984c3b255fab8c74214b3801c95f0ce3c81ca407 | [
"Apache-2.0"
] | null | null | null | resources/scenes/jvm_inject.py | jw10041229/space-capsule | 984c3b255fab8c74214b3801c95f0ce3c81ca407 | [
"Apache-2.0"
] | null | null | null | resources/scenes/jvm_inject.py | jw10041229/space-capsule | 984c3b255fab8c74214b3801c95f0ce3c81ca407 | [
"Apache-2.0"
] | null | null | null | # case12
from spacecapsule.k8s import copy_tar_file_to_namespaced_pod, prepare_api, executor_command_inside_namespaced_pod
from spacecapsule.template import resource_path
def case12():
print('TODO')
def slow_code(namespace, pod, claz, method, inject_code):
print('TODO')
def runtime_err():
print('TODO'... | 27.064516 | 113 | 0.755662 | 116 | 839 | 5.172414 | 0.474138 | 0.086667 | 0.08 | 0.043333 | 0.2 | 0.086667 | 0 | 0 | 0 | 0 | 0 | 0.008499 | 0.158522 | 839 | 30 | 114 | 27.966667 | 0.84136 | 0.1764 | 0 | 0.266667 | 0 | 0 | 0.074453 | 0.032117 | 0 | 0 | 0 | 0 | 0 | 1 | 0.333333 | false | 0 | 0.133333 | 0 | 0.466667 | 0.333333 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9441397660eeb6dafedb77f0318a2a6abc7c766f | 308 | py | Python | setup.py | kasparmartens/BasisVAE | 6edf9145768e8e811d57a05b4282681453c7197e | [
"MIT"
] | 31 | 2020-03-10T19:40:42.000Z | 2021-11-30T19:15:41.000Z | setup.py | kasparmartens/BasisVAE | 6edf9145768e8e811d57a05b4282681453c7197e | [
"MIT"
] | null | null | null | setup.py | kasparmartens/BasisVAE | 6edf9145768e8e811d57a05b4282681453c7197e | [
"MIT"
] | 6 | 2020-03-03T20:20:23.000Z | 2021-12-05T08:51:34.000Z | from setuptools import setup
setup(name='BasisVAE',
version='0.1',
description='Implementation of BasisVAE',
author='Kaspar Märtens',
author_email='kaspar.martens@spc.ox.ac.uk',
url='https://github.com/kasparmartens/BasisVAE',
license='MIT',
packages=['BasisVAE'])
| 28 | 54 | 0.659091 | 35 | 308 | 5.771429 | 0.828571 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.008 | 0.188312 | 308 | 10 | 55 | 30.8 | 0.8 | 0 | 0 | 0 | 0 | 0 | 0.422078 | 0.087662 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.111111 | 0 | 0.111111 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9446b42c1d1158060ccbf4acd325cfa2c00d7aba | 2,576 | py | Python | src/nagiosplugin/tests/test_runtime.py | Puneeth-n/nagiosplugin | f0a77f8e1aa64516fcbeceef7b630e0a1e33ea2f | [
"ZPL-2.1"
] | null | null | null | src/nagiosplugin/tests/test_runtime.py | Puneeth-n/nagiosplugin | f0a77f8e1aa64516fcbeceef7b630e0a1e33ea2f | [
"ZPL-2.1"
] | null | null | null | src/nagiosplugin/tests/test_runtime.py | Puneeth-n/nagiosplugin | f0a77f8e1aa64516fcbeceef7b630e0a1e33ea2f | [
"ZPL-2.1"
] | null | null | null | from nagiosplugin.runtime import Runtime, guarded
import logging
import nagiosplugin
import pytest
@pytest.fixture
def fake_check():
class Check(object):
summary_str = 'summary'
verbose_str = 'long output'
name = 'check'
state = nagiosplugin.Ok
exitcode = 0
perfdat... | 26.833333 | 79 | 0.71118 | 312 | 2,576 | 5.570513 | 0.298077 | 0.172612 | 0.040276 | 0.066168 | 0.211162 | 0.150748 | 0.113924 | 0.041427 | 0 | 0 | 0 | 0.007744 | 0.197981 | 2,576 | 95 | 80 | 27.115789 | 0.833495 | 0 | 0 | 0.029851 | 0 | 0 | 0.07337 | 0 | 0 | 0 | 0 | 0 | 0.134328 | 1 | 0.223881 | false | 0.014925 | 0.059701 | 0 | 0.447761 | 0.014925 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
944729b8bd518a9b2fbda8ce1139db3f9ba10578 | 744 | py | Python | visualqc/tests/test_freesurfer_new_api.py | raamana/corticalqa | 8bca13b2c624e7a230d0b0a5a6539357af641163 | [
"Apache-2.0"
] | 54 | 2018-02-05T14:50:57.000Z | 2022-02-04T10:24:35.000Z | visualqc/tests/test_freesurfer_new_api.py | shannyfoo/visualqc | 606d2b8770e619f8d990faeae24032bf4b152f29 | [
"Apache-2.0"
] | 45 | 2018-02-09T02:46:32.000Z | 2022-03-30T22:36:59.000Z | visualqc/tests/test_freesurfer_new_api.py | shannyfoo/visualqc | 606d2b8770e619f8d990faeae24032bf4b152f29 | [
"Apache-2.0"
] | 10 | 2018-02-09T19:46:27.000Z | 2022-02-17T09:44:36.000Z |
import shlex
import sys
from os import makedirs
from os.path import dirname, join as pjoin, realpath
from visualqc.freesurfer import cli_run
test_dir = dirname(realpath(__file__))
fs_dir = realpath(pjoin(test_dir, '..', '..', 'example_datasets'))
id_list = pjoin(fs_dir, 'id_list')
# fs_dir = '/data1/strother_lab/p... | 29.76 | 93 | 0.721774 | 110 | 744 | 4.572727 | 0.490909 | 0.049702 | 0.053678 | 0.043738 | 0.151093 | 0.151093 | 0 | 0 | 0 | 0 | 0 | 0.00936 | 0.138441 | 744 | 24 | 94 | 31 | 0.775351 | 0.262097 | 0 | 0 | 0 | 0 | 0.175601 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.357143 | 0 | 0.357143 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
944938c7f223259b5c38f448a37433459e22f858 | 212 | py | Python | src/main.py | BobcatSMS/Bobcat | 044c390de949966810f2c74167b4d79b8431a886 | [
"WTFPL"
] | null | null | null | src/main.py | BobcatSMS/Bobcat | 044c390de949966810f2c74167b4d79b8431a886 | [
"WTFPL"
] | null | null | null | src/main.py | BobcatSMS/Bobcat | 044c390de949966810f2c74167b4d79b8431a886 | [
"WTFPL"
] | 1 | 2016-04-19T13:34:45.000Z | 2016-04-19T13:34:45.000Z | import bobcat as b
import sys
if __name__ == '__main__':
message = b.BobMessage(sys.argv[1])
if not message.is_valid():
raise Exception("This Message isn't a Valid BobMessage : " + message)
message.send()
| 21.2 | 71 | 0.712264 | 32 | 212 | 4.4375 | 0.6875 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.00565 | 0.165094 | 212 | 9 | 72 | 23.555556 | 0.79661 | 0 | 0 | 0 | 0 | 0 | 0.226415 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.285714 | 0 | 0.285714 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
94507d09a35b4c52163d6012af2491312182ac6d | 969 | py | Python | zamna/playlists/models.py | nistalhelmuth/zamna_back_end | 30a4ea6c8ec321b7e245c051e43335918858fa78 | [
"MIT"
] | null | null | null | zamna/playlists/models.py | nistalhelmuth/zamna_back_end | 30a4ea6c8ec321b7e245c051e43335918858fa78 | [
"MIT"
] | null | null | null | zamna/playlists/models.py | nistalhelmuth/zamna_back_end | 30a4ea6c8ec321b7e245c051e43335918858fa78 | [
"MIT"
] | null | null | null | from django.db import models
from books.models import Book
from django.contrib.auth.models import User
# Playlist
class Playlist(models.Model):
#name = models.CharField(max_length=100)
uri = models.CharField(max_length=150)
user_id = models.ForeignKey(User, on_delete=models.CASCADE)
#description = mod... | 32.3 | 95 | 0.742002 | 125 | 969 | 5.64 | 0.352 | 0.056738 | 0.099291 | 0.119149 | 0.212766 | 0.116312 | 0.116312 | 0 | 0 | 0 | 0 | 0.012077 | 0.145511 | 969 | 29 | 96 | 33.413793 | 0.839372 | 0.162023 | 0 | 0.117647 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.176471 | 0 | 1 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
9454c667b179ff5ae8349e05f2e79564bbfac672 | 617 | py | Python | tests/secrets_bits.py | Thiagojm/InfoVision | 9a66d4469a2524bf3f5de22720c891881d6651ab | [
"MIT"
] | null | null | null | tests/secrets_bits.py | Thiagojm/InfoVision | 9a66d4469a2524bf3f5de22720c891881d6651ab | [
"MIT"
] | null | null | null | tests/secrets_bits.py | Thiagojm/InfoVision | 9a66d4469a2524bf3f5de22720c891881d6651ab | [
"MIT"
] | null | null | null | import secrets
import time
bit_size = 8192
t0 = time.time()
bits = secrets.randbits(bit_size)
print(bits)
bin_ascii = bin(bits)[2:].zfill(bit_size)
print("Binary String: ", bin_ascii)
print("Binary lenght: ", len(bin_ascii))
num_ones_array = bin_ascii.count('1')
print("Number of 'ones': ", num_ones_array)
print(time... | 19.903226 | 46 | 0.643436 | 96 | 617 | 3.958333 | 0.333333 | 0.065789 | 0.052632 | 0.105263 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.022556 | 0.137763 | 617 | 30 | 47 | 20.566667 | 0.691729 | 0 | 0 | 0.190476 | 0 | 0 | 0.167235 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.095238 | 0 | 0.095238 | 0.428571 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 |
9455aac0d6aa7b36ad69cc4e8ec80a021281d7a2 | 928 | py | Python | angr/exploration_techniques/taint_engine/defines.py | badnack/angr | 81526da198dc67f5d6eb520c1fa5b3ad9fe12aca | [
"BSD-2-Clause"
] | null | null | null | angr/exploration_techniques/taint_engine/defines.py | badnack/angr | 81526da198dc67f5d6eb520c1fa5b3ad9fe12aca | [
"BSD-2-Clause"
] | null | null | null | angr/exploration_techniques/taint_engine/defines.py | badnack/angr | 81526da198dc67f5d6eb520c1fa5b3ad9fe12aca | [
"BSD-2-Clause"
] | null | null | null | #
# Defined constants
#
import archinfo
# Taint/Untaint
TAINT_BUF = "taint_buf"
PAGE_SIZE = 4096 # 1 page
BOGUS_RETURN = 0x41414141
GLOB_TAINT_DEP_KEY = 'taint_deps'
UNTAINT_DATA = 'untainted_data'
UNTAINTED_VARS = 'untainted_vars'
# Taint dependency
SEEN_MASTERS = 'seen_masters'
CURRENT_IFL = 'current_ifl'
TAINT_A... | 21.581395 | 73 | 0.772629 | 130 | 928 | 5.169231 | 0.615385 | 0.02381 | 0.071429 | 0.083333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.018634 | 0.132543 | 928 | 42 | 74 | 22.095238 | 0.816149 | 0.141164 | 0 | 0 | 0 | 0 | 0.367684 | 0.148855 | 0 | 0 | 0.012723 | 0.02381 | 0 | 1 | 0.08 | false | 0 | 0.04 | 0.08 | 0.2 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
945646f70c67be515da75943357776a44e8dd2ea | 3,725 | py | Python | engine/animation.py | yoursred/twitchgame | b77314f43cc66e05a92512ab65e40e7cd5e841ff | [
"Unlicense"
] | null | null | null | engine/animation.py | yoursred/twitchgame | b77314f43cc66e05a92512ab65e40e7cd5e841ff | [
"Unlicense"
] | null | null | null | engine/animation.py | yoursred/twitchgame | b77314f43cc66e05a92512ab65e40e7cd5e841ff | [
"Unlicense"
] | null | null | null | """
Animation
"""
from abc import ABC, abstractmethod
from engine.misc import black, curve, scaletup
class PlayerAnimation(ABC):
def __init__(self, length):
length = round(length)
self.length = length
self.frame = length
def tick(self):
if self.frame:
self.frame -... | 28.435115 | 105 | 0.545503 | 498 | 3,725 | 3.985944 | 0.158635 | 0.081612 | 0.065491 | 0.064484 | 0.713854 | 0.647859 | 0.627204 | 0.627204 | 0.570781 | 0.570781 | 0 | 0.034536 | 0.308188 | 3,725 | 130 | 106 | 28.653846 | 0.735739 | 0.020403 | 0 | 0.608696 | 0 | 0 | 0.003298 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.217391 | false | 0 | 0.021739 | 0.097826 | 0.456522 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
94678d76d36ae6d4eb7f37ace4278b3841bd418a | 539 | py | Python | products/admin.py | Code-Institute-Submissions/Dermomurphy-MS4-DJ-ecomSite_MayResub | b1925d1b75e777be31b658698025f6aa963d97b0 | [
"MIT"
] | null | null | null | products/admin.py | Code-Institute-Submissions/Dermomurphy-MS4-DJ-ecomSite_MayResub | b1925d1b75e777be31b658698025f6aa963d97b0 | [
"MIT"
] | null | null | null | products/admin.py | Code-Institute-Submissions/Dermomurphy-MS4-DJ-ecomSite_MayResub | b1925d1b75e777be31b658698025f6aa963d97b0 | [
"MIT"
] | 1 | 2021-02-28T12:00:41.000Z | 2021-02-28T12:00:41.000Z | from django.contrib import admin
from .models import Product, Brewery
# Register your models here.
class ProductAdmin(admin.ModelAdmin):
list_display = (
'sku',
'name',
'ibu',
'abv',
'brewery',
'price',
'rating',
'image',
)
ordering = ('na... | 19.962963 | 42 | 0.57885 | 50 | 539 | 6.18 | 0.56 | 0.110032 | 0.122977 | 0.168285 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.294991 | 539 | 27 | 43 | 19.962963 | 0.813158 | 0.048237 | 0 | 0.181818 | 0 | 0 | 0.125 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.090909 | 0 | 0.318182 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9467b22460f9315892acb27b005d1570be941c18 | 1,466 | py | Python | thelma/repositories/rdb/schema/views/moleculesuppliermoleculedesign.py | fogathmann/TheLMA | ac330a0005da4fea2f1387da9ff9938611ad1481 | [
"MIT"
] | 1 | 2020-07-12T22:47:58.000Z | 2020-07-12T22:47:58.000Z | thelma/repositories/rdb/schema/views/moleculesuppliermoleculedesign.py | papagr/TheLMA | d2dc7a478ee5d24ccf3cc680888e712d482321d0 | [
"MIT"
] | null | null | null | thelma/repositories/rdb/schema/views/moleculesuppliermoleculedesign.py | papagr/TheLMA | d2dc7a478ee5d24ccf3cc680888e712d482321d0 | [
"MIT"
] | 1 | 2020-07-12T22:40:36.000Z | 2020-07-12T22:40:36.000Z | """
This file is part of the TheLMA (THe Laboratory Management Application) project.
See LICENSE.txt for licensing, CONTRIBUTORS.txt for contributor information.
Molecule supplier molecule design view.
"""
from sqlalchemy.schema import ForeignKey
from sqlalchemy.sql import and_
from sqlalchemy.sql import select
from ... | 32.577778 | 80 | 0.669168 | 181 | 1,466 | 5.066298 | 0.337017 | 0.167939 | 0.215921 | 0.109051 | 0.230098 | 0.061069 | 0 | 0 | 0 | 0 | 0 | 0 | 0.253752 | 1,466 | 44 | 81 | 33.318182 | 0.838208 | 0.163029 | 0 | 0 | 0 | 0 | 0.056478 | 0.031561 | 0 | 0 | 0 | 0 | 0 | 1 | 0.035714 | false | 0 | 0.142857 | 0 | 0.214286 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9467fcfbb93f8d417f9fe37920d9a071b0899bd7 | 2,054 | py | Python | test/test_parser_struct.py | rxtender/rxtender | ba4cec4f01597d0ee9e0828a58adcbfd4b35eef4 | [
"MIT"
] | null | null | null | test/test_parser_struct.py | rxtender/rxtender | ba4cec4f01597d0ee9e0828a58adcbfd4b35eef4 | [
"MIT"
] | 8 | 2017-09-01T20:05:56.000Z | 2017-10-19T20:43:19.000Z | test/test_parser_struct.py | rxtender/rxtender | ba4cec4f01597d0ee9e0828a58adcbfd4b35eef4 | [
"MIT"
] | null | null | null | from unittest import TestCase
from rxtender.rxtender import parse_idl
class ParserStructTestCase(TestCase):
def test_struct(self):
rxt = '''struct Foo {
field1: u32;
field2: i32;
}'''
expected_ast = [{
'stream': None,
'struct': {
... | 27.026316 | 43 | 0.359299 | 136 | 2,054 | 5.330882 | 0.301471 | 0.044138 | 0.053793 | 0.066207 | 0.565517 | 0.565517 | 0.525517 | 0.482759 | 0.388966 | 0.388966 | 0 | 0.046231 | 0.515579 | 2,054 | 75 | 44 | 27.386667 | 0.682412 | 0 | 0 | 0.642857 | 0 | 0 | 0.305745 | 0 | 0 | 0 | 0 | 0 | 0.042857 | 1 | 0.042857 | false | 0 | 0.028571 | 0 | 0.085714 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9468510b371ed09768e31874efe38c8799873ee2 | 1,206 | py | Python | Ensemble.py | rboyes/KerasScripts | 97c430b789fd09aa2036e0da82b4aa2e014ab3d7 | [
"Apache-2.0"
] | null | null | null | Ensemble.py | rboyes/KerasScripts | 97c430b789fd09aa2036e0da82b4aa2e014ab3d7 | [
"Apache-2.0"
] | null | null | null | Ensemble.py | rboyes/KerasScripts | 97c430b789fd09aa2036e0da82b4aa2e014ab3d7 | [
"Apache-2.0"
] | null | null | null | import os
import datetime
import sys
import time
import string
import random
import pandas as pd
import numpy as np
from sklearn.metrics import log_loss
def ensemblePrediction(predictionFiles, outputName):
namesDataFrame = pd.read_csv(predictionFiles[0], header=None)
numberOfImages = len(namesDataFrame)... | 30.923077 | 76 | 0.69403 | 141 | 1,206 | 5.907801 | 0.510638 | 0.042017 | 0.036014 | 0.026411 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.011364 | 0.197347 | 1,206 | 38 | 77 | 31.736842 | 0.848141 | 0 | 0 | 0 | 0 | 0 | 0.041494 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.3 | null | null | 0.033333 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
946b090da0a2b7207b5f6340cebea0132140880b | 1,353 | py | Python | tests/test_util_path.py | JFlynnXYZ/pymel | 2aa254c7982c78aac3e30e8d1b6a85f2465f898e | [
"BSD-3-Clause"
] | 287 | 2015-01-03T21:18:59.000Z | 2022-03-16T07:55:33.000Z | tests/test_util_path.py | JFlynnXYZ/pymel | 2aa254c7982c78aac3e30e8d1b6a85f2465f898e | [
"BSD-3-Clause"
] | 412 | 2015-06-19T15:13:33.000Z | 2022-02-25T08:12:25.000Z | tests/test_util_path.py | JFlynnXYZ/pymel | 2aa254c7982c78aac3e30e8d1b6a85f2465f898e | [
"BSD-3-Clause"
] | 106 | 2015-01-03T06:46:44.000Z | 2022-03-30T15:43:01.000Z | from __future__ import print_function
from __future__ import division
from __future__ import absolute_import
import os
import unittest
import pymel.util.path
from pymel.util.path import path
class TestPath(unittest.TestCase):
def test_misc(self):
thisFile = path(__file__)
self.assert... | 32.214286 | 73 | 0.637103 | 138 | 1,353 | 6.057971 | 0.297101 | 0.047847 | 0.105263 | 0.038278 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.245381 | 1,353 | 41 | 74 | 33 | 0.818805 | 0 | 0 | 0 | 0 | 0 | 0.070283 | 0.019862 | 0 | 0 | 0 | 0 | 0.548387 | 1 | 0.032258 | false | 0 | 0.225806 | 0 | 0.290323 | 0.032258 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
94761ac7032bb6c91379637f8f415ce41c159cc5 | 445 | py | Python | tests/test_is_valid_date.py | rogervila/pymongo_is_valid_date | 58f4142e217363fa31c46af38fa53c18f33a4b65 | [
"MIT"
] | 1 | 2021-01-21T09:35:44.000Z | 2021-01-21T09:35:44.000Z | tests/test_is_valid_date.py | rogervila/pymongo_is_valid_date | 58f4142e217363fa31c46af38fa53c18f33a4b65 | [
"MIT"
] | 5 | 2021-11-02T23:19:21.000Z | 2022-03-01T23:22:48.000Z | tests/test_is_valid_date.py | rogervila/python_is_valid_date | 58f4142e217363fa31c46af38fa53c18f33a4b65 | [
"MIT"
] | null | null | null | import unittest
from is_valid_date import check
from datetime import date, datetime
class test_is_valid_date(unittest.TestCase):
def test_string_dates(self):
self.assertTrue(check('1714-09-11'))
self.assertFalse(check('not a date'))
def test_date_and_datetime_instances(self):
self.ass... | 24.722222 | 47 | 0.71236 | 59 | 445 | 5.050847 | 0.491525 | 0.14094 | 0.191275 | 0.154362 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.021739 | 0.173034 | 445 | 17 | 48 | 26.176471 | 0.788043 | 0 | 0 | 0 | 0 | 0 | 0.062921 | 0 | 0 | 0 | 0 | 0 | 0.333333 | 1 | 0.166667 | false | 0 | 0.25 | 0 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
947824661fb74507cc549461c5e5ae5c766ced32 | 175 | py | Python | python-core/src/reading-multipe-inputs.py | NSnietol/python-core-and-advanced | 85d03894d5430bcdd62b0ae35371356f26d9374a | [
"MIT"
] | 2 | 2019-04-13T14:10:38.000Z | 2021-01-17T00:57:51.000Z | python-core/src/reading-multipe-inputs.py | NSnietol/python-core-and-advanced | 85d03894d5430bcdd62b0ae35371356f26d9374a | [
"MIT"
] | null | null | null | python-core/src/reading-multipe-inputs.py | NSnietol/python-core-and-advanced | 85d03894d5430bcdd62b0ae35371356f26d9374a | [
"MIT"
] | 1 | 2020-02-20T15:44:36.000Z | 2020-02-20T15:44:36.000Z | '''
Created on Nov 3, 2018
@author: nilson.nieto
'''
list_numeros =input("Ingrese varios numeros separados por espacio : ").split(" , ")
for i in list_numeros:
print(i) | 17.5 | 83 | 0.68 | 25 | 175 | 4.68 | 0.84 | 0.188034 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.034722 | 0.177143 | 175 | 10 | 84 | 17.5 | 0.777778 | 0.257143 | 0 | 0 | 0 | 0 | 0.406504 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.333333 | 1 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9480d64157cf8e642a423ec34a2f193ad8419b19 | 1,644 | py | Python | developer_manual/design/icons-gen.py | mnheia/documentation | 98baee3f2f96e116fd1ca2ef8276077dd91bc099 | [
"CC-BY-3.0"
] | 1 | 2020-06-13T00:53:31.000Z | 2020-06-13T00:53:31.000Z | developer_manual/design/icons-gen.py | mnheia/documentation | 98baee3f2f96e116fd1ca2ef8276077dd91bc099 | [
"CC-BY-3.0"
] | null | null | null | developer_manual/design/icons-gen.py | mnheia/documentation | 98baee3f2f96e116fd1ca2ef8276077dd91bc099 | [
"CC-BY-3.0"
] | null | null | null | #! /bin/env python
# Generate the icon part of the design documentation
# coding=utf8
# the above tag defines encoding for this document and is for Python 2.x compatibility
import re
import os
iconregex = re.compile("(\.icon-[a-z-]*)")
pathregex = r"url\(\"([a-z0-9-./]+)"
os.system('rm -R ./img/')
os.system('rm icon... | 34.978723 | 119 | 0.657543 | 253 | 1,644 | 4.272727 | 0.395257 | 0.111008 | 0.064755 | 0.077706 | 0.182239 | 0.173913 | 0.123959 | 0.123959 | 0.123959 | 0.123959 | 0 | 0.009756 | 0.127129 | 1,644 | 47 | 120 | 34.978723 | 0.743554 | 0.100365 | 0 | 0 | 1 | 0.028571 | 0.435637 | 0.110434 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.085714 | 0 | 0.085714 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
9485286d1d993a727362662eefc057e2689ce60e | 958 | py | Python | serverapp/services.py | khavitidala/tubes-sisterpar-gRPC | d4afc880216deab80a1cf61839dd8aa8d4197947 | [
"MIT"
] | null | null | null | serverapp/services.py | khavitidala/tubes-sisterpar-gRPC | d4afc880216deab80a1cf61839dd8aa8d4197947 | [
"MIT"
] | null | null | null | serverapp/services.py | khavitidala/tubes-sisterpar-gRPC | d4afc880216deab80a1cf61839dd8aa8d4197947 | [
"MIT"
] | null | null | null | import grpc
import random
from datetime import datetime
from django_grpc_framework.services import Service
from serverapp.models import Penduduk
from serverapp.serializers import PendudukProtoSerializer
class PendudukService(Service):
def Create(self, request, context):
random.seed()
nama = ["Ryan"... | 34.214286 | 93 | 0.669102 | 114 | 958 | 5.552632 | 0.596491 | 0.037915 | 0.056872 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.010512 | 0.205637 | 958 | 27 | 94 | 35.481481 | 0.821288 | 0.151357 | 0 | 0 | 0 | 0 | 0.026055 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.055556 | false | 0 | 0.333333 | 0 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
9486c1c42342580b1b3f8914db9ec02560b976ba | 2,398 | py | Python | tests/segmentation/test_segmentation_two_stage.py | mknz/dsr-road-roughness-prediction | 5f56b6ba5da70a09f2c967b7f32c740072e20ed1 | [
"MIT"
] | 7 | 2019-04-04T06:40:29.000Z | 2020-11-12T10:53:30.000Z | tests/segmentation/test_segmentation_two_stage.py | mknz/dsr-road-roughness-prediction | 5f56b6ba5da70a09f2c967b7f32c740072e20ed1 | [
"MIT"
] | 1 | 2021-09-28T07:11:05.000Z | 2021-09-28T07:11:05.000Z | tests/segmentation/test_segmentation_two_stage.py | mknz/dsr-road-roughness-prediction | 5f56b6ba5da70a09f2c967b7f32c740072e20ed1 | [
"MIT"
] | null | null | null | '''Test two-stage segmentation'''
from pathlib import Path
import shutil
import tempfile
import torch
import numpy as np
from PIL import Image
from albumentations.augmentations.functional import center_crop
from torchvision.transforms.functional import to_tensor
from road_roughness_prediction.segmentation.datasets im... | 37.46875 | 89 | 0.745621 | 302 | 2,398 | 5.612583 | 0.374172 | 0.053097 | 0.050147 | 0.079646 | 0.184661 | 0.083776 | 0.083776 | 0.033038 | 0 | 0 | 0 | 0.006552 | 0.172644 | 2,398 | 63 | 90 | 38.063492 | 0.847782 | 0.03628 | 0 | 0 | 0 | 0 | 0.055122 | 0.032118 | 0 | 0 | 0 | 0 | 0.021739 | 1 | 0.086957 | false | 0 | 0.282609 | 0 | 0.608696 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
9488b2e7f1c5d5ed6465be9fd38def05c15071cc | 5,975 | py | Python | eval.py | ascust/SEC-MXNet | 94f46af24f8b414ccf64be8584f4632df136f4af | [
"MIT"
] | 24 | 2018-03-04T07:11:22.000Z | 2021-07-21T14:08:50.000Z | eval.py | ascust/SEC-MXNet | 94f46af24f8b414ccf64be8584f4632df136f4af | [
"MIT"
] | 17 | 2018-03-01T15:35:00.000Z | 2020-07-06T03:47:46.000Z | eval.py | ascust/SEC-MXNet | 94f46af24f8b414ccf64be8584f4632df136f4af | [
"MIT"
] | 3 | 2018-03-20T05:39:09.000Z | 2021-07-21T14:08:51.000Z | import argparse
import logging
import mxnet as mx
import os
from cores.data.InferenceDataProducer import InferenceDataProducer
from cores.utils import metrics
import numpy as np
from PIL import Image
from cores.config import conf
from cores.data.data_utils import get_voc_classnames as get_classnames
from cores.data.dat... | 37.111801 | 127 | 0.638661 | 834 | 5,975 | 4.352518 | 0.238609 | 0.016529 | 0.027548 | 0.023141 | 0.229477 | 0.207989 | 0.14573 | 0.113774 | 0.07741 | 0.067769 | 0 | 0.011489 | 0.22795 | 5,975 | 160 | 128 | 37.34375 | 0.775417 | 0 | 0 | 0.08 | 0 | 0 | 0.088792 | 0.008879 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.112 | null | null | 0.008 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
948d3ce570d2e420b1876ee3ee3918d495f85a2e | 130,927 | py | Python | xen/xen-4.2.2/tools/python/xen/xm/main.py | zhiming-shen/Xen-Blanket-NG | 47e59d9bb92e8fdc60942df526790ddb983a5496 | [
"Apache-2.0"
] | 1 | 2018-02-02T00:15:26.000Z | 2018-02-02T00:15:26.000Z | xen/xen-4.2.2/tools/python/xen/xm/main.py | zhiming-shen/Xen-Blanket-NG | 47e59d9bb92e8fdc60942df526790ddb983a5496 | [
"Apache-2.0"
] | null | null | null | xen/xen-4.2.2/tools/python/xen/xm/main.py | zhiming-shen/Xen-Blanket-NG | 47e59d9bb92e8fdc60942df526790ddb983a5496 | [
"Apache-2.0"
] | 1 | 2019-05-27T09:47:18.000Z | 2019-05-27T09:47:18.000Z | # (C) Copyright IBM Corp. 2005
# Copyright (C) 2004 Mike Wray
# Copyright (c) 2005-2006 XenSource Ltd.
#
# Authors:
# Sean Dague <sean at dague dot net>
# Mike Wray <mike dot wray at hp dot com>
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of version 2.1 of the G... | 32.184612 | 124 | 0.524048 | 15,814 | 130,927 | 4.185279 | 0.07525 | 0.026471 | 0.013598 | 0.024265 | 0.388859 | 0.327093 | 0.280225 | 0.237951 | 0.207944 | 0.1762 | 0 | 0.013759 | 0.334958 | 130,927 | 4,067 | 125 | 32.192525 | 0.746371 | 0.030208 | 0 | 0.342034 | 0 | 0.0033 | 0.184552 | 0.007027 | 0 | 0 | 0 | 0 | 0.0006 | 0 | null | null | 0.010801 | 0.015302 | null | null | 0.039604 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
846ca88166fdacd57123d4d9ceb1bcc3c578f3a2 | 8,606 | py | Python | ENCODE_collection.py | ENCODE-DCC/WranglerScripts | 8467e295704f418901986696dbb8836d21bfe2fe | [
"MIT"
] | 3 | 2015-07-07T16:02:42.000Z | 2019-01-30T04:35:42.000Z | ENCODE_collection.py | ENCODE-DCC/WranglerScripts | 8467e295704f418901986696dbb8836d21bfe2fe | [
"MIT"
] | 2 | 2018-02-23T19:33:15.000Z | 2018-05-18T20:42:05.000Z | ENCODE_collection.py | ENCODE-DCC/WranglerScripts | 8467e295704f418901986696dbb8836d21bfe2fe | [
"MIT"
] | 4 | 2015-07-29T13:31:39.000Z | 2020-10-01T11:49:25.000Z | #!/usr/bin/env python
# -*- coding: latin-1 -*-
'''GET an ENCODE collection and output a tsv of all objects and their properties suitable for spreadsheet import'''
'''use requests to handle the HTTP connection'''
import requests
'''use json to convert between Python dictionaries and JSON objects'''
import json
'''use ... | 32.353383 | 131 | 0.703695 | 1,173 | 8,606 | 5.02046 | 0.231884 | 0.021396 | 0.028867 | 0.033282 | 0.13313 | 0.081848 | 0.049414 | 0.030056 | 0 | 0 | 0 | 0.002205 | 0.156984 | 8,606 | 265 | 132 | 32.475472 | 0.809511 | 0.068324 | 0 | 0.165919 | 0 | 0.004484 | 0.218352 | 0.019193 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.017937 | 0.026906 | null | null | 0.053812 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
846d18f095e23fe9a1312930bd173045bf334c3a | 483 | py | Python | app.py | aws-samples/aws-analytics-immersion-day | 9b138a41b3cf112d810dfc81281bb822a40f7bf2 | [
"MIT-0"
] | 1 | 2022-03-29T07:19:42.000Z | 2022-03-29T07:19:42.000Z | app.py | aws-samples/aws-analytics-immersion-day | 9b138a41b3cf112d810dfc81281bb822a40f7bf2 | [
"MIT-0"
] | 1 | 2022-03-21T03:40:37.000Z | 2022-03-21T12:50:07.000Z | app.py | aws-samples/aws-analytics-immersion-day | 9b138a41b3cf112d810dfc81281bb822a40f7bf2 | [
"MIT-0"
] | 1 | 2022-01-26T19:24:50.000Z | 2022-01-26T19:24:50.000Z | #!/usr/bin/env python3
# -*- encoding: utf-8 -*-
# vim: tabstop=2 shiftwidth=2 softtabstop=2 expandtab
import os
import aws_cdk as cdk
from data_analytics_system.data_analytics_system_stack import DataAnalyticsSystemStack
ACCOUNT = os.getenv('CDK_DEFAULT_ACCOUNT', '')
REGION = os.getenv('CDK_DEFAULT_REGION', 'us-ea... | 25.421053 | 86 | 0.770186 | 68 | 483 | 5.294118 | 0.5 | 0.108333 | 0.158333 | 0.1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.013793 | 0.099379 | 483 | 18 | 87 | 26.833333 | 0.813793 | 0.200828 | 0 | 0 | 0 | 0 | 0.174935 | 0.05483 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.333333 | 0 | 0.333333 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
84719d01d8f668927b2f1d97199fa2b8fcc60738 | 509 | py | Python | setup/install_dask.py | garstka/idact-test-environment | a9b430636f5198de7f3c5de517ab93b9b57c6ca6 | [
"MIT"
] | null | null | null | setup/install_dask.py | garstka/idact-test-environment | a9b430636f5198de7f3c5de517ab93b9b57c6ca6 | [
"MIT"
] | null | null | null | setup/install_dask.py | garstka/idact-test-environment | a9b430636f5198de7f3c5de517ab93b9b57c6ca6 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
"""Installs Dask, Dask Distributed and bokeh."""
import os
import subprocess
def get_command_install_dask():
python = 'python{CONTAINER_PYTHON_VERSION}'.format(
CONTAINER_PYTHON_VERSION=os.environ['CONTAINER_PYTHON_VERSION'])
return [python, '-m', 'pip', 'install', 'dask', 'di... | 23.136364 | 75 | 0.705305 | 61 | 509 | 5.540984 | 0.508197 | 0.133136 | 0.195266 | 0.130178 | 0.159763 | 0 | 0 | 0 | 0 | 0 | 0 | 0.002304 | 0.147348 | 509 | 21 | 76 | 24.238095 | 0.776498 | 0.125737 | 0 | 0 | 0 | 0 | 0.323462 | 0.127563 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0 | 0.181818 | 0 | 0.454545 | 0.090909 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
8473925a81825a9668f248dad551789b266f5c24 | 4,283 | py | Python | webapp/WEB-INF/js/mjt/tools/mkdemo.py | gagoel/acre | f5774af2dfbd2fc337d614846748ac6620c421c0 | [
"Apache-2.0"
] | null | null | null | webapp/WEB-INF/js/mjt/tools/mkdemo.py | gagoel/acre | f5774af2dfbd2fc337d614846748ac6620c421c0 | [
"Apache-2.0"
] | null | null | null | webapp/WEB-INF/js/mjt/tools/mkdemo.py | gagoel/acre | f5774af2dfbd2fc337d614846748ac6620c421c0 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
#
# mkdemo.py takes the html output from rst2html.py
# and turns each literal text block into a live
# mjt demo, with source on the left and output
# on the right.
#
#
import os, sys, re
import optparse
from BeautifulSoup import BeautifulSoup, Tag
from htmlentitydefs import name2codepoint
... | 27.280255 | 82 | 0.526267 | 504 | 4,283 | 4.375 | 0.378968 | 0.027211 | 0.017687 | 0.017234 | 0.064399 | 0.026304 | 0 | 0 | 0 | 0 | 0 | 0.009823 | 0.263133 | 4,283 | 156 | 83 | 27.455128 | 0.688847 | 0.114172 | 0 | 0.022472 | 0 | 0 | 0.149767 | 0.009615 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.05618 | null | null | 0.033708 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
8479575292e40567ef55116a8bebd46b77749f44 | 944 | py | Python | 14. SOLID - Exercise/01_workers.py | elenaborisova/Python-OOP | 584882c08f84045b12322917f0716c7c7bd9befc | [
"MIT"
] | 1 | 2021-03-27T16:56:30.000Z | 2021-03-27T16:56:30.000Z | 14. SOLID - Exercise/01_workers.py | elenaborisova/Python-OOP | 584882c08f84045b12322917f0716c7c7bd9befc | [
"MIT"
] | null | null | null | 14. SOLID - Exercise/01_workers.py | elenaborisova/Python-OOP | 584882c08f84045b12322917f0716c7c7bd9befc | [
"MIT"
] | 1 | 2021-03-15T14:50:39.000Z | 2021-03-15T14:50:39.000Z | class Manager:
def __init__(self):
self.worker = None
def set_worker(self, worker):
assert "Worker" in [el.__name__ for el in worker.__class__.__mro__], "'worker' must be of type Worker"
self.worker = worker
def manage(self):
if self.worker is not None:
self.wo... | 19.265306 | 110 | 0.64089 | 122 | 944 | 4.770492 | 0.368852 | 0.085911 | 0.06701 | 0.087629 | 0.118557 | 0.118557 | 0 | 0 | 0 | 0 | 0 | 0 | 0.238347 | 944 | 48 | 111 | 19.666667 | 0.809458 | 0 | 0 | 0.151515 | 0 | 0 | 0.15678 | 0 | 0 | 0 | 0 | 0 | 0.060606 | 1 | 0.212121 | false | 0 | 0 | 0.030303 | 0.393939 | 0.121212 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
847c05e425376ceb20782ba7b5ce66f9d2606124 | 9,758 | py | Python | src/oci/data_integration/models/foreign_key.py | LaudateCorpus1/oci-python-sdk | b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015 | [
"Apache-2.0",
"BSD-3-Clause"
] | null | null | null | src/oci/data_integration/models/foreign_key.py | LaudateCorpus1/oci-python-sdk | b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015 | [
"Apache-2.0",
"BSD-3-Clause"
] | null | null | null | src/oci/data_integration/models/foreign_key.py | LaudateCorpus1/oci-python-sdk | b0d3ce629d5113df4d8b83b7a6502b2c5bfa3015 | [
"Apache-2.0",
"BSD-3-Clause"
] | null | null | null | # coding: utf-8
# Copyright (c) 2016, 2022, Oracle and/or its affiliates. All rights reserved.
# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may c... | 30.304348 | 245 | 0.62933 | 1,181 | 9,758 | 4.99492 | 0.147333 | 0.048822 | 0.124767 | 0.061027 | 0.549754 | 0.427869 | 0.312934 | 0.220715 | 0.16613 | 0.13765 | 0 | 0.004088 | 0.298012 | 9,758 | 321 | 246 | 30.398754 | 0.85708 | 0.520189 | 0 | 0.087379 | 0 | 0 | 0.110329 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.213592 | false | 0 | 0.029126 | 0.019417 | 0.378641 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
848141bcd13373c95789e4ae819ba2610a0e728a | 250 | py | Python | abc/233/D.py | tonko2/AtCoder | 5d617072517881d226d7c8af09cb88684d41af7e | [
"Xnet",
"X11",
"CECILL-B"
] | 2 | 2022-01-22T07:56:58.000Z | 2022-01-24T00:29:37.000Z | abc/233/D.py | tonko2/AtCoder | 5d617072517881d226d7c8af09cb88684d41af7e | [
"Xnet",
"X11",
"CECILL-B"
] | null | null | null | abc/233/D.py | tonko2/AtCoder | 5d617072517881d226d7c8af09cb88684d41af7e | [
"Xnet",
"X11",
"CECILL-B"
] | null | null | null | N, K = map(int, input().split())
A = [0]
total = 0
a = list(map(int, input().split()))
ans = 0
m = {0: 1}
for x in a:
total += x
count = m.get(total - K, 0)
ans += count
m[total] = m.get(total, 0) + 1
A.append(total)
print(ans) | 15.625 | 35 | 0.512 | 47 | 250 | 2.723404 | 0.425532 | 0.09375 | 0.171875 | 0.25 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.043956 | 0.272 | 250 | 16 | 36 | 15.625 | 0.659341 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.076923 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
848442f048ed738e4757f9880eb45749650ecf6d | 1,124 | py | Python | class6/ex4.py | nkbyrne/pyplus | 2fd31eb41c697259f641fd90a371d2cd9ed4a673 | [
"Apache-2.0"
] | null | null | null | class6/ex4.py | nkbyrne/pyplus | 2fd31eb41c697259f641fd90a371d2cd9ed4a673 | [
"Apache-2.0"
] | null | null | null | class6/ex4.py | nkbyrne/pyplus | 2fd31eb41c697259f641fd90a371d2cd9ed4a673 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python3
import yaml
import pyeapi
from getpass import getpass
from jinja2 import FileSystemLoader, StrictUndefined
from jinja2.environment import Environment
from pprint import pprint
env = Environment(undefined=StrictUndefined)
env.loader = FileSystemLoader(".")
template_file = "ex4.j2"
template = env.... | 27.414634 | 57 | 0.698399 | 142 | 1,124 | 5.464789 | 0.408451 | 0.054124 | 0.028351 | 0.046392 | 0.270619 | 0.270619 | 0.270619 | 0.270619 | 0.270619 | 0.270619 | 0 | 0.016967 | 0.161032 | 1,124 | 40 | 58 | 28.1 | 0.805938 | 0.018683 | 0 | 0.30303 | 0 | 0 | 0.072595 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.121212 | 0.181818 | 0 | 0.181818 | 0.212121 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
8497902a6caa723701ee40d225db35a8da987ff4 | 324 | py | Python | array/643_maximum_average_subarray_i.py | shawlu95/Algorithm-Toolbox | b6c7b2228d8e70e0842e0bad607533a2c8322cf0 | [
"MIT"
] | null | null | null | array/643_maximum_average_subarray_i.py | shawlu95/Algorithm-Toolbox | b6c7b2228d8e70e0842e0bad607533a2c8322cf0 | [
"MIT"
] | null | null | null | array/643_maximum_average_subarray_i.py | shawlu95/Algorithm-Toolbox | b6c7b2228d8e70e0842e0bad607533a2c8322cf0 | [
"MIT"
] | 2 | 2020-02-07T20:49:02.000Z | 2020-02-11T06:01:55.000Z | class Solution:
def findMaxAverage(self, nums: List[int], k: int) -> float:
# sliding window, O(N) time, O(1) space
globMax = tempMax = sum(nums[:k])
for i in range(k, len(nums)):
tempMax += (nums[i] - nums[i-k])
globMax = max(tempMax, globMax)
return globMax ... | 36 | 63 | 0.546296 | 44 | 324 | 4.022727 | 0.613636 | 0.056497 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004464 | 0.308642 | 324 | 8 | 64 | 40.5 | 0.785714 | 0.114198 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0 | 0 | 0 | 0.428571 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84aa614bfe83e15e9a32e5f5a254e00523c6e27c | 7,178 | py | Python | lib/solutions/CHK/checkout_solution.py | DPNT-Sourcecode/CHK-kdir01 | 291d2ca18da1f4d34e11fe70ade024b1702226d5 | [
"Apache-2.0"
] | null | null | null | lib/solutions/CHK/checkout_solution.py | DPNT-Sourcecode/CHK-kdir01 | 291d2ca18da1f4d34e11fe70ade024b1702226d5 | [
"Apache-2.0"
] | null | null | null | lib/solutions/CHK/checkout_solution.py | DPNT-Sourcecode/CHK-kdir01 | 291d2ca18da1f4d34e11fe70ade024b1702226d5 | [
"Apache-2.0"
] | null | null | null | from __future__ import annotations
from collections import Counter, defaultdict
from dataclasses import dataclass
import itertools
from typing import Dict, List
@dataclass
class PurchaseOption:
"""
Represents a purchase option for customers in terms of a collection of skus for a given price.
"""
sku... | 37.19171 | 106 | 0.658261 | 954 | 7,178 | 4.797694 | 0.232704 | 0.159712 | 0.079528 | 0.036705 | 0.251475 | 0.236618 | 0.02447 | 0 | 0 | 0 | 0 | 0.025962 | 0.232655 | 7,178 | 192 | 107 | 37.385417 | 0.805011 | 0.161744 | 0 | 0.062992 | 0 | 0 | 0.008259 | 0 | 0 | 0 | 0 | 0.010417 | 0 | 1 | 0.07874 | false | 0 | 0.03937 | 0.007874 | 0.244094 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84ae360ac0780c5a7005959f904b54ae3231dbdb | 6,288 | py | Python | utilities/cleanup_netcdf_files.py | OzFlux/PFP_Classic | a567cc986c2e220d95a377ca129994b018f0248c | [
"BSD-3-Clause"
] | 1 | 2021-01-17T20:53:39.000Z | 2021-01-17T20:53:39.000Z | utilities/cleanup_netcdf_files.py | OzFlux/PFP_Classic | a567cc986c2e220d95a377ca129994b018f0248c | [
"BSD-3-Clause"
] | null | null | null | utilities/cleanup_netcdf_files.py | OzFlux/PFP_Classic | a567cc986c2e220d95a377ca129994b018f0248c | [
"BSD-3-Clause"
] | null | null | null | # standard modules
import copy
import os
import sys
# 3rd party modules
from configobj import ConfigObj
import timezonefinder
# check the scripts folder exists
scripts_path = os.path.join("..", "scripts", "")
if not os.path.exists(scripts_path):
print "cleanup_netcdf_files: the scripts directory is missing"
sys... | 36.988235 | 95 | 0.631838 | 854 | 6,288 | 4.516393 | 0.208431 | 0.098004 | 0.019964 | 0.018667 | 0.222193 | 0.15245 | 0.124449 | 0.060669 | 0.060669 | 0.060669 | 0 | 0.007243 | 0.253499 | 6,288 | 170 | 96 | 36.988235 | 0.814444 | 0.091285 | 0 | 0.159664 | 0 | 0 | 0.17689 | 0.004051 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.067227 | null | null | 0.092437 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84b1bad3474f20ad8f890aa515bd14ae25079712 | 310 | py | Python | app.py | sandeepsn1997/civilapp | 749027e904924575f60883c5d44688101f7e9864 | [
"MIT"
] | null | null | null | app.py | sandeepsn1997/civilapp | 749027e904924575f60883c5d44688101f7e9864 | [
"MIT"
] | null | null | null | app.py | sandeepsn1997/civilapp | 749027e904924575f60883c5d44688101f7e9864 | [
"MIT"
] | null | null | null | from flask import Flask
from flask_restful import Api
from resources.findresult import resultClass
from flask_cors import CORS
app = Flask(__name__)
api = Api(app)
cors = CORS(app, resources={r"*": {"origins": "*"}})
api.add_resource(resultClass, "/calculate",)
if __name__ == "__main__":
app.run() | 15.5 | 52 | 0.716129 | 41 | 310 | 5.04878 | 0.463415 | 0.130435 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.148387 | 310 | 20 | 53 | 15.5 | 0.784091 | 0 | 0 | 0 | 0 | 0 | 0.086817 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.4 | 0 | 0.4 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
84b5233d42281133240d90a6282304a5f6974593 | 1,334 | py | Python | src/main/python/geeksforgeeks/list/merge-a-linked-list-into-another-linked-list-at-alternate-positions.py | sonymoon/algorithm | cc2a9e0125fc64bdbf6549034bad6482d2027ea2 | [
"Apache-2.0"
] | null | null | null | src/main/python/geeksforgeeks/list/merge-a-linked-list-into-another-linked-list-at-alternate-positions.py | sonymoon/algorithm | cc2a9e0125fc64bdbf6549034bad6482d2027ea2 | [
"Apache-2.0"
] | null | null | null | src/main/python/geeksforgeeks/list/merge-a-linked-list-into-another-linked-list-at-alternate-positions.py | sonymoon/algorithm | cc2a9e0125fc64bdbf6549034bad6482d2027ea2 | [
"Apache-2.0"
] | null | null | null | class Node:
def __init__(self, val):
self.val = val
self.next = None
class Solution:
def __init__(self, head1, head2):
self.head1 = head1
self.head2 = head2
def mergeLists(self):
if not self.head1:
return
p1 = self.head1
p2 = self.head2... | 19.910448 | 37 | 0.478261 | 165 | 1,334 | 3.787879 | 0.254545 | 0.0864 | 0.064 | 0.0384 | 0.1568 | 0.1376 | 0.1376 | 0.0832 | 0.0832 | 0 | 0 | 0.071802 | 0.425787 | 1,334 | 66 | 38 | 20.212121 | 0.744125 | 0 | 0 | 0.148148 | 0 | 0 | 0.010495 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | null | null | 0.148148 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84bf142f67d30886b1439d0e5702cbba5b47e01c | 8,344 | py | Python | yabt/target_extraction.py | resonai/ybt | 48e9f9b8bc02686c95b2afc29265b799ff9d80da | [
"Apache-2.0"
] | 2 | 2018-10-10T09:13:47.000Z | 2021-08-18T08:57:19.000Z | yabt/target_extraction.py | resonai/ybt | 48e9f9b8bc02686c95b2afc29265b799ff9d80da | [
"Apache-2.0"
] | 123 | 2018-02-05T08:36:47.000Z | 2022-03-29T07:44:24.000Z | yabt/target_extraction.py | resonai/ybt | 48e9f9b8bc02686c95b2afc29265b799ff9d80da | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Copyright 2016 Resonai Ltd. All rights reserved
#
# 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 requir... | 43.010309 | 79 | 0.639741 | 1,079 | 8,344 | 4.7924 | 0.241891 | 0.052794 | 0.044092 | 0.03829 | 0.206343 | 0.147747 | 0.09708 | 0.048153 | 0.028234 | 0 | 0 | 0.00229 | 0.267378 | 8,344 | 193 | 80 | 43.233161 | 0.843612 | 0.297459 | 0 | 0.0625 | 0 | 0 | 0.079268 | 0 | 0 | 0 | 0 | 0.010363 | 0.071429 | 1 | 0.080357 | false | 0 | 0.071429 | 0.017857 | 0.214286 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84c0d5480b9a0dfcd689f7916f542d27835308dd | 991 | py | Python | roles/node_exporter/molecule/default/tests/test_default.py | virtuman/metalk8s | 5330d94115f6517f807743ae9160cdf830b019f8 | [
"Apache-2.0"
] | null | null | null | roles/node_exporter/molecule/default/tests/test_default.py | virtuman/metalk8s | 5330d94115f6517f807743ae9160cdf830b019f8 | [
"Apache-2.0"
] | null | null | null | roles/node_exporter/molecule/default/tests/test_default.py | virtuman/metalk8s | 5330d94115f6517f807743ae9160cdf830b019f8 | [
"Apache-2.0"
] | null | null | null | import os
import requests
import testinfra.utils.ansible_runner
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
os.environ['MOLECULE_INVENTORY_FILE']).get_hosts('all')
def _node_exporter_svc(host):
return host.service('node_exporter')
def test_node_exporter_is_enabled(host):
assert _n... | 26.078947 | 77 | 0.744702 | 148 | 991 | 4.709459 | 0.466216 | 0.172166 | 0.063128 | 0.109039 | 0.149211 | 0.088953 | 0.088953 | 0 | 0 | 0 | 0 | 0.034198 | 0.144299 | 991 | 37 | 78 | 26.783784 | 0.787736 | 0.149344 | 0 | 0 | 0 | 0 | 0.172825 | 0.053635 | 0 | 0 | 0 | 0 | 0.368421 | 1 | 0.263158 | false | 0 | 0.157895 | 0.052632 | 0.473684 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84c334ebafafbcef453fd0dd337e95d55e2d471e | 2,052 | py | Python | tools/scrape/scrape.py | therealplato/vim-awesome | 54e33073f4d470230e4578239ceb8f203f5f6613 | [
"MIT"
] | 1,379 | 2016-04-10T06:35:30.000Z | 2022-03-31T16:07:38.000Z | tools/scrape/scrape.py | therealplato/vim-awesome | 54e33073f4d470230e4578239ceb8f203f5f6613 | [
"MIT"
] | 119 | 2016-04-10T04:26:48.000Z | 2022-03-25T15:10:06.000Z | tools/scrape/scrape.py | therealplato/vim-awesome | 54e33073f4d470230e4578239ceb8f203f5f6613 | [
"MIT"
] | 83 | 2016-04-10T11:32:03.000Z | 2022-03-16T01:56:35.000Z | import argparse
import logging
from raven import Client
from tools.scrape import vimorg, github
try:
import secrets
_SENTRY_DSN = getattr(secrets, 'SENTRY_DSN', None)
except ImportError:
_SENTRY_DSN = None
client = Client(_SENTRY_DSN)
def scrape_github_plugins(num):
print "\nScraping plugins from ... | 30.176471 | 74 | 0.683723 | 256 | 2,052 | 5.25 | 0.300781 | 0.041667 | 0.050595 | 0.053571 | 0.221726 | 0.159226 | 0.159226 | 0.159226 | 0.159226 | 0.159226 | 0 | 0.004902 | 0.204678 | 2,052 | 67 | 75 | 30.626866 | 0.818627 | 0 | 0 | 0.102041 | 0 | 0 | 0.253411 | 0.010721 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.122449 | null | null | 0.183673 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84c3cb4712b0efb11d6339a780efbbe1e2e5b375 | 814 | py | Python | condicionales.py | NewSteven/python | bcb3f81741058a3a610d0a66d4422bb0c23d301f | [
"MIT"
] | null | null | null | condicionales.py | NewSteven/python | bcb3f81741058a3a610d0a66d4422bb0c23d301f | [
"MIT"
] | null | null | null | condicionales.py | NewSteven/python | bcb3f81741058a3a610d0a66d4422bb0c23d301f | [
"MIT"
] | null | null | null | """ if
print('programa de notas')
def evaluacion(nota):
valoracion="aprovado"
if nota < 5:
valoracion='suspendido'
else:
valoracion='aprovo'
return valoracion
dato = input('ingrese la nota: ')
print(evaluacion(int(dato))) """
""" for
# recorro una lista
for i in... | 18.930233 | 65 | 0.552826 | 107 | 814 | 4.205607 | 0.551402 | 0.035556 | 0.053333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.025641 | 0.281327 | 814 | 43 | 66 | 18.930233 | 0.74359 | 0.339066 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.5 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 1 |
84c46aa8a4fecd6e028d72b776acafc1de164ea6 | 2,040 | py | Python | ExtraModule/os_cory_schaffer/os.py | mlobf/new_pandas_course | ecf0ea529b22422a7e97719b89ba9037d0fb2be7 | [
"BSD-3-Clause"
] | null | null | null | ExtraModule/os_cory_schaffer/os.py | mlobf/new_pandas_course | ecf0ea529b22422a7e97719b89ba9037d0fb2be7 | [
"BSD-3-Clause"
] | null | null | null | ExtraModule/os_cory_schaffer/os.py | mlobf/new_pandas_course | ecf0ea529b22422a7e97719b89ba9037d0fb2be7 | [
"BSD-3-Clause"
] | null | null | null | import os
from datetime import datetime
# All for os molule.
# print(dir(os))
# Current Directory
# print(os.getcwd())
# Changing directories
# /ExtraModule/os_cory_schaffer
# os.chdir('/home/mlobf/Documents/my_git/new_pandas_course/new_pandas_course/')
# print(os.getcwd())
# Listing Directories
# print(os.listd... | 17.894737 | 79 | 0.690686 | 326 | 2,040 | 4.226994 | 0.346626 | 0.076197 | 0.055878 | 0.055152 | 0.153846 | 0.127721 | 0.039187 | 0 | 0 | 0 | 0 | 0.002894 | 0.152941 | 2,040 | 113 | 80 | 18.053097 | 0.79456 | 0.735784 | 0 | 0.333333 | 0 | 0 | 0.093168 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.111111 | 0.111111 | 0 | 0.111111 | 0.166667 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
84cc6666dab2effde59ecef6bec4cb643a92bdc6 | 1,650 | py | Python | proma/projects/migrations/0006_timesheet.py | erickgnavar/Proma | 159051f4247700166f063075b3819ae426f6d337 | [
"MIT"
] | 3 | 2018-01-22T08:50:38.000Z | 2021-07-16T04:08:28.000Z | proma/projects/migrations/0006_timesheet.py | erickgnavar/Proma | 159051f4247700166f063075b3819ae426f6d337 | [
"MIT"
] | 13 | 2019-05-27T03:08:29.000Z | 2020-01-03T03:36:04.000Z | proma/projects/migrations/0006_timesheet.py | erickgnavar/Proma | 159051f4247700166f063075b3819ae426f6d337 | [
"MIT"
] | 1 | 2019-10-03T17:52:29.000Z | 2019-10-03T17:52:29.000Z | # Generated by Django 2.0.9 on 2018-12-23 15:33
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import model_utils.fields
class Migration(migrations.Migration):
dependencies = [
('projects', '0005_expense_is_billable'),
]
operations = [
... | 45.833333 | 166 | 0.632121 | 174 | 1,650 | 5.83908 | 0.41954 | 0.097441 | 0.074803 | 0.076772 | 0.132874 | 0.104331 | 0.104331 | 0.104331 | 0.104331 | 0 | 0 | 0.016535 | 0.230303 | 1,650 | 35 | 167 | 47.142857 | 0.783465 | 0.027273 | 0 | 0 | 1 | 0 | 0.16781 | 0.014972 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.137931 | 0 | 0.241379 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84cd4b3e13455675e1738dcb0bceae65326b3579 | 1,969 | py | Python | tests/finiteField_test.py | PedroGabrielBHZ/bitcoin_lib | 4bb8db646497df7d905d285814337218a36818b6 | [
"MIT"
] | null | null | null | tests/finiteField_test.py | PedroGabrielBHZ/bitcoin_lib | 4bb8db646497df7d905d285814337218a36818b6 | [
"MIT"
] | null | null | null | tests/finiteField_test.py | PedroGabrielBHZ/bitcoin_lib | 4bb8db646497df7d905d285814337218a36818b6 | [
"MIT"
] | null | null | null | from unittest import TestCase, TestSuite, TextTestRunner
from cryptoMath.finiteField import FieldElement
class FieldElementTest(TestCase):
def test_ne(self):
a = FieldElement(2, 31)
b = FieldElement(2, 31)
c = FieldElement(15, 31)
self.assertEqual(a, b)
self.assertTrue(a !... | 29.38806 | 57 | 0.599797 | 244 | 1,969 | 4.758197 | 0.209016 | 0.190353 | 0.161068 | 0.170543 | 0.374677 | 0.356589 | 0.182601 | 0.079242 | 0.079242 | 0 | 0 | 0.082296 | 0.265617 | 1,969 | 66 | 58 | 29.833333 | 0.720609 | 0 | 0 | 0.092593 | 0 | 0 | 0.027933 | 0 | 0 | 0 | 0 | 0 | 0.240741 | 1 | 0.12963 | false | 0 | 0.037037 | 0 | 0.185185 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84d36286f1eb060224e876b47b52f620e41be939 | 1,007 | py | Python | Python/1-Fundamentals/Week 3/workshop3/donations_pkg/user.py | armirh/Nucamp-SQL-Devops-Training | 6c2dc5793c732bfb4c4d365acbb346a95fbf4bf2 | [
"MIT"
] | 2 | 2022-01-19T02:33:11.000Z | 2022-01-19T02:33:13.000Z | Python/1-Fundamentals/Week 3/workshop3/donations_pkg/user.py | armirh/Nucamp-SQL-Devops-Training | 6c2dc5793c732bfb4c4d365acbb346a95fbf4bf2 | [
"MIT"
] | null | null | null | Python/1-Fundamentals/Week 3/workshop3/donations_pkg/user.py | armirh/Nucamp-SQL-Devops-Training | 6c2dc5793c732bfb4c4d365acbb346a95fbf4bf2 | [
"MIT"
] | null | null | null | #Task 4: Login functionality
# In its parameter list, define three parameters: database, username, and password.
def login(database, username, password):
if username in dict.keys(database) and database[username] == password:
print("Welcome back: ", username)
elif username in dict.keys(database) or pass... | 31.46875 | 83 | 0.678252 | 120 | 1,007 | 5.666667 | 0.491667 | 0.094118 | 0.061765 | 0.047059 | 0.15 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001269 | 0.217478 | 1,007 | 31 | 84 | 32.483871 | 0.861675 | 0.108242 | 0 | 0.130435 | 0 | 0 | 0.271812 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.173913 | false | 0.130435 | 0 | 0 | 0.217391 | 0.347826 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
84d416f953c1de75c9d22dfc606269affcaaf543 | 253 | py | Python | loop/index.py | ugtern/Py_test | b1af399b19df38befc8f971b600cbcdc7249beb6 | [
"MIT"
] | null | null | null | loop/index.py | ugtern/Py_test | b1af399b19df38befc8f971b600cbcdc7249beb6 | [
"MIT"
] | null | null | null | loop/index.py | ugtern/Py_test | b1af399b19df38befc8f971b600cbcdc7249beb6 | [
"MIT"
] | null | null | null | from app.worker import WorkerClass
import json
""" получение конфигурационных данных из json файла """
with open('config.json') as file:
file = json.load(file)
work = WorkerClass(file['mongo_con_str'], file['url_for_parse'])
work.parse_worker()
| 21.083333 | 64 | 0.73913 | 36 | 253 | 5.055556 | 0.666667 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.134387 | 253 | 11 | 65 | 23 | 0.83105 | 0 | 0 | 0 | 0 | 0 | 0.186869 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.333333 | 0 | 0.333333 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
84d4f1a2546c6012e991ac9efe5f63d3915d7e40 | 11,299 | py | Python | test/runtest.py | jsmeredith/EAVL | 114924a92aed4f1adfcf4f751151d9355c593944 | [
"Apache-2.0",
"BSD-2-Clause"
] | 6 | 2016-12-11T21:40:00.000Z | 2018-04-04T10:33:40.000Z | test/runtest.py | jsmeredith/EAVL | 114924a92aed4f1adfcf4f751151d9355c593944 | [
"Apache-2.0",
"BSD-2-Clause"
] | 3 | 2015-02-11T20:55:01.000Z | 2017-05-31T01:56:21.000Z | test/runtest.py | jsmeredith/EAVL | 114924a92aed4f1adfcf4f751151d9355c593944 | [
"Apache-2.0",
"BSD-2-Clause"
] | 6 | 2015-05-24T06:27:45.000Z | 2020-05-08T12:17:07.000Z | #! /usr/bin/env python
# *****************************************************************************
# File: runtest.py
#
# Purpose:
# Runs a set of tests against sample data files and validates the
# results against known baselines. For now, the results are simply
# a summary of the generated data set (sh... | 37.290429 | 164 | 0.578635 | 1,279 | 11,299 | 5.006255 | 0.181392 | 0.032485 | 0.061065 | 0.022958 | 0.290489 | 0.210995 | 0.141184 | 0.122911 | 0.082461 | 0.082461 | 0 | 0.011738 | 0.193203 | 11,299 | 302 | 165 | 37.413907 | 0.690654 | 0.160014 | 0 | 0.078341 | 0 | 0.004608 | 0.343012 | 0.104164 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.018433 | 0.133641 | null | null | 0.041475 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84dc78aa1b83b27d1d05c5b29f287d1e838f87f8 | 4,257 | py | Python | hood/migrations/0001_initial.py | feddykip/Neighborhood | b57e27acaa2142111691627798d3f97f033631c3 | [
"MIT"
] | null | null | null | hood/migrations/0001_initial.py | feddykip/Neighborhood | b57e27acaa2142111691627798d3f97f033631c3 | [
"MIT"
] | null | null | null | hood/migrations/0001_initial.py | feddykip/Neighborhood | b57e27acaa2142111691627798d3f97f033631c3 | [
"MIT"
] | null | null | null | # Generated by Django 3.2.9 on 2022-01-04 20:23
import cloudinary.models
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
migrations.swappable_dependency(settings.AUTH_US... | 51.914634 | 158 | 0.604651 | 441 | 4,257 | 5.684807 | 0.208617 | 0.061029 | 0.071799 | 0.070203 | 0.704826 | 0.674112 | 0.654966 | 0.532908 | 0.532908 | 0.532908 | 0 | 0.020748 | 0.25276 | 4,257 | 81 | 159 | 52.555556 | 0.767369 | 0.010571 | 0 | 0.459459 | 1 | 0 | 0.092874 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.054054 | 0 | 0.108108 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84e05a795603de9a2f35aaccf00062c284c78f69 | 9,434 | py | Python | bc_exploration/envs/grid_world.py | braincorp/bc_exploration | c684e1b7df76171000d59bd507ee8af6839347a8 | [
"MIT"
] | 1 | 2021-02-19T03:01:22.000Z | 2021-02-19T03:01:22.000Z | bc_exploration/envs/grid_world.py | braincorp/bc_exploration | c684e1b7df76171000d59bd507ee8af6839347a8 | [
"MIT"
] | null | null | null | bc_exploration/envs/grid_world.py | braincorp/bc_exploration | c684e1b7df76171000d59bd507ee8af6839347a8 | [
"MIT"
] | 1 | 2019-05-15T20:53:35.000Z | 2019-05-15T20:53:35.000Z | """grid_world.py
A simple grid world environment. Edges of the map are treated like obstacles
Map must be a image file whose values represent free (255, white), occupied (0, black).
"""
from __future__ import print_function, absolute_import, division
import cv2
import numpy as np
from bc_exploration.mapping.costmap i... | 42.687783 | 128 | 0.647127 | 1,278 | 9,434 | 4.612676 | 0.210485 | 0.022561 | 0.021374 | 0.012892 | 0.1905 | 0.164037 | 0.12536 | 0.12536 | 0.12536 | 0.080916 | 0 | 0.01588 | 0.265741 | 9,434 | 220 | 129 | 42.881818 | 0.835138 | 0.374815 | 0 | 0.020619 | 0 | 0 | 0.011477 | 0 | 0 | 0 | 0 | 0.013636 | 0.061856 | 1 | 0.134021 | false | 0 | 0.061856 | 0 | 0.298969 | 0.061856 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84e3d2bf75b5344fe1ff8e6e1e921c64c4175720 | 3,548 | py | Python | CSDGAN/pipeline/data/make_image_dataset.py | Atrus619/CSDGAN | 712be213e59b32a79a4970684d726af63616edaf | [
"MIT"
] | 1 | 2019-06-27T12:14:39.000Z | 2019-06-27T12:14:39.000Z | CSDGAN/pipeline/data/make_image_dataset.py | Atrus619/CSDGAN | 712be213e59b32a79a4970684d726af63616edaf | [
"MIT"
] | 21 | 2019-08-06T12:44:14.000Z | 2019-11-03T14:28:46.000Z | CSDGAN/pipeline/data/make_image_dataset.py | Atrus619/Synthetic_Data_GAN_Capstone | 712be213e59b32a79a4970684d726af63616edaf | [
"MIT"
] | 1 | 2020-07-25T13:14:31.000Z | 2020-07-25T13:14:31.000Z | import CSDGAN.utils.constants as cs
import CSDGAN.utils.db as db
import CSDGAN.utils.utils as cu
import CSDGAN.utils.img_data_loading as cuidl
import logging
import os
import pickle as pkl
def make_image_dataset(run_id, username, title, folder, bs, x_dim=None, splits=None):
"""
Requirements of image data set... | 47.306667 | 138 | 0.683484 | 539 | 3,548 | 4.369202 | 0.326531 | 0.030573 | 0.042463 | 0.033121 | 0.22845 | 0.221656 | 0.208917 | 0.138854 | 0.117622 | 0.039066 | 0 | 0.00145 | 0.222379 | 3,548 | 74 | 139 | 47.945946 | 0.85212 | 0.253382 | 0 | 0 | 0 | 0 | 0.178709 | 0 | 0 | 0 | 0 | 0 | 0.047619 | 1 | 0.02381 | false | 0 | 0.309524 | 0 | 0.333333 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
84ee6d82c6a3a9272fdf1987ab9318472bce0814 | 383 | py | Python | custom_steps/my_custom_steps.py | lubosmato/web-hooker | e95751185ab0292cd6a345baa14f2ff6055c9fa8 | [
"MIT"
] | 4 | 2019-12-25T19:32:30.000Z | 2020-10-16T14:56:57.000Z | custom_steps/my_custom_steps.py | lubosmato/web-hooker | e95751185ab0292cd6a345baa14f2ff6055c9fa8 | [
"MIT"
] | 6 | 2020-01-13T21:28:03.000Z | 2020-02-17T18:48:37.000Z | custom_steps/my_custom_steps.py | lubosmato/web-hooker | e95751185ab0292cd6a345baa14f2ff6055c9fa8 | [
"MIT"
] | 1 | 2019-12-24T15:36:01.000Z | 2019-12-24T15:36:01.000Z | from typing import Any
from pipeliner.steps import Step
import logging
logger = logging.getLogger(__name__)
class SayHello(Step):
def perform(self, data: Any) -> Any:
logger.info(f"Hello there! Got this: {data}")
return data
class SayBye(Step):
def perform(self, data: Any) -> Any:
... | 19.15 | 53 | 0.652742 | 53 | 383 | 4.641509 | 0.490566 | 0.056911 | 0.113821 | 0.146341 | 0.487805 | 0.317073 | 0.317073 | 0.317073 | 0.317073 | 0.317073 | 0 | 0 | 0.234987 | 383 | 19 | 54 | 20.157895 | 0.83959 | 0 | 0 | 0.333333 | 0 | 0 | 0.140992 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0.25 | 0 | 0.75 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
84f273e313c7cafb5c945e0360110c5397237ff6 | 2,595 | py | Python | m2g/functional/m2g_func.py | caseypw/m2g | be29587322ab1fafb96f6afb726efbdb39b64b66 | [
"Apache-2.0"
] | null | null | null | m2g/functional/m2g_func.py | caseypw/m2g | be29587322ab1fafb96f6afb726efbdb39b64b66 | [
"Apache-2.0"
] | null | null | null | m2g/functional/m2g_func.py | caseypw/m2g | be29587322ab1fafb96f6afb726efbdb39b64b66 | [
"Apache-2.0"
] | null | null | null | import subprocess
import yaml
from m2g.utils.gen_utils import run
def make_dataconfig(input_dir, sub, ses, anat, func, acquisition='alt+z', tr=2.0):
"""Generates the data_config file needed by cpac
Arguments:
input_dir {str} -- Path of directory containing input files
sub {int} -- subject ... | 33.269231 | 167 | 0.625434 | 339 | 2,595 | 4.60767 | 0.327434 | 0.046095 | 0.028809 | 0.043534 | 0.361716 | 0.330986 | 0.283611 | 0.212548 | 0.169014 | 0.169014 | 0 | 0.005747 | 0.262428 | 2,595 | 77 | 168 | 33.701299 | 0.810345 | 0.339499 | 0 | 0 | 1 | 0.027778 | 0.264174 | 0.056075 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0 | 0.083333 | 0 | 0.222222 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84f4de0ece45397a534f11bb4e81184a1b090ad3 | 504 | py | Python | Hangman/words.py | pralhad88/Python_project | ec3978859b0218f35ceba0e8eeff2555e3b7f372 | [
"MIT"
] | 1 | 2020-04-14T08:31:30.000Z | 2020-04-14T08:31:30.000Z | Hangman/words.py | pralhad88/Python_project | ec3978859b0218f35ceba0e8eeff2555e3b7f372 | [
"MIT"
] | null | null | null | Hangman/words.py | pralhad88/Python_project | ec3978859b0218f35ceba0e8eeff2555e3b7f372 | [
"MIT"
] | null | null | null | import string
import random
def load_words():
"""
Ye function kaafi jayada words ko load karne mai help karega
"""
word_list = open("words.txt",'r').read().split()
return word_list
def choose_word():
"""
word_list (list): list of words (strings)
ye function ek word randoml... | 24 | 65 | 0.644841 | 67 | 504 | 4.656716 | 0.477612 | 0.128205 | 0.089744 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.253968 | 504 | 21 | 66 | 24 | 0.829787 | 0 | 0 | 0 | 0 | 0 | 0.032787 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.181818 | null | null | 0.090909 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84f750bccc49fc9c6ad222918acc6c6e7887f8cf | 912 | py | Python | tests/test_utils.py | daleal/fintoc-python | 3cd886e562b09a0615f27388d59c1ea8bde7fd73 | [
"BSD-3-Clause"
] | null | null | null | tests/test_utils.py | daleal/fintoc-python | 3cd886e562b09a0615f27388d59c1ea8bde7fd73 | [
"BSD-3-Clause"
] | null | null | null | tests/test_utils.py | daleal/fintoc-python | 3cd886e562b09a0615f27388d59c1ea8bde7fd73 | [
"BSD-3-Clause"
] | null | null | null | import unittest
from fintoc import utils
class UtilsTestCase(unittest.TestCase):
def setUp(self):
self.dict_ = {"spam": 42, "ham": "spam", "bacon": {"spam": -1}}
def test_pick(self):
self.assertEqual(utils.pick(self.dict_, "ham"), {"ham": "spam"})
self.assertEqual(utils.pick(self.dict... | 28.5 | 72 | 0.596491 | 98 | 912 | 5.234694 | 0.408163 | 0.146199 | 0.194932 | 0.140351 | 0.253411 | 0.253411 | 0 | 0 | 0 | 0 | 0 | 0.008772 | 0.25 | 912 | 31 | 73 | 29.419355 | 0.741228 | 0 | 0 | 0.125 | 0 | 0 | 0.201754 | 0.125 | 0 | 0 | 0 | 0 | 0.208333 | 1 | 0.166667 | false | 0 | 0.083333 | 0 | 0.291667 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
84fd04a8b2a061588f605c0efb68d2e9000b264b | 1,210 | py | Python | algorithms/others/solve_the_equation.py | kevinshenyang07/Data-Structure-and-Algo | 36b02feea04b892f1256de090c4fcf7b6aa98873 | [
"MIT"
] | null | null | null | algorithms/others/solve_the_equation.py | kevinshenyang07/Data-Structure-and-Algo | 36b02feea04b892f1256de090c4fcf7b6aa98873 | [
"MIT"
] | null | null | null | algorithms/others/solve_the_equation.py | kevinshenyang07/Data-Structure-and-Algo | 36b02feea04b892f1256de090c4fcf7b6aa98873 | [
"MIT"
] | null | null | null | # Solve the Equation
class Solution(object):
def solveEquation(self, equation):
"""
:type equation: str
:rtype: str
"""
left, right = equation.split('=')
a1, b1 = self.get_coefficients(left)
a2, b2 = self.get_coefficients(right)
a, b = a1 - a2, b2 - b... | 25.208333 | 54 | 0.345455 | 131 | 1,210 | 3.167939 | 0.351145 | 0.108434 | 0.043373 | 0.033735 | 0.043373 | 0.043373 | 0 | 0 | 0 | 0 | 0 | 0.035211 | 0.530579 | 1,210 | 47 | 55 | 25.744681 | 0.695423 | 0.047934 | 0 | 0.216216 | 0 | 0 | 0.035746 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.054054 | false | 0 | 0 | 0 | 0.189189 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
170099110d90ed57efa2cd76120e5eb208978e87 | 770 | py | Python | Utils/Paths.py | kuyu12/Tower_defence | 91ea938d6f9d4d46a8236fea2be4c450fe48504b | [
"MIT"
] | null | null | null | Utils/Paths.py | kuyu12/Tower_defence | 91ea938d6f9d4d46a8236fea2be4c450fe48504b | [
"MIT"
] | null | null | null | Utils/Paths.py | kuyu12/Tower_defence | 91ea938d6f9d4d46a8236fea2be4c450fe48504b | [
"MIT"
] | null | null | null | import sys
ASSETS_PATH = sys.path[1] + "/Assets"
MAP_IMAGES_PATH = ASSETS_PATH + '/Maps_images'
TOWER_IMAGES_PATH = ASSETS_PATH + '/Towers_images'
ENEMY_IMAGES_PATH = ASSETS_PATH + '/Enemy_images'
EXPLOSION_IMAGES_PATH = ASSETS_PATH + '/Shot_images/explotion_images'
STAGES_PATH = sys.path[1] + "/Stages_data"
USER_INFO... | 42.777778 | 73 | 0.794805 | 111 | 770 | 5.018018 | 0.279279 | 0.16158 | 0.201077 | 0.143627 | 0.265709 | 0.118492 | 0 | 0 | 0 | 0 | 0 | 0.011494 | 0.096104 | 770 | 17 | 74 | 45.294118 | 0.788793 | 0 | 0 | 0 | 0 | 0 | 0.285714 | 0.148052 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.066667 | 0 | 0.066667 | 0 | 0 | 0 | 0 | null | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca02dc90099319d1808d8114dea9ac9e91a5036b | 6,119 | py | Python | charms/dex-auth/reactive/dex_auth.py | ycliuhw/bundle-kubeflow | 227fa751b878add4822e8788f406256ffc9b8df1 | [
"Apache-2.0"
] | null | null | null | charms/dex-auth/reactive/dex_auth.py | ycliuhw/bundle-kubeflow | 227fa751b878add4822e8788f406256ffc9b8df1 | [
"Apache-2.0"
] | null | null | null | charms/dex-auth/reactive/dex_auth.py | ycliuhw/bundle-kubeflow | 227fa751b878add4822e8788f406256ffc9b8df1 | [
"Apache-2.0"
] | null | null | null | import random
import string
import subprocess
import typing
from hashlib import sha256
from pathlib import Path
from uuid import uuid4
import yaml
from charmhelpers.core import hookenv
from charms import layer
from charms.reactive import clear_flag, endpoint_from_name, hook, set_flag, when, when_any, when_not
try:
... | 31.219388 | 100 | 0.558751 | 622 | 6,119 | 5.345659 | 0.345659 | 0.027068 | 0.014436 | 0.018947 | 0.124812 | 0.101654 | 0.063158 | 0.063158 | 0.063158 | 0.043308 | 0 | 0.004967 | 0.309037 | 6,119 | 195 | 101 | 31.379487 | 0.781457 | 0.055891 | 0 | 0.128205 | 0 | 0 | 0.209359 | 0.048007 | 0 | 0 | 0 | 0 | 0 | 1 | 0.051282 | false | 0.051282 | 0.089744 | 0 | 0.173077 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
ca04a5ed841c61bbe580846ba1733ee1825be939 | 4,315 | py | Python | network/network.py | kashu98/Simple-Deep-Learning | 73fc4719c145cc1f49826fd90d5448db65cbe08b | [
"MIT"
] | 1 | 2017-09-25T06:28:14.000Z | 2017-09-25T06:28:14.000Z | network/network.py | kashu98/Simple-Deep-Learning | 73fc4719c145cc1f49826fd90d5448db65cbe08b | [
"MIT"
] | null | null | null | network/network.py | kashu98/Simple-Deep-Learning | 73fc4719c145cc1f49826fd90d5448db65cbe08b | [
"MIT"
] | null | null | null | from collections import OrderedDict
import sys,os
sys.path.append(os.pardir)
# import from parent direntory
from loss import *
from activation import *
from layers import *
from optimizer import *
from initializer import *
# model weights are easily stored using HDF5 format and that the network structure can be save... | 37.521739 | 161 | 0.609038 | 566 | 4,315 | 4.583039 | 0.257951 | 0.142637 | 0.06515 | 0.058982 | 0.421742 | 0.289514 | 0.231689 | 0.205474 | 0.162298 | 0.126831 | 0 | 0.006092 | 0.239166 | 4,315 | 114 | 162 | 37.850877 | 0.784039 | 0 | 0 | 0.1875 | 0 | 0 | 0.064475 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.015625 | 0.109375 | null | null | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca060d0e8b73f301a52aea377eca788a7e21ae58 | 1,476 | py | Python | taegis_sdk_python/errors.py | secureworks/taegis-sdk-python | 195bbc2ca9738c9fad572ca2d22e6e9297fa9b35 | [
"Apache-2.0"
] | 1 | 2021-02-25T23:00:46.000Z | 2021-02-25T23:00:46.000Z | taegis_sdk_python/errors.py | secureworks/taegis-sdk-python | 195bbc2ca9738c9fad572ca2d22e6e9297fa9b35 | [
"Apache-2.0"
] | null | null | null | taegis_sdk_python/errors.py | secureworks/taegis-sdk-python | 195bbc2ca9738c9fad572ca2d22e6e9297fa9b35 | [
"Apache-2.0"
] | null | null | null | from dataclasses import MISSING
from typing import List
class ServiceCoreException(Exception):
"""
base class for all tool errors
"""
def __init__(
self, message,
comments: List[str] = None,
nested_exception: BaseException = None
):
# Call the base clas... | 25.894737 | 94 | 0.651084 | 149 | 1,476 | 6.268456 | 0.436242 | 0.11242 | 0.08137 | 0.034261 | 0.057816 | 0.057816 | 0 | 0 | 0 | 0 | 0 | 0 | 0.264228 | 1,476 | 56 | 95 | 26.357143 | 0.860037 | 0.205285 | 0 | 0.107143 | 0 | 0 | 0.091158 | 0.053783 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0.107143 | 0.071429 | 0 | 0.392857 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
ca104a4777a65713480f7f4fe42480dc9a6cd53d | 893 | py | Python | main.py | kwon-young/pyqt_corrector | f48b7c75d074d5d0ffce55006ff7653e5ad309bb | [
"MIT"
] | null | null | null | main.py | kwon-young/pyqt_corrector | f48b7c75d074d5d0ffce55006ff7653e5ad309bb | [
"MIT"
] | 1 | 2021-11-15T17:49:09.000Z | 2021-11-15T17:49:09.000Z | main.py | kwon-young/pyqt_corrector | f48b7c75d074d5d0ffce55006ff7653e5ad309bb | [
"MIT"
] | null | null | null | """
File: main2.py
Author: Kwon-Young Choi
Email: kwon-young.choi@irisa.fr
Date: 2019-08-12
Description: main
"""
import sys
from PySide2.QtUiTools import QUiLoader
from PySide2.QtWidgets import QApplication
from PySide2 import QtCore
from PySide2.QtCore import QFile, QCoreApplication
from pyqt_corrector.mainwindow i... | 27.060606 | 67 | 0.776036 | 105 | 893 | 6.447619 | 0.485714 | 0.064993 | 0.075332 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.016818 | 0.134379 | 893 | 32 | 68 | 27.90625 | 0.858991 | 0.117581 | 0 | 0 | 0 | 0 | 0.033333 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.380952 | 0 | 0.380952 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
ca21c13ca16920c92e9a08d60e67d8732aa0cd13 | 4,256 | py | Python | examples/covariance/covariance_run_COSMOS-like_no_lensing.py | DrexelLenser/Lenser | 01ace74bf714fd600b9be58d8d99765276846492 | [
"BSD-4-Clause-UC"
] | null | null | null | examples/covariance/covariance_run_COSMOS-like_no_lensing.py | DrexelLenser/Lenser | 01ace74bf714fd600b9be58d8d99765276846492 | [
"BSD-4-Clause-UC"
] | null | null | null | examples/covariance/covariance_run_COSMOS-like_no_lensing.py | DrexelLenser/Lenser | 01ace74bf714fd600b9be58d8d99765276846492 | [
"BSD-4-Clause-UC"
] | null | null | null | from covariance import Covariance
import numpy as np
from scipy.special import gamma
"""Covariance run 1: COSMOS-like with no lensing fields"""
# Generate non-fit parameters.
# .. These values should be motivated to reflect actual data
# .. Postage stamp size
Nx = 150
Ny = 150
# .. Standard galaxy size (in pixels)
a... | 25.035294 | 183 | 0.698778 | 739 | 4,256 | 3.907984 | 0.242219 | 0.027701 | 0.031163 | 0.027701 | 0.470222 | 0.461911 | 0.396814 | 0.359072 | 0.30644 | 0.273199 | 0 | 0.088864 | 0.175047 | 4,256 | 169 | 184 | 25.183432 | 0.733694 | 0.164944 | 0 | 0 | 1 | 0 | 0.030439 | 0.030439 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.083333 | 0 | 0.083333 | 0.027778 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca2cbd269d6dfc3fc0dc90287c83b599b6f9adf8 | 28,626 | py | Python | RFPcodonstall.py | TaliaferroLab/AnalysisScripts | 3df37d2f8fca9bc402afe5ea870c42200fca1ed3 | [
"MIT"
] | null | null | null | RFPcodonstall.py | TaliaferroLab/AnalysisScripts | 3df37d2f8fca9bc402afe5ea870c42200fca1ed3 | [
"MIT"
] | null | null | null | RFPcodonstall.py | TaliaferroLab/AnalysisScripts | 3df37d2f8fca9bc402afe5ea870c42200fca1ed3 | [
"MIT"
] | 1 | 2021-10-30T07:37:19.000Z | 2021-10-30T07:37:19.000Z | import gffutils
import os
import sys
import pysam
import subprocess
import argparse
import pickle
import pybedtools
from Bio import SeqIO
import gzip
from itertools import product
from random import randrange
import scipy.stats as stats
import statsmodels.stats.multitest as mt
from collections import OrderedDict
from m... | 40.31831 | 187 | 0.701949 | 3,681 | 28,626 | 5.405596 | 0.172779 | 0.00985 | 0.011559 | 0.010554 | 0.305307 | 0.271334 | 0.240426 | 0.223942 | 0.212584 | 0.196502 | 0 | 0.021023 | 0.167505 | 28,626 | 709 | 188 | 40.375176 | 0.81394 | 0.239747 | 0 | 0.342612 | 0 | 0.002141 | 0.093935 | 0.017892 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.002141 | 0.036403 | null | null | 0.057816 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca3782d6695012bee2fd0eb18793cf01145c1b7e | 246 | py | Python | Python/async_await.py | Sid200026/Misc-Programs | d50a1689a89d331d2567486a5dd22fb2311a0d87 | [
"MIT"
] | 3 | 2021-05-13T13:36:39.000Z | 2021-09-01T05:33:48.000Z | Python/async_await.py | rosy2000/Misc-Programs | d50a1689a89d331d2567486a5dd22fb2311a0d87 | [
"MIT"
] | 4 | 2021-10-06T08:46:33.000Z | 2022-02-26T21:19:42.000Z | Python/async_await.py | rosy2000/Misc-Programs | d50a1689a89d331d2567486a5dd22fb2311a0d87 | [
"MIT"
] | 2 | 2021-09-01T05:33:51.000Z | 2021-09-06T14:39:15.000Z | import asyncio
import time
# the execution of a function can be paused using yield, yield_from and await.
async def test():
await asyncio.sleep(4)
print("Bye")
def hi():
print("yo")
print("1")
asyncio.run(test())
hi()
print("2")
| 13.666667 | 78 | 0.662602 | 39 | 246 | 4.153846 | 0.717949 | 0.08642 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015152 | 0.195122 | 246 | 17 | 79 | 14.470588 | 0.80303 | 0.308943 | 0 | 0 | 0 | 0 | 0.041916 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.090909 | true | 0 | 0.181818 | 0 | 0.272727 | 0.363636 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca39cba0e5b0e71f84127459448decba01d9b1cd | 6,294 | py | Python | fridge/test_suite/mcnpCreatorFunctions_test.py | SoftwareDevEngResearch/FRIDGe | 70ebe31e27b805a935e919e94325b501bdeb3cf6 | [
"MIT"
] | 1 | 2018-04-26T00:33:55.000Z | 2018-04-26T00:33:55.000Z | fridge/test_suite/mcnpCreatorFunctions_test.py | SoftwareDevEngResearch/FRIDGe | 70ebe31e27b805a935e919e94325b501bdeb3cf6 | [
"MIT"
] | 2 | 2018-05-07T02:58:33.000Z | 2019-04-22T17:10:13.000Z | fridge/test_suite/mcnpCreatorFunctions_test.py | SoftwareDevEngResearch/FRIDGe | 70ebe31e27b805a935e919e94325b501bdeb3cf6 | [
"MIT"
] | null | null | null | import fridge.utilities.mcnpCreatorFunctions as MCF
import numpy as np
def test_getRCC():
surfaceCard = MCF.getRCC(0.5, 10, [0.0, 0.0, 0.5555555], 1, '$ Comment')
surfaceCardKnown = '1 RCC 0.0 0.0 0.55556 0 0 10 0.5 $ Comment'
assert surfaceCard == surfaceCardKnown
def test_getRHP():
surfaceCard = M... | 31.949239 | 105 | 0.672863 | 851 | 6,294 | 4.921269 | 0.13396 | 0.016237 | 0.072588 | 0.021729 | 0.666428 | 0.660936 | 0.589303 | 0.56638 | 0.549188 | 0.535339 | 0 | 0.116389 | 0.190499 | 6,294 | 196 | 106 | 32.112245 | 0.705594 | 0 | 0 | 0.304348 | 0 | 0.014493 | 0.09946 | 0 | 0 | 0 | 0 | 0 | 0.246377 | 1 | 0.217391 | false | 0 | 0.014493 | 0 | 0.231884 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca3a6cf2f3e92f3a147c394889d0affc20ae4db0 | 2,603 | py | Python | python/test_RigidMol_Campher.py | ProkopHapala/SimpleSimulationEngine | 240f9b7e85b3a6eda7a27dc15fe3f7b8c08774c5 | [
"MIT"
] | 26 | 2016-12-04T04:45:12.000Z | 2022-03-24T09:39:28.000Z | python/test_RigidMol_Campher.py | ProkopHapala/SimpleSimulationEngine | 240f9b7e85b3a6eda7a27dc15fe3f7b8c08774c5 | [
"MIT"
] | null | null | null | python/test_RigidMol_Campher.py | ProkopHapala/SimpleSimulationEngine | 240f9b7e85b3a6eda7a27dc15fe3f7b8c08774c5 | [
"MIT"
] | 2 | 2019-02-09T12:31:06.000Z | 2019-04-28T02:24:50.000Z | #!/usr/bin/python
import sys
import os
import numpy as np
import pyMolecular.RigidMol as rmol
import pyMolecular.atomicUtils as au
#import pyMolecular.RigidMol
os.chdir("/u/25/prokoph1/unix/git/SimpleSimulationEngine/cpp/Build/apps/MolecularEditor2")
#Cu = np.genfromtxt ( "inputs/Campher.xyz", dtyp... | 28.604396 | 182 | 0.640799 | 416 | 2,603 | 3.956731 | 0.365385 | 0.053463 | 0.061968 | 0.063183 | 0.154921 | 0.123937 | 0.092345 | 0.092345 | 0.070474 | 0.070474 | 0 | 0.086976 | 0.138686 | 2,603 | 90 | 183 | 28.922222 | 0.64719 | 0.258164 | 0 | 0 | 0 | 0 | 0.202049 | 0.104724 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.131579 | null | null | 0.131579 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca3cd94a668db5d2e8617fa6ccd03e308a7b907e | 1,096 | py | Python | croppic/forms.py | doppiozerosrl/django-croppic | 7dace0a2447e8a2e6889eebfea116a34033ee32a | [
"MIT"
] | null | null | null | croppic/forms.py | doppiozerosrl/django-croppic | 7dace0a2447e8a2e6889eebfea116a34033ee32a | [
"MIT"
] | null | null | null | croppic/forms.py | doppiozerosrl/django-croppic | 7dace0a2447e8a2e6889eebfea116a34033ee32a | [
"MIT"
] | null | null | null | from django import forms
from .models import Picture
class PicForm(forms.ModelForm):
class Meta:
model = Picture
fields = ('image', )
class CropForm(forms.Form):
"""Django form for accepting the information passed after cropping a loaded
image
"""
imgUrl = forms.CharField(max_len... | 45.666667 | 109 | 0.676095 | 134 | 1,096 | 5.522388 | 0.432836 | 0.183784 | 0.113514 | 0.064865 | 0.477027 | 0.356757 | 0.189189 | 0.189189 | 0.189189 | 0.189189 | 0 | 0.006127 | 0.255474 | 1,096 | 23 | 110 | 47.652174 | 0.900735 | 0.448905 | 0 | 0 | 0 | 0 | 0.008606 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.125 | 0 | 0.875 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 1 |
ca3ee0f0137f7f918f38edd949a61b95207aa4d3 | 2,746 | py | Python | ringalarmdevice.py | rs1932/homeassistant-ring_alarm_component | b65b8ee1bc7e7408c3bc1adb6fd4e3f4ebf330d6 | [
"Apache-2.0"
] | 4 | 2019-09-07T23:15:54.000Z | 2020-04-20T22:47:37.000Z | ringalarmdevice.py | rs1932/homeassistant-ring_alarm_component | b65b8ee1bc7e7408c3bc1adb6fd4e3f4ebf330d6 | [
"Apache-2.0"
] | 3 | 2019-09-10T00:03:24.000Z | 2020-10-02T13:26:08.000Z | ringalarmdevice.py | rs1932/homeassistant-ring_alarm_component | b65b8ee1bc7e7408c3bc1adb6fd4e3f4ebf330d6 | [
"Apache-2.0"
] | 3 | 2019-11-19T11:03:01.000Z | 2021-05-12T20:11:16.000Z | import datetime
from homeassistant.core import callback
from homeassistant.helpers.dispatcher import async_dispatcher_connect
from homeassistant.helpers.entity import Entity
from .constants import *
class RingAlarmDevice(Entity):
"""Representation of a RingAlarm device entity."""
def __init__(self, ringalar... | 27.188119 | 115 | 0.586307 | 289 | 2,746 | 5.273356 | 0.217993 | 0.108268 | 0.096457 | 0.055774 | 0.246063 | 0.24147 | 0.153543 | 0.107612 | 0.107612 | 0.045932 | 0 | 0.004393 | 0.336854 | 2,746 | 100 | 116 | 27.46 | 0.83251 | 0.016023 | 0 | 0.46988 | 0 | 0 | 0.015579 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.084337 | false | 0.144578 | 0.060241 | 0.036145 | 0.204819 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
ca499a8608b4467bc30c7bc822b29aecddbd429e | 6,839 | py | Python | blog/user/migrations/0001_initial.py | gdludan/blog | 8b4540d4e5d2110b661f0acd4e98b4278053eae9 | [
"MIT"
] | 3 | 2018-12-15T13:08:48.000Z | 2019-01-05T08:33:14.000Z | blog/user/migrations/0001_initial.py | cang-meng/blog | 8b4540d4e5d2110b661f0acd4e98b4278053eae9 | [
"MIT"
] | 9 | 2020-06-05T19:45:05.000Z | 2022-03-11T23:38:28.000Z | blog/user/migrations/0001_initial.py | gdludan/blog | 8b4540d4e5d2110b661f0acd4e98b4278053eae9 | [
"MIT"
] | null | null | null | # Generated by Django 2.1.3 on 2019-01-03 13:32
from django.conf import settings
import django.contrib.auth.models
import django.contrib.auth.validators
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
... | 62.172727 | 329 | 0.618219 | 734 | 6,839 | 5.580381 | 0.277929 | 0.136963 | 0.046875 | 0.064453 | 0.485352 | 0.460938 | 0.394287 | 0.313965 | 0.258301 | 0.258301 | 0 | 0.01534 | 0.237462 | 6,839 | 109 | 330 | 62.743119 | 0.770086 | 0.00658 | 0 | 0.333333 | 1 | 0 | 0.206714 | 0.009128 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.009804 | 0.058824 | 0 | 0.098039 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca5449a26dad2e085a640b34e383ccb59dd127b7 | 2,858 | py | Python | isbit_client/client.py | ISBITX/isbit-client-python | 6943b69cb15d12a8c524461467e3806ab5b1ba19 | [
"MIT"
] | 1 | 2018-04-22T01:30:21.000Z | 2018-04-22T01:30:21.000Z | isbit_client/client.py | ISBITX/isbit-client-python | 6943b69cb15d12a8c524461467e3806ab5b1ba19 | [
"MIT"
] | 1 | 2018-04-26T05:30:41.000Z | 2018-04-26T05:30:41.000Z | isbit_client/client.py | ISBITX/isbit-client-python | 6943b69cb15d12a8c524461467e3806ab5b1ba19 | [
"MIT"
] | 1 | 2018-04-26T01:54:42.000Z | 2018-04-26T01:54:42.000Z | # coding: utf-8
import requests
from .auth import Auth
from .error import IsbitClientError
class IsbitClient:
def __init__(self, endpoint = "https://isbit.co", access_key = None, secret_key = None, timeout = 60):
self.endpoint = endpoint
self.timeout = timeout
if access_key and secret_key:
self.ac... | 33.232558 | 133 | 0.664801 | 372 | 2,858 | 5.016129 | 0.276882 | 0.051447 | 0.057878 | 0.04716 | 0.338156 | 0.314577 | 0.303323 | 0.303323 | 0.303323 | 0.282958 | 0 | 0.013581 | 0.227082 | 2,858 | 85 | 134 | 33.623529 | 0.831145 | 0.154304 | 0 | 0.42623 | 0 | 0 | 0.111943 | 0 | 0 | 0 | 0 | 0.011765 | 0 | 1 | 0.098361 | false | 0 | 0.04918 | 0 | 0.229508 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca566d866cfaf328370cd633628f3e726956144c | 14,520 | py | Python | packages/selinux-policy/selinux-policy/policy/flask/flask.py | d3vilbox/CLIP | f4e5858fb4345af71c1f92360067cf4c2bb1145d | [
"Apache-2.0"
] | 8 | 2015-07-23T16:26:14.000Z | 2021-12-22T15:40:32.000Z | packages/selinux-policy/selinux-policy/policy/flask/flask.py | d3vilbox/CLIP | f4e5858fb4345af71c1f92360067cf4c2bb1145d | [
"Apache-2.0"
] | 56 | 2015-03-01T00:12:54.000Z | 2019-05-30T13:37:02.000Z | packages/selinux-policy/selinux-policy/policy/flask/flask.py | d3vilbox/CLIP | f4e5858fb4345af71c1f92360067cf4c2bb1145d | [
"Apache-2.0"
] | 8 | 2015-04-23T20:14:20.000Z | 2022-01-11T15:57:35.000Z | #!/usr/bin/python -E
#
# Author(s): Caleb Case <ccase@tresys.com>
#
# Adapted from the bash/awk scripts mkflask.sh and mkaccess_vector.sh
#
import getopt
import os
import sys
import re
class ParseError(Exception):
def __init__(self, type, file, line):
self.type = type
self.file = file
self.line = line
def __s... | 27.039106 | 168 | 0.62562 | 2,003 | 14,520 | 4.47329 | 0.132801 | 0.059487 | 0.01875 | 0.020313 | 0.417634 | 0.361272 | 0.329464 | 0.303125 | 0.282254 | 0.255469 | 0 | 0.004852 | 0.219284 | 14,520 | 536 | 169 | 27.089552 | 0.78555 | 0.027755 | 0 | 0.406699 | 0 | 0.007177 | 0.167863 | 0.017164 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.009569 | null | null | 0.016746 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca5b25853b7d494d7c1aed1f445601415885939c | 4,194 | py | Python | modules/HGNN.py | benywon/ComQA | 6731d63d16b731d6c3654b2dc7d2503cf333127f | [
"Apache-2.0"
] | 15 | 2021-01-16T09:48:56.000Z | 2022-03-12T07:22:40.000Z | modules/HGNN.py | benywon/ComQA | 6731d63d16b731d6c3654b2dc7d2503cf333127f | [
"Apache-2.0"
] | null | null | null | modules/HGNN.py | benywon/ComQA | 6731d63d16b731d6c3654b2dc7d2503cf333127f | [
"Apache-2.0"
] | 5 | 2021-01-16T10:15:56.000Z | 2021-11-19T06:30:25.000Z | # -*- coding: utf-8 -*-
"""
@Time : 2021/1/14 下午5:21
@FileName: HGNN.py
@author: 王炳宁
@contact: wangbingning@sogou-inc.com
"""
from modules.BERT import *
class HGNN(Transformer):
def __init__(self, vocab_size, n_embedding, n_hidden, n_layer, n_head, aggregation='fused', M=2):
super().__init__(vocab... | 49.341176 | 161 | 0.670482 | 566 | 4,194 | 4.630742 | 0.215548 | 0.048073 | 0.109882 | 0.036627 | 0.39794 | 0.338802 | 0.294926 | 0.294926 | 0.260588 | 0.210607 | 0 | 0.008027 | 0.227706 | 4,194 | 84 | 162 | 49.928571 | 0.801173 | 0.030997 | 0 | 0.058824 | 0 | 0 | 0.003703 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.088235 | false | 0.073529 | 0.014706 | 0 | 0.205882 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
ca5da68655dc6005ca80bde3ca660b6242302dcf | 239 | py | Python | ex012.py | danieldf0l/exercicios-curso-python3 | 8f8a0e2467efee855da47ea47a4c2f4fda152c41 | [
"MIT"
] | null | null | null | ex012.py | danieldf0l/exercicios-curso-python3 | 8f8a0e2467efee855da47ea47a4c2f4fda152c41 | [
"MIT"
] | null | null | null | ex012.py | danieldf0l/exercicios-curso-python3 | 8f8a0e2467efee855da47ea47a4c2f4fda152c41 | [
"MIT"
] | null | null | null | valorProduto = float(input('Insira o valor do produto: R$'))
porcentagem = int(input('Insira a % de desconto deste produto: '))
valorDesconto = porcentagem*valorProduto/100
print(f'O valor final é de: R${valorProduto-valorDesconto:.2f} ')
| 47.8 | 66 | 0.748954 | 33 | 239 | 5.424242 | 0.666667 | 0.122905 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.018957 | 0.117155 | 239 | 4 | 67 | 59.75 | 0.829384 | 0 | 0 | 0 | 0 | 0 | 0.51046 | 0.142259 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.25 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca69395114c87f448de9c83e655ff072594aacce | 1,528 | py | Python | ano_bissexto.py | Fabiano23/exercicios_python | e23119442ff58a0671992707355b3214452a7c19 | [
"MIT"
] | 1 | 2021-07-07T09:41:23.000Z | 2021-07-07T09:41:23.000Z | ano_bissexto.py | Fabiano23/exercicios_python | e23119442ff58a0671992707355b3214452a7c19 | [
"MIT"
] | null | null | null | ano_bissexto.py | Fabiano23/exercicios_python | e23119442ff58a0671992707355b3214452a7c19 | [
"MIT"
] | null | null | null | # Função que recebe um ano como argumento e retorna se ele é/foi ou não bissexto.
# Pegando o ano atual da máquina local com o método data da biblioteca datetime
# O objetivo é ajustar frase da função de acordo com o ano no momento de sua execução
from datetime import date
ano_atual = date.today().year
def ano_b... | 32.510638 | 105 | 0.655759 | 253 | 1,528 | 3.893281 | 0.355731 | 0.054822 | 0.063959 | 0.060914 | 0.317767 | 0.218274 | 0.218274 | 0.218274 | 0.218274 | 0.218274 | 0 | 0.113142 | 0.248037 | 1,528 | 46 | 106 | 33.217391 | 0.744125 | 0.363874 | 0 | 0.111111 | 0 | 0 | 0.123932 | 0 | 0 | 0 | 0 | 0.021739 | 0 | 1 | 0.055556 | false | 0 | 0.055556 | 0 | 0.333333 | 0.111111 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca69c1dc54beacf0cd14e7d37d71e1e9fe8512bf | 1,428 | py | Python | sample-charge-payment.py | netosjb/febraban-python | a546fa3353d2db1546df60f6f8cc26c7c862c743 | [
"MIT"
] | 7 | 2019-07-16T11:31:50.000Z | 2019-07-29T19:49:50.000Z | sample-charge-payment.py | netosjb/febraban-python | a546fa3353d2db1546df60f6f8cc26c7c862c743 | [
"MIT"
] | 4 | 2020-05-07T15:34:21.000Z | 2020-11-12T21:09:34.000Z | sample-charge-payment.py | netosjb/febraban-python | a546fa3353d2db1546df60f6f8cc26c7c862c743 | [
"MIT"
] | 6 | 2019-12-04T00:40:10.000Z | 2020-11-05T18:39:40.000Z |
# coding: utf-8
from febraban.cnab240.itau.sispag import ChargePayment, File
from febraban.cnab240.itau.sispag.file.lot import Lot
from febraban.cnab240.libs.barCode import BarCodeJ
from febraban.cnab240.user import User, UserAddress, UserBank
sender = User(
name="YOUR COMPANY NAME HERE",
identifier="123456... | 21.969231 | 61 | 0.696078 | 135 | 1,428 | 7.362963 | 0.562963 | 0.04829 | 0.076459 | 0.046278 | 0.05835 | 0 | 0 | 0 | 0 | 0 | 0 | 0.216124 | 0.183473 | 1,428 | 64 | 62 | 22.3125 | 0.636364 | 0.009104 | 0 | 0.06 | 0 | 0 | 0.221828 | 0.093551 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.08 | 0 | 0.08 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca6b75fb076e531a55f378ff7ee6122cea64040d | 338 | py | Python | setup.py | SNUDerek/MLPy | 0d47a8ef8522a663716cda6a831855e6482069ba | [
"MIT"
] | 1 | 2019-05-10T10:39:12.000Z | 2019-05-10T10:39:12.000Z | setup.py | SNUDerek/MLPy | 0d47a8ef8522a663716cda6a831855e6482069ba | [
"MIT"
] | null | null | null | setup.py | SNUDerek/MLPy | 0d47a8ef8522a663716cda6a831855e6482069ba | [
"MIT"
] | null | null | null | from setuptools import find_packages, setup
setup(name='mlpy',
version='0.1.0',
description='an educational python-based ML library',
url='https://github.com/SNUDerek/MLPy',
author='Derek Hommel',
author_email='dsh9470@snu.ac.kr',
# license='MIT',
packages=find_packages(),
... | 30.727273 | 59 | 0.653846 | 43 | 338 | 5.046512 | 0.837209 | 0.110599 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.025926 | 0.201183 | 338 | 11 | 60 | 30.727273 | 0.777778 | 0.04142 | 0 | 0 | 0 | 0 | 0.334365 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.111111 | 0 | 0.111111 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca73c43e7029be2bc0db6db08adf38420ae8adb2 | 108,503 | py | Python | astrobase/cpserver/checkplotserver_handlers.py | adrn/astrobase | 7af71167deec58dffc8f668c0b34cb75ed44ae6a | [
"MIT"
] | null | null | null | astrobase/cpserver/checkplotserver_handlers.py | adrn/astrobase | 7af71167deec58dffc8f668c0b34cb75ed44ae6a | [
"MIT"
] | null | null | null | astrobase/cpserver/checkplotserver_handlers.py | adrn/astrobase | 7af71167deec58dffc8f668c0b34cb75ed44ae6a | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
'''checkplotserver_handlers.py - Waqas Bhatti (wbhatti@astro.princeton.edu) -
Jan 2017
These are Tornado handlers for serving checkplots and operating on them.
'''
####################
## SYSTEM IMPORTS ##
####################
import os... | 38.421742 | 83 | 0.398772 | 7,749 | 108,503 | 5.546264 | 0.117951 | 0.01303 | 0.014589 | 0.011238 | 0.504863 | 0.45514 | 0.429545 | 0.410699 | 0.382987 | 0.369468 | 0 | 0.007875 | 0.516677 | 108,503 | 2,823 | 84 | 38.435352 | 0.811659 | 0.13854 | 0 | 0.52238 | 0 | 0 | 0.110602 | 0 | 0 | 0 | 0 | 0.002125 | 0 | 1 | 0.006799 | false | 0.000567 | 0.019263 | 0 | 0.032295 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca76bc65ab4822731e1123151088537f3a768d67 | 496 | py | Python | ITE-428/collection2/list4.py | richeyphu/ITE-428-LAB | c68fdddb7bbfa8b74a58a0b26bdcb4565af3b08b | [
"MIT"
] | 1 | 2021-07-14T11:12:19.000Z | 2021-07-14T11:12:19.000Z | ITE-428/collection2/list4.py | richeyphu/ITE-428-LAB | c68fdddb7bbfa8b74a58a0b26bdcb4565af3b08b | [
"MIT"
] | null | null | null | ITE-428/collection2/list4.py | richeyphu/ITE-428-LAB | c68fdddb7bbfa8b74a58a0b26bdcb4565af3b08b | [
"MIT"
] | null | null | null | # สร้าง list
def detail(data): # data รับมาเป็น list
for i in data:
print("{}".format(i))
score = []
print("{}".format(score))
print("{}".format(type(score)))
for i in range(5):
x = int(input('Enter Score : '))
score.append(x)
print("{}".format(score))
detail(score)
# List Com... | 19.84 | 45 | 0.546371 | 79 | 496 | 3.468354 | 0.493671 | 0.240876 | 0.087591 | 0.120438 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.057292 | 0.225806 | 496 | 24 | 46 | 20.666667 | 0.648438 | 0.135081 | 0 | 0.133333 | 0 | 0 | 0.065 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.066667 | false | 0 | 0 | 0 | 0.066667 | 0.4 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca79cdc146bef3109d244ed3ab2b9c065509c9da | 1,121 | py | Python | RLBotPack/DisasterBot/mechanic/drive_navigate_boost/drive_navigate_boost.py | L0laapk3/RLBotPack | f54038475d2a57428f3784560755f96bfcf8015f | [
"MIT"
] | 13 | 2019-05-25T20:25:51.000Z | 2022-03-19T13:36:23.000Z | RLBotPack/DisasterBot/mechanic/drive_navigate_boost/drive_navigate_boost.py | L0laapk3/RLBotPack | f54038475d2a57428f3784560755f96bfcf8015f | [
"MIT"
] | 53 | 2019-06-07T13:31:59.000Z | 2022-03-28T22:53:47.000Z | RLBotPack/DisasterBot/mechanic/drive_navigate_boost/drive_navigate_boost.py | L0laapk3/RLBotPack | f54038475d2a57428f3784560755f96bfcf8015f | [
"MIT"
] | 78 | 2019-06-30T08:42:13.000Z | 2022-03-23T20:11:42.000Z | from rlbot.agents.base_agent import SimpleControllerState
from mechanic.base_mechanic import BaseMechanic
from mechanic.drive_arrive_in_time import DriveArriveInTime
from skeleton.util.structure import Player
from util.linear_algebra import norm, flatten
from util.path_finder import find_fastest_path, first_target, p... | 41.518519 | 119 | 0.756467 | 154 | 1,121 | 5.253247 | 0.435065 | 0.055624 | 0.014833 | 0.014833 | 0.007417 | 0 | 0 | 0 | 0 | 0 | 0 | 0.012685 | 0.156111 | 1,121 | 26 | 120 | 43.115385 | 0.842495 | 0.013381 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.117647 | false | 0 | 0.411765 | 0 | 0.647059 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
ca81b7c423dae5c724c6d9e39c2defc49b577e03 | 383 | py | Python | django_statsd/__init__.py | techdragon/django-dogstatsd | 9b766c2006efe8e7fa1fa9fdae1bfc9441e67401 | [
"BSD-2-Clause"
] | null | null | null | django_statsd/__init__.py | techdragon/django-dogstatsd | 9b766c2006efe8e7fa1fa9fdae1bfc9441e67401 | [
"BSD-2-Clause"
] | null | null | null | django_statsd/__init__.py | techdragon/django-dogstatsd | 9b766c2006efe8e7fa1fa9fdae1bfc9441e67401 | [
"BSD-2-Clause"
] | null | null | null | from django_statsd.middleware import (
decr,
incr,
start,
stop,
with_,
wrapper,
named_wrapper,
decorator,
)
from django_statsd import redis, celery, json, templates
__all__ = [
'decr',
'incr',
'start',
'stop',
'with_',
'wrapper',
'named_wrapper',
'decorat... | 14.185185 | 56 | 0.556136 | 36 | 383 | 5.638889 | 0.5 | 0.098522 | 0.157635 | 0.167488 | 0.482759 | 0.482759 | 0.482759 | 0.482759 | 0.482759 | 0 | 0 | 0 | 0.305483 | 383 | 26 | 57 | 14.730769 | 0.763158 | 0 | 0 | 0 | 0 | 0 | 0.195822 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.08 | 0 | 0.08 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca8775ba2d0a296a6b19f3e42c5ee5e8c02436df | 533 | py | Python | dataflow/multi_gen/vis.py | violin-1/test | 5f63a3ab093ad9366afa2bdb2307ac88349fdb69 | [
"MIT"
] | null | null | null | dataflow/multi_gen/vis.py | violin-1/test | 5f63a3ab093ad9366afa2bdb2307ac88349fdb69 | [
"MIT"
] | null | null | null | dataflow/multi_gen/vis.py | violin-1/test | 5f63a3ab093ad9366afa2bdb2307ac88349fdb69 | [
"MIT"
] | null | null | null | def set_vis_args(datactr):
from visualizer.OpencvVis import CVis
datactr.vis = CVis(grab_pcl_fuc=datactr.get_data,
switch_model_func=datactr.switch_model,
switch_dataset_func=datactr.switch_dataset,
switch_pcl_func=datactr.switc... | 44.416667 | 71 | 0.596623 | 59 | 533 | 5.016949 | 0.474576 | 0.148649 | 0.172297 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.002857 | 0.34334 | 533 | 12 | 72 | 44.416667 | 0.842857 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.083333 | false | 0.083333 | 0.083333 | 0 | 0.166667 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
ca8ba786ce49e5e98beba866b1cb29033e6a9fa9 | 7,561 | py | Python | lang/pascal/pascal.py | daveweij/knausj_talon | 37c1124d842e5fac7862f79ea942d6a3d468d5df | [
"MIT"
] | null | null | null | lang/pascal/pascal.py | daveweij/knausj_talon | 37c1124d842e5fac7862f79ea942d6a3d468d5df | [
"MIT"
] | null | null | null | lang/pascal/pascal.py | daveweij/knausj_talon | 37c1124d842e5fac7862f79ea942d6a3d468d5df | [
"MIT"
] | null | null | null | from talon import Context, Module, actions, settings
mod = Module()
ctx = Context()
ctx.matches = r"""
mode: user.pascal
mode: command
and code.language: pascal
"""
ctx.lists["self.pascal_types"] = {
"character": "char",
"char": "char",
"string": "string",
"int": "Integer",
"integer": "Integer",... | 33.604444 | 89 | 0.634572 | 891 | 7,561 | 5.117845 | 0.180696 | 0.0875 | 0.149123 | 0.122807 | 0.542105 | 0.500877 | 0.36864 | 0.270833 | 0.205044 | 0.159649 | 0 | 0.000672 | 0.213067 | 7,561 | 224 | 90 | 33.754464 | 0.765714 | 0.073403 | 0 | 0.229947 | 0 | 0 | 0.142613 | 0.019966 | 0 | 0 | 0 | 0.004464 | 0 | 1 | 0.331551 | false | 0 | 0.016043 | 0 | 0.368984 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca8c2d1e947f507c05f0c2a0590fffcbeb496655 | 149 | py | Python | Others/tenka1/tenka1-2013-qualb/a.py | KATO-Hiro/AtCoder | cbbdb18e95110b604728a54aed83a6ed6b993fde | [
"CC0-1.0"
] | 2 | 2020-06-12T09:54:23.000Z | 2021-05-04T01:34:07.000Z | Others/tenka1/tenka1-2013-qualb/a.py | KATO-Hiro/AtCoder | cbbdb18e95110b604728a54aed83a6ed6b993fde | [
"CC0-1.0"
] | 961 | 2020-06-23T07:26:22.000Z | 2022-03-31T21:34:52.000Z | Others/tenka1/tenka1-2013-qualb/a.py | KATO-Hiro/AtCoder | cbbdb18e95110b604728a54aed83a6ed6b993fde | [
"CC0-1.0"
] | null | null | null | # -*- coding: utf-8 -*-
def main():
s = sorted([input() for _ in range(15)])
print(s[6])
if __name__ == '__main__':
main()
| 13.545455 | 45 | 0.47651 | 19 | 149 | 3.263158 | 0.842105 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.038835 | 0.308725 | 149 | 10 | 46 | 14.9 | 0.563107 | 0.14094 | 0 | 0 | 0 | 0 | 0.068966 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.2 | false | 0 | 0 | 0 | 0.2 | 0.2 | 1 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca8dac6cdcc434eb39f3fe996c4a6172516d1ba7 | 13,326 | py | Python | SRC/common/EXTRA/gfxprof.py | usnistgov/OOF3D | 4fd423a48aea9c5dc207520f02de53ae184be74c | [
"X11"
] | 31 | 2015-04-01T15:59:36.000Z | 2022-03-18T20:21:47.000Z | SRC/common/EXTRA/gfxprof.py | usnistgov/OOF3D | 4fd423a48aea9c5dc207520f02de53ae184be74c | [
"X11"
] | 3 | 2015-02-06T19:30:24.000Z | 2017-05-25T14:14:31.000Z | SRC/common/EXTRA/gfxprof.py | usnistgov/OOF3D | 4fd423a48aea9c5dc207520f02de53ae184be74c | [
"X11"
] | 7 | 2015-01-23T15:19:22.000Z | 2021-06-09T09:03:59.000Z | # -*- python -*-
# This software was produced by NIST, an agency of the U.S. government,
# and by statute is not subject to copyright in the United States.
# Recipients of this software assume all responsibilities associated
# with its operation, modification and maintenance. However, to
# facilitate maintenance we as... | 36.60989 | 84 | 0.613162 | 1,587 | 13,326 | 5.080655 | 0.221172 | 0.020092 | 0.009922 | 0.00893 | 0.263177 | 0.218281 | 0.142379 | 0.086816 | 0.062012 | 0.020836 | 0 | 0.016642 | 0.278553 | 13,326 | 363 | 85 | 36.710744 | 0.82203 | 0.122918 | 0 | 0.216028 | 0 | 0 | 0.039914 | 0 | 0 | 0 | 0 | 0 | 0.003484 | 0 | null | null | 0.017422 | 0.017422 | null | null | 0.006969 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ca96967c674696af50d2b10b2b24ea137a226706 | 519 | py | Python | apps/accounts/migrations/0006_account_team.py | spiperac/bctf | 136abee0b7c3f9b3dd31bb341d53e8f4c58ebea5 | [
"MIT"
] | 6 | 2019-09-13T18:12:45.000Z | 2020-07-31T19:27:53.000Z | apps/accounts/migrations/0006_account_team.py | spiperac/bctf | 136abee0b7c3f9b3dd31bb341d53e8f4c58ebea5 | [
"MIT"
] | 10 | 2020-02-12T00:12:42.000Z | 2022-03-11T23:47:06.000Z | apps/accounts/migrations/0006_account_team.py | spiperac/bctf | 136abee0b7c3f9b3dd31bb341d53e8f4c58ebea5 | [
"MIT"
] | 7 | 2019-09-13T18:12:50.000Z | 2020-10-13T22:36:10.000Z | # Generated by Django 2.1.2 on 2018-11-19 03:02
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('teams', '0001_initial'),
('accounts', '0005_account_points'),
]
operations = [
migrations.AddField(... | 24.714286 | 121 | 0.626204 | 60 | 519 | 5.333333 | 0.666667 | 0.075 | 0.0875 | 0.1375 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.058524 | 0.242775 | 519 | 20 | 122 | 25.95 | 0.755725 | 0.086705 | 0 | 0 | 1 | 0 | 0.137712 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.142857 | 0 | 0.357143 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
0467a760bfcd6ac7bd5b2f3d28bec70b001733e6 | 2,957 | py | Python | pystache/locator.py | jakearchibald/pystache | b7de415288c2c2a71bdae4d87cbff1f2978b419a | [
"MIT"
] | 1 | 2017-04-01T21:14:38.000Z | 2017-04-01T21:14:38.000Z | pystache/locator.py | jakearchibald/pystache | b7de415288c2c2a71bdae4d87cbff1f2978b419a | [
"MIT"
] | null | null | null | pystache/locator.py | jakearchibald/pystache | b7de415288c2c2a71bdae4d87cbff1f2978b419a | [
"MIT"
] | null | null | null | # coding: utf-8
"""
This module provides a Locator class for finding template files.
"""
import os
import re
import sys
DEFAULT_EXTENSION = 'mustache'
class Locator(object):
def __init__(self, extension=None):
"""
Construct a template locator.
Arguments:
extension: the te... | 26.63964 | 76 | 0.608725 | 368 | 2,957 | 4.692935 | 0.342391 | 0.069485 | 0.036479 | 0.020845 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001964 | 0.311126 | 2,957 | 110 | 77 | 26.881818 | 0.845852 | 0.376395 | 0 | 0.052632 | 0 | 0 | 0.039315 | 0 | 0 | 0 | 0 | 0.018182 | 0 | 1 | 0.184211 | false | 0 | 0.078947 | 0.026316 | 0.5 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
046c65581250a8645814cc360b7124916ac15b57 | 3,791 | py | Python | classifier.py | pankaj5395/clickbait-classifier | 0323b6c2cabfa11171afc6ff62f28dc0ea9f95dc | [
"MIT"
] | 122 | 2015-01-12T03:07:56.000Z | 2022-01-29T09:38:07.000Z | classifier.py | pankaj5395/clickbait-classifier | 0323b6c2cabfa11171afc6ff62f28dc0ea9f95dc | [
"MIT"
] | 4 | 2015-01-12T07:12:10.000Z | 2017-10-24T00:14:23.000Z | classifier.py | pankaj5395/clickbait-classifier | 0323b6c2cabfa11171afc6ff62f28dc0ea9f95dc | [
"MIT"
] | 23 | 2015-01-12T03:52:18.000Z | 2021-09-16T12:21:14.000Z | #!/usr/bin/env python
# coding: utf-8
# Sources for machine learning information / examples:
# http://nbviewer.ipython.org/gist/rjweiss/7158866
# http://scikit-learn.org/stable/modules/feature_extraction.html
# http://www.datarobot.com/blog/classification-with-scikit-learn/
# http://scikit-learn.org/stable/aut... | 35.429907 | 90 | 0.717489 | 519 | 3,791 | 5.025048 | 0.377649 | 0.027607 | 0.019939 | 0.020706 | 0.197853 | 0.084356 | 0.055215 | 0.055215 | 0 | 0 | 0 | 0.013397 | 0.173041 | 3,791 | 106 | 91 | 35.764151 | 0.818501 | 0.22105 | 0 | 0.054795 | 0 | 0 | 0.062351 | 0.00954 | 0 | 0 | 0 | 0.009434 | 0.027397 | 0 | null | null | 0 | 0.164384 | null | null | 0.068493 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04742b86e9ab87b9ab2d5da25c4b8e6079504408 | 3,606 | py | Python | Digital-Signal-Processing/_utils.py | diegoinacio/computer-vision-notebooks | a86c63ab7d4e3cf0397d9962dd09e06151d9ad69 | [
"MIT"
] | 81 | 2020-02-17T22:02:49.000Z | 2022-03-21T16:28:23.000Z | Digital-Signal-Processing/_utils.py | romuloallc/computer-vision-notebooks | 89040e9aaa5a3382173d10efcce11068d5a82d71 | [
"MIT"
] | 10 | 2020-09-03T19:39:12.000Z | 2021-06-22T12:26:02.000Z | Digital-Signal-Processing/_utils.py | romuloallc/computer-vision-notebooks | 89040e9aaa5a3382173d10efcce11068d5a82d71 | [
"MIT"
] | 22 | 2020-05-13T05:56:26.000Z | 2022-02-25T04:20:19.000Z | import matplotlib.pyplot as plt
import matplotlib.gridspec as gridspec
import librosa
import librosa.display
import numpy as np
def summary(x):
if x.ndim == 1:
SUM = ('\n{0:>10s}: {1:>15.4f}').format('min', np.amin(x))
SUM += ('\n{0:>10s}: {1:>15.4f}').format('1st Quar', np.percentile(x, 25))
SUM += ('\n{0:>10s... | 36.795918 | 109 | 0.593455 | 656 | 3,606 | 3.248476 | 0.170732 | 0.039418 | 0.032848 | 0.052557 | 0.753637 | 0.721727 | 0.647583 | 0.611919 | 0.581417 | 0.511028 | 0 | 0.074232 | 0.151969 | 3,606 | 98 | 110 | 36.795918 | 0.622629 | 0 | 0 | 0.549451 | 0 | 0.076923 | 0.211533 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.032967 | false | 0 | 0.054945 | 0 | 0.087912 | 0.054945 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04766d5bea8b917892aaec2710e71e4de4e0ae62 | 1,917 | py | Python | notes1.py | rishabh135/WTM-IITKanpur | 42272cc2cb8f66635e0ba01c9c5fe5bf2d8853a9 | [
"MIT"
] | null | null | null | notes1.py | rishabh135/WTM-IITKanpur | 42272cc2cb8f66635e0ba01c9c5fe5bf2d8853a9 | [
"MIT"
] | null | null | null | notes1.py | rishabh135/WTM-IITKanpur | 42272cc2cb8f66635e0ba01c9c5fe5bf2d8853a9 | [
"MIT"
] | 1 | 2019-10-20T21:37:24.000Z | 2019-10-20T21:37:24.000Z | # Comparisons can be chained!
1 < 2 < 3 # => True
2 < 3 < 2 # => False
1j*1j == -1
# math vs cmath
# Strings are created with " or '; multiline strings with ''' or """
"This is a string."
'This is also a string.'
"""
This is a
multiline
string
"""
pass
# A string can be treated like a list of ... | 17.587156 | 69 | 0.558164 | 334 | 1,917 | 3.164671 | 0.353293 | 0.013245 | 0.02649 | 0.036897 | 0.057711 | 0.029328 | 0.029328 | 0.029328 | 0 | 0 | 0 | 0.053199 | 0.274387 | 1,917 | 108 | 70 | 17.75 | 0.706686 | 0.282212 | 0 | 0.060606 | 0 | 0 | 0.14404 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.015152 | 0 | null | null | 0.106061 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04832ff0ad8c6bc3bde47e0ebfeb9d657c53a2a5 | 10,096 | py | Python | wa_simulator/vehicle.py | WisconsinAutonomous/wa_simulator | 405a086b16f262fc82513ca9b23fd040e6375945 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 5 | 2021-02-14T03:56:07.000Z | 2021-12-16T04:46:54.000Z | wa_simulator/vehicle.py | WisconsinAutonomous/wa_simulator | 405a086b16f262fc82513ca9b23fd040e6375945 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 1 | 2021-02-05T19:30:55.000Z | 2021-02-05T19:51:21.000Z | wa_simulator/vehicle.py | WisconsinAutonomous/wa_simulator | 405a086b16f262fc82513ca9b23fd040e6375945 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 3 | 2021-09-20T21:21:12.000Z | 2022-01-09T20:49:46.000Z | """
Wisconsin Autonomous - https://www.wisconsinautonomous.org
Copyright (c) 2021 wisconsinautonomous.org
All rights reserved.
Use of this source code is governed by a BSD-style license that can be found
in the LICENSE file at the top level of the repo
"""
from abc import abstractmethod # Abstract Base Class
# WA ... | 32.358974 | 220 | 0.613312 | 1,289 | 10,096 | 4.580295 | 0.203258 | 0.014397 | 0.01626 | 0.019309 | 0.303015 | 0.236789 | 0.142615 | 0.118902 | 0.118902 | 0.070799 | 0 | 0.007874 | 0.295563 | 10,096 | 311 | 221 | 32.463023 | 0.822272 | 0.340432 | 0 | 0.230769 | 0 | 0 | 0.05157 | 0.007158 | 0 | 0 | 0 | 0.006431 | 0 | 1 | 0.153846 | false | 0.055944 | 0.034965 | 0.041958 | 0.27972 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
048543ad7e3f37b907cebd723141bf6353b4dd1a | 1,658 | py | Python | ustoolbox/utils/io_validations.py | eegkno/ustoolbox | db315ba239daf4a6d776311c161ec85e8cacb804 | [
"MIT"
] | null | null | null | ustoolbox/utils/io_validations.py | eegkno/ustoolbox | db315ba239daf4a6d776311c161ec85e8cacb804 | [
"MIT"
] | 3 | 2018-08-21T21:13:18.000Z | 2018-10-10T22:31:53.000Z | ustoolbox/utils/io_validations.py | eegkno/ustoolbox | db315ba239daf4a6d776311c161ec85e8cacb804 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
import os
def is_accessible(path: str, mode: str = 'r') -> bool:
'''Check if the file at `path` can
be accessed by the program using `mode` open flags.
Parameters
----------
path : str
Path for the file to validate.
mode : str
Returns
-------
T... | 18.629213 | 57 | 0.545838 | 208 | 1,658 | 4.3125 | 0.264423 | 0.078038 | 0.061316 | 0.078038 | 0.618729 | 0.534002 | 0.518395 | 0.373467 | 0.373467 | 0.282051 | 0 | 0.001779 | 0.322075 | 1,658 | 88 | 58 | 18.840909 | 0.796263 | 0.538601 | 0 | 0.210526 | 0 | 0 | 0.001776 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.263158 | false | 0 | 0.052632 | 0 | 0.684211 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
0487cc2743649a223b14802d4c915775fc57aadd | 2,079 | py | Python | problems/problem17.py | Julien-Verdun/Project-Euler | 94b073a9e4593960fcd74e678951bc27009e34f9 | [
"MIT"
] | null | null | null | problems/problem17.py | Julien-Verdun/Project-Euler | 94b073a9e4593960fcd74e678951bc27009e34f9 | [
"MIT"
] | null | null | null | problems/problem17.py | Julien-Verdun/Project-Euler | 94b073a9e4593960fcd74e678951bc27009e34f9 | [
"MIT"
] | null | null | null | # Problem 17 : Number letter counts
liste_digit_letter = ['one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine', 'ten',
'eleven', 'twelve', 'thirteen', 'fourteen', 'fifteen', 'sixteen', 'seventeen', 'eighteen', 'nineteen']
liste_ten_letter = ['twenty', 'thirty', 'forty',
... | 36.473684 | 141 | 0.630592 | 282 | 2,079 | 4.429078 | 0.340426 | 0.044836 | 0.076861 | 0.045637 | 0.152922 | 0.040032 | 0 | 0 | 0 | 0 | 0 | 0.034593 | 0.249158 | 2,079 | 56 | 142 | 37.125 | 0.765535 | 0 | 0 | 0.057143 | 0 | 0 | 0.11037 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | null | null | 0.057143 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04a1aeb53b360272dbf617393c82238dc9a739b5 | 6,985 | py | Python | hz/sbb/api.py | oskopek/hackzurich-surprise_pass | f57242b646880d8dc147fc8a33c007c9bceb901d | [
"MIT"
] | null | null | null | hz/sbb/api.py | oskopek/hackzurich-surprise_pass | f57242b646880d8dc147fc8a33c007c9bceb901d | [
"MIT"
] | null | null | null | hz/sbb/api.py | oskopek/hackzurich-surprise_pass | f57242b646880d8dc147fc8a33c007c9bceb901d | [
"MIT"
] | null | null | null | import requests
import json
import warnings
WEATHER_KEY = "TODO_KEY"
WEATHER_API = "http://api.openweathermap.org/data/2.5/"
API_URL = "https://b2p-int.api.sbb.ch/api/"
CLIENT_ID = "22ebc2be"
CLIENT_SECRET = "TODO_KEY"
CONTRACT_ID = "HAC222P"
AUTH_HEADERS = {"grant_type": "client_credentials", "client_id": CLIENT_ID... | 36.763158 | 121 | 0.641518 | 929 | 6,985 | 4.64155 | 0.250807 | 0.039425 | 0.006957 | 0.013915 | 0.168831 | 0.130334 | 0.115955 | 0.100186 | 0.080241 | 0.080241 | 0 | 0.018129 | 0.210308 | 6,985 | 189 | 122 | 36.957672 | 0.763597 | 0.065283 | 0 | 0.109489 | 0 | 0.029197 | 0.236458 | 0.058923 | 0 | 0 | 0 | 0.005291 | 0 | 1 | 0.058394 | false | 0.051095 | 0.043796 | 0 | 0.189781 | 0.021898 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
04a4bc96c0253c76cf7aa4aa9d5a7c5b52f98f4d | 508 | py | Python | util/inst-gen.py | ronaldosvieira/threads-life | 7c36d2a745d7a7dd65280bd111f3d91c6208eed9 | [
"MIT"
] | null | null | null | util/inst-gen.py | ronaldosvieira/threads-life | 7c36d2a745d7a7dd65280bd111f3d91c6208eed9 | [
"MIT"
] | null | null | null | util/inst-gen.py | ronaldosvieira/threads-life | 7c36d2a745d7a7dd65280bd111f3d91c6208eed9 | [
"MIT"
] | null | null | null | from random import random
file = raw_input("Nome do arquivo: ")
size = input("Tamanho da instancia: ")
step = input("Quantidade de passos: ")
with open('examples/' + str(file), 'w') as inst:
inst.write(str(size) + " " + str(step) + "\n")
data = ""
for i in range(0, int(size)):
for j in range(... | 25.4 | 50 | 0.470472 | 63 | 508 | 3.777778 | 0.603175 | 0.07563 | 0.067227 | 0.092437 | 0.12605 | 0 | 0 | 0 | 0 | 0 | 0 | 0.012422 | 0.366142 | 508 | 20 | 51 | 25.4 | 0.726708 | 0 | 0 | 0 | 0 | 0 | 0.153242 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.066667 | 0.066667 | 0 | 0.066667 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
04a6fa461ade18b9d19c56af35b0cdcc8befc641 | 691 | py | Python | src/tests/genetic_param_sampler_test.py | ZmeiGorynych/generative_playground | 5c336dfbd14235e4fd97b21778842a650e733275 | [
"MIT"
] | 9 | 2018-09-23T17:34:23.000Z | 2021-07-29T09:48:55.000Z | src/tests/genetic_param_sampler_test.py | ZmeiGorynych/generative_playground | 5c336dfbd14235e4fd97b21778842a650e733275 | [
"MIT"
] | 2 | 2020-04-15T17:52:18.000Z | 2020-04-15T18:26:27.000Z | src/tests/genetic_param_sampler_test.py | ZmeiGorynych/generative_playground | 5c336dfbd14235e4fd97b21778842a650e733275 | [
"MIT"
] | 6 | 2019-04-30T22:01:43.000Z | 2021-11-22T02:20:18.000Z | import random
import numpy as np
import os, sys, inspect
from unittest import TestCase
from generative_playground.models.param_sampler import ParameterSampler, extract_params_rewards, values_to_percentiles
my_location = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
test_root = os.path.real... | 36.368421 | 118 | 0.777135 | 87 | 691 | 5.965517 | 0.551724 | 0.100193 | 0.077071 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001656 | 0.125904 | 691 | 19 | 119 | 36.368421 | 0.857616 | 0 | 0 | 0 | 0 | 0 | 0.114162 | 0.106936 | 0 | 0 | 0 | 0 | 0 | 1 | 0.071429 | false | 0 | 0.357143 | 0 | 0.5 | 0.071429 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
04a9679782184c6400853bd82285e9b2ae7c3b63 | 2,374 | py | Python | api/management/commands/update-sovereign-and-disputed.py | IFRCGo/ifrcgo-api | c1c3e0cf1076ab48d03db6aaf7a00f8485ca9e1a | [
"MIT"
] | 11 | 2018-06-11T06:05:12.000Z | 2022-03-25T09:31:44.000Z | api/management/commands/update-sovereign-and-disputed.py | IFRCGo/ifrcgo-api | c1c3e0cf1076ab48d03db6aaf7a00f8485ca9e1a | [
"MIT"
] | 498 | 2017-11-07T21:20:13.000Z | 2022-03-31T14:37:18.000Z | api/management/commands/update-sovereign-and-disputed.py | IFRCGo/ifrcgo-api | c1c3e0cf1076ab48d03db6aaf7a00f8485ca9e1a | [
"MIT"
] | 6 | 2018-04-11T13:29:50.000Z | 2020-07-16T16:52:11.000Z | import csv
from django.core.management.base import BaseCommand, CommandError
from django.core.exceptions import ObjectDoesNotExist, MultipleObjectsReturned
from django.db import transaction
from api.models import Country
class Command(BaseCommand):
help = "update the sovereign country and disputed status for all the... | 38.918033 | 162 | 0.675232 | 298 | 2,374 | 5.147651 | 0.315436 | 0.200782 | 0.070404 | 0.073012 | 0.276402 | 0.123859 | 0.074316 | 0.074316 | 0.074316 | 0.074316 | 0 | 0.002194 | 0.232098 | 2,374 | 60 | 163 | 39.566667 | 0.839276 | 0.062763 | 0 | 0.045455 | 0 | 0.022727 | 0.147497 | 0.013081 | 0 | 0 | 0 | 0 | 0 | 1 | 0.045455 | false | 0 | 0.113636 | 0 | 0.227273 | 0.045455 | 0 | 0 | 0 | null | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04ab32c64ee9425bffa24f6ee2d3618a4f6e7f5e | 281 | py | Python | Python/Learning/Tips/coroutine.py | prynix/learning-programming | 85aea40a61fb824a2b4e142331d9ac7971fef263 | [
"MIT"
] | 2 | 2017-03-14T16:02:08.000Z | 2017-05-02T13:48:18.000Z | Python/Learning/Tips/coroutine.py | CajetanP/learning-programming | 85aea40a61fb824a2b4e142331d9ac7971fef263 | [
"MIT"
] | 4 | 2021-05-20T21:10:13.000Z | 2022-02-26T09:50:19.000Z | Python/Learning/Tips/coroutine.py | CajetanP/learning-programming | 85aea40a61fb824a2b4e142331d9ac7971fef263 | [
"MIT"
] | 1 | 2021-06-18T01:31:24.000Z | 2021-06-18T01:31:24.000Z |
def grep(pattern):
print("Searching for", pattern)
while True:
line = (yield)
if pattern in line:
print(line)
search = grep('coroutine')
next(search)
search.send("I love you")
search.send("Don't you love me")
search.send("I love coroutines")
| 18.733333 | 35 | 0.622776 | 39 | 281 | 4.487179 | 0.589744 | 0.171429 | 0.125714 | 0.171429 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.241993 | 281 | 14 | 36 | 20.071429 | 0.821596 | 0 | 0 | 0 | 0 | 0 | 0.235714 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.090909 | false | 0 | 0 | 0 | 0.090909 | 0.181818 | 0 | 0 | 0 | null | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
04b025f0866f0f61843b0ee3a04fb9e1f6f190ae | 1,570 | py | Python | Level22_drawPicture.py | z-Wind/Python_Challenge | be91ed491be57a1b9bf4b6d6bcb8ca23f48ef81b | [
"MIT"
] | null | null | null | Level22_drawPicture.py | z-Wind/Python_Challenge | be91ed491be57a1b9bf4b6d6bcb8ca23f48ef81b | [
"MIT"
] | null | null | null | Level22_drawPicture.py | z-Wind/Python_Challenge | be91ed491be57a1b9bf4b6d6bcb8ca23f48ef81b | [
"MIT"
] | null | null | null | # http://www.pythonchallenge.com/pc/hex/copper.html
__author__ = 'Administrator'
import urllib.request
from io import BytesIO
from PIL import Image,ImageSequence
def opener(username, password):
# User Name & Password
password_mgr = urllib.request.HTTPPasswordMgrWithDefaultRealm()
top_level_url =... | 30.192308 | 95 | 0.63121 | 224 | 1,570 | 4.357143 | 0.366071 | 0.079918 | 0.067623 | 0.076844 | 0.104508 | 0.104508 | 0.043033 | 0 | 0 | 0 | 0 | 0.057785 | 0.206369 | 1,570 | 52 | 96 | 30.192308 | 0.725522 | 0.063057 | 0 | 0.051282 | 0 | 0 | 0.076977 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.025641 | false | 0.102564 | 0.076923 | 0 | 0.128205 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 1 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.