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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
397c061fa7c5a196ef92439c8738b332eab59630 | 933 | py | Python | drones/taskapp/tasks.py | DiazRock/drones-musala | ef88f5e14a92c49a9682eddbfbde9ce291e5b765 | [
"MIT"
] | null | null | null | drones/taskapp/tasks.py | DiazRock/drones-musala | ef88f5e14a92c49a9682eddbfbde9ce291e5b765 | [
"MIT"
] | null | null | null | drones/taskapp/tasks.py | DiazRock/drones-musala | ef88f5e14a92c49a9682eddbfbde9ce291e5b765 | [
"MIT"
] | null | null | null | """Celery tasks."""
# Django
from django.conf import settings
from django.template.loader import render_to_string
from django.utils import timezone
#Model
from drones.api.models import Drone
# Celery
from celery.decorators import task, periodic_task
from celery.task.schedules import crontab
from celery.utils.log imp... | 26.657143 | 119 | 0.737406 | 139 | 933 | 4.820144 | 0.482014 | 0.089552 | 0.038806 | 0.059701 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.006297 | 0.148982 | 933 | 34 | 120 | 27.441176 | 0.837531 | 0.125402 | 0 | 0 | 0 | 0 | 0.179551 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.052632 | false | 0 | 0.421053 | 0 | 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 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 1 |
3984b8faf301fae1483a27ec05cbde00e131bae7 | 9,182 | py | Python | gsuite/calendarsync/CES_calendar.py | futurice/futuit-hacks | 8e6d842a1731d88a7507613bd25a4b19fa87a0e5 | [
"MIT"
] | 3 | 2017-10-23T11:26:38.000Z | 2020-04-15T16:12:30.000Z | gsuite/calendarsync/CES_calendar.py | futurice/futuit-hacks | 8e6d842a1731d88a7507613bd25a4b19fa87a0e5 | [
"MIT"
] | 1 | 2021-02-08T20:29:37.000Z | 2021-02-08T20:29:37.000Z | gsuite/calendarsync/CES_calendar.py | futurice/futuit-hacks | 8e6d842a1731d88a7507613bd25a4b19fa87a0e5 | [
"MIT"
] | 3 | 2017-12-16T02:35:47.000Z | 2020-04-15T16:12:22.000Z | # -*- coding: utf-8 -*-
import datetime
import CES_db
import CES_group
import CES_serviceaccount_googleservice
from apiclient.errors import HttpError
from CES_util import *
from CES_main import CMD_OPTIONS
from local_settings import *
class cesEvent:
def __init__(self, google_event):
logging.debug("Crea... | 46.140704 | 151 | 0.617839 | 1,108 | 9,182 | 4.970217 | 0.223827 | 0.045942 | 0.032686 | 0.018885 | 0.209007 | 0.166697 | 0.152352 | 0.115308 | 0.115308 | 0.103323 | 0 | 0.002237 | 0.269876 | 9,182 | 198 | 152 | 46.373737 | 0.819212 | 0.094968 | 0 | 0.132813 | 0 | 0.007813 | 0.202429 | 0.0031 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.0625 | 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 |
398743551ab74372c0f845e70d22508b791597ff | 4,291 | py | Python | dating_grabber/models.py | onidzelskyi/dating_grabber | 08f27efe6e0a75e76a7b50f7f126fb01de0f5345 | [
"MIT"
] | null | null | null | dating_grabber/models.py | onidzelskyi/dating_grabber | 08f27efe6e0a75e76a7b50f7f126fb01de0f5345 | [
"MIT"
] | null | null | null | dating_grabber/models.py | onidzelskyi/dating_grabber | 08f27efe6e0a75e76a7b50f7f126fb01de0f5345 | [
"MIT"
] | null | null | null | """Define DB models for tables."""
from sqlalchemy import Column, Integer, String, ForeignKey
from sqlalchemy.orm import relationship
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import create_engine
import os
import logging
import configparser
# Logger
logging.basicConfig(level=logging.DEB... | 33.263566 | 104 | 0.614542 | 477 | 4,291 | 5.30608 | 0.230608 | 0.061636 | 0.047412 | 0.034769 | 0.474516 | 0.421177 | 0.398262 | 0.398262 | 0.329514 | 0.25642 | 0 | 0.009276 | 0.24633 | 4,291 | 128 | 105 | 33.523438 | 0.773346 | 0.149382 | 0 | 0.407407 | 0 | 0 | 0.158982 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.098765 | false | 0 | 0.08642 | 0.037037 | 0.679012 | 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 |
398d18d1f1a698d12fd82ba12489ad19b859a498 | 1,765 | py | Python | recipes/Python/576757_Shelllike_datprocessing_using_Popen_pipes/recipe-576757.py | tdiprima/code | 61a74f5f93da087d27c70b2efe779ac6bd2a3b4f | [
"MIT"
] | 2,023 | 2017-07-29T09:34:46.000Z | 2022-03-24T08:00:45.000Z | recipes/Python/576757_Shelllike_datprocessing_using_Popen_pipes/recipe-576757.py | unhacker/code | 73b09edc1b9850c557a79296655f140ce5e853db | [
"MIT"
] | 32 | 2017-09-02T17:20:08.000Z | 2022-02-11T17:49:37.000Z | recipes/Python/576757_Shelllike_datprocessing_using_Popen_pipes/recipe-576757.py | unhacker/code | 73b09edc1b9850c557a79296655f140ce5e853db | [
"MIT"
] | 780 | 2017-07-28T19:23:28.000Z | 2022-03-25T20:39:41.000Z | from io import BytesIO
from subprocess import Popen, PIPE
from os import pipe, fdopen
from threading import Thread
class Pipeable( object ):
def __init__( self ):
self.output = None
def _output( self, input = None ):
return self.output
def __or__( self, right ):
if not isinstance( right, Pipeable ): return No... | 25.57971 | 133 | 0.660623 | 237 | 1,765 | 4.662447 | 0.2827 | 0.072398 | 0.059729 | 0.065158 | 0.164706 | 0.124887 | 0.074208 | 0.074208 | 0 | 0 | 0 | 0.005751 | 0.211898 | 1,765 | 68 | 134 | 25.955882 | 0.788641 | 0 | 0 | 0.237288 | 0 | 0 | 0.014164 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.016949 | 0.067797 | null | null | 0.016949 | 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 |
398e4f07e0b6085b6a2e68e1f995479425be2592 | 276 | py | Python | client.py | hholst80/python-rpc | e9db39ae2693925f603cd394639253182a7d5f3f | [
"Unlicense"
] | 3 | 2017-04-27T12:53:03.000Z | 2018-09-13T07:15:22.000Z | client.py | hholst80/python-rpc | e9db39ae2693925f603cd394639253182a7d5f3f | [
"Unlicense"
] | null | null | null | client.py | hholst80/python-rpc | e9db39ae2693925f603cd394639253182a7d5f3f | [
"Unlicense"
] | null | null | null | from pprint import pprint
from pyrpc import Client
client = Client()
method = client.reset
print('method: {}'.format(method))
obs = method()
print('observation:')
pprint(obs)
obs = client.reset()
pprint(obs)
a,b,c,d = client.step(0)
pprint(a)
pprint(b)
pprint(c)
pprint(d)
| 14.526316 | 34 | 0.706522 | 43 | 276 | 4.534884 | 0.395349 | 0.123077 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.004149 | 0.126812 | 276 | 18 | 35 | 15.333333 | 0.804979 | 0 | 0 | 0.133333 | 0 | 0 | 0.07971 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.133333 | 0 | 0.133333 | 0.6 | 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 |
3991e4c8993c5757b92296c7cc0842502830a439 | 6,779 | py | Python | src/ai/pushgame.py | mattheuslee/PyPlayer | 0cccff7130be40e3f547b7287e00cbe29e9a5796 | [
"MIT"
] | null | null | null | src/ai/pushgame.py | mattheuslee/PyPlayer | 0cccff7130be40e3f547b7287e00cbe29e9a5796 | [
"MIT"
] | null | null | null | src/ai/pushgame.py | mattheuslee/PyPlayer | 0cccff7130be40e3f547b7287e00cbe29e9a5796 | [
"MIT"
] | null | null | null | import random
import numpy as np
from keras.models import Sequential
from keras.layers import Dense
from keras.optimizers import Adam
class PushGame1D:
NUM_CELLS = 10
PLAYER_VAL = 55
BOX_VAL = 155
TARGET_VAL = 255
def __init__(self):
self.stateSize = self.NUM_CELLS
self.actionSiz... | 38.299435 | 119 | 0.558047 | 861 | 6,779 | 4.335656 | 0.135889 | 0.149746 | 0.073132 | 0.067506 | 0.76614 | 0.726493 | 0.65363 | 0.586124 | 0.5588 | 0.552371 | 0 | 0.035699 | 0.314058 | 6,779 | 176 | 120 | 38.517045 | 0.767097 | 0.076117 | 0 | 0.576159 | 0 | 0 | 0.012348 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.086093 | false | 0 | 0.033113 | 0.013245 | 0.231788 | 0.019868 | 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 |
39a98a22eba480348d7e914a71f7ab9d16223c9e | 395 | py | Python | numbers/prime_factorization.py | Flowerowl/basic_algorithm | b38cd177a6190907bbe87c73b182e63d5c8cafa5 | [
"MIT"
] | null | null | null | numbers/prime_factorization.py | Flowerowl/basic_algorithm | b38cd177a6190907bbe87c73b182e63d5c8cafa5 | [
"MIT"
] | null | null | null | numbers/prime_factorization.py | Flowerowl/basic_algorithm | b38cd177a6190907bbe87c73b182e63d5c8cafa5 | [
"MIT"
] | 3 | 2015-05-11T17:11:42.000Z | 2021-01-09T13:54:33.000Z | #encoding:utf-8
import math
n = 9
i = 2
factors = []
def is_prime(n):
if n % 2 == 0 and n > 2:
return False
return all(n % i for i in range(3, int(math.sqrt(n)) + 1, 2))
while i * i <= n:
while n % i == 0:
n /= i
if is_prime(i):
factors.append(i)
if n > 1:
... | 14.62963 | 65 | 0.478481 | 69 | 395 | 2.695652 | 0.42029 | 0.043011 | 0.086022 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.04918 | 0.382278 | 395 | 26 | 66 | 15.192308 | 0.713115 | 0.035443 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.055556 | null | null | 0.055556 | 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 |
39ade7d2fa5d033aa78fd8d28a0e11a8b087f706 | 5,460 | py | Python | tools/pdtools/pdtools/util.py | lhartung/paradrop-test | 22a491bf3198bf61bcabaedfaecde5b9be97e76f | [
"Apache-2.0"
] | 76 | 2015-08-24T18:15:20.000Z | 2021-12-06T20:03:19.000Z | tools/pdtools/pdtools/util.py | leilei1881/Paradrop | 546464e075f8a226b9eb4fe444390dc5c8527ad9 | [
"Apache-2.0"
] | 35 | 2015-07-07T22:27:49.000Z | 2022-03-01T17:13:40.000Z | tools/pdtools/pdtools/util.py | lhartung/paradrop-test | 22a491bf3198bf61bcabaedfaecde5b9be97e76f | [
"Apache-2.0"
] | 27 | 2016-02-03T22:00:09.000Z | 2021-09-26T16:59:38.000Z | import getpass
import os
import tempfile
import builtins
import yaml
LOCAL_DEFAULT_USERNAME = "paradrop"
LOCAL_DEFAULT_PASSWORD = ""
def format_result(data):
"""
Format a result from an API call for printing.
"""
if data is None or data == []:
return ""
return yaml.safe_dump(data, defau... | 28.4375 | 93 | 0.641758 | 722 | 5,460 | 4.778393 | 0.304709 | 0.010435 | 0.015942 | 0.022029 | 0.187826 | 0.187826 | 0.172754 | 0.155942 | 0.134493 | 0.134493 | 0 | 0.000752 | 0.269414 | 5,460 | 191 | 94 | 28.586387 | 0.864126 | 0.367399 | 0 | 0.27957 | 0 | 0 | 0.100926 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.096774 | false | 0.064516 | 0.053763 | 0 | 0.27957 | 0.010753 | 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 |
39b7229de3ad8398e076841f9b7397c28d7b4b04 | 819 | py | Python | fileupload/urls.py | TunedMystic/django-file-upload | 5a33cebc42e69d18e4f51984fc37f3845f39858b | [
"MIT"
] | null | null | null | fileupload/urls.py | TunedMystic/django-file-upload | 5a33cebc42e69d18e4f51984fc37f3845f39858b | [
"MIT"
] | null | null | null | fileupload/urls.py | TunedMystic/django-file-upload | 5a33cebc42e69d18e4f51984fc37f3845f39858b | [
"MIT"
] | null | null | null | """
Amtex Training Project
"Image Upload Program"
Sandeep Jadoonanan
October 24, 2014
"""
from django.conf.urls import patterns, include, url
from django.contrib import admin
from django.views.generic import TemplateView
from django.conf import settings
urlpatterns = patterns('',
# Ex... | 29.25 | 123 | 0.643468 | 99 | 819 | 5.272727 | 0.545455 | 0.038314 | 0.05364 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.008902 | 0.177045 | 819 | 28 | 124 | 29.25 | 0.765579 | 0.282051 | 0 | 0 | 0 | 0 | 0.204301 | 0.044803 | 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 |
39c19d2da8c6087bdb0fd62a3e4ef1bbf58b738b | 1,922 | py | Python | simulation/sub8_gazebo/diagnostics/set_model_position_test.py | ericgorday/SubjuGator | f45ac790f06eb97efc0b0810a7b43d0a6e2facee | [
"MIT"
] | 27 | 2020-02-17T21:54:09.000Z | 2022-03-18T17:49:23.000Z | simulation/sub8_gazebo/diagnostics/set_model_position_test.py | ericgorday/SubjuGator | f45ac790f06eb97efc0b0810a7b43d0a6e2facee | [
"MIT"
] | 325 | 2019-09-11T14:13:56.000Z | 2022-03-31T00:38:30.000Z | simulation/sub8_gazebo/diagnostics/set_model_position_test.py | ericgorday/SubjuGator | f45ac790f06eb97efc0b0810a7b43d0a6e2facee | [
"MIT"
] | 24 | 2019-09-16T00:29:45.000Z | 2022-03-06T10:56:38.000Z | #!/usr/bin/env python
from __future__ import division
import txros
from nav_msgs.msg import Odometry
from sub8_gazebo.srv import RunJobResponse
from mil_ros_tools import msg_helpers
import job_runner
import tf
from twisted.internet import reactor, defer
import numpy as np
@txros.util.cancellableInlineCallbacks
def ... | 30.03125 | 91 | 0.712279 | 264 | 1,922 | 4.965909 | 0.405303 | 0.073227 | 0.029748 | 0.048055 | 0.053394 | 0 | 0 | 0 | 0 | 0 | 0 | 0.014585 | 0.179501 | 1,922 | 63 | 92 | 30.507937 | 0.816741 | 0.029136 | 0 | 0.108696 | 0 | 0 | 0.059581 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.021739 | 0.195652 | null | null | 0.26087 | 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 |
39ca678e284c82622cf8412d6ce2a36b48f24cfd | 1,366 | py | Python | mpcontribs-api/mpcontribs/api/projects/document.py | josuav1/MPContribs | 3cbf0e83ba6cd749dd4fc988c9f6ad076b05f935 | [
"MIT"
] | 1 | 2019-07-03T04:38:58.000Z | 2019-07-03T04:38:58.000Z | mpcontribs-api/mpcontribs/api/projects/document.py | josuav1/MPContribs | 3cbf0e83ba6cd749dd4fc988c9f6ad076b05f935 | [
"MIT"
] | null | null | null | mpcontribs-api/mpcontribs/api/projects/document.py | josuav1/MPContribs | 3cbf0e83ba6cd749dd4fc988c9f6ad076b05f935 | [
"MIT"
] | 1 | 2019-07-03T04:39:04.000Z | 2019-07-03T04:39:04.000Z | from flask_mongoengine import Document
from mongoengine import fields, DynamicEmbeddedDocument
# DynamicDocument documents work in the same way as Document but any data /
# attributes set to them will also be saved
class Projects(Document):
__project_regex__ = '^[a-zA-Z0-9_]+$'
project = fields.StringField(
... | 36.918919 | 75 | 0.661054 | 160 | 1,366 | 5.4625 | 0.5125 | 0.05492 | 0.05492 | 0.089245 | 0.147597 | 0.147597 | 0.147597 | 0 | 0 | 0 | 0 | 0.012416 | 0.233529 | 1,366 | 36 | 76 | 37.944444 | 0.82235 | 0.153734 | 0 | 0 | 0 | 0 | 0.226759 | 0 | 0 | 0 | 0 | 0.027778 | 0 | 1 | 0 | false | 0 | 0.064516 | 0 | 0.354839 | 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 |
39d8f8608950540254580d5baf99bf552c079b94 | 382 | py | Python | setup.py | liut/mockldap3 | 31fed65bf70990274703303d8fa4bbfd17a4bb16 | [
"MIT"
] | null | null | null | setup.py | liut/mockldap3 | 31fed65bf70990274703303d8fa4bbfd17a4bb16 | [
"MIT"
] | null | null | null | setup.py | liut/mockldap3 | 31fed65bf70990274703303d8fa4bbfd17a4bb16 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
from setuptools import setup
setup(
name = "mockldap3",
version = "0.0.2",
url = 'http://github.com/liut/mockldap3',
license = '',
description = "Mock LDAP for ldap3",
author = 'Eagle Liut',
packages = ['mockldap3'],
keywords=['mock', 'ldap', 'ldap3'],
install... | 18.190476 | 45 | 0.562827 | 40 | 382 | 5.35 | 0.75 | 0.074766 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.031915 | 0.26178 | 382 | 20 | 46 | 19.1 | 0.72695 | 0.052356 | 0 | 0 | 0 | 0 | 0.311111 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
39e7c0d27b05f89e2046d53439eafb61ba16b661 | 682 | py | Python | epi/swap_bits.py | napplebee/EPI | 02732c62b6846d93ebb80e59745e3d3d5e5d337e | [
"MIT"
] | null | null | null | epi/swap_bits.py | napplebee/EPI | 02732c62b6846d93ebb80e59745e3d3d5e5d337e | [
"MIT"
] | null | null | null | epi/swap_bits.py | napplebee/EPI | 02732c62b6846d93ebb80e59745e3d3d5e5d337e | [
"MIT"
] | null | null | null | # 5.2
import random as rnd
def swap_bits(number, i, j):
original_bin = bin(number)
if (number >> i) & 1 == (number >> j) & 1:
return original_bin, original_bin
swapped = number ^ ((1 << i) | (1 << j))
swapped_bin = bin(swapped)
return original_bin, swapped_bin
def test():
inp = inpu... | 24.357143 | 60 | 0.567449 | 100 | 682 | 3.79 | 0.35 | 0.073879 | 0.073879 | 0.079156 | 0.084433 | 0 | 0 | 0 | 0 | 0 | 0 | 0.027778 | 0.260997 | 682 | 27 | 61 | 25.259259 | 0.724206 | 0.004399 | 0 | 0 | 0 | 0 | 0.098966 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.05 | null | null | 0.15 | 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 |
39e8ced298952836221af426b0d8c55eb7eeae18 | 762 | py | Python | tools/bk7231u/gen_firmware_img.py | Ai-Thinker-Open/Ai-Thinker-Open_ALIOS_DEV | 27b3e2883d5801551c6919bf405583919d2f3f08 | [
"Apache-2.0"
] | 12 | 2020-12-04T15:06:22.000Z | 2022-01-19T09:57:47.000Z | tools/bk7231u/gen_firmware_img.py | Ai-Thinker-Open/Ai-Thinker-Open_ALIOS_DEV | 27b3e2883d5801551c6919bf405583919d2f3f08 | [
"Apache-2.0"
] | 1 | 2021-03-01T04:29:31.000Z | 2021-03-15T03:15:20.000Z | tools/bk7231u/gen_firmware_img.py | Ai-Thinker-Open/Ai-Thinker-Open_ALIOS_DEV | 27b3e2883d5801551c6919bf405583919d2f3f08 | [
"Apache-2.0"
] | 5 | 2020-12-10T09:09:24.000Z | 2021-04-15T11:50:32.000Z | import os
import sys
import struct
import zlib
import time
def pack_image(fw_file, boot_file):
print 'app file_name:', fw_file
print 'boot file_name:', boot_file
fname = os.path.splitext(fw_file)
f = file(boot_file, 'rb')
bootloader = f.read()
f.close()
f = file(fw_file,... | 19.05 | 43 | 0.536745 | 112 | 762 | 3.455357 | 0.375 | 0.062016 | 0.062016 | 0.056848 | 0.082687 | 0.082687 | 0 | 0 | 0 | 0 | 0 | 0.027079 | 0.321522 | 762 | 39 | 44 | 19.538462 | 0.72147 | 0 | 0 | 0.066667 | 0 | 0 | 0.094053 | 0 | 0 | 0 | 0.009682 | 0 | 0 | 0 | null | null | 0 | 0.166667 | null | null | 0.1 | 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 |
39ee6557e2519a8f3bba20346e2a245ab2d02a8c | 742 | py | Python | project/server.py | francomanca93/machine-learning-profesional-con-scikit-learn | 44edb5dd0879c62205a9f6174ad85f7c2f2aaf29 | [
"MIT"
] | 11 | 2021-04-01T16:42:18.000Z | 2022-03-21T06:23:07.000Z | project/server.py | santywin/machine-learning-profesional-con-scikit-learn | 44edb5dd0879c62205a9f6174ad85f7c2f2aaf29 | [
"MIT"
] | null | null | null | project/server.py | santywin/machine-learning-profesional-con-scikit-learn | 44edb5dd0879c62205a9f6174ad85f7c2f2aaf29 | [
"MIT"
] | 8 | 2021-04-09T19:48:09.000Z | 2022-02-25T20:49:53.000Z | import joblib
import numpy as np
from flask import Flask, app
from flask import jsonify # herramienta para trabajar cno arch json
app = Flask(__name__)
#POSTMAN PARA PRUEBAS
@app.route('/predict', methods=['GET'])
def predict():
"""Funcion que se expondra en la direccion 8080/predict y que muestra la prediccion ... | 35.333333 | 131 | 0.737197 | 109 | 742 | 4.87156 | 0.651376 | 0.033898 | 0.056497 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.155172 | 0.140162 | 742 | 21 | 132 | 35.333333 | 0.677116 | 0.278976 | 0 | 0 | 0 | 0 | 0.114286 | 0.059048 | 0 | 0 | 0 | 0 | 0 | 1 | 0.076923 | false | 0 | 0.307692 | 0 | 0.461538 | 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 |
39f17a2c8189ea0ed4302348dd8c4f28dbb05424 | 1,001 | py | Python | sampledb/models/dataverse_export.py | nilsholle/sampledb | 90d7487a3990995ca2ec5dfd8b59d4739d6a9a87 | [
"MIT"
] | 5 | 2020-02-13T15:25:37.000Z | 2021-05-06T21:05:14.000Z | sampledb/models/dataverse_export.py | nilsholle/sampledb | 90d7487a3990995ca2ec5dfd8b59d4739d6a9a87 | [
"MIT"
] | 28 | 2019-11-12T14:14:08.000Z | 2022-03-11T16:29:27.000Z | sampledb/models/dataverse_export.py | nilsholle/sampledb | 90d7487a3990995ca2ec5dfd8b59d4739d6a9a87 | [
"MIT"
] | 8 | 2019-12-10T15:46:02.000Z | 2021-11-02T12:24:52.000Z | # coding: utf-8
"""
"""
import datetime
import typing
from .. import db
from .objects import Objects
from .users import User
class DataverseExport(db.Model):
__tablename__ = 'dataverse_exports'
object_id = db.Column(db.Integer, db.ForeignKey(Objects.object_id_column), primary_key=True)
dataverse_url =... | 31.28125 | 130 | 0.708292 | 137 | 1,001 | 4.868613 | 0.343066 | 0.083958 | 0.05997 | 0.035982 | 0.092954 | 0.092954 | 0.092954 | 0 | 0 | 0 | 0 | 0.004854 | 0.176823 | 1,001 | 31 | 131 | 32.290323 | 0.804612 | 0.012987 | 0 | 0 | 0 | 0 | 0.0818 | 0.063395 | 0 | 0 | 0 | 0 | 0 | 1 | 0.1 | false | 0 | 0.25 | 0.05 | 0.7 | 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 |
39f1ed3b1cd7862b03359a5807a0eb61be105716 | 402 | py | Python | apps/accounts/conf.py | sotkonstantinidis/testcircle | 448aa2148fbc2c969e60f0b33ce112d4740a8861 | [
"Apache-2.0"
] | 3 | 2019-02-24T14:24:43.000Z | 2019-10-24T18:51:32.000Z | apps/accounts/conf.py | sotkonstantinidis/testcircle | 448aa2148fbc2c969e60f0b33ce112d4740a8861 | [
"Apache-2.0"
] | 17 | 2017-03-14T10:55:56.000Z | 2022-03-11T23:20:19.000Z | apps/accounts/conf.py | sotkonstantinidis/testcircle | 448aa2148fbc2c969e60f0b33ce112d4740a8861 | [
"Apache-2.0"
] | 2 | 2016-02-01T06:32:40.000Z | 2019-09-06T04:33:50.000Z | from django.conf import settings # noqa
from appconf import AppConf
class AccountConf(AppConf):
"""
Custom settings for the account module. Mainly settings required for
the login on the remote system.
"""
PID = 3
LOGIN_TYPE = 'login'
LOGIN_SUCCESS_URL = 'home'
# The name of the UNCCD... | 25.125 | 72 | 0.696517 | 56 | 402 | 4.910714 | 0.625 | 0.043636 | 0.109091 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003279 | 0.241294 | 402 | 15 | 73 | 26.8 | 0.898361 | 0.415423 | 0 | 0 | 0 | 0 | 0.121495 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.285714 | 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 |
f2cd50d4ae996b6920480de3116036fa8fd3d435 | 1,537 | py | Python | backend/backend.py | ajinkyagadgil/zendesk-coding-assesment-2022 | 336868b7504237677a9a6ec0d3481bc3f26b30c3 | [
"MIT"
] | null | null | null | backend/backend.py | ajinkyagadgil/zendesk-coding-assesment-2022 | 336868b7504237677a9a6ec0d3481bc3f26b30c3 | [
"MIT"
] | null | null | null | backend/backend.py | ajinkyagadgil/zendesk-coding-assesment-2022 | 336868b7504237677a9a6ec0d3481bc3f26b30c3 | [
"MIT"
] | null | null | null | from flask import Flask, jsonify
from flask_cors import CORS
import requests, base64
from init import Config
import json
app = Flask(__name__)
cors = CORS(app, resources={r"*": {"origins": "*"}})
cg = Config()
@app.route('/api/ticket/all',methods=['GET'])
def get_all_tickets():
u_name = cg.data.get('username')
... | 30.74 | 113 | 0.654522 | 198 | 1,537 | 4.893939 | 0.313131 | 0.072239 | 0.055728 | 0.086687 | 0.390093 | 0.390093 | 0.390093 | 0.390093 | 0.390093 | 0.390093 | 0 | 0.01664 | 0.17892 | 1,537 | 50 | 114 | 30.74 | 0.751189 | 0.155498 | 0 | 0.3125 | 0 | 0 | 0.168087 | 0.033308 | 0 | 0 | 0 | 0 | 0 | 1 | 0.0625 | false | 0.1875 | 0.15625 | 0 | 0.28125 | 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 |
f2d2c49d5507b62ff446311cdae008f752b6c5dd | 528 | py | Python | apps/users/migrations/0002_auto_20170413_1628.py | Fors3cDream/DjX | cac207b84923a558da83b0cad15f736f5e6faad2 | [
"Apache-2.0"
] | null | null | null | apps/users/migrations/0002_auto_20170413_1628.py | Fors3cDream/DjX | cac207b84923a558da83b0cad15f736f5e6faad2 | [
"Apache-2.0"
] | null | null | null | apps/users/migrations/0002_auto_20170413_1628.py | Fors3cDream/DjX | cac207b84923a558da83b0cad15f736f5e6faad2 | [
"Apache-2.0"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.9.8 on 2017-04-13 16:28
from __future__ import unicode_literals
import datetime
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('users', '0001_initial'),
]
operations = [
migrations.AlterFi... | 24 | 111 | 0.647727 | 58 | 528 | 5.741379 | 0.775862 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.081481 | 0.232955 | 528 | 21 | 112 | 25.142857 | 0.740741 | 0.126894 | 0 | 0 | 1 | 0 | 0.146288 | 0.052402 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.214286 | 0 | 0.428571 | 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 |
f2d2ebef54cde12bfe9676536a44576d8e8f58f0 | 1,305 | py | Python | qt__pyqt__pyside__pyqode/qt_fill_QTableWidget_from_SQL/main.py | DazEB2/SimplePyScripts | 1dde0a42ba93fe89609855d6db8af1c63b1ab7cc | [
"CC-BY-4.0"
] | 117 | 2015-12-18T07:18:27.000Z | 2022-03-28T00:25:54.000Z | qt__pyqt__pyside__pyqode/qt_fill_QTableWidget_from_SQL/main.py | DazEB2/SimplePyScripts | 1dde0a42ba93fe89609855d6db8af1c63b1ab7cc | [
"CC-BY-4.0"
] | 8 | 2018-10-03T09:38:46.000Z | 2021-12-13T19:51:09.000Z | qt__pyqt__pyside__pyqode/qt_fill_QTableWidget_from_SQL/main.py | DazEB2/SimplePyScripts | 1dde0a42ba93fe89609855d6db8af1c63b1ab7cc | [
"CC-BY-4.0"
] | 28 | 2016-08-02T17:43:47.000Z | 2022-03-21T08:31:12.000Z | #!/usr/bin/env python3
# -*- coding: utf-8 -*-
__author__ = 'ipetrash'
try:
from PyQt5.QtWidgets import *
from PyQt5.QtGui import *
from PyQt5.QtCore import *
except:
from PyQt4.QtGui import *
from PyQt4.QtCore import *
import sqlite3
class Widget(QMainWindow):
def __init__(self):
... | 23.727273 | 112 | 0.623755 | 147 | 1,305 | 5.319728 | 0.462585 | 0.11509 | 0.191816 | 0.084399 | 0.095908 | 0 | 0 | 0 | 0 | 0 | 0 | 0.013361 | 0.254406 | 1,305 | 54 | 113 | 24.166667 | 0.790339 | 0.03295 | 0 | 0 | 0 | 0 | 0.079365 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.060606 | false | 0 | 0.181818 | 0 | 0.272727 | 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 |
f2d57e72af1a33d86b40f1fa035eebdbddd636cb | 829 | py | Python | tests/test_impl_yaml.py | Cologler/anyser-python | 52afa0a62003adcfe269f47d81863e00381d8ff9 | [
"MIT"
] | null | null | null | tests/test_impl_yaml.py | Cologler/anyser-python | 52afa0a62003adcfe269f47d81863e00381d8ff9 | [
"MIT"
] | null | null | null | tests/test_impl_yaml.py | Cologler/anyser-python | 52afa0a62003adcfe269f47d81863e00381d8ff9 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
#
# Copyright (c) 2020~2999 - Cologler <skyoflw@gmail.com>
# ----------
#
# ----------
import pytest
from anyser import *
def test_yaml_default():
data = {
'a': 1,
'b': '2',
'c': {
'd': 'ddddd'
}
}
s = dumps(data, 'yaml')
assert loa... | 22.405405 | 70 | 0.516285 | 110 | 829 | 3.781818 | 0.418182 | 0.108173 | 0.15625 | 0.182692 | 0.230769 | 0.182692 | 0.038462 | 0 | 0 | 0 | 0 | 0.039024 | 0.258142 | 829 | 36 | 71 | 23.027778 | 0.634146 | 0.118215 | 0 | 0 | 0 | 0 | 0.143646 | 0 | 0 | 0 | 0 | 0 | 0.217391 | 1 | 0.173913 | false | 0 | 0.086957 | 0 | 0.26087 | 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 |
f2db8178f2108f87bffc9c12a6ecf808bf61487a | 318 | py | Python | cosmic-core/systemvm/test/python/TestCsProcess.py | sanderv32/cosmic | 9a9d86500b67255a1c743a9438a05c0d969fd210 | [
"Apache-2.0"
] | 64 | 2016-01-30T13:31:00.000Z | 2022-02-21T02:13:25.000Z | cosmic-core/systemvm/test/python/TestCsProcess.py | sanderv32/cosmic | 9a9d86500b67255a1c743a9438a05c0d969fd210 | [
"Apache-2.0"
] | 525 | 2016-01-22T10:46:31.000Z | 2022-02-23T11:08:01.000Z | cosmic-core/systemvm/test/python/TestCsProcess.py | sanderv32/cosmic | 9a9d86500b67255a1c743a9438a05c0d969fd210 | [
"Apache-2.0"
] | 25 | 2016-01-13T16:46:46.000Z | 2021-07-23T15:22:27.000Z | import merge
import unittest
from cs.CsProcess import CsProcess
class TestCsProcess(unittest.TestCase):
def setUp(self):
merge.DataBag.DPATH = "."
def test_init(self):
csprocess = CsProcess({ })
self.assertTrue(csprocess is not None)
if __name__ == '__main__':
unittest.main()
| 18.705882 | 46 | 0.672956 | 36 | 318 | 5.694444 | 0.638889 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.22327 | 318 | 16 | 47 | 19.875 | 0.82996 | 0 | 0 | 0 | 0 | 0 | 0.028302 | 0 | 0 | 0 | 0 | 0 | 0.090909 | 1 | 0.181818 | false | 0 | 0.272727 | 0 | 0.545455 | 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 |
f2e9426e98969d6cc4661a0469f7622f2846b00c | 2,623 | py | Python | abides-gym/abides_gym/envs/markets_environment.py | jpmorganchase/ABIDES-jpmc-gym | 198736a1b1316190072356c980412569579f15a6 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | 1 | 2021-09-23T13:17:26.000Z | 2021-09-23T13:17:26.000Z | abides-gym/abides_gym/envs/markets_environment.py | jpmorganchase/ABIDES-gym | 198736a1b1316190072356c980412569579f15a6 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | abides-gym/abides_gym/envs/markets_environment.py | jpmorganchase/ABIDES-gym | 198736a1b1316190072356c980412569579f15a6 | [
"BSD-3-Clause-No-Nuclear-License-2014",
"BSD-3-Clause"
] | null | null | null | from copy import deepcopy
from abc import abstractmethod, ABC
from typing import Any, Callable, Dict, List, Optional, Tuple
import gym
import numpy as np
from gym.utils import seeding
import abides_markets.agents.utils as markets_agent_utils
from abides_core import Kernel, NanosecondTime
from abides_core.generators i... | 40.984375 | 126 | 0.730843 | 323 | 2,623 | 5.647059 | 0.365325 | 0.052632 | 0.061404 | 0.072368 | 0.143092 | 0.119518 | 0.097588 | 0.057018 | 0.057018 | 0 | 0 | 0.000489 | 0.220358 | 2,623 | 63 | 127 | 41.634921 | 0.891443 | 0.295463 | 0 | 0 | 0 | 0 | 0.043913 | 0.013897 | 0 | 0 | 0 | 0 | 0 | 1 | 0.023256 | false | 0 | 0.302326 | 0 | 0.372093 | 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 |
f2f206a7d36d1186598da3e162e61b9d750b14f0 | 335 | py | Python | 04/04_P19.py | monikuri/2110101_Com_Prog | bed16297685571edd7101b3e911d74ae3c62310c | [
"MIT"
] | null | null | null | 04/04_P19.py | monikuri/2110101_Com_Prog | bed16297685571edd7101b3e911d74ae3c62310c | [
"MIT"
] | null | null | null | 04/04_P19.py | monikuri/2110101_Com_Prog | bed16297685571edd7101b3e911d74ae3c62310c | [
"MIT"
] | null | null | null | s = input()
k1 = input()
k2 = input()
out = ""
for c in s:
found = False
for i in range(len(k1)):
if c == k1[i]:
out += k2[i]
found = True
break
elif c == k2[i]:
out += k1[i]
found = True
break
if not found:
out ... | 18.611111 | 28 | 0.39403 | 46 | 335 | 2.869565 | 0.413043 | 0.045455 | 0.151515 | 0.227273 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.039773 | 0.474627 | 335 | 18 | 29 | 18.611111 | 0.710227 | 0 | 0 | 0.222222 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.055556 | 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 |
f2f3c4dd5d35d0ad0d4f6ae0d6946742efd7d857 | 902 | py | Python | oops_fhir/r4/code_system/failure_action.py | Mikuana/oops_fhir | 77963315d123756b7d21ae881f433778096a1d25 | [
"MIT"
] | null | null | null | oops_fhir/r4/code_system/failure_action.py | Mikuana/oops_fhir | 77963315d123756b7d21ae881f433778096a1d25 | [
"MIT"
] | null | null | null | oops_fhir/r4/code_system/failure_action.py | Mikuana/oops_fhir | 77963315d123756b7d21ae881f433778096a1d25 | [
"MIT"
] | null | null | null | from pathlib import Path
from fhir.resources.codesystem import CodeSystem
from oops_fhir.utils import CodeSystemConcept
__all__ = ["failureaction"]
_resource = CodeSystem.parse_file(Path(__file__).with_suffix(".json"))
class failureaction:
"""
Failure-action
The result if validation fails
Statu... | 16.107143 | 80 | 0.60643 | 87 | 902 | 6.126437 | 0.54023 | 0.157599 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.005891 | 0.247228 | 902 | 55 | 81 | 16.4 | 0.779087 | 0.16408 | 0 | 0 | 0 | 0 | 0.181219 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 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 |
f2f58cf1eb4a0ca869bb33e562f7e0ea56cc92c1 | 1,147 | py | Python | lessons/107/create_rainbow_table.py | marianod92/tutorials | 40fbf96c9866f1264b1b7d7e75171157a3db979a | [
"MIT"
] | 1 | 2022-02-20T09:31:05.000Z | 2022-02-20T09:31:05.000Z | lessons/107/create_rainbow_table.py | kevAnto/tutorials | 9db76b5eeb6a54afabae6a4e386f155cc5dbc025 | [
"MIT"
] | null | null | null | lessons/107/create_rainbow_table.py | kevAnto/tutorials | 9db76b5eeb6a54afabae6a4e386f155cc5dbc025 | [
"MIT"
] | null | null | null | import csv
import hashlib
from urllib.request import urlopen
def get_wordlist(url):
try:
with urlopen(url) as f:
wordlist = f.read().decode('utf-8').splitlines()
return wordlist
except Exception as e:
print(f'failed to get wordlist: {e}')
exit(1)
def hash(pass... | 28.675 | 162 | 0.665214 | 140 | 1,147 | 5.257143 | 0.45 | 0.130435 | 0.086957 | 0.048913 | 0.209239 | 0.209239 | 0.209239 | 0.209239 | 0 | 0 | 0 | 0.044994 | 0.224935 | 1,147 | 39 | 163 | 29.410256 | 0.782902 | 0 | 0 | 0.206897 | 0 | 0.034483 | 0.215344 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.103448 | false | 0.137931 | 0.103448 | 0 | 0.275862 | 0.068966 | 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 |
f2fc049fe417b3d58a7a93361fa125cdbb306674 | 1,948 | py | Python | phase_plane_interactive/cuda_template.py | DeLaVlag/tvb-hpc | 6559707dfee8ec712d9624aaf441f9901919fe63 | [
"Apache-2.0"
] | 3 | 2017-02-22T10:17:19.000Z | 2019-06-20T13:13:53.000Z | phase_plane_interactive/cuda_template.py | DeLaVlag/tvb-hpc | 6559707dfee8ec712d9624aaf441f9901919fe63 | [
"Apache-2.0"
] | 27 | 2017-02-07T10:25:31.000Z | 2020-07-01T09:48:13.000Z | phase_plane_interactive/cuda_template.py | DeLaVlag/tvb-hpc | 6559707dfee8ec712d9624aaf441f9901919fe63 | [
"Apache-2.0"
] | 10 | 2017-03-06T10:52:02.000Z | 2020-11-20T02:17:17.000Z | #include <stdio.h> // for printf
#define PI_2 (2 * M_PI_F)
#include <curand_kernel.h>
#include <curand.h>
__device__ float wrap_2_pi(float x)
{
bool lt_0 = x < 0.0f;
bool gt_2pi = x > PI_2;
return (x + PI_2)*lt_0 + x*(!lt_0)*(!gt_2pi) + (x - PI_2)*gt_2pi;
}
__global__ void ${name}( \
unsigned int i_step,... | 27.43662 | 93 | 0.562115 | 296 | 1,948 | 3.462838 | 0.307432 | 0.063415 | 0.046829 | 0.029268 | 0.134634 | 0.117073 | 0.068293 | 0.068293 | 0.068293 | 0.068293 | 0 | 0.018064 | 0.289528 | 1,948 | 70 | 94 | 27.828571 | 0.722543 | 0 | 0 | 0.042553 | 0 | 0 | 0.001233 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0 | 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 |
840a67f603fe88b318f50370e356d0877ed46339 | 867 | py | Python | courses/migrations/0005_course_data_creation.py | Wassaf-Shahzad/micromasters | b1340a8c233499b1d8d22872a6bc1fe7f49fd323 | [
"BSD-3-Clause"
] | 32 | 2016-03-25T01:03:13.000Z | 2022-01-15T19:35:42.000Z | courses/migrations/0005_course_data_creation.py | Wassaf-Shahzad/micromasters | b1340a8c233499b1d8d22872a6bc1fe7f49fd323 | [
"BSD-3-Clause"
] | 4,858 | 2016-03-03T13:48:30.000Z | 2022-03-29T22:09:51.000Z | courses/migrations/0005_course_data_creation.py | umarmughal824/micromasters | ea92d3bcea9be4601150fc497302ddacc1161622 | [
"BSD-3-Clause"
] | 20 | 2016-08-18T22:07:44.000Z | 2021-11-15T13:35:35.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.9.4 on 2016-03-31 15:18
# pylint: disable=unused-argument
from __future__ import unicode_literals
from django.db import migrations
def forwards(apps, schema_editor):
Course = apps.get_model('courses', 'Course')
CourseRun = apps.get_model('courses', 'CourseRun')... | 27.967742 | 86 | 0.666667 | 101 | 867 | 5.554455 | 0.594059 | 0.035651 | 0.057041 | 0.067736 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.029586 | 0.2203 | 867 | 30 | 87 | 28.9 | 0.800296 | 0.114187 | 0 | 0 | 1 | 0 | 0.074607 | 0.027487 | 0 | 0 | 0 | 0 | 0 | 1 | 0.05 | false | 0 | 0.1 | 0 | 0.3 | 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 |
840cae384a057c3e5f49dc801de16217b41075ca | 3,517 | py | Python | bin/MSA_gene_extractor.py | yasinkaymaz/ViralGenomeAssembly | 03e75ee7358946823660a299e0718213dbbd161c | [
"MIT"
] | null | null | null | bin/MSA_gene_extractor.py | yasinkaymaz/ViralGenomeAssembly | 03e75ee7358946823660a299e0718213dbbd161c | [
"MIT"
] | null | null | null | bin/MSA_gene_extractor.py | yasinkaymaz/ViralGenomeAssembly | 03e75ee7358946823660a299e0718213dbbd161c | [
"MIT"
] | null | null | null | #!/usr/bin/python
"""
This code is a collaborative effort with Sevtap Duman Northeastern University, systems security lab.
"""
import os
import pandas as pd
import sys
import collections
from Bio import AlignIO
import Bio.Align
alndata = []
#sys.argv[1] -> Alignment File
#sys.argv[2] -> type of virus
if len(sys.argv)... | 24.423611 | 130 | 0.695479 | 508 | 3,517 | 4.740157 | 0.332677 | 0.037791 | 0.016611 | 0.028239 | 0.135797 | 0.104651 | 0.052326 | 0.052326 | 0.052326 | 0.024917 | 0 | 0.01871 | 0.148991 | 3,517 | 143 | 131 | 24.594406 | 0.785834 | 0.479102 | 0 | 0.115385 | 0 | 0 | 0.145068 | 0.01354 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.038462 | 0.115385 | null | null | 0.076923 | 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 |
840d1bda771c72ce3545dc243a8458f5b6d0e53e | 1,656 | py | Python | regist/WatchingList.py | yamanakahirofumi/mokobot | 374edd5906b6695ae81020b03a102270c9b69507 | [
"MIT"
] | null | null | null | regist/WatchingList.py | yamanakahirofumi/mokobot | 374edd5906b6695ae81020b03a102270c9b69507 | [
"MIT"
] | null | null | null | regist/WatchingList.py | yamanakahirofumi/mokobot | 374edd5906b6695ae81020b03a102270c9b69507 | [
"MIT"
] | null | null | null | from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy import Table, Column, Integer, String, Text, ForeignKey
from sqlalchemy.orm import relationship
Base = declarative_base()
class Category(Base):
__tablename__ = "category_watching"
id = Column(Integer, primary_key=True)
category = Colu... | 34.5 | 173 | 0.704106 | 195 | 1,656 | 5.641026 | 0.225641 | 0.065455 | 0.081818 | 0.051818 | 0.322727 | 0.249091 | 0 | 0 | 0 | 0 | 0 | 0 | 0.186594 | 1,656 | 47 | 174 | 35.234043 | 0.81663 | 0.011473 | 0 | 0.166667 | 0 | 0 | 0.086957 | 0.028781 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0.083333 | 0.055556 | 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 |
8413c73434f0042bb2e808f8d51208bea3ac9f84 | 729 | py | Python | stanley/slack.py | thermondo/stanley | 32c93ebbba897bcda2cd740fdad9fd02d112c46c | [
"Apache-2.0"
] | 8 | 2018-03-16T14:22:46.000Z | 2022-01-31T17:14:37.000Z | stanley/slack.py | Thermondo/stanley | 9454054a2de1b981bc21702b1a6d24c4518843b3 | [
"Apache-2.0"
] | 1,027 | 2018-03-02T16:41:53.000Z | 2022-02-10T04:15:57.000Z | stanley/slack.py | Thermondo/thermondo-feedback-bot | 27fb575d9043b663f8749503db8e652fa85612bb | [
"Apache-2.0"
] | 1 | 2020-02-24T18:02:09.000Z | 2020-02-24T18:02:09.000Z | from asyncio import Future
from typing import List, Union
from slack_sdk import WebClient
from slack_sdk.web.slack_response import SlackResponse
from stanley.settings import SLACK_API_TOKEN
slack_client = WebClient(SLACK_API_TOKEN, timeout=30)
def get_team_members() -> List[tuple]:
"""Return user list in forma... | 29.16 | 83 | 0.728395 | 99 | 729 | 5.171717 | 0.464646 | 0.064453 | 0.046875 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003295 | 0.167353 | 729 | 24 | 84 | 30.375 | 0.840198 | 0.085048 | 0 | 0 | 0 | 0 | 0.034796 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0.3125 | 0 | 0.5625 | 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 |
841cfebe47f49b0d61b2be76d0e8e3f539a51209 | 1,830 | py | Python | src/app/config_template.py | CLARIAH/wp4-csdh-api | 8f5d75c82a77a62545fa091da238b17691eab1c3 | [
"MIT"
] | 1 | 2018-09-30T06:48:03.000Z | 2018-09-30T06:48:03.000Z | src/app/config_template.py | CLARIAH/wp4-csdh-api | 8f5d75c82a77a62545fa091da238b17691eab1c3 | [
"MIT"
] | 10 | 2016-01-22T13:18:52.000Z | 2016-04-19T10:08:54.000Z | src/app/config_template.py | CLARIAH/wp4-csdh-api | 8f5d75c82a77a62545fa091da238b17691eab1c3 | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Copy this file to 'config.py' and make necessary changes for your local setup.
import os
# Add the converters module to the python path
import sys
sys.path.append("wp4-converters/src")
# Path to a directory where temporary files can be written
# (must be read/writable by the user that owns ... | 36.6 | 122 | 0.746448 | 283 | 1,830 | 4.710247 | 0.438163 | 0.090023 | 0.024756 | 0.021005 | 0.069017 | 0.045011 | 0 | 0 | 0 | 0 | 0 | 0.001889 | 0.13224 | 1,830 | 49 | 123 | 37.346939 | 0.837531 | 0.369945 | 0 | 0 | 0 | 0 | 0.379736 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0.090909 | 0.136364 | 0 | 0.136364 | 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 |
84209f87fd2b39f18b0ed94e0793373ee6e82159 | 1,662 | py | Python | pwn/game_pwn/exp/angr_deal.py | Wood1314/xctf_huaweicloud-qualifier-2020 | 58e10707720c193a7770bd96fda6794973c39eab | [
"Apache-2.0"
] | 15 | 2020-12-24T10:15:46.000Z | 2021-11-25T15:23:23.000Z | pwn/game_pwn/exp/angr_deal.py | Wood1314/xctf_huaweicloud-qualifier-2020 | 58e10707720c193a7770bd96fda6794973c39eab | [
"Apache-2.0"
] | 1 | 2020-12-30T02:12:46.000Z | 2020-12-30T02:12:46.000Z | pwn/game_pwn/exp/angr_deal.py | huaweictf/xctf_huaweicloud-qualifier-2020 | 58e10707720c193a7770bd96fda6794973c39eab | [
"Apache-2.0"
] | 7 | 2020-12-24T10:15:47.000Z | 2021-05-19T05:58:48.000Z | import angr
from angr import *
#from simuvex.procedures.stubs.UserHook import UserHook
binary_path = "./tmp_file.bin"
stack_addr = 0
def get_mem(state, addr, size):
mem = state.memory.load(addr, size)
#print mem
return state.se.eval(mem)
def gen_cond(state, index):
"""Returns a symbolic BitVector and contrains... | 23.083333 | 90 | 0.696149 | 261 | 1,662 | 4.272031 | 0.398467 | 0.03139 | 0.019731 | 0.037668 | 0.095067 | 0.095067 | 0.095067 | 0.095067 | 0.095067 | 0.095067 | 0 | 0.026989 | 0.152828 | 1,662 | 72 | 91 | 23.083333 | 0.764915 | 0.108905 | 0 | 0 | 0 | 0 | 0.039625 | 0 | 0 | 0 | 0.022334 | 0 | 0 | 0 | null | null | 0.020833 | 0.041667 | null | null | 0.145833 | 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 |
84215b929da939c85540b06e3b86f8aa0ebd4f52 | 1,519 | py | Python | TestDemo.py | junneyang/datadrivedunittest | 4d48e29e3978d61ec0ffb8792c78a580d8b9bd09 | [
"MIT"
] | null | null | null | TestDemo.py | junneyang/datadrivedunittest | 4d48e29e3978d61ec0ffb8792c78a580d8b9bd09 | [
"MIT"
] | null | null | null | TestDemo.py | junneyang/datadrivedunittest | 4d48e29e3978d61ec0ffb8792c78a580d8b9bd09 | [
"MIT"
] | null | null | null | #!/usr/bin/python
# -*- coding: utf-8 -*-
'''
Created on 2015/09/08
@author: yangjun
'''
import unittest
import sys
import json
import logging
class ParametrizedTestCase(unittest.TestCase):
""" TestCase classes that want to be parametrized should
inherit from this class.
"""
def __init__(self,... | 29.211538 | 79 | 0.636603 | 165 | 1,519 | 5.721212 | 0.527273 | 0.052966 | 0.04661 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.01426 | 0.261356 | 1,519 | 51 | 80 | 29.784314 | 0.827094 | 0.025016 | 0 | 0.060606 | 0 | 0 | 0.025833 | 0 | 0 | 0 | 0 | 0 | 0.060606 | 0 | null | null | 0 | 0.121212 | null | null | 0.060606 | 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 |
8423b745e135ed5f1286471491c84ce9e7c4f3e6 | 211 | py | Python | Python/Week4/PythonExe/urlJasonParsing.py | CoSandu/PythonCourses | 0cec199f8f9f335e2c8daf5733eb6685c978fff8 | [
"Apache-2.0"
] | null | null | null | Python/Week4/PythonExe/urlJasonParsing.py | CoSandu/PythonCourses | 0cec199f8f9f335e2c8daf5733eb6685c978fff8 | [
"Apache-2.0"
] | null | null | null | Python/Week4/PythonExe/urlJasonParsing.py | CoSandu/PythonCourses | 0cec199f8f9f335e2c8daf5733eb6685c978fff8 | [
"Apache-2.0"
] | null | null | null | import urllib
import json
url_in = raw_input("Enter site here: ")
html = urllib.urlopen(url_in).read()
print html
info = json.loads(html)
s = 0
for v in info["comments"]:
s = s + int(v["count"])
print s
| 14.066667 | 39 | 0.663507 | 37 | 211 | 3.702703 | 0.621622 | 0.072993 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.005848 | 0.189573 | 211 | 14 | 40 | 15.071429 | 0.795322 | 0 | 0 | 0 | 0 | 0 | 0.14218 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.2 | null | null | 0.2 | 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 |
8427544e4dafa0afc1935cfd66fdc8695a1d6e01 | 13,926 | py | Python | gateway.py | knightman/skybitz-gatewaydemo | 5944b45828b868d0a3811d3e67df8ce27cef07af | [
"MIT"
] | null | null | null | gateway.py | knightman/skybitz-gatewaydemo | 5944b45828b868d0a3811d3e67df8ce27cef07af | [
"MIT"
] | null | null | null | gateway.py | knightman/skybitz-gatewaydemo | 5944b45828b868d0a3811d3e67df8ce27cef07af | [
"MIT"
] | null | null | null | import requests
import xmltodict
import json
import os
class Gateway:
'''Gateway class'''
def __init__(self):
'''Establish a gateway connection using a connection URL and auth credentials'''
self.url = 'http://dev.tanklink.com/latlontdg/service.asmx?WSDL'
def gateway_request(self, string)... | 43.51875 | 156 | 0.620997 | 1,398 | 13,926 | 6.11731 | 0.186695 | 0.021515 | 0.019294 | 0.024556 | 0.536366 | 0.517423 | 0.472053 | 0.402011 | 0.383419 | 0.366347 | 0 | 0.001731 | 0.294916 | 13,926 | 319 | 157 | 43.655172 | 0.869233 | 0.287448 | 0 | 0.526316 | 0 | 0 | 0.147047 | 0.071027 | 0 | 0 | 0 | 0.003135 | 0 | 1 | 0.110048 | false | 0.057416 | 0.019139 | 0 | 0.277512 | 0.004785 | 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 |
842f9d5dd58e30e08d053335a0e0d64ac9e5c40a | 547 | py | Python | diventi/products/migrations/0005_auto_20180304_1040.py | flavoi/diven | 3173ca3ca3fbedc191b8eab3639a6bceb3c442c4 | [
"Apache-2.0"
] | 2 | 2019-06-27T16:00:17.000Z | 2020-08-14T07:46:05.000Z | diventi/products/migrations/0005_auto_20180304_1040.py | flavoi/diven | 3173ca3ca3fbedc191b8eab3639a6bceb3c442c4 | [
"Apache-2.0"
] | 26 | 2020-02-15T22:39:35.000Z | 2022-02-19T21:09:01.000Z | diventi/products/migrations/0005_auto_20180304_1040.py | flavoi/diven | 3173ca3ca3fbedc191b8eab3639a6bceb3c442c4 | [
"Apache-2.0"
] | 1 | 2021-11-12T22:30:15.000Z | 2021-11-12T22:30:15.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.11.5 on 2018-03-04 09:40
from __future__ import unicode_literals
import diventi.products.fields
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('products', '0004_auto_20180226_1206'),
]
operations = [
... | 24.863636 | 123 | 0.654479 | 61 | 547 | 5.688525 | 0.754098 | 0.086455 | 0.121037 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.07783 | 0.224863 | 547 | 21 | 124 | 26.047619 | 0.740566 | 0.124314 | 0 | 0 | 1 | 0 | 0.128151 | 0.048319 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.214286 | 0 | 0.428571 | 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 |
8437f5b4453f8490dd76b87ff04a06820f23555a | 579 | py | Python | The Most Frequent.py | Nonac/Checkio_Mission | 1ea2e0d1aeeeb7087a9b1793662b47d1a9526f26 | [
"Apache-2.0"
] | null | null | null | The Most Frequent.py | Nonac/Checkio_Mission | 1ea2e0d1aeeeb7087a9b1793662b47d1a9526f26 | [
"Apache-2.0"
] | null | null | null | The Most Frequent.py | Nonac/Checkio_Mission | 1ea2e0d1aeeeb7087a9b1793662b47d1a9526f26 | [
"Apache-2.0"
] | null | null | null | def most_frequent(data):
"""
determines the most frequently occurring string in the sequence.
"""
# your code here
max = 0
res = ''
for each in data:
if max < data.count(each):
res = each
max = data.count(each)
return res
if __name__ == '__main__':
... | 24.125 | 84 | 0.525043 | 73 | 579 | 4.013699 | 0.575342 | 0.122867 | 0.081911 | 0.109215 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.002558 | 0.324698 | 579 | 23 | 85 | 25.173913 | 0.746803 | 0.274611 | 0 | 0 | 0 | 0 | 0.072682 | 0 | 0 | 0 | 0 | 0.043478 | 0.125 | 1 | 0.0625 | false | 0 | 0 | 0 | 0.125 | 0.0625 | 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 |
843ddb4e63da2ecad00198a078bfb349bed4e9fa | 362 | py | Python | tests/unit/commands/test_is_visible.py | lukas-linhart/pageobject | 6ae83680ae62a94f93cefc394e4f3cc6999aeead | [
"MIT"
] | 1 | 2017-01-12T06:15:36.000Z | 2017-01-12T06:15:36.000Z | tests/unit/commands/test_is_visible.py | lukas-linhart/pageobject | 6ae83680ae62a94f93cefc394e4f3cc6999aeead | [
"MIT"
] | null | null | null | tests/unit/commands/test_is_visible.py | lukas-linhart/pageobject | 6ae83680ae62a94f93cefc394e4f3cc6999aeead | [
"MIT"
] | null | null | null | from tests.unit.fixtures import mock_commands_po as mock_po
def test_is_visible_method_uses_is_displayed_method(mock_po):
mock_po.webelement.is_displayed = lambda log=True: True
assert mock_po.is_visible() == mock_po.is_displayed()
mock_po.webelement.is_displayed = lambda log=True: False
assert mock_p... | 36.2 | 61 | 0.790055 | 58 | 362 | 4.534483 | 0.37931 | 0.18251 | 0.121673 | 0.136882 | 0.593156 | 0.593156 | 0.593156 | 0.593156 | 0.288973 | 0 | 0 | 0 | 0.124309 | 362 | 9 | 62 | 40.222222 | 0.829653 | 0 | 0 | 0.333333 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.333333 | 1 | 0.166667 | false | 0 | 0.166667 | 0 | 0.333333 | 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 |
843e676dd7d963414cf92310e00edf404cb1cc43 | 948 | py | Python | cde-root/usr/lib64/python2.4/site-packages/japanese/aliases/__init__.py | NirBenTalLab/proorigami-cde-package | 273379075830a9b94d3f2884661a54f853777ff6 | [
"MIT"
] | null | null | null | cde-root/usr/lib64/python2.4/site-packages/japanese/aliases/__init__.py | NirBenTalLab/proorigami-cde-package | 273379075830a9b94d3f2884661a54f853777ff6 | [
"MIT"
] | null | null | null | cde-root/usr/lib64/python2.4/site-packages/japanese/aliases/__init__.py | NirBenTalLab/proorigami-cde-package | 273379075830a9b94d3f2884661a54f853777ff6 | [
"MIT"
] | null | null | null | # Tamito KAJIYAMA <2 April 2002>
# $Id: __init__.py,v 1.3 2003/11/29 23:31:23 kajiyama Exp $
import encodings.aliases
encodings.aliases.aliases.update({
'euc_jp': 'japanese.euc_jp',
'eucjp': 'japanese.euc_jp',
'ujis': 'japanese.euc_jp',
'shift_jis': ... | 41.217391 | 61 | 0.543249 | 111 | 948 | 4.243243 | 0.378378 | 0.104034 | 0.133758 | 0.144374 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.141745 | 0.322785 | 948 | 22 | 62 | 43.090909 | 0.5919 | 0.092827 | 0 | 0 | 0 | 0 | 0.484247 | 0.115519 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.055556 | 0 | 0.055556 | 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 |
843f6855dc890272a6df4f98eee72c2cf8ba2774 | 1,680 | py | Python | visualizer/scripts/solver_interactive.py | zdobroff1/CSE505 | d9f74dddc24ce6570abfd87b5e5cfaeca71c4c0c | [
"MIT"
] | null | null | null | visualizer/scripts/solver_interactive.py | zdobroff1/CSE505 | d9f74dddc24ce6570abfd87b5e5cfaeca71c4c0c | [
"MIT"
] | null | null | null | visualizer/scripts/solver_interactive.py | zdobroff1/CSE505 | d9f74dddc24ce6570abfd87b5e5cfaeca71c4c0c | [
"MIT"
] | null | null | null | #! /usr/bin/env python
from solver_inc import *
VERSION = '0.1.1'
class Interactive_Solver(Incremental_Solver):
def __init__(self):
super(Interactive_Solver, self).__init__()
self._inits = []
def on_data(self, data):
if self._reset == True:
self._inits = []
sel... | 31.111111 | 66 | 0.525 | 204 | 1,680 | 4.039216 | 0.308824 | 0.065534 | 0.109223 | 0.072816 | 0.169903 | 0.128641 | 0.082524 | 0.082524 | 0.082524 | 0 | 0 | 0.013761 | 0.35119 | 1,680 | 53 | 67 | 31.698113 | 0.742202 | 0.0125 | 0 | 0.090909 | 0 | 0 | 0.039204 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.022727 | null | null | 0.022727 | 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 |
84458213f2814e6bb8726c17f4f3e369b1d5021a | 2,517 | py | Python | src/selectedtests/test_mappings/get_test_mappings.py | isabella232/selected-tests | 890cd5f39f5571d50f0406b4c25a1a2eef1006a3 | [
"Apache-2.0"
] | 2 | 2020-04-13T11:26:57.000Z | 2022-01-21T00:03:52.000Z | src/selectedtests/test_mappings/get_test_mappings.py | mongodb/selected-tests | 467f71f1d45b06ac3cc5db252f18658f8cd93083 | [
"Apache-2.0"
] | 54 | 2019-09-26T18:56:34.000Z | 2022-03-12T01:07:00.000Z | src/selectedtests/test_mappings/get_test_mappings.py | isabella232/selected-tests | 890cd5f39f5571d50f0406b4c25a1a2eef1006a3 | [
"Apache-2.0"
] | 6 | 2019-10-01T14:24:27.000Z | 2020-02-13T15:53:47.000Z | """Script to get test mappings."""
from decimal import Decimal
from typing import List
from pymongo.collection import Collection
def get_correlated_test_mappings(
collection: Collection, changed_source_files: List[str], project: str, threshold: Decimal
) -> List[dict]:
"""
Retrieve test mappings associat... | 38.723077 | 98 | 0.400874 | 186 | 2,517 | 5.22043 | 0.397849 | 0.055613 | 0.053553 | 0.045314 | 0.07415 | 0.07415 | 0.07415 | 0.07415 | 0 | 0 | 0 | 0 | 0.517282 | 2,517 | 64 | 99 | 39.328125 | 0.799177 | 0.220501 | 0 | 0 | 0 | 0 | 0.152604 | 0.056771 | 0 | 0 | 0 | 0 | 0 | 1 | 0.020408 | false | 0 | 0.061224 | 0 | 0.102041 | 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 |
844c15eeddedfe0b7dc01cd60c6b3b13408bedc6 | 50,773 | py | Python | Python.py | iFirst/Dormitory-Management-Syatems | 072658a09a0cd4fc9c93686b79fb2fd935109cb7 | [
"CNRI-Python"
] | null | null | null | Python.py | iFirst/Dormitory-Management-Syatems | 072658a09a0cd4fc9c93686b79fb2fd935109cb7 | [
"CNRI-Python"
] | null | null | null | Python.py | iFirst/Dormitory-Management-Syatems | 072658a09a0cd4fc9c93686b79fb2fd935109cb7 | [
"CNRI-Python"
] | null | null | null | __author__ = 'Phawitch & Tanawit'
import hid
import time
import mysql.connector
import datetime
class Domdatabase():
def __init__(self):
#print "Test"
#self.server = DomServer()
self.config = {
'user': 'newuser',
'password': '12345678',
... | 33.42528 | 124 | 0.502866 | 5,110 | 50,773 | 4.854795 | 0.114286 | 0.072718 | 0.026121 | 0.034827 | 0.564818 | 0.515035 | 0.483997 | 0.459368 | 0.446066 | 0.439455 | 0 | 0.023952 | 0.370945 | 50,773 | 1,518 | 125 | 33.447299 | 0.752779 | 0.11059 | 0 | 0.532587 | 0 | 0 | 0.053233 | 0.016402 | 0 | 0 | 0.000566 | 0 | 0 | 0 | null | null | 0.008147 | 0.004073 | null | null | 0.080448 | 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 |
84526230cfaed162d112747247d775c3adf85975 | 233 | py | Python | hackerrank/Python/Validating Credit Card Numbers/solution.py | ATrain951/01.python-com_Qproject | c164dd093954d006538020bdf2e59e716b24d67c | [
"MIT"
] | 4 | 2020-07-24T01:59:50.000Z | 2021-07-24T15:14:08.000Z | hackerrank/Python/Validating Credit Card Numbers/solution.py | ATrain951/01.python-com_Qproject | c164dd093954d006538020bdf2e59e716b24d67c | [
"MIT"
] | null | null | null | hackerrank/Python/Validating Credit Card Numbers/solution.py | ATrain951/01.python-com_Qproject | c164dd093954d006538020bdf2e59e716b24d67c | [
"MIT"
] | null | null | null | import re
for _ in range(int(input())):
s = input().strip()
if re.match(r'^[456](\d{15}|\d{3}(-\d{4}){3})$', s) and not re.search(r'(\d)\1\1\1', s.replace('-', '')):
print('Valid')
else:
print('Invalid')
| 25.888889 | 109 | 0.484979 | 39 | 233 | 2.871795 | 0.666667 | 0.035714 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.059783 | 0.2103 | 233 | 8 | 110 | 29.125 | 0.548913 | 0 | 0 | 0 | 0 | 0 | 0.236052 | 0.137339 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.142857 | 0 | 0.142857 | 0.285714 | 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 |
845402b2f088f463f69523ca5a47144e772226a7 | 2,990 | py | Python | gpytorch/lazy/non_lazy_tensor.py | Sciguymjm/gpytorch | 9ea45c1221e21652fcd6229e87d217a716eea983 | [
"MIT"
] | null | null | null | gpytorch/lazy/non_lazy_tensor.py | Sciguymjm/gpytorch | 9ea45c1221e21652fcd6229e87d217a716eea983 | [
"MIT"
] | null | null | null | gpytorch/lazy/non_lazy_tensor.py | Sciguymjm/gpytorch | 9ea45c1221e21652fcd6229e87d217a716eea983 | [
"MIT"
] | null | null | null | #!/usr/bin/env python3
import torch
from .. import settings
from ..lazy import LazyTensor
class NonLazyTensor(LazyTensor):
def __init__(self, tsr):
"""
Not a lazy tensor
Args:
- tsr (Tensor: matrix) a Tensor
"""
if not torch.is_tensor(tsr):
raise Runti... | 33.977273 | 112 | 0.601672 | 369 | 2,990 | 4.650407 | 0.279133 | 0.064103 | 0.04662 | 0.022145 | 0.141026 | 0.073427 | 0.04662 | 0.04662 | 0 | 0 | 0 | 0.008975 | 0.291973 | 2,990 | 87 | 113 | 34.367816 | 0.801606 | 0.08796 | 0 | 0.070175 | 0 | 0 | 0.049235 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.175439 | false | 0 | 0.052632 | 0.105263 | 0.45614 | 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 | 1 | 0 | 0 | 0 | 1 |
84567cc099452062a48163ce4ae51657983a02e4 | 1,396 | py | Python | misago/misago/menus/tests/conftest.py | vascoalramos/misago-deployment | 20226072138403108046c0afad9d99eb4163cedc | [
"MIT"
] | 2 | 2021-03-06T21:06:13.000Z | 2021-03-09T15:05:12.000Z | misago/misago/menus/tests/conftest.py | vascoalramos/misago-deployment | 20226072138403108046c0afad9d99eb4163cedc | [
"MIT"
] | null | null | null | misago/misago/menus/tests/conftest.py | vascoalramos/misago-deployment | 20226072138403108046c0afad9d99eb4163cedc | [
"MIT"
] | null | null | null | import pytest
from ..menuitems import get_footer_menu_items, get_navbar_menu_items
from ..models import MenuItem
@pytest.fixture
def navar_menu_item(db):
return MenuItem.objects.create(
title="Top Menu Item",
url="https://navbar_menu_item.com",
menu=MenuItem.MENU_NAVBAR,
)
@pytest.f... | 24.068966 | 84 | 0.713467 | 186 | 1,396 | 5.037634 | 0.215054 | 0.128068 | 0.102455 | 0.117396 | 0.490929 | 0.363927 | 0.241195 | 0.20064 | 0.110993 | 0.110993 | 0 | 0 | 0.189112 | 1,396 | 57 | 85 | 24.491228 | 0.827739 | 0 | 0 | 0.318182 | 0 | 0 | 0.171203 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.136364 | false | 0 | 0.068182 | 0.136364 | 0.340909 | 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 | 1 | 0 | 0 | 0 | 1 |
845952544143958b1bda55ef01ee96098f127471 | 1,096 | py | Python | reobject/transaction.py | agusmakmun/reobject | a7689bbb37f021c6c8ea72d6984513adec0d8a17 | [
"Apache-2.0"
] | 92 | 2017-02-08T21:51:03.000Z | 2021-05-27T22:58:07.000Z | reobject/transaction.py | agusmakmun/reobject | a7689bbb37f021c6c8ea72d6984513adec0d8a17 | [
"Apache-2.0"
] | 15 | 2017-01-27T22:54:42.000Z | 2021-05-27T01:31:58.000Z | reobject/transaction.py | agusmakmun/reobject | a7689bbb37f021c6c8ea72d6984513adec0d8a17 | [
"Apache-2.0"
] | 7 | 2017-02-08T22:00:41.000Z | 2021-05-26T00:26:44.000Z | # -*- coding: utf-8 -*-
from copy import deepcopy
from reobject.exceptions import CorruptTransactionException
__all__ = ['Transaction', 'transactional']
class Transaction(object):
def __init__(self, obj):
self.obj = obj
self.__transaction_state = None
def __enter__(self):
self.__tr... | 21.92 | 59 | 0.588504 | 111 | 1,096 | 5.351351 | 0.387387 | 0.047138 | 0.13468 | 0.057239 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.001333 | 0.315693 | 1,096 | 49 | 60 | 22.367347 | 0.790667 | 0.019161 | 0 | 0 | 0 | 0 | 0.022367 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.242424 | false | 0 | 0.060606 | 0 | 0.454545 | 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 |
845d3de99c7b56d36ea492e348fdbc8c2ec1b22b | 2,050 | py | Python | pycycle/element_base.py | anilyil/pyCycle | 8028dcf8abad4ecb51e5d5b1dcd7f4b2bccc3a83 | [
"Apache-2.0"
] | 38 | 2019-08-12T15:27:25.000Z | 2022-01-27T16:34:51.000Z | pycycle/element_base.py | anilyil/pyCycle | 8028dcf8abad4ecb51e5d5b1dcd7f4b2bccc3a83 | [
"Apache-2.0"
] | 16 | 2019-11-07T17:39:54.000Z | 2022-03-01T14:59:48.000Z | pycycle/element_base.py | anilyil/pyCycle | 8028dcf8abad4ecb51e5d5b1dcd7f4b2bccc3a83 | [
"Apache-2.0"
] | 35 | 2019-08-12T15:27:37.000Z | 2022-03-17T16:25:33.000Z | import numpy as np
import openmdao.api as om
from pycycle.flow_in import FlowIn
from pycycle.thermo.thermo import Thermo, ThermoAdd
from pycycle.constants import ALLOWED_THERMOS
class Element(om.Group):
"""
Custom pyCycle group for anything that requires input or output ports
"""
def __init__(self,... | 32.03125 | 120 | 0.633171 | 270 | 2,050 | 4.607407 | 0.374074 | 0.033762 | 0.028135 | 0.044212 | 0.09164 | 0.07717 | 0.043408 | 0.043408 | 0 | 0 | 0 | 0 | 0.286829 | 2,050 | 63 | 121 | 32.539683 | 0.850889 | 0.198537 | 0 | 0.066667 | 0 | 0 | 0.175754 | 0 | 0 | 0 | 0 | 0.015873 | 0 | 1 | 0.133333 | false | 0 | 0.166667 | 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 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
846318a5054f8e36233133149286fda242000c48 | 1,363 | py | Python | py/day_07/solve.py | Thundzz/advent-of-code-2021 | e91cd8a5756566ad3f47e07a51b0beb5b9f5326c | [
"MIT"
] | null | null | null | py/day_07/solve.py | Thundzz/advent-of-code-2021 | e91cd8a5756566ad3f47e07a51b0beb5b9f5326c | [
"MIT"
] | null | null | null | py/day_07/solve.py | Thundzz/advent-of-code-2021 | e91cd8a5756566ad3f47e07a51b0beb5b9f5326c | [
"MIT"
] | null | null | null | import statistics
import math
def parse_input(filename):
with open(filename) as file:
return [int(i) for i in file.readline().split(",")]
def fuel_cost_assumption(positions, target):
return sum(map(lambda p: abs(p - target), positions))
def min_fuel_assumption(positions):
m = statistics.median(po... | 30.288889 | 89 | 0.683786 | 188 | 1,363 | 4.819149 | 0.420213 | 0.04415 | 0.059603 | 0.089404 | 0.140177 | 0.09713 | 0.09713 | 0.09713 | 0.09713 | 0.09713 | 0 | 0.002737 | 0.195891 | 1,363 | 44 | 90 | 30.977273 | 0.823905 | 0.172414 | 0 | 0.068966 | 0 | 0 | 0.016319 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.206897 | false | 0 | 0.068966 | 0.068966 | 0.448276 | 0.103448 | 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 |
ffc07fec18123cc8079fd63e689db595731b80fe | 1,201 | py | Python | 2020/day4-2.py | alvaropp/AdventOfCode2017 | 2827dcc18ecb9ad59a1a5fe11e469f31bafb74ad | [
"MIT"
] | null | null | null | 2020/day4-2.py | alvaropp/AdventOfCode2017 | 2827dcc18ecb9ad59a1a5fe11e469f31bafb74ad | [
"MIT"
] | null | null | null | 2020/day4-2.py | alvaropp/AdventOfCode2017 | 2827dcc18ecb9ad59a1a5fe11e469f31bafb74ad | [
"MIT"
] | null | null | null | import re
with open("day4.txt", "r") as f:
passport_list = [
{
k: v
for k, v in [
field.split(":")
for field in list(filter(None, re.split("[, \n]+", passport)))
]
}
for passport in f.read().split("\n\n")
]
def field... | 27.930233 | 79 | 0.532057 | 169 | 1,201 | 3.715976 | 0.443787 | 0.124204 | 0.057325 | 0.047771 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.050343 | 0.272273 | 1,201 | 42 | 80 | 28.595238 | 0.668192 | 0 | 0 | 0 | 0 | 0 | 0.080766 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.09375 | false | 0.5625 | 0.03125 | 0.0625 | 0.21875 | 0.03125 | 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 |
ffc5821c768e78700a44946274332f537cefbc33 | 161 | py | Python | 004/004_2.py | ys-nuem/project-euler | bcdb98fa01bea93606227e74cc15930a38a4c8d5 | [
"MIT"
] | null | null | null | 004/004_2.py | ys-nuem/project-euler | bcdb98fa01bea93606227e74cc15930a38a4c8d5 | [
"MIT"
] | null | null | null | 004/004_2.py | ys-nuem/project-euler | bcdb98fa01bea93606227e74cc15930a38a4c8d5 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
problem4 = max(i*j for i in range(100, 1000+1) for j in range(i, 1000+1) \
if str(i*j) == str(i*j)[::-1])
print(problem4)
| 26.833333 | 74 | 0.559006 | 32 | 161 | 2.8125 | 0.53125 | 0.066667 | 0.111111 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.130081 | 0.236025 | 161 | 5 | 75 | 32.2 | 0.601626 | 0.124224 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.333333 | 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 |
ffd15539c6716921aaadb9ff12e0a7c0204cc685 | 4,669 | py | Python | backend.py | Gyan-Ratan/Music-Player | c96f72605fd2bd4d62101e5ee8d350e6a9905f2b | [
"MIT"
] | 8 | 2017-01-28T18:24:03.000Z | 2020-09-07T22:21:01.000Z | backend.py | Gyan-Ratan/Music-Player | c96f72605fd2bd4d62101e5ee8d350e6a9905f2b | [
"MIT"
] | 2 | 2018-02-26T22:48:48.000Z | 2018-02-26T22:52:23.000Z | backend.py | Gyan-Ratan/Music-Player | c96f72605fd2bd4d62101e5ee8d350e6a9905f2b | [
"MIT"
] | 6 | 2018-02-21T20:22:25.000Z | 2022-01-22T02:25:43.000Z | # TODO: keep in mind that this class uses PyQt and it extends QObject
import os
import gi
gi.require_version('Gst', '1.0')
gi.require_version('GstBase', '1.0')
from gi.repository import GObject, Gst, GstBase, GObject
from PyQt4.QtCore import QObject, pyqtSignal, pyqtSlot
class MusicPlayer(QObject):
# declare a new... | 30.318182 | 109 | 0.650246 | 636 | 4,669 | 4.617925 | 0.284591 | 0.047668 | 0.045965 | 0.027239 | 0.216548 | 0.162751 | 0.085802 | 0.085802 | 0.085802 | 0.040177 | 0 | 0.004588 | 0.253159 | 4,669 | 153 | 110 | 30.51634 | 0.837683 | 0.210323 | 0 | 0.214286 | 0 | 0 | 0.109422 | 0 | 0 | 0 | 0 | 0.006536 | 0 | 0 | null | null | 0 | 0.047619 | null | null | 0.107143 | 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 |
ffd36c5a4ae951b70bc114912a804d8f0815d679 | 264 | py | Python | instagram/admin.py | amiinegal/instagram | bddf0e34ac1dd250775c2b69be3648dc814e630d | [
"MIT",
"Unlicense"
] | null | null | null | instagram/admin.py | amiinegal/instagram | bddf0e34ac1dd250775c2b69be3648dc814e630d | [
"MIT",
"Unlicense"
] | 3 | 2021-03-19T00:48:03.000Z | 2021-06-10T21:28:11.000Z | instagram/admin.py | amiinegal/instagram | bddf0e34ac1dd250775c2b69be3648dc814e630d | [
"MIT",
"Unlicense"
] | null | null | null | from django.contrib import admin
from .models import Image, Profile,Location
# Register your models here.
class ImageAdmin(admin.ModelAdmin):
filter_horizontal = ('tags')
admin.site.register(Image)
admin.site.register(Profile)
admin.site.register(Location)
| 24 | 44 | 0.787879 | 34 | 264 | 6.088235 | 0.558824 | 0.130435 | 0.246377 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.109848 | 264 | 10 | 45 | 26.4 | 0.880851 | 0.098485 | 0 | 0 | 0 | 0 | 0.016949 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.285714 | 0 | 0.571429 | 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 |
ffd430f496c6eee39a6625b2b665309a6608d15b | 2,102 | py | Python | my_cv/09/09_02_animals_ann.py | strawsyz/straw | db313c78c2e3c0355cd10c70ac25a15bb5632d41 | [
"MIT"
] | 2 | 2020-04-06T09:09:19.000Z | 2020-07-24T03:59:55.000Z | my_cv/09/09_02_animals_ann.py | strawsyz/straw | db313c78c2e3c0355cd10c70ac25a15bb5632d41 | [
"MIT"
] | null | null | null | my_cv/09/09_02_animals_ann.py | strawsyz/straw | db313c78c2e3c0355cd10c70ac25a15bb5632d41 | [
"MIT"
] | null | null | null | import cv2
import numpy as np
from random import randint
animals_net = cv2.ml.ANN_MLP_create()
# 设定train函数为弹性(resilient)反向传播
animals_net.setTrainMethod(cv2.ml.ANN_MLP_RPROP | cv2.ml.ANN_MLP_UPDATE_WEIGHTS)
# 设置sigmoid作为激活函数
animals_net.setActivationFunction(cv2.ml.ANN_MLP_SIGMOID_SYM)
# 按照书里的把隐藏层节点数设为8,效果非常差,所以改成3
ani... | 28.405405 | 88 | 0.680304 | 309 | 2,102 | 4.462783 | 0.278317 | 0.094271 | 0.121827 | 0.116026 | 0.408267 | 0.397389 | 0.397389 | 0.345903 | 0.345903 | 0.225526 | 0 | 0.067156 | 0.156993 | 2,102 | 73 | 89 | 28.794521 | 0.711061 | 0.043768 | 0 | 0 | 0 | 0 | 0.006799 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.2 | false | 0 | 0.075 | 0.2 | 0.475 | 0.125 | 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 | 1 | 0 | 0 | 0 | 1 |
ffdf0c7f53a992b100810a1f0e1c66f11e6e84c3 | 10,616 | py | Python | maskrcnn_modanet/cli/main.py | jayrodge/maskrcnn-modanet | 3f81bc987e6899a2ced19b03db137084209483f7 | [
"MIT"
] | 1 | 2020-04-10T09:53:47.000Z | 2020-04-10T09:53:47.000Z | maskrcnn_modanet/cli/main.py | jayrodge/maskrcnn-modanet | 3f81bc987e6899a2ced19b03db137084209483f7 | [
"MIT"
] | null | null | null | maskrcnn_modanet/cli/main.py | jayrodge/maskrcnn-modanet | 3f81bc987e6899a2ced19b03db137084209483f7 | [
"MIT"
] | null | null | null | import click, json, os
from . import validators
from maskrcnn_modanet import processimages
def print_help(ctx, param, value):
if value is False:
return
click.echo(ctx.get_help())
ctx.exit()
@click.group()
def main():
"""Main CLI."""
pass
@main.group()
def datasets():
''' Manage your dataset... | 44.41841 | 192 | 0.733327 | 1,599 | 10,616 | 4.734209 | 0.166979 | 0.02959 | 0.063804 | 0.069353 | 0.659841 | 0.639102 | 0.619683 | 0.584676 | 0.584676 | 0.562219 | 0 | 0.007022 | 0.128014 | 10,616 | 238 | 193 | 44.605042 | 0.810738 | 0.148832 | 0 | 0.503106 | 0 | 0.018634 | 0.26895 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111801 | false | 0.074534 | 0.055901 | 0 | 0.173913 | 0.099379 | 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 |
ffe0a30bcfb0c56d795371f5c5feb071ff36a856 | 972 | py | Python | hoover/search/migrations/0003_update_snoop_url.py | hoover/hoover | 84053b2479e966b0f639692c9e226261e3188709 | [
"MIT"
] | 15 | 2016-08-18T10:48:06.000Z | 2019-10-15T14:41:20.000Z | hoover/search/migrations/0003_update_snoop_url.py | hoover/hoover | 84053b2479e966b0f639692c9e226261e3188709 | [
"MIT"
] | 88 | 2019-10-28T14:55:16.000Z | 2021-05-14T12:42:52.000Z | hoover/search/migrations/0003_update_snoop_url.py | hoover/hoover | 84053b2479e966b0f639692c9e226261e3188709 | [
"MIT"
] | 14 | 2016-09-27T13:11:57.000Z | 2019-10-08T23:33:59.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.10.6 on 2018-12-18 16:08
from __future__ import unicode_literals
from django.db import migrations
from urllib.parse import urlparse, urlunparse, ParseResult
from json import loads, dumps
def update_snoop_url(apps, schema_editor):
Collection = apps.get_model('search... | 30.375 | 89 | 0.647119 | 110 | 972 | 5.572727 | 0.563636 | 0.04894 | 0.045677 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.02861 | 0.244856 | 972 | 31 | 90 | 31.354839 | 0.80654 | 0.069959 | 0 | 0 | 1 | 0 | 0.083241 | 0.031077 | 0 | 0 | 0 | 0 | 0 | 1 | 0.045455 | false | 0 | 0.181818 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
ffe17b6aede48ffeb86154c7a3161d5472bc5cb4 | 1,705 | py | Python | buffer/in-vicinity-python/uno/uinit.py | zaqwes8811/coordinator-tasks | 7f63fdf613eff5d441a3c2c7b52d2a3d02d9736a | [
"MIT"
] | null | null | null | buffer/in-vicinity-python/uno/uinit.py | zaqwes8811/coordinator-tasks | 7f63fdf613eff5d441a3c2c7b52d2a3d02d9736a | [
"MIT"
] | 15 | 2015-03-07T12:46:41.000Z | 2015-04-11T09:08:36.000Z | projects/python-desk/shadow/uno/uinit.py | zaqwes8811/micro-apps | 7f63fdf613eff5d441a3c2c7b52d2a3d02d9736a | [
"MIT"
] | null | null | null | #-*- coding : utf-8 -*-
# file : import uinit
import os
import sys
def import_uno():
# Add the URE_BOOTSTRAP environment variable #3
os.environ['URE_BOOTSTRAP'] = 'vnd.sun.star.pathname:c:\Program Files\OpenOffice.org 3\program\\fundamental.ini'
# Add the UNO_PATH environment variable ... | 29.396552 | 226 | 0.690323 | 225 | 1,705 | 5.146667 | 0.377778 | 0.041451 | 0.067358 | 0.099309 | 0.351468 | 0.351468 | 0.274611 | 0.215889 | 0.100173 | 0 | 0 | 0.009986 | 0.177713 | 1,705 | 58 | 227 | 29.396552 | 0.815264 | 0.194721 | 0 | 0.371429 | 0 | 0.057143 | 0.367117 | 0.159159 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.171429 | 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 |
ffe4de1d0d65dd5c245354546e91d77c0caa114c | 461 | py | Python | story/migrations/0005_auto_20200521_0513.py | VotarkSocial/votarkAPI | eea10a64ac0b255c97078b90786fccb30d0a451e | [
"MIT"
] | 2 | 2020-06-14T08:25:29.000Z | 2021-09-22T07:48:11.000Z | story/migrations/0005_auto_20200521_0513.py | suulcoder/votarkAPI | eea10a64ac0b255c97078b90786fccb30d0a451e | [
"MIT"
] | 10 | 2020-06-14T08:36:42.000Z | 2022-03-12T00:30:53.000Z | story/migrations/0005_auto_20200521_0513.py | suulcoder/votarkAPI | eea10a64ac0b255c97078b90786fccb30d0a451e | [
"MIT"
] | 1 | 2021-09-22T07:48:17.000Z | 2021-09-22T07:48:17.000Z | # Generated by Django 3.0.4 on 2020-05-21 05:13
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('story', '0004_auto_20200520_2352'),
]
operations = [
migrations.RenameField(
model_name='story',
old_name='video',
... | 20.043478 | 47 | 0.550976 | 46 | 461 | 5.369565 | 0.717391 | 0.072874 | 0.11336 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.100977 | 0.334056 | 461 | 22 | 48 | 20.954545 | 0.703583 | 0.097614 | 0 | 0.25 | 1 | 0 | 0.13285 | 0.055556 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.0625 | 0 | 0.25 | 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 |
fff67c645c91fcdcf4876bec222ba5dfc41d68c2 | 899 | py | Python | blessed_extensions/validate_comment_len.py | sprin/pg-discuss | 1b5e045be286ff7a08e29663e0c148ffbf4955b0 | [
"PostgreSQL",
"Ruby",
"MIT"
] | 13 | 2015-12-29T19:46:37.000Z | 2021-06-09T21:05:53.000Z | blessed_extensions/validate_comment_len.py | sprin/pg-discuss | 1b5e045be286ff7a08e29663e0c148ffbf4955b0 | [
"PostgreSQL",
"Ruby",
"MIT"
] | 30 | 2015-10-07T17:03:49.000Z | 2017-08-09T15:27:15.000Z | blessed_extensions/validate_comment_len.py | sprin/pg-discuss | 1b5e045be286ff7a08e29663e0c148ffbf4955b0 | [
"PostgreSQL",
"Ruby",
"MIT"
] | 4 | 2015-11-08T15:58:42.000Z | 2017-11-23T15:37:44.000Z | import voluptuous
from pg_discuss import ext
#: Minimum allowed comment length
MIN_COMMENT_LENGTH = 3
#: Maximum allowed comment length
MAX_COMMENT_LENGTH = 65535
class ValidateCommentLen(ext.ValidateComment):
"""Extension to add a validation rule that enforces a minimum and
maximum comment length.
"""
... | 32.107143 | 74 | 0.723026 | 111 | 899 | 5.54955 | 0.36036 | 0.316558 | 0.155844 | 0.112013 | 0.298701 | 0 | 0 | 0 | 0 | 0 | 0 | 0.008219 | 0.187987 | 899 | 27 | 75 | 33.296296 | 0.835616 | 0.167964 | 0 | 0 | 0 | 0 | 0.103825 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.125 | false | 0 | 0.125 | 0 | 0.375 | 0 | 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 |
fffe1d1fbd964367b7c28dfb8920e3e8cc1e4b56 | 8,255 | py | Python | sprd/vowifi/tmtc_ut/lib/adbhelper.py | deevarvar/myLab | 7a5019f5f7fc11e173d350e6e2a7d2c80504782d | [
"MIT"
] | null | null | null | sprd/vowifi/tmtc_ut/lib/adbhelper.py | deevarvar/myLab | 7a5019f5f7fc11e173d350e6e2a7d2c80504782d | [
"MIT"
] | null | null | null | sprd/vowifi/tmtc_ut/lib/adbhelper.py | deevarvar/myLab | 7a5019f5f7fc11e173d350e6e2a7d2c80504782d | [
"MIT"
] | 3 | 2016-10-08T15:01:49.000Z | 2018-05-24T03:14:24.000Z | #-*- coding=utf-8 -*-
#author: zhihua.ye@spreadtrum.com
#https://stackoverflow.com/questions/30937829/how-to-get-both-return-code-and-output-from-subprocess-in-python
"""
1. adb root, adb remount
2. adb push libs and resource
2.1 currently use adb cmd, python-adb is optional
"""
from logConf import *
from ... | 36.526549 | 115 | 0.526953 | 917 | 8,255 | 4.699019 | 0.280262 | 0.037132 | 0.051984 | 0.06498 | 0.19935 | 0.181481 | 0.115108 | 0.093989 | 0.093989 | 0.093989 | 0 | 0.010987 | 0.360509 | 8,255 | 226 | 116 | 36.526549 | 0.805266 | 0.152635 | 0 | 0.211382 | 0 | 0 | 0.079022 | 0 | 0.00813 | 0 | 0 | 0.004425 | 0 | 0 | null | null | 0 | 0.01626 | null | null | 0.00813 | 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 |
08107051539880f8a411127355349160e0bede39 | 2,664 | py | Python | subsetFonts.py | vizzie-tx/epub3-template | 7781992ba764a44fc94daad2e89dcb5ebf6281f0 | [
"MIT"
] | 2 | 2016-01-25T18:35:07.000Z | 2019-02-06T20:17:01.000Z | subsetFonts.py | vizzie-tx/epub3-template | 7781992ba764a44fc94daad2e89dcb5ebf6281f0 | [
"MIT"
] | null | null | null | subsetFonts.py | vizzie-tx/epub3-template | 7781992ba764a44fc94daad2e89dcb5ebf6281f0 | [
"MIT"
] | null | null | null | n#!/usr/bin/env python
# Copyright (c) 2014-2016 Larry Daffner
# Permission is hereby granted, free of charge, to any person
# obtaining a COPY of this software and associated documentation files
# (the "Software"), to deal in the Software without restriction,
# including without limitation the rights to use, copy, mo... | 35.052632 | 70 | 0.65503 | 366 | 2,664 | 4.73224 | 0.502732 | 0.050808 | 0.024249 | 0.018476 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.009453 | 0.245496 | 2,664 | 75 | 71 | 35.52 | 0.852239 | 0.429429 | 0 | 0 | 0 | 0 | 0.033356 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.083333 | null | null | 0.020833 | 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 |
081eea947bb2aa04334bfc1c24198810d7b9c748 | 1,002 | py | Python | soldajustica/project/migrations/0003_auto_20150616_1926.py | patrickporto/soldajustica | 191299012a8142c8d1c073f025a2ff2d1a2d267c | [
"MIT"
] | null | null | null | soldajustica/project/migrations/0003_auto_20150616_1926.py | patrickporto/soldajustica | 191299012a8142c8d1c073f025a2ff2d1a2d267c | [
"MIT"
] | null | null | null | soldajustica/project/migrations/0003_auto_20150616_1926.py | patrickporto/soldajustica | 191299012a8142c8d1c073f025a2ff2d1a2d267c | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('project', '0002_auto_20150615_2305'),
]
operations = [
migrations.AlterField(
model_name='project',
... | 28.628571 | 92 | 0.58982 | 104 | 1,002 | 5.538462 | 0.471154 | 0.138889 | 0.173611 | 0.201389 | 0.472222 | 0.472222 | 0.295139 | 0 | 0 | 0 | 0 | 0.023876 | 0.289421 | 1,002 | 34 | 93 | 29.470588 | 0.776685 | 0.020958 | 0 | 0.428571 | 0 | 0 | 0.15526 | 0.023493 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.071429 | 0 | 0.178571 | 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 |
08225b798dec0ff70bccbc7fb5d17116ab7a9c3e | 351 | py | Python | ngapp.py | calmetree/NgToolset | b7db73ba0a2309085b87b0859f9b5448e56ea931 | [
"BSD-3-Clause"
] | null | null | null | ngapp.py | calmetree/NgToolset | b7db73ba0a2309085b87b0859f9b5448e56ea931 | [
"BSD-3-Clause"
] | null | null | null | ngapp.py | calmetree/NgToolset | b7db73ba0a2309085b87b0859f9b5448e56ea931 | [
"BSD-3-Clause"
] | 1 | 2020-01-09T06:57:49.000Z | 2020-01-09T06:57:49.000Z | #!/usr/bin/python3
# -*- encoding: utf-8 -*-
'''
File:
ng_app.py
Description:
The main routine.
Change History:
2018-1-19 v0.1 created by github/zhenggao2
'''
import sys
from PyQt5.QtWidgets import QApplication
from ngmainwin import NgMainWin
app = QApplication(sys.argv)
mainWin = NgMainWin()
mainWi... | 16.714286 | 51 | 0.700855 | 48 | 351 | 5.083333 | 0.75 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.044521 | 0.168091 | 351 | 20 | 52 | 17.55 | 0.791096 | 0.467236 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.428571 | 0 | 0.428571 | 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 |
08267da019e951146931d8f65252ca8bb1d8a123 | 1,495 | py | Python | fact_checking/fact_checker.py | fractalego/fact_checking | 22cfa13280eefc1f3fcced8c99ff093c719dbf6c | [
"MIT"
] | 1 | 2022-02-07T23:41:16.000Z | 2022-02-07T23:41:16.000Z | fact_checking/fact_checker.py | fractalego/fact_checking | 22cfa13280eefc1f3fcced8c99ff093c719dbf6c | [
"MIT"
] | null | null | null | fact_checking/fact_checker.py | fractalego/fact_checking | 22cfa13280eefc1f3fcced8c99ff093c719dbf6c | [
"MIT"
] | null | null | null | from fact_checking.utils import (
create_prompt_from_evidence_and_claim,
generate_y_n_answer,
generate_multiple_y_n_answers)
class FactChecker:
def __init__(self, model, tokenizer):
'''
:param model: One of the models in this repository
:param tokenizer: The appropriate tokeni... | 39.342105 | 96 | 0.674916 | 193 | 1,495 | 4.994819 | 0.357513 | 0.057054 | 0.049793 | 0.074689 | 0.46888 | 0.358921 | 0.325726 | 0.325726 | 0.325726 | 0.325726 | 0 | 0.005343 | 0.248829 | 1,495 | 37 | 97 | 40.405405 | 0.853072 | 0.377926 | 0 | 0.133333 | 1 | 0 | 0.001244 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.2 | false | 0 | 0.066667 | 0 | 0.466667 | 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 |
083263a8ebe07676c72458573c8b36a308b9b73e | 4,228 | py | Python | SubsetRasterDatasetsWithShapefile.py | USEPA/Estimated_Floodplains_RandomForest | b602936a32ddd90591176b22068059ba83062cb1 | [
"Unlicense"
] | null | null | null | SubsetRasterDatasetsWithShapefile.py | USEPA/Estimated_Floodplains_RandomForest | b602936a32ddd90591176b22068059ba83062cb1 | [
"Unlicense"
] | null | null | null | SubsetRasterDatasetsWithShapefile.py | USEPA/Estimated_Floodplains_RandomForest | b602936a32ddd90591176b22068059ba83062cb1 | [
"Unlicense"
] | 1 | 2022-03-24T18:42:22.000Z | 2022-03-24T18:42:22.000Z | """
author: Jeremy Baynes
contact: baynes.jeremy@epa.gov
This script takes a set of raster datasets and a shapefile to
extract each dataset to the same extent (i.e., same columns and rows).
Primarily used to subset a series of large rasters (e.g., national extent) with
a vector datasets (e.g., HUCs, counties... | 34.655738 | 80 | 0.648061 | 566 | 4,228 | 4.666078 | 0.30212 | 0.056797 | 0.087088 | 0.102234 | 0.235895 | 0.167361 | 0.087846 | 0.087846 | 0.059069 | 0.032563 | 0 | 0.012454 | 0.221381 | 4,228 | 121 | 81 | 34.942149 | 0.789793 | 0.185667 | 0 | 0.09375 | 0 | 0 | 0.18486 | 0.052956 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.046875 | null | null | 0.03125 | 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 |
083760c2ef7be0a9969f76c8ffba25e677afa57d | 1,002 | py | Python | dailyReport/migrations/0008_auto_20220109_1959.py | seun-beta/foodcoApp | ded57db065dccb3e178b7e4f394385d14b1ed04a | [
"MIT"
] | null | null | null | dailyReport/migrations/0008_auto_20220109_1959.py | seun-beta/foodcoApp | ded57db065dccb3e178b7e4f394385d14b1ed04a | [
"MIT"
] | 5 | 2022-01-04T15:45:42.000Z | 2022-01-07T15:16:15.000Z | dailyReport/migrations/0008_auto_20220109_1959.py | seun-beta/foodco-backend | ded57db065dccb3e178b7e4f394385d14b1ed04a | [
"MIT"
] | null | null | null | # Generated by Django 3.2 on 2022-01-09 18:59
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('dailyReport', '0007_auto_20220109_1951'),
]
operations = [
migrations.CreateModel(
name='Pastry',
fields=[
... | 33.4 | 164 | 0.581836 | 98 | 1,002 | 5.795918 | 0.581633 | 0.06162 | 0.091549 | 0.091549 | 0.253521 | 0.253521 | 0.253521 | 0.253521 | 0.253521 | 0.253521 | 0 | 0.047684 | 0.267465 | 1,002 | 29 | 165 | 34.551724 | 0.726158 | 0.042914 | 0 | 0.130435 | 1 | 0 | 0.208986 | 0.024033 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.043478 | 0 | 0.173913 | 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 |
0838eb8796609352f4b71642094a07f454414979 | 3,273 | py | Python | ds/linkedlist.py | amresht/hackerrank | 184502d275654fde68b93c3a4fbb341bbf1f81ca | [
"MIT"
] | null | null | null | ds/linkedlist.py | amresht/hackerrank | 184502d275654fde68b93c3a4fbb341bbf1f81ca | [
"MIT"
] | null | null | null | ds/linkedlist.py | amresht/hackerrank | 184502d275654fde68b93c3a4fbb341bbf1f81ca | [
"MIT"
] | null | null | null | # LINKED list in python
# @AUTHOR - AMRESH TRIPATHI
class Node:
def __init__(self, data, next = None):
self.data = data
self.next = next # link to next node
class LinkedList:
# initialize with no values
def __init__(self, head=None):
self.head = head
#convert li... | 25.570313 | 71 | 0.541399 | 403 | 3,273 | 4.325062 | 0.287841 | 0.050488 | 0.041308 | 0.024096 | 0.166954 | 0.145152 | 0.133104 | 0.133104 | 0.102697 | 0.079174 | 0 | 0.00299 | 0.386801 | 3,273 | 128 | 72 | 25.570313 | 0.865471 | 0.329361 | 0 | 0.212121 | 0 | 0 | 0.011111 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.030303 | 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 |
08423528afca434a5680e6fd35a895af3958fc48 | 701 | py | Python | C04_Sorted.py | lleej/python | f4eff76819cec2c479ec19a4940141406079cb9a | [
"MIT"
] | null | null | null | C04_Sorted.py | lleej/python | f4eff76819cec2c479ec19a4940141406079cb9a | [
"MIT"
] | 2 | 2018-02-01T02:54:17.000Z | 2018-06-14T03:18:51.000Z | C04_Sorted.py | lleej/python | f4eff76819cec2c479ec19a4940141406079cb9a | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# 高阶函数
# sorted
## 翻转字符串
s = '12345'
d = sorted(s, reverse=True)
print(''.join(d))
s = '12345'
d = s[::-1]
print(d)
## 列表元素排序
L = [36, 5, -12, 9, -21]
print('列表', L, '排序: ', sorted(L))
## 按元素的绝对值排序
print('列表', L, '绝对值排序: ', sorted(L, key=abs))
## 字符串排序
L = ['bob', 'about', 'Zoo', 'Credit']
... | 16.302326 | 59 | 0.553495 | 121 | 701 | 3.173554 | 0.454545 | 0.145833 | 0.15625 | 0.15625 | 0.296875 | 0.208333 | 0.119792 | 0 | 0 | 0 | 0 | 0.054608 | 0.164051 | 701 | 42 | 60 | 16.690476 | 0.600683 | 0.118402 | 0 | 0.190476 | 0 | 0 | 0.124579 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.095238 | false | 0 | 0 | 0.095238 | 0.190476 | 0.47619 | 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 |
0847d068a6f29578ef8af69f09cd913501b24129 | 2,090 | py | Python | misc/test_cuda2.py | shenxudeu/deuNN | 81fcddd4da2be5f46d8e96e1a760a33a7e2579d2 | [
"MIT"
] | 1 | 2016-03-27T20:14:19.000Z | 2016-03-27T20:14:19.000Z | misc/test_cuda2.py | shenxudeu/deuNet | 81fcddd4da2be5f46d8e96e1a760a33a7e2579d2 | [
"MIT"
] | null | null | null | misc/test_cuda2.py | shenxudeu/deuNet | 81fcddd4da2be5f46d8e96e1a760a33a7e2579d2 | [
"MIT"
] | null | null | null | import numpy
import theano
import theano.tensor as T
import pdb
theano.config.floatX = 'float32'
rng = numpy.random
N = 40000
feats = 784
D = (rng.randn(N, feats).astype(theano.config.floatX),
rng.randint(size=N,low=0, high=2).astype(theano.config.floatX))
training_steps = 10000
# Declare Theano symbolic va... | 30.289855 | 90 | 0.65933 | 347 | 2,090 | 3.876081 | 0.363112 | 0.053532 | 0.080297 | 0.053532 | 0.301859 | 0.203717 | 0.178439 | 0.104089 | 0.062454 | 0.062454 | 0 | 0.027027 | 0.167943 | 2,090 | 68 | 91 | 30.735294 | 0.746406 | 0.249282 | 0 | 0.047619 | 0 | 0 | 0.109748 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.095238 | null | null | 0.190476 | 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 |
08564154ab951ac361f1967ae6a8beb6e71658c0 | 744 | py | Python | test/test_taxosaurus.py | Daniel-Davies/pytaxize | 446990c0f64c8360f1ee65fa7beaeb2410f6213d | [
"MIT"
] | 21 | 2015-02-23T19:41:09.000Z | 2020-11-04T15:11:20.000Z | test/test_taxosaurus.py | Daniel-Davies/pytaxize | 446990c0f64c8360f1ee65fa7beaeb2410f6213d | [
"MIT"
] | 56 | 2015-01-12T09:05:10.000Z | 2020-09-24T01:48:10.000Z | test/test_taxosaurus.py | Daniel-Davies/pytaxize | 446990c0f64c8360f1ee65fa7beaeb2410f6213d | [
"MIT"
] | 21 | 2015-01-12T08:45:02.000Z | 2020-09-10T01:01:43.000Z | import os
from nose.tools import *
import unittest
import vcr
import pytaxize
class Taxosaurus(unittest.TestCase):
@vcr.use_cassette("test/vcr_cassettes/taxo_datasources.yml")
def test_taxo_datasources(self):
"taxo_datasources"
res = pytaxize.taxo_datasources()
assert isinstance(res, l... | 31 | 78 | 0.678763 | 94 | 744 | 5.212766 | 0.404255 | 0.163265 | 0.193878 | 0.140816 | 0.363265 | 0.314286 | 0.314286 | 0.17551 | 0 | 0 | 0 | 0.00846 | 0.205645 | 744 | 23 | 79 | 32.347826 | 0.820643 | 0.038978 | 0 | 0.1 | 0 | 0 | 0.194892 | 0.099462 | 0 | 0 | 0 | 0 | 0.3 | 1 | 0.1 | false | 0 | 0.25 | 0 | 0.4 | 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 |
085ae1043123751ceec644afb17e483c0b1defab | 6,399 | py | Python | qurkexp/join/sort-results.py | marcua/qurk_experiments | 453c207ff50e730aefb6e1118e0f93e33babdb0b | [
"BSD-3-Clause"
] | 1 | 2015-09-30T00:09:06.000Z | 2015-09-30T00:09:06.000Z | qurkexp/join/sort-results.py | marcua/qurk_experiments | 453c207ff50e730aefb6e1118e0f93e33babdb0b | [
"BSD-3-Clause"
] | null | null | null | qurkexp/join/sort-results.py | marcua/qurk_experiments | 453c207ff50e730aefb6e1118e0f93e33babdb0b | [
"BSD-3-Clause"
] | null | null | null | #!/usr/bin/env python
import sys, os
ROOT = os.path.abspath('%s/../..' % os.path.abspath(os.path.dirname(__file__)))
sys.path.append(ROOT)
os.environ['DJANGO_SETTINGS_MODULE'] = 'qurkexp.settings'
from django.core.management import setup_environ
from django.conf import settings
from qurkexp.join.models import *
from q... | 41.551948 | 174 | 0.605251 | 940 | 6,399 | 3.992553 | 0.191489 | 0.011191 | 0.048495 | 0.063416 | 0.455635 | 0.40794 | 0.378098 | 0.362377 | 0.330136 | 0.287237 | 0 | 0.053126 | 0.267542 | 6,399 | 153 | 175 | 41.823529 | 0.7476 | 0.264416 | 0 | 0.198347 | 0 | 0.016529 | 0.13292 | 0.010274 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.049587 | null | null | 0.07438 | 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 |
f22d0e66e80a185cf38741504e292d02f6fcd35b | 157 | py | Python | Kontrollstrukturen/continue.py | swaldtmann/python-basic | 58f3b046942ca8da03a2c8e6ad9e3e29a8ff7bb4 | [
"MIT"
] | null | null | null | Kontrollstrukturen/continue.py | swaldtmann/python-basic | 58f3b046942ca8da03a2c8e6ad9e3e29a8ff7bb4 | [
"MIT"
] | null | null | null | Kontrollstrukturen/continue.py | swaldtmann/python-basic | 58f3b046942ca8da03a2c8e6ad9e3e29a8ff7bb4 | [
"MIT"
] | null | null | null | #!/usr/bin/env python
# -*- coding: utf-8 -*-
count = 0
while count < 10:
count += 1
if count % 2 == 0:
continue
print(count, end=" ")
| 14.272727 | 25 | 0.503185 | 22 | 157 | 3.590909 | 0.772727 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.064815 | 0.312102 | 157 | 10 | 26 | 15.7 | 0.666667 | 0.267516 | 0 | 0 | 0 | 0 | 0.00885 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0 | 0 | 0 | 0.166667 | 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 |
f22dba1be9051d1f49c8ac2cbeb334053630a03e | 2,356 | py | Python | Python/4 kyu/Ten-Pin Bowling/bowlingscore.py | newtonsspawn/codewars_challenges | 62b20d4e729c8ba79eac7cae6a179af57abd45d4 | [
"MIT"
] | 3 | 2020-05-29T23:29:35.000Z | 2021-08-12T03:16:44.000Z | Python/4 kyu/Ten-Pin Bowling/bowlingscore.py | newtonsspawn/codewars_challenges | 62b20d4e729c8ba79eac7cae6a179af57abd45d4 | [
"MIT"
] | null | null | null | Python/4 kyu/Ten-Pin Bowling/bowlingscore.py | newtonsspawn/codewars_challenges | 62b20d4e729c8ba79eac7cae6a179af57abd45d4 | [
"MIT"
] | 3 | 2020-05-22T12:14:55.000Z | 2021-04-15T12:52:42.000Z | def bowling_score(frames):
frames = [list(r) for r in frames.split(' ')]
points = 0
for f in range(0, 8):
if frames[f][0] == 'X':
points += 10
if frames[f+1][0] == 'X':
points += 10
if frames[f+2][0] == 'X':
p... | 29.45 | 67 | 0.396859 | 316 | 2,356 | 2.914557 | 0.120253 | 0.152009 | 0.117264 | 0.247557 | 0.754615 | 0.686211 | 0.661238 | 0.609121 | 0.513572 | 0.364821 | 0 | 0.117347 | 0.417657 | 2,356 | 79 | 68 | 29.822785 | 0.553936 | 0 | 0 | 0.633803 | 0 | 0 | 0.070034 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.014085 | false | 0 | 0 | 0 | 0.028169 | 0.070423 | 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 |
f2318b5596fd8aaff9890c66d20ca069f66b993b | 6,177 | py | Python | a4kSubtitles/services/bsplayer.py | peno64/a4kSubtitles | db48714e9c3d0c2a3fc27d5a5043c75a260dfdf0 | [
"MIT"
] | 72 | 2020-04-23T13:48:11.000Z | 2022-03-29T15:04:01.000Z | a4kSubtitles/services/bsplayer.py | peno64/a4kSubtitles | db48714e9c3d0c2a3fc27d5a5043c75a260dfdf0 | [
"MIT"
] | 50 | 2020-04-21T23:10:32.000Z | 2022-03-20T23:12:32.000Z | a4kSubtitles/services/bsplayer.py | rrosajp/a4kSubtitles | 70dc1b91070ad9eb94fe05deb6d1a94e5fc8a56c | [
"MIT"
] | 17 | 2020-04-22T11:12:45.000Z | 2022-03-27T08:50:13.000Z | # -*- coding: utf-8 -*-
__soap_format = (
'<?xml version="1.0" encoding="UTF-8"?>\n'
'<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" '
'xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" '
'xmlns:xsi="http://www.w3.org/2001/XM... | 31.040201 | 118 | 0.613405 | 727 | 6,177 | 5.022008 | 0.247593 | 0.08436 | 0.082169 | 0.056697 | 0.381813 | 0.326212 | 0.247877 | 0.208162 | 0.181868 | 0.138592 | 0 | 0.020017 | 0.247855 | 6,177 | 198 | 119 | 31.19697 | 0.76582 | 0.0034 | 1 | 0.240506 | 0 | 0.012658 | 0.187358 | 0.037374 | 0 | 0 | 0 | 0 | 0 | 1 | 0.082278 | false | 0.006329 | 0 | 0 | 0.234177 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
f2391ac19d21fed5aa196653df941ba28c83b42b | 8,866 | py | Python | src/run.py | santteegt/ucl-drl-msc | eec0cdb634cc1a33eee17e5f1f045784040a70e8 | [
"Apache-2.0"
] | 24 | 2017-07-20T03:41:48.000Z | 2021-07-26T03:27:26.000Z | src/run.py | santteegt/ucl-drl-msc | eec0cdb634cc1a33eee17e5f1f045784040a70e8 | [
"Apache-2.0"
] | 4 | 2017-04-01T08:54:30.000Z | 2018-04-03T01:12:46.000Z | src/run.py | santteegt/ucl-drl-msc | eec0cdb634cc1a33eee17e5f1f045784040a70e8 | [
"Apache-2.0"
] | 8 | 2017-03-21T18:22:15.000Z | 2020-05-07T08:44:09.000Z | #!/usr/bin/env python
import os
import experiment
import gym
import numpy as np
import filter_env
import ddpg
import wolpertinger as wp
import fmpolicy as fmp
import tensorflow as tf
import time
flags = tf.app.flags
FLAGS = flags.FLAGS
flags.DEFINE_boolean('upload',False,'upload to gym (requires evironment variable OPE... | 43.24878 | 123 | 0.656102 | 1,255 | 8,866 | 4.494024 | 0.196813 | 0.037234 | 0.024823 | 0.014894 | 0.394149 | 0.317731 | 0.23617 | 0.197518 | 0.15922 | 0.143262 | 0 | 0.008815 | 0.21949 | 8,866 | 204 | 124 | 43.460784 | 0.806214 | 0.199977 | 0 | 0.138686 | 0 | 0 | 0.171015 | 0.007799 | 0 | 0 | 0 | 0.004902 | 0.007299 | 0 | null | null | 0 | 0.080292 | null | null | 0.036496 | 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 |
f23b926d617a68b89243102ebd5f6a2146b445d2 | 3,531 | py | Python | aves/api/settings.py | krunal10/aves | 9639ae3b1422cf28bbe804fa6d15ee7d1462c29f | [
"MIT"
] | null | null | null | aves/api/settings.py | krunal10/aves | 9639ae3b1422cf28bbe804fa6d15ee7d1462c29f | [
"MIT"
] | null | null | null | aves/api/settings.py | krunal10/aves | 9639ae3b1422cf28bbe804fa6d15ee7d1462c29f | [
"MIT"
] | null | null | null | import os
import sys
from decouple import Csv, config
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
ROOT_DIR = os.path.dirname(BASE_DIR)
sys.path.append(BASE_DIR)
# Quick-start development settings - unsuitable for produ... | 29.672269 | 93 | 0.705183 | 397 | 3,531 | 6.128463 | 0.397985 | 0.069462 | 0.054254 | 0.061652 | 0.120427 | 0.079326 | 0.078093 | 0.029593 | 0 | 0 | 0 | 0.006081 | 0.161711 | 3,531 | 118 | 94 | 29.923729 | 0.815878 | 0.244973 | 0 | 0.026316 | 0 | 0 | 0.508141 | 0.423703 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.039474 | 0 | 0.039474 | 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 | 1 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
f2434852e63872dcb198c7def8225d5da93abd51 | 1,052 | py | Python | testtools/dictionarysplicer.py | afy2103/spambayes-9-10-Frozen | 383db71e3b7b2141975cf66e6d223bb437511776 | [
"PSF-2.0"
] | null | null | null | testtools/dictionarysplicer.py | afy2103/spambayes-9-10-Frozen | 383db71e3b7b2141975cf66e6d223bb437511776 | [
"PSF-2.0"
] | null | null | null | testtools/dictionarysplicer.py | afy2103/spambayes-9-10-Frozen | 383db71e3b7b2141975cf66e6d223bb437511776 | [
"PSF-2.0"
] | null | null | null | __author__ = 'Alex'
import os
import sys
sys.path.insert(-1, os.getcwd())
sys.path.insert(-1, os.path.dirname(os.getcwd()))
from spambayes.Options import get_pathname_option
from os import listdir, remove
# Assume that Set3 is already populated with dictionaries to splice.
def splice(dict_dest, n):
dictionary =... | 25.047619 | 102 | 0.648289 | 149 | 1,052 | 4.355705 | 0.442953 | 0.03698 | 0.040062 | 0.043143 | 0.049307 | 0 | 0 | 0 | 0 | 0 | 0 | 0.012121 | 0.215779 | 1,052 | 41 | 103 | 25.658537 | 0.774545 | 0.062738 | 0 | 0 | 0 | 0 | 0.088415 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.133333 | 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 |
f244a2f9dd794d5f241c4226646aea3ca98b749f | 1,666 | py | Python | ask_melnikov/ask/migrations/0006_auto_20171114_1346.py | BatrSens/ask_melnikov | 4aa6565fbc86454c168feec585f8abde5e30ab0b | [
"MIT"
] | null | null | null | ask_melnikov/ask/migrations/0006_auto_20171114_1346.py | BatrSens/ask_melnikov | 4aa6565fbc86454c168feec585f8abde5e30ab0b | [
"MIT"
] | null | null | null | ask_melnikov/ask/migrations/0006_auto_20171114_1346.py | BatrSens/ask_melnikov | 4aa6565fbc86454c168feec585f8abde5e30ab0b | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
# Generated by Django 1.11.7 on 2017-11-14 13:46
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('ask', '0005_user'),
]
operations = [
migra... | 28.724138 | 111 | 0.54922 | 165 | 1,666 | 5.412121 | 0.442424 | 0.090705 | 0.101904 | 0.133259 | 0.446809 | 0.446809 | 0.159015 | 0.159015 | 0.159015 | 0.159015 | 0 | 0.022968 | 0.320528 | 1,666 | 57 | 112 | 29.22807 | 0.765901 | 0.040816 | 0 | 0.48 | 1 | 0 | 0.094044 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.06 | 0 | 0.12 | 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 |
f25a62ed0c3be113484c33482d13ccc6c141a7d2 | 1,472 | py | Python | pyipptool/config.py | doudz/pyipptool | d9cfef11627cc90ac921474749232ebfe62b2b6e | [
"Apache-2.0"
] | 22 | 2015-06-19T12:56:25.000Z | 2021-09-23T16:19:10.000Z | pyipptool/config.py | doudz/pyipptool | d9cfef11627cc90ac921474749232ebfe62b2b6e | [
"Apache-2.0"
] | 5 | 2015-12-02T18:49:45.000Z | 2021-10-03T18:59:17.000Z | pyipptool/config.py | doudz/pyipptool | d9cfef11627cc90ac921474749232ebfe62b2b6e | [
"Apache-2.0"
] | 9 | 2017-02-25T07:37:59.000Z | 2022-01-06T07:41:13.000Z | import os
from future import standard_library
with standard_library.hooks():
import configparser
def read_config(paths=()):
config = {}
fs_config = configparser.ConfigParser()
fs_config.read(paths)
config['cups_uri'] = fs_config.get('main', 'cups_uri')
config['ipptool_path'] = fs_config.get('... | 28.862745 | 66 | 0.619565 | 160 | 1,472 | 5.48125 | 0.3375 | 0.072976 | 0.050171 | 0.068415 | 0.100342 | 0.100342 | 0 | 0 | 0 | 0 | 0 | 0.00274 | 0.256114 | 1,472 | 50 | 67 | 29.44 | 0.798174 | 0 | 0 | 0.238095 | 0 | 0 | 0.152174 | 0.066576 | 0 | 0 | 0 | 0 | 0 | 1 | 0.095238 | false | 0.071429 | 0.071429 | 0.02381 | 0.261905 | 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 |
f25ab4967fa74fd482cd2af7ec62011886122de9 | 455 | py | Python | WebMirror/management/rss_parser_funcs/feed_parse_extractWLTranslations.py | fake-name/ReadableWebProxy | ed5c7abe38706acc2684a1e6cd80242a03c5f010 | [
"BSD-3-Clause"
] | 193 | 2016-08-02T22:04:35.000Z | 2022-03-09T20:45:41.000Z | WebMirror/management/rss_parser_funcs/feed_parse_extractWLTranslations.py | fake-name/ReadableWebProxy | ed5c7abe38706acc2684a1e6cd80242a03c5f010 | [
"BSD-3-Clause"
] | 533 | 2016-08-23T20:48:23.000Z | 2022-03-28T15:55:13.000Z | WebMirror/management/rss_parser_funcs/feed_parse_extractWLTranslations.py | rrosajp/ReadableWebProxy | ed5c7abe38706acc2684a1e6cd80242a03c5f010 | [
"BSD-3-Clause"
] | 19 | 2015-08-13T18:01:08.000Z | 2021-07-12T17:13:09.000Z | def extractWLTranslations(item):
"""
# 'WL Translations'
"""
vol, chp, frag, postfix = extractVolChapterFragmentPostfix(item['title'])
if not (chp or vol or frag) or 'preview' in item['title'].lower():
return None
if 'Chapter Releases' in item['tags'] and ('OSI' in item['tags'] or item['title'].startswith('OSI ... | 41.363636 | 110 | 0.714286 | 59 | 455 | 5.508475 | 0.525424 | 0.083077 | 0.061538 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.134066 | 455 | 10 | 111 | 45.5 | 0.824873 | 0.041758 | 0 | 0 | 0 | 0 | 0.197183 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.142857 | false | 0 | 0 | 0 | 0.571429 | 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 |
f25fa98c5e39692ddedbb5c820dfa5cd10c8c438 | 621 | py | Python | setup.py | WISDEM/TowerSE | 4c528ecf33127cc1a36af175c82e504fd70e6724 | [
"Apache-2.0"
] | 2 | 2015-07-09T15:21:56.000Z | 2015-09-27T06:20:48.000Z | setup.py | WISDEM/TowerSE | 4c528ecf33127cc1a36af175c82e504fd70e6724 | [
"Apache-2.0"
] | 5 | 2015-02-07T17:15:25.000Z | 2020-05-03T21:25:28.000Z | setup.py | WISDEM/TowerSE | 4c528ecf33127cc1a36af175c82e504fd70e6724 | [
"Apache-2.0"
] | 5 | 2015-07-18T19:06:07.000Z | 2021-04-19T18:40:30.000Z | #!/usr/bin/env python
# encoding: utf-8
from setuptools import setup
setup(
name='TowerSE',
version='0.1.1',
description='Tower Systems Engineering Model',
author='NREL WISDEM Team',
author_email='systems.engineering@nrel.gov',
install_requires=['openmdao>=1.5', 'commonse', 'pyframe3dd'],
... | 29.571429 | 82 | 0.671498 | 78 | 621 | 5.282051 | 0.717949 | 0.087379 | 0.067961 | 0.097087 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.017274 | 0.161031 | 621 | 20 | 83 | 31.05 | 0.773512 | 0.312399 | 0 | 0 | 0 | 0 | 0.369048 | 0.066667 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | true | 0 | 0.076923 | 0 | 0.076923 | 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 |
f263e9b0e7d010972621427051631e5737e27ef0 | 2,876 | py | Python | tests/exchange/test_poloniex.py | nongnoobjung/catalyst | 94583c2684ca5e43b3a21296789dd21378be66aa | [
"Apache-2.0"
] | null | null | null | tests/exchange/test_poloniex.py | nongnoobjung/catalyst | 94583c2684ca5e43b3a21296789dd21378be66aa | [
"Apache-2.0"
] | null | null | null | tests/exchange/test_poloniex.py | nongnoobjung/catalyst | 94583c2684ca5e43b3a21296789dd21378be66aa | [
"Apache-2.0"
] | null | null | null | from catalyst.exchange.poloniex.poloniex import Poloniex
from catalyst.finance.order import Order
from base import BaseExchangeTestCase
from logbook import Logger
from catalyst.exchange.exchange_utils import get_exchange_auth
import pandas as pd
from catalyst.utils.deprecate import deprecated
from test_utils import ou... | 29.649485 | 75 | 0.621001 | 345 | 2,876 | 5.017391 | 0.321739 | 0.103986 | 0.095321 | 0.069324 | 0.084922 | 0.082034 | 0.036973 | 0 | 0 | 0 | 0 | 0.029665 | 0.273296 | 2,876 | 96 | 76 | 29.958333 | 0.798565 | 0.09249 | 0 | 0.118421 | 0 | 0 | 0.149827 | 0.02766 | 0 | 0 | 0 | 0 | 0.039474 | 1 | 0.131579 | false | 0.118421 | 0.105263 | 0 | 0.25 | 0.013158 | 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 |
f266316ef4dcfd971e270188972d218e1f2d273c | 1,127 | py | Python | main.py | dezounet/google_hash_code_2020 | 65a289951aab6dc05d6edd087f85a373cb4c2e11 | [
"MIT"
] | 1 | 2020-02-20T17:25:41.000Z | 2020-02-20T17:25:41.000Z | main.py | dezounet/google_hash_code_2020 | 65a289951aab6dc05d6edd087f85a373cb4c2e11 | [
"MIT"
] | 1 | 2020-02-20T17:41:45.000Z | 2020-02-20T17:41:45.000Z | main.py | dezounet/google_hash_code_2020 | 65a289951aab6dc05d6edd087f85a373cb4c2e11 | [
"MIT"
] | null | null | null | import os
import sys
from config import INPUT_DIRECTORY
from config import OUTPUT_DIRECTORY
from read import read
from score import get_best_score
from write import write
if __name__ == '__main__':
# Get input file from command line arg list
input_file = sys.argv[1]
file_path = os.path.join(INPUT_DIRECT... | 26.209302 | 62 | 0.680568 | 159 | 1,127 | 4.559748 | 0.308176 | 0.111724 | 0.049655 | 0.044138 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.005841 | 0.240461 | 1,127 | 42 | 63 | 26.833333 | 0.841122 | 0.168589 | 0 | 0 | 0 | 0 | 0.084855 | 0 | 0 | 0 | 0 | 0.02381 | 0.038462 | 1 | 0 | false | 0 | 0.269231 | 0 | 0.269231 | 0.076923 | 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 |
f26695f2071ab9142891c6c485eac6aec662287d | 1,923 | py | Python | arhuaco/analysis/util/metric.py | kuronosec/arhuaco | 6eec1691dd03b2e3726ae8c2101588b45d58b6d7 | [
"Apache-2.0"
] | 1 | 2020-08-08T02:17:34.000Z | 2020-08-08T02:17:34.000Z | arhuaco/analysis/util/metric.py | kuronosec/arhuaco | 6eec1691dd03b2e3726ae8c2101588b45d58b6d7 | [
"Apache-2.0"
] | null | null | null | arhuaco/analysis/util/metric.py | kuronosec/arhuaco | 6eec1691dd03b2e3726ae8c2101588b45d58b6d7 | [
"Apache-2.0"
] | null | null | null | # Copyright (c) 2019 Andres Gomez Ramirez.
# All Rights Reserved.
import os
import numpy as np
import keras.backend as K
# A set of utilities for calculating evaluation metrics.
class Metric:
# TODO: is there a way to make a more compact method
# that calculates all theses metrics?
def false_pos_rate(s... | 30.046875 | 56 | 0.587624 | 352 | 1,923 | 2.923295 | 0.178977 | 0.165209 | 0.116618 | 0.077745 | 0.586978 | 0.586978 | 0.586978 | 0.586978 | 0.586978 | 0.586978 | 0 | 0.020787 | 0.299532 | 1,923 | 63 | 57 | 30.52381 | 0.743133 | 0.105564 | 0 | 0.652174 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.015873 | 0 | 1 | 0.086957 | false | 0 | 0.065217 | 0 | 0.26087 | 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 |
f269bb649678e9f30d8af12a2172e0d7c5ab3ee6 | 1,455 | py | Python | CreateSurrogates/CNS_surrogate_trait.py | pik-copan/pydrf | 998072d655331ca6669c71bb6df665292e8972e7 | [
"BSD-3-Clause"
] | 1 | 2021-10-01T09:01:30.000Z | 2021-10-01T09:01:30.000Z | CreateSurrogates/CNS_surrogate_trait.py | pik-copan/pydrf | 998072d655331ca6669c71bb6df665292e8972e7 | [
"BSD-3-Clause"
] | null | null | null | CreateSurrogates/CNS_surrogate_trait.py | pik-copan/pydrf | 998072d655331ca6669c71bb6df665292e8972e7 | [
"BSD-3-Clause"
] | 1 | 2021-10-01T09:02:54.000Z | 2021-10-01T09:02:54.000Z | from sensible_raw.loaders import loader
from world_viewer.cns_world import CNSWorld
from world_viewer.glasses import Glasses
import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
import networkx as nx
from matplotlib.colors import LogNorm
from sklearn.utils import shuffle
folder = "tmp/Shuffled/"
# l... | 37.307692 | 112 | 0.747766 | 234 | 1,455 | 4.393162 | 0.337607 | 0.074903 | 0.097276 | 0.052529 | 0.152724 | 0.050584 | 0 | 0 | 0 | 0 | 0 | 0.018096 | 0.12646 | 1,455 | 38 | 113 | 38.289474 | 0.790716 | 0.026804 | 0 | 0 | 0 | 0 | 0.125354 | 0.067989 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.321429 | 0 | 0.321429 | 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 |
f26e23dfba9f106e6d6efac8f083dd0fa5d4fe16 | 2,378 | py | Python | deid/embeddings/embeddings.py | KavishBhatia/deid-training-data | 9d586cd7f52d929b2571028365587d3f96e44caa | [
"MIT"
] | 15 | 2018-10-28T13:57:55.000Z | 2022-01-03T07:25:04.000Z | deid/embeddings/embeddings.py | KavishBhatia/deid-training-data | 9d586cd7f52d929b2571028365587d3f96e44caa | [
"MIT"
] | 7 | 2019-04-29T13:55:52.000Z | 2021-12-13T19:51:30.000Z | deid/embeddings/embeddings.py | KavishBhatia/deid-training-data | 9d586cd7f52d929b2571028365587d3f96e44caa | [
"MIT"
] | 3 | 2019-08-01T19:02:37.000Z | 2021-01-08T09:12:25.000Z | from typing import Sequence, Dict
import numpy as np
class Embeddings:
""" Flexible base class for embeddings that doesn't necessarily use a matrix """
@property
def size(self) -> int:
raise NotImplementedError
@property
def mean(self) -> float:
return 0.
@property
def ... | 31.289474 | 119 | 0.66905 | 293 | 2,378 | 5.406143 | 0.279863 | 0.151515 | 0.085227 | 0.088384 | 0.578914 | 0.464015 | 0.422348 | 0.422348 | 0.364268 | 0.237374 | 0 | 0.001125 | 0.252313 | 2,378 | 75 | 120 | 31.706667 | 0.889764 | 0.374685 | 0 | 0.675676 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.351351 | false | 0 | 0.054054 | 0.027027 | 0.540541 | 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 |
f26f808f0b25ac557b013bf620e5180d310fd35f | 723 | py | Python | app/app/wsgi.py | ulflundgren/recipie-app-api | 63aae96c9c7fc5f9cea8fb334e552c06352ea6ba | [
"MIT"
] | null | null | null | app/app/wsgi.py | ulflundgren/recipie-app-api | 63aae96c9c7fc5f9cea8fb334e552c06352ea6ba | [
"MIT"
] | null | null | null | app/app/wsgi.py | ulflundgren/recipie-app-api | 63aae96c9c7fc5f9cea8fb334e552c06352ea6ba | [
"MIT"
] | null | null | null | """
WSGI config for app project.
It exposes the WSGI callable as a module-level variable named ``application``.
For more information on this file, see
https://docs.djangoproject.com/en/3.0/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault('DJANGO_SETTINGS_... | 28.92 | 78 | 0.735823 | 112 | 723 | 4.660714 | 0.625 | 0.011494 | 0.068966 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.016447 | 0.159059 | 723 | 24 | 79 | 30.125 | 0.842105 | 0.53527 | 0 | 0 | 0 | 0 | 0.16358 | 0.067901 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.375 | 0 | 0.375 | 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 |
f26f9424a65b4b2e91fdcb266e5124d9641fa312 | 346 | py | Python | blog/migrations/0004_alter_category_options.py | chandelures/chandeblog | 4b44f199fdf652ab09d705f4f93e2a24c9595a4b | [
"MIT"
] | 2 | 2020-01-02T04:00:04.000Z | 2021-04-15T16:43:24.000Z | blog/migrations/0004_alter_category_options.py | chandelures/chandeblog | 4b44f199fdf652ab09d705f4f93e2a24c9595a4b | [
"MIT"
] | 18 | 2020-06-05T20:09:22.000Z | 2022-03-31T00:13:14.000Z | blog/migrations/0004_alter_category_options.py | chandelures/chandeblog | 4b44f199fdf652ab09d705f4f93e2a24c9595a4b | [
"MIT"
] | null | null | null | # Generated by Django 3.2.7 on 2021-09-23 05:16
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('blog', '0003_alter_image_img'),
]
operations = [
migrations.AlterModelOptions(
name='category',
options={'ordering': ('-crea... | 19.222222 | 48 | 0.583815 | 35 | 346 | 5.685714 | 0.885714 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.076613 | 0.283237 | 346 | 17 | 49 | 20.352941 | 0.725806 | 0.130058 | 0 | 0 | 1 | 0 | 0.160535 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.090909 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
f27b814c3b59f2fcc8b8b5e9b397f5ae164dc70b | 7,915 | py | Python | fxprime/NN_regression_strategy.py | jamescorsini/FXprime | 49725997891e7bb20423d8a1a69116d5821e965c | [
"MIT"
] | 2 | 2017-10-20T08:46:47.000Z | 2019-03-12T14:40:50.000Z | fxprime/NN_regression_strategy.py | jamescorsini/FXprime | 49725997891e7bb20423d8a1a69116d5821e965c | [
"MIT"
] | 5 | 2017-04-18T17:24:47.000Z | 2018-12-06T03:39:07.000Z | fxprime/NN_regression_strategy.py | jamescorsini/FXprime | 49725997891e7bb20423d8a1a69116d5821e965c | [
"MIT"
] | 1 | 2021-09-10T17:27:32.000Z | 2021-09-10T17:27:32.000Z | # -*- coding: utf-8 -*-
"""
Created on Sun Jun 05 12:05:28 2016
@author: james
"""
import logging
#from fxprime import scripts
from fxprime import output
from settings import *
import os
import dateutil.parser
from sklearn import svm
import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
#from skl... | 34.714912 | 168 | 0.509033 | 957 | 7,915 | 4.117032 | 0.3093 | 0.038071 | 0.018274 | 0.012183 | 0.175381 | 0.129695 | 0.073096 | 0.036548 | 0.036548 | 0.036548 | 0 | 0.031493 | 0.36614 | 7,915 | 227 | 169 | 34.867841 | 0.753837 | 0.157423 | 0 | 0.069767 | 0 | 0 | 0.075033 | 0 | 0 | 0 | 0 | 0.004405 | 0 | 0 | null | null | 0 | 0.069767 | null | null | 0.046512 | 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 |
f284e00b405972e16d63c07feceeda47a3faa2d6 | 31,648 | py | Python | contribute/struc.py | biocad/leadoptmap | 203674fc1f2991ab5cabcc574e923cff16cb6c6e | [
"BSD-3-Clause"
] | 1 | 2022-02-15T13:28:30.000Z | 2022-02-15T13:28:30.000Z | contribute/struc.py | OpenFreeEnergy/leadoptmap | 203674fc1f2991ab5cabcc574e923cff16cb6c6e | [
"BSD-3-Clause"
] | null | null | null | contribute/struc.py | OpenFreeEnergy/leadoptmap | 203674fc1f2991ab5cabcc574e923cff16cb6c6e | [
"BSD-3-Clause"
] | 1 | 2022-02-15T13:28:30.000Z | 2022-02-15T13:28:30.000Z | """Defines a `Struc' class as a generic represention of molecular structure
"""
from kbase import KBASE
import os
import copy
import hashlib
# Flag indicating which infrastructure we are using.
infrastructure = None # "schrodinger" | "oechem"
class _AtomContainer( object ) :
"""
"""
def __init... | 36.377011 | 179 | 0.442366 | 3,135 | 31,648 | 4.349601 | 0.103349 | 0.036301 | 0.015914 | 0.027427 | 0.632297 | 0.603036 | 0.564682 | 0.522954 | 0.508214 | 0.492593 | 0 | 0.00402 | 0.481231 | 31,648 | 869 | 180 | 36.418872 | 0.826532 | 0.012449 | 0 | 0.528796 | 0 | 0.005236 | 0.064446 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.005236 | 0.028796 | null | null | 0.013089 | 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 |
f2962c272268564905721bc37dcf8fa1204aff89 | 2,744 | py | Python | Ago-Dic-2017/Omar Abasta/ordinario/hotelDAS/hotelDAS/app/migrations/0001_initial.py | angelicardz/DAS_Sistemas | e2a69fec358f0fad4fe05c39ea6168c89eed41ac | [
"MIT"
] | 41 | 2017-09-26T09:36:32.000Z | 2022-03-19T18:05:25.000Z | Ago-Dic-2017/Omar Abasta/ordinario/hotelDAS/hotelDAS/app/migrations/0001_initial.py | angelicardz/DAS_Sistemas | e2a69fec358f0fad4fe05c39ea6168c89eed41ac | [
"MIT"
] | 67 | 2017-09-11T05:06:12.000Z | 2022-02-14T04:44:04.000Z | Ago-Dic-2017/Omar Abasta/ordinario/hotelDAS/hotelDAS/app/migrations/0001_initial.py | angelicardz/DAS_Sistemas | e2a69fec358f0fad4fe05c39ea6168c89eed41ac | [
"MIT"
] | 210 | 2017-09-01T00:10:08.000Z | 2022-03-19T18:05:12.000Z | # -*- coding: utf-8 -*-
# Generated by Django 1.11.8 on 2017-12-07 06:33
from __future__ import unicode_literals
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.Crea... | 38.111111 | 117 | 0.564869 | 245 | 2,744 | 6.220408 | 0.359184 | 0.026247 | 0.082021 | 0.075459 | 0.440945 | 0.351706 | 0.255906 | 0.199475 | 0.199475 | 0.171916 | 0 | 0.020291 | 0.299563 | 2,744 | 71 | 118 | 38.647887 | 0.772633 | 0.024781 | 0 | 0.47619 | 1 | 0 | 0.09914 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | false | 0 | 0.047619 | 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 | 1 | 0 | 0 | 0 | null | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 |
f29a526e4672b76e344cde0a8eb0f159f1652a1f | 3,932 | py | Python | example/flight_replay/flight_replay.py | dgorissen/dronekit-python | 040c78381d740184f58c91a37fb80b7fa7b675ff | [
"Apache-2.0"
] | null | null | null | example/flight_replay/flight_replay.py | dgorissen/dronekit-python | 040c78381d740184f58c91a37fb80b7fa7b675ff | [
"Apache-2.0"
] | null | null | null | example/flight_replay/flight_replay.py | dgorissen/dronekit-python | 040c78381d740184f58c91a37fb80b7fa7b675ff | [
"Apache-2.0"
] | 1 | 2019-12-27T15:33:52.000Z | 2019-12-27T15:33:52.000Z | #
# This is an example of talking to Droneshare to receive a past flight, and then 'replaying' that flight by sending waypoints
# to the vehicle that approximates the stored flight log.
# Usage:
# * mavproxy.py
# * module load api
# * api start flight_replay.py <missionid>
# (Where mission ID is a numeric mission numbe... | 37.447619 | 129 | 0.60885 | 506 | 3,932 | 4.608696 | 0.371542 | 0.006003 | 0.006432 | 0.020583 | 0.138079 | 0.103774 | 0.049743 | 0.049743 | 0.049743 | 0.049743 | 0 | 0.019134 | 0.295524 | 3,932 | 104 | 130 | 37.807692 | 0.822744 | 0.191251 | 0 | 0.082192 | 0 | 0.013699 | 0.103901 | 0.045564 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.041096 | null | null | 0.041096 | 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 |
f29d7e532cc908db83a84f9aa4e996a873325da5 | 718 | py | Python | Data Structures/Array/Programs/count_frequenct.py | chasesagar/Python-Programming | 310c082955b7069738e0f2b6941cbc19796cdb7f | [
"MIT"
] | null | null | null | Data Structures/Array/Programs/count_frequenct.py | chasesagar/Python-Programming | 310c082955b7069738e0f2b6941cbc19796cdb7f | [
"MIT"
] | null | null | null | Data Structures/Array/Programs/count_frequenct.py | chasesagar/Python-Programming | 310c082955b7069738e0f2b6941cbc19796cdb7f | [
"MIT"
] | null | null | null | # A program to calculate frequency of array elements
class ArrayBasic:
def __init__(self, arr, n):
self.arr = arr
self.n = n
def calculate_frequency_hash_map(self):
"""
[A program to calculate counting frequency of array elements]
Time complexity: O(n)
Auxiliary... | 26.592593 | 81 | 0.5961 | 102 | 718 | 4.04902 | 0.441176 | 0.118644 | 0.116223 | 0.174334 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.033663 | 0.296657 | 718 | 27 | 81 | 26.592593 | 0.784158 | 0.285515 | 0 | 0 | 0 | 0 | 0.155361 | 0.085339 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0 | 0 | 0.333333 | 0.083333 | 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 |
f29e5da956204e10e60643ca2aeba4a20beae97b | 1,368 | py | Python | class2/walk2.py | patrebert/pynet_cert | b82cce3ddb20d9e4abc89d74579ddeb3513bdf55 | [
"Apache-2.0"
] | null | null | null | class2/walk2.py | patrebert/pynet_cert | b82cce3ddb20d9e4abc89d74579ddeb3513bdf55 | [
"Apache-2.0"
] | null | null | null | class2/walk2.py | patrebert/pynet_cert | b82cce3ddb20d9e4abc89d74579ddeb3513bdf55 | [
"Apache-2.0"
] | null | null | null | #!/usr/bin/env python
"""
Demonstrate use of pysnmp walks
"""
import sys
import re
from pysnmp.entity.rfc3413.oneliner import cmdgen
cmdGen = cmdgen.CommandGenerator()
devip = sys.argv.pop(1)
errorIndication, errorStatus, errorIndex, varBindTable = cmdGen.nextCmd(
cmdgen.CommunityData('server', 'galileo', 1),
... | 28.5 | 72 | 0.557749 | 143 | 1,368 | 5.335664 | 0.48951 | 0.015727 | 0.039318 | 0.04325 | 0.070773 | 0.070773 | 0.070773 | 0 | 0 | 0 | 0 | 0.018143 | 0.315058 | 1,368 | 47 | 73 | 29.106383 | 0.796158 | 0.01462 | 0 | 0.108108 | 0 | 0 | 0.061927 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0 | 0.081081 | null | null | 0.081081 | 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 |
f29e876f772ab4a4ac5bc3888d8a0ba65fa612df | 19,422 | py | Python | app/backend/src/couchers/models.py | Almenon/couchers | 30c13fbb48a8b7ceaaf7e79ef92655a4672a14b3 | [
"MIT"
] | null | null | null | app/backend/src/couchers/models.py | Almenon/couchers | 30c13fbb48a8b7ceaaf7e79ef92655a4672a14b3 | [
"MIT"
] | null | null | null | app/backend/src/couchers/models.py | Almenon/couchers | 30c13fbb48a8b7ceaaf7e79ef92655a4672a14b3 | [
"MIT"
] | null | null | null | import enum
from calendar import monthrange
from datetime import date
from sqlalchemy import Boolean, Column, Date, DateTime, Enum, Float, ForeignKey, Integer
from sqlalchemy import LargeBinary as Binary
from sqlalchemy import MetaData, String, UniqueConstraint, func
from sqlalchemy.ext.declarative import declarative_... | 33.086882 | 181 | 0.692462 | 2,378 | 19,422 | 5.479394 | 0.164003 | 0.068841 | 0.052187 | 0.043899 | 0.455564 | 0.37759 | 0.326861 | 0.300767 | 0.278511 | 0.251804 | 0 | 0.004275 | 0.193132 | 19,422 | 586 | 182 | 33.143345 | 0.827197 | 0.13356 | 0 | 0.25 | 0 | 0.018519 | 0.132715 | 0.07051 | 0 | 0 | 0 | 0.006826 | 0 | 1 | 0.064815 | false | 0.015432 | 0.033951 | 0.04321 | 0.808642 | 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 |
f29e8ec36f0c9d17d92c2e75710b7e779a18ddc6 | 437 | py | Python | app/processor/common.py | ken-pan/wallpaper-downloader | b39efce45d1634452879c8e41824f861b439fabd | [
"Apache-2.0"
] | 2 | 2020-02-18T09:23:02.000Z | 2020-02-18T09:23:04.000Z | app/processor/common.py | ken-pan/wallpaper-downloader | b39efce45d1634452879c8e41824f861b439fabd | [
"Apache-2.0"
] | null | null | null | app/processor/common.py | ken-pan/wallpaper-downloader | b39efce45d1634452879c8e41824f861b439fabd | [
"Apache-2.0"
] | null | null | null | from concurrent.futures import ThreadPoolExecutor
from ..config import Config
from ..util import PathFormat
class Processor(Config):
category = 'processor'
def __init__(self):
self.executor = ThreadPoolExecutor(max_workers=int(self.config('MaxWorkers')))
def submit(self, func, extractor):
... | 23 | 86 | 0.707094 | 47 | 437 | 6.468085 | 0.510638 | 0.078947 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.196796 | 437 | 18 | 87 | 24.277778 | 0.866097 | 0 | 0 | 0 | 0 | 0 | 0.043678 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.181818 | false | 0 | 0.272727 | 0 | 0.636364 | 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 |
f2a10615d4a44f09da2d7683698e6ef49ea99520 | 275 | py | Python | src/envassert/group.py | shirou/envassert | 1113eb7fd1b1dffa28243e9fd11fd49830388124 | [
"MIT"
] | null | null | null | src/envassert/group.py | shirou/envassert | 1113eb7fd1b1dffa28243e9fd11fd49830388124 | [
"MIT"
] | null | null | null | src/envassert/group.py | shirou/envassert | 1113eb7fd1b1dffa28243e9fd11fd49830388124 | [
"MIT"
] | null | null | null | from __future__ import with_statement
from fabric.api import run, env, hide, sudo
def is_exists(name):
with hide("everything"):
group_data = run("getent group | egrep '^%s:' ; true" % (name))
if group_data:
return True
else:
return None
| 22.916667 | 71 | 0.636364 | 37 | 275 | 4.513514 | 0.702703 | 0.107784 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.258182 | 275 | 11 | 72 | 25 | 0.818627 | 0 | 0 | 0 | 0 | 0 | 0.16 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.111111 | false | 0 | 0.222222 | 0 | 0.555556 | 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 |
f2a43547693d16d461a7a8c1103d60944b85ac06 | 8,231 | py | Python | Mafia-Killer404/pro.py | shyamjangid07/Reverse-Engineering | 469efabcd6057f7895d8d891f1fabdf2ffe730b0 | [
"Apache-2.0"
] | 337 | 2020-08-15T12:22:14.000Z | 2022-03-29T06:05:15.000Z | Mafia-Killer404/pro.py | ajairakaam/Reverse-Engineering | 49d00bafd0622ffb79e081946a19c5fd3a42628f | [
"Apache-2.0"
] | 3 | 2020-11-12T14:30:48.000Z | 2021-05-18T16:56:22.000Z | Mafia-Killer404/pro.py | ajairakaam/Reverse-Engineering | 49d00bafd0622ffb79e081946a19c5fd3a42628f | [
"Apache-2.0"
] | 83 | 2020-08-15T00:22:58.000Z | 2022-03-31T08:40:23.000Z |
# Decompiled by HTR-TECH | TAHMID RAYAT
# Github : https://github.com/htr-tech
#---------------------------------------
# Source File : pro.py
# Time : Sun Feb 14 08:34:41 2021
#---------------------------------------
# uncompyle6 version 3.7.4
# Python bytecode 2.7
# Decompiled from: Python 2.7.16 (default, Oct 10 20... | 33.189516 | 563 | 0.465679 | 935 | 8,231 | 4.009626 | 0.26631 | 0.017605 | 0.017605 | 0.011736 | 0.321419 | 0.296079 | 0.259269 | 0.216591 | 0.172846 | 0.152574 | 0 | 0.04711 | 0.352691 | 8,231 | 248 | 564 | 33.189516 | 0.656532 | 0.043494 | 0 | 0.404878 | 0 | 0.014634 | 0.299707 | 0.051266 | 0 | 0 | 0 | 0 | 0 | 0 | null | null | 0.043902 | 0.004878 | null | null | 0.229268 | 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 |
f2a88fabc27f4d8aca7a16f645bc9f7392640bfb | 702 | py | Python | paderwasn/databases/synchronization/utils.py | fgnt/paderwasn | ff88f73a51228bb2cb4372f7595169dd716f4f2f | [
"MIT"
] | 7 | 2021-09-06T03:42:37.000Z | 2022-01-11T15:51:19.000Z | paderwasn/databases/synchronization/utils.py | fgnt/paderwasn | ff88f73a51228bb2cb4372f7595169dd716f4f2f | [
"MIT"
] | null | null | null | paderwasn/databases/synchronization/utils.py | fgnt/paderwasn | ff88f73a51228bb2cb4372f7595169dd716f4f2f | [
"MIT"
] | 1 | 2022-03-22T03:06:58.000Z | 2022-03-22T03:06:58.000Z | from pathlib import Path
import numpy as np
def load_binary(path, dtype=np.float32):
"""Loads a binary file and returns it as a numpy.ndarray.
Args:
path: String or ``pathlib.Path`` object.
dtype: Data type used to determine the size and byte-order
of the items in the file. The r... | 25.071429 | 75 | 0.641026 | 104 | 702 | 4.307692 | 0.557692 | 0.071429 | 0.080357 | 0.071429 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0.003891 | 0.267806 | 702 | 27 | 76 | 26 | 0.867704 | 0.428775 | 0 | 0 | 0 | 0 | 0.005525 | 0 | 0 | 0 | 0 | 0 | 0.1 | 1 | 0.2 | false | 0 | 0.2 | 0.1 | 0.6 | 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 |
f2ac693d52c26254f26daa9a99b550da1896cb24 | 1,052 | py | Python | src/FFEAT/ffeat/flow/EachArg.py | PatrikValkovic/MasterThesis | 6e9f3b186541db6c8395ebc96ace7289d01c805b | [
"MIT"
] | null | null | null | src/FFEAT/ffeat/flow/EachArg.py | PatrikValkovic/MasterThesis | 6e9f3b186541db6c8395ebc96ace7289d01c805b | [
"MIT"
] | null | null | null | src/FFEAT/ffeat/flow/EachArg.py | PatrikValkovic/MasterThesis | 6e9f3b186541db6c8395ebc96ace7289d01c805b | [
"MIT"
] | null | null | null | ###############################
#
# Created by Patrik Valkovic
# 3/9/2021
#
###############################
from typing import Callable
from ffeat import STANDARD_REPRESENTATION
from . import Lambda
class EachArg(Lambda):
"""
Applies lambda function to each parameter.
"""
def __init__(self, _lambda: Ca... | 30.941176 | 86 | 0.595057 | 114 | 1,052 | 5.298246 | 0.473684 | 0.039735 | 0.099338 | 0.076159 | 0.119205 | 0.119205 | 0 | 0 | 0 | 0 | 0 | 0.008974 | 0.258555 | 1,052 | 33 | 87 | 31.878788 | 0.765385 | 0.398289 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0.166667 | false | 0 | 0.25 | 0 | 0.583333 | 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 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.