code
stringlengths
1
25.8M
language
stringclasses
18 values
source
stringclasses
4 values
repo
stringclasses
78 values
path
stringlengths
0
268
#!/usr/bin/env python """ Setup ufuncs for the legendre polynomials ----------------------------------------- This example demonstrates how you can use the ufuncify utility in SymPy to create fast, customized universal functions for use with numpy arrays. An autowrapped sympy expression can be significantly faster tha...
unknown
codeparrot/codeparrot-clean
/* Copyright 2020 The TensorFlow Authors. All Rights Reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or a...
c
github
https://github.com/tensorflow/tensorflow
tensorflow/core/kernels/data/experimental/directed_interleave_dataset_op.h
/** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you...
java
github
https://github.com/apache/hadoop
hadoop-common-project/hadoop-common/src/test/java/org/apache/hadoop/io/TestDefaultStringifier.java
#!/usr/bin/env python3 '''Create YAML for dashboard page by querying GitHub repositories.''' import sys import time import yaml CONTROLS = ( ('swcarpentry/shell-novice', 'Unix Shell'), ('swcarpentry/git-novice', 'Git'), ('swcarpentry/hg-novice', 'Mercurial'), ('swcarpentry/sql-novice-survey', 'SQL'),...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- ############################################################################### # # DeleteFile # Moves a file to the trash. # # Python versions 2.6, 2.7, 3.x # # Copyright 2014, Temboo Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in...
unknown
codeparrot/codeparrot-clean
//===-- ASTSignalsTests.cpp -------------------------------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
cpp
github
https://github.com/llvm/llvm-project
clang-tools-extra/clangd/unittests/ASTSignalsTests.cpp
# -*- coding: utf-8 -*- import logging import socket import threading from connection import Connection from i2p.util import receive_line import shared class I2PListener(threading.Thread): def __init__(self, nick, host='127.0.0.1', port=7656): super().__init__(name='I2P Listener') self.host = hos...
unknown
codeparrot/codeparrot-clean
exports.abc = "abc"; exports.def = "def";
javascript
github
https://github.com/webpack/webpack
test/cases/cjs-tree-shaking/esm-to-cjs/module.js
#!/usr/bin/python # -*- coding: utf-8 -*- # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], ...
unknown
codeparrot/codeparrot-clean
# Copyright 2012 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
unknown
codeparrot/codeparrot-clean
// Copyright 2009 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package math import "unsafe" // Despite being an exported symbol, // Float32bits is linknamed by widely used packages. // Notable members of the hall of shame...
go
github
https://github.com/golang/go
src/math/unsafe.go
from __future__ import unicode_literals from setuptools import setup, find_packages from codecs import open from os import path __version__ = '0.0.1' here = path.abspath(path.dirname(__file__)) # Get the long description from the README file with open(path.join(here, 'README.md'), encoding='utf-8') as f: long_de...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env conda-execute """ CLI to build a folder full of recipes. Example usage: build.py /folder/of/recipes --python 2.7 3.4 3.5 --numpy 1.10 1.11 --token <your anaconda token> build.py --help """ # conda execute # env: # - conda-build # - anaconda-client # - networkx # - slacker # run_with: python import i...
unknown
codeparrot/codeparrot-clean
""" Regression tests for Django built-in views. """ from django.db import models from django.utils.encoding import python_2_unicode_compatible @python_2_unicode_compatible class Author(models.Model): name = models.CharField(max_length=100) def __str__(self): return self.name def get_absolute_url...
unknown
codeparrot/codeparrot-clean
import Cosmic from "cosmicjs"; import { PostType } from "interfaces"; import ErrorPage from "next/error"; const BUCKET_SLUG = process.env.COSMIC_BUCKET_SLUG; const READ_KEY = process.env.COSMIC_READ_KEY; const bucket = Cosmic().bucket({ slug: BUCKET_SLUG, read_key: READ_KEY, }); export const getPreviewPostBySlug...
typescript
github
https://github.com/vercel/next.js
examples/cms-cosmic/lib/api.tsx
"""Family Hub camera for Samsung Refrigerators.""" from pyfamilyhublocal import FamilyHubCam import voluptuous as vol from homeassistant.components.camera import PLATFORM_SCHEMA, Camera from homeassistant.const import CONF_IP_ADDRESS, CONF_NAME from homeassistant.helpers.aiohttp_client import async_get_clientsession i...
unknown
codeparrot/codeparrot-clean
# Copyright (c) 2015 OpenStack Foundation # # 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 ...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- import datetime from django.core.files.uploadedfile import SimpleUploadedFile from django.forms import Form, ModelForm, FileField, ModelChoiceField from django.test import TestCase from regressiontests.forms.models import ChoiceModel, ChoiceOptionModel, ChoiceFieldModel, FileModel, Group, Bounda...
unknown
codeparrot/codeparrot-clean
# Copyright 2014 OpenStack Foundation # # 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 ...
unknown
codeparrot/codeparrot-clean
# Copyright (C) 2010 Google 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: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the f...
unknown
codeparrot/codeparrot-clean
from ...attrs import LIKE_NUM # Source https://quizlet.com/4271889/1-100-urdu-number-wordsurdu-numerals-flash-cards/ # http://www.urduword.com/lessons.php?lesson=numbers # https://en.wikibooks.org/wiki/Urdu/Vocabulary/Numbers # https://www.urdu-english.com/lessons/beginner/numbers _num_words = """ایک دو تین چار پانچ ...
unknown
codeparrot/codeparrot-clean
// Copyright (c) HashiCorp, Inc. // SPDX-License-Identifier: BUSL-1.1 package configs import ( "fmt" "io/ioutil" "path" "path/filepath" "reflect" "sort" "strings" "testing" "github.com/davecgh/go-spew/spew" version "github.com/hashicorp/go-version" "github.com/hashicorp/hcl/v2" ) func TestBuildConfig(t ...
go
github
https://github.com/hashicorp/terraform
internal/configs/config_build_test.go
#!/usr/bin/python # coding=utf-8 ################################################################################ from test import CollectorTestCase from test import get_collector_config from test import unittest from mock import Mock from mock import patch from diamond.collector import Collector from postqueue impor...
unknown
codeparrot/codeparrot-clean
import numba; from numba import *; from numba.error import NumbaError from numba.testing.test_support import rewrite_doc @autojit def error1(): def inner(): pass @autojit def error2(): @autojit def inner(): pass @autojit def error3(): inner(10, 20, 30) @jit(restype=void, argtypes=...
unknown
codeparrot/codeparrot-clean
#### Note: this error code is no longer emitted by the compiler. The `start` function was defined with a where clause.
unknown
github
https://github.com/rust-lang/rust
compiler/rustc_error_codes/src/error_codes/E0647.md
// Copyright 2014 Manu Martinez-Almeida. All rights reserved. // Use of this source code is governed by a MIT style // license that can be found in the LICENSE file. package gin import ( "fmt" "io" "net/http" "os" "time" "github.com/mattn/go-isatty" ) type consoleColorModeValue int const ( autoColor console...
go
github
https://github.com/gin-gonic/gin
logger.go
# 3.4.0 > Published 22 January 2026 ### Features * [KTOR-8316](https://youtrack.jetbrains.com/issue/KTOR-8316) Support OpenAPI specification for the Ktor Client and Server Application * [KTOR-9085](https://youtrack.jetbrains.com/issue/KTOR-9085) Read OpenAPI security details from authentication plugin * [KTOR-899...
unknown
github
https://github.com/ktorio/ktor
CHANGELOG.md
#ifndef OPTIONS_PARSER_H_INCLUDED #define OPTIONS_PARSER_H_INCLUDED /* Copyright (c) 2016, 2025, Oracle and/or its affiliates. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2.0, as published by the Free Software Foundation. ...
c
github
https://github.com/mysql/mysql-server
sql/options_parser.h
/* origin: FreeBSD /usr/src/lib/msun/src/k_sinf.c */ /* * Conversion to float by Ian Lance Taylor, Cygnus Support, ian@cygnus.com. * Optimized by Bruce D. Evans. */ /* * ==================================================== * Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved. * * Developed at SunPr...
rust
github
https://github.com/nodejs/node
deps/crates/vendor/libm/src/math/k_sinf.rs
# -*- coding: utf-8 -*- # # Copyright (C) 2011-2014 Alexander Shorin # All rights reserved. # # This software is licensed as described in the file LICENSE, which # you should have received as part of this distribution. # import sys import simpleubjson from ..draft8 import Draft8Decoder from ..draft9 import Draft9Decod...
unknown
codeparrot/codeparrot-clean
from __future__ import unicode_literals import os from django.conf import settings from django.contrib.gis.geos import GEOSGeometry from django.contrib.gis.geoip import GeoIP, GeoIPException from django.utils import unittest # Note: Requires use of both the GeoIP country and city datasets. # The GEOIP_DATA path shoul...
unknown
codeparrot/codeparrot-clean
/* * Copyright (c) 1988-1997 Sam Leffler * Copyright (c) 1991-1997 Silicon Graphics, Inc. * * Permission to use, copy, modify, distribute, and sell this software and * its documentation for any purpose is hereby granted without fee, provided * that (i) the above copyright notices and this permission notice appear...
c
github
https://github.com/opencv/opencv
3rdparty/libtiff/tif_print.c
// Copyright 2013 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. package sort_test import ( "fmt" "sort" ) // A couple of type definitions to make the units clear. type earthMass float64 type au float64 // A Planet defin...
go
github
https://github.com/golang/go
src/sort/example_keys_test.go
from django import forms from django.contrib.auth.models import User from django.contrib.auth.forms import UserCreationForm, AuthenticationForm from django.forms import ModelForm class RegistrationForm(UserCreationForm): email = forms.EmailField(required=True) first_name = forms.CharField(required=True)...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- # (c) 2014-2016 Andreas Motl, Elmyra UG import re _slugify_strip_re = re.compile(r'[^\w\s-]') _slugify_strip_wo_equals_re = re.compile(r'[^\w\s=-]') _slugify_hyphenate_re = re.compile(r'[-\s]+') def slugify(value, strip_equals=True, lowercase=True): """ Normalizes string, converts to lo...
unknown
codeparrot/codeparrot-clean
import pytest from datetime import datetime, timedelta import pytz import numpy as np from pandas import (NaT, Index, Timestamp, Timedelta, Period, DatetimeIndex, TimedeltaIndex, Series, isna) from pandas.core.arrays import PeriodArray from pandas.util import testing as tm from...
unknown
codeparrot/codeparrot-clean
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not u...
unknown
codeparrot/codeparrot-clean
/** * @license * Copyright Google LLC All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.dev/license */ import {ChangeDetectorRef, Component} from '@angular/core'; @Component({ selector: 'app-root', templateUrl: './...
typescript
github
https://github.com/angular/angular
devtools/projects/demo-no-zone/src/app/app.component.ts
# Copyright (C) 2014 Nippon Telegraph and Telephone Corporation. # # 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 appli...
unknown
codeparrot/codeparrot-clean
// mksysnum_netbsd.pl // Code generated by the command above; DO NOT EDIT. package syscall const ( SYS_EXIT = 1 // { void|sys||exit(int rval); } SYS_FORK = 2 // { int|sys||fork(void); } SYS_READ = 3 // { ssize_t|sys||read(int fd, void *buf, size_t nbyte); } SY...
go
github
https://github.com/golang/go
src/syscall/zsysnum_netbsd_386.go
#!/usr/bin/python2 import fltk import sys import os #from __future__ import print_function def open_cb(): x = 1 def quit_cb(widget, data): sys.exit(0) def genmenuitems(): menuitems = (( "&File", 0, 0, 0, fltk.FL_SUBMENU ), #( "&New File", 0, new_cb ), #( "&Open File...", fl...
unknown
codeparrot/codeparrot-clean
import argparse import multiprocessing import numpy as np import chainer from chainer.optimizer_hooks import WeightDecay from chainer import serializers from chainer import training from chainer.training import extensions from chainer.training import triggers import chainermn from chainercv.chainer_experimental.data...
unknown
codeparrot/codeparrot-clean
"""Append module search paths for third-party packages to sys.path. **************************************************************** * This module is automatically imported during initialization. * **************************************************************** In earlier versions of Python (up to 1.5a3), scripts or...
unknown
codeparrot/codeparrot-clean
import croniter import datetime import os from django.conf import settings from django.contrib import messages from django.http import HttpResponseRedirect from django.urls import reverse from django.shortcuts import render, get_object_or_404 from django.utils.html import format_html from django.utils.safestring impor...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'form.ui' # # Created: Wed Feb 18 22:38:35 2015 # by: PyQt5 UI code generator 5.3.1 # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets class Ui_Form(object): def setupUi(self, Form):...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python # Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """ Removes bundled libraries to make sure they are not used. See README for more details. """ import optparse import os.path import ...
unknown
codeparrot/codeparrot-clean
/* Copyright 2017 - 2025 R. Thomas * Copyright 2017 - 2025 Quarkslab * * 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 req...
unknown
github
https://github.com/nodejs/node
deps/LIEF/include/LIEF/MachO/BinaryParser.hpp
framework: fragments: enabled: true hinclude_default_template: global_hinclude_template
unknown
github
https://github.com/symfony/symfony
src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/yml/fragments_and_hinclude.yml
from __future__ import unicode_literals from time import gmtime from calendar import timegm from datetime import datetime import pytz from dateutil.parser import parse from dateutil.relativedelta import relativedelta from elasticsearch import Elasticsearch from website import settings from util import generate_co...
unknown
codeparrot/codeparrot-clean
import requests from django.conf import settings from django.core.exceptions import ImproperlyConfigured from django.http import HttpResponse, QueryDict from django.middleware.csrf import get_token from django.shortcuts import redirect from django.views.decorators.http import require_GET, require_POST from allauth.soc...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python import sys s = "" index = 0 # The index of the current char into |s| vars = { } exprs = [] lastExpr = 0 stack = [] verboseMode = False # Read the file with the name specified by the second arg # (the first arg is the name of the executable) if len(sys.argv) >= 2: s = open(sys.argv[1]).read() n...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python import logging from collections import defaultdict from errno import ENOENT from stat import S_IFDIR, S_IFLNK, S_IFREG from sys import argv, exit from time import time from fuse import FUSE, FuseOSError, Operations, LoggingMixIn if not hasattr(__builtins__, 'bytes'): bytes = str class Mem...
unknown
codeparrot/codeparrot-clean
from datetime import datetime, timedelta from time import sleep from random import uniform from pokemongo_bot.base_task import BaseTask class SleepSchedule(BaseTask): """Pauses the execution of the bot every day for some time Simulates the user going to sleep every day for some time, the sleep time and th...
unknown
codeparrot/codeparrot-clean
from __future__ import absolute_import, unicode_literals import datetime from django.contrib.auth.models import User from django.test import TestCase from django.utils.datastructures import SortedDict from .models import TestObject, Order, RevisionableModel class ExtraRegressTests(TestCase): def setUp(self): ...
unknown
codeparrot/codeparrot-clean
/* * Copyright (C) 2007 The Guava 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 agr...
java
github
https://github.com/google/guava
android/guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java
{ "kind": "Dashboard", "apiVersion": "dashboard.grafana.app/v2beta1", "metadata": { "name": "v34.multiple_stats_cloudwatch.v42" }, "spec": { "annotations": [ { "kind": "AnnotationQuery", "spec": { "query": { "kind": "DataQuery", "group": "grafana...
json
github
https://github.com/grafana/grafana
apps/dashboard/pkg/migration/conversion/testdata/migrated_dashboards_output/v1beta1-mig-v34.multiple_stats_cloudwatch.v42.v2beta1.json
"""Utilities for the neural network modules """ # Author: Issam H. Laradji <issam.laradji@gmail.com> # License: BSD 3 clause import numpy as np from scipy.special import expit as logistic_sigmoid def identity(X): """Simply return the input array. Parameters ---------- X : {array-like, sparse matrix...
unknown
codeparrot/codeparrot-clean
# Copyright 2018 PerfKitBenchmarker Authors. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
unknown
codeparrot/codeparrot-clean
<script setup> import * as d3 from "d3"; import WorldMap from "../components/WorldMap.vue"; const width = 688; const height = 400; </script> # Azimuthal projections Azimuthal projections project the sphere directly onto a plane. ## geoAzimuthalEqualArea() {#geoAzimuthalEqualArea} <a href="https://observablehq.co...
unknown
github
https://github.com/d3/d3
docs/d3-geo/azimuthal.md
//===--- GenObjC.h - Swift IR generation for Objective-C --------*- C++ -*-===// // // This source file is part of the Swift.org open source project // // Copyright (c) 2014 - 2017 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/L...
c
github
https://github.com/apple/swift
lib/IRGen/GenObjC.h
/* * Written by Doug Lea with assistance from members of JCP JSR-166 * Expert Group and released to the public domain, as explained at * http://creativecommons.org/publicdomain/zero/1.0/ */ /* * Source: * http://gee.cs.oswego.edu/cgi-bin/viewcvs.cgi/jsr166/src/jsr166e/LongAdder.java?revision=1.17 */ package co...
java
github
https://github.com/google/guava
android/guava/src/com/google/common/cache/LongAdder.java
!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.flamegraph=n():(t.flamegraph=t.flamegraph||{},t.flamegraph.tooltip=n())}(self,(function(){return(()=>{"use strict";var t={d:(n,e)=>{for(var r in e)t.o(e...
javascript
github
https://github.com/python/cpython
Lib/profiling/sampling/_vendor/d3-flame-graph/4.1.3/d3-flamegraph-tooltip.min.js
/* * Copyright 2014-2019 JetBrains s.r.o and contributors. Use of this source code is governed by the Apache 2.0 license. */ package io.ktor.client.engine.okhttp import io.ktor.utils.io.* import io.ktor.utils.io.streams.asByteWriteChannel import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Dispatcher...
kotlin
github
https://github.com/ktorio/ktor
ktor-client/ktor-client-okhttp/jvm/src/io/ktor/client/engine/okhttp/StreamRequestBody.kt
package v0alpha1 import ( "context" "github.com/grafana/grafana-app-sdk/resource" ) type SnapshotClient struct { client *resource.TypedClient[*Snapshot, *SnapshotList] } func NewSnapshotClient(client resource.Client) *SnapshotClient { return &SnapshotClient{ client: resource.NewTypedClient[*Snapshot, *Snapsho...
go
github
https://github.com/grafana/grafana
apps/dashboard/pkg/apis/dashboard/v0alpha1/snapshot_client_gen.go
function Component(props) { const x = useState; const state = x(null); return state[0]; }
javascript
github
https://github.com/facebook/react
compiler/packages/babel-plugin-react-compiler/src/__tests__/fixtures/compiler/error.invalid-assign-hook-to-local.js
#!/usr/bin/python # (c) 2017, NetApp, Inc # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['deprecated'], ...
unknown
codeparrot/codeparrot-clean
area: "Transform" issues: - 95367 pr: 142403 summary: Fix transform validation to reject PUT and `_start` when user lacks remote index permissions type: bug
unknown
github
https://github.com/elastic/elasticsearch
docs/changelog/142403.yaml
import warnings import numpy as np import matplotlib as mpl import matplotlib.pyplot as plt from ._core import ( VectorPlotter, ) from .utils import ( locator_to_legend_entries, adjust_legend_subtitles, _default_color, _deprecate_ci, ) from ._statistics import EstimateAggregator from .axisgrid imp...
unknown
codeparrot/codeparrot-clean
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: MPL-2.0 package framework import ( "context" "fmt" "net/http" "reflect" "strings" "sync/atomic" "testing" "time" "github.com/hashicorp/go-secure-stdlib/strutil" "github.com/hashicorp/vault/sdk/helper/consts" "github.com/hashicorp/vault/sdk/logi...
go
github
https://github.com/hashicorp/vault
sdk/framework/backend_test.go
name: Build Triton wheels on: push: branches: - main tags: # NOTE: Binary build pipelines should only get triggered on release candidate builds # Release candidate tags look like: v1.11.0-rc1 - v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ - 'ciflow/triton_binaries/*' paths: - .githu...
unknown
github
https://github.com/pytorch/pytorch
.github/workflows/build-triton-wheel.yml
from __future__ import annotations import typing as t import pytest from pytest_mock import MockerFixture from ansible._internal._errors._handler import ErrorHandler, ErrorAction from ansible.parsing.vault import VaultSecretsContext, VaultSecret from ansible._internal._templating._engine import _TemplateConfig from...
python
github
https://github.com/ansible/ansible
test/units/controller_only_conftest.py
__author__ = 'civa' OBJECT_TYPES = dict(STAR=0, CATALOG_STAR=1, PLANET=2, OPEN_CLUSTER=3, GLOBULAR_CLUSTER=4, GASEOUS_NEBULA=5, PLANETARY_NEBULA=6, SUPERNOVA_REMNANT=7, GALAXY=8, COMET=9, ASTEROID=10, CONSTELLATION=11, MOON=12, ASTERISM=13, GALAXY_CLUSTER=14, DARK_NEBULA=15, QUASAR=16, MULT_STAR=17, RADIO_SOURCE=18...
unknown
codeparrot/codeparrot-clean
# coding: utf-8 # # Copyright 2014 The Oppia Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requi...
unknown
codeparrot/codeparrot-clean
# -*- coding: utf-8 -*- # --------------------------------------------------------------------- # # --------------------------------------------------------------------- # Copyright (C) 2017-2018 The --- Project # See LICENSE for details # --------------------------------------------------------------------- class Con...
unknown
codeparrot/codeparrot-clean
from __future__ import with_statement from cms.api import create_page, add_plugin from cms.models.pluginmodel import CMSPlugin from cms.plugins.text.models import Text from cms.test_utils.testcases import (CMSTestCase, URL_CMS_PLUGIN_ADD, URL_CMS_PLUGIN_EDIT, URL_CMS_PLUGIN_REMOVE) from django.conf import settings ...
unknown
codeparrot/codeparrot-clean
# Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors # MIT License. See license.txt # For license information, please see license.txt from __future__ import unicode_literals import webnotes import webnotes.utils import os, datetime from website.doctype.website_sitemap.website_sitemap import add_to...
unknown
codeparrot/codeparrot-clean
# vim: set et sw=3 tw=0 fo=awqorc ft=python: # # Astxx, the Asterisk C++ API and Utility Library. # Copyright (C) 2005, 2006 Matthew A. Nicholson # Copyright (C) 2006 Tim Blechmann # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License ...
unknown
codeparrot/codeparrot-clean
from __future__ import unicode_literals from django.conf import settings from django.contrib.redirects.models import Redirect from django.contrib.sites.models import get_current_site from django.core.exceptions import ImproperlyConfigured from django import http class RedirectFallbackMiddleware(object): # Define...
unknown
codeparrot/codeparrot-clean
// Copyright IBM Corp. 2016, 2025 // SPDX-License-Identifier: BUSL-1.1 package http import ( "bytes" "context" "crypto/tls" "encoding/json" "errors" "io" "net/http" "net/http/httptest" "net/textproto" "net/url" "reflect" "runtime" "strings" "testing" "github.com/go-test/deep" "github.com/hashicorp/go...
go
github
https://github.com/hashicorp/vault
http/handler_test.go
#!/usr/bin/python # # GemUO # # (c) 2005-2010 Max Kellermann <max@duempel.org> # # 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; version 2 of the License. # # This program is distribut...
unknown
codeparrot/codeparrot-clean
"""Test Tracer classes.""" from __future__ import annotations from datetime import datetime, timezone from typing import Any from uuid import uuid4 import pytest from freezegun import freeze_time from langchain_core.callbacks import AsyncCallbackManager from langchain_core.exceptions import TracerException from lan...
python
github
https://github.com/langchain-ai/langchain
libs/core/tests/unit_tests/tracers/test_async_base_tracer.py
# Copyright 2010 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requ...
unknown
codeparrot/codeparrot-clean
# # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under...
unknown
codeparrot/codeparrot-clean
# (c) 2005 Ian Bicking and contributors; written for Paste (http://pythonpaste.org) # Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php """ This module implements a class for handling URLs. """ from six.moves.urllib.parse import quote, unquote, urlencode import cgi from paste import re...
unknown
codeparrot/codeparrot-clean
# stdlib import cPickle as pickle import logging import struct # 3p from tornado.ioloop import IOLoop from tornado.tcpserver import TCPServer log = logging.getLogger(__name__) class GraphiteServer(TCPServer): def __init__(self, app, hostname, io_loop=None, ssl_options=None, **kwargs): log.warn('Graphite...
unknown
codeparrot/codeparrot-clean
# -*- test-case-name: twisted.conch.test.test_transport -*- # Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ The lowest level SSH protocol. This handles the key negotiation, the encryption and the compression. The transport layer is described in RFC 4253. Maintainer: Paul Swartz """ from...
unknown
codeparrot/codeparrot-clean
/* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Version 2.0 * (the "License"); you may n...
java
github
https://github.com/apache/kafka
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/TransformationStage.java
# coding=utf-8 """ Collect statistics from a HTTP or HTTPS connexion #### Dependencies * urllib2 #### Usage Add the collector config as : enabled = True ttl_multiplier = 2 path_suffix = "" measure_collector_time = False byte_unit = byte, req_vhost = www.my_server.com req_url = https://www.my_server.com/, https://...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # # Copyright (c) 2015, Darren Worrall <darren@iweb.co.uk> # Copyright (c) 2015, René Moser <mail@renemoser.net> # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) ANSIBLE_METADATA = {'metadata_version': '1.1', 'sta...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python ''' OWASP ZSC https://www.owasp.org/index.php/OWASP_ZSC_Tool_Project https://github.com/zscproject/OWASP-ZSC http://api.z3r0d4y.com/ https://groups.google.com/d/forum/owasp-zsc [ owasp-zsc[at]googlegroups[dot]com ] ''' import binascii import random import string from core.compatible import version...
unknown
codeparrot/codeparrot-clean
# sql/default_comparator.py # Copyright (C) 2005-2016 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php """Default implementation of SQL comparison operations. """ from .. impor...
unknown
codeparrot/codeparrot-clean
from __future__ import absolute_import from django.core.urlresolvers import reverse from django.http import HttpRequest from sentry.models import User from sentry.testutils import TestCase from sentry.utils.auth import EmailAuthBackend, get_login_redirect class EmailAuthBackendTest(TestCase): def setUp(self): ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2016, Abdoul Bah (@helldorado) <bahabdoul at gmail.com> """ Ansible module to manage Qemu(KVM) instance in Proxmox VE cluster. This module is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Fr...
unknown
codeparrot/codeparrot-clean
from __future__ import unicode_literals import logging import os from django.utils.translation import ugettext_lazy as _ import paramiko from reviewboard.ssh.errors import MakeSSHDirError, UnsupportedSSHKeyError class SSHStorage(object): def __init__(self, namespace=None): self.namespace = namespace ...
unknown
codeparrot/codeparrot-clean
#!/usr/bin/env python __author__ = "Mike McCann" __copyright__ = "Copyright 2012, MBARI" __license__ = "GPL" __maintainer__ = "Mike McCann" __email__ = "mccann at mbari.org" __doc__ = ''' Script to read data from Western Flyer Seabird profile ctd .asc files and write them to netCDF files. Use the conventions for Tra...
unknown
codeparrot/codeparrot-clean
from __future__ import print_function import re from datetime import datetime, timedelta import numpy as np import pandas as pd from pandas.tseries.base import DatetimeIndexOpsMixin from pandas.util.testing import assertRaisesRegexp, assert_isinstance from pandas.tseries.common import is_datetimelike from pandas import...
unknown
codeparrot/codeparrot-clean
# Copyright 2018 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
unknown
codeparrot/codeparrot-clean
# download_sync_controller # # Copyright (C) 2012-2013 Intel Corporation. All rights reserved. # # This program is free software; you can redistribute it and/or modify it # under the terms and conditions of the GNU Lesser General Public License, # version 2.1, as published by the Free Software Foundation. # # This prog...
unknown
codeparrot/codeparrot-clean
import os import sys import ssl import pprint import socket import urllib.parse # Rename HTTPServer to _HTTPServer so as to avoid confusion with HTTPSServer. from http.server import (HTTPServer as _HTTPServer, SimpleHTTPRequestHandler, BaseHTTPRequestHandler) from test import support threading = support.import_mod...
unknown
codeparrot/codeparrot-clean
# MySQL Connector/Python - MySQL driver written in Python. # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. # MySQL Connector/Python is licensed under the terms of the GPLv2 # <http://www.gnu.org/licenses/old-licenses/gpl-2.0.html>, like most # MySQL Connectors. There are special exceptio...
unknown
codeparrot/codeparrot-clean