Dataset Viewer
Auto-converted to Parquet Duplicate
id
stringlengths
1
265
text
stringlengths
6
5.19M
dataset_id
stringclasses
7 values
3377378
<gh_stars>1-10 # AUTOGENERATED! DO NOT EDIT! File to edit: 01_image_classification.ipynb (unless otherwise specified). __all__ = ['data'] # Cell from fastai.vision.all import * # Cell data = DataBlock(blocks = (ImageBlock, CategoryBlock), get_items = get_image_files, get_y = parent_...
StarcoderdataPython
1625880
<reponame>Heyjoy/P3<filename>datafield.py<gh_stars>0 import math # models hyperParmeter TrainTestSplitSize = 0.2 N_EPOCH = 20 Verbose = 1 BatchSize = 64 zeroSteeringCount = 3 #GaussianNoiseStddev = 1 # Imgae Process tuning paramter IMGPath = '../data/IMG/' CSVPath = '../data/driving_log.csv' ImgShape = [160, 320, 3...
StarcoderdataPython
45432
<reponame>pep7/GorillaBot # Copyright (c) 2013-2016 <NAME> # # 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, modify,...
StarcoderdataPython
1649956
<reponame>jdmartinez36/azure-batch-cli-extensions # -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # ------------------...
StarcoderdataPython
128922
<reponame>Tiago-S-Ribeiro/Python-Pro-Bootcamp<filename>100_days_of_code/Intermediate+/day_37/main.py import requests import datetime as dt from data import USER, TOKEN, G_ID, PXL_ENDPOINT, NEW_PIXEL_ENDPOINT, GRAPH_ENDPOINT headers = { "X-USER-TOKEN": TOKEN } today = dt.datetime.now() #------------------- Create...
StarcoderdataPython
3251212
from .directory import DirectoryClient from .organization import OrganizationClient from .service import ServiceClient
StarcoderdataPython
1768653
import discord import secrets import itertools import random import re import os from keepAlive import keep_alive import requests import json client = discord.Client() prefix = '&' diceTypes = [4,6,8,10,12,20,100] dnd5e_races = ["DragonBorn", "Dwarf", "Elf", "Gnome", "Half-Elf", "Halfing", "Half-Orc", "Human", "Tief...
StarcoderdataPython
152736
''' defines all the sources necessary for building cgui.pyd ''' import os BUILD_BUDDYLIST_GUI = False thisdir = os.path.dirname(os.path.abspath(__file__)) sources = ''' src/ctextutil.cpp src/SplitImage4.cpp src/ScrollWindow.cpp src/skinvlist.cpp src/pyutils.cpp src/cwindowfx.cpp ...
StarcoderdataPython
1691462
from http.server import HTTPServer, SimpleHTTPRequestHandler class MyHTTPRequestHandler(SimpleHTTPRequestHandler): def do_GET(self): self.send_response(200) self.end_headers() self.wfile.write(b"hi there") if __name__ == '__main__': server_address = ('127.0.0.1', 8000) httpd = HT...
StarcoderdataPython
1684312
#!/usr/bin/env python """ TAP protocol client library. Copyright (c) 2010 <NAME> <<EMAIL>> """ import socket import string import random import struct import asyncore import mc_bin_server import mc_bin_client from memcacheConstants import REQ_MAGIC_BYTE, RES_MAGIC_BYTE from memcacheConstants import REQ_PKT_FMT, RE...
StarcoderdataPython
3281548
<gh_stars>1000+ #!/usr/bin/python3 """ [[https://bluemaestro.com/products/product-details/bluetooth-environmental-monitor-and-logger][Bluemaestro]] temperature/humidity/pressure monitor """ # todo most of it belongs to DAL... but considering so few people use it I didn't bother for now from datetime import datetime, t...
StarcoderdataPython
68495
import datetime from ..dojo_test_case import DojoTestCase from dojo.models import Test from dojo.tools.acunetix.parser import AcunetixParser class TestAcunetixParser(DojoTestCase): def test_parse_file_with_one_finding(self): testfile = open("unittests/scans/acunetix/one_finding.xml") parser = Ac...
StarcoderdataPython
1625657
# This module is used to map the old Python 2 names to the new names used in # Python 3 for the pickle module. This needed to make pickle streams # generated with Python 2 loadable by Python 3. # This is a copy of lib2to3.fixes.fix_imports.MAPPING. We cannot import # lib2to3 and use the mapping defined there, becaus...
StarcoderdataPython
4813743
<reponame>Shea192/pytorch-lightning<gh_stars>1-10 import torch from pytorch_lightning import Trainer from tests.base import EvalModelTemplate import tests.base.utils as tutils def test_training_epoch_end_metrics_collection(tmpdir): """ Test that progress bar metrics also get collected at the end of an epoch. ""...
StarcoderdataPython
25897
<reponame>nvuillam/checkov<filename>tests/cloudformation/graph_builder/test_local_graph.py import os from unittest import TestCase from checkov.cloudformation.graph_builder.graph_components.block_types import BlockType from checkov.cloudformation.graph_builder.local_graph import CloudformationLocalGraph from checkov.c...
StarcoderdataPython
3293553
# -*- coding: utf-8 -*- from argh.decorators import arg from lain_sdk.util import warn, info from lain_cli.utils import get_version_lists, lain_yaml, check_phase, ClusterConfig @arg('phase', help="lain cluster phase id, can be added by lain config save") @arg('-r', '--registry', help='registry url') def appversion(p...
StarcoderdataPython
3285051
#!/usr/bin/env python import sys #from heapq import heappush, heappop, heapify from random import randint, choice, seed try: import numpy #import scipy.sparse.linalg as la except ImportError: print("numpy not found") if sys.version_info.major>=3: long = int from bruhat.util import write class Poi...
StarcoderdataPython
89200
<reponame>subaruclover/apis-fixed<filename>plots_fixed.py<gh_stars>0 """ Show the results of different acc with plots input data files: .csv files with one week data from sample data House ID: E001 ~ E004 created by Qiong TODO: plot the sample data (from apis-emulator/data/input/Sample) and compare it with our acc dat...
StarcoderdataPython
1622599
#!/usr/bin/python2 # -*- coding: utf-8 -*- import os os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2' import glob, csv, librosa, os, subprocess, time import numpy as np import pandas as pd import data_vn try: from StringIO import StringIO except ImportError: from io import StringIO __author__ = '<EMAIL>' # data ...
StarcoderdataPython
164741
from functools import partial from . import utils import numpy as np import jax.numpy as jnp import jax.random as random from jax import grad, jit, vmap, lax, jacrev, jacfwd, jvp, vjp, hessian #class Lattice(seed, cell_params, sim_params, def random_c0(subkeys, odds_c, n): """Make random initial conditions g...
StarcoderdataPython
3248149
from flask import current_app, request, make_response, jsonify, abort from api.blueprint import api from core import crossdomain from flask_security import auth_token_required, roles_required from flask_login import current_user from jsonschema import validate from jsonschema.exceptions import ValidationError from api...
StarcoderdataPython
1745205
<reponame>WeiwenXu21/FRU<gh_stars>10-100 import math import tensorflow as tf from tensorflow.python.util import nest import collections import pdb _FRUStateTuple = collections.namedtuple("FRUStateTuple", ("state", "t")) class FRUStateTuple(_FRUStateTuple): """Tuple used by FRU Cells for `state_size`, `zero_stat...
StarcoderdataPython
1633058
<gh_stars>10-100 ################################################ ## Writen by <NAME> ################################################ from utilities import * from Co8 import * # Define dictionaries of ordinary gems and jewelry in the game. # Format is key : [value in gp, [list of proto numbers]] gem_table = { 1:...
StarcoderdataPython
1648823
# slope """ x_0: initial position dt: dt float iteration: integer a: accerelation 0 < a < 1 t: dt * iteration """ # class slope_field(object): # """docstring for slope_field""" # def __init__(self, arg): # super(slope_field, self).__init__() # self.arg = arg def slope(x_0, dt, iteration, a): ...
StarcoderdataPython
1646651
<filename>sdk/python/pulumi_azure/cognitive/outputs.py # coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapp...
StarcoderdataPython
4814134
from django.apps import AppConfig class ChatUsersConfig(AppConfig): name = 'chat_users'
StarcoderdataPython
1761695
from __future__ import print_function import sys import numpy as np def main(argv): np.random.seed(2) numPoints = 1001 xs = np.linspace(-5, 5, numPoints) probs = generateData(numPoints) convProbs = convolveProbs(probs) print(np.sum(convProbs)) plt.imshow(convProbs, interpolation = 'none') plt.sh...
StarcoderdataPython
1701222
import os os.system('docker login -u "dashy2004" -p "12345678qwerty123" repo.treescale.com') os.system('docker build -t games-day .') os.system('docker tag games-day repo.treescale.com/dashy2004/games-day:latest') os.system('docker push repo.treescale.com/dashy2004/games-day:latest') print('The build passed yay!')
StarcoderdataPython
1759169
import os import sys from alembic import command from alembic import config directory = os.path.abspath( os.path.join(os.path.dirname(__file__), '..')) sys.path.insert(0, directory) import settings import data.db_session as db_session directory = os.path.abspath( os.path.join(os.path.dirname(__file__), '../....
StarcoderdataPython
1666648
<filename>setup.py from setuptools import setup def readme(): with open('README.md') as f: return f.read() setup( name='diffenv', version='0.2.9', author='<NAME>, <NAME>', author_email='<EMAIL>, <EMAIL>', url='http://github.com/error-central/diffenv', description='Compare develop...
StarcoderdataPython
4833512
<gh_stars>0 from pathlib import Path import cv2 import matplotlib.pyplot as plt import numpy as np from skimage import io, transform from datawriter import FolderWriter, ICDAR2015Writer from synthgen import RendererV3 import random # Define some configuration variables: NUM_IMG = -1 # no. of images to use for gener...
StarcoderdataPython
47229
import os from flask import Flask from flask_restful import Resource, Api app = Flask(__name__) api = Api(app) class EnvironmentVariablesEndpoint(Resource): def get(self): return [(key, os.environ[key]) for key in os.environ.keys()] api.add_resource(EnvironmentVariablesEndpoint, '/') if __name__ == '...
StarcoderdataPython
37424
import math import pathlib import sys import torch import torch.nn as nn PROJECT_DIR = pathlib.Path(__file__).absolute().parent.parent.parent # main directory, the parent of src if str(PROJECT_DIR) not in sys.path: sys.path.append(str(PROJECT_DIR)) from src.model.ConvLayer import ConvLayer from src.m...
StarcoderdataPython
3333357
<filename>instascrape/structures.py import os import sys import json import logging import traceback from typing import * from io import BytesIO from collections import namedtuple, OrderedDict import requests from instascrape.constants import * from instascrape.exceptions import * from instascrape.group import * from...
StarcoderdataPython
End of preview. Expand in Data Studio

Dataset Card for "code_5p_data"

More Information needed

Downloads last month
9