max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
5,937 | // Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
//+---------------------------------------------------------------------------
//
//
// Description:
// Decl... | 472 |
488 | <reponame>maurizioabba/rose<gh_stars>100-1000
public class cave3_for0 {
public void loop() {
for(int i = 0; i < 10; i++) {
}
}
}
| 67 |
604 | import copy
import json
from mmdet.datasets import DATASETS, CocoDataset
from mmdet.datasets.api_wrappers import COCO
@DATASETS.register_module()
class PseudoCocoDataset(CocoDataset):
def __init__(
self,
ann_file,
pseudo_ann_file,
pipeline,
confidence_threshold=0.9,
... | 1,294 |
1,223 | <filename>src/Binding/JSNFS.cpp
/*
Copyright 2016 Nidium Inc. All rights reserved.
Use of this source code is governed by a MIT license
that can be found in the LICENSE file.
*/
#include "Binding/JSNFS.h"
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <jsapi.h>
#include "Core/Path.h"
... | 1,700 |
644 | # Copyright <NAME> 2016
"""
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
distri... | 5,008 |
852 | #ifndef DE_TRAIT_H
#define DE_TRAIT_H
/*\class template DEtrait
*\description data|emulation auxiliary template
type associator trait struct
*\author <NAME> (CERN)
*\date 07.03
*/
// L1 dataformats includes
#include "DataFormats/EcalDigi/interface/EcalDigiCollections.h"
#include "DataFormats/HcalD... | 3,246 |
4,036 |
typedef unsigned int size_t;
void *memset(void *ptr, int value, size_t num);
struct myStruct
{
int x, y;
};
typedef myStruct *myStructPtr;
struct otherStruct
{
int a, b;
};
#define NUM (10)
int main()
{
{
myStruct ms;
memset(&ms, 0, sizeof(myStruct)); // GOOD
memset(&ms, 0, sizeof(ms)); // GOOD
memset(... | 2,181 |
669 | // Copyright 2019 <NAME>
// 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, so... | 2,686 |
3,799 | /*
* Copyright 2021 The Android Open Source Project
*
* 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... | 1,462 |
348 | <reponame>chamberone/Leaflet.PixiOverlay<filename>docs/data/leg-t2/026/02603289.json
{"nom":"Saillans","circ":"3ème circonscription","dpt":"Drôme","inscrits":1079,"abs":612,"votants":467,"blancs":75,"nuls":23,"exp":369,"res":[{"nuance":"REM","nom":"<NAME>","voix":263},{"nuance":"LR","nom":"<NAME>","voix":106}]} | 128 |
2,206 | <reponame>steljord2/deeplearning4j<filename>libnd4j/include/helpers/impl/HessenbergAndSchur.cpp<gh_stars>1000+
/* ******************************************************************************
*
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 w... | 4,654 |
2,759 | <filename>src/yb/docdb/doc_ttl_util.h
// Copyright (c) YugaByte, Inc.
//
// 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 ... | 872 |
809 | <gh_stars>100-1000
/*
* LensKit, an open-source toolkit for recommender systems.
* Copyright 2014-2017 LensKit contributors (see CONTRIBUTORS.md)
* Copyright 2010-2014 Regents of the University of Minnesota
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and ass... | 2,120 |
603 | <filename>src/main/java/com/onarandombox/MultiverseCore/enums/AddProperties.java
/******************************************************************************
* Multiverse 2 Copyright (c) the Multiverse Team 2011. *
* Multiverse 2 is licensed under the BSD License. *... | 344 |
319 | /**
* FaceTracker Licence
* -------------------
* (Academic, non-commercial, not-for-profit licence)
*
* Copyright (c) 2010 <NAME>
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* ... | 2,716 |
854 | <reponame>timxor/leetcode-journal
__________________________________________________________________________________________________
sample 5 ms submission
class Solution {
public boolean searchMatrix(int[][] matrix, int target) {
if(matrix==null || matrix.length==0 || matrix[0].length==0)return false;
... | 2,212 |
310 | /*******************************************************************************
* 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... | 1,259 |
623 | package com.netease.nim.uikit.business.ait;
/**
* Created by hzchenkang on 2017/7/10.
*/
public interface AitTextChangeListener {
void onTextAdd(String content, int start, int length);
void onTextDelete(int start, int length);
}
| 85 |
1,031 | <reponame>kyletanyag/LL-Smartcard
import director_binary_string.*;
public class director_binary_string_runme {
static {
try {
System.loadLibrary("director_binary_string");
} catch (UnsatisfiedLinkError e) {
System.err.println("Native code library failed to load. See the chapter on Dynamic Linki... | 622 |
911 | <gh_stars>100-1000
from django.apps import AppConfig
class BlogsAppConfig(AppConfig):
name = 'blogs'
| 38 |
551 | <reponame>sharklatan/tweakCompatible
{
"id": "com.hackyouriphone.copic20",
"name": "Copic 2",
"latest": "1.0.9-beta-5k",
"repository": "HackYouriPhone",
"url": "http://cydia.saurik.com/package/com.hackyouriphone.copic20/",
"shortDescription": "The new Copic 2 is totally redesigned, optimized and rebuild fro... | 711 |
19,920 | /*
* Copyright (C) 2017 The Android Open Source Project
*
* 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 app... | 3,431 |
406 | package org.broad.igv.ui.color;
import java.awt.*;
import java.util.HashMap;
import java.util.Map;
/**
* Created by jrobinson on 7/5/16.
*/
public class GreyscaleColorTable implements ColorTable {
Map<String, Color> colorMap;
int min;
int max;
public GreyscaleColorTable() {
this(50, 200);
... | 349 |
1,061 | <gh_stars>1000+
from .envs import available_envs_module
def available_envs():
available_envs = [env_module.__name__.split('.')[-1] for env_module in available_envs_module]
wip = ['realtime-v0']
return available_envs
def make(env_id, obs_data_len, step_len,
df, fee, deal_col_name='price',
... | 562 |
460 | <reponame>zzzgoda/FakeXposed
/*
* Copyright (c) 2021 FakeXposed by sanfengAndroid.
*
* 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
... | 655 |
340 | /**
@author <NAME> visit <www.igushev.com> e-mail <<EMAIL>>
@brief Stability test pack for fixed deque
Warranty and license
The implementation is provided “as it is” with no warranty.
Any private and commercial usage is allowed.
Keeping the original name and link to the source is required.
... | 1,382 |
561 | <filename>tasks/tts/fs2_orig.py<gh_stars>100-1000
import torch
import torch.nn.functional as F
from modules.tts.fs2_orig import FastSpeech2Orig
from tasks.tts.dataset_utils import FastSpeechDataset
from tasks.tts.fs import FastSpeechTask
from utils.commons.dataset_utils import collate_1d, collate_2d
from utils.commons.... | 3,236 |
2,220 | <gh_stars>1000+
from unittest.mock import Mock
import pandas as pd
import pytest
import pytz
from qstrader.portcon.order_sizer.long_short import (
LongShortLeveragedOrderSizer
)
@pytest.mark.parametrize(
"gross_leverage,expected",
[
(-1.0, None),
(0.0, None),
(0.01, 0.01),
... | 3,363 |
810 | <filename>spring-cloud-openfeign-core/src/test/java/org/springframework/cloud/openfeign/FeignClientConfigurationTests.java
/*
* Copyright 2021-2021 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
... | 1,978 |
1,338 | /*
* Copyright 2010, <NAME>, <EMAIL>.
* Copyright 2005-2009, <NAME>, <EMAIL>.
* Distributed under the terms of the MIT License.
*
* Copyright 2001-2002, <NAME>. All rights reserved.
* Distributed under the terms of the NewOS License.
*/
#ifndef _KERNEL_ARCH_M68K_PAGING_040_PAGING_H
#define _KERNEL_ARCH_M68K_PAGI... | 1,933 |
487 | <reponame>srivani/p4c<gh_stars>100-1000
#ifndef FRONTENDS_V1LEXER_H_
#define FRONTENDS_V1LEXER_H_
// FlexLexer.h requires you to provide an external #include guard so that it can
// be included multiple times, each time providing a different definition for
// yyFlexLexer, to define multiple lexer base classes.
#ifndef... | 538 |
3,102 | <gh_stars>1000+
// REQUIRES: systemz-registered-target
// RUN: %clang_cc1 -target-cpu z15 -triple s390x-ibm-linux -flax-vector-conversions=none \
// RUN: -Wall -Wno-unused -Werror -emit-llvm %s -o - | FileCheck %s
typedef __attribute__((vector_size(16))) signed char vec_schar;
typedef __attribute__((vector_size(16))) ... | 1,275 |
488 | /*
* Copyright (C) 2007 The Android Open Source Project
*
* 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 app... | 539 |
1,444 | <reponame>J-VOL/mage
package mage.sets;
import mage.cards.ExpansionSet;
import mage.collation.BoosterCollator;
import mage.collation.BoosterStructure;
import mage.collation.CardRun;
import mage.collation.RarityConfiguration;
import mage.constants.Rarity;
import mage.constants.SetType;
import java.util.ArrayList;
impo... | 16,684 |
3,924 | <gh_stars>1000+
/*
Copyright 2016 Amazon.com, Inc. or its affiliates. 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. A copy of the License is located at
http://aws.amazon.com/apache2.0/
or in the "li... | 26,100 |
366 | /**
* Copyright 2019 Airbnb. Licensed under Apache-2.0. See License in the project root for license
* information.
*/
package com.airbnb.spinaltap.mysql.schema;
import com.airbnb.spinaltap.mysql.MysqlSourceMetrics;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;
import java.util.... | 2,004 |
348 | {"nom":"Bellegarde-sur-Valserine","circ":"3ème circonscription","dpt":"Ain","inscrits":6066,"abs":4161,"votants":1905,"blancs":140,"nuls":69,"exp":1696,"res":[{"nuance":"REM","nom":"Mme <NAME>","voix":992},{"nuance":"LR","nom":"Mme <NAME>","voix":704}]} | 103 |
325 | // Generated by Apple Swift version 3.1 (swiftlang-802.0.53 clang-802.0.42)
#pragma clang diagnostic push
#if defined(__has_include) && __has_include(<swift/objc-prologue.h>)
# include <swift/objc-prologue.h>
#endif
#pragma clang diagnostic ignored "-Wauto-import"
#include <objc/NSObject.h>
#include <stdint.h>
#inclu... | 3,792 |
1,863 | <gh_stars>1000+
/*
* wrbmp.c
*
* Copyright (C) 1994-1996, <NAME>.
* This file is part of the Independent JPEG Group's software.
* For conditions of distribution and use, see the accompanying README file.
*
* This file contains routines to write output images in Microsoft "BMP"
* format (MS Windows 3.x and OS/2 ... | 5,512 |
4,013 | <reponame>antonblr/checkov<filename>tests/terraform/checks/resource/aws/test_RedshiftClusterEncryption.py
import unittest
from checkov.terraform.checks.resource.aws.RedshiftClusterEncryption import check
from checkov.common.models.enums import CheckResult
class TestRedshiftClusterEncryption(unittest.TestCase):
... | 584 |
790 | <reponame>MiCHiLU/google_appengine_sdk
"""
"""
from django.contrib.auth import models
import pyamf.adapters
models.User.__amf__ = {
'exclude': ('message_set', 'password'),
'readonly': ('username',)
}
# ensure that the adapter that we depend on is loaded ..
pyamf.adapters.get_adapter('django.db.models.base'... | 138 |
519 | // BSD 3-Clause License; see https://github.com/scikit-hep/awkward-1.0/blob/main/LICENSE
#define FILENAME(line) FILENAME_FOR_EXCEPTIONS_C("src/cpu-kernels/awkward_Identities_from_IndexedArray.cpp", line)
#include "awkward/kernels.h"
template <typename ID, typename T>
ERROR awkward_Identities_from_IndexedArray(
boo... | 1,485 |
546 | #include "MsnhViewerNodeCreator.h"
#include <QDebug>
namespace MsnhViewer
{
NodeCreator& NodeCreator::instance()
{
static NodeCreator creator_;
return creator_;
}
void NodeCreator::addItem(QString const& type, QVector<AttributeInfo> const& attributes)
{
QHash<... | 544 |
310 | // Copyright 2016-2018 The RamFuzz contributors. 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 req... | 486 |
375 | /*
* Copyright 2016 Nokia Solutions and Networks
* Licensed under the Apache License, Version 2.0,
* see license.txt file for details.
*/
package org.robotframework.ide.eclipse.main.plugin.tableeditor.source.assist;
import static com.google.common.collect.Lists.newArrayList;
import static org.assertj.core.api.Asse... | 6,685 |
4,901 | <gh_stars>1000+
/*
* 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
... | 1,093 |
3,861 | /* $Id: fsw_core.h 33540 2010-10-28 09:27:05Z vboxsync $ */
/** @file
* fsw_core.h - Core file system wrapper abstraction layer header.
*/
/*
* Copyright (C) 2010-2012 Oracle Corporation
*
* This file is part of VirtualBox Open Source Edition (OSE), as
* available from http://www.virtualbox.org. This fi... | 10,525 |
1,362 | {
"weightUnitErrorRate": 0.0014,
"weightTransposeErrorRate": 0.001,
"weightSwitchErrorRate": 0.0004,
"weightExtremeErrorRate": 0.0014,
"weightDuplicateErrorRate": 0.1385,
"weightCarriedForwardErrorRate": 0.1324,
"heightUnitErrorRate": 0.0007,
"heightTransposeErrorRate": 0.001,
"heightSwitchErrorRate":... | 180 |
511 | <reponame>SenthilKumarGS/TizenRT
/* Copyright 2017-present Samsung Electronics Co., Ltd. and other contributors
*
* 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... | 13,946 |
337 | <gh_stars>100-1000
/*
Syphon.h
Syphon
Copyright 2010-2011 bangnoise (<NAME>) & vade (<NAME>).
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 cod... | 2,673 |
2,321 | package life.majiang.community.strategy;
import lombok.Data;
@Data
public class LoginUserInfo {
private String name;
private Long id;
private String bio;
private String avatarUrl;
}
| 68 |
892 | {
"schema_version": "1.2.0",
"id": "GHSA-4wf3-x44x-f4f7",
"modified": "2022-04-20T00:00:19Z",
"published": "2022-04-20T00:00:19Z",
"aliases": [
"CVE-2022-21491"
],
"details": "Vulnerability in the Oracle VM VirtualBox product of Oracle Virtualization (component: Core). The supported version that is af... | 528 |
2,206 | /* ******************************************************************************
*
*
* This program and the accompanying materials are made available under the
* terms of the Apache License, Version 2.0 which is available at
* https://www.apache.org/licenses/LICENSE-2.0.
*
* See the NOTICE file distributed wit... | 1,980 |
335 | <filename>H/Heavenly_adjective.json
{
"word": "Heavenly",
"definitions": [
"Of heaven; divine.",
"Of the heavens or sky.",
"Very pleasing; wonderful."
],
"parts-of-speech": "Adjective"
} | 103 |
6,541 | /*
* Copyright 2016 The Emscripten Authors. All rights reserved.
* Emscripten is available under two separate licenses, the MIT license and the
* University of Illinois/NCSA Open Source License. Both these licenses can be
* found in the LICENSE file.
*/
#include <string>
#include <sstream>
#include <iostream>
... | 155 |
2,757 | /**
**/
/**
Copyright (c) 2013 - 2014, Intel Corporation. All rights reserved
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
The full text of the license may be found at
http://opensour... | 10,515 |
348 | #ifndef SYMBOL_ENVIRONMENT_H
#define SYMBOL_ENVIRONMENT_H
#include <string>
#include <vector>
//#include <ext/hash_map>
#include <map>
#include <FPG/Symbol.h>
namespace AST {
struct FunctionDefinition;
struct Node;
}
struct Collect_variables;
struct SymbolEnvironment {
SymbolEnvironment();
// corresp... | 718 |
777 | // Copyright 2016 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.
#ifndef NET_NQE_SOCKET_WATCHER_H_
#define NET_NQE_SOCKET_WATCHER_H_
#include "base/callback.h"
#include "base/memory/ref_counted.h"
#include "base/memory... | 711 |
353 | <reponame>MiheevN/USharp
CSEXPORT void* CSCONV Export_FScriptArray_GetData(FScriptArray* instance)
{
return instance->GetData();
}
CSEXPORT csbool CSCONV Export_FScriptArray_IsValidIndex(FScriptArray* instance, int32 i)
{
return instance->IsValidIndex(i);
}
CSEXPORT int32 CSCONV Export_FScriptArray_Num(FScriptArray... | 999 |
312 | <filename>src/math/mTransform.cc
//-----------------------------------------------------------------------------
// Copyright (c) 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 Soft... | 958 |
357 | <gh_stars>100-1000
/**
* OEML - REST API
* This section will provide necessary information about the `CoinAPI OEML REST API` protocol. <br/> This API is also available in the Postman application: <a href=\"https://postman.coinapi.io/\" target=\"_blank\">https://postman.coinapi.io/</a> <br/><br/> Implemented Sta... | 1,771 |
320 | <filename>jme3-blender/src/com/jme3/gde/blender/package-info.java
@TemplateRegistrations({
@TemplateRegistration(folder = "Blender", content = "tpl_box.blend", displayName = "Box prepared for UV texturing"),
@TemplateRegistration(folder = "Blender", content = "tpl_anim.blend", displayName = "Basic animation exa... | 155 |
480 | /*
* Copyright [2013-2021], Alibaba Group Holding Limited
*
* 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 app... | 7,993 |
643 | <reponame>boaz001/pipes<filename>tests/partition.cpp
#include "catch.hpp"
#include "pipes/override.hpp"
#include "pipes/partition.hpp"
#include "pipes/push_back.hpp"
TEST_CASE("partition")
{
std::vector<int> input = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
std::vector<int> expectedEvens = {2, 4, 6, 8, 10};
st... | 1,460 |
1,085 | /*
* Copyright (C) 2017-2019 Dremio 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 applicable l... | 1,248 |
428 | /*
* Copyright 2012 SURFnet bv, The Netherlands
*
* 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 ... | 2,422 |
388 | /* Copyright 2017 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... | 2,017 |
1,592 | #A part of NonVisual Desktop Access (NVDA)
#This file is covered by the GNU General Public License.
#See the file COPYING for more details.
#Copyright (C) 2011 <NAME> <<EMAIL>>
# Parts of this code are inherited from the baum braille driver
# written by <NAME> <<EMAIL>>
# This file represents the braille disp... | 2,575 |
6,620 | import unittest
from contextlib import contextmanager
from numba import njit
from numba.core import errors, cpu, utils, typing
from numba.core.descriptors import TargetDescriptor
from numba.core.dispatcher import TargetConfigurationStack
from numba.core.retarget import BasicRetarget
from numba.core.extending import ov... | 3,582 |
713 | package org.infinispan.xsite.offline;
import java.util.Collection;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.TimeoutException;
import org.infinispan.remoting.transport.AbstractDelegatingTransport;
import org.infinispan.remoting.transport.BackupResponse;
import org.infinispan.remoting.... | 737 |
466 | <reponame>1071931588/Zhumulangma<filename>module_listen/src/main/java/com/gykj/zhumulangma/listen/activity/HistoryActivity.java
package com.gykj.zhumulangma.listen.activity;
import android.app.AlertDialog;
import android.view.View;
import androidx.annotation.NonNull;
import androidx.lifecycle.ViewModelProvider;
impor... | 1,856 |
3,010 |
#define COLOR(r, g, b) (((r) << 16) | ((g) << 8) | (b))
// For brightness == 255 (full). This will be adjusted downward for various different RGB indicators,
// which vary in brightness.
#define INTENSITY (0x30)
#define BLACK COLOR(0, 0, 0)
#define GREEN COLOR(0, INTENSITY, 0)
#define BLUE COLOR(0, 0, INTENSIT... | 364 |
6,036 | <reponame>sstamenova/onnxruntime
# -------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
# --------------------------------------------------------------------------
import os
import sys
import torch
from ... | 1,681 |
10,608 | <reponame>WojciechKusa/datasets<gh_stars>1000+
# coding=utf-8
# Copyright 2020 The TensorFlow Datasets Authors and the HuggingFace Datasets 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 Licen... | 2,262 |
1,026 | from .common import assert_subpackage; assert_subpackage(__name__)
from contextlib import contextmanager
from pathlib import Path
from typing import Optional
def disable_cachew() -> None:
try:
import cachew
except ImportError:
# nothing to disable
return
from cachew import setting... | 685 |
713 | <filename>algoexpert.io/python/Numbers_In_Pi.py
# O(n^3) time | O(n + m) space
def numbersInPi(pi, numbers):
numbersTable = {number: True for number in numbers}
minSpaces = getMinSpaces(pi, numbersTable, {}, 0)
return -1 if minSpaces == float('inf') else minSpaces
def getMinSpaces(pi, numbersTable, cac... | 326 |
2,659 | /*
* Copyright 2021 4Paradigm
*
* 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 w... | 1,193 |
921 | <filename>src/sqlancer/postgres/gen/PostgresNotifyGenerator.java<gh_stars>100-1000
package sqlancer.postgres.gen;
import sqlancer.Randomly;
import sqlancer.common.query.SQLQueryAdapter;
import sqlancer.postgres.PostgresGlobalState;
public final class PostgresNotifyGenerator {
private PostgresNotifyGenerator() {
... | 599 |
435 | <gh_stars>100-1000
{
"alias": "video/3679/how-i-built-a-power-debugger-out-of-the-standard",
"category": "PyOhio 2015",
"copyright_text": "CC BY",
"description": "Smiley spys on your application, recording everything it does, using\nPython's built-in tracing facility and a database to create a complete\nrecord ... | 406 |
412 | # -*- coding: utf-8 -*-
#
# Copyright (C) 2019 Max-Planck-Gesellschaft zur Förderung der Wissenschaften e.V. (MPG),
# acting on behalf of its Max Planck Institute for Intelligent Systems and the
# Max Planck Institute for Biological Cybernetics. All rights reserved.
#
# Max-Planck-Gesellschaft zur Förderung der Wissens... | 1,840 |
5,964 | <reponame>wenfeifei/miniblink49
// Copyright 2014 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.
#ifndef InspectorCacheStorageAgent_h
#define InspectorCacheStorageAgent_h
#include "core/InspectorFrontend.h"
#include "c... | 497 |
3,246 | /*
* Copyright 2019 The Data Transfer Project 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
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicab... | 620 |
5,238 | class LV_ExampleAnimTimeline_1(object):
def __init__(self):
self.obj_width = 120
self.obj_height = 150
#
# Create an animation timeline
#
self.par = lv.scr_act()
self.par.set_flex_flow(lv.FLEX_FLOW.ROW)
self.par.set_flex_align(lv.FLEX_ALIGN.SPACE_ARO... | 2,821 |
1,379 | /*
* Copyright 2013 LinkedIn, Inc
*
* 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... | 3,906 |
1,826 | <filename>flexmark-ext-gfm-users/src/main/java/com/vladsch/flexmark/ext/gfm/users/package-info.java<gh_stars>1000+
package com.vladsch.flexmark.ext.gfm.users;
| 66 |
661 | <gh_stars>100-1000
/*
Bullet Continuous Collision Detection and Physics Library
Copyright (c) 2003-2013 <NAME> http://bulletphysics.org
This software is provided 'as-is', without any express or implied warranty.
In no event will the authors be held liable for any damages arising from the use of this software.
Permiss... | 6,341 |
1,194 | <filename>hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/term/loinc/LoincPartLinkHandler.java<gh_stars>1000+
package ca.uhn.fhir.jpa.term.loinc;
/*-
* #%L
* HAPI FHIR JPA Server
* %%
* Copyright (C) 2014 - 2022 Smile CDR, Inc.
* %%
* Licensed under the Apache License, Version 2.0 (the "License");
* you ... | 1,294 |
5,166 | # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
# SPDX-License-Identifier: Apache-2.0
"""
Stub functions that are used by the AWS STS unit tests.
When tests are run against an actual AWS account, the stubber class does not
set up stubs and passes all calls through to the Boto 3 client.
"""
impor... | 1,460 |
1,467 | <filename>http-clients/netty-nio-client/src/main/java/software/amazon/awssdk/http/nio/netty/internal/http2/HttpToHttp2OutboundAdapter.java
/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in... | 4,107 |
1,127 | // Copyright (C) 2021 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//
#include <gtest/gtest.h>
#include <utils/jit_kernel.hpp>
#include <random>
using namespace ov::intel_cpu;
using namespace dnnl::impl::cpu::x64;
using namespace Xbyak;
namespace {
#define TEST_JIT_SCALAR_EXPRESSION (c << 5) * b | (a & ... | 4,295 |
1,007 | # -*- coding: utf-8 -*-
# daemon/version/__init__.py
# Part of python-daemon, an implementation of PEP 3143.
#
# Copyright © 2008–2010 <NAME> <<EMAIL>>
# This is free software: you may copy, modify, and/or distribute this work
# under the terms of the Python Software Foundation License, version 2 or
# later as publish... | 402 |
7,629 | # Copyright 2020 Google Inc.
#
# 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,... | 1,285 |
777 | <reponame>google-ar/chromium<filename>net/quic/test_tools/delayed_verify_strike_register_client.cc
// 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.
#include "net/quic/test_tools/delayed_verify_strike_reg... | 798 |
386 | /*********************************************************************************
* *
* The MIT License (MIT) *
* ... | 2,512 |
14,668 | <reponame>zealoussnow/chromium
// Copyright 2020 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.
#ifndef CHROMEOS_COMPONENTS_CHROMEBOX_FOR_MEETINGS_FEATURES_FEATURES_H_
#define CHROMEOS_COMPONENTS_CHROMEBOX_FOR_MEETINGS_... | 376 |
1,652 | <reponame>minluzhou/test1<filename>redis/redis-core/src/test/java/com/ctrip/xpipe/redis/core/meta/impl/InverseHostPortMapBuilderTest.java
package com.ctrip.xpipe.redis.core.meta.impl;
import com.ctrip.xpipe.redis.core.AbstractRedisTest;
import org.junit.Test;
/**
* @author wenchao.meng
* <p>
* Dec ... | 266 |
348 | <filename>docs/data/leg-t2/080/08004060.json<gh_stars>100-1000
{"nom":"Béalcourt","circ":"4ème circonscription","dpt":"Somme","inscrits":77,"abs":40,"votants":37,"blancs":3,"nuls":1,"exp":33,"res":[{"nuance":"FN","nom":"<NAME>","voix":17},{"nuance":"REM","nom":"<NAME>","voix":16}]} | 119 |
1,350 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.apimanagement.models;
import com.azure.resourcemanager.apimanagement.fluent.models.ReportRecordContractInner;
import java.time.O... | 1,956 |
348 | <reponame>chamberone/Leaflet.PixiOverlay
{"nom":"Mont-sur-Monnet","circ":"2ème circonscription","dpt":"Jura","inscrits":170,"abs":72,"votants":98,"blancs":7,"nuls":1,"exp":90,"res":[{"nuance":"LR","nom":"<NAME>","voix":56},{"nuance":"MDM","nom":"Mme <NAME>","voix":34}]} | 113 |
5,079 | #! /usr/bin/env python
# $Id: test_test_directives.py 4564 2006-05-21 20:44:42Z wiemann $
# Author: <NAME> <<EMAIL>>
# Copyright: This module has been placed in the public domain.
"""
Tests for misc.py test directives.
"""
from __init__ import DocutilsTestSupport
def suite():
s = DocutilsTestSupport.ParserTestS... | 2,171 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.