max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
2,690 | # Copyright ClusterHQ Inc. See LICENSE file for details.
"""
Functional tests for ``flocker.node.agents.ebs`` using an EC2 cluster.
"""
from uuid import uuid4
from bitmath import Byte, GiB
from datetime import timedelta
from botocore.exceptions import ClientError
from testtools.matchers import AllMatch, ContainsA... | 12,485 |
971 | <filename>src/include/optimizer/statistics/table_stats.h
#pragma once
#include <memory>
#include <shared_mutex>
#include <unordered_map>
#include <utility>
#include <vector>
#include "catalog/catalog_defs.h"
#include "common/macros.h"
#include "common/managed_pointer.h"
#include "optimizer/statistics/column_stats.h"
... | 1,406 |
743 | # GPIO Zero: a library for controlling the Raspberry Pi's GPIO pins
#
# Copyright (c) 2021 <NAME> <<EMAIL>>
#
# SPDX-License-Identifier: BSD-3-Clause
from __future__ import (
unicode_literals,
absolute_import,
print_function,
division,
)
str = type('')
import io
from collections import Counter
from it... | 3,518 |
587 | <filename>src/libs6/s6_svc_writectl.c
/* ISC license. */
#include <skalibs/sysdeps.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#include <string.h>
#include <skalibs/djbunix.h>
#include <skalibs/unix-transactional.h>
#include <s6/supervise.h>
int s6_svc_writectl (char const *service, char const *sub... | 506 |
2,293 | #include "SupportBarF32.h"
#include "Error.h"
void SupportBarF32::test_barycenter_f32()
{
arm_barycenter_f32(this->inp, this->coefsp,
this->outp,
this->nbVectors,
this->vecDim);
}
void SupportBarF32::setUp(Testing::testID_t id,std::vector<Testing::... | 569 |
506 | <reponame>tabulon-ext/imapfilter<gh_stars>100-1000
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <strings.h>
#include <errno.h>
#include <netinet/in.h>
#include <netdb.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <sys/time.h>
#include <sys/select.h>
#include <openssl/ssl.h>
#include... | 5,052 |
2,633 | def application(scope, receive=None, send=None):
assert scope['type'] == 'http'
if receive == None and send == None:
return app_http
else:
return app_http(receive, send)
async def app_http(receive, send):
await send(
{
'type': 'http.response.start',
's... | 186 |
566 | <gh_stars>100-1000
{
"extends": [
"config:base"
],
"commitBody": "Signed-off-by: {{{gitAuthor}}}",
"automerge": true,
"labels": [
"dependencies"
],
"major": {
"automerge": false
}
}
| 98 |
11,356 | <filename>deps/src/boost_1_65_1/libs/math/test/test_legacy_nonfinite.cpp
// Copyright (c) 2006 <NAME>
// Copyright (c) 2011 <NAME>
// 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)
/*!
\file
\brief Legacy (non-C99... | 2,144 |
2,151 | package org.skia.skqp;
import android.content.Context;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.util.Log;
public class SkQPActivity extends AppCompatActivity implements Runnable {
private SkQP testRunner = new SkQP();
... | 423 |
1,861 | #!/usr/bin/env python3
#
# Author:
# <NAME> (@skelsec)
#
import io
from pypykatz.commons.common import KatzSystemArchitecture, WindowsMinBuild, WindowsBuild
from pypykatz.alsadecryptor.win_datatypes import BOOLEAN, HANDLE, USHORT, ULONG, LSA_UNICODE_STRING, LSAISO_DATA_BLOB, \
BYTE, PVOID, WORD, DWORD, POINTER, LUID,... | 14,958 |
3,170 | //
// Copyright (c) 2014-2016 THUNDERBEAST GAMES LLC
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify... | 2,501 |
416 | package org.simpleflatmapper.jdbc.test;
import org.junit.Test;
import org.simpleflatmapper.jdbc.DynamicJdbcMapper;
import org.simpleflatmapper.jdbc.JdbcColumnKey;
import org.simpleflatmapper.jdbc.JdbcMapperFactory;
import org.simpleflatmapper.jdbc.property.JdbcGetterFactoryProperty;
import org.simpleflatmapper.map.pro... | 1,634 |
7,407 | /*
===========================================================================
Copyright (C) 1999-2005 Id Software, Inc., 2016 Google Inc.
This file is part of Quake III Arena source code.
Quake III Arena source code is free software; you can redistribute it
and/or modify it under the terms of the GNU General Public ... | 4,750 |
611 | <reponame>packagesdev/dejalu
// DejaLu
// Copyright (c) 2015 <NAME>. All rights reserved.
#import <Foundation/Foundation.h>
#import <WebKit/WebKit.h>
@protocol DJLURLHandlerDelegate;
@interface DJLURLHandler : NSObject
@property (nonatomic, assign, getter=isReady) BOOL ready;
@property (nonatomic, assign) id <DJLU... | 386 |
627 | <reponame>YuanYuanDog/DesignPatterns-Objective-C<filename>DesignPatterns/FactoryMethod/UndergraduateFactory.h
//
// UndergraduateFactory.h
// DesignPatterns
//
// Created by leichunfeng on 14-10-19.
// Copyright (c) 2014年 zdnst. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "ILeiFengFactory.h"
... | 160 |
1,104 | <reponame>Zorghts/roll20-character-sheets
{
"html": "PTA.html",
"css": "PTA.css",
"authors": "<NAME> (sepianra)",
"roll20userid": "225131",
"preview": "PTA.png",
"instructions": "Characteristic Buttons will roll checks using modifiers",
"legacy": true
} | 105 |
458 | <reponame>Tazura/ngrest<filename>tools/ngrestcg/templates/common/enums.cpp
##foreach $(.enums)
##ifeq($(enum.isExtern),false)
##include "nsopt.cpp"
// enum $(enum.name)
const char* $(enum.ownerName.!replace/::/Serializer::/)Serializer::toCString($(enum.ownerName) value)
{
switch (value) {
##foreach $(enum.members... | 373 |
14,668 | // 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.
#include "third_party/blink/renderer/platform/network/content_security_policy_parsers.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace blink ... | 352 |
14,425 | <filename>hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/protocol/JournalProtocol.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 copy... | 1,152 |
892 | <gh_stars>100-1000
{
"schema_version": "1.2.0",
"id": "GHSA-5v65-cw5f-3jfp",
"modified": "2022-04-30T18:19:21Z",
"published": "2022-04-30T18:19:21Z",
"aliases": [
"CVE-2002-0500"
],
"details": "Internet Explorer 5.0 through 6.0 allows remote attackers to determine the existence of files on the client ... | 461 |
365 | <reponame>rbabari/blender
import bpy
track = bpy.context.edit_movieclip.tracking.tracks.active
track.color = (0.0, 1.0, 0.0)
track.use_custom_color = True
| 63 |
575 | // Copyright 2018 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 "components/offline_pages/core/auto_fetch.h"
#include "components/offline_pages/core/client_namespace_constants.h"
#include "testing/gtest/inclu... | 446 |
1,144 | // SPDX-License-Identifier: GPL-2.0+
/*
* Copyright (C) 2016, <NAME> <<EMAIL>>
*/
#include <common.h>
#include <dm.h>
#include <pci.h>
#include <vbe.h>
static int vesa_video_probe(struct udevice *dev)
{
return vbe_setup_video(dev, NULL);
}
static const struct udevice_id vesa_video_ids[] = {
{ .compatible = "vesa... | 290 |
572 | <reponame>cassiasamp/live-de-python<gh_stars>100-1000
s = 'Batatinha quando nasce espalha rama pelo chão'
s.count('a')
from collections import Counter
print(Counter(s))
| 67 |
2,221 | <filename>flume-ng-channels/flume-file-channel/src/test/java/org/apache/flume/channel/file/encryption/TestFileChannelEncryption.java<gh_stars>1000+
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additiona... | 5,368 |
4,036 | <filename>python/tools/recorded-call-graph-metrics/tests/python-src/getsockname.py
import socket
sock = socket.socket()
print(sock.getsockname())
| 50 |
335 | <filename>O/Overspill_noun.json
{
"word": "Overspill",
"definitions": [
"The action or result of spilling over or spreading into another area.",
"A surplus population moving or forced to move from an overcrowded area to a less heavily populated one."
],
"parts-of-speech": "Noun"
} | 109 |
32,544 | <reponame>DBatOWL/tutorials
package com.baeldung.persistence.dao;
import com.baeldung.persistence.model.Event;
import org.springframework.stereotype.Repository;
@Repository
public class EventDao extends AbstractHibernateDao<Event> implements IEventDao {
public EventDao() {
super();
setClazz(Eve... | 138 |
1,808 | <reponame>keesg60/hyperion.ng
#pragma once
#include <QAbstractNativeEventFilter>
// QT includes
#include <QObject>
#include <QJsonObject>
#include <QJsonArray>
#include <QJsonDocument>
#include <utils/ColorRgb.h>
#include <hyperion/Grabber.h>
#include <sys/ipc.h>
#include <sys/shm.h>
#include <xcb/randr.h>
#include... | 862 |
1,850 | <filename>repeater-plugin-api/src/main/java/com/alibaba/jvm/sandbox/repeater/plugin/domain/Invocation.java
package com.alibaba.jvm.sandbox.repeater.plugin.domain;
/**
* {@link Invocation} 描述一次调用
*
* <p>
* {@link Invocation} 调用信息抽象;一次完整的{@link RecordModel} 由一次入口{@link RecordModel#entranceInvocation}和若干次子{@link Reco... | 2,567 |
1,444 |
package mage.cards.n;
import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.filter.StaticFilters;
import mage.target.common.TargetCardInLibrary;
import java.util.UUID;
/**
*
* @author LevelX2... | 337 |
1,227 | from .preprocess import HiddenOutput, UAE, preprocess_drift
__all__ = [
"HiddenOutput",
"UAE",
"preprocess_drift"
]
| 52 |
6,304 | // Copyright 2020 Google LLC.
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file.
#include "tools/fiddle/examples.h"
REG_FIDDLE_ANIMATED(SkPath_cubicTo_example_parametric_animated, 512, 512, false, 0, 3) {
/*
If the starting point is (x0, y0), then this curve is ... | 1,627 |
444 | <reponame>icoz69/DeepEMD<gh_stars>100-1000
import argparse
import torch.nn as nn
import tqdm
from torch.utils.data import DataLoader
from Models.dataloader.samplers import CategoriesSampler
from Models.models.Network import DeepEMD
from Models.utils import *
from Models.dataloader.data_utils import *
DATA_DIR='your/... | 1,624 |
1,241 | import pigpio
import time
class OdomDist(object):
"""
Take a tick input from odometry and compute the distance travelled
"""
def __init__(self, mm_per_tick, debug=False):
self.mm_per_tick = mm_per_tick
self.m_per_tick = mm_per_tick / 1000.0
self.meters = 0
self.last_time... | 1,073 |
2,504 | <gh_stars>1000+
// ---------------------------------------------------------------------
// THIS FILE IS AUTO-GENERATED BY BEHAVIAC DESIGNER, SO PLEASE DON'T MODIFY IT BY YOURSELF!
// ---------------------------------------------------------------------
#include "../types/behaviac_types.h"
namespace behaviac
{
clas... | 731 |
8,805 | //////////////////////////////////////////////////////////////////////////////
//
// (C) Copyright <NAME> 2011-2013. 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)
//
// See http://www.boost.org/libs/containe... | 2,549 |
4,261 | /**
* Copyright (c) 2016-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#import <Foundation/Foundation.h>
/**
Defines an outgoing reference from Objective-C object.
*/
@proto... | 330 |
333 | package com.alipay.api.response;
import com.alipay.api.internal.mapping.ApiField;
import com.alipay.api.AlipayResponse;
/**
* ALIPAY API: mybank.finance.account.rysenterprise.query response.
*
* @author <NAME>
* @since 1.0, 2021-07-14 10:10:20
*/
public class MybankFinanceAccountRysenterpriseQueryR... | 374 |
4,098 | <filename>thirdparty/bullet/BulletCollision/BroadphaseCollision/btAxisSweep3.h
//Bullet Continuous Collision Detection and Physics Library
//Copyright (c) 2003-2006 <NAME> http://continuousphysics.com/Bullet/
//
// btAxisSweep3.h
//
// Copyright (c) 2006 <NAME>
//
// This software is provided 'as-is', without any exp... | 769 |
967 | //
// ECOCrashPlugin.h
// EchoSDK
//
// Created by Lux on 2019/8/26.
//
#import "ECOBasePlugin.h"
NS_ASSUME_NONNULL_BEGIN
@interface ECOCrashPlugin : ECOBasePlugin
@end
NS_ASSUME_NONNULL_END
| 89 |
3,428 | /**
* @license Apache-2.0
*
* Copyright (c) 2018 The Stdlib 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 a... | 6,440 |
4,140 | <filename>shims/common/src/main/java/org/apache/hadoop/fs/ProxyLocalFileSystem.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 copyright ownership. The ASF license... | 1,538 |
317 | package com.googlecode.totallylazy.iterators;
import java.util.Iterator;
import java.util.NoSuchElementException;
public class TakeIterator<T> extends ReadOnlyIterator<T> {
private final Iterator<? extends T> iterator;
private int count;
public TakeIterator(Iterator<? extends T> iterator, int count) {
... | 257 |
331 | <filename>models/resnet.py
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import shutil
from chainer.dataset import download
from chainer.links.model.vision import resnet
class ResNet(resnet.ResNetLayers):
URLS = {
'resnet50': 'https://www.dropbox.com/s/f0sqe7za120msbs/'
'R... | 930 |
613 | <reponame>valli-dr/spring-cloud-aws
/*
* Copyright 2013-2019 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/LI... | 1,657 |
3,372 | /*
* 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
*
* or in the "licen... | 2,807 |
611 | <reponame>ste93cry/idea-php-symfony2-plugin<gh_stars>100-1000
package fr.adrienbrault.idea.symfony2plugin.util;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.psi.PsiElement;
import org.jetbrains.annotations.NotNull;
/**
* All project related function
*... | 342 |
4,081 | /*
* The Alluxio Open Foundation licenses this work under the Apache License, version 2.0
* (the "License"). You may not use this work except in compliance with the License, which is
* available at www.apache.org/licenses/LICENSE-2.0
*
* This software is distributed on an "AS IS" basis, WITHOUT WARRANTIES OR CONDI... | 542 |
2,073 | /*
* 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 ... | 1,413 |
362 | <reponame>hsiangawang/whois<filename>whois-update/src/main/java/net/ripe/db/whois/update/handler/validator/organisation/CountryRipeMaintainedValidator.java<gh_stars>100-1000
package net.ripe.db.whois.update.handler.validator.organisation;
import com.google.common.collect.ImmutableList;
import net.ripe.db.whois.common.... | 1,038 |
561 | import math
import torch
from torch import nn
from torch.nn import Parameter, Linear
from modules.commons.layers import LayerNorm, Embedding
from utils.nn.seq_utils import get_incremental_state, set_incremental_state, softmax, make_positions
import torch.nn.functional as F
DEFAULT_MAX_SOURCE_POSITIONS = 2000
DEFAULT_M... | 15,933 |
1,559 | <reponame>msgi/nlp-tour
import pickle
from gensim.corpora import Dictionary
from gensim.models import LdaModel, TfidfModel
import jieba
import os
class LdaTopicModel(object):
def __init__(self, model_path,
config_path,
train=False,
file_path=None):
self... | 1,063 |
32,544 | <reponame>DBatOWL/tutorials
module jlinkModule {
requires java.logging;
} | 31 |
1,053 | /*
* "Copyright (c) 2008, 2009 The Regents of the University of California.
* All rights reserved."
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose, without fee, and without written agreement is
* hereby granted, provided that the above copyright notice, ... | 1,404 |
2,094 | ////////////////////////////////////////////////////////////////////////////////////////////////////
//
// Project: Embedded Learning Library (ELL)
// File: HuberLoss.h (optimization)
// Authors: <NAME>, <NAME>
//
/////////////////////////////////////////////////////////////////////////////////////////////////... | 1,764 |
399 | <reponame>adrianmgg/GRIP<filename>core/src/test/java/edu/wpi/grip/core/sockets/MockInputSocketFactory.java
package edu.wpi.grip.core.sockets;
import edu.wpi.grip.core.cuda.NullCudaDetector;
import com.google.common.eventbus.EventBus;
public class MockInputSocketFactory extends InputSocketImpl.FactoryImpl {
publi... | 149 |
733 | from rx.core import Observable
from rx.internal import extensionmethod
@extensionmethod(Observable, alias="every")
def all(self, predicate):
"""Determines whether all elements of an observable sequence satisfy a
condition.
1 - res = source.all(lambda value: value.length > 3)
Keyword arguments:
:... | 183 |
368 | /*
* Copyright 2020 ZUP IT SERVICOS EM TECNOLOGIA E INOVACAO SA
*
* 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... | 349 |
1,276 | {
"name": "@nuxtjs/browserconfig",
"version": "0.0.13",
"license": "MIT",
"main": "index.js",
"repository": "https://github.com/nuxt/modules",
"homepage": "https://github.com/nuxt/modules/tree/master/packages/browserconfig",
"dependencies": {
"data2xml": "^1.3.4",
"lodash": "^4.17.20"
}
}
| 137 |
376 | <reponame>cjsmeele/Kvasir
#pragma once
#include <Register/Utility.hpp>
namespace Kvasir {
//Power Calculation Engine (PCE)
namespace PcePintcr{ ///<PCE core interrupt control
using Addr = Register::Address<0x4406f000,0xfffffff8,0x00000000,unsigned>;
///PCERST
constexpr Register::FieldLoc... | 1,043 |
1,794 | # Copyright 2019-2021 The AmpliGraph Authors. All Rights Reserved.
#
# This file is Licensed under the Apache License, Version 2.0.
# A copy of the Licence is available in LICENCE, or at:
#
# http://www.apache.org/licenses/LICENSE-2.0
#
import numpy as np
import pytest
from sklearn.cluster import DBSCAN
from amplig... | 7,412 |
1,093 | /*
* Copyright 2002-2019 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
*
* Unless required by a... | 682 |
7,713 | <filename>ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSettingsActivity.java<gh_stars>1000+
/**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An a... | 298 |
532 | <reponame>MariaHammer/opensim-core_HaeufleMuscle
/* -------------------------------------------------------------------------- *
* OpenSim Moco: MocoControlBoundConstraint.cpp *
* -------------------------------------------------------------------------- *
* Copyright (c) 2019 Stanford ... | 2,966 |
1,570 | //===- subzero/crosstest/vectors.h - Common SIMD vector utilies -*- C++ -*-===//
//
// The Subzero Code Generator
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------... | 1,781 |
6,034 | <filename>user-service-project/user-service-api/src/main/java/cn/iocoder/mall/userservice/rpc/address/dto/UserAddressUpdateReqDTO.java
package cn.iocoder.mall.userservice.rpc.address.dto;
import cn.iocoder.common.framework.validator.InEnum;
import cn.iocoder.common.framework.validator.Mobile;
import cn.iocoder.mall.us... | 809 |
2,460 | <reponame>shawkins/kubernetes-client
/**
* Copyright (C) 2015 Red Hat, 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
*
*... | 932 |
305 | //===- ForwardOpTree.h ------------------------------------------*- 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
//
//===---------------------------... | 225 |
333 | void nop()
{
123;
}
int main(void) {
nop();
return 42;
}
| 38 |
7,464 | <filename>standard/sonar-vj/src/main/java/com/vip/vjkit/sonarvj/checks/MissingCurlyBracesCheck.java<gh_stars>1000+
package com.vip.vjkit.sonarvj.checks;
import com.google.common.collect.ImmutableList;
import org.sonar.check.Rule;
import org.sonar.plugins.java.api.IssuableSubscriptionVisitor;
import org.sonar.plugins.j... | 1,157 |
335 | {
"word": "Terrorist",
"definitions": [
"Unlawfully using violence and intimidation, especially against civilians, in the pursuit of political aims."
],
"parts-of-speech": "Adjective"
} | 72 |
375 | package io.lumify.palantir.model;
import io.lumify.palantir.util.JGeometryWrapper;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Writable;
import java.io.DataInput;
import java.io.DataOutput;
import java.io.IOException;
import java.sql.Struct;
public class PtPropertyAndValue extends PtModelBa... | 3,182 |
8,569 | #define _POSIX_C_SOURCE 200809L
#include <unistd.h>
#include <errno.h>
#include "sway/config.h"
#include "sway/commands.h"
#include "log.h"
#include "stringop.h"
struct cmd_results *input_cmd_xkb_file(int argc, char **argv) {
struct cmd_results *error = NULL;
if ((error = checkarg(argc, "xkb_file", EXPECTED_EQUAL_TO... | 630 |
31,928 | import json
import logging
import random
import string
from moto.iam.policy_validation import IAMPolicyDocumentValidator
from moto.secretsmanager import models as secretsmanager_models
from moto.secretsmanager.exceptions import SecretNotFoundException
from moto.secretsmanager.models import SecretsManagerBackend, secre... | 2,377 |
1,144 | <reponame>Keneral/asystem
/*
* Copyright (C) 2016 The Android Open Source Project
* 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... | 1,169 |
530 | package org.carlspring.strongbox.security.authentication.suppliers;
import javax.annotation.CheckForNull;
import javax.annotation.Nonnull;
import javax.servlet.http.HttpServletRequest;
import java.util.List;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.security.core.Authenticati... | 1,027 |
1,253 | import java.util.*;
public class ShellSort {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int[] elements;
System.out.println("Enter the number of elements: ");
int j, n = sc.nextInt();
elements = new int[n];
int gap = n / 2;
System.out.println("Enter eleme... | 361 |
1,178 | /*
* Copyright 2020 Makani Technologies LLC
*
* 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,149 |
388 | # Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License.
from .aiohttp_web_socket import AiohttpWebSocket
__all__ = [
"AiohttpWebSocket",
]
| 58 |
634 | /****************************************************************
* 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... | 2,069 |
12,824 | <filename>tests/pos/chang/Outer.java
package com.netgents.hello;
public class Outer<A> {
public Inner inner = new Inner();
public class Inner {
public A a;
}
}
| 62 |
852 | //
//
// File: hitfit/gentop.h
// Purpose: Toy ttbar event generator for testing.
// Created: Jul, 2000, sss.
//
// This is a very simple event generator for ttbar events, to allow some
// basic tests of the mass fitting code. We generate random ttbars,
// with kinematics pulled out of a hat, and then decay them into ... | 3,912 |
5,169 | <filename>Specs/f/7/0/SmartechNudges/8.5.9/SmartechNudges.podspec.json
{
"name": "SmartechNudges",
"version": "8.5.9",
"platforms": {
"ios": "10.0"
},
"summary": "SmartechNudges is for adding no code nudges in the app.",
"description": "SmartechNudges framework powers developers to rapidly experiment an... | 657 |
5,169 | {
"name": "FTTimer",
"version": "0.0.1",
"summary": "Just a tiny library to make using NSTimer easier without retain cycle",
"homepage": "https://github.com/futantan/FTTimer",
"license": "MIT",
"authors": {
"futantan": "<EMAIL>"
},
"source": {
"git": "https://github.com/futantan/FTTimer.git",
... | 194 |
1,398 | <gh_stars>1000+
/*
* This file is part of the SDWebImage package.
* (c) <NAME> <<EMAIL>>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
#ifdef SD_WEBP
#import <Foundation/Foundation.h>
#import "SDWebImageCoder.h"
/**
Built in c... | 161 |
701 | //
// Pagination.h
// mcapp
//
// Created by zhuchao on 14/11/7.
// Copyright (c) 2014年 zhuchao. All rights reserved.
//
#import "Model.h"
@interface Pagination : Model
@property(nonatomic,retain)NSNumber *page;
@property(nonatomic,retain)NSNumber *pageSize;
@property(nonatomic,retain)NSNumber *total;
@property(n... | 178 |
357 | from . import expr
from . import stmt
| 11 |
916 | <filename>flexy-pool-core/src/test/java/com/vladmihalcea/flexypool/util/ClassLoaderUtilsTest.java<gh_stars>100-1000
package com.vladmihalcea.flexypool.util;
import org.junit.Test;
import java.io.IOException;
import static org.junit.Assert.*;
/**
* ClassLoaderUtilsTest - ClassLoaderUtils Test
*
* @author <NAME>
... | 883 |
506 | // https://cses.fi/problemset/task/1109/
#include <iostream>
using namespace std;
int x, y, n, a[1000001];
int main() {
string s;
cin >> s;
n = s.size();
int i = 1;
for (;i < n; i++) {
a[i] = max(0, min(a[i - x], y - i + 1));
while (a[i] + i < n && s[a[i]] == s[a[i] + i]) {
x = i; y = a[i] + ... | 220 |
374 | <filename>src/parcsr_ls/par_add_cycle.c
/******************************************************************************
* Copyright 1998-2019 Lawrence Livermore National Security, LLC and other
* HYPRE Project Developers. See the top-level COPYRIGHT file for details.
*
* SPDX-License-Identifier: (Apache-2.0 OR MIT)... | 23,974 |
1,056 | <gh_stars>1000+
/*
* 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
* ... | 1,679 |
4,047 | <gh_stars>1000+
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <boost/python.hpp>
struct World
{
void set(std::string msg) { this->msg = msg; }
std::string greet() { return msg; }
std::string version() { return std::to_string(PY_MAJOR_VERSION) + "." + std::to_string(PY_MINOR_VERSION); }
std::str... | 241 |
328 | /**
* @file remoteconfig.cpp
*
*/
/* Copyright (C) 2019-2021 by <NAME> mailto:<EMAIL>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitatio... | 19,568 |
660 | /*
* Copyright (c) 2019, Intel Corporation
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publis... | 4,952 |
831 | /*
* Copyright 2000-2012 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... | 3,481 |
339 | from __future__ import division, print_function, unicode_literals
import argparse
import json
import random
import time
from io import open
import os
import numpy as np
import torch
from torch.optim import Adam
from convlab2.policy.mdrg.multiwoz.utils import util
from convlab2.policy.mdrg.multiwoz.model import Model... | 3,516 |
467 | <gh_stars>100-1000
from django.conf import settings
DEVSERVER_MODULES = getattr(settings, 'DEVSERVER_MODULES', (
'devserver.modules.sql.SQLRealTimeModule',
# 'devserver.modules.sql.SQLSummaryModule',
# 'devserver.modules.profile.ProfileSummaryModule',
# 'devserver.modules.request.SessionInfoModule',
... | 484 |
2,151 | <filename>components/variations/variations_params_manager.h
// 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 COMPONENTS_VARIATIONS_VARIATIONS_PARAMS_MANAGER_H_
#define COMPONENTS_VARIATIONS_VARIA... | 1,105 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.