max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
478 | /*
Copyright (c) 2014 Aerys
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, publish, distribute,
sublicens... | 5,719 |
1,770 | package io.prometheus.client.dropwizard.samplebuilder;
import io.prometheus.client.Collector;
import org.junit.Test;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import static org.junit.Assert.assertEquals;
public class CustomMappingSa... | 3,750 |
4,416 | <reponame>dvlpsh/leetcode-1
class Solution(object):
def canReorderDoubled(self, A):
"""
:type A: List[int]
:rtype: bool
"""
v_map = {}
A.sort(key=lambda x: abs(x))
for n in A:
v_map[n] = v_map.get(n, 0) + 1
for n in A:
if v_map[... | 448 |
1,738 | <reponame>brianherrera/lumberyard
/*
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
* its licensors.
*
* For complete copyright and license terms please see the LICENSE at the root of this
* distribution (the "License"). All use of this software is governed by the License,
* or, if p... | 680 |
3,168 | # code adapted from:
# https://github.com/kakaobrain/fast-autoaugment
# https://github.com/rpmcruz/autoaugment
import math
import random
import numpy as np
from collections import defaultdict
import PIL, PIL.ImageOps, PIL.ImageEnhance, PIL.ImageDraw
from PIL import Image
random_mirror = True
RESAMPLE_MODE=Image.BICU... | 6,408 |
1,447 | <gh_stars>1000+
# Copyright (c) 2017-2020 <NAME>.
# Author: <NAME>
# Email: <EMAIL>
# Update: 2020 - 6 - 16
import torch
import torch.nn as nn
import torch.nn.functional as F
from ..Model import SuperResolution
from ..Ops.Discriminator import PatchGAN
from ..Ops.Loss import DiscriminatorLoss, GeneratorLoss, VggFe... | 3,222 |
1,779 | //
// Copyright 2019 Google 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 or agreed to ... | 443 |
571 | # 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
# d... | 2,662 |
466 | package com.sqisland.friendspell.util;
import android.content.Context;
import android.graphics.drawable.Drawable;
import android.text.SpannableString;
import android.text.style.ForegroundColorSpan;
import android.widget.TextView;
import java.util.Locale;
public abstract class ViewUtil {
public static CharSequence ... | 478 |
5,964 | <reponame>wenfeifei/miniblink49
// Copyright (c) 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef HTMLNames_h
#define HTMLNames_h
#include "core/CoreExport.h"
#include "core/dom/QualifiedName.h"
#in... | 9,860 |
369 | /** @file
@brief Header
@date 2015
@author
Sensics, Inc.
<http://sensics.com/osvr>
*/
// Copyright 2015 Sensics, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License a... | 946 |
755 | <gh_stars>100-1000
from sick_lib import func as renamed_func, GLOBAL
from other_lib import *
renamed_func(20, 30)
print("GLOBAL: " + str(GLOBAL))
func1()
func2("hello")
print(VAR)
| 74 |
32,544 | package com.baeldung.ejbspringcomparison.ejb.stateful;
import java.util.ArrayList;
import java.util.List;
import javax.ejb.Stateful;
@Stateful
public class ShoppingCartEJB implements ShoppingCartEJBRemote {
private String name;
private List<String> shoppingCart;
public ShoppingCartEJB() {
shoppi... | 252 |
5,168 | <reponame>Olalaye/MegEngine
/**
* \file dnn/src/x86/elemwise/sse_util/sse_util.cpp
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under... | 7,550 |
309 | # Copyright 2019 RedHat 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 ... | 803 |
17,275 | /*
* The MIT License
*
* Copyright (c) 2004-2010, Sun Microsystems, Inc., <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, including without limitation the... | 2,742 |
831 | /*
* Copyright (C) 2017 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... | 1,562 |
1,511 | <filename>tests/cluecode/data/ics/opencv-cxcore-src/cxutils.cpp
// Intel License Agreement
// For Open Source Computer Vision Library
//
// Copyright (C) 2000, Intel Corporation, all rights reserved.
// Third party copyrights are property of their respective owners.
//
// Redistrib... | 585 |
1,536 | def logging_finish(self):
from .results import result_todf
# save the results
self = result_todf(self)
return self
| 50 |
316 | /*
* Copyright (c) 2016, Salesforce.com, Inc.
* 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 notice,
* this list of c... | 2,577 |
537 | <reponame>arikfr/turbodbc
#include "cpp_odbc/level2/input_string_buffer.h"
#include <cstring>
namespace cpp_odbc { namespace level2 {
input_string_buffer::input_string_buffer(std::string const & data) :
data_(data.size() + 1)
{
memcpy(data_.data(), data.data(), data_.size());
}
std::size_t input_string_buffer::si... | 171 |
27,208 | <gh_stars>1000+
# This file is modified from udify, which is licensed under the MIT license:
# MIT License
#
# Copyright (c) 2019 <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 with... | 2,665 |
305 | #ifndef RECT_H_
#define RECT_H_
#include <SDL.h>
#include <math.h>
#include <stdbool.h>
#include "math/vec.h"
#include "system/stacktrace.h"
typedef enum Rect_side {
RECT_SIDE_TOP = 0,
RECT_SIDE_LEFT,
RECT_SIDE_BOTTOM,
RECT_SIDE_RIGHT,
RECT_SIDE_N
} Rect_side;
typedef struct Rect {
float x,... | 1,804 |
440 | {
"name": "leaflet-control-geocoder-demo-esbuild",
"private": true,
"scripts": {
"build": "esbuild --bundle --loader:.gif=file --loader:.png=file --outdir=dist/ main.js"
},
"dependencies": {
"leaflet": "^1.5.1",
"leaflet-control-geocoder": "^1.8.0"
},
"devDependencies": {
"esbuild": "^0.8.... | 154 |
8,980 | //
// CompositionalLayoutBackgroundSwizzler.h
// WWDC
//
// Created by <NAME> on 31/05/20.
// Copyright © 2020 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@interface CompositionalLayoutBackgroundSwizzler : NSObject
@end
NS_ASSUME_NONNULL_END
| 107 |
715 | #include <bits/stdc++.h>
using namespace std;
long long mod = (int)1e9 + 7;
#define matrix2D vector< vector<long long> >
matrix2D matrixMultiply(matrix2D &a, matrix2D &b)
{
matrix2D c (a.size(), vector< long long >(b[0].size()));
for(int i=0; i<a.size(); i++)
{
for(int j=0; j<b[0].size(); j++)
... | 495 |
861 | package cn.springcloud.gray.server.resources.domain.fo;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.NotEmpty;
@ApiModel
@Data
public class ServiceOwnerFO {
@NotEmpty
@ApiModelProperty("服务id")
private... | 160 |
428 | /**
* Copyright 2008 - 2011
*
* 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 wr... | 11,224 |
527 | package com.tomandjerry.coolanim.lib.letter;
import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.animation.ValueAnimator;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.graphics.Path;
import android.graphics.Point;
import android.util.Log;
... | 1,315 |
1,040 | <reponame>Ybalrid/orbiter
/*
**-----------------------------------------------------------------------------
** File: WinMain.cpp
** Purpose: D3D sample showing DrawPrimitive functionality
** Notes:
**
** There are 3 main C++ classes that make this sample work.
**
** DDDrvMgr: Enumerates all drivers, mode... | 6,019 |
76,518 | <reponame>ixjf/Windows-driver-samples
#include "pch.h" | 24 |
325 | package com.box.l10n.mojito.service.pluralform;
import com.box.l10n.mojito.entity.Locale;
import com.box.l10n.mojito.entity.PluralFormForLocale;
import com.box.l10n.mojito.service.locale.LocaleRepository;
import com.ibm.icu.text.PluralRules;
import com.ibm.icu.util.ULocale;
import java.util.ArrayList;
import java.ut... | 837 |
335 | <reponame>Safal08/Hacktoberfest-1<gh_stars>100-1000
{
"word": "Benefit",
"definitions": [
"An advantage or profit gained from something.",
"A payment made by the state or an insurance scheme to someone entitled to receive it.",
"An event such as a concert or game that is intended to rais... | 141 |
14,668 | <filename>content/public/test/android/javatests/src/org/chromium/content_public/browser/test/ContentJUnit4RunnerDelegate.java
// Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package org.chromium.content... | 505 |
751 | <gh_stars>100-1000
/*
* Copyright (c) 2016 Cisco and/or its affiliates.
* 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... | 1,197 |
3,073 | """
(C) Copyright 2012, 10gen
This is a label on a mattress. Do not modify this file!
"""
import threading, time, traceback, warnings, sets
warnings.simplefilter( 'ignore', DeprecationWarning )
getLogsAgentVersion = "1.5.7"
class GetLogsThread( threading.Thread ):
""" When enabled pull log data from hosts. """... | 1,765 |
3,102 | #include "a.h"
#if !__building_module(b)
#error "should only get here when building module b"
#endif
const int b = 2;
| 44 |
23,220 | <gh_stars>1000+
package com.alibaba.otter.canal.protocol.exception;
import org.apache.commons.lang.exception.NestableRuntimeException;
/**
* @author zebin.xuzb @ 2012-6-20
* @version 1.0.0
*/
public class CanalClientException extends NestableRuntimeException {
private static final long serialVersionUID = -754... | 301 |
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.frontdoor.implementation;
import com.azure.core.management.Region;
import com.azure.core.util.Context;
import com.azure.resource... | 3,959 |
333 | /*** Copyright (c), The Regents of the University of California ***
*** For more information please refer to files in the COPYRIGHT directory ***/
/* reHelpers1.h - common header file for rods server and agents
*/
#ifndef RE_HELPERS1_HPP
#define RE_HELPERS1_HPP
#include "reGlobalsExtern.hpp"
#include ... | 769 |
11,356 | <filename>deps/src/boost_1_65_1/libs/config/test/boost_no_restrict_references.ipp<gh_stars>1000+
// (C) Copyright <NAME> 2009
// Use, modification and distribution are subject to 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)
... | 503 |
2,123 | <reponame>TKNopro/risc-v
require_extension('C');
MMU.store_uint32(RVC_SP + insn.rvc_swsp_imm(), RVC_RS2);
| 54 |
808 | /* Copyright (c) 2007 Massachusetts Institute of Technology
*
* 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,... | 3,895 |
1,738 | /*
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
* its licensors.
*
* For complete copyright and license terms please see the LICENSE at the root of this
* distribution (the "License"). All use of this software is governed by the License,
* or, if provided, by the license below or t... | 409 |
14,668 | // Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/sync/test/fake_server/fake_server_nigori_helper.h"
#include <string>
#include <vector>
#include "components/sync/nigori/nigori_test... | 945 |
368 | /*
Plugin-SDK (Grand Theft Auto 3) source file
Authors: GTA Community. See more here
https://github.com/DK22Pac/plugin-sdk
Do not delete this comment block. Respect others' work!
*/
#include "CTheCarGenerators.h"
PLUGIN_SOURCE_FILE
PLUGIN_VARIABLE CCarGenerator(&CTheCarGenerators::CarGeneratorArray)[1... | 1,278 |
659 | package net.steamcrafted.lineartimepicker.view;
import android.animation.Animator;
import android.animation.ValueAnimator;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.Rect;
import android.graphics.drawable.Drawabl... | 14,941 |
1,738 | <reponame>jeikabu/lumberyard<filename>dev/Code/Framework/GridMate/GridMate/Replica/Interest/InterestQueryResult.cpp
/*
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
* its licensors.
*
* For complete copyright and license terms please see the LICENSE at the root of this
* distributio... | 309 |
1,069 | import os
import cv2
import sys
import torch
import argparse
import subprocess
import numpy as np
from PIL import Image
from glob import glob
import os.path as osp
import scipy.io as io
import multiprocessing as mp
import numpy.linalg as linalg
import matplotlib.pyplot as plt
import multiprocessing.pool as mpp
from sci... | 2,404 |
1,056 | <filename>ide/xml.xdm/test/unit/src/org/netbeans/modules/xml/xdm/diff/MergeDiffTest.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 li... | 14,507 |
780 | <reponame>nity224/selenide
package integration.server;
import javax.servlet.http.Cookie;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.Set;
import static javax.servlet.http.HttpServletResponse.SC_NOT_FOUND;
import static javax... | 459 |
1,444 |
package mage.game.turn;
import java.util.UUID;
import mage.constants.PhaseStep;
import mage.game.Game;
import mage.game.events.GameEvent.EventType;
import mage.players.Player;
/**
*
* @author <EMAIL>
*/
public class CleanupStep extends Step {
public CleanupStep() {
super(PhaseStep.CLEANUP, true)... | 600 |
7,892 | /**********************************************************************
Audacity: A Digital Audio Editor
AVCodecFunctionsLoaders.cpp
<NAME>
**********************************************************************/
#include "AVCodecFunctionsLoader.h"
#include <wx/dynlib.h>
#include "AVCodecFunctions.h"
#inclu... | 462 |
711 | /*
* Copyright 2015 JBoss 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 i... | 1,475 |
522 | #include "KalmanCrop.h"
#include "../../utils/facefinder.h"
const QString KalmanCrop::shapePredictorWeightsPath =
QDir::homePath() + "/.avatarify/models/shape_predictor_5_face_landmarks.dat";
KalmanCrop::KalmanCrop() : m_dlibPredictor(shapePredictorWeightsPath), m_kalmanFilter(4, 20, 0.0001) {
m_kalmanFi... | 1,627 |
393 | <reponame>nFnK/otros-log-viewer
package pl.otros.swing.functional;
import javax.swing.*;
import java.awt.*;
import java.util.function.Function;
public class StringListCellRenderer<E> implements ListCellRenderer<E> {
private final Function<E,String> mapping;
private final DefaultListCellRenderer defaultListCellRe... | 256 |
38,047 | <gh_stars>1000+
/* Simple timer, for use in benchmark reporting. */
typedef struct {
nstime_t t0;
nstime_t t1;
} timedelta_t;
void timer_start(timedelta_t *timer);
void timer_stop(timedelta_t *timer);
uint64_t timer_usec(const timedelta_t *timer);
void timer_ratio(timedelta_t *a, timedelta_t *b, char *buf, size_t b... | 138 |
410 | <reponame>ValtoGameEngines/Blueshift-Engine<filename>Source/Runtime/Private/Platform/Posix/PlatformPosixThread.cpp
// Copyright(c) 2017 POLYGONTEK
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the Li... | 2,765 |
318 | <filename>sys/mac/mrecover.c
/* SCCS Id: @(#)mrecover.c 3.4 1996/07/24 */
/* Copyright (c) <NAME>, 1993. */
/* NetHack may be freely redistributed. See license for details. */
/* Macintosh Recovery Application */
/* based on code in util/recover.c. the significant differences are:
* -... | 12,858 |
363 | <filename>easy-batch-extensions/easy-batch-msexcel/src/main/java/org/jeasy/batch/extensions/msexcel/MsExcelRecordMapper.java
/*
* The MIT License
*
* Copyright (c) 2021, <NAME> (<EMAIL>)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated docume... | 1,190 |
488 | //! if statement without an explicit basic block as a body
#include <omp.h>
void foo(int j)
{
int i;
int a[100];
if (j != - 1) {
#pragma omp parallel for private (i)
for (i = 0; i <= 99; i += 1) {
a[i] = a[i] + 1;
}
}
}
| 119 |
340 | from .exceptions import Auth0Error, RateLimitError, TokenValidationError
| 18 |
1,979 | <gh_stars>1000+
package com.qihoo.qsql.metadata.utils;
import com.qihoo.qsql.metadata.MetadataParams;
import java.io.File;
import java.io.FileInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
import java.util.Pr... | 1,159 |
8,323 | from sympy.testing.pytest import raises
from sympy import (
Array, ImmutableDenseNDimArray, ImmutableSparseNDimArray,
MutableDenseNDimArray, MutableSparseNDimArray, sin, cos,
simplify, Matrix
)
from sympy.abc import x, y
array_types = [
ImmutableDenseNDimArray,
ImmutableSparseNDimArray,
Mutable... | 724 |
5,823 | // Copyright 2013 The Flutter 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 io.flutter.app;
import androidx.annotation.CallSuper;
import com.google.android.play.core.splitcompat.SplitCompatApplication;
import io.flutter.Fl... | 611 |
791 | <reponame>aruniiird/zig
#include <sys/membarrier.h>
#include <semaphore.h>
#include <signal.h>
#include <string.h>
#include "pthread_impl.h"
#include "syscall.h"
static void dummy_0(void)
{
}
static void dummy_1(pthread_t t)
{
}
weak_alias(dummy_0, __tl_lock);
weak_alias(dummy_0, __tl_unlock);
weak_alias(dummy_1, __... | 882 |
1,253 | #include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double dl;
#define mem(x,val) memset((x),(val),sizeof(x))
#define pb push_back
#define mod 1000000007
int subsetXOR(int arr[],int n,int k)
{
int max_ele=*max_element(arr,arr+n);
int m=(1<<(int)log2(max_ele)+1)-1;
int dp[n+1][m+1];
... | 469 |
764 | {"symbol": "XGG","address": "0x06B179e292f080871825beD5D722162fD96B4c95","overview":{"en": ""},"email": "","website": "http://10x.gg/","state": "NORMAL","links": {"blog": "https://10xgg.medium.com/10x-gg-in-depth-explanation-81c868b2721a","twitter": "https://twitter.com/10xdotgg","telegram": "","github": ""}} | 128 |
663 | <reponame>mchelen-gov/integrations-core
# (C) Datadog, Inc. 2018-present
# All rights reserved
# Licensed under a 3-clause BSD style license (see LICENSE)
import random
import time
from typing import Any, Dict, List, Optional, Sequence, Set, Tuple, cast
import click
from .....fs import basepath, chdir
from .....subpr... | 8,514 |
777 | // Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <stddef.h>
#include <stdint.h>
#include "base/bind.h"
#include "base/bind_helpers.h"
#include "base/macros.h"
#include "base/synchronization/con... | 4,008 |
575 | <filename>chrome/browser/ui/cocoa/screentime/history_bridge_unittest.cc
// 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 "chrome/browser/ui/cocoa/screentime/history_bridge.h"
#include "base/fil... | 1,831 |
483 | {
"bundles": {
"MediaMonks\\SonataMediaBundle\\MediaMonksSonataMediaBundle": ["all"]
},
"env": {
"MEDIA_REDIRECT_URL": "https://media-redirect-url/"
},
"copy-from-recipe": {
"config/": "%CONFIG_DIR%/",
"src/": "%SRC_DIR%/"
}
}
| 148 |
2,167 | from random import choice, randint
role = "role"
location = "location"
LOC = ["NYC", "London", "Berlin"]
USERS = {
"alice": {role: "employee", location: LOC[0]},
"bhavik": {role: "employee", location: LOC[1]},
"cora": {role: "employee", location: LOC[2]},
"deirdre": {role: "accountant", location: LOC... | 714 |
307 | import numpy as np
from plotoptix import TkOptiX
from plotoptix.utils import make_color
from plotoptix.materials import m_plastic
def trefoil(u, v, r):
x = r * np.sin(3 * u) / (2 + np.cos(v))
y = r * (np.sin(u) + 2 * np.sin(2 * u)) / (2 + np.cos(v + np.pi * 2 / 3))
z = r / 2 * (np.cos(u) - 2 * np.cos(2 * u... | 1,260 |
2,151 | <reponame>zipated/src
// Copyright 2017 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 THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_REPORT_BODY_H_
#define THIRD_PARTY_BLINK_RENDERER_CORE_FRAME_REPORT_BODY_H_
#include ... | 234 |
393 | /**
* This file has no copyright assigned and is placed in the Public Domain.
* This file is part of the mingw-w64 runtime package.
* No warranty is given; refer to the file DISCLAIMER.PD within this package.
*/
#ifndef _INC_FUNCTIONDISCOVERYKEYS
#define _INC_FUNCTIONDISCOVERYKEYS
#include <propkeydef.h>
DEFINE_P... | 189 |
1,040 | // Copyright (c) <NAME>
// Licensed under the MIT License
#define STRICT 1
#define OAPI_IMPLEMENTATION
#include "CamAPI.h"
#include "Camera.h"
extern Camera *g_camera;
// ======================================================================
// class ExternalCameraControl
ExternalCameraControl::ExternalCameraContro... | 480 |
335 | <reponame>Safal08/Hacktoberfest-1<filename>D/Disorder_noun.json
{
"word": "Disorder",
"definitions": [
"A state of confusion.",
"The breakdown of peaceful and law-abiding public behaviour.",
"An illness that disrupts normal physical or mental functions."
],
"parts-of-speech": "No... | 126 |
1,428 | <reponame>saurabhcommand/Hello-world<filename>Python/hello-warudo.py
print("Hello <NAME>!") | 34 |
2,150 | <filename>examples/crash_detection/crash_utils/model.py
# Copyright (c) Facebook, Inc. and its affiliates.
# This source code is licensed under the MIT license found in the
# LICENSE file in the root directory of this source tree.
import torch
import torch.utils.model_zoo as model_zoo
from torch import nn
from torch... | 755 |
868 | // Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
//
// Licensed under the BSD 3-Clause License (the "License"); you may not use this
// file except in compliance with the License. You may obtain a copy of the
// License at
//
// https://opensource.org/licenses/BSD-3-Clause
//
// Unless req... | 618 |
3,552 | <gh_stars>1000+
/*
* Copyright 2013-2020 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unle... | 939 |
19,438 | <filename>Userland/Utilities/ps.cpp
/*
* Copyright (c) 2018-2021, <NAME> <<EMAIL>>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <AK/QuickSort.h>
#include <LibCore/ArgsParser.h>
#include <LibCore/ProcessStatisticsReader.h>
#include <LibCore/System.h>
#include <LibMain/Main.h>
#include <unistd.h>
ErrorOr<i... | 2,693 |
322 | /*
* 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")... | 2,325 |
372 | /*
* 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 under t... | 3,818 |
737 | from lyrebird import application
from .. import checker
class CheckerEventHandler:
def __call__(self, channel, *args, **kw):
def func(origin_func):
if not checker.scripts_tmp_storage.get(checker.TYPE_EVENT):
checker.scripts_tmp_storage[checker.TYPE_EVENT] = []
chec... | 511 |
819 | /*
Copyright 2017 Google 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 or agreed to in ... | 611 |
516 | #pragma once
#include "DataDirEntryWrapper.h"
/*
typedef struct WIN_CERTIFICATE {
DWORD dwLength;
WORD wRevision;
WORD wCertificateType;
BYTE bCertificate[];
} WIN_CERTIFICATE, *LPWIN_CERTIFICATE;
*/
class SecurityDirWrapper : public DataDirEntryWrapper
{
public:
enum SecurityDirFID {
NONE = FIE... | 510 |
1,144 | // SPDX-License-Identifier: GPL-2.0+
/*
* Copyright 2017 Google, Inc
*/
#include <common.h>
#include <dm.h>
#include <wdt.h>
#include <asm/state.h>
static int sandbox_wdt_start(struct udevice *dev, u64 timeout, ulong flags)
{
struct sandbox_state *state = state_get_current();
state->wdt.counter = timeout;
state... | 469 |
799 | <reponame>diCagri/content
"""Base Integration for Cortex XSOAR - Unit Tests file
Pytest Unit Tests: all funcion names must start with "test_"
More details: https://xsoar.pan.dev/docs/integrations/unit-testing
MAKE SURE YOU REVIEW/REPLACE ALL THE COMMENTS MARKED AS "TODO"
You must add at least a Unit Test function f... | 9,338 |
938 | {
"parent": "tconstruct:block/foundry/controller/alloyer",
"textures": {
"front": "tconstruct:block/foundry/controller/alloyer_active"
}
}
| 56 |
473 | <reponame>pingjuiliao/cb-multios<filename>challenges/XStore/src/tr.c
/*
* Copyright (c) 2015 Kaprica Security, Inc.
*
* 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,... | 2,090 |
1,187 | #import <MAMapKit/MAOverlayRenderer.h>
@interface AMapOverlay : UIView <MAOverlay>
- (MAOverlayRenderer *)renderer;
@end
| 51 |
415 | <gh_stars>100-1000
{
"Comment": "comment -- ed25519/256 by putty Euw2avMXw89WTiDY",
"FingerprintSHA256": "J86amzfj3uUtabH4liKQb8nbTB79L2Y6rOJtxbLeghU",
"FingerprintMD5": "75:d9:f3:44:09:0f:9f:81:05:3a:40:db:e7:ed:68:31",
"Type": "ed25519",
"Bits": 256,
"Encrypted": true,
"command": "puttygen... | 280 |
4,054 | // Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.search.grouping.result;
import com.yahoo.search.Result;
import com.yahoo.search.grouping.GroupingRequest;
/**
* This class represents a labeled group list in the grouping result model. It is con... | 240 |
486 | // test: UnicodeCodePointEscapes
/*
* Copyright (C) 2019-2021 Google, LLC.
*
* License: https://opensource.org/licenses/BSD-3-Clause
*
* Redistribution and use in source and binary forms, with or without modification, are permitted
* provided that the following conditions are met:
*
* 1. Redistributions of sour... | 1,524 |
5,169 | <reponame>Gantios/Specs<gh_stars>1000+
{
"name": "AlphabetSlider",
"version": "3.0.7",
"summary": "Provides an incremental slider for arbitary string values.",
"description": "Provides an incremental slider, allowing the user to select from any arbitary values of your choosing--alphabet letters, numbers, values... | 409 |
373 | /*
* #%L
* ACS AEM Commons Bundle
* %%
* Copyright (C) 2015 Adobe
* %%
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless... | 1,654 |
2,338 | <filename>compiler-rt/test/asan/TestCases/Linux/pthread_create_from_constructor.cpp
// Test that ASan doesn't deadlock in __interceptor_pthread_create called
// from dlopened shared library constructor. The deadlock happens only in shared
// ASan runtime with recent Glibc (2.23 fits) when __interceptor_pthread_create
/... | 505 |
388 | {
"name": "simulacra",
"description": "Data-binding function for the DOM.",
"version": "2.2.0",
"license": "MIT",
"author": {
"name": "daliwali",
"email": "<EMAIL>",
"url": "http://daliwa.li"
},
"homepage": "http://simulacra.js.org/",
"repository": {
"type": "git",
"url": "<EMAIL>:da... | 1,124 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.