max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
3,600 | <reponame>duxinyu03/moco
package com.github.dreamhead.moco.rest;
import com.github.dreamhead.moco.Moco;
import com.github.dreamhead.moco.RequestMatcher;
import com.github.dreamhead.moco.RestIdMatcher;
import static com.github.dreamhead.moco.Moco.uri;
import static com.github.dreamhead.moco.util.Preconditions.checkNot... | 622 |
3,274 | <reponame>tyang513/QLExpress
package com.ql.util.express.instruction.op;
import com.ql.util.express.ArraySwap;
import com.ql.util.express.InstructionSetContext;
import com.ql.util.express.OperateData;
import com.ql.util.express.instruction.OperateDataCacheManager;
import com.ql.util.express.instruction.opdata.OperateD... | 410 |
4,036 | package bsh;
public class EvalError extends Exception {
}
| 21 |
1,602 | <reponame>jhh67/chapel<filename>test/trivial/shannon/gentest/compTest.c<gh_stars>1000+
#include <stdio.h>
main() {
int m = 2;
int n = 3;
int o = 5;
int answer = 0;
printf("* and * permutations\n");
printf("=========================\n");
answer = m * n * o;
printf("%d\n", answer);
answer = (m * n) *... | 24,035 |
442 | <reponame>danqiusheng/spring-framework-5.1.x<filename>spring-websocket/src/main/java/org/springframework/web/socket/client/standard/StandardWebSocketClient.java
/*
* Copyright 2002-2018 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file ex... | 2,228 |
1,350 | <reponame>Manny27nyc/azure-sdk-for-java<filename>sdk/security/azure-resourcemanager-security/src/main/java/com/azure/resourcemanager/security/fluent/models/SecurityTaskInner.java
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest C... | 1,373 |
390 | /*!
@file WinAsm.h
@brief Windows specific MASM-written functions.
@author <NAME>
@copyright Copyright (c) 2020 - , <NAME>. All rights reserved.
*/
#pragma once
#include "WinCommon.h"
/*!
@brief Reads the value of LDTR.
@return The value of LDTR.
*/
UINT16
AsmReadLdtr (
);
/*!
@b... | 516 |
1,148 | """ERC-20 compatibility."""
from web3.contract import Contract
def test_erc20_interface(token: Contract, token_owner: str, empty_address: str):
"""Token satisfies ERC-20 interface."""
# https://github.com/OpenZeppelin/zeppelin-solidity/blob/master/contracts/token/ERC20.sol
assert token.functions.balanc... | 244 |
3,442 | <reponame>wcicola/jitsi
/*
* Jitsi, the OpenSource Java VoIP and Instant Messaging client.
*
* Copyright @ 2015 Atlassian Pty 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
*
* ... | 1,107 |
785 | /*
* Copyright 2016-2021 Pnoker. 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 ... | 1,023 |
1,338 | <filename>src/apps/haikudepot/server/LocalRepositoryUpdateProcess.h
/*
* Copyright 2018-2020, <NAME> <<EMAIL>>.
* All rights reserved. Distributed under the terms of the MIT License.
*/
#ifndef LOCAL_REPOSITORY_UPDATE_PROCESS__H
#define LOCAL_REPOSITORY_UPDATE_PROCESS__H
#include "AbstractProcess.h"
#include <F... | 665 |
12,278 | <reponame>rajeev02101987/arangodb
// Copyright <NAME> 2017.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#include <boost/parameter/config.hpp>
#if (BOOST_PARAMETER_MAX_ARITY < 10)
#error Define BOOST_PARAMET... | 3,362 |
32,544 | <reponame>DBatOWL/tutorials
package com.baeldung.validations.functional.model;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
@AllArgsConstructor
@NoArgsConstructor
@... | 181 |
809 | /**
* @file
*
* @brief
*
* @date 03.07.2012
* @author <NAME>
*/
#ifndef FRAMEWORK_MOD_OPTIONS_H_
#define FRAMEWORK_MOD_OPTIONS_H_
#include <util/macro.h>
#define __OPTION_MODULE_GET(mod,type,name) \
OPTION_##type##_##mod##__##name
#define OPTION_MODULE_GET(mod,type,name) \
__OPTION_MODULE_GET(mod,type,nam... | 422 |
12,706 | from __future__ import absolute_import
import sys
import unittest
from testutils import ADMIN_CLIENT, suppress_urllib3_warning
from testutils import harbor_server
from testutils import TEARDOWN
import library.repository
import library.cnab
from library.project import Project
from library.user import User
from library... | 3,561 |
17,104 | /*
* Tencent is pleased to support the open source community by making Mars available.
* Copyright (C) 2016 THL A29 Limited, a Tencent company. All rights reserved.
*
* Licensed under the MIT License (the "License"); you may not use this file except in
* compliance with the License. You may obtain a copy of the Licens... | 1,764 |
617 | <reponame>RamboWu/pokerstove<gh_stars>100-1000
#include "PokerHandEvaluator.h"
#include <gtest/gtest.h>
TEST(PokerHandEvaluator, OmahaHigh)
{
using namespace pokerstove;
boost::shared_ptr<PokerHandEvaluator> evaluator = PokerHandEvaluator::alloc("O");
EXPECT_EQ(true, evaluator->usesSuits());
EXPECT_EQ... | 151 |
1,144 | /*
* Copyright 2006,2007 <NAME>, <NAME> This file is part of
* CheckboxTree. CheckboxTree 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 License, or (at your
* option) any later v... | 1,491 |
5,169 | {
"name": "SideMenuDrawer",
"version": "1.0.0",
"summary": "This framework is used to create slidemenu.",
"description": "This framework is used to create slidemenu as in android",
"homepage": "https://github.com/sawanmind/SideMenuDrawer",
"license": "MIT",
"authors": {
"<NAME>": "<EMAIL>"
},
"soc... | 262 |
339 | <reponame>ljw23/ConvLab-2
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
"""
import multiprocessing as mp
import threading as th
class LockBase(object):
def __init__(self):
self.locks = []
def enter(self):
for lock in self.locks:
lock.acquire()
def leave(self):
... | 2,702 |
777 | <reponame>google-ar/chromium
// 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.
#include "content/browser/android/java_interfaces_impl.h"
#include <jni.h>
#include <utility>
#include "base/android/conte... | 643 |
407 | package com.alibaba.tesla.gateway.common.utils;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* @author <EMAIL>
*/
public class ServerNameCheckUtilTest {
@Test
public void check() {
String url = "lb://fass.test.1233%alibaba/test_test";
ServerNameCheckUtil.check(url);
}
... | 132 |
435 | <reponame>amaajemyfren/data<filename>pydata-berlin-2017/videos/tal-perry-a-word-is-worth-a-thousand-pictures-convolutional-methods-for-text.json
{
"copyright_text": "Standard YouTube License",
"description": "Link to slides: https://www.slideshare.net/secret/2a5Xz9Sgc3D5GU\n\nDescription\nThose folks in computer vi... | 779 |
671 | <gh_stars>100-1000
typedef NS_ENUM(NSInteger, NYAlertViewControllerTransitionStyle) {
/** Fade in the alert view */
NYAlertViewControllerTransitionStyleFade,
/** Slide the alert view from the top of the view */
NYAlertViewControllerTransitionStyleSlideFromTop,
/** Slide the alert view from the botto... | 121 |
839 | /**
* 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 m... | 4,000 |
496 | import os
import anglepy.data
import h5py
path = os.environ['ML_DATA_PATH']+'/mnist_binarized/'
# MNIST binarized dataset from <NAME>
def load_numpy(size=28):
train_x = h5py.File(path+"binarized_mnist-train.h5")['data'][:].T
valid_x = h5py.File(path+"binarized_mnist-valid.h5")['data'][:].T
test_x = h5py.F... | 187 |
1,068 | <gh_stars>1000+
package com.github.jknack.handlebars.cache;
import static org.junit.Assert.assertEquals;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
import java.io.IOException;
import org.junit.Test;
import com.github.jknack.handlebars.Pa... | 358 |
2,179 | /*
* 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 ... | 682 |
342 | {
"__class__": "<class 'rl_agents.agents.control.linear_feedback.LinearFeedbackAgent'>",
"K": [[1e-1, 2, 0, 1]]
} | 54 |
634 | /*
* Copyright 2000-2017 JetBrains s.r.o.
*
* 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 agre... | 407 |
575 | // Copyright 2019 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 CHROME_BROWSER_MEDIA_HISTORY_MEDIA_HISTORY_ORIGIN_TABLE_H_
#define CHROME_BROWSER_MEDIA_HISTORY_MEDIA_HISTORY_ORIGIN_TABLE_H_
#include <string>
... | 641 |
648 | {"resourceType":"DataElement","id":"Condition.category","meta":{"lastUpdated":"2017-04-19T07:44:43.294+10:00"},"url":"http://hl7.org/fhir/DataElement/Condition.category","status":"draft","experimental":true,"stringency":"fully-specified","element":[{"id":"Condition.category","path":"Condition.category","short":"problem... | 297 |
665 | <filename>core/internaltestsupport/src/main/java/org/apache/isis/core/internaltestsupport/jmocking/JMockActions.java
/*
* 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 ... | 966 |
5,169 | {
"name": "CameraResolutionHelper",
"platforms": {
"ios": "8.0"
},
"authors": "<NAME>",
"version": "1.0",
"requires_arc": true,
"summary": "CameraResolutionHelper allows you to obtain resolutions of different cameras while maintaining the aspect ratio.",
"homepage": "https://github.com/adrianAlvarez... | 282 |
321 | /**
* Most of the code in the Qalingo project is copyrighted Hoteia and licensed
* under the Apache License Version 2.0 (release version 0.8.0)
* http://www.apache.org/licenses/LICENSE-2.0
*
* Copyright (c) Hoteia, 2012-2014
* http://www.hoteia.com - http://twitter.com/hoteia - <EMAIL>
... | 698 |
6,992 | package sample;
import static org.junit.Assert.*;
import org.junit.Test;
public class TheClassTest {
TheClass theClass = new TheClass();
@Test
public void doStuffWhenTrueThenTrue() {
assertTrue(theClass.doStuff(true));
}
@Test
public void doStuffWhenTrueThenFalse() {
assertFalse(theClass.doStuff(false));... | 117 |
652 | """Controller class.
Represents a Gamepad or Joystick controller.
"""
# Copyright (c) Jupyter Development Team.
# Distributed under the terms of the Modified BSD License.
from .widget import Widget, register, widget_serialization
from traitlets import Bool, Int, Float, Unicode, List, Instance
@register('IPython.Co... | 558 |
945 | <filename>Wrapping/Generators/Java/Tests/notYetUsable/VoronoiSegmentation.java
/*=========================================================================
*
* Copyright NumFOCUS
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.... | 646 |
3,799 | <filename>car/app/app/src/main/java/androidx/car/app/connection/CarConnectionTypeLiveData.java
/*
* 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 Li... | 1,712 |
504 | #include <localize.h>
#include "codepage.h"
#define DEFAULT_CODEPAGE CP_WESTEUROPE
#define SHUTDOWN_CODEPAGE CP_NIL
wchar RTFCodePageToGeos(wchar ch);
wchar RTFGeosToCodePage(wchar ch);
void RTFSetCodePage(DosCodePage nCP);
| 100 |
585 | import os
import pytest
import shutil
from nipype.interfaces.dcm2nii import Dcm2niix
no_dcm2niix = not bool(Dcm2niix().version)
no_datalad = False
try:
from datalad import api # to pull and grab data
from datalad.support.exceptions import IncompleteResultsError
except ImportError:
no_datalad = True
DICO... | 852 |
403 | /*
* Camunda Platform REST API
* OpenApi Spec for Camunda Platform REST API.
*
* The version of the OpenAPI document: 7.16.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
package com.camu... | 3,486 |
1,844 | /*
* Copyright 2010-2013 Ning, Inc.
* Copyright 2014-2018 Groupon, Inc
* Copyright 2014-2018 The Billing Project, LLC
*
* The Billing Project licenses this file to you 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 cop... | 3,853 |
369 | <filename>cdap-app-fabric/src/main/java/io/cdap/cdap/internal/pipeline/StageContext.java
/*
* Copyright © 2014 <NAME>, 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://w... | 821 |
420 | <reponame>duclmdev/TachiyomiServer
/*
* Copyright (C) 2015 Square, 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... | 1,187 |
7,158 | // This file is part of OpenCV project.
// It is subject to the license terms in the LICENSE file found in the top-level directory
// of this distribution and at http://opencv.org/license.html.
#ifndef _OPENCV_OR_VECTOR_HPP_
#define _OPENCV_OR_VECTOR_HPP_
#ifdef __CUDACC__
#define __CV_CUDA_HOST_DEVICE__ __host__ __d... | 1,072 |
1,511 | {
"name": "alfandega",
"epoch": null,
"version": "2.0",
"release": "1.7.3",
"arch": "noarch",
"os": "linux",
"summary": "A perl modules for iptables firewall control.",
"description": null,
"distribution": null,
"vendor": null,
"license": "GPL",
"packager": "<NAME> <<EMAI... | 230 |
328 | package com.dragon.flow.service.flowable;
import com.dragon.flow.model.org.Personal;
import com.dragon.flow.vo.flowable.processinstance.InstanceQueryParamsVo;
import com.dragon.flow.vo.flowable.processinstance.ProcessInstanceVo;
import com.dragon.flow.vo.flowable.runtime.StartProcessInstanceVo;
import com.dragon.flow.... | 593 |
312 | <gh_stars>100-1000
/*******************************************************************************
* Copyright (c) 2015 Eclipse RDF4J contributors, Aduna, and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Distribution License v1.0
* w... | 413 |
1,821 | <reponame>hangqiu/pixie
/*
* Copyright 2018- The Pixie 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... | 1,324 |
1,900 | /*
* Copyright Terracotta, 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 ... | 1,516 |
4,047 | #include<lua.h>
#include<stdio.h>
#include<stdlib.h>
#include<png.h>
#include<string.h>
#if !defined(_MSC_VER)
#include<unistd.h>
#endif
static void *l_alloc (void *ud, void *ptr, size_t osize,
size_t nsize) {
(void)ud;
(void)osize;
if (nsize == 0) {
free(ptr);
return NULL;
} el... | 738 |
1,100 | <filename>Exercise_18/Exercise_18_21/Exercise_18_21.java
/*********************************************************************************
* (Decimal to binary) Write a recursive method that converts a decimal number *
* into a binary number as a string. The method header is: *
* ... | 679 |
3,710 | <reponame>rozhuk-im/opentoonz<filename>toonz/sources/toonz/scanpopup.h
#pragma once
#ifndef SCANPOPUP_H
#define SCANPOPUP_H
#include "toonzqt/dvdialog.h"
#include "tscanner.h"
#include "scanlist.h"
// forward declaration
namespace DVGui {
class DoubleField;
class IntField;
class CheckBox;
}
class QComboBox;
class P... | 907 |
1,405 | package com.lenovo.lps.reaper.sdk.request;
import com.lenovo.lps.reaper.sdk.api.DispatchCallback;
import com.lenovo.lps.reaper.sdk.util.TLog;
public final class WorkerTask implements Runnable {
private static final String a = WorkerTask.class.getName();
private final DispatchCallback b;
public WorkerTask... | 239 |
422 | from all_models.models import TbSource
class SourceService(object):
@staticmethod
def updateSource(sourceData):
tbModel = TbSource.objects.filter(id=sourceData["id"])
tbModel.update(**sourceData)
| 83 |
488 | <filename>CTCWordBeamSearch-master/cpp/test.hpp
#pragma once
// test the classes and functions of this project
void test(); | 39 |
544 | /*
* 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 ... | 544 |
435 | <filename>pycon-thailand-2018/videos/studying-thai-with-programming.json
{
"copyright_text": "Creative Commons Attribution license (reuse allowed)",
"description": "I'm an educator with a background in computer science. I've worked as a firmware engineer at a large corporation and as a software developer at a small... | 355 |
741 | import dkim
def bs64encode(value):
import base64
return b"=?utf-8?B?"+ base64.b64encode(value) + b"?="
def quoted_printable(value):
import quopri
return b"=?utf-8?Q?"+ quopri.encodestring(value) + b"?="
def id_generator(size=6):
import random
import string
chars=string.ascii_uppercase + string.digits
retur... | 682 |
2,030 | import json
import os
import threading
import unittest
from http.server import BaseHTTPRequestHandler, HTTPServer
from test.support import EnvironmentVarGuard
from urllib.parse import urlparse
from kaggle_web_client import (KaggleWebClient,
_KAGGLE_URL_BASE_ENV_VAR_NAME,
... | 3,444 |
591 | <gh_stars>100-1000
// Copyright(c) 2015-present, <NAME> & spdlog contributors.
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#pragma once
#ifdef _WIN32
#error tcp_client not supported under windows yet
#endif
// tcp client helper
#include <spdlog/common.h>
#include <spdlog/details/os.h>
... | 2,018 |
544 | //
// CountryViewItem.h
// TogglDesktop
//
// Created by <NAME> on 16/05/2018.
// Copyright © 2018 Alari. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface CountryViewItem : NSObject
@property (assign, nonatomic) uint64_t ID;
@property (assign, nonatomic) BOOL VatApplicable;
@property (copy, no... | 220 |
1,909 | <gh_stars>1000+
/*
* Copyright 2006-2017 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.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unle... | 1,877 |
1,444 | <filename>restclient-ui/src/main/java/org/wiztools/restclient/ui/AuthHelper.java
package org.wiztools.restclient.ui;
import java.util.List;
import org.wiztools.restclient.bean.HTTPAuthMethod;
/**
*
* @author subwiz
*/
public class AuthHelper {
public static final String NONE = "None";
public static final S... | 743 |
416 | //
// INPayBillIntent.h
// Intents
//
// Copyright (c) 2016-2017 Apple Inc. All rights reserved.
//
#import <Intents/INIntent.h>
#import <Intents/INIntentResolutionResult.h>
#import <Intents/INBillType.h>
@class INBillPayee;
@class INBillPayeeResolutionResult;
@class INBillTypeResolutionResult;
@class INDateCompo... | 1,931 |
543 | <reponame>CoenRijsdijk/Bytecoder<filename>classlib/java.desktop/src/main/resources/META-INF/modules/java.desktop/classes/javax/print/StreamPrintService.java
/*
* Copyright (c) 2000, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code... | 1,392 |
4,126 |
// ImageComposingCallback
// Declares the cImageComposingCallback class that implements a subset of cCallback for composing per-region images
#pragma once
#include "Callback.h"
/** Implements the plumbing for composing per-region images from multiple chunks.
To use this class, create a descendant that write... | 1,079 |
1,853 | #include <cstdio>
int main()
{
unsigned int a = 5;
unsigned int b = 4;
printf("a %% b: %d %% %d = %d\n", a, b, (a%b));
signed int c = -5;
signed int d = 4;
printf("c %% d: %d %% %d = %d\n", c, d, (c%d));
signed int e = 5;
signed int f = -4;
printf("e %% f: %d %% %d = %d\n", e, f, (e%f));
signed char g = -5;
un... | 274 |
1,375 | <filename>sw/device/lib/dif/autogen/dif_aon_timer_autogen.c
// Copyright lowRISC contributors.
// Licensed under the Apache License, Version 2.0, see LICENSE for details.
// SPDX-License-Identifier: Apache-2.0
// THIS FILE HAS BEEN GENERATED, DO NOT EDIT MANUALLY. COMMAND:
// util/make_new_dif.py --mode=regen --only=a... | 2,438 |
1,732 | #
# Execute watson on a session
#
import argparse
from lib import shellcode
__description__ = "Show missing KBs and suggest exploits for priv esc"
__author__ = "@Flangvik, @_RastaMouse"
__type__ = "enumeration"
# identify the task as shellcode execute
USERCD_EXEC_ID = 0x3000
# location of Watson binary
WATSON_BIN ... | 565 |
884 | <reponame>rt112000/CDM
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from cdm.objectmodel import CdmAttributeContext, CdmAttributeResolutionGuidanceDefin... | 422 |
9,541 | <filename>benchmark/top_tweet/rapidjson.h<gh_stars>1000+
#pragma once
#ifdef SIMDJSON_COMPETITION_RAPIDJSON
#include "top_tweet.h"
namespace top_tweet {
using namespace rapidjson;
struct rapidjson_base {
using StringType=std::string_view;
Document doc{};
bool run(Document &root, int64_t max_retweet_count, ... | 1,024 |
3,372 | <gh_stars>1000+
/*
* Copyright 2016-2021 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
*
* ... | 10,121 |
801 | import numpy as np
from sklearn import datasets
from sklearn.model_selection import StratifiedKFold
from neupy.algorithms import PNN
dataset = datasets.load_iris()
data, target = dataset.data, dataset.target
print("> Start classify iris dataset")
skfold = StratifiedKFold(n_splits=10)
for i, (train, test) in enumer... | 301 |
1,764 | <filename>test/data/70.py
class Foo:
class Bar:
def baz(self):
pass
| 49 |
1,992 | #include "test/cross_compile/lib/embed.h"
#include <stdlib.h>
int GetAnswer() {
return atoi(embed_start());
}
| 46 |
323 | {
"type": "deactivate",
"didSuffix": "<KEY>",
"revealValue": "EiB-dib5oumdaDGH47TB17Qg1nHza036bTIGibQOKFUY2A",
"signedData": "<KEY>"
}
| 75 |
506 | // https://codeforces.com/contest/1131/problem/F
#include<bits/stdc++.h>
using namespace std;
using vi = vector<int>;
using vvi = vector<vi>;
vi p;
vvi r;
int find(int i) {
if (i == p[i]) return i;
return p[i] = find(p[i]);
};
void unite(int i, int j) {
i = find(i);
j = find(j);
if (i == j) return;
if ... | 395 |
370 | try:
from mechanize import Request, urlopen, URLError, HTTPError,ProxyHandler, build_opener, install_opener, Browser
except ImportError:
print "\n[X] Please install mechanize module:"
print " http://wwwsearch.sourceforge.net/mechanize/\n"
exit()
import re
import random
import threading
from lxml imp... | 5,320 |
14,668 | // 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.
#include "third_party/blink/renderer/modules/peerconnection/rtc_encoded_video_underlying_sink.h"
#include "base/memory/scoped_refptr.h"
#include "testing... | 3,174 |
360 | <filename>bower.json
{
"name": "vminpoly",
"main": "vminpoly.js",
"version": "0.1.0",
"homepage": "https://github.com/saabi/vminpoly",
"authors": [
"<NAME> <<EMAIL>>"
],
"description": "A polyfill for CSS units vw, vh & vmin and now some media queries to boot.",
"keywords": [
"polyfill",
"cs... | 231 |
4,538 | <gh_stars>1000+
/*
* Copyright (C) 2015-2020 Alibaba Group Holding Limited
*
*/
#ifndef __UVOICE_MLIST_H__
#define __UVOICE_MLIST_H__
/** @defgroup uvoice_mlist_api uvoice_mlist
* @ingroup uvoice_aos_api
* @{
*/
/**
* 显示播放列表
*
* @retrun 成功返回0,失败返回非0.
*/
int mlist_source_show(void);
/**
* 扫描本地音频文件,更新播放列... | 882 |
657 | <filename>lib/slack/web/docs/channels.kick.json<gh_stars>100-1000
{
"desc": "Removes a user from a channel.",
"args": {
"channel": {
"type" : "channel",
"required" : true,
"desc" : "Channel to remove user from."
},
"user": {
"type" : "user",
"required" : true,
"desc" : "User to remove fro... | 327 |
2,225 | {
"fontId": "dseg14",
"fontName": "DSEG14",
"subsets": ["classic", "classic-mini", "modern", "modern-mini"],
"weights": [300, 400, 700],
"styles": ["italic", "normal"],
"defSubset": "classic",
"variable": false,
"lastModified": "2020-08-02",
"version": "v0.46",
"category": "other",
"source": "http... | 187 |
1,646 | package com.litesuits.orm.kvdb;
public interface FileDataCahe {
}
| 32 |
984 | /*
* Copyright DataStax, 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 wri... | 491 |
2,206 | <reponame>Celebrate-future/deeplearning4j
/*
* ******************************************************************************
* *
* *
* * 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/lic... | 2,123 |
3,274 | <filename>src/test/java/com/ql/util/express/bugfix/TestOverFlow.java<gh_stars>1000+
package com.ql.util.express.bugfix;
import org.junit.Test;
public class TestOverFlow {
public class Result{
private int a = 0;
private String b = "我是一个长长的字符串";
public int getA() {
return a;
... | 1,614 |
380 | from the_pile.utils import *
import random
import os
from tqdm import tqdm
import shutil
import zstandard
import io
import json
import sys
f = sys.argv[1]
fout = 'tmp'
def readf(f):
with open(f, 'rb') as fh:
cctx = zstandard.ZstdDecompressor()
reader = io.BufferedReader(cctx.stream_reader(fh))
... | 563 |
1,006 | /****************************************************************************
* arch/arm/src/nrf52/nrf52_rng.c
*
* 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 ow... | 2,675 |
1,481 | package apoc.data.url;
import apoc.util.TestUtil;
import org.junit.BeforeClass;
import org.junit.ClassRule;
import org.junit.Test;
import org.neo4j.test.rule.DbmsRule;
import org.neo4j.test.rule.ImpermanentDbmsRule;
import java.util.HashMap;
import java.util.Map;
import static apoc.util.MapUtil.map;
import static ap... | 2,122 |
1,083 | <filename>src/dale/Form/Proc/Dereference/Dereference.cpp
#include "Dereference.h"
#include <string>
#include <vector>
#include "../../../Function/Function.h"
#include "../../../Node/Node.h"
#include "../../../Operation/Destruct/Destruct.h"
#include "../../../ParseResult/ParseResult.h"
#include "../../../Units/Units.h... | 1,122 |
704 | <reponame>ozyb/novel-cloud
package com.java2nb.novel.file.schedule;
import com.java2nb.novel.book.entity.Book;
import com.java2nb.novel.common.utils.Constants;
import com.java2nb.novel.common.utils.FileUtil;
import com.java2nb.novel.file.feign.BookFeignClient;
import com.java2nb.novel.file.service.FileService;
import ... | 872 |
391 | <filename>clai/server/plugins/manpage_agent/manpage_agent.py<gh_stars>100-1000
#
# Copyright (C) 2020 IBM. All Rights Reserved.
#
# See LICENSE.txt file in the root directory
# of this source tree for licensing information.
#
import requests
import os
import json
from pathlib import Path
from clai.server.agent import... | 1,075 |
14,668 | <reponame>zealoussnow/chromium
// Copyright 2021 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.
package org.chromium.chrome.browser.continuous_search;
import static org.mockito.ArgumentMatchers.any;
import static org.m... | 3,203 |
448 | <gh_stars>100-1000
#include "LibunwindWrapper.h"
#include "Main.h"
#include <stdio.h>
#include <vector>
using namespace std;
LibunwindWrapper* wrapper;
int main(int argc, char** argv) {
if (argc != 3) {
printf("2 arguments required.\r\n");
return 1;
}
printf("Launching with args %s,%s\r\n", argv[1], argv[2])... | 832 |
1,144 | <reponame>gokhanForesight/metasfresh
package de.metas.invoicecandidate.api.impl.aggregationEngine;
/*
* #%L
* de.metas.swat.base
* %%
* Copyright (C) 2015 metas GmbH
* %%
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as
* published... | 4,059 |
416 | package org.simpleflatmapper.reflect.asm;
import org.simpleflatmapper.ow2asm.ClassWriter;
import org.simpleflatmapper.ow2asm.MethodVisitor;
import org.simpleflatmapper.reflect.Instantiator;
import static org.simpleflatmapper.ow2asm.Opcodes.ACC_BRIDGE;
import static org.simpleflatmapper.ow2asm.Opcodes.ACC_FINAL;
impor... | 1,279 |
369 | /** @file
@brief Header
@date 2015
@author
Sensics, Inc.
<http://sensics.com/osvr>
*/
// Copyright 2015 Sensics, 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 a... | 2,337 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.