hexsha
stringlengths
40
40
size
int64
5
2.06M
ext
stringclasses
10 values
lang
stringclasses
1 value
max_stars_repo_path
stringlengths
3
248
max_stars_repo_name
stringlengths
5
125
max_stars_repo_head_hexsha
stringlengths
40
78
max_stars_repo_licenses
listlengths
1
10
max_stars_count
int64
1
191k
max_stars_repo_stars_event_min_datetime
stringlengths
24
24
max_stars_repo_stars_event_max_datetime
stringlengths
24
24
max_issues_repo_path
stringlengths
3
248
max_issues_repo_name
stringlengths
5
125
max_issues_repo_head_hexsha
stringlengths
40
78
max_issues_repo_licenses
listlengths
1
10
max_issues_count
int64
1
67k
max_issues_repo_issues_event_min_datetime
stringlengths
24
24
max_issues_repo_issues_event_max_datetime
stringlengths
24
24
max_forks_repo_path
stringlengths
3
248
max_forks_repo_name
stringlengths
5
125
max_forks_repo_head_hexsha
stringlengths
40
78
max_forks_repo_licenses
listlengths
1
10
max_forks_count
int64
1
105k
max_forks_repo_forks_event_min_datetime
stringlengths
24
24
max_forks_repo_forks_event_max_datetime
stringlengths
24
24
content
stringlengths
5
2.06M
avg_line_length
float64
1
1.02M
max_line_length
int64
3
1.03M
alphanum_fraction
float64
0
1
count_classes
int64
0
1.6M
score_classes
float64
0
1
count_generators
int64
0
651k
score_generators
float64
0
1
count_decorators
int64
0
990k
score_decorators
float64
0
1
count_async_functions
int64
0
235k
score_async_functions
float64
0
1
count_documentation
int64
0
1.04M
score_documentation
float64
0
1
cc8abb2907e577ffd204f1ea8583e97ab1d687f1
410
py
Python
lib/googlecloudsdk/compute/subcommands/http_health_checks/__init__.py
IsaacHuang/google-cloud-sdk
52afa5d1a75dff08f4f5380c5cccc015bf796ca5
[ "Apache-2.0" ]
null
null
null
lib/googlecloudsdk/compute/subcommands/http_health_checks/__init__.py
IsaacHuang/google-cloud-sdk
52afa5d1a75dff08f4f5380c5cccc015bf796ca5
[ "Apache-2.0" ]
null
null
null
lib/googlecloudsdk/compute/subcommands/http_health_checks/__init__.py
IsaacHuang/google-cloud-sdk
52afa5d1a75dff08f4f5380c5cccc015bf796ca5
[ "Apache-2.0" ]
2
2020-07-25T05:03:06.000Z
2020-11-04T04:55:57.000Z
# Copyright 2014 Google Inc. All Rights Reserved. """Commands for reading and manipulating HTTP health checks.""" from googlecloudsdk.calliope import base class HttpHealthChecks(base.Group): """Read and manipulate HTTP health checks for load balanced instances.""" HttpHealthChecks.detailed_help = { 'brief': ...
27.333333
75
0.736585
111
0.270732
0
0
0
0
0
0
262
0.639024
cc8c3ccbb426c49972b991935c3bbbd09c451c5d
52,014
py
Python
pycofe/tasks/basic.py
ekr-ccp4/jsCoFE
b9424733fb567938927509bc667ef24ed60ddd8c
[ "MIT" ]
null
null
null
pycofe/tasks/basic.py
ekr-ccp4/jsCoFE
b9424733fb567938927509bc667ef24ed60ddd8c
[ "MIT" ]
null
null
null
pycofe/tasks/basic.py
ekr-ccp4/jsCoFE
b9424733fb567938927509bc667ef24ed60ddd8c
[ "MIT" ]
1
2021-02-25T06:54:15.000Z
2021-02-25T06:54:15.000Z
##!/usr/bin/python # # ============================================================================ # # 06.02.18 <-- Date of Last Modification. # ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # ---------------------------------------------------------------------------- # # BASIC TASK WRAPPER # # Command-line...
40.103315
100
0.514381
50,503
0.97095
0
0
0
0
0
0
12,683
0.243838
cc8c90a4501fe9ab990f2ab191504461fa54d0c3
154
py
Python
models/__init__.py
Celiali/FixMatch
fe55ea9daf353aead58b630da96f357eee728a82
[ "MIT" ]
12
2020-12-07T04:24:58.000Z
2022-02-16T15:33:26.000Z
models/__init__.py
Celiali/FixMatch
fe55ea9daf353aead58b630da96f357eee728a82
[ "MIT" ]
1
2021-07-15T23:02:22.000Z
2021-07-15T23:02:22.000Z
models/__init__.py
Celiali/FixMatch
fe55ea9daf353aead58b630da96f357eee728a82
[ "MIT" ]
1
2021-07-14T10:21:48.000Z
2021-07-14T10:21:48.000Z
from .wideresnet import * from .wideresnet_lk import * WRN_MODELS = { 'WideResNet':WideResNet, 'WideResNet_Lk': WideResNet_Lk, }
19.25
39
0.642857
0
0
0
0
0
0
0
0
27
0.175325
cc8d3cb600d5b30b2c38ef88bbba0a6183336176
8,954
py
Python
sp3-diffusion/extract-convert.py
robfairh/npre555-cp03
2aea7ae2df4a720c5d09003f98192f8986a6d107
[ "BSD-3-Clause" ]
null
null
null
sp3-diffusion/extract-convert.py
robfairh/npre555-cp03
2aea7ae2df4a720c5d09003f98192f8986a6d107
[ "BSD-3-Clause" ]
2
2021-01-04T12:29:30.000Z
2021-02-01T11:13:45.000Z
sp3-diffusion/extract-convert.py
robfairh/npre555-cp03
2aea7ae2df4a720c5d09003f98192f8986a6d107
[ "BSD-3-Clause" ]
null
null
null
# This script is based on moltres/python/extractSerpent2GCs.py import os import numpy as np import argparse import subprocess import serpentTools as sT def makePropertiesDir( outdir, filebase, mapFile, unimapFile, serp1=False, fromMain=False): """ Takes in a mapping...
38.594828
78
0.52256
0
0
0
0
0
0
0
0
1,976
0.220683
cc8e5699c6d924eefec86f5ef76ba0da8a0749bf
63,581
py
Python
ms1searchpy/main.py
markmipt/ms1searchpy
1fae3ba9ca25ac151b34110d333820f0a063ee11
[ "Apache-2.0" ]
6
2020-01-28T12:29:02.000Z
2022-02-01T14:43:44.000Z
ms1searchpy/main.py
markmipt/ms1searchpy
1fae3ba9ca25ac151b34110d333820f0a063ee11
[ "Apache-2.0" ]
3
2021-07-30T01:28:05.000Z
2021-11-25T09:14:31.000Z
ms1searchpy/main.py
markmipt/ms1searchpy
1fae3ba9ca25ac151b34110d333820f0a063ee11
[ "Apache-2.0" ]
2
2020-07-23T10:01:10.000Z
2021-05-04T12:46:04.000Z
import os from . import utils import numpy as np from scipy.stats import scoreatpercentile from scipy.optimize import curve_fit from scipy import exp import operator from copy import copy, deepcopy from collections import defaultdict, Counter import re from pyteomics import parser, mass, fasta, auxiliary as aux, achrom...
37.466706
276
0.564225
0
0
0
0
0
0
0
0
6,285
0.09885
cc8e8a561ef5687c9cc7d4a828c190e58f83f661
1,099
py
Python
waitinglist/urls.py
konradb/django-waitinglist
81e2b3ba81d96c377f4167b0bbd01bb023f7b97a
[ "MIT" ]
null
null
null
waitinglist/urls.py
konradb/django-waitinglist
81e2b3ba81d96c377f4167b0bbd01bb023f7b97a
[ "MIT" ]
null
null
null
waitinglist/urls.py
konradb/django-waitinglist
81e2b3ba81d96c377f4167b0bbd01bb023f7b97a
[ "MIT" ]
null
null
null
from django.conf.urls import url from django.views.generic import TemplateView from . import views urlpatterns = [ url(r"^list_signup/$", views.list_signup, name="waitinglist_list_signup"), url(r"^ajax_list_signup/$", views.ajax_list_signup, name="waitinglist_ajax_list_signup"), url(r"^survey/thanks/$", ...
57.842105
128
0.744313
0
0
0
0
0
0
0
0
549
0.499545
cc8eeef4e955218a7296a121d1dfb2153b85aa22
1,162
py
Python
nokogiri/tqdm_load.py
nat-chan/nokogiri
476c2989e2fbe80b2937923fbef0211459ec738f
[ "MIT" ]
null
null
null
nokogiri/tqdm_load.py
nat-chan/nokogiri
476c2989e2fbe80b2937923fbef0211459ec738f
[ "MIT" ]
null
null
null
nokogiri/tqdm_load.py
nat-chan/nokogiri
476c2989e2fbe80b2937923fbef0211459ec738f
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from pathlib import Path from nokogiri.which_env import which_env from pickle import Unpickler class TQDMBytesReader(object): def __init__(self, fd, tqdm, total, desc=''): self.fd = fd self.tqdm = tqdm(total=total) self.tqdm.set_description(des...
31.405405
77
0.60241
585
0.503442
0
0
0
0
0
0
53
0.045611
cc930b4f7f09f8fa1727fc2d776abafb2a109c6e
5,991
py
Python
tests/test_contrib/test_prepredict.py
uricod/yellowbrick
6fb2e9b7e5b2998c6faa4dcca81a4b0f91bf29b4
[ "Apache-2.0" ]
1
2017-03-03T03:26:54.000Z
2017-03-03T03:26:54.000Z
tests/test_contrib/test_prepredict.py
uricod/yellowbrick
6fb2e9b7e5b2998c6faa4dcca81a4b0f91bf29b4
[ "Apache-2.0" ]
1
2021-11-10T18:06:19.000Z
2021-11-10T18:06:19.000Z
tests/test_contrib/test_prepredict.py
uricod/yellowbrick
6fb2e9b7e5b2998c6faa4dcca81a4b0f91bf29b4
[ "Apache-2.0" ]
null
null
null
# tests.test_contrib.test_prepredict # Test the prepredict estimator. # # Author: Benjamin Bengfort <[email protected]> # Created: Mon Jul 12 07:07:33 2021 -0400 # # ID: test_prepredict.py [] [email protected] $ """ Test the prepredict estimator. """ ##########################################################...
32.037433
93
0.624604
3,151
0.525956
0
0
4,610
0.769488
0
0
2,084
0.347855
cc9334543aeeb4519b2ac91825f9b078d9f16ee4
94
py
Python
src6/1/string3.py
pjackson3/cs50
4cf8ca67abfc293d4dbb9bf5a1cb742d74ca7a31
[ "MIT" ]
null
null
null
src6/1/string3.py
pjackson3/cs50
4cf8ca67abfc293d4dbb9bf5a1cb742d74ca7a31
[ "MIT" ]
null
null
null
src6/1/string3.py
pjackson3/cs50
4cf8ca67abfc293d4dbb9bf5a1cb742d74ca7a31
[ "MIT" ]
1
2020-11-24T23:25:26.000Z
2020-11-24T23:25:26.000Z
# input and print, with format strings s = input("What's your name?\n") print(f"hello, {s}")
18.8
38
0.659574
0
0
0
0
0
0
0
0
72
0.765957
cc93993829d4a8f1dc6a847d22783d8908c2b006
2,259
py
Python
examples/metrics/fc/example_idtxl_wrapper_multi.py
HelmchenLabSoftware/mesostat-dev
8baa7120b892fe0df893cdcf0f20f49876643d75
[ "MIT" ]
null
null
null
examples/metrics/fc/example_idtxl_wrapper_multi.py
HelmchenLabSoftware/mesostat-dev
8baa7120b892fe0df893cdcf0f20f49876643d75
[ "MIT" ]
null
null
null
examples/metrics/fc/example_idtxl_wrapper_multi.py
HelmchenLabSoftware/mesostat-dev
8baa7120b892fe0df893cdcf0f20f49876643d75
[ "MIT" ]
null
null
null
import os, sys import numpy as np import matplotlib.pyplot as plt # Export library path rootname = "mesoscopic-functional-connectivity" thispath = os.path.dirname(os.path.abspath(__file__)) rootpath = os.path.join(thispath[:thispath.index(rootname)], rootname) print("Appending project path", rootpath) sys.path.append(...
29.723684
93
0.660912
0
0
0
0
0
0
0
0
981
0.434263
cc97881f01338acc3697d0a0591a9ee19e6dbad9
1,747
py
Python
project.py
blendacosta/CIP_FinalProject
8f50298d1b35cffe4569f5a78a158d6d699fa532
[ "MIT" ]
null
null
null
project.py
blendacosta/CIP_FinalProject
8f50298d1b35cffe4569f5a78a158d6d699fa532
[ "MIT" ]
null
null
null
project.py
blendacosta/CIP_FinalProject
8f50298d1b35cffe4569f5a78a158d6d699fa532
[ "MIT" ]
null
null
null
''' A Gameplay Mechanic [TS4] By CozyGnomes (https://cozygnomes.tumblr.com/) This is an existing document that contains several things you can do in your gameplay on TS4. This program comes with the intention of automatically generating the related phrase without having to sear...
37.170213
112
0.661133
0
0
0
0
0
0
0
0
1,001
0.571673
cc9a005a14d0a98035518428a505d967d10c254e
101
py
Python
Section 18/8.Document-function-with-keyword-based-arguments.py
airbornum/-Complete-Python-Scripting-for-Automation
bc053444f8786259086269ca1713bdb10144dd74
[ "MIT" ]
18
2020-04-13T03:14:06.000Z
2022-03-09T18:54:41.000Z
Section 18/8.Document-function-with-keyword-based-arguments.py
airbornum/-Complete-Python-Scripting-for-Automation
bc053444f8786259086269ca1713bdb10144dd74
[ "MIT" ]
null
null
null
Section 18/8.Document-function-with-keyword-based-arguments.py
airbornum/-Complete-Python-Scripting-for-Automation
bc053444f8786259086269ca1713bdb10144dd74
[ "MIT" ]
22
2020-04-29T21:12:42.000Z
2022-03-17T18:19:54.000Z
def display(a,b): print(f'a={a}') return None display(3,4) display(a=3,b=4) display(b=4,a=3)
14.428571
18
0.60396
0
0
0
0
0
0
0
0
8
0.079208
cc9b021bad66790ffb26790ca7f0b624083f6bad
830
py
Python
test_dataloader.py
dsoselia/Continual-Learning-Benchmark
b3393aa9eb9a6956a6560ee15904a2cdb046e4c7
[ "MIT" ]
null
null
null
test_dataloader.py
dsoselia/Continual-Learning-Benchmark
b3393aa9eb9a6956a6560ee15904a2cdb046e4c7
[ "MIT" ]
null
null
null
test_dataloader.py
dsoselia/Continual-Learning-Benchmark
b3393aa9eb9a6956a6560ee15904a2cdb046e4c7
[ "MIT" ]
null
null
null
# %% from collections import OrderedDict import dataloaders.base from dataloaders.datasetGen import SplitGen, PermutedGen train_dataset, val_dataset = dataloaders.base.__dict__["CIFAR10"]('data', False) # %% print(train_dataset) # %% train_dataset_splits, val_dataset_splits, task_output_space = SplitGen(train_data...
28.62069
98
0.474699
0
0
0
0
0
0
0
0
46
0.055422
cc9ccfbe858fbd860be65559e189e269ad336b72
4,631
py
Python
zsalt/pretty_redshift.py
dmnielsen/zSALT
938904ef8f331d5e047bd00a04a4424e982552e2
[ "BSD-3-Clause" ]
null
null
null
zsalt/pretty_redshift.py
dmnielsen/zSALT
938904ef8f331d5e047bd00a04a4424e982552e2
[ "BSD-3-Clause" ]
null
null
null
zsalt/pretty_redshift.py
dmnielsen/zSALT
938904ef8f331d5e047bd00a04a4424e982552e2
[ "BSD-3-Clause" ]
null
null
null
import sys import pyfits import numpy as np from PySpectrograph import Spectrum from PySpectrograph.Utilities.fit import interfit import pylab as pl def ncor(x, y): """Calculate the normalized correlation of two arrays""" d=np.correlate(x,x)*np.correlate(y,y) if d<=0: return 0 return np.correlate(x,y)...
30.668874
105
0.649536
0
0
0
0
0
0
0
0
1,079
0.232995
cc9d27fc8106d84826a9bc91142a53251a35c56a
62,936
py
Python
niimpy/preprocess.py
CxAalto/niimpy
ffd20f9c6aba1671d9035f47715d1649ced0e6e7
[ "MIT" ]
5
2021-11-23T12:05:23.000Z
2022-02-11T12:57:50.000Z
niimpy/preprocess.py
niima-project/niimpy
975470507b1f8836d9e29d43601e345612b06a62
[ "MIT" ]
62
2021-07-16T09:17:18.000Z
2022-03-16T11:27:50.000Z
niimpy/preprocess.py
niima-project/niimpy
975470507b1f8836d9e29d43601e345612b06a62
[ "MIT" ]
6
2021-09-07T13:06:57.000Z
2022-03-14T11:26:30.000Z
################################################################################ # This is the main file for preprocessing smartphone sensor data # # # # Contributors: Anna Hakala & Ana Triana ...
42.182306
270
0.668981
0
0
0
0
0
0
0
0
26,247
0.417003
cc9e3bc94eb629f76a855b39c6d9abe102c7440e
15,570
py
Python
analog-voltage-control/analogVoltageController.py
jsbangsund/measurement-automation-tools
d2c2fd58b3a6884945081cb9a9ad87366da4a10e
[ "MIT" ]
2
2018-09-27T09:47:47.000Z
2022-03-24T09:53:04.000Z
analog-voltage-control/analogVoltageController.py
jsbangsund/measurement-automation-tools
d2c2fd58b3a6884945081cb9a9ad87366da4a10e
[ "MIT" ]
null
null
null
analog-voltage-control/analogVoltageController.py
jsbangsund/measurement-automation-tools
d2c2fd58b3a6884945081cb9a9ad87366da4a10e
[ "MIT" ]
null
null
null
# imports import visa import numpy as np import os import csv import time import datetime import tkinter as tk from tkinter.filedialog import askopenfilename, askdirectory from tkinter.ttk import Frame, Button, Style,Treeview, Scrollbar, Checkbutton from functools import partial import serial # This app uses an arduino...
48.504673
107
0.617213
14,929
0.958831
0
0
0
0
0
0
3,948
0.253565
cc9ffda493fbb21c5940dac2d68d30da4ab49dc6
12,522
py
Python
cnn_theano_overlap.py
nanfeng1101/DBQA
56b0a320e4641f46e80db78039d4ca79e9037d7e
[ "MIT" ]
7
2017-08-14T02:40:04.000Z
2019-04-24T13:44:44.000Z
cnn_theano_overlap.py
nanfeng1101/DBQA
56b0a320e4641f46e80db78039d4ca79e9037d7e
[ "MIT" ]
null
null
null
cnn_theano_overlap.py
nanfeng1101/DBQA
56b0a320e4641f46e80db78039d4ca79e9037d7e
[ "MIT" ]
2
2018-05-19T01:26:38.000Z
2019-12-04T07:58:09.000Z
#-*- coding:utf-8 -*- __author__ = "ChenJun" import theano import theano.tensor as T import numpy as np import cPickle as pickle from theano_models.qa_cnn import CNNModule from theano_models.layers import InteractLayer, MLP, MLPDropout, BatchNormLayer from theano_models.optimizer import Optimizer from data_process.load...
47.977011
169
0.645504
0
0
0
0
0
0
0
0
2,461
0.196534
cca08eaaa789f720d1578ebb6f7b99357f1739e1
7,298
py
Python
marble-plotter-dous/src/main/python/server.py
paser4se/marble
35da5ac8ff24ff7f30a135cbabf57f60f06f54e3
[ "Apache-2.0" ]
2
2017-06-05T13:06:06.000Z
2021-06-23T13:53:33.000Z
marble-plotter-dous/src/main/python/server.py
paser4se/marble
35da5ac8ff24ff7f30a135cbabf57f60f06f54e3
[ "Apache-2.0" ]
35
2015-07-21T15:09:24.000Z
2020-07-08T09:06:08.000Z
marble-plotter-dous/src/main/python/server.py
paser4se/marble
35da5ac8ff24ff7f30a135cbabf57f60f06f54e3
[ "Apache-2.0" ]
5
2015-06-16T09:40:39.000Z
2020-11-05T08:13:57.000Z
# Rest Server from flask import Flask, jsonify, abort, request # Eureka client from eureka.client import EurekaClient # Background tasks import threading import atexit import logging import socket import netifaces as ni import sys import os import time # Plotter libs from io import BytesIO import pymongo from pymongo ...
29.075697
121
0.565908
441
0.060428
0
0
363
0.04974
0
0
1,329
0.182105
cca2291d6cc0c07dfc8cf1b487d638a6d05c267b
3,274
py
Python
dependencies/src/4Suite-XML-1.0.2/test/Xml/Xslt/Borrowed/sm_19991228.py
aleasims/Peach
bb56841e943d719d5101fee0a503ed34308eda04
[ "MIT" ]
null
null
null
dependencies/src/4Suite-XML-1.0.2/test/Xml/Xslt/Borrowed/sm_19991228.py
aleasims/Peach
bb56841e943d719d5101fee0a503ed34308eda04
[ "MIT" ]
null
null
null
dependencies/src/4Suite-XML-1.0.2/test/Xml/Xslt/Borrowed/sm_19991228.py
aleasims/Peach
bb56841e943d719d5101fee0a503ed34308eda04
[ "MIT" ]
1
2020-07-26T03:57:45.000Z
2020-07-26T03:57:45.000Z
#Example for Jon Smirl on 28 Dec 1999, originally by Steve Muench, with improvements by Mike Brown and Jeremy Richman from Xml.Xslt import test_harness sheet_1 = """<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:template match="/"> <html> <head/> <body> <xsl:apply-template...
25.578125
117
0.640806
0
0
0
0
0
0
0
0
2,756
0.841784
cca2be577b6cb5b5ef2f77c8c187c1f9904195fb
2,687
py
Python
django_docutils/favicon/rst/transforms/favicon.py
tony/django-docutils
ed3e089728507a0f579a62bcb182f283bc59929c
[ "MIT" ]
10
2017-04-28T00:19:10.000Z
2020-07-22T15:27:09.000Z
django_docutils/favicon/rst/transforms/favicon.py
tony/django-docutils
ed3e089728507a0f579a62bcb182f283bc59929c
[ "MIT" ]
231
2017-01-17T04:47:51.000Z
2022-03-30T03:03:42.000Z
django_docutils/favicon/rst/transforms/favicon.py
tony/django-docutils
ed3e089728507a0f579a62bcb182f283bc59929c
[ "MIT" ]
1
2019-01-25T14:42:15.000Z
2019-01-25T14:42:15.000Z
import tldextract from django.db.models import Q from docutils import nodes from docutils.transforms import Transform from django_docutils.favicon.models import get_favicon_model from ..nodes import icon Favicon = get_favicon_model() def resolve_favicon(url): """Given a URL to a website, see if a Favicon exist...
30.885057
81
0.61965
1,219
0.453666
0
0
0
0
0
0
1,020
0.379606
cca383b23457a782befbce9c96268d9161502ad0
1,733
py
Python
xnmt/model_context.py
marcintustin/xnmt
f315fc5e493d25746bbde46d2c89cea3410d43df
[ "Apache-2.0" ]
null
null
null
xnmt/model_context.py
marcintustin/xnmt
f315fc5e493d25746bbde46d2c89cea3410d43df
[ "Apache-2.0" ]
null
null
null
xnmt/model_context.py
marcintustin/xnmt
f315fc5e493d25746bbde46d2c89cea3410d43df
[ "Apache-2.0" ]
null
null
null
import dynet as dy import os from xnmt.serializer import Serializable class ModelContext(Serializable): yaml_tag = u'!ModelContext' def __init__(self): self.dropout = 0.0 self.weight_noise = 0.0 self.default_layer_dim = 512 self.dynet_param_collection = None self.serialize_params = ["dropout", ...
38.511111
100
0.709175
1,659
0.957299
0
0
0
0
0
0
97
0.055972
cca508227383d8fc79a193435ae1d2995d0eb8b7
3,100
py
Python
utils.py
Akshayvm98/Django-School
723d52db2cd3bc7665680a3adaf8687f97836d48
[ "MIT" ]
26
2015-08-04T00:13:27.000Z
2021-03-19T01:01:14.000Z
utils.py
Akshayvm98/Django-School
723d52db2cd3bc7665680a3adaf8687f97836d48
[ "MIT" ]
null
null
null
utils.py
Akshayvm98/Django-School
723d52db2cd3bc7665680a3adaf8687f97836d48
[ "MIT" ]
28
2015-01-19T15:10:15.000Z
2020-10-27T11:22:21.000Z
import csv from django.http import HttpResponse, HttpResponseForbidden from django.template.defaultfilters import slugify from django.db.models.loading import get_model def export(qs, fields=None): model = qs.model response = HttpResponse(mimetype='text/csv') response['Content-Disposition'] = 'attachment; ...
36.470588
179
0.639032
0
0
0
0
0
0
0
0
1,138
0.367097
cca9c51d89c5109307f0fb8fc9ff82831401ed2e
1,668
py
Python
hard-gists/a027a9fc5aac66e6a382/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
21
2019-07-08T08:26:45.000Z
2022-01-24T23:53:25.000Z
hard-gists/a027a9fc5aac66e6a382/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
5
2019-06-15T14:47:47.000Z
2022-02-26T05:02:56.000Z
hard-gists/a027a9fc5aac66e6a382/snippet.py
jjhenkel/dockerizeme
eaa4fe5366f6b9adf74399eab01c712cacaeb279
[ "Apache-2.0" ]
17
2019-05-16T03:50:34.000Z
2021-01-14T14:35:12.000Z
# -*- coding: utf-8 -*- # Author: Massimo Menichinelli # Homepage: http://www.openp2pdesign.org # License: MIT # import wx import serial # A new custom class that extends the wx.Frame class MyFrame(wx.Frame): def __init__(self, parent, title): super(MyFrame, self).__init__(parent, title=title, ...
23.492958
71
0.601918
1,100
0.656325
0
0
0
0
0
0
618
0.368735
ccae60674a2d5d72a4d3496efd86de39ff78e0dc
13,807
py
Python
src/python/pants/backend/docker/util_rules/docker_build_context_test.py
asherf/pants
e010b93c4123b4446a631cac5db0b7ea15634686
[ "Apache-2.0" ]
null
null
null
src/python/pants/backend/docker/util_rules/docker_build_context_test.py
asherf/pants
e010b93c4123b4446a631cac5db0b7ea15634686
[ "Apache-2.0" ]
14
2021-05-03T13:54:41.000Z
2022-03-30T10:20:58.000Z
src/python/pants/backend/docker/util_rules/docker_build_context_test.py
asherf/pants
e010b93c4123b4446a631cac5db0b7ea15634686
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import annotations from textwrap import dedent from typing import Any, ContextManager import pytest from pants.backend.docker.subsystems.dockerfile_parser import rules a...
32.640662
99
0.557833
0
0
0
0
3,334
0.241472
0
0
5,191
0.375969
ccb0eb936ec41c62e8c05807faa25bca2c7ad40d
48
py
Python
tests/extensions/artificial_intelligence/ai_model/__init__.py
chr0m1ng/blip-sdk-js
74f404a3ef048a100cc330f78a9751572e31fb0b
[ "MIT" ]
null
null
null
tests/extensions/artificial_intelligence/ai_model/__init__.py
chr0m1ng/blip-sdk-js
74f404a3ef048a100cc330f78a9751572e31fb0b
[ "MIT" ]
9
2021-05-27T21:08:23.000Z
2021-06-14T20:10:10.000Z
tests/extensions/artificial_intelligence/ai_model/__init__.py
chr0m1ng/blip-sdk-python
74f404a3ef048a100cc330f78a9751572e31fb0b
[ "MIT" ]
null
null
null
from .test_ai_model import TestAiModelExtension
24
47
0.895833
0
0
0
0
0
0
0
0
0
0
ccb0f6edadd14edc784ea01c369c3b62583b31ca
5,100
py
Python
src/rescuexport/dal.py
karlicoss/rescuexport
69f5275bfa7cb39a1ba74b99312b605ba340916a
[ "MIT" ]
6
2019-11-28T10:56:53.000Z
2022-01-10T21:07:40.000Z
src/rescuexport/dal.py
karlicoss/rescuexport
69f5275bfa7cb39a1ba74b99312b605ba340916a
[ "MIT" ]
null
null
null
src/rescuexport/dal.py
karlicoss/rescuexport
69f5275bfa7cb39a1ba74b99312b605ba340916a
[ "MIT" ]
1
2020-12-08T14:16:53.000Z
2020-12-08T14:16:53.000Z
#!/usr/bin/env python3 import logging from pathlib import Path import json from datetime import datetime, timedelta from typing import Set, Sequence, Any, Iterator from dataclasses import dataclass from .exporthelpers.dal_helper import PathIsh, Json, Res, datetime_naive from .exporthelpers.logging_helper import LazyLo...
31.097561
122
0.550392
2,861
0.56076
2,802
0.549196
1,000
0.196002
0
0
1,519
0.297726
ccb20b99e03872ed73a498ac6c05de75181ce2b4
1,287
py
Python
MuonAnalysis/MuonAssociators/python/muonHLTL1Match_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
852
2015-01-11T21:03:51.000Z
2022-03-25T21:14:00.000Z
MuonAnalysis/MuonAssociators/python/muonHLTL1Match_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
30,371
2015-01-02T00:14:40.000Z
2022-03-31T23:26:05.000Z
MuonAnalysis/MuonAssociators/python/muonHLTL1Match_cfi.py
ckamtsikis/cmssw
ea19fe642bb7537cbf58451dcf73aa5fd1b66250
[ "Apache-2.0" ]
3,240
2015-01-02T05:53:18.000Z
2022-03-31T17:24:21.000Z
import FWCore.ParameterSet.Config as cms from MuonAnalysis.MuonAssociators.muonL1Match_cfi import * muonHLTL1Match = cms.EDProducer("HLTL1MuonMatcher", muonL1MatcherParameters, # Reconstructed muons src = cms.InputTag("muons"), # L1 Muon collection, and preselection on that collection ...
40.21875
186
0.679876
0
0
0
0
0
0
0
0
851
0.661228
ccb315a349fc8cff12751a9ddd2a5e9db7858230
632
py
Python
Curso_em_Video_py3/ex082.py
Rodrigo98Matos/Projetos_py
6428e2c09d28fd8a717743f4434bc788e7d7d3cc
[ "MIT" ]
1
2021-05-11T12:39:43.000Z
2021-05-11T12:39:43.000Z
Curso_em_Video_py3/ex082.py
Rodrigo98Matos/Projetos_py
6428e2c09d28fd8a717743f4434bc788e7d7d3cc
[ "MIT" ]
null
null
null
Curso_em_Video_py3/ex082.py
Rodrigo98Matos/Projetos_py
6428e2c09d28fd8a717743f4434bc788e7d7d3cc
[ "MIT" ]
null
null
null
lista = list() while True: lista.append(int(input("Digite um número inteiro:\t"))) while True: p = str(input("Digitar mais números?\t").strip())[0].upper() if p in 'SN': break else: print("\033[31mDigite uma opção válida!\033[m") if p == 'N': break par...
26.333333
140
0.568038
0
0
0
0
0
0
0
0
245
0.381026
ccb4877c2d894de84894acf89db676779bb0786b
1,212
py
Python
census_data_downloader/tables/percapitaincome.py
JoeGermuska/census-data-downloader
0098b9e522b78ad0e30301c9845ecbcc903c62e4
[ "MIT" ]
170
2019-04-01T01:41:42.000Z
2022-03-25T21:22:06.000Z
census_data_downloader/tables/percapitaincome.py
JoeGermuska/census-data-downloader
0098b9e522b78ad0e30301c9845ecbcc903c62e4
[ "MIT" ]
68
2019-03-31T22:52:43.000Z
2021-08-30T16:33:54.000Z
census_data_downloader/tables/percapitaincome.py
JoeGermuska/census-data-downloader
0098b9e522b78ad0e30301c9845ecbcc903c62e4
[ "MIT" ]
34
2019-04-02T17:57:16.000Z
2022-03-28T17:22:35.000Z
#! /usr/bin/env python # -*- coding: utf-8 -* import collections from census_data_downloader.core.tables import BaseTableConfig from census_data_downloader.core.decorators import register @register class PerCapitaIncomeDownloader(BaseTableConfig): # inflation adjusted PROCESSED_TABLE_NAME = "percapitaincome" ...
26.933333
65
0.782178
959
0.791254
0
0
1,009
0.832508
0
0
336
0.277228
ccb69ce91869d886c281dd5c097515346b3bb141
844
py
Python
pyskel_bc/cli.py
smnorris/pyskel_bc
d8bdec3e15da6268c9b6a0f3be1fdd6af9737d21
[ "Apache-2.0" ]
null
null
null
pyskel_bc/cli.py
smnorris/pyskel_bc
d8bdec3e15da6268c9b6a0f3be1fdd6af9737d21
[ "Apache-2.0" ]
null
null
null
pyskel_bc/cli.py
smnorris/pyskel_bc
d8bdec3e15da6268c9b6a0f3be1fdd6af9737d21
[ "Apache-2.0" ]
null
null
null
# Copyright 2018 Province of British Columbia # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
30.142857
76
0.740521
0
0
0
0
200
0.236967
0
0
653
0.773697
ccb6b1cc30ddbfae5e44890354c45b22ed3bc398
757
py
Python
solutions/python3/558.py
sm2774us/amazon_interview_prep_2021
f580080e4a6b712b0b295bb429bf676eb15668de
[ "MIT" ]
42
2020-08-02T07:03:49.000Z
2022-03-26T07:50:15.000Z
solutions/python3/558.py
ajayv13/leetcode
de02576a9503be6054816b7444ccadcc0c31c59d
[ "MIT" ]
null
null
null
solutions/python3/558.py
ajayv13/leetcode
de02576a9503be6054816b7444ccadcc0c31c59d
[ "MIT" ]
40
2020-02-08T02:50:24.000Z
2022-03-26T15:38:10.000Z
class Solution: def intersect(self, q1, q2): if q1.isLeaf: return q1.val and q1 or q2 elif q2.isLeaf: return q2.val and q2 or q1 else: tLeft = self.intersect(q1.topLeft, q2.topLeft) tRight = self.intersect(q1.topRight, q2.topRight) ...
47.3125
136
0.587847
757
1
0
0
0
0
0
0
0
0
ccb7c733b68470d611b304324e4c358b41fac520
1,442
py
Python
project/encryption_utils.py
v2121/redshift-django
b6d66b2ee0443f039cfbad9f53c4ffd4efd156ec
[ "CC0-1.0" ]
null
null
null
project/encryption_utils.py
v2121/redshift-django
b6d66b2ee0443f039cfbad9f53c4ffd4efd156ec
[ "CC0-1.0" ]
null
null
null
project/encryption_utils.py
v2121/redshift-django
b6d66b2ee0443f039cfbad9f53c4ffd4efd156ec
[ "CC0-1.0" ]
null
null
null
import Crypto.Random from Crypto.Cipher import AES import hashlib import base64 SALT_SIZE = 16 AES_MULTIPLE = 16 NUMBER_OF_ITERATIONS = 20 def generate_key(password, salt): key = password.encode('utf-8') + salt for i in range(NUMBER_OF_ITERATIONS): key = hashlib.sha256(str(key).encode('utf-8')).digest...
31.347826
63
0.731623
0
0
0
0
0
0
0
0
28
0.019417
ccb976a45584bf29937e03ff9e1aef9ce04de815
462
py
Python
core/xml/utils.py
Magoli1/carla-pre-crash-scenario-generator
46666309a55e9aab59cebeda33aca7723c1d360c
[ "MIT" ]
1
2022-03-30T08:28:53.000Z
2022-03-30T08:28:53.000Z
core/xml/utils.py
Magoli1/carla-pre-crash-scenario-generator
46666309a55e9aab59cebeda33aca7723c1d360c
[ "MIT" ]
null
null
null
core/xml/utils.py
Magoli1/carla-pre-crash-scenario-generator
46666309a55e9aab59cebeda33aca7723c1d360c
[ "MIT" ]
null
null
null
from xml.etree import ElementTree from xml.dom import minidom def get_pretty_xml(tree): """Transforms and pretty-prints a given xml-tree to string :param tree: XML-tree :type tree: object :returns: (Prettified) stringified version of the passed xml-tree :rtype: str """ stringified_tree = ...
28.875
69
0.71645
0
0
0
0
0
0
0
0
213
0.461039
ccba7105c97f04202293ba5c9e3bb9286a1e1c30
1,745
py
Python
tests/test_main.py
giulionf/GetOldTweets3
038b8fed7da27300e6c611d3c0fd617588075a58
[ "MIT" ]
null
null
null
tests/test_main.py
giulionf/GetOldTweets3
038b8fed7da27300e6c611d3c0fd617588075a58
[ "MIT" ]
null
null
null
tests/test_main.py
giulionf/GetOldTweets3
038b8fed7da27300e6c611d3c0fd617588075a58
[ "MIT" ]
null
null
null
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import os import sys import time import GetOldTweets3 as Got3 if sys.version_info[0] < 3: raise Exception("Python 2.x is not supported. Please upgrade to 3.x") sys.path.append(os.path.join(os.path.dirname(__file__), "..")) def test_username(): tweet_criteria =...
33.557692
92
0.681948
0
0
0
0
0
0
0
0
345
0.197708
ccbaa690673254ea1cda4e119201ebd6a7af3c57
421
py
Python
extsum/__main__.py
streof/extsum
45949a6a6aff65ceaf2a4bdc70f5b4d9660fca5f
[ "MIT" ]
null
null
null
extsum/__main__.py
streof/extsum
45949a6a6aff65ceaf2a4bdc70f5b4d9660fca5f
[ "MIT" ]
null
null
null
extsum/__main__.py
streof/extsum
45949a6a6aff65ceaf2a4bdc70f5b4d9660fca5f
[ "MIT" ]
null
null
null
import extsum as ext URL = "https://i.picsum.photos/id/42/1/1.jpg" # Uncomment for random Picsum photo # URL = "https://picsum.photos/1/1" if __name__ == '__main__': # Init photo = ext.Load(URL) photo_parsed = ext.Parse(photo) # Print found ID (if any) id_found = photo_parsed.find_id() if id_...
23.388889
45
0.631829
0
0
0
0
0
0
0
0
194
0.460808
ccbaec8553da0b692edf4bc23f5c78797c64aa03
931
py
Python
rplugin/python3/denite/kind/lab_browse.py
lighttiger2505/denite-lab
611e5e081d049d79999a8c0a0f38c2466d8ca970
[ "MIT" ]
1
2018-02-26T15:27:03.000Z
2018-02-26T15:27:03.000Z
rplugin/python3/denite/kind/lab_browse.py
lighttiger2505/denite-lab
611e5e081d049d79999a8c0a0f38c2466d8ca970
[ "MIT" ]
null
null
null
rplugin/python3/denite/kind/lab_browse.py
lighttiger2505/denite-lab
611e5e081d049d79999a8c0a0f38c2466d8ca970
[ "MIT" ]
null
null
null
import subprocess from .base import Base class Kind(Base): def __init__(self, vim): super().__init__(vim) self.name = 'lab_browse' self.default_action = 'lab_browse' def action_lab_browse(self, context): for target in context['targets']: iid = target['word'] ...
30.032258
64
0.525242
886
0.951665
0
0
0
0
0
0
65
0.069817
ccbbb657919673062f15afd66c5a069d9e36de11
3,358
py
Python
Betsy/Betsy/modules/plot_sample_pca.py
jefftc/changlab
11da8c415afefcba0b0216238387c75aeb3a56ac
[ "MIT" ]
9
2017-01-13T02:38:41.000Z
2021-04-08T00:44:39.000Z
Betsy/Betsy/modules/plot_sample_pca.py
jefftc/changlab
11da8c415afefcba0b0216238387c75aeb3a56ac
[ "MIT" ]
null
null
null
Betsy/Betsy/modules/plot_sample_pca.py
jefftc/changlab
11da8c415afefcba0b0216238387c75aeb3a56ac
[ "MIT" ]
4
2017-01-05T16:25:25.000Z
2019-12-12T20:07:38.000Z
from Module import AbstractModule class Module(AbstractModule): def __init__(self): AbstractModule.__init__(self) def run( self, network, antecedents, out_attributes, user_options, num_cores, outfile): from genomicode import filelib from genomicode import parallel ...
32.921569
76
0.532758
2,170
0.646218
0
0
0
0
0
0
2,204
0.656343
ccbc5e88899c66f97d3d1a9a12e0ddc302dbc43e
1,098
py
Python
scripts/seg_vs_dog_plots.py
AbigailMcGovern/platelet-segmentation
46cd87b81fc44473b07a2bebed1e6134b2582348
[ "BSD-3-Clause" ]
1
2022-02-01T23:40:38.000Z
2022-02-01T23:40:38.000Z
scripts/seg_vs_dog_plots.py
AbigailMcGovern/platelet-segmentation
46cd87b81fc44473b07a2bebed1e6134b2582348
[ "BSD-3-Clause" ]
3
2021-03-12T02:03:15.000Z
2021-03-31T00:39:05.000Z
scripts/seg_vs_dog_plots.py
AbigailMcGovern/platelet-segmentation
46cd87b81fc44473b07a2bebed1e6134b2582348
[ "BSD-3-Clause" ]
1
2021-04-06T23:23:32.000Z
2021-04-06T23:23:32.000Z
from plots import plot_experiment_APs, plot_experiment_no_diff, experiment_VI_plots import os # paths, names, title, out_dir, out_name data_dir = '/Users/amcg0011/Data/pia-tracking/dl-results/210512_150843_seed_z-1_y-1_x-1_m_centg' suffix = 'seed_z-1_y-1_x-1_m_centg' out_dir = os.path.join(data_dir, 'DL-vs-Dog') ap_pat...
64.588235
106
0.736794
0
0
0
0
0
0
0
0
651
0.592896
ccbcc99c190554ac665c0c7ffb46b19b240c78b3
2,925
py
Python
src/pyfme/models/state/velocity.py
gaofeng2020/PyFME
26b76f0622a8dca0e24eb477a6fb4a8b2aa604d7
[ "MIT" ]
199
2015-12-29T19:49:42.000Z
2022-03-19T14:31:24.000Z
src/pyfme/models/state/velocity.py
gaofeng2020/PyFME
26b76f0622a8dca0e24eb477a6fb4a8b2aa604d7
[ "MIT" ]
126
2015-09-23T11:15:42.000Z
2020-07-29T12:27:22.000Z
src/pyfme/models/state/velocity.py
gaofeng2020/PyFME
26b76f0622a8dca0e24eb477a6fb4a8b2aa604d7
[ "MIT" ]
93
2015-12-26T13:02:29.000Z
2022-03-19T14:31:13.000Z
""" Python Flight Mechanics Engine (PyFME). Copyright (c) AeroPython Development Team. Distributed under the terms of the MIT License. Velocity -------- The aircraft state has """ from abc import abstractmethod import numpy as np # TODO: think about generic changes from body to horizon that could be used for # vel...
23.58871
79
0.563077
2,373
0.811282
0
0
703
0.240342
0
0
968
0.33094
ccbe05761dc731218eefcccd4c39733dc739862d
68
py
Python
tests/CompileTests/Python_tests/test2011_029.py
maurizioabba/rose
7597292cf14da292bdb9a4ef573001b6c5b9b6c0
[ "BSD-3-Clause" ]
488
2015-01-09T08:54:48.000Z
2022-03-30T07:15:46.000Z
tests/CompileTests/Python_tests/test2011_029.py
sujankh/rose-matlab
7435d4fa1941826c784ba97296c0ec55fa7d7c7e
[ "BSD-3-Clause" ]
174
2015-01-28T18:41:32.000Z
2022-03-31T16:51:05.000Z
tests/CompileTests/Python_tests/test2011_029.py
sujankh/rose-matlab
7435d4fa1941826c784ba97296c0ec55fa7d7c7e
[ "BSD-3-Clause" ]
146
2015-04-27T02:48:34.000Z
2022-03-04T07:32:53.000Z
# test while statements while 0: 1 while 0: 2 else: 3
6.8
23
0.558824
0
0
0
0
0
0
0
0
23
0.338235
ccbffdcc60fb438aee22b3f831c544750ef569d6
246
py
Python
minds/sections/__init__.py
Atherz97/minds-bot
965f44ba39ad816947e4bcba051a86fa1c5ee05c
[ "MIT" ]
3
2020-05-01T10:59:59.000Z
2022-01-18T01:40:34.000Z
minds/sections/__init__.py
Atherz97/minds-bot
965f44ba39ad816947e4bcba051a86fa1c5ee05c
[ "MIT" ]
null
null
null
minds/sections/__init__.py
Atherz97/minds-bot
965f44ba39ad816947e4bcba051a86fa1c5ee05c
[ "MIT" ]
null
null
null
from minds.sections.newsfeed import NewsfeedAPI from minds.sections.channel import ChannelAPI from minds.sections.notifications import NotificationsAPI from minds.sections.posting import PostingAPI from minds.sections.interact import InteractAPI
41
57
0.878049
0
0
0
0
0
0
0
0
0
0
ccc14d33e30db584c95153ccde86ea32ce7c48be
8,331
py
Python
wavelet_prosody_toolkit/wavelet_prosody_toolkit/cwt_global_spectrum.py
eugenemfu/TTS_HW
34b3a32da2904578ddbd86bfd9529798cc3a1e9f
[ "BSD-3-Clause" ]
115
2019-08-06T08:34:33.000Z
2022-02-15T09:44:40.000Z
wavelet_prosody_toolkit/wavelet_prosody_toolkit/cwt_global_spectrum.py
eugenemfu/TTS_HW
34b3a32da2904578ddbd86bfd9529798cc3a1e9f
[ "BSD-3-Clause" ]
11
2019-08-13T15:27:07.000Z
2022-03-28T15:59:39.000Z
wavelet_prosody_toolkit/wavelet_prosody_toolkit/cwt_global_spectrum.py
eugenemfu/TTS_HW
34b3a32da2904578ddbd86bfd9529798cc3a1e9f
[ "BSD-3-Clause" ]
32
2019-01-30T12:00:15.000Z
2022-03-28T10:06:39.000Z
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ AUTHOR - Antti Suni <[email protected]> - Sébastien Le Maguer <[email protected]> DESCRIPTION usage: cwt_global_spectrum.py [-h] [-v] [-o OUTPUT] [-P] input_file Tool for extracting global wavel...
35.451064
171
0.591886
0
0
0
0
0
0
0
0
3,659
0.43915
ccc1a90b2d04001d5b226461f9c2d2ad26294437
4,177
py
Python
sdlc.py
phillipfurtado/mysearchengine
d28ad99b2729fba9df3f5f606c9aeafa2b257280
[ "Apache-2.0" ]
null
null
null
sdlc.py
phillipfurtado/mysearchengine
d28ad99b2729fba9df3f5f606c9aeafa2b257280
[ "Apache-2.0" ]
null
null
null
sdlc.py
phillipfurtado/mysearchengine
d28ad99b2729fba9df3f5f606c9aeafa2b257280
[ "Apache-2.0" ]
null
null
null
import sys import math import operator import re from os import listdir from os.path import isfile, join from PIL import Image IMAGE_WIDTH = 355 IMAGE_HEIGHT = 355 BORDER_DISCOUNT = 0.11 BLOCK_SIZE = 36 BLOCKS_SIZE = BLOCK_SIZE * BLOCK_SIZE X_BLOCK_SIZE = IMAGE_WIDTH / BLOCK_SIZE; Y_BLOCK_SIZE = IMAGE_HEIGHT / BLO...
27.123377
142
0.627484
0
0
0
0
0
0
0
0
558
0.133589
ccc2302b262199c91606683ac0c0ea01d97056a4
1,649
py
Python
betahex/training/supervised.py
StarvingMarvin/betahex
0626cf4d003e94423f34f3d83149702a5557ddb8
[ "MIT" ]
2
2019-03-17T07:09:14.000Z
2020-05-04T17:40:51.000Z
betahex/training/supervised.py
StarvingMarvin/betahex
0626cf4d003e94423f34f3d83149702a5557ddb8
[ "MIT" ]
null
null
null
betahex/training/supervised.py
StarvingMarvin/betahex
0626cf4d003e94423f34f3d83149702a5557ddb8
[ "MIT" ]
null
null
null
import tensorflow as tf from tensorflow.contrib import learn from betahex.features import Features from betahex.training.common import make_train_model, make_policy_input_fn, accuracy from betahex.models import MODEL tf.logging.set_verbosity(tf.logging.INFO) def main(unused_argv): # Load training and eval data...
25.765625
84
0.627653
0
0
0
0
0
0
0
0
246
0.149181
ccc373e2e0f33ced1981ea3d8ae722d60f288cc2
9,747
py
Python
MeterToTransPairingScripts.py
sandialabs/distribution-system-model-calibration
55493cc03b8ebcc5a0f2e7d2ff9092cb2e608f90
[ "BSD-3-Clause" ]
1
2021-11-12T21:30:35.000Z
2021-11-12T21:30:35.000Z
MeterTransformerPairing/MeterToTransPairingScripts.py
sandialabs/distribution-system-model-calibration
55493cc03b8ebcc5a0f2e7d2ff9092cb2e608f90
[ "BSD-3-Clause" ]
null
null
null
MeterTransformerPairing/MeterToTransPairingScripts.py
sandialabs/distribution-system-model-calibration
55493cc03b8ebcc5a0f2e7d2ff9092cb2e608f90
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- """ BSD 3-Clause License Copyright 2021 National Technology & Engineering Solutions of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S. Government retains certain rights in this software. Redistribution and use in source and binary forms, with or without...
48.492537
344
0.733149
0
0
0
0
0
0
0
0
6,910
0.708936
ccc51ab14667f22cd9b5eaba86b2724ac98a38f4
10,726
py
Python
mcdc_tnt/pyk_kernels/all/advance.py
jpmorgan98/MCDC-TNT-2
c437596097caa9af56df95213e7f64db38aac40e
[ "BSD-3-Clause" ]
1
2022-02-26T02:12:12.000Z
2022-02-26T02:12:12.000Z
mcdc_tnt/pyk_kernels/all/advance.py
jpmorgan98/MCDC-TNT-2
c437596097caa9af56df95213e7f64db38aac40e
[ "BSD-3-Clause" ]
null
null
null
mcdc_tnt/pyk_kernels/all/advance.py
jpmorgan98/MCDC-TNT-2
c437596097caa9af56df95213e7f64db38aac40e
[ "BSD-3-Clause" ]
1
2022-02-09T22:39:42.000Z
2022-02-09T22:39:42.000Z
import math import numpy as np import pykokkos as pk @pk.workload class Advance_cycle: def __init__(self, num_part, p_pos_x, p_pos_y, p_pos_z, p_dir_y, p_dir_z, p_dir_x, p_mesh_cell, p_speed, p_time, dx, mesh_total_xsec, L, p_dist_travled, p_end_trans, rands): self.p_pos_x: pk.View1D[pk.double] = p...
35.516556
312
0.591274
5,519
0.514544
0
0
5,558
0.51818
0
0
2,081
0.194015
ccc5fd6159d96d352e343e6b001e8aa4a53ede03
514
py
Python
DGF/auth/_authenticator.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
DGF/auth/_authenticator.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
DGF/auth/_authenticator.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
from django.conf import settings from ..defaults import AUTHENTICATORS from ..utils import get_module authenticators = [] all_args = [] def collect_authenticators(): global authenticators, all_args authenticators = list(map(get_module, getattr(settings, 'GRAHENE_ADDONS_AUTHENTICATORS', AUTHENTICATORS))) ...
34.266667
110
0.774319
0
0
0
0
0
0
0
0
31
0.060311
ccc6026c8a78ded0d003eb1ba605983fe1d65590
1,123
py
Python
facerec/face_util.py
seanbenhur/sih2020
f8b5988425185ed3c85872b98b622932895f932b
[ "MIT" ]
null
null
null
facerec/face_util.py
seanbenhur/sih2020
f8b5988425185ed3c85872b98b622932895f932b
[ "MIT" ]
null
null
null
facerec/face_util.py
seanbenhur/sih2020
f8b5988425185ed3c85872b98b622932895f932b
[ "MIT" ]
null
null
null
import face_recognition as fr def compare_faces(file1, file2): """ Compare two images and return True / False for matching. """ # Load the jpg files into numpy arrays image1 = fr.load_image_file(file1) image2 = fr.load_image_file(file2) # Get the face encodings for each face in each im...
33.029412
107
0.664292
0
0
0
0
0
0
0
0
537
0.478183
ccc6e968fc2455af2569e67afae509ff5c1e5fc0
3,354
py
Python
src/correlation/dataset_correlation.py
sakdag/crime-data-analysis
9c95238c6aaf1394f68be59e26e8c6d75f669d7e
[ "MIT" ]
null
null
null
src/correlation/dataset_correlation.py
sakdag/crime-data-analysis
9c95238c6aaf1394f68be59e26e8c6d75f669d7e
[ "MIT" ]
null
null
null
src/correlation/dataset_correlation.py
sakdag/crime-data-analysis
9c95238c6aaf1394f68be59e26e8c6d75f669d7e
[ "MIT" ]
null
null
null
import numpy as np import pandas as pd import pyproj as pyproj import shapely as shapely from shapely.geometry import Point from haversine import haversine import src.config.column_names as col_names def correlate_and_save(crime_df: pd.DataFrame, census_df: pd.DataFrame, ...
46.583333
129
0.707812
0
0
0
0
0
0
0
0
294
0.087657
cccac18c6d9e0d8ce330a9adb50aea424e46871f
197
py
Python
Function/xargs.py
tusharxoxoxo/Python-practice
2d75750029655c65271fd51a8d175285719a62e6
[ "MIT" ]
null
null
null
Function/xargs.py
tusharxoxoxo/Python-practice
2d75750029655c65271fd51a8d175285719a62e6
[ "MIT" ]
null
null
null
Function/xargs.py
tusharxoxoxo/Python-practice
2d75750029655c65271fd51a8d175285719a62e6
[ "MIT" ]
null
null
null
def increment(*numbers): print(numbers) def dance(*numbers): total = 1 for number in numbers: total *= number return total increment(3,4,5,6) print(dance(1,2,3,4,5,6))
13.133333
26
0.614213
0
0
0
0
0
0
0
0
0
0
cccd71a65c5bf63a13dfaa2062a6d5203e62b9ef
2,386
py
Python
blog/resources/tag.py
espstan/fBlog
7c63d117a3bbae3da80b3e8d7f731ae89036eb0d
[ "MIT" ]
2
2019-06-17T13:55:36.000Z
2019-06-19T22:40:06.000Z
blog/resources/tag.py
espstan/fBlog
7c63d117a3bbae3da80b3e8d7f731ae89036eb0d
[ "MIT" ]
35
2019-06-17T07:00:49.000Z
2020-02-17T09:41:53.000Z
blog/resources/tag.py
espstan/fBlog
7c63d117a3bbae3da80b3e8d7f731ae89036eb0d
[ "MIT" ]
null
null
null
from flask_restful import Resource from flask_restful import reqparse from sqlalchemy.exc import SQLAlchemyError from config import Configuration from models.tag import TagModel as TM class Tag(Resource): parser = reqparse.RequestParser() parser.add_argument('name', type=str, ...
31.394737
106
0.55658
2,193
0.919111
0
0
0
0
0
0
338
0.14166
ccd003a4c9bdfc241fd64f093ae2afa4fde92196
2,198
py
Python
Torrents/migrations/0001_initial.py
tabish-ali/torrent_site
58e2e7f943a28b16134b26f450b54e9a066e7114
[ "MIT" ]
1
2019-12-17T07:36:46.000Z
2019-12-17T07:36:46.000Z
Torrents/migrations/0001_initial.py
tabish-ali/torrent_site
58e2e7f943a28b16134b26f450b54e9a066e7114
[ "MIT" ]
null
null
null
Torrents/migrations/0001_initial.py
tabish-ali/torrent_site
58e2e7f943a28b16134b26f450b54e9a066e7114
[ "MIT" ]
null
null
null
# Generated by Django 3.0.7 on 2020-06-06 16:06 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Comments', fields=[ ('id', models.AutoField...
41.471698
114
0.560055
2,105
0.957689
0
0
0
0
0
0
374
0.170155
ccd0e580fc925afb48c3d9bac3c4c4c1b73ecf0c
5,493
py
Python
Agent.py
594zyc/CMCC_DialogSystem
9d85f4c319677bf5e682a562041b908fc3135a17
[ "Apache-2.0" ]
1
2019-11-20T16:36:30.000Z
2019-11-20T16:36:30.000Z
Agent.py
594zyc/CMCC_DialogSystem
9d85f4c319677bf5e682a562041b908fc3135a17
[ "Apache-2.0" ]
null
null
null
Agent.py
594zyc/CMCC_DialogSystem
9d85f4c319677bf5e682a562041b908fc3135a17
[ "Apache-2.0" ]
null
null
null
""" 结合所有的 Manager,实现text-in text-out的交互式 agent 的接口 """ import os import sys import time import argparse import logging BASE_DIR = os.path.dirname(os.path.abspath(__file__)) sys.path.append(os.path.join(BASE_DIR, '../..')) os.environ["CUDA_VISIBLE_DEVICES"]="1" from DM.DST.StateTracking import DialogStateTracker from D...
34.54717
97
0.54178
4,101
0.669551
0
0
0
0
0
0
1,731
0.282612
ccd2091aa554752b80be765a8333a7d8212199e1
1,712
py
Python
clu/constants/exceptions.py
fish2000/CLU
80bc2df5f001b5639d79ba979e19ec77a9931425
[ "BSD-3-Clause" ]
1
2019-07-02T08:17:59.000Z
2019-07-02T08:17:59.000Z
clu/constants/exceptions.py
fish2000/CLU
80bc2df5f001b5639d79ba979e19ec77a9931425
[ "BSD-3-Clause" ]
13
2019-12-17T02:28:30.000Z
2021-11-17T03:46:10.000Z
clu/constants/exceptions.py
fish2000/CLU
80bc2df5f001b5639d79ba979e19ec77a9931425
[ "BSD-3-Clause" ]
null
null
null
# -*- coding: utf-8 -*- from __future__ import print_function """ CLU’s Custom exception classes live here """ class BadDotpathWarning(Warning): """ Conversion from a path to a dotpath resulted in a bad dotpath … likely there are invalid characters like dashes in there. """ pass class CDBError(Ex...
28.065574
74
0.672313
1,288
0.7471
0
0
0
0
0
0
1,075
0.62355
ccd4b8a090334276bc85ce2b13557564dea0406a
231
py
Python
setup.py
seakarki/vehicle_accident_prediction
a921015104865dc1e4901fb1581f7822bef75f06
[ "FTL" ]
null
null
null
setup.py
seakarki/vehicle_accident_prediction
a921015104865dc1e4901fb1581f7822bef75f06
[ "FTL" ]
null
null
null
setup.py
seakarki/vehicle_accident_prediction
a921015104865dc1e4901fb1581f7822bef75f06
[ "FTL" ]
null
null
null
from setuptools import find_packages, setup setup( name='src', packages=find_packages(), version='0.1.0', description='Prediction of likely occurance of Vehicle Accident', author='sea karki', license='', )
21
69
0.679654
0
0
0
0
0
0
0
0
77
0.333333
ccd5ca4d81ce2bd9480bed7ee3a94756e7ada584
6,543
py
Python
utils/revOrm.py
NSLS-II/aphla
ceb5410dc836a8fb16321b6dc5e10d442be765c5
[ "BSD-3-Clause" ]
null
null
null
utils/revOrm.py
NSLS-II/aphla
ceb5410dc836a8fb16321b6dc5e10d442be765c5
[ "BSD-3-Clause" ]
1
2020-02-17T18:56:18.000Z
2020-02-20T17:06:20.000Z
utils/revOrm.py
NSLS-II/aphla
ceb5410dc836a8fb16321b6dc5e10d442be765c5
[ "BSD-3-Clause" ]
1
2021-03-08T16:07:11.000Z
2021-03-08T16:07:11.000Z
#!/usr/bin/env python import sys, time, os sys.path.append('../src') import numpy as np import matplotlib.pylab as plt import hla from hla import caget, caput def compare(o1, o2): print o1 print o2 npoint, nbpm, ntrim = np.shape(o1._rawmatrix) print "checking bpm" for i in range(nbpm): # ...
31.917073
197
0.52346
0
0
0
0
0
0
0
0
1,371
0.209537
ae9f5ca026e9179a91eee39f486434f7618b47ec
1,698
py
Python
Object Detection and Tracking HSV color space.py
shivtejshete/Advanced_Image_Processing
b5a7ef94a44ab0b3bd9fa4a70d843099af70079e
[ "MIT" ]
null
null
null
Object Detection and Tracking HSV color space.py
shivtejshete/Advanced_Image_Processing
b5a7ef94a44ab0b3bd9fa4a70d843099af70079e
[ "MIT" ]
null
null
null
Object Detection and Tracking HSV color space.py
shivtejshete/Advanced_Image_Processing
b5a7ef94a44ab0b3bd9fa4a70d843099af70079e
[ "MIT" ]
null
null
null
import numpy as np import cv2 #sample function - dummy callback function def nothing(x): pass #capture live video cap = cv2.VideoCapture(0) #window for trackbars cv2.namedWindow('Track') #defining trackbars to control HSV values of given video stream cv2.createTrackbar('L_HUE', 'Track', 0, 255, noth...
29.789474
86
0.6596
0
0
0
0
0
0
0
0
574
0.338045
ae9fdc83392f9acd375ec6b842e275792831330a
15,934
py
Python
tools/run_tests/xds_k8s_test_driver/tests/url_map/fault_injection_test.py
echo80313/grpc
93cdc8b77e7b3fe4a3afec1c9c7e29b3f02ec3cf
[ "Apache-2.0" ]
null
null
null
tools/run_tests/xds_k8s_test_driver/tests/url_map/fault_injection_test.py
echo80313/grpc
93cdc8b77e7b3fe4a3afec1c9c7e29b3f02ec3cf
[ "Apache-2.0" ]
4
2022-02-27T18:59:37.000Z
2022-02-27T18:59:53.000Z
tools/run_tests/xds_k8s_test_driver/tests/url_map/fault_injection_test.py
echo80313/grpc
93cdc8b77e7b3fe4a3afec1c9c7e29b3f02ec3cf
[ "Apache-2.0" ]
null
null
null
# Copyright 2021 The gRPC Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
43.654795
80
0.622756
10,934
0.686206
0
0
3,901
0.244822
0
0
4,117
0.258378
ae9ff35726e01cb8b94b132adc55d816f0af6cd8
2,008
py
Python
funda/spiders/FundaListings.py
royzwambag/funda-scraper
c288ae3521731d1fa12fbde7acc10d725048603a
[ "MIT" ]
1
2021-02-21T22:42:43.000Z
2021-02-21T22:42:43.000Z
funda/spiders/FundaListings.py
royzwambag/funda-scraper
c288ae3521731d1fa12fbde7acc10d725048603a
[ "MIT" ]
null
null
null
funda/spiders/FundaListings.py
royzwambag/funda-scraper
c288ae3521731d1fa12fbde7acc10d725048603a
[ "MIT" ]
1
2021-12-01T12:18:54.000Z
2021-12-01T12:18:54.000Z
import scrapy from ..items import BasicHouseItem from ..utils import generate_url class FundaListingsSpider(scrapy.Spider): name = 'funda_listings' allowed_domains = ["funda.nl"] custom_settings = { "FEED_EXPORT_FIELDS": ["address", "zipcode", "price", "house_size", "plot_size", "rooms", "url", "i...
44.622222
125
0.580677
1,923
0.957669
1,574
0.783865
0
0
0
0
667
0.332171
aea00ef15d75bbb6792d81d979d452ecd7795555
754
py
Python
wfdb/__init__.py
melbourne-cdth/wfdb-python
a36c22e12f8417ff18e57dbe54b7180dd183ec66
[ "MIT" ]
null
null
null
wfdb/__init__.py
melbourne-cdth/wfdb-python
a36c22e12f8417ff18e57dbe54b7180dd183ec66
[ "MIT" ]
null
null
null
wfdb/__init__.py
melbourne-cdth/wfdb-python
a36c22e12f8417ff18e57dbe54b7180dd183ec66
[ "MIT" ]
null
null
null
from wfdb.io.record import (Record, MultiRecord, rdheader, rdrecord, rdsamp, wrsamp, dl_database, edf2mit, mit2edf, wav2mit, mit2wav, wfdb2mat, csv2mit, sampfreq, signame, wfdbdesc, wfdbtime, sigavg) from wfdb.io.annotation import (Anno...
58
82
0.66313
0
0
0
0
0
0
0
0
0
0
aea011bdabd2351b652997696862bc1051c59d81
647
py
Python
reports/migrations/0103_auto_20190224_1000.py
CMU-TRP/podd-api
6eb5c4598f848f75d131287163cd9babf2a0a0fc
[ "MIT" ]
3
2020-04-26T06:28:50.000Z
2021-04-05T08:02:26.000Z
reports/migrations/0103_auto_20190224_1000.py
CMU-TRP/podd-api
6eb5c4598f848f75d131287163cd9babf2a0a0fc
[ "MIT" ]
10
2020-06-05T17:36:10.000Z
2022-03-11T23:16:42.000Z
reports/migrations/0103_auto_20190224_1000.py
CMU-TRP/podd-api
6eb5c4598f848f75d131287163cd9babf2a0a0fc
[ "MIT" ]
5
2021-04-08T08:43:49.000Z
2021-11-27T06:36:46.000Z
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations class Migration(migrations.Migration): dependencies = [ ('reports', '0102_recordspec_group_key'), ] operations = [ migrations.AlterField( model_name='reportimage', ...
23.962963
50
0.591963
538
0.83153
0
0
0
0
0
0
111
0.171561
aea0f505ac0ae8958de0fe2ef7a2f11f420d2940
936
py
Python
CodeFights2.py
sassy224/challenges
3e4c9c6fe19351f2e47408967bf1bd3f4ca63bb7
[ "MIT" ]
null
null
null
CodeFights2.py
sassy224/challenges
3e4c9c6fe19351f2e47408967bf1bd3f4ca63bb7
[ "MIT" ]
null
null
null
CodeFights2.py
sassy224/challenges
3e4c9c6fe19351f2e47408967bf1bd3f4ca63bb7
[ "MIT" ]
null
null
null
""" You are given a digital number written down on a sheet of paper. Your task is to figure out if you rotate the given sheet of paper by 180 degrees would the number still look exactly the same. input: "1" output: false input: "29562" output: true input: "77" output: false """ def digital_number(number): ...
21.767442
126
0.654915
0
0
0
0
0
0
0
0
732
0.780384
aea133a870e185a7ab120fb1bfa33b1fd3b07e6f
5,196
py
Python
AKSDataOpsDemo/scripts/evaluate.py
cloudmelon/aks-severless
ade3b6a110444c09bc4c0ff44cb232cb09ddebe7
[ "MIT" ]
6
2019-12-06T22:55:41.000Z
2019-12-10T23:57:40.000Z
AKSDataOpsDemo/scripts/evaluate.py
cloudmelon/aks-severless
ade3b6a110444c09bc4c0ff44cb232cb09ddebe7
[ "MIT" ]
null
null
null
AKSDataOpsDemo/scripts/evaluate.py
cloudmelon/aks-severless
ade3b6a110444c09bc4c0ff44cb232cb09ddebe7
[ "MIT" ]
2
2019-12-26T16:25:44.000Z
2020-09-02T22:43:41.000Z
import argparse import os, json, sys import azureml.core from azureml.core import Workspace from azureml.core import Experiment from azureml.core.model import Model import azureml.core from azureml.core import Run from azureml.core.webservice import AciWebservice, Webservice from azureml.core.conda_dependencies import...
33.960784
106
0.746151
0
0
0
0
0
0
0
0
1,548
0.297921
aea32992cb3ebb2d5d93b2c9d53e7b2172d6b5d0
2,048
py
Python
tools/instruction.py
mzins/MIPS-CPU-SIM
0f6723c668266447035c5010c67abdd041324d1a
[ "MIT" ]
null
null
null
tools/instruction.py
mzins/MIPS-CPU-SIM
0f6723c668266447035c5010c67abdd041324d1a
[ "MIT" ]
null
null
null
tools/instruction.py
mzins/MIPS-CPU-SIM
0f6723c668266447035c5010c67abdd041324d1a
[ "MIT" ]
null
null
null
from tools import instruction_helpers from tools.errors import InstructionNotFound from logs.logconfig import log_config LOG = log_config() class Instruction: binary_instruction = "" def __init__(self): inst = raw_input("Please type a single command\n") self.opcode = None self.binary...
37.236364
100
0.657715
1,903
0.929199
0
0
0
0
0
0
274
0.133789
aea38d32840ca9cfc7b545135134ea487ccba8a9
19,377
py
Python
projects/views.py
msherman64/portal
e5399ef2ed3051d7c9a46c660f028c666ae22ca6
[ "Apache-2.0" ]
null
null
null
projects/views.py
msherman64/portal
e5399ef2ed3051d7c9a46c660f028c666ae22ca6
[ "Apache-2.0" ]
null
null
null
projects/views.py
msherman64/portal
e5399ef2ed3051d7c9a46c660f028c666ae22ca6
[ "Apache-2.0" ]
null
null
null
from django.shortcuts import render from django.contrib.auth.decorators import login_required from chameleon.decorators import terms_required from django.contrib import messages from django.http import ( Http404, HttpResponseForbidden, HttpResponse, HttpResponseRedirect, HttpResponseNotAllowed, ...
35.489011
95
0.588533
0
0
0
0
14,583
0.752593
0
0
4,450
0.229654
aea745b7da47bd3d0550f56fe6d42adc49716eb3
268
py
Python
Easy/find_the_distance_value_between_two_arrays.py
BrynjarGeir/LeetCode
dbd57e645c5398dec538b6466215b61491c8d1d9
[ "MIT" ]
null
null
null
Easy/find_the_distance_value_between_two_arrays.py
BrynjarGeir/LeetCode
dbd57e645c5398dec538b6466215b61491c8d1d9
[ "MIT" ]
null
null
null
Easy/find_the_distance_value_between_two_arrays.py
BrynjarGeir/LeetCode
dbd57e645c5398dec538b6466215b61491c8d1d9
[ "MIT" ]
null
null
null
class Solution: def findTheDistanceValue(self, arr1: List[int], arr2: List[int], d: int) -> int: distance = 0 for element in arr1: if not any(c for c in arr2 if abs(c-element) <= d): distance += 1 return distance
38.285714
84
0.559701
268
1
0
0
0
0
0
0
0
0
aea75e1eb83214dedb643e0e6cd5c7568f6bf1b4
2,193
py
Python
listeners/pipe.py
ggilestro/majordomo
d111c1dd1a4c4b8d2cdaa9651b51ece60a1b648d
[ "MIT" ]
null
null
null
listeners/pipe.py
ggilestro/majordomo
d111c1dd1a4c4b8d2cdaa9651b51ece60a1b648d
[ "MIT" ]
null
null
null
listeners/pipe.py
ggilestro/majordomo
d111c1dd1a4c4b8d2cdaa9651b51ece60a1b648d
[ "MIT" ]
null
null
null
#!/usr/bin/env python2 # -*- coding: utf-8 -*- # # pipe.py # # Copyright 2014 Giorgio Gilestro <gg@kozak> # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the Licen...
28.480519
96
0.617419
1,144
0.52166
0
0
0
0
0
0
1,157
0.527588
aea97cde74c5b76516a1287e08c111bed632fb99
1,608
py
Python
scripts/android-patch.py
rasaha91/react-native-macos
5da5441c1d98596683590bc076541560db61ff82
[ "CC-BY-4.0", "MIT" ]
2,114
2020-05-06T10:05:45.000Z
2022-03-31T23:19:28.000Z
scripts/android-patch.py
rasaha91/react-native-macos
5da5441c1d98596683590bc076541560db61ff82
[ "CC-BY-4.0", "MIT" ]
623
2020-05-05T21:24:26.000Z
2022-03-30T21:00:31.000Z
scripts/android-patch.py
rasaha91/react-native-macos
5da5441c1d98596683590bc076541560db61ff82
[ "CC-BY-4.0", "MIT" ]
85
2020-05-05T23:09:40.000Z
2022-03-29T10:12:42.000Z
import os import sys # A Python script that can be used to determine which files that require # patching have been touched between two points in the repo. def shell(command): stream = os.popen(command) result = stream.read() stream.close() return result def get_patches(): patches = {} for fil...
34.212766
77
0.625622
0
0
0
0
0
0
0
0
288
0.179104
aeaa0a335119f48bebc88e35cf1698370503f3a0
259
py
Python
pyautofinance/common/strategies/usable_strategies/live_trading_test_strategy.py
webclinic017/PyAutoFinance
532cb1c5418dd9eeb07f2f08646170cde1fe0303
[ "MIT" ]
null
null
null
pyautofinance/common/strategies/usable_strategies/live_trading_test_strategy.py
webclinic017/PyAutoFinance
532cb1c5418dd9eeb07f2f08646170cde1fe0303
[ "MIT" ]
null
null
null
pyautofinance/common/strategies/usable_strategies/live_trading_test_strategy.py
webclinic017/PyAutoFinance
532cb1c5418dd9eeb07f2f08646170cde1fe0303
[ "MIT" ]
1
2022-02-24T09:18:13.000Z
2022-02-24T09:18:13.000Z
from pyautofinance.common.strategies.bracket_strategy import BracketStrategy class LiveTradingTestStrategy(BracketStrategy): def _open_long_condition(self) -> bool: return True def _open_short_condition(self) -> bool: return False
23.545455
76
0.760618
179
0.69112
0
0
0
0
0
0
0
0
aeaabc6f5b0d5b7cf3ded3141d91ff7d3817bb49
5,624
py
Python
src/example_publish_pypi_medium/asm-enforce-ready-signatures.py
lrhazi/example-publish-pypi
135bc75b0e37225b1879cb79d644f709977f1f3d
[ "MIT" ]
null
null
null
src/example_publish_pypi_medium/asm-enforce-ready-signatures.py
lrhazi/example-publish-pypi
135bc75b0e37225b1879cb79d644f709977f1f3d
[ "MIT" ]
null
null
null
src/example_publish_pypi_medium/asm-enforce-ready-signatures.py
lrhazi/example-publish-pypi
135bc75b0e37225b1879cb79d644f709977f1f3d
[ "MIT" ]
null
null
null
import json from docopt import docopt from bigip_utils.logger import logger from bigip_utils.bigip import * # # This script enforces all attack signatures that are ready to be enforced: # https://support.f5.com/csp/article/K60640453?utm_source=f5support&utm_medium=RSS # __doc__ = """ Usage: enforce-read...
43.9375
163
0.618243
0
0
0
0
0
0
0
0
2,414
0.429232
aeabb21d13fb47406449b6804d29f4983877b33d
13,358
py
Python
farb/sysinstall.py
samskivert/farbot
d88f16dcbd23d7ca3b7fdcf341c9346c0ab21bb8
[ "BSD-3-Clause" ]
null
null
null
farb/sysinstall.py
samskivert/farbot
d88f16dcbd23d7ca3b7fdcf341c9346c0ab21bb8
[ "BSD-3-Clause" ]
null
null
null
farb/sysinstall.py
samskivert/farbot
d88f16dcbd23d7ca3b7fdcf341c9346c0ab21bb8
[ "BSD-3-Clause" ]
null
null
null
# sysinstall.py vi:ts=4:sw=4:expandtab: # # Copyright (c) 2006-2008 Three Rings Design, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the a...
33.562814
96
0.643584
11,691
0.875206
0
0
0
0
0
0
6,775
0.507187
aeac7c6dc8a5f5e913ca2483b61751b8f3dca05f
1,233
py
Python
dynamo_consistency/dynamo/v1/siteinfo.py
dabercro/dynamo-consistency
f37dfebe781a833e9ae30869d8f57be79b4f583c
[ "MIT" ]
null
null
null
dynamo_consistency/dynamo/v1/siteinfo.py
dabercro/dynamo-consistency
f37dfebe781a833e9ae30869d8f57be79b4f583c
[ "MIT" ]
1
2018-02-20T21:21:14.000Z
2018-02-20T21:21:14.000Z
dynamo_consistency/dynamo/v1/siteinfo.py
dabercro/dynamo-consistency
f37dfebe781a833e9ae30869d8f57be79b4f583c
[ "MIT" ]
2
2018-06-25T11:27:45.000Z
2021-05-13T20:32:36.000Z
""" This module is for fetching information from dynamo about different sites """ from .inventory import _get_inventory def _small_query(*args): """ This is a wrapper function for opening and closing inventory connection :param args: arguments to pass to query :returns: Result of the query :rty...
20.898305
83
0.652879
0
0
0
0
0
0
0
0
745
0.604217
aeadb61a2cb83bca3659659ea3f7918d3b60f93f
1,163
py
Python
core/management/commands/onetime_fix_cover_paths.py
flaiming/bookfinder
59154d106b62680668087e46eca9c0bf9cdaf336
[ "MIT" ]
null
null
null
core/management/commands/onetime_fix_cover_paths.py
flaiming/bookfinder
59154d106b62680668087e46eca9c0bf9cdaf336
[ "MIT" ]
null
null
null
core/management/commands/onetime_fix_cover_paths.py
flaiming/bookfinder
59154d106b62680668087e46eca9c0bf9cdaf336
[ "MIT" ]
null
null
null
import shutil import os from django.core.management.base import BaseCommand, CommandError from django.conf import settings from .models import BookCover, get_book_cover_image_path class Command(BaseCommand): help = "" def handle(self, *args, **options): qs = BookCover.objects.exclude(image__iregex=r"...
31.432432
87
0.55632
980
0.842648
0
0
0
0
0
0
86
0.073947
aeafb1f7e55c1238f2645e1019c684aa0c10629d
1,002
py
Python
src/gafaelfawr/schema/admin_history.py
slaclab/gafaelfawr
7a64b0f159003d4745531c89d5b0f7d9777f7bce
[ "MIT" ]
null
null
null
src/gafaelfawr/schema/admin_history.py
slaclab/gafaelfawr
7a64b0f159003d4745531c89d5b0f7d9777f7bce
[ "MIT" ]
5
2019-06-18T17:28:52.000Z
2020-04-20T22:15:54.000Z
src/gafaelfawr/schema/admin_history.py
slaclab/gafaelfawr
7a64b0f159003d4745531c89d5b0f7d9777f7bce
[ "MIT" ]
1
2019-06-25T16:04:57.000Z
2019-06-25T16:04:57.000Z
"""The admin_history database table. This is a stopgap representation of changes to the admin table until we have a group system and a group-based authorization system up and running. """ from __future__ import annotations from datetime import datetime from sqlalchemy import Column, DateTime, Enum, Index, Integer, ...
30.363636
78
0.746507
536
0.53493
0
0
0
0
0
0
268
0.267465
aeb200362d7e9aa9bfe424f4789c60841fc0fb5c
316
py
Python
app/utils/build_handled_query.py
msolorio/flask_world_api
a2d5394618b736aa7d5d5e75a422dbe9e5713533
[ "MIT" ]
1
2022-02-24T04:37:04.000Z
2022-02-24T04:37:04.000Z
app/utils/build_handled_query.py
msolorio/flask_world_api
a2d5394618b736aa7d5d5e75a422dbe9e5713533
[ "MIT" ]
null
null
null
app/utils/build_handled_query.py
msolorio/flask_world_api
a2d5394618b736aa7d5d5e75a422dbe9e5713533
[ "MIT" ]
null
null
null
import traceback from ..models import ServerError def build_handled_query(query): def handled_query(*kwargs, **args): try: return query(*kwargs, **args) except: print('Stack Trace ==>', traceback.format_exc()) return ServerError() return handled_query
21.066667
60
0.617089
0
0
0
0
0
0
0
0
17
0.053797
aeb2c65fe32f5a74d10e3aa724b39a7ca6e18fa4
8,153
py
Python
wpscan_out_parse/parser/_cli_parser.py
clivewalkden/wpscan_out_parse
dff46aa2e98390afc79b7bb622eb4c01d066fbb5
[ "MIT" ]
1
2021-06-24T08:35:15.000Z
2021-06-24T08:35:15.000Z
wpscan_out_parse/parser/_cli_parser.py
clivewalkden/wpscan_out_parse
dff46aa2e98390afc79b7bb622eb4c01d066fbb5
[ "MIT" ]
null
null
null
wpscan_out_parse/parser/_cli_parser.py
clivewalkden/wpscan_out_parse
dff46aa2e98390afc79b7bb622eb4c01d066fbb5
[ "MIT" ]
null
null
null
import re from typing import Any, Dict, Sequence, List, Optional, Tuple from .base import Parser from .components import InterestingFinding from .results import WPScanResults #################### CLI PARSER ###################### class WPScanCliParser(Parser): """Main interface to parse WPScan CLI output. ...
36.725225
135
0.531461
7,917
0.971054
0
0
0
0
0
0
2,543
0.31191
aeb3088e188323526fd71e3f97c23bb2c556a657
1,095
py
Python
backend/backend/views.py
synw/django-mqueue-livefeed
d4e8cc2a4c1014f1d7322c297f8f50db9ab8540f
[ "MIT" ]
9
2016-08-30T16:15:15.000Z
2022-03-22T17:17:01.000Z
backend/backend/views.py
synw/django-mqueue-livefeed
d4e8cc2a4c1014f1d7322c297f8f50db9ab8540f
[ "MIT" ]
null
null
null
backend/backend/views.py
synw/django-mqueue-livefeed
d4e8cc2a4c1014f1d7322c297f8f50db9ab8540f
[ "MIT" ]
2
2017-01-20T22:03:53.000Z
2017-12-20T11:43:38.000Z
from typing import Any, Dict, Union from django.conf import settings from django.http.response import HttpResponseBase, HttpResponseRedirect from django.views.generic import TemplateView from django.contrib.auth.views import LoginView, redirect_to_login class LoginView(LoginView): template_name = "login_form.html...
36.5
84
0.689498
835
0.762557
0
0
0
0
0
0
133
0.121461
aeb3a40599bade079c5b02f2bf2cc33038b720fa
3,220
py
Python
tests/animation/generator/test_animation.py
OrangeUtan/MCMetagen
0293ea14bf1c6b1bae58741f9876ba662930b43d
[ "MIT" ]
null
null
null
tests/animation/generator/test_animation.py
OrangeUtan/MCMetagen
0293ea14bf1c6b1bae58741f9876ba662930b43d
[ "MIT" ]
null
null
null
tests/animation/generator/test_animation.py
OrangeUtan/MCMetagen
0293ea14bf1c6b1bae58741f9876ba662930b43d
[ "MIT" ]
null
null
null
import pytest from mcanitexgen.animation.generator import Animation, GeneratorError def frame(index: int, time: int): return {"index": index, "time": time} class Test_append: def test(self): anim1 = Animation(0, 10, [frame(0, 10)]) anim2 = Animation(10, 20, [frame(0, 10)]) anim1.ap...
29.009009
87
0.491304
3,051
0.947516
0
0
2,511
0.779814
0
0
228
0.070807
aeb447aba93643942a7e8b9f82a86a22f927bf04
2,214
py
Python
bin/mircx_polsplit.py
jdmonnier/mircx_mystic
45bf8491117674157b39f49cfe0c92c5ec6da500
[ "MIT" ]
1
2022-01-13T19:32:51.000Z
2022-01-13T19:32:51.000Z
bin/mircx_polsplit.py
jdmonnier/mircx_mystic
45bf8491117674157b39f49cfe0c92c5ec6da500
[ "MIT" ]
null
null
null
bin/mircx_polsplit.py
jdmonnier/mircx_mystic
45bf8491117674157b39f49cfe0c92c5ec6da500
[ "MIT" ]
null
null
null
#! /usr/bin/env python """ This is a "quick and dirty" solution to getting polarization data through the pipeline. This script creates new fits files with independent polarization states. Make sure you have plenty of diskspace. """ from __future__ import print_function import argparse import os from time import sleep...
32.558824
103
0.62421
0
0
0
0
0
0
0
0
866
0.391147
aeb56753078f68e7ebf914dfe3362d2ce395b9ab
44
py
Python
holoprot/models/__init__.py
vsomnath/holoprot
9bd6c58491eec701db94ce12f8e15e2143e202b9
[ "MIT" ]
10
2022-01-19T19:01:35.000Z
2022-03-21T13:04:59.000Z
holoprot/models/__init__.py
vsomnath/holoprot
9bd6c58491eec701db94ce12f8e15e2143e202b9
[ "MIT" ]
null
null
null
holoprot/models/__init__.py
vsomnath/holoprot
9bd6c58491eec701db94ce12f8e15e2143e202b9
[ "MIT" ]
3
2022-01-11T16:21:32.000Z
2022-03-11T15:33:57.000Z
from holoprot.models.trainer import Trainer
22
43
0.863636
0
0
0
0
0
0
0
0
0
0
aeb5bac5587511509d5243a09d8d7dc4620f3a3a
3,233
py
Python
mars/dataframe/datasource/core.py
HarshCasper/mars
4c12c968414d666c7a10f497bc22de90376b1932
[ "Apache-2.0" ]
2
2019-03-29T04:11:10.000Z
2020-07-08T10:19:54.000Z
mars/dataframe/datasource/core.py
HarshCasper/mars
4c12c968414d666c7a10f497bc22de90376b1932
[ "Apache-2.0" ]
null
null
null
mars/dataframe/datasource/core.py
HarshCasper/mars
4c12c968414d666c7a10f497bc22de90376b1932
[ "Apache-2.0" ]
null
null
null
# Copyright 1999-2020 Alibaba Group Holding Ltd. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
33.677083
82
0.631921
2,454
0.759047
0
0
1,748
0.540674
0
0
1,080
0.334055
aeb5f63f02d815be3691dc63ea53c88a38fdabc3
1,759
py
Python
scripts/chengyu.py
cfeibiao/chinese-xinhua
fc39a885e6bbd6d79576997bea53682af4e8f596
[ "MIT" ]
9,321
2018-02-10T09:17:33.000Z
2022-03-31T11:39:38.000Z
scripts/chengyu.py
cfeibiao/chinese-xinhua
fc39a885e6bbd6d79576997bea53682af4e8f596
[ "MIT" ]
48
2018-07-30T12:35:49.000Z
2022-03-11T03:49:24.000Z
scripts/chengyu.py
cfeibiao/chinese-xinhua
fc39a885e6bbd6d79576997bea53682af4e8f596
[ "MIT" ]
2,255
2018-03-12T09:54:37.000Z
2022-03-31T10:17:47.000Z
# -*- coding: utf-8 -*- """ author: pwxcoo date: 2018-02-05 description: 抓取下载成语并保存 """ import requests, json from bs4 import BeautifulSoup def downloader(url): """ 下载成语并保存 """ response = requests.get(url) if response.status_code != 200: print(f'{url} is failed!') return ...
32.574074
100
0.582149
0
0
0
0
0
0
0
0
502
0.28029
aeb856b22c775bb3a156957570f8b200275c77c9
21,563
py
Python
data/prepare_data_3dhp.py
YxZhxn/Ray3D
cc19cf1a8471b8464c172808e77d6305a3218a3c
[ "Apache-2.0" ]
23
2022-03-22T05:09:34.000Z
2022-03-31T08:24:43.000Z
data/prepare_data_3dhp.py
YxZhxn/Ray3D
cc19cf1a8471b8464c172808e77d6305a3218a3c
[ "Apache-2.0" ]
4
2022-03-22T05:11:48.000Z
2022-03-30T03:27:10.000Z
data/prepare_data_3dhp.py
YxZhxn/Ray3D
cc19cf1a8471b8464c172808e77d6305a3218a3c
[ "Apache-2.0" ]
2
2022-03-23T09:47:50.000Z
2022-03-25T01:12:18.000Z
import os import sys import copy import ipdb import json import mat73 import numpy as np import scipy.io as sio sys.path.append(os.path.join(os.path.dirname(__file__), '..')) from lib.camera.camera import CameraInfoPacket, catesian2homogenous rot = np.array([[1, 0, 0], [0, 0, -1], [0, 1, 0]]) # rotate along the x ax...
37.177586
119
0.518202
0
0
0
0
0
0
0
0
4,907
0.227566
aeb984e53fbe4f0422547372387cc06ffdabc996
1,512
py
Python
alipay/aop/api/response/KoubeiServindustryLeadsRecordBatchqueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
213
2018-08-27T16:49:32.000Z
2021-12-29T04:34:12.000Z
alipay/aop/api/response/KoubeiServindustryLeadsRecordBatchqueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
29
2018-09-29T06:43:00.000Z
2021-09-02T03:27:32.000Z
alipay/aop/api/response/KoubeiServindustryLeadsRecordBatchqueryResponse.py
antopen/alipay-sdk-python-all
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
[ "Apache-2.0" ]
59
2018-08-27T16:59:26.000Z
2022-03-25T10:08:15.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.response.AlipayResponse import AlipayResponse from alipay.aop.api.domain.LeadsOrderInfo import LeadsOrderInfo class KoubeiServindustryLeadsRecordBatchqueryResponse(AlipayResponse): def __init__(self): super(KoubeiServindustryL...
35.162791
120
0.70172
1,320
0.873016
0
0
652
0.431217
0
0
116
0.07672
aeba289fa36713ab8da25a19a9e51eb95799d065
6,125
py
Python
iadmin/filters.py
saxix/django-iadmin
675317e8f0b4142eaf351595da27c065637a83ba
[ "BSD-1-Clause" ]
1
2015-06-23T09:24:12.000Z
2015-06-23T09:24:12.000Z
iadmin/filters.py
saxix/django-iadmin
675317e8f0b4142eaf351595da27c065637a83ba
[ "BSD-1-Clause" ]
null
null
null
iadmin/filters.py
saxix/django-iadmin
675317e8f0b4142eaf351595da27c065637a83ba
[ "BSD-1-Clause" ]
null
null
null
from django.contrib.admin.filters import RelatedFieldListFilter, AllValuesFieldListFilter from django.db import models from django.db.models.query_utils import Q from django.utils.translation import ugettext as _ from django.utils.encoding import smart_unicode class CellFilter(object): title = "" menu_labels ...
37.576687
112
0.629388
5,837
0.95298
1,417
0.231347
0
0
0
0
587
0.095837
aeba984159365e20b71a8671ae068606c6f145f8
332
py
Python
db.py
amkudr/roadbotproject
f3a0cd10b85bc43e8c823b8670c8b4801e9ed3ab
[ "MIT" ]
null
null
null
db.py
amkudr/roadbotproject
f3a0cd10b85bc43e8c823b8670c8b4801e9ed3ab
[ "MIT" ]
1
2021-06-21T12:41:08.000Z
2021-06-21T12:41:08.000Z
db.py
amkudr/roadbotproject
f3a0cd10b85bc43e8c823b8670c8b4801e9ed3ab
[ "MIT" ]
1
2021-06-21T08:01:12.000Z
2021-06-21T08:01:12.000Z
from sqlalchemy import create_engine from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.orm import scoped_session, sessionmaker import settings engine = create_engine(settings.API_DATA) db_session = scoped_session(sessionmaker(bind=engine)) Base = declarative_base() Base.query = db_session.query...
27.666667
55
0.843373
0
0
0
0
0
0
0
0
0
0
aebb903fbc8412bafe91beffd2ed946df7885f12
132
py
Python
python/Numpy/np-arrays.py
cdrowley/hackerrank
cc5c925327cd3ce5b52c1614b814da75d42cca72
[ "MIT" ]
null
null
null
python/Numpy/np-arrays.py
cdrowley/hackerrank
cc5c925327cd3ce5b52c1614b814da75d42cca72
[ "MIT" ]
null
null
null
python/Numpy/np-arrays.py
cdrowley/hackerrank
cc5c925327cd3ce5b52c1614b814da75d42cca72
[ "MIT" ]
null
null
null
# https://www.hackerrank.com/challenges/np-arrays/problem import numpy def arrays(arr): return numpy.array(arr, float)[::-1]
16.5
57
0.712121
0
0
0
0
0
0
0
0
57
0.431818
aebbeb314ce75549bd49f12026710823e4b7c6f5
2,738
py
Python
pycfg.py
rhum1s/scripting_tools
c354a8a3bd38ca8aeaaa91405aa1c4ce703ef36b
[ "MIT" ]
null
null
null
pycfg.py
rhum1s/scripting_tools
c354a8a3bd38ca8aeaaa91405aa1c4ce703ef36b
[ "MIT" ]
null
null
null
pycfg.py
rhum1s/scripting_tools
c354a8a3bd38ca8aeaaa91405aa1c4ce703ef36b
[ "MIT" ]
null
null
null
# -*- coding:utf-8 -*- """ PyCfg - R. Souweine, 2016. """ import sys import os import ConfigParser from datetime import datetime class Cfg(): def __init__(self, cfg_file, cfg_sections, debug=False): """ Lecture d'un fichier de configuation type. """ if os.path.isfile(cfg_file): ...
34.225
88
0.528853
2,476
0.902661
0
0
0
0
0
0
647
0.235873
aebcb1ae1aa0b22cd2b6d96651c21aa61504ef82
504
py
Python
DGF/resolvers/change.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
DGF/resolvers/change.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
DGF/resolvers/change.py
LonguCodes/DGF
bd344eff34cbe6438f71631e2cc103f1c4584e09
[ "MIT" ]
null
null
null
from .utils import get_filters, get_values, get_relations, set_values, set_relations def default_resolve(schema, model, data, **kwargs): filters = get_filters(schema, data) return model.objects.filter(**filters) def default_execute(schema, data, raw_data, **kwargs): values = get_values(schema, raw_data)...
28
84
0.712302
0
0
0
0
0
0
0
0
0
0
aebe95d42dfd494b017b2be2cdcdbc8f022206bc
212
py
Python
11 Februari 2021/7_Ceil and Floor.py
FarrelRamdhani/KelasInformatika
4c43c0405f335447b10aab74afec627df23b919f
[ "MIT" ]
null
null
null
11 Februari 2021/7_Ceil and Floor.py
FarrelRamdhani/KelasInformatika
4c43c0405f335447b10aab74afec627df23b919f
[ "MIT" ]
null
null
null
11 Februari 2021/7_Ceil and Floor.py
FarrelRamdhani/KelasInformatika
4c43c0405f335447b10aab74afec627df23b919f
[ "MIT" ]
null
null
null
from math import ceil, floor, trunc x = 1.4 y = 2.6 print(floor(x), floor(y)) print(floor(-x), floor(-y)) print(ceil(x), ceil(y)) print(ceil(-x), ceil(-y)) print(trunc(x), trunc(y)) print(trunc(-x), trunc(-y))
17.666667
35
0.622642
0
0
0
0
0
0
0
0
0
0
aebf8e2ff0886eb00e8aeefe34ba66669b5dca4c
513
py
Python
clients/python/rest.py
BernardNotarianni/barrel-aof17
02b959aa38751f9912aa1b0dc5d112b76b727585
[ "Apache-2.0" ]
1
2017-09-11T00:35:49.000Z
2017-09-11T00:35:49.000Z
clients/python/rest.py
BernardNotarianni/barrel-aof17
02b959aa38751f9912aa1b0dc5d112b76b727585
[ "Apache-2.0" ]
null
null
null
clients/python/rest.py
BernardNotarianni/barrel-aof17
02b959aa38751f9912aa1b0dc5d112b76b727585
[ "Apache-2.0" ]
null
null
null
#!/usr/bin/env python import requests import json store = 'http://localhost:8080/source' print "post a document" doc = {'name': 'tom'} headers = {'Content-Type': 'application/json'} r = requests.post(store, headers=headers, data=json.dumps(doc)) print r.status_code docid = r.json()['id'] revid = r.json()['rev'] p...
18.321429
63
0.678363
0
0
0
0
0
0
0
0
172
0.335283
aec0c6a44b056aadc36e40e0073e2808b0d0bb55
10,463
py
Python
mvg_distributions/sqrt_gamma_gaussian.py
Liang813/tf_mvg
01bc681a8b3aac5dcf0837d481b963f4968eb777
[ "MIT" ]
21
2019-04-04T07:46:54.000Z
2021-12-15T18:06:35.000Z
mvg_distributions/sqrt_gamma_gaussian.py
Liang813/tf_mvg
01bc681a8b3aac5dcf0837d481b963f4968eb777
[ "MIT" ]
8
2019-03-01T10:08:30.000Z
2021-10-04T13:00:11.000Z
mvg_distributions/sqrt_gamma_gaussian.py
Liang813/tf_mvg
01bc681a8b3aac5dcf0837d481b963f4968eb777
[ "MIT" ]
7
2019-12-18T23:41:44.000Z
2021-11-21T10:15:48.000Z
import numpy as np import tensorflow as tf from tensorflow_probability.python.distributions import seed_stream import tensorflow_probability as tfp import mvg_distributions.covariance_representations as cov_rep from mvg_distributions.gamma import SqrtGamma tfd = tfp.distributions tfb = tfp.bijectors class SqrtGamma...
43.057613
119
0.640925
10,154
0.970467
0
0
2,305
0.2203
0
0
2,957
0.282615
aec3ddbaacba1c772ca5cc048314681c7330681e
3,606
py
Python
anymail/webhooks/sendinblue.py
alee/django-anymail
acca6a46e17143caadb0445d7bdeb2f1eb00b71b
[ "BSD-3-Clause" ]
1,324
2016-03-10T04:57:52.000Z
2022-03-31T15:14:58.000Z
anymail/webhooks/sendinblue.py
alee/django-anymail
acca6a46e17143caadb0445d7bdeb2f1eb00b71b
[ "BSD-3-Clause" ]
208
2016-03-10T03:40:59.000Z
2022-03-22T23:16:08.000Z
anymail/webhooks/sendinblue.py
alee/django-anymail
acca6a46e17143caadb0445d7bdeb2f1eb00b71b
[ "BSD-3-Clause" ]
129
2016-03-10T09:24:52.000Z
2022-02-07T05:37:24.000Z
import json from datetime import datetime from django.utils.timezone import utc from .base import AnymailBaseWebhookView from ..signals import AnymailTrackingEvent, EventType, RejectReason, tracking class SendinBlueTrackingWebhookView(AnymailBaseWebhookView): """Handler for SendinBlue delivery and engagement tr...
42.928571
111
0.640044
3,402
0.943428
0
0
0
0
0
0
1,267
0.351359
aec6b13b4c7b4c30dffc5f72de017a641a160409
2,232
py
Python
authentication/strategy.py
mitodl/bootcamp-ecommerce
ba7d6aefe56c6481ae2a5afc84cdd644538b6d50
[ "BSD-3-Clause" ]
2
2018-06-20T19:37:03.000Z
2021-01-06T09:51:40.000Z
authentication/strategy.py
mitodl/bootcamp-ecommerce
ba7d6aefe56c6481ae2a5afc84cdd644538b6d50
[ "BSD-3-Clause" ]
1,226
2017-02-23T14:52:28.000Z
2022-03-29T13:19:54.000Z
authentication/strategy.py
mitodl/bootcamp-ecommerce
ba7d6aefe56c6481ae2a5afc84cdd644538b6d50
[ "BSD-3-Clause" ]
3
2017-03-20T03:51:27.000Z
2021-03-19T15:54:31.000Z
"""Custom strategy""" from urllib.parse import urlencode from django.db import transaction from social_django.strategy import DjangoStrategy from main import features from profiles.models import LegalAddress, Profile class BootcampDjangoStrategy(DjangoStrategy): """Abstract strategy for botcamp app""" def ...
35.428571
96
0.696237
2,004
0.897849
0
0
0
0
0
0
756
0.33871
aec73f93f4747f28f93931758f77133311e3036f
83
py
Python
dynasty/__init__.py
LeMinaw/Dynasty
458685df8051cd11f497222e0cd7b672515cd6aa
[ "MIT" ]
2
2021-04-04T19:31:32.000Z
2022-02-06T13:38:09.000Z
dynasty/__init__.py
LeMinaw/Dynasty
458685df8051cd11f497222e0cd7b672515cd6aa
[ "MIT" ]
null
null
null
dynasty/__init__.py
LeMinaw/Dynasty
458685df8051cd11f497222e0cd7b672515cd6aa
[ "MIT" ]
null
null
null
__version__ = '0.0.2' from pathlib import Path APP_DIR = Path(__file__).parent
10.375
31
0.722892
0
0
0
0
0
0
0
0
7
0.084337
aec8d771cb10d5ba72ec5fd7b9d6f0e927a8f333
580
py
Python
addons/swift/tests/utils.py
tsukaeru/RDM-osf.io
2dc3e539322b6110e51772f8bd25ebdeb8e12d0e
[ "Apache-2.0" ]
11
2018-12-11T16:39:40.000Z
2022-02-26T09:51:32.000Z
addons/swift/tests/utils.py
tsukaeru/RDM-osf.io
2dc3e539322b6110e51772f8bd25ebdeb8e12d0e
[ "Apache-2.0" ]
52
2018-04-13T05:03:21.000Z
2022-03-22T02:56:19.000Z
addons/swift/tests/utils.py
tsukaeru/RDM-osf.io
2dc3e539322b6110e51772f8bd25ebdeb8e12d0e
[ "Apache-2.0" ]
16
2018-07-09T01:44:51.000Z
2021-06-30T01:57:16.000Z
# -*- coding: utf-8 -*- from addons.base.tests.base import OAuthAddonTestCaseMixin, AddonTestCase from addons.swift.provider import SwiftProvider from addons.swift.serializer import SwiftSerializer from addons.swift.tests.factories import SwiftAccountFactory class SwiftAddonTestCase(OAuthAddonTestCaseMixin, AddonTestC...
30.526316
73
0.753448
319
0.55
0
0
0
0
0
0
79
0.136207
aec9ee64277ff4b007aad939e4ac17372b6cdf19
1,311
py
Python
_grains/mac_sp.py
mosen/salt-osx
818d4ae89bb2853b28999a8ddb883c0fe1b1a657
[ "MIT" ]
68
2015-02-11T00:53:54.000Z
2021-11-06T16:07:17.000Z
_grains/mac_sp.py
Jaharmi/salt-osx
f6db606f04846d45935f3ed729e6243441cee360
[ "MIT" ]
13
2016-01-05T00:01:34.000Z
2022-03-18T23:44:21.000Z
_grains/mac_sp.py
Jaharmi/salt-osx
f6db606f04846d45935f3ed729e6243441cee360
[ "MIT" ]
19
2015-04-09T20:58:55.000Z
2020-11-04T06:39:06.000Z
# -*- coding: utf-8 -*- ''' Mac hardware information, generated by system_profiler. This is a separate grains module because it has a dependency on plistlib. ''' import logging import salt.utils import salt.modules.cmdmod log = logging.getLogger(__name__) __virtualname__ = 'mac_sp' try: import plistlib has...
25.211538
97
0.723112
0
0
0
0
0
0
0
0
695
0.53013
aeca5f1921632d7c1be82445181945bbbb66f42a
901
py
Python
cogs/insult.py
nikhilvayeda/Bhendi-Bot-3
2268e4310b91d6f3d62fe7bb642c3a57f623e215
[ "MIT" ]
8
2020-10-02T04:35:01.000Z
2021-11-08T10:38:32.000Z
cogs/insult.py
nikhilvayeda/Bhendi-Bot-3
2268e4310b91d6f3d62fe7bb642c3a57f623e215
[ "MIT" ]
8
2020-10-05T07:45:38.000Z
2021-03-13T22:02:28.000Z
cogs/insult.py
nikhilvayeda/Bhendi-Bot-3
2268e4310b91d6f3d62fe7bb642c3a57f623e215
[ "MIT" ]
2
2020-10-15T05:38:13.000Z
2020-10-29T11:41:16.000Z
import json import requests import discord from discord.ext import commands class Fun_insult(commands.Cog): def __init__(self, client): self.client = client @commands.command() async def insult(self, ctx): '''insult command''' _res = requests.get(url='https://evilinsu...
26.5
96
0.593785
751
0.833518
0
0
649
0.720311
624
0.692564
156
0.173141
aecc522dc3defa35037e11a7262e7658ad5e8c35
1,873
py
Python
util/monitor.py
reservoirlabs/G2-Mininet
4e0dd6b5367a1d51ee65310e59fc3b0ba55575b8
[ "BSD-3-Clause" ]
2
2021-08-20T08:29:49.000Z
2022-02-25T02:08:26.000Z
util/monitor.py
reservoirlabs/G2-Mininet
4e0dd6b5367a1d51ee65310e59fc3b0ba55575b8
[ "BSD-3-Clause" ]
2
2019-11-27T09:54:35.000Z
2019-12-05T15:52:03.000Z
util/monitor.py
reservoirlabs/G2-Mininet
4e0dd6b5367a1d51ee65310e59fc3b0ba55575b8
[ "BSD-3-Clause" ]
2
2020-03-12T14:38:06.000Z
2022-03-20T10:15:13.000Z
""" G2_RIGHTS. This module defines Monitor class to monitor CPU and memory utilization. Pre-requisite non-standard Python module(s): psutil """ import time import threading import psutil class Monitor(): def __init__(self, interval=1): """ Monitor constructor. Args: interval (i...
25.310811
91
0.549386
1,676
0.894821
0
0
0
0
0
0
892
0.476241
aecd3d71119eb36cd9ff199e7ad910beb0a003d1
2,888
py
Python
IO_supervisor.py
dwalley/SICXE
f3d019301e82712a1e94c6936b667bb5c93bbce0
[ "MIT" ]
null
null
null
IO_supervisor.py
dwalley/SICXE
f3d019301e82712a1e94c6936b667bb5c93bbce0
[ "MIT" ]
null
null
null
IO_supervisor.py
dwalley/SICXE
f3d019301e82712a1e94c6936b667bb5c93bbce0
[ "MIT" ]
null
null
null
# Module which defines how the I/O system works import sys, os from Registers import * from random import * from binascii import * class IO_supervisor(Registers): def __init__(self,my_registers): self.i_o = 'stuff' self.num_devices = 2 # native OS files simulate devices worki...
30.723404
79
0.602147
2,744
0.950139
0
0
0
0
0
0
819
0.283587