max_stars_count int64 301 224k | text stringlengths 6 1.05M | token_count int64 3 727k |
|---|---|---|
331 | <reponame>fakegit/Subtitles-View
package org.fordes.subview.controller;
import de.felixroske.jfxsupport.FXMLController;
import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.fxml.Initializable;
import javafx.scene.input.MouseEvent;
import javafx.scene.layout.GridPane;
import java.net.URL;
import jav... | 463 |
567 | package com.google.cloud.bigquery.utils.queryfixer.fixer;
import com.google.cloud.bigquery.utils.queryfixer.entity.FixResult;
import com.google.cloud.bigquery.utils.queryfixer.errors.NoMatchingSignatureError;
import com.google.common.collect.ImmutableSet;
import lombok.AllArgsConstructor;
import java.util.ArrayList;
... | 1,989 |
1,794 | <reponame>rvencu/lxml
"""
Simple HTTP request dumper for tests.
"""
import sys
from contextlib import contextmanager
try:
import urlparse
except ImportError:
# Python 3
import urllib.parse as urlparse
@contextmanager
def webserver(app, port=0, host=None):
"""Context manager entry point for the 'with... | 933 |
679 | /**************************************************************
*
* 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 y... | 2,905 |
921 | <filename>src/main/java/com/vladsch/md/nav/psi/util/TextMapElementType.java
// Copyright (c) 2015-2020 <NAME> <<EMAIL>> Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.vladsch.md.nav.psi.util;
import com.intellij.openapi.ui.ComboBox;
import com.vladsch.... | 1,767 |
1,444 | package mage.client.components.tray;
import java.awt.*;
import java.util.concurrent.TimeUnit;
import mage.client.MageFrame;
import org.apache.log4j.Logger;
import org.mage.plugins.card.utils.impl.ImageManagerImpl;
/**
* @author noxx
*/
public enum MageTray {
instance;
private static final Logger log = Log... | 1,928 |
3,055 | /*
Fontname: -FreeType-Logisoso-Medium-R-Normal--38-380-72-72-P-46-ISO10646-1
Copyright: Created by <NAME> with FontForge 2.0 (http://fontforge.sf.net) - Brussels - 2009
Glyphs: 96/527
BBX Build Mode: 0
*/
const uint8_t u8g2_font_logisoso26_tr[2644] U8G2_FONT_SECTION("u8g2_font_logisoso26_tr") =
"`\0\4\4\5\6... | 4,545 |
4,036 | <gh_stars>1000+
public class Test<T> {
static class Super {}
static class Sub1 extends Super {}
static class Sub2 extends Super {}
// modeled after results on Alfresco
void foo(Super lhs, Super rhs) {
if (lhs instanceof Sub1) ;
else if (rhs instanceof Sub1)
if ((lhs instanceof Sub1) || (lhs instanceof Sub2... | 502 |
1,162 | package net.simonvt.schematic.compiler;
import com.squareup.javapoet.ClassName;
import com.squareup.javapoet.FieldSpec;
import com.squareup.javapoet.MethodSpec;
import com.squareup.javapoet.TypeSpec;
import javax.lang.model.element.Modifier;
public final class WriterUtils {
private WriterUtils() {
}
public st... | 675 |
611 | //
// ObjcService.h
// ZRouterTests
//
// Created by zuik on 2018/5/23.
// Copyright © 2018 zuik. All rights reserved.
//
#import <Foundation/Foundation.h>
@protocol ObjcServiceInput
@end
@protocol ObjcServiceSubInput <ObjcServiceInput>
@end
@interface ObjcService : NSObject<ObjcServiceSubInput>
@end
@interfa... | 132 |
799 | RAW_RESPONSE = {
"lastUpdated": 1609661791534,
"handles": [
"testname"
],
"links": {
"forums": [
{
"name": "testforum",
"actorHandle": "testname",
"uid": "4671aeaf49c792689533b00664a5c3ef"
}
],
"forum... | 1,287 |
1,856 | #pragma once
#ifdef PCPP_TESTS_DEBUG
#include "Packet.h"
#endif
#include <stdint.h>
#include <stdlib.h>
namespace pcpp_tests
{
int getFileLength(const char* filename);
uint8_t* readFileIntoBuffer(const char* filename, int& bufferLength);
void printBufferDifferences(const uint8_t* buffer1, size_t buffer1Len, const ... | 406 |
10,016 | <filename>zap/src/main/java/org/zaproxy/zap/extension/ascan/filters/ScanFilter.java
/*
* Zed Attack Proxy (ZAP) and its related class files.
*
* ZAP is an HTTP/HTTPS proxy for assessing web application security.
*
* Copyright 2019 The ZAP Development Team
*
* Licensed under the Apache License, Version 2.0 (the "... | 369 |
9,715 | <reponame>Debanitrkl/MLAlgorithms
# coding:utf-8
from mla.datasets.base import *
| 35 |
3,639 | <gh_stars>1000+
package top.tangyh.lamp.model.entity.base;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHas... | 1,938 |
1,133 | <gh_stars>1000+
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Copyright 2010 California Institute of Technology. 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 obt... | 3,883 |
575 | //
// PipelineDuplexLogic.h
// DJISdkDemo
//
// Copyright © 2020 DJI. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "PipelineStatistical.h"
#import <DJISDK/DJISDK.h>
NS_ASSUME_NONNULL_BEGIN
@interface PipelineDuplexLogic : NSObject
@property (atomic) PipelineStatistical *uploadStatistical;
@... | 575 |
336 | <reponame>tomwei7/LA104
static constexpr const char* mSendStrings[] = {
"AT\r\n", "ATI\r\n", "ATD\r\n", "AT+CMGF=1\r\n", "",
"A", "B", "C", "D", "0", "1", ""
};
class CPageSend : public CPage
{
bool mSendInterval{false};
int mCurrentIndex{0};
public:
CPageSend(CApplication& app) : CPage(app)
... | 1,221 |
4,047 | <reponame>kira78/meson<gh_stars>1000+
#!/usr/bin/env python3
import os
import sys
if not os.path.isfile(sys.argv[1]):
raise Exception("Couldn't find {!r}".format(sys.argv[1]))
| 81 |
4,372 | <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 "Lic... | 998 |
849 | """
Copyright 2020 The Magma Authors.
This source code is licensed under the BSD-style license found in the
LICENSE file in the root directory of this source tree.
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES O... | 699 |
1,830 | #!/usr/bin/python
# -*- coding: UTF-8 -*-
import configparser
from common import utilities
from common.utilities import ConfigInfo
import shutil
import os
from service.tars_service import TarsService
class NodeConfigGenerator:
def __init__(self, config):
self.config = config
self.genesis_tpl_confi... | 6,285 |
325 | #include <wiz/utility/text.h>
#include <wiz/utility/path.h>
#include <wiz/utility/reader.h>
#include <wiz/utility/report.h>
#include <wiz/utility/import_manager.h>
#include <wiz/utility/source_location.h>
#include <wiz/utility/resource_manager.h>
namespace wiz {
namespace {
const char* const SourceExtensio... | 1,903 |
9,718 | #include <Arduino.h>
#include <arduino-timer.h>
#include <rpcWiFi.h>
#include <sfud.h>
#include <SPI.h>
#include "config.h"
#include "language_understanding.h"
#include "mic.h"
#include "speech_to_text.h"
#include "text_to_speech.h"
void connectWiFi()
{
while (WiFi.status() != WL_CONNECTED)
{
Serial.p... | 1,039 |
3,301 | package com.alibaba.alink.operator.common.aps;
import org.apache.flink.ml.api.misc.param.Params;
import com.alibaba.alink.operator.batch.BatchOperator;
public abstract class ApsCheckpoint {
public abstract void write(BatchOperator <?> operator, String identity, Long mlEnvId, Params params);
public abstract BatchO... | 124 |
511 | <gh_stars>100-1000
//******************************************************************
//
// Copyright 2015 Samsung Electronics All Rights Reserved.
//
//-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file e... | 5,644 |
764 | <gh_stars>100-1000
{"symbol": "MAKI","address": "0x270D09cb4be817c98e84fEffdE03D5CD45e30a27","overview":{"en": ""},"email": "","website": "https://maki.finance","state": "NORMAL","links": {"blog": "","twitter": "https://twitter.com/maki_finance","telegram": "","github": ""}} | 109 |
1,439 | /*******************************************************************************
* Copyright 2018 <NAME> http://galenframework.com
*
* 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... | 1,123 |
5,169 | <reponame>Gantios/Specs<gh_stars>1000+
{
"name": "ActionsDrawer",
"version": "0.1.1",
"summary": "A prettier alternative to action sheets.",
"swift_version": "4.2",
"description": "ActionsDrawer is built as a replacement to the standard action sheets. Action sheets provide little to no customization UI wise, ... | 339 |
5,651 | """
Experiments with infix operator dispatch
>>> kadd = KnowsAdd()
>>> kadd + 1
(<KnowsAdd object>, 1)
>>> kadd * 1
"""
class KnowsAdd:
def __add__(self, other):
return self, other
def __repr__(self):
return '<{} object>'.format(type(self).__name__)
| 125 |
5,169 | <filename>Specs/ATSDK/0.0.1-weex/ATSDK.podspec.json
{
"name": "ATSDK",
"version": "0.0.1-weex",
"summary": "No summary",
"description": "description",
"license": {
"type": "Copyright",
"text": " Alibaba-INC copyright\n"
},
"authors": {
"yinfeng": "<EMAIL>"
},
"source": {
"htt... | 327 |
749 | import os
import sys
import site
from distutils.sysconfig import get_python_lib
if __name__ == '__main__':
prefix = sys.argv[1]
#ask distutils where to install the python module
install_dir = get_python_lib(plat_specific=True, prefix=prefix)
#use sites when the prefix is already recognized
try:
... | 204 |
364 | /**
* @file oglplus/buffer_binding.hpp
* @brief Buffer binding point indices
*
* @author <NAME>
*
* Copyright 2010-2019 <NAME>. Distributed under the Boost
* Software License, Version 1.0. (See accompanying file
* LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
*/
#pragma once
#ifndef O... | 821 |
778 | package org.aion.api.server.types;
import static junit.framework.TestCase.assertEquals;
import static junit.framework.TestCase.assertNull;
import static org.aion.base.Constants.NRG_CREATE_CONTRACT_DEFAULT;
import static org.aion.base.Constants.NRG_TRANSACTION_DEFAULT;
import java.math.BigInteger;
import org.aion.util... | 1,290 |
1,103 | /*
* Copyright 2016-2019 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 ... | 633 |
371 | <reponame>wuchunfu/EngineX<filename>jar-enginex-runner/src/main/java/com/baoying/enginex/executor/engine/service/EngineNodeService.java
package com.baoying.enginex.executor.engine.service;
import com.baomidou.mybatisplus.extension.service.IService;
import com.baoying.enginex.executor.engine.model.EngineNode;
import j... | 227 |
14,668 | <filename>ash/quick_pair/feature_status_tracker/fast_pair_enabled_provider_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 "ash/quick_pair/feature_status_tracker/fast_pair_enabled_p... | 2,514 |
1,210 | <gh_stars>1000+
// Copyright (c) 2011 <NAME>
//
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
#if !defined(BOOST_SPIRIT_REPOSITORY_QI_ADVANCE_JAN_23_2011_1203PM)
#define BOOST_SPIRIT_REPOSITORY_QI_ADVANCE_JAN_... | 1,703 |
677 | <reponame>InfiniteSynthesis/lynx-native
#include "gl/canvas/lynx_shader.h"
namespace canvas {
const char* LxVertexShaderPos::GetShaderString() {
return "\
attribute vec4 a_position; \
attribute vec2 a_texCoord; \
attribute vec4 a_color; \
varying vec2 v_texCoord; \
varying vec4 v_color; \
... | 351 |
338 | {
"Smartfren Andromax AD6B1H": {
"type": "mobile-phone",
"properties": {
"Device_Name": "C3",
"Device_Code_Name": "AD6B1H",
"Device_Maker": "Smartfren Andromax",
"Device_Pointing_Method": "touchscreen",
"Device_Brand_Name": "Harga"
},
"standard": false
}
}
| 146 |
1,039 | <reponame>thmclellan/PDF-Writer
/*
Source File : InputStringStream.h
Copyright 2016 <NAME> PDFWriter
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
Un... | 403 |
389 | from enum import Enum
class Color(str, Enum):
green = "green"
red = "red"
yellow = "yellow"
| 43 |
348 | {"nom":"Saint-Palais","circ":"11ème circonscription","dpt":"Gironde","inscrits":398,"abs":220,"votants":178,"blancs":23,"nuls":1,"exp":154,"res":[{"nuance":"REM","nom":"<NAME>","voix":91},{"nuance":"FN","nom":"<NAME>","voix":63}]} | 91 |
995 | // Copyright 2004-present Facebook. All Rights Reserved.
#pragma once
#include <fizz/client/PskCache.h>
#include <fizz/protocol/Factory.h>
#include <fizz/protocol/OpenSSLFactory.h>
namespace fizz {
namespace client {
std::string serializePsk(const fizz::client::CachedPsk& psk);
fizz::client::CachedPsk deserializePs... | 152 |
17,702 | # ==============================================================================
# Copyright (c) Microsoft. All rights reserved.
# Licensed under the MIT license. See LICENSE.md file in the project root
# for full license information.
# ==============================================================================
im... | 1,095 |
3,495 | /*
*
* Copyright (c) 2020 Project CHIP Authors
* Copyright (c) 2018 Nest Labs, 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
*
* ... | 1,084 |
571 | /**
* @file copyMakeBorder.cpp
* @brief mex interface for cv::copyMakeBorder
* @ingroup core
* @author Amro
* @date 2015
*/
#include "mexopencv.hpp"
using namespace std;
using namespace cv;
/**
* Main entry called from Matlab
* @param nlhs number of left-hand-side arguments
* @param plhs pointers to mxArrays ... | 957 |
649 | package net.poc.model;
public class Note {
private final String title;
private final String description;
private final boolean withPicture;
public boolean getWithPicture() {
return withPicture;
}
public String getTitle() {
return title;
}
public String getDescription(... | 838 |
628 | <gh_stars>100-1000
#include "basic_auth.h"
#include <utility>
#include "CivetServer.h"
#include "detail/base64.h"
namespace prometheus {
BasicAuthHandler::BasicAuthHandler(AuthFunc callback, std::string realm)
: callback_(std::move(callback)), realm_(std::move(realm)) {}
bool BasicAuthHandler::authorize(CivetS... | 722 |
720 | <reponame>choco9966/ttach<filename>ttach/transforms.py<gh_stars>100-1000
from functools import partial
from typing import Optional, List, Union, Tuple
from . import functional as F
from .base import DualTransform, ImageOnlyTransform
class HorizontalFlip(DualTransform):
"""Flip images horizontally (left->right)"""... | 3,526 |
16,461 | <gh_stars>1000+
// Copyright 2018-present 650 Industries. All rights reserved.
#import <ABI43_0_0ExpoModulesCore/ABI43_0_0EXExportedModule.h>
#import <ABI43_0_0ExpoModulesCore/ABI43_0_0EXModuleRegistryConsumer.h>
#import <ABI43_0_0ExpoModulesCore/ABI43_0_0EXEventEmitter.h>
#import <ABI43_0_0ExpoModulesCore/ABI43_0_0EX... | 212 |
2,667 | <reponame>TaylorWenOne/viabtc_exchange_server<gh_stars>1000+
/*
* Description:
* History: <EMAIL>, 2016/04/17, create
*/
# include <stdlib.h>
# include <unistd.h>
# include <assert.h>
# include "nw_job.h"
# include "nw_sock.h"
struct thread_arg {
nw_job *job;
void *privdata;
};
static void *thread_r... | 3,073 |
427 | <reponame>Polidea/SiriusObfuscator<filename>SymbolExtractorAndRenamer/lldb/packages/Python/lldbsuite/test/lang/swift/get_value/TestSwiftGetValueAsUnsigned.py
# TestSwiftGetValueAsUnsigned.py
#
# This source file is part of the Swift.org open source project
#
# Copyright (c) 2014 - 2016 Apple Inc. and the Swift project ... | 1,186 |
344 | <reponame>PuzeLiu/mushroom-rl
from .muscle_simulation import NoExternalSimulation, MuscleSimulation
| 34 |
860 | /*
* 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 ... | 2,348 |
1,338 | // -*- C++ -*- compatibility header.
// This file is part of the GNU ANSI C++ Library.
#include <algorithm>
#include <deque>
#include <functional>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <numeric>
#include <set>
#include <stack>
#include <utility>
#include <vector>
| 105 |
4,262 | <reponame>rikvb/camel
/*
* 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
* (th... | 2,189 |
571 | /*
Cephes Math Library Release 2.3: December, 1988
Copyright 1984, 1987, 1988 by <NAME>
Direct inquiries to 30 Frost Street, Cambridge, MA 02140
*/
#pragma once
namespace cephes {
double polevl(double x, const double *coef, int N);
double p1evl(double x, const double *coef, int N);
}
| 99 |
328 | // Copyright 2022 The BladeDISC Authors. 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 l... | 390 |
1,716 | <gh_stars>1000+
/*
* Copyright 2013 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 l... | 1,411 |
2,206 | <reponame>YunLemon/speedment
/*
*
* Copyright (c) 2006-2020, Speedment, 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/L... | 2,914 |
728 | /*
* Copyright (c) 2015 <NAME> <<EMAIL>>
* All Rights Reserved.
*/
package me.zhanghai.android.patternlock.sample.util;
public class PreferenceContract {
public static final String KEY_THEME = "pref_key_theme";
public static final String DEFAULT_THEME = "0";
public static final String KEY_PATTERN_SHA... | 187 |
1,726 | /// @ref gtc_vec1
/// @file glm/gtc/vec1.hpp
///
/// @see core (dependence)
///
/// @defgroup gtc_vec1 GLM_GTC_vec1
/// @ingroup gtc
///
/// Include <glm/gtc/vec1.hpp> to use the features of this extension.
///
/// Add vec1, ivec1, uvec1 and bvec1 types.
#pragma once
// Dependency:
#include "../ext/vec1.hpp"
#if GLM... | 208 |
595 | /******************************************************************************
* Copyright (C) 2018 - 2021 Xilinx, Inc. All rights reserved.
* SPDX-License-Identifier: MIT
******************************************************************************/
/****************************************************************... | 4,104 |
1,333 | package org.xujin.moss.client.endpoint;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.xujin.moss.client.endpoint.dependency.analyzer.JarDependencies;
import org.xujin.moss.client.utils.Analyzer;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory... | 1,085 |
496 | /*******************************************************************************
* Project: Nebula
* @file Channel.hpp
* @brief
* @author bwar
* @date: Mar 25, 2018
* @note
* Modify history:
******************************************************************************/
#ifndef SRC_CHANNEL_CHANNEL_HPP_
#defi... | 159 |
14,668 | <reponame>zealoussnow/chromium
// 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.
#ifndef COMPONENTS_INVALIDATION_IMPL_FCM_SYNC_NETWORK_CHANNEL_H_
#define COMPONENTS_INVALIDATION_IMPL_FCM_SYNC_NETWORK_CHAN... | 1,243 |
348 | {"nom":"Villers-Chief","circ":"5ème circonscription","dpt":"Doubs","inscrits":103,"abs":50,"votants":53,"blancs":2,"nuls":0,"exp":51,"res":[{"nuance":"LR","nom":"Mme <NAME>","voix":43},{"nuance":"REM","nom":"Mme <NAME>","voix":8}]} | 93 |
921 | <reponame>vsch/idea-markdown
// Copyright (c) 2015-2020 <NAME> <<EMAIL>> Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
package com.vladsch.md.nav.util.format;
import com.intellij.lang.ASTNode;
import com.intellij.openapi.editor.Editor;
import com.vladsch.flexmark... | 4,584 |
870 | <gh_stars>100-1000
from setuptools import setup, find_packages
setup(name='batchgenerators',
version='0.23',
description='Data augmentation toolkit',
url='https://github.com/MIC-DKFZ/batchgenerators',
author='Division of Medical Image Computing, German Cancer Research Center AND Applied Compute... | 407 |
361 | <gh_stars>100-1000
def test_function():
return True
class test_class():
def __init__(self):
pass
def test_me(self):
return "I'm a test"
| 75 |
5,903 | <reponame>zhouguangping/pentaho-kettle
/*!
* Copyright (C) 2017 by <NAME> : http://www.pentaho.com
*
* 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... | 478 |
1,582 | # -*- coding: utf-8 -*-
from urllib import urlencode
def redirect_to_login(request, next_path, login_url, redirect_field_name):
url = login_url + '?' + urlencode({redirect_field_name: next_path})
return request.redirect(url)
| 88 |
310 | <gh_stars>100-1000
package org.minbox.framework.knowledge.library.common.entity;
import com.gitee.hengboy.mybatis.enhance.common.annotation.Column;
import com.gitee.hengboy.mybatis.enhance.common.annotation.Id;
import com.gitee.hengboy.mybatis.enhance.common.annotation.Table;
import com.gitee.hengboy.mybatis.enhance.co... | 1,290 |
763 | <filename>db/basedb.py
#!/usr/bin/env python
# -*- encoding: utf-8 -*-
# vim: set et sw=4 ts=4 sts=4 ff=unix fenc=utf8:
# Author: Binux<<EMAIL>>
# http://binux.me
# Created on 2012-08-30 17:43:49
import logging
import sqlite3
logger = logging.getLogger('qiandao.basedb')
def tostr(s):
if isinstance(s, byte... | 2,780 |
8,027 | <reponame>Unknoob/buck
/*
* Copyright (c) Facebook, Inc. and 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
*
* Un... | 1,654 |
1,630 | #!/usr/bin/env python
# -*- encoding: utf-8 -*-
from functools import partial
import pytest
import torch
import torch.distributed as dist
import torch.multiprocessing as mp
from colossalai.communication import (recv_backward, recv_forward, recv_obj_meta, send_backward,
send_backw... | 1,598 |
593 | <reponame>Awais75/Linq
/*=============================================================================
Copyright (c) 2012 <NAME>
take_while.h
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
===============... | 362 |
1,352 | // pbrt is Copyright(c) 1998-2020 <NAME>, <NAME>, and <NAME>.
// The pbrt source code is licensed under the Apache License, Version 2.0.
// SPDX: Apache-2.0
#include <pbrt/util/pstd.h>
#include <pbrt/util/check.h>
#include <pbrt/util/memory.h>
namespace pstd {
namespace pmr {
memory_resource::~memory_resource() {}... | 1,083 |
831 | <reponame>qq1056779951/android
/*
* Copyright (C) 2019 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... | 1,590 |
5,422 | # Copyright 2020 The Oppia Authors. 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 ... | 1,463 |
6,958 | <filename>source/backend/cpu/CPUQuantizationUtils.hpp<gh_stars>1000+
/* Copyright 2015 The TensorFlow Authors. 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.apac... | 6,595 |
3,348 | <filename>heron/api/src/java/org/apache/heron/api/topology/SpoutDeclarer.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 licenses thi... | 754 |
6,034 | <reponame>ssSlowDown/onemall<filename>trade-service-project/trade-service-app/src/main/java/cn/iocoder/mall/tradeservice/dal/mysql/dataobject/order/TradeOrderLogisticsDO.java
package cn.iocoder.mall.tradeservice.dal.mysql.dataobject.order;
import cn.iocoder.mall.mybatis.core.dataobject.DeletableDO;
import cn.iocoder.m... | 819 |
385 | <reponame>vector-ai/vectorhub<filename>tests/test_encode_chunk_documents.py<gh_stars>100-1000
import pytest
from vectorhub.encoders.text.tfhub import USE2Vec
enc = USE2Vec()
enc.__name__ = "sample"
@pytest.fixture
def chunk_docs():
return [{
"value": [
{
"text": "hey"
... | 474 |
2,504 | <reponame>dujianxin/Windows-universal-samples
#include "pch.h"
#include "MrcVideoEffectDefinition.h"
using namespace MrcEffectDefinitions;
MrcVideoEffectDefinition::MrcVideoEffectDefinition()
{
StreamType = DefaultStreamType;
HologramCompositionEnabled = DefaultHologramCompositionEnabled;
Record... | 253 |
742 | <gh_stars>100-1000
/*********************************************************************
* Software License Agreement (BSD License)
*
* Copyright (c) 20012, <NAME>, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the f... | 3,567 |
892 | {
"schema_version": "1.2.0",
"id": "GHSA-5jh3-w6q5-9mr3",
"modified": "2022-01-22T00:02:15Z",
"published": "2022-01-15T00:01:53Z",
"aliases": [
"CVE-2022-22056"
],
"details": "The Le-yan dental management system contains a hard-coded credentials vulnerability in the web page source code, which allows ... | 364 |
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 ... | 2,802 |
310 | {
"name": "MLB at Bat (iOS)",
"description": "An iPhone baseball app for viewing scores and streaming matches.",
"url": "http://m.mlb.com/apps/atbat"
} | 53 |
348 | <filename>ichnaea/scripts/load_cell_data.py
#!/usr/bin/env python
"""
Import from public cell data into a local dev environment.
Download from https://location.services.mozilla.com/downloads
This has been tested with a differential cell export (~400kB compressed).
A full cell export (~370,000kB) contains unexpected d... | 898 |
14,668 | <reponame>zealoussnow/chromium
// Copyright 2014 The Crashpad Authors. 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/LICENS... | 1,007 |
988 | <filename>src/filter_tree/filter_tree_utils.h
/*
* Copyright 2018-2021 Redis Labs Ltd. and Contributors
*
* This file is available under the Redis Labs Source Available License Agreement
*/
#pragma once
#include "filter_tree.h"
bool isInFilter(const FT_FilterNode *filter);
bool extractOriginAndRadius(const FT_Filte... | 138 |
547 | <gh_stars>100-1000
from math import atan2
import numpy as np
import numba as nb
from functools import partial
import dask.array as da
from numba import cuda
import xarray as xr
from xrspatial.utils import ngjit
from xrspatial.utils import has_cuda
from xrspatial.utils import cuda_args
from xrspatial.utils import i... | 4,361 |
692 | <filename>SingularityService/src/main/java/com/hubspot/singularity/smtp/SingularityMailRecordCleaner.java
package com.hubspot.singularity.smtp;
import com.google.inject.Inject;
import com.google.inject.Singleton;
import com.hubspot.mesos.JavaUtils;
import com.hubspot.singularity.config.SMTPConfiguration;
import com.hu... | 879 |
1,223 | package carpet.mixins;
import carpet.fakes.SpawnHelperInnerInterface;
import carpet.utils.SpawnReporter;
import it.unimi.dsi.fastutil.objects.Object2IntOpenHashMap;
import net.minecraft.entity.SpawnGroup;
import net.minecraft.util.math.GravityField;
import net.minecraft.world.SpawnHelper;
import org.spongepowered.asm.... | 531 |
22,481 | """Hub for communication with 1-Wire server or mount_dir."""
from __future__ import annotations
import logging
import os
from typing import TYPE_CHECKING
from pi1wire import Pi1Wire
from pyownet import protocol
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import (
ATTR_IDENTIFIER... | 4,057 |
3,102 | <filename>clang/test/Analysis/html_diagnostics/relevant_lines/synthesized_body.cpp
// Faking std::call_once implementation.
namespace std {
typedef struct once_flag_s {
int _M_once = 0;
} once_flag;
template <class Callable, class... Args>
void call_once(once_flag &o, Callable&& func, Args&&... args);
} // namespace... | 313 |
14,668 | // Copyright 2021 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/page_load_metrics/browser/observers/ad_metrics/aggregate_frame_data.h"
#include "components/page_load_metrics/browser/observers/ad_m... | 659 |
1,444 | <gh_stars>1000+
package mage.abilities.effects.common.combat;
import mage.abilities.Ability;
import mage.abilities.effects.RestrictionEffect;
import mage.constants.Duration;
import mage.filter.common.FilterCreaturePermanent;
import mage.game.Game;
import mage.game.permanent.Permanent;
/**
* @author LevelX2
*/
publi... | 545 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.