max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
977 | package io.leangen.graphql.metadata;
import io.leangen.geantyref.GenericTypeReflector;
import io.leangen.graphql.metadata.exceptions.MappingException;
import io.leangen.graphql.metadata.execution.Executable;
import io.leangen.graphql.util.ClassUtils;
import io.leangen.graphql.util.Utils;
import java.lang.reflect.Anno... | 2,408 |
784 | /**
* Copyright (c) 2015-2021, <NAME> 杨福海 (<EMAIL>).
* <p>
* 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
* <p>
* http://www.apache.org/licenses/LICENSE-2.0
* <p>
* Unless required by... | 432 |
1,681 | # Copyright 2019 The TensorNetwork Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed ... | 8,313 |
826 | <gh_stars>100-1000
#!/usr/bin/env python
"""
A simple cmd-line tool for displaying FormattingString capabilities.
For example::
$ python tprint.py bold A rather bold statement.
"""
# std
from __future__ import print_function
# std imports
import argparse
# local
from blessed import Terminal
def parse_args():
... | 285 |
310 | #ifndef SRC_VERSION_H_
#define SRC_VERSION_H_
#define BUD_VERSION_MAJOR 4
#define BUD_VERSION_MINOR 0
#define BUD_VERSION_PATCH 28
#endif /* SRC_VERSION_H_ */
| 71 |
2,460 | /*
* Copyright (c) 2016-2021 <NAME> <<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 limitation the
* rights to use, copy, modify, merge, ... | 3,869 |
883 | {
"title": "EventBridge to AppSync",
"description": "Create an EventBridge bus and destination with OAuth authorization to trigger an AppSync GraphQL API",
"language": "Node.js",
"architectureURL": "pattern-cdk-eventbridge-appsync.png",
"level": "200",
"framework": "CDK",
"services": {
"from": "eventb... | 741 |
404 | <reponame>techkey/PTVS
import blah
print('hi') | 19 |
301 | {
"rootWorkspaces": [],
"folderURIWorkspaces": [],
"emptyWorkspaceInfos": [],
"emptyWorkspaces": []
}
| 42 |
434 | /*
* GainStrong Oolite V5.2 module and development board support
*
* Copyright (C) 2018 <NAME> <<EMAIL>>
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 as published
* by the Free Software Foundation.
*/
#include <linux/g... | 1,445 |
412 | /*******************************************************************\
Module: Messaget tests
Author: <NAME>.
\*******************************************************************/
#include <sstream>
#include <testing-utils/use_catch.h>
#include <util/message.h>
TEST_CASE("Copy a messaget")
{
std::ostringstream ss... | 384 |
591 | [
{"artifacts/fence/_fence.go.json": true },
{"artifacts/firewood/_firewood.go.json": true },
{"artifacts/stoneWall/_stoneWall.go.json": true },
{"artifacts/campfire/_campfire.go.json": true },
{"artifacts/glassBottle/_glassBottle.go.json": true },
{"artifacts/pot/_pot.go.json": true },
{"ar... | 448 |
2,728 | <reponame>m5o/passenger
/*
* Phusion Passenger - https://www.phusionpassenger.com/
* Copyright (c) 2010-2017 Phusion Holding B.V.
*
* "Passenger", "Phusion Passenger" and "Union Station" are registered
* trademarks of Phusion Holding B.V.
*
* Permission is hereby granted, free of charge, to any person obtai... | 4,805 |
511 | <gh_stars>100-1000
/****************************************************************************
*
* Copyright 2018 Samsung Electronics 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 cop... | 1,811 |
2,151 | // Copyright (c) 2015 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 ANDROID_WEBVIEW_BROWSER_NET_AW_HTTP_USER_AGENT_SETTINGS_H_
#define ANDROID_WEBVIEW_BROWSER_NET_AW_HTTP_USER_AGENT_SETTINGS_H_
#include <strin... | 434 |
14,668 | <reponame>chromium/chromium
// 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.
// This file contains UTF16 strings that we want as char16_t arrays.
#include "components/autofill/core/browser/autofill_rege... | 16,047 |
1,275 | <reponame>ananthdurai/pinot<filename>pinot-segment-local/src/test/java/org/apache/pinot/segment/local/utils/nativefst/FSTSanityTest.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 informat... | 1,091 |
383 | <filename>fastexcel-writer/src/main/java/org/dhatim/fastexcel/DataValidation.java
package org.dhatim.fastexcel;
import java.io.IOException;
interface DataValidation {
/**
* Write this dataValidation as an XML element.
*
* @param w Output writer.
* @throws IOException If an I/O error occurs.
... | 140 |
3,139 | <filename>jme3-vr/src/main/java/com/jme3/input/vr/VRTrackedController.java
package com.jme3.input.vr;
import com.jme3.math.Matrix4f;
import com.jme3.math.Quaternion;
import com.jme3.math.Vector3f;
/**
* TODO
* @author <NAME> - COMEX SA - <a href="http://www.seinturier.fr">http://www.seinturier.fr</a>
*/
... | 525 |
763 | package org.batfish.representation.juniper;
import static org.batfish.representation.juniper.JuniperConfiguration.computeConditionRoutingPolicyName;
import javax.annotation.Nonnull;
import javax.annotation.ParametersAreNonnullByDefault;
import org.batfish.common.Warnings;
import org.batfish.datamodel.Configuration;
i... | 426 |
2,151 | <filename>cc/trees/layer_tree_host_unittest_masks.cc
// 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 "cc/trees/layer_tree_host.h"
#include "cc/test/fake_picture_layer.h"
#include "cc/test/fake... | 10,442 |
2,587 | <filename>android-godeye/src/main/java/cn/hikyson/godeye/core/internal/modules/battery/BatteryConfig.java
package cn.hikyson.godeye.core.internal.modules.battery;
import androidx.annotation.Keep;
import java.io.Serializable;
@Keep
public class BatteryConfig implements Serializable {
@Override
public String ... | 133 |
347 | package org.ovirt.engine.ui.uicommonweb.models;
import org.ovirt.engine.core.common.businessentities.Queryable;
import com.google.gwt.view.client.ProvidesKey;
public class QueryableEntityKeyProvider<T> implements ProvidesKey<T> {
@Override
public Object getKey(T item) {
if (item instanceof Queryable... | 165 |
764 | {"symbol": "PHV","address": "0x25200235cA7113C2541E70dE737c41f5e9AcD1F6","overview":{"en": ""},"email": "<EMAIL>","website": "https://pathhive.com/","state": "NORMAL","links": {"blog": "https://medium.com/@PathHiveNetwork","twitter": "https://twitter.com/PathHiveNetwork","telegram": "https://t.me/pathhive1","github": "... | 137 |
2,577 | /*
* Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
* under one or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information regarding copyright
* ownership. Camunda licenses this file to you under the Apache License,
* Version 2.0; y... | 493 |
2,869 | /*
* JBoss, Home of Professional Open Source.
* Copyright 2020 Red Hat, Inc., and individual contributors
* as indicated by the @author tags.
*
* 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... | 3,177 |
9,724 | <gh_stars>1000+
//===-- sanitizer_thread_safety.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
//
//===-----------... | 820 |
344 | <reponame>socialwifi/fluent-logger-python<gh_stars>100-1000
# -*- coding: utf-8 -*-
import logging
import sys
import unittest
import fluent.handler
from tests import mockserver
class TestHandler(unittest.TestCase):
def setUp(self):
super(TestHandler, self).setUp()
self._server = mockserver.Mock... | 6,537 |
2,111 | <filename>algorithms/src/LocalizationAndMapping/registration_localization/fast_gicp/thirdparty/nvbio/nvbio/basic/atomics.h
/*
* nvbio
* Copyright (c) 2011-2014, NVIDIA CORPORATION. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided th... | 5,411 |
5,535 | <gh_stars>1000+
//---------------------------------------------------------------------------
// Greenplum Database
// Copyright (C) 2008 Greenplum, Inc.
//
// @filename:
// CAutoPTest.h
//
// @doc:
// Unit test for CAutoP
//---------------------------------------------------------------------------
#ifndef GPOS_... | 281 |
13,846 | <filename>src/ProjectTemplates/Web.ProjectTemplates/content/ComponentsWebAssembly-CSharp/.template.config/ko-KR/strings.json
{
"version": "1.0.0.0",
"strings": {
"name": "Blazor WebAssembly 앱",
"description": "WebAssembly에서 실행되고 ASP.NET Core 앱에서 선택적으로 호스트되는 Blazor 앱을 만들기 위한 프로젝트 템플릿입니다. 이 템플릿은 다양한 동적 UI(사용자... | 388 |
558 | from nose2.tools import params
import unittest
from test.example_runner import run_docstring_example
from hamcrest import assert_that
from allure_commons_test.report import has_test_case
from allure_commons_test.result import has_parameter
from allure_commons.utils import represent
@params(
(("alpha", "hello"), (... | 1,003 |
28,992 | <gh_stars>1000+
"""
Cache implementation.
Currently only two types of cache are allowed:
* "none" cache switched off
* "redis" use redis for cache
Configuration parameters:
cache.type = redis | none
cache.redis.db
cache.redis.host
cache.redis.port
"""
import os
import json
from config im... | 699 |
5,102 | package com.nepxion.discovery.common.apollo.constant;
/**
* <p>Title: Nepxion Discovery</p>
* <p>Description: Nepxion Discovery</p>
* <p>Copyright: Copyright (c) 2017-2050</p>
* <p>Company: Nepxion</p>
* @author <NAME>
* @version 1.0
*/
import com.ctrip.framework.apollo.core.ConfigConsts;
public class ApolloC... | 209 |
313 | //------------------------------------------------------------------------------
// GB_cast_array: typecast an array
//------------------------------------------------------------------------------
// SuiteSparse:GraphBLAS, <NAME>, (c) 2017-2022, All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
//---------... | 1,443 |
16,461 | //
// ABI42_0_0AIRGMSPolygon.h
// AirMaps
//
// Created by <NAME> 02/05/2017.
//
#ifdef ABI42_0_0HAVE_GOOGLE_MAPS
#import <GoogleMaps/GoogleMaps.h>
#import <ABI42_0_0React/ABI42_0_0UIView+React.h>
@class ABI42_0_0AIRGoogleMapPolygon;
@interface ABI42_0_0AIRGMSPolygon : GMSPolygon
@property (nonatomic, strong) NS... | 193 |
335 | {
"word": "Romance",
"definitions": [
"Try to gain the love of; court.",
"Seek the attention or custom of (someone), especially by the use of flattery.",
"Engage in a love affair."
],
"parts-of-speech": "Verb"
} | 104 |
965 | <reponame>bobbrow/cpp-docs
// A basic agent that uses control-flow to regulate the order of program
// execution. This agent reads numbers from a message buffer and counts the
// number of positive and negative values.
class control_flow_agent : public agent
{
public:
explicit control_flow_agent(ISource<int>& sour... | 593 |
370 | package com.jeremyliao.android.asm;
/**
* Created by liaohailiang on 2019-09-26.
*/
public class TestTarget {
public int getIntValue() {
return 10;
}
public boolean getBoolValue() {
return true;
}
public int parseLong(long value) {
return (int) value;
}
}
| 129 |
1,847 | /*
* Copyright (C) 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 app... | 2,698 |
543 | <reponame>Dynamite12138/NLPwork
/* NiuTrans.Tensor - an open-source tensor library
* Copyright (C) 2020, Natural Language Processing Lab, Northeastern University.
* All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the Lic... | 886 |
432 | /*
* SYS/THREAD2.H
*
* Implements inline procedure support for the LWKT subsystem.
*
* Generally speaking these routines only operate on threads associated
* with the current cpu. For example, a higher priority thread pending
* on a different cpu will not be immediately scheduled by a yield() on
* this cpu.
*... | 4,089 |
1,048 | <reponame>glebshevchukk/gradslam
from .projutils import *
| 25 |
1,755 | /*=========================================================================
Program: Visualization Toolkit
Module: vtkMultiBlockDataSet.h
Copyright (c) <NAME>, <NAME>, <NAME>
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is distributed W... | 1,341 |
964 | <reponame>cxMiguelSilva/kics
[
{
"queryName": "Configuration Aggregator to All Regions Disabled",
"severity": "HIGH",
"line": 10
},
{
"queryName": "Configuration Aggregator to All Regions Disabled",
"severity": "HIGH",
"line": 24
}
]
| 108 |
1,136 | #include <stdio.h>
#include <stdlib.h>
#include <getopt.h>
#include <string.h>
#include <errno.h>
#include "hiredis/hiredis.h"
void Usage(const char *program_name) {
printf("Usage: %s [options]\n"
"options:\n"
" -s, --socket <file> unix socket of kids\n"
" -h, --host <host> host of kids (a... | 1,078 |
881 | # -*- coding: utf-8 -*-
"""
Tencent is pleased to support the open source community by making 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community
Edition) available.
Copyright (C) 2017-2021 THL A29 Limited, a Tencent company. All rights reserved.
Licensed under the MIT License (the "License"); you may not use this file except in co... | 7,847 |
1,077 | <filename>Quicksilver/Code-App/QSAdvancedPrefPane.h
//
// QSAdvancedPrefPane.h
// Quicksilver
//
// Created by <NAME> on 4/28/06.
// Copyright 2006 __MyCompanyName__. All rights reserved.
//
#import <Cocoa/Cocoa.h>
@interface QSAdvancedPrefPane : QSPreferencePane <NSTableViewDataSource, NSTableViewDelegate> {
IB... | 314 |
573 | <gh_stars>100-1000
// Copyright 2015, VIXL authors
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are met:
//
// * Redistributions of source code must retain the above copyright notice,
// this ... | 229,910 |
634 | <reponame>halotroop2288/consulo
/*
* Copyright 2000-2015 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 re... | 3,545 |
7,629 | /*
# Copyright 2018 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 writi... | 1,124 |
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.
package org.chromium.components.payments.secure_payment_confirmation;
import org.chromium.components.url_formatter.SchemeDisplay;
import org.chromium.com... | 1,025 |
852 | #include "DataFormats/SiPixelDigi/interface/SiPixelCalibDigiError.h"
std::string SiPixelCalibDigiError::printError() const {
std::string result = "unknown error";
switch (fErrorType) {
case (1): {
result = "arrived at unexpected pattern.";
break;
}
case (2): {
result = "pixel is not i... | 151 |
335 | #!/usr/bin/env python
"""parser.py - A JavaScript parser, currently with many bugs.
See README.md for instructions.
"""
from . import parser_tables
from .lexer import JSLexer
# "type: ignore" because mypy can't see inside js_parser.parser_tables.
class JSParser(parser_tables.Parser): # type: ignore
def __init... | 574 |
2,583 | {
"contexts": [
{
"name": "histogram_pass",
"depth_write": false,
"compare_mode": "always",
"cull_mode": "none",
"blend_source": "source_alpha",
"blend_destination": "inverse_source_alpha",
"blend_operation": "add",
"links": [],
"texture_params": [],
"vertex_shader": "../include/pass.ve... | 185 |
1,590 | <gh_stars>1000+
/*
* Simd Library (http://ermig1979.github.io/Simd).
*
* Copyright (c) 2011-2017 <NAME>.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, includin... | 2,699 |
1,464 | /*
* Copyright (C) 2017-2021 <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... | 1,390 |
451 | // File Automatically generated by eLiSe
#include "general/all.h"
#include "private/all.h"
#include "cEqAppui_X_C2MPolyn3.h"
cEqAppui_X_C2MPolyn3::cEqAppui_X_C2MPolyn3():
cElCompiledFonc(1)
{
AddIntRef (cIncIntervale("Intr",0,17));
AddIntRef (cIncIntervale("Orient",17,23));
Close(false);
}
void cEqApp... | 3,302 |
808 | #!/bin/env python
# -*- coding: utf-8 -*-
################################################################################
#
# Copyright (c) 2014 Baidu.com, Inc. All Rights Reserved
#
################################################################################
import configparser
import os
import sys
import io
imp... | 3,226 |
1,159 | <reponame>dyuri/vizzu-lib
#include "angle.h"
#include <cmath>
#include <stdexcept>
#include "base/text/valueunit.h"
using namespace Geom;
double Angle::degToRad(double deg)
{
return M_PI * deg / 180.0;
}
double Angle::radToDeg(double rad)
{
return 180.0 * rad / M_PI;
}
Angle::Angle(const std::string &str)
{
Te... | 730 |
7,407 | /*
===========================================================================
Copyright (C) 1999-2005 Id Software, Inc., 2016-2017 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 Pu... | 36,725 |
914 | <filename>cicada-db/src/main/java/top/crossoverjie/cicada/db/core/handle/HandleProxy.java
package top.crossoverjie.cicada.db.core.handle;
import lombok.extern.slf4j.Slf4j;
import top.crossoverjie.cicada.db.listener.DataChangeListener;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;
import... | 683 |
2,728 | # coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... | 1,570 |
1,510 | <filename>contrib/native/client/test/ssl/testSSL.cpp
/*
* 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... | 9,039 |
2,035 | <filename>tests/python/test_states.py<gh_stars>1000+
import tinyflow as tf
import numpy as np
def test_assign():
x = tf.Variable(tf.zeros(shape=[2,3]))
sess = tf.Session()
sess.run(tf.assign(x, tf.zeros(shape=[2,3])))
ax = sess.run(x)
np.testing.assert_almost_equal(ax, np.zeros((2,3)))
def test_gr... | 536 |
486 | /*
* ARX: Powerful Data Anonymization
* Copyright 2012 - 2021 <NAME> and 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.org/licenses/LICE... | 1,687 |
488 | <gh_stars>100-1000
#ifndef ROSE_StringUtility_SplitJoin_H
#define ROSE_StringUtility_SplitJoin_H
#include <Rose/Constants.h>
#include <rosedll.h>
#include <list>
#include <sstream>
#include <string>
#include <vector>
namespace Rose {
namespace StringUtility {
////////////////////////////////////////////////////////... | 2,189 |
404 | #include "nanoprintf_in_unit_tests.h"
#include "CppUTest/TestHarness.h"
#include <cstring>
TEST_GROUP(itoa) { char buf[64]; };
#define NPF_ITOA_CHECK(EXPECT_STR, VAL) \
do { \
int const n = npf_itoa_rev(buf, VAL); \
CHECK_EQUAL((int)strlen(EXPE... | 864 |
776 | <reponame>Diffblue-benchmarks/actframework
package act.app.conf;
/*-
* #%L
* ACT Framework
* %%
* Copyright (C) 2014 - 2017 ActFramework
* %%
* 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... | 692 |
453 | <gh_stars>100-1000
/*
* Copyright (c) 2011 <NAME>
*
* BSD license:
*
* 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 ... | 985 |
575 | // Copyright (c) 2012 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.
//
// THREAD SAFETY
//
// This class is generally not thread safe. Callers should ensure thread safety.
// For instance, the |sink_lock_| in WebAudioSo... | 1,779 |
315 | <reponame>Lilhxr/AlgorithmDiagram
#include <iostream>
using namespace std;
//找出基准元的下标,并且完成元素的分块
//找出基准元的方法很多,取第一个或者最后一个都不是一个好方法
//具体可以自行上网查阅资料
int Sort(int arr[], int left, int right) {
//取第一个元素为基准元
int pivotValue = arr[left];
//使用双向扫描法完成分块
//基准元的左边都小于他,右边都大于他
while (left < right) {
while (left < right && arr[... | 616 |
416 | <reponame>Amity-Network/amity
//
// CNSocialProfile.h
// Contacts
//
// Copyright (c) 2015 Apple Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <Contacts/ContactsDefines.h>
NS_ASSUME_NONNULL_BEGIN
/*!
* @abstract An immutable value object representing a social profile.
*
* @discussion ... | 1,076 |
631 | // Copyright 2020 The Beam Team
//
// 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... | 15,306 |
307 | """
This module provides the `Sequence` class. This class is the abstract
base class for biological sequence collections (e.g. genomes).
"""
from abc import ABCMeta
from abc import abstractmethod
import numpy as np
from ._sequence import _fast_sequence_to_encoding
def sequence_to_encoding(sequence, base_to_index, ... | 3,605 |
790 | <reponame>loftwah/appscale
import json
import logging
import time
from kazoo.client import KazooException
from kazoo.client import KazooState
from kazoo.client import NoNodeError
from kazoo.exceptions import ZookeeperError
from threading import Lock
from .constants import TINY_WAIT
class ConfigInaccessible(Exceptio... | 1,939 |
785 | <filename>crosshair/libimpl/relib_ch_test.py
import re
import sys
from typing import Optional, Sequence
import pytest # type: ignore
from crosshair.core_and_libs import analyze_function
from crosshair.core_and_libs import run_checkables
from crosshair.core_and_libs import MessageType
from crosshair.options import An... | 1,560 |
575 | <gh_stars>100-1000
// 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.
#ifndef CHROME_BROWSER_MEDIA_WEBRTC_DESKTOP_MEDIA_LIST_ASH_H_
#define CHROME_BROWSER_MEDIA_WEBRTC_DESKTOP_MEDIA_LIST_ASH_H_
#include <... | 568 |
675 | <reponame>dcarbone/go-heicker<filename>vendor/github.com/jdeng/goheif/libde265/libde265/bitstream.h
/*
* H.265 video codec.
* Copyright (c) 2013-2014 struktur AG, <NAME> <<EMAIL>>
*
* This file is part of libde265.
*
* libde265 is free software: you can redistribute it and/or modify
* it under the terms of the G... | 665 |
317 | // Released under the MIT License. See LICENSE for details.
#ifndef BALLISTICA_PYTHON_PYTHON_SYS_H_
#define BALLISTICA_PYTHON_PYTHON_SYS_H_
// Any code that actually runs any python logic should include this.
// This header pulls in the actual python includes and also defines some handy
// macros and functions for wo... | 2,642 |
30,023 | <filename>homeassistant/components/locative/const.py<gh_stars>1000+
"""Const for Locative."""
DOMAIN = "locative"
| 41 |
1,420 | /*
*
* Copyright 2016 Netflix, 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 ap... | 508 |
1,463 | #!/usr/bin/env python
#
# Copyright 2007 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 o... | 5,262 |
651 | package org.spongycastle.util.io.test;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.security.SecureRandom;
import org.spongycastle.util.io.BufferingOutputStream;
import org.spongycastle.util.test.SimpleTest;
public class BufferingOutputStreamTest
extends SimpleTest
{
public S... | 768 |
348 | <gh_stars>100-1000
{"nom":"Vayres","circ":"2ème circonscription","dpt":"Haute-Vienne","inscrits":587,"abs":267,"votants":320,"blancs":15,"nuls":12,"exp":293,"res":[{"nuance":"COM","nom":"<NAME>","voix":159},{"nuance":"REM","nom":"<NAME>","voix":134}]} | 100 |
1,027 | <reponame>vfaronov/httpolice
import os
import sys
import httpolice.cli
if __name__ == '__main__':
args = httpolice.cli.parse_args(sys.argv)
import afl
while afl.loop(100):
httpolice.cli.run_cli(args, sys.stdout, sys.stderr)
# As suggested by python-afl docs.
os._exit(0) # pylint: d... | 153 |
12,278 | <filename>libs/numeric/ublas/benchmarks/benchmark.hpp<gh_stars>1000+
//
// Copyright (c) 2018 <NAME>
// All rights reserved.
//
// This file is part of Boost.uBLAS. It is made available under the
// Boost Software License, Version 1.0.
// (Consult LICENSE or http://www.boost.org/LICENSE_1_0.txt)
#pragma once
#include... | 507 |
686 | /*
* Copyright 2020 <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... | 1,513 |
1,664 | <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
* ... | 2,082 |
955 | <reponame>MajesticFalcon/nornir
from typing import List
from concurrent.futures import ThreadPoolExecutor
from nornir.core.task import AggregatedResult, Task
from nornir.core.inventory import Host
class SerialRunner:
"""
SerialRunner runs the task over each host one after the other without any parellelizatio... | 527 |
458 | /*
* FlatView.java
* WhirlyGlobeLib
*
* Created by <NAME> on 4/19/19.
* Copyright 2011-2019 mousebird consulting
*
* 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... | 780 |
377 | <filename>inception/inception-kb/src/main/java/de/tudarmstadt/ukp/inception/kb/querybuilder/Queries.java
/*
* Licensed to the Technische Universität Darmstadt under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright owners... | 1,401 |
2,103 | """Unit tests for h/atom.py."""
from datetime import datetime, timedelta
from unittest import mock
import pytest
from h import models
from h.feeds import atom
def _annotation(**kwargs):
args = {
"userid": "acct:<EMAIL>",
"created": datetime.utcnow(),
"updated": datetime.utcnow(),
... | 2,476 |
768 | <filename>app/src/main/java/tellh/com/gitclub/model/sharedprefs/AccountPrefs.java<gh_stars>100-1000
package tellh.com.gitclub.model.sharedprefs;
import android.content.Context;
import android.content.SharedPreferences;
import android.text.TextUtils;
import com.google.gson.Gson;
import tellh.com.gitclub.model.entity.... | 866 |
1,056 | <reponame>timfel/netbeans
/*
* 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.... | 536 |
6,224 | /*
* Copyright (c) 2021 STMicroelectronics
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <kernel.h>
#include <device.h>
#include <string.h>
#include <drivers/flash.h>
#include <init.h>
#include <soc.h>
#include "flash_stm32.h"
bool flash_stm32_valid_range(const struct device *dev, off_t offset,
uin... | 1,874 |
1,266 | <gh_stars>1000+
// Copyright (c) 2009-2020 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <blockindex.h>
/**
* Turn the lowest '1' bit in the binary representation of a number into a '0'.
*/
s... | 1,017 |
6,584 | <filename>wasm/src/graphs.h
#ifndef OPA_GRAPHS_H
#define OPA_GRAPHS_H
#include "value.h"
opa_value *builtin_graph_reachable(opa_value *graph, opa_value *initial);
#endif
| 77 |
4,071 | /*
* \file batch_normalization_op_test.cc
* \brief The batch normalization op test unit
*/
#include "gtest/gtest.h"
#include <thread>
#include "blaze/test/operator/operator_test_common.h"
namespace blaze {
TEST(TestBatchNormalization, TestCPU) {
std::vector<std::string> output_str;
output_str.push_back("outp... | 265 |
2,912 | """
Tests primitive encoders and decoders.
"""
import ctypes
from .helpers import encdec_factory
from weld.encoders.primitives import PrimitiveWeldEncoder, PrimitiveWeldDecoder
from weld.types import *
encdec = encdec_factory(PrimitiveWeldEncoder, PrimitiveWeldDecoder)
def test_i8_encode():
encdec(-1, I8())
de... | 568 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.