max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
402 | #
# filter_database.py
#
# Look through a COCO-ct database and find images matching some crtieria, writing
# a subset of images and annotations to a new file.
#
#%% Constants and imports
import os
import json
import math
#%% Configuration
baseDir = r'd:\temp\snapshot_serengeti_tfrecord_generation'
imageBaseDir = o... | 970 |
3,573 | <reponame>ex0ample/cryptopp<gh_stars>1000+
#include <altivec.h>
int main(int argc, char* argv[])
{
#if defined(__ibmxl__) || (defined(_AIX) && defined(__xlC__))
__vector unsigned int x = {1,2,3,4};
x=__vshasigmaw(x, 0, 0);
__vector unsigned long long y = {1,2};
y=__vshasigmad(y, 0, 0);
#elif def... | 393 |
1,056 | /*
* 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 ... | 450 |
312 | <filename>solutions/MultilingualPages/SPFxExt/config/config.json
{
"$schema": "https://developer.microsoft.com/json-schemas/spfx-build/config.2.0.schema.json",
"version": "2.0",
"bundles": {
"multilingual-extension-application-customizer": {
"components": [
{
"entrypoint": "./lib/exten... | 441 |
315 | /*
* testpalette.c
*
* A simple test of runtime palette modification for animation
* (using the SDL_SetPalette() API).
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
/* This isn't in the Windows headers */
#ifndef M_PI
#define M_PI 3.14159265358979323846
#endif
#include "SDL.h"... | 4,502 |
18,396 | <reponame>attenuation/srs<filename>trunk/3rdparty/srt-1-fit/srtcore/channel.h
/*
* SRT - Secure, Reliable, Transport
* Copyright (c) 2018 Haivision Systems Inc.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, Yo... | 2,000 |
412 | <gh_stars>100-1000
inline int foo()
{
int *p;
return *p;
}
int main()
{
foo();
return 0;
}
| 48 |
1,103 | from recon.core.module import BaseModule
from recon.mixins.search import GoogleWebMixin
import urllib
import re
class Module(BaseModule, GoogleWebMixin):
meta = {
'name': 'Google Hostname Enumerator',
'author': '<NAME> (@LaNMaSteR53)',
'description': 'Harvests hosts from Google.com by usin... | 1,219 |
771 | import lombok.extern.slf4j.Slf4j;
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
/**
* 密码加密测试
*
* @author tycoding
* @date 2019-05-29
*/
@Slf4j
public class PasswordEncoderTest {
private static BCryptPasswordEncoder passwordEncoder = new BCryptPasswordEncoder();
public static v... | 356 |
339 | <filename>integration/dataservice-hosting-tests/tests-integration/tests/src/test/java/org/wso2/ei/dataservice/integration/test/samples/RDBMSSampleTestCase.java
/*
*Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
*
*WSO2 Inc. licenses this file to you under the Apache License,
*Version 2.0 ... | 2,686 |
421 | <gh_stars>100-1000
"""Restart containers associated with Dusty apps or services.
Upon restart, an app container will execute the command specified
in its `commands.always` spec key. Restarting app containers will
also perform a NFS mount of repos needed for restarted containers,
using your current repo override settin... | 358 |
387 | #ifndef _CPP_CSTD_STRING_H_
#define _CPP_CSTD_STRING_H_
#include "../export.h"
#include <string.h>
DLLEXPORT void* cstd_memcpy(void* buf1, const void* buf2, size_t n)
{
return memcpy(buf1, buf2, n);
}
#endif | 116 |
1,962 | package com.bolingcavalry.service.impl;
import com.bolingcavalry.service.MessageService;
import kafka.javaapi.producer.Producer;
import kafka.producer.KeyedMessage;
import kafka.producer.ProducerConfig;
import org.springframework.stereotype.Service;
import javax.annotation.PostConstruct;
import java.util.Properties;
... | 724 |
2,291 | {
"id" : 371,
"status" : "Invalid",
"summary" : "How to create overlayItem by click on map?",
"labels" : [ "Type-Defect", "Priority-Medium" ],
"stars" : 0,
"commentCount" : 3,
"comments" : [ {
"id" : 0,
"commenterId" : 462469271112654667,
"content" : "Hello\r\nI'm developing an android program... | 517 |
1,855 | <filename>SevenZip/CPP/7zip/Compress/LzfseDecoder.cpp
// LzfseDecoder.cpp
/*
This code implements LZFSE data decompressing.
The code from "LZFSE compression library" was used.
2018 : <NAME> : BSD 3-clause License : the code in this file
2015-2017 : Apple Inc : BSD 3-clause License : original "LZFSE compressio... | 11,272 |
589 | package rocks.inspectit.agent.java.core.disruptor.impl;
import java.util.Map;
import javax.annotation.PostConstruct;
import org.springframework.beans.factory.BeanInitializationException;
import org.springframework.beans.factory.annotation.Autowired;
import rocks.inspectit.agent.java.config.IConfigurationStorage;
im... | 501 |
10,608 | <gh_stars>1000+
""" Official evaluation script for CUAD dataset. """
import argparse
import json
import re
import string
import sys
import numpy as np
IOU_THRESH = 0.5
def get_jaccard(prediction, ground_truth):
remove_tokens = [".", ",", ";", ":"]
for token in remove_tokens:
ground_truth = ground... | 3,046 |
537 | <gh_stars>100-1000
/*!
* @file
* Casting strings to tuples of primitive types including std::array.
*
* This file is a part of easyLambda(ezl) project for parallel data
* processing with modern C++ and MPI.
*
* @copyright <NAME> <<EMAIL>> 2015-2016
* Distributed under the Boost Software License, Version 1.0.
*... | 1,253 |
423 | <reponame>karanjot21/meter
// Copyright 2017 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 app... | 4,164 |
1,006 | /****************************************************************************
* arch/arm/src/phy62xx/bus_dev.h
*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ow... | 2,442 |
5,250 | /* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed... | 703 |
1,350 | // Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.
package com.azure.resourcemanager.loganalytics.models;
import com.azure.resourcemanager.loganalytics.fluent.models.AvailableServiceTierInner;
/** An immutable cl... | 652 |
490 | #include <Halide.h>
#include "align.h"
#include "merge.h"
#include "finish.h"
namespace {
class HdrPlusPipeline : public Halide::Generator<HdrPlusPipeline> {
public:
// 'inputs' is really a series of raw 2d frames; extent[2] specifies the count
Input<Halide::Buffer<uint16_t>> inputs{"inputs",... | 695 |
310 | <reponame>dreeves/usesthis
{
"name": "Lifetime Folding Chair",
"description": "A folding chair.",
"url": "https://www.costco.com/Lifetime-Folding-Chair%2C-4-pack.product.11482116.html"
}
| 79 |
585 | <reponame>jinwyp/image-background-remove-tool
"""
Name: Pre-processing class file
Description: This file contains pre-processing classes.
Version: [release][3.2]
Source url: https://github.com/OPHoperHPO/image-background-remove-tool
Author: Anodev (OPHoperHPO)[https://github.com/OPHoperHPO] .
License: Apache License 2.... | 8,759 |
333 | /*
-------------------------------------------------------------------------
CxxTest: A lightweight C++ unit testing library.
Copyright (c) 2008 Sandia Corporation.
This software is distributed under the LGPL License v2.1
For more information, see the COPYING file in the top CxxTest directory.
Under the terms of C... | 5,371 |
519 | # BSD 3-Clause License; see https://github.com/scikit-hep/awkward-1.0/blob/main/LICENSE
from __future__ import absolute_import
import pytest # noqa: F401
import numpy as np # noqa: F401
import awkward as ak # noqa: F401
def test():
array = ak.Array(
[
[{"x": 0.0, "y": []}, {"x": 1.1, "y":... | 1,511 |
1,006 | /****************************************************************************
* libs/libc/misc/lib_mkfifo.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 owner... | 786 |
454 | package com.waylau.spring.boot.security.repository;
import org.springframework.data.jpa.repository.JpaRepository;
import com.waylau.spring.boot.security.domain.User;
/**
* 用户仓库.
*
* @since 1.0.0 2017年3月2日
* @author <a href="https://waylau.com"><NAME></a>
*/
public interface UserRepository extends J... | 164 |
892 | {
"schema_version": "1.2.0",
"id": "GHSA-7983-c95j-wcr3",
"modified": "2022-05-02T04:00:25Z",
"published": "2022-05-02T04:00:25Z",
"aliases": [
"CVE-2009-4997"
],
"details": "gnome-power-manager 2.27.92 does not properly implement the lock_on_suspend and lock_on_hibernate settings for locking the scre... | 461 |
501 | /*
* Decode tests.
*
* Test that cover aspects of the front-end instruction and uop deliver
* such as decoding, DSB, LSD, etc.
*/
#include "benchmark.hpp"
#include "util.hpp"
#include "boost/preprocessor/repetition/repeat_from_to.hpp"
extern "C" {
/* misc benches */
bench2_f decode33334;
bench2_f decode333322;... | 1,631 |
530 | import pytest
from tartiflette import Resolver, create_engine
_SDL = """
type Entry {
id: Int!
name: String!
}
input SubSubEntry {
name: String!
}
input SubEntryInput {
name: String!
subSubEntry: SubSubEntry
}
input AddEntryInput {
clientMutationId: String
subEntry1: SubEntryInput!
subEntry2: SubEn... | 1,134 |
336 | <reponame>eik00d/CANSploit
load_modules = {
'hw_CAN232': {'port': '/dev/cu.usbmodem1421', 'speed': '500KBPS', 'serial_speed': 115200, 'debug': 3},
'mod_stat': {'debug': 0},
}
actions = [
{'hw_CAN232': {'action': 'read', 'pipe': 1}},
{'mod_stat': {'pipe': 1}},
]
| 132 |
903 | <gh_stars>100-1000
package php.runtime.reflection;
import php.runtime.Memory;
import php.runtime.common.HintType;
import php.runtime.common.Messages;
import php.runtime.common.Modifier;
import php.runtime.env.Context;
import php.runtime.env.Environment;
import php.runtime.env.TraceInfo;
import php.runtime.exceptions.C... | 6,137 |
778 | <filename>libcxx/test/std/utilities/time/time.hms/time.hms.members/minutes.pass.cpp
//===----------------------------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-Li... | 907 |
7,676 | <reponame>Infi-zc/horovod
// Copyright 2019 Uber Technologies, Inc. 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... | 905 |
301 | //******************************************************************
//
// Copyright 2014 Intel Mobile Communications GmbH All Rights Reserved.
//
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except ... | 4,781 |
335 | {
"word": "Worthy",
"definitions": [
"Having or showing the qualities that deserve the specified action or regard.",
"Deserving effort, attention, or respect.",
"Good enough; suitable.",
"Characterized by good intent but lacking in humour or imagination."
],
"parts-of-spe... | 119 |
468 | <reponame>vinjn/glintercept
/*=============================================================================
GLIntercept - OpenGL intercept/debugging tool
Copyright (C) 2006 <NAME>
Licensed under the MIT license - See Docs\license.txt for details.
=================================================================... | 8,470 |
3,102 | // Make sure that arguments that begin with @ are left as is in the argument
// stream, and also that @file arguments continue to be processed.
// RUN: echo "-D FOO" > %t.args
// RUN: %clang -rpath @executable_path/../lib @%t.args %s -### 2>&1 | FileCheck %s
// CHECK: "-D" "FOO"
// CHECK: "-rpath" "@executable_path/..... | 114 |
1,837 | //========================================================================
//Copyright 2007-2011 <NAME> <EMAIL>
//------------------------------------------------------------------------
//Licensed under the Apache License, Version 2.0 (the "License");
//you may not use this file except in compliance with the License.
... | 1,547 |
854 | __________________________________________________________________________________________________
sample 152 ms submission
class MyHashSet:
def __init__(self):
"""
Initialize your data structure here.
"""
self.data = set()
def add(self, key):
self.data.add(key)
de... | 1,328 |
348 | {"nom":"Bolazec","circ":"6ème circonscription","dpt":"Finistère","inscrits":156,"abs":76,"votants":80,"blancs":17,"nuls":7,"exp":56,"res":[{"nuance":"REM","nom":"<NAME>","voix":32},{"nuance":"LR","nom":"<NAME>","voix":24}]} | 90 |
782 | /*
* Copyright (c) 2021, <NAME>. All Rights Reserved.
*
* This file is part of BoofCV (http://boofcv.org).
*
* 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... | 914 |
1,110 | from contextlib import contextmanager
from unittest import skipIf, skipUnless
import os
import io
import socket
import sys
from sphinx.application import Sphinx
from sphinx.errors import SphinxWarning
try:
import enchant
except ImportError:
enchant = None
import cms
from cms.test_utils.testcases import CMST... | 1,625 |
852 | #ifndef TkDetLayers_Phase2EndcapRing_h
#define TkDetLayers_Phase2EndcapRing_h
#include "TrackingTools/DetLayers/interface/GeometricSearchDet.h"
#include "Utilities/BinningTools/interface/PeriodicBinFinderInPhi.h"
#include "SubLayerCrossings.h"
#include "DataFormats/GeometrySurface/interface/BoundDisk.h"
/** A concret... | 1,471 |
2,195 | from aim.sdk import Repo
from aim.web.api.runs.utils import get_run_props
from performance_tests.utils import timing
@timing()
def collect_runs_data(query):
repo = Repo.default_repo()
runs = repo.query_runs(query)
runs_dict = {}
for run_trace_collection in runs.iter_runs():
run = run_trace_col... | 823 |
11,496 | <gh_stars>1000+
{
"title": "Launcher",
"description": "Launcher settings.",
"jupyter.lab.shortcuts": [
{
"command": "launcher:create",
"keys": [""],
"selector": "body"
}
],
"properties": {},
"additionalProperties": false,
"type": "object"
}
| 122 |
739 | <gh_stars>100-1000
package org.fxmisc.richtext.keyboard.navigation;
import javafx.stage.Stage;
import org.fxmisc.richtext.InlineCssTextAreaAppTest;
import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.Timeout;
import static javafx.scene.input.KeyCode.DOWN;
import static javafx.scene.input.KeyCode.UP;
... | 584 |
879 | package org.zstack.utils.logging;
/**
* Goals:
* 1. log4j interface
* 2. two category logs: (1) ordinary log outputting to primary log file (2) supporting log that should be present to
* customer or support team saves to another file
* 3. use gson to attach parameters to log
* 4. cooperate with EventKit sys... | 279 |
435 | {
"copyright_text": null,
"description": "GPUs are typically used to accelerate deep learning models, but they haven't been widely deployed for traditional machine learning. This talk will cover cuML's GPU based implementation of Decision Trees and Random Forest algorithms, aimed to provide 10x-50x speedup and a ne... | 351 |
1,442 | <reponame>VersiraSec/epsilon-cfw
#include <stddef.h>
#include <string.h>
/* See the "Run-time ABI for the ARM Architecture", Section 4.3.4 */
void __aeabi_memcpy(void * dest, const void * src, size_t n) {
memcpy(dest, src, n);
}
// TODO: optimize aeabi_memcpy4 to take advantage of the 4-byte alignment
void __aeabi... | 161 |
1,197 | <reponame>Plutonian/controlsfx
/**
* Copyright (c) 2018 ControlsFX
* 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
* n... | 2,903 |
367 | <reponame>SAP/cloud-commerce-spartacus-storefront
{
"$schema": "http://json-schema.org/schema",
"$id": "UserSchematics",
"title": "User Schematics",
"description": "Most of the Spartacus features require User Account feature to be properly configured.",
"type": "object",
"properties": {
"project": {
... | 444 |
453 | <filename>python/Microsoftpython/Class 12:loops/class 12:loops.py<gh_stars>100-1000
# python之中僅有兩種循環,for和while
# 以下先從for循環講起,意思為打印出name變量中每一個值
for name in ['Heisenberg', 'White', 'Walter', 'Jesse', 'Gustavo']:
print(name)
print()
# 下面range是代表index變量是從數字0至1
for index in range(0,2):
print(index)
print()
# 下面是wh... | 621 |
999 | import json
import logging
from typing import Any
from typing import Dict
from typing import Set
import botocore
from cloudaux.aws.sts import boto3_cached_conn
from repokid.exceptions import BlocklistError
from repokid.filters import Filter
from repokid.role import RoleList
from repokid.types import RepokidFilterConf... | 1,829 |
977 | <gh_stars>100-1000
package io.leangen.graphql.execution;
import io.leangen.graphql.metadata.Operation;
import io.leangen.graphql.metadata.Resolver;
import java.util.function.Consumer;
public class InvocationContext {
private final Operation operation;
private final Resolver resolver;
private final Resol... | 902 |
887 | <gh_stars>100-1000
/*
* Copyright (C) 2012 Open Source Robotics Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unle... | 3,675 |
713 | <reponame>franz1981/infinispan<filename>documentation/src/main/asciidoc/topics/code_examples/ExternalizerRegisterMultiple.java
builder.serialization()
.addAdvancedExternalizer(new Person.PersonExternalizer(),
new Address.AddressExternalizer());
| 75 |
14,668 | // 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.
#include "ash/system/tray/tray_event_filter.h"
#include "ash/capture_mode/capture_mode_util.h"
#include "ash/public/cpp/shell_window_ids.h"
#include ... | 2,271 |
19,529 | <filename>vnpy/api/nst/generator/nst_typedef.py
T_UFT_BYTE = "unsigned char"
T_UFT_WORD = "unsigned short"
T_UFT_DWORD = "unsigned long"
T_UFT_INT1 = "char"
T_UFT_INT2 = "short"
T_UFT_INT4 = "int"
T_UFT_UINT4 = "unsigned int"
T_UFT_REAL4 = "float"
T_UFT_REAL8 = "double"
T_UFT_CHAR = "char"
T_UFT_FtdcErrorIDType = "int"... | 2,229 |
4,054 | <gh_stars>1000+
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include "inspector.h"
namespace vespalib::slime {
class Symbol;
/**
* Interface used when traversing all the fields of an object value
* tagged with symbol id.
**/
struct Object... | 228 |
1,306 | <gh_stars>1000+
// Copyright © 2017-2020 Trust Wallet.
//
// This file is part of Trust. The full Trust copyright notice, including
// terms governing use, modification, and redistribution, is contained in the
// file LICENSE at the root of the source code distribution tree.
#include "Coin.h"
#include "HexCoding.h"
#i... | 4,158 |
9,425 | """
:codeauthor: <NAME> <<EMAIL>>
"""
import os
import salt.modules.oracle as oracle
from tests.support.mixins import LoaderModuleMockMixin
from tests.support.mock import MagicMock, patch
from tests.support.unit import TestCase
class OracleTestCase(TestCase, LoaderModuleMockMixin):
"""
Test cases for s... | 1,128 |
865 | <gh_stars>100-1000
from django.core.paginator import Paginator
from django.db.models import Func
class Round(Func):
function = "ROUND"
arity = 2
def paginate_list(data=None, page=1, per_page=10, limit=None):
if not data:
data = []
total = len(data)
if per_page != -1:
p = Pagina... | 260 |
809 | <gh_stars>100-1000
/**
* @file
*
* @date Nov 1, 2013
* @author: <NAME>
*/
#ifndef SOCKET_DESC_H_
#define SOCKET_DESC_H_
extern struct sock *idesc_sock_get(int idx);
#endif /* SOCKET_DESC_H_ */
| 96 |
372 | /* Editor Settings: expandtabs and use 4 spaces for indentation
* ex: set softtabstop=4 tabstop=8 expandtab shiftwidth=4: *
* -*- mode: c, c-basic-offset: 4 -*- */
/*
* Copyright © BeyondTrust Software 2004 - 2019
* All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you m... | 5,934 |
1,724 | #include <libwidget/Components.h>
#include "settings/pages/Home.h"
#include "settings/windows/MainWindow.h"
namespace Settings
{
MainWindow::MainWindow() : Window(WINDOW_RESIZABLE)
{
size({700, 500});
root()->add(Widget::titlebar(Graphic::Icon::get("cog"), "Settings"));
auto navigation_bar = root()->ad... | 224 |
454 | <reponame>zwkjhx/vertx-zero
package io.vertx.up.uca.rs.regular;
import io.vertx.up.atom.Rule;
import io.vertx.up.exception.WebException;
import java.util.Collection;
public interface Ruler {
static Ruler get(final String type) {
return Pool.RULERS.get(type);
}
static WebException verify(final Co... | 573 |
338 | <filename>ezyfox-server-core/src/test/java/com/tvd12/ezyfoxserver/testing/command/EzyAppSetupImplTest.java
package com.tvd12.ezyfoxserver.testing.command;
import org.testng.annotations.Test;
import com.tvd12.ezyfoxserver.EzySimpleApplication;
import com.tvd12.ezyfoxserver.app.EzyAppRequestController;
import com.tvd12... | 366 |
515 | <reponame>zenglongGH/spresense
/*
* Copyright 2015-2018 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.... | 1,000 |
3,799 | /*
* Copyright (C) 2011 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... | 4,990 |
778 | <filename>applications/SolidMechanicsApplication/custom_conditions/boundary_condition.hpp
//
// Project Name: KratosSolidMechanicsApplication $
// Created by: $Author: JMCarbonell $
// Last modified by: $Co-Author: $
// Date: $Date: A... | 6,154 |
2,260 | """Finger tree implementation and application examples.
A finger tree is a purely functional data structure used in
efficiently implementing other functional data structures. A
finger tree gives amortized constant time access to the "fingers"
(leaves) of the tree, where data is stored, and the internal
nodes are label... | 3,244 |
602 | import matplotlib.pyplot as plt
from scipy.stats import beta, poisson, norm
import numpy as np
import pymc3 as pm
import arviz as az
from functools import lru_cache
def plot_betadist_pdf(a, b):
b = beta(a, b)
x = np.linspace(0, 1, 1000)
pdf = b.pdf(x)
plt.plot(x, pdf)
def coin_flip_data():
retur... | 761 |
948 | /*
* Copyright (c) 2016, Zolertia - http://www.zolertia.com
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notic... | 1,667 |
1,772 | <filename>dojo/db_migrations/0123_scan_type.py<gh_stars>1000+
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('dojo', '0122_cobaltio_product'),
]
operations = [
migrations.AddField(
model_name='test',
name='scan_t... | 181 |
522 | package algs.example.convexhull.imageBound;
import java.io.File;
import java.io.FileNotFoundException;
/**
* Compute convex hull and number of distinct regions for given sample
* ASCII image.
*
* @author <NAME>
* @version 1.0, 6/15/08
* @since 1.0
*/
public class OneMore {
public static void main(String[] a... | 302 |
3,102 | <gh_stars>1000+
// RUN: %clang_cc1 -emit-llvm %s -o -
// Test case by <NAME>!
void foo(void)
{
char a[1];
int t = 1;
((char (*)[t]) a)[0][0] = 0;
}
| 79 |
892 | {
"schema_version": "1.2.0",
"id": "GHSA-6w2r-x6qc-ch2w",
"modified": "2022-04-30T18:18:11Z",
"published": "2022-04-30T18:18:11Z",
"aliases": [
"CVE-2001-1517"
],
"details": "** DISPUTED ** RunAs (runas.exe) in Windows 2000 stores cleartext authentication information in memory, which could allow attac... | 553 |
310 | <reponame>dreeves/usesthis
{
"name": "NeatReceipts",
"description": "A portable scanner and digital filing system.",
"url": "http://www.neat.com/products/neatreceipts/"
} | 66 |
4,638 | {
"name": "root",
"author": "<NAME> <<EMAIL>> (https://davidmurdoch.com)",
"private": true,
"engines": {
"node": ">=10.13.0 <=14.16.0",
"npm": ">=6.4.1"
},
"scripts": {
"build": "npm run tsc && cross-env NODE_OPTIONS=--max_old_space_size=4096 lerna run build",
"clean": "npm run tsc.clean && ... | 1,116 |
1,357 | <reponame>JonyFang/MTHawkeye<gh_stars>1000+
//
// Copyright (c) 2014-2016, Flipboard
// All rights reserved.
//
// This source code is licensed under the license found in the LICENSE file in
// the root directory of this source tree.
//
// Created on: 2/10/15
// Created by: <NAME>
//
#import <UIKit/UIKit.h>
NS_ASSUM... | 218 |
6,224 | <filename>subsys/mgmt/osdp/src/osdp.c
/*
* Copyright (c) 2020 <NAME> <<EMAIL>>
*
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr.h>
#include <kernel.h>
#include <init.h>
#include <device.h>
#include <drivers/uart.h>
#include <sys/ring_buffer.h>
#include <logging/log.h>
#include "osdp_common.h"
LOG_MODU... | 2,988 |
4,901 | <filename>third_party/android/platform-libcore/android-platform-libcore/luni/src/main/java/org/xml/sax/ext/LexicalHandler.java<gh_stars>1000+
// LexicalHandler.java - optional handler for lexical parse events.
// http://www.saxproject.org
// Public Domain: no warranty.
// $Id: LexicalHandler.java,v 1.5 2002/01/30 21:00... | 2,756 |
351 | <reponame>DeathGOD7/Floodgate
/*
* Copyright (c) 2019-2021 GeyserMC. http://geysermc.org
*
* 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 limitati... | 974 |
451 | #include "bool.h"
/*
Big must be set equal to any very large double precision constant.
It's value here is appropriate for the Sun.
*/
#define BIG 1.0e37
/*
stdlib.h - used to define the return value of malloc() and free().
*/
#include <stdlib.h>
void
l1(m, n, a, b, toler, x, e)
int m, n;
double *a, *b, to... | 3,515 |
892 | <reponame>westonsteimel/advisory-database-github
{
"schema_version": "1.2.0",
"id": "GHSA-xpj5-4mpq-74xf",
"modified": "2022-02-18T00:01:00Z",
"published": "2022-02-11T00:00:48Z",
"aliases": [
"CVE-2022-22780"
],
"details": "The Zoom Client for Meetings chat functionality was susceptible to Zip bombin... | 409 |
348 | {"nom":"Rébénacq","circ":"4ème circonscription","dpt":"Pyrénées-Atlantiques","inscrits":546,"abs":224,"votants":322,"blancs":36,"nuls":9,"exp":277,"res":[{"nuance":"DVD","nom":"<NAME>","voix":151},{"nuance":"REM","nom":"<NAME>","voix":126}]} | 98 |
836 | /* Copyright (C) 2003 Univ. of Massachusetts Amherst, Computer Science Dept.
This file is part of "MALLET" (MAchine Learning for LanguagE Toolkit).
http://www.cs.umass.edu/~mccallum/mallet
This software is provided under the terms of the Common Public License,
version 1.0, as published by http://www.opensou... | 1,817 |
4,535 | #include <utility>
#include "base/util/catch.h"
#include "tile/lang/parser.h"
#include "tile/lang/parser.y.h"
#include "tile/lang/parser_lex.h"
#include "tile/lang/type.h"
namespace vertexai {
namespace tile {
namespace lang {
using namespace math; // NOLINT
Context parse_helper(const std::string& code, int64_t st... | 889 |
2,706 | /* FCE Ultra - NES/Famicom Emulator
*
* Copyright notice for this file:
* Copyright (C) 2002 Xodnizel
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, o... | 7,971 |
665 | """Snow Globe for Adafruit Circuit Playground express with CircuitPython """
import math
import time
from adafruit_circuitplayground.express import cpx
ROLL_THRESHOLD = 30 # Total acceleration
cpx.pixels.brightness = 0.1 # set brightness value
WHITE = (65, 65, 65)
RED = (220, 0, 0)
GREEN = (0, 220, 0)
BLUE = (0, ... | 2,067 |
2,053 | package scouter.agent.proxy;
import scouter.agent.Logger;
import scouter.agent.trace.TraceContext;
public class ElasticSearchTraceFactory {
private static IElasticSearchTracer tracer;
private static Object lock = new Object();
private static final String CLIENT = "scouter.xtra.java8.ElasticSearchTracer"... | 861 |
679 | <filename>main/connectivity/java/sdbc_postgresql/src/com/sun/star/sdbcx/comp/postgresql/PostgresqlPreparedStatement.java
/**************************************************************
*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* di... | 3,698 |
627 | /* Copyright 2019 The Chromium OS Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
/* Intel BASEBOARD-RVP USB MUX specific configuration */
#include "common.h"
#include "anx7440.h"
#include "bb_retimer.h"
#include "timer.h"
#incl... | 1,050 |
5,079 | <reponame>kokosing/hue<filename>desktop/core/ext-py/nose-1.3.7/functional_tests/test_issue120/support/some_test.py
def some_test():
pass
| 58 |
3,680 | //
// Copyright 2016 Pixar
//
// Licensed under the Apache License, Version 2.0 (the "Apache License")
// with the following modification; you may not use this file except in
// compliance with the Apache License and the following modification to it:
// Section 6. Trademarks. is deleted and replaced with:
//
// 6. Trad... | 919 |
419 | <filename>thirdparty/win/miracl/miracl_osmt/source/mrgcd.c
/***************************************************************************
*
Copyright 2013 CertiVox UK Ltd. *
... | 3,810 |
1,236 | # Copyright (c) 2017 Baidu, Inc. 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 ... | 420 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.