prompt
large_stringlengths
70
991k
completion
large_stringlengths
0
1.02k
<|file_name|>lint.py<|end_file_name|><|fim▁begin|># Copyright 2004-2010 PyTom <pytom@bishoujo.us> # # 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 witho...
import renpy import codecs import os
<|file_name|>benchmark.js<|end_file_name|><|fim▁begin|>/** * @license Apache-2.0 * * Copyright (c) 2018 The Stdlib Authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.a...
var bench = require( '@stdlib/bench' ); var fromCodePoint = require( '@stdlib/string/from-code-point' ); var pkg = require( './../package.json' ).name;
<|file_name|>run.py<|end_file_name|><|fim▁begin|>#! /usr/bin/env python #---------------------------------------------------------------- # Author: Jason Gors <jasonDOTgorsATgmail> # Creation Date: 07-30-2013 # Purpose: this is where the program is called into action. #-------------------------------------------------...
else: additional_args = [] # set back to empty to avoid the flag at the end of argparse stuff
<|file_name|>test_clipboard.cc<|end_file_name|><|fim▁begin|>// Copyright 2014 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be<|fim▁hole|>#include "ui/base/clipboard/test/test_clipboard.h" #include <stddef.h> #include <memory> #include <utility> #incl...
// found in the LICENSE file.
<|file_name|>LocatedAttributeAdapter.java<|end_file_name|><|fim▁begin|>/* * SonarQube Java * Copyright (C) 2012-2017 SonarSource SA * mailto:info AT sonarsource DOT com * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as publ...
* You should have received a copy of the GNU Lesser General Public License * along with this program; if not, write to the Free Software Foundation, * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
<|file_name|>nvme_compare_test.py<|end_file_name|><|fim▁begin|># Copyright (c) 2015-2016 Western Digital Corporation or its affiliates. # # 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 v...
<|file_name|>CustomAuthenticationProvider.java<|end_file_name|><|fim▁begin|>package org.clinical3PO.common.security; import java.util.Collection; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.authentication.AuthenticationProvider; import org.springframework.securit...
@Override public boolean supports(Class<?> arg0) { return true;
<|file_name|>basic.py<|end_file_name|><|fim▁begin|># # Author: Pearu Peterson, March 2002 # # w/ additions by Travis Oliphant, March 2002 # and Jake Vanderplas, August 2012 from __future__ import division, print_function, absolute_import from warnings import warn import numpy as np from numpy import atle...
"lstsq", the least squares solution is returned. Default is "raise".
<|file_name|>fu_poteng_bending.py<|end_file_name|><|fim▁begin|>#------------------------------------------------------------------------- # # Copyright (c) 2009, IMB, RWTH Aachen. # All rights reserved. # # This software is provided without warranty under the terms of the BSD # license included in simvisage/LICENSE.txt...
<|file_name|>win_init.py<|end_file_name|><|fim▁begin|>import os, pygame #create window of correct size (320x200, with some multiple) x = 320 y = 200 size_mult = 4 bright_mult = 4<|fim▁hole|>os.environ['SDL_VIDEO_WINDOW_POS'] = str(0) + "," + str(40) #put window in consistent location screen = pygame.display.set_mode(...
pygame.init() os.environ['SDL_VIDEO_WINDOW_POS'] = str(0) + "," + str(40) #put window in consistent location
<|file_name|>EthernetServer.cpp<|end_file_name|><|fim▁begin|>// Standard system includes #include <assert.h> #include <errno.h> // -EINVAL, -ENODEV #include <netdb.h> // gethostbyname #include <sys/poll.h> #include <sys/types.h> // connect #include <sys/socket.h> // connect #include <trace.h> #define MY_TRACE_P...
<|file_name|>function.rs<|end_file_name|><|fim▁begin|>use std::any::Any; use std::marker::PhantomData; #[cfg(feature = "serde")] use crate::serde::{Deserialize, Deserializer}; use futures::{ prelude::*, ready, task::{self, Poll}, }; use crate::base::symbol::Symbol; use crate::base::types::ArcType; use c...
} else { self.name }; let id = Symbol::from(name.replace("::", "."));
<|file_name|>banking-helper.service.ts<|end_file_name|><|fim▁begin|>import { Inject, Injectable } from '@angular/core'; import { FormGroup } from '@angular/forms'; import { Account, AccountKind, AccountType, AccountWithOwner, BaseTransferDataForSearch, Image, PreselectedPeriod, RecurringPaymentStatusEnum, Transac...
<|file_name|>regions-ref-in-fn-arg.rs<|end_file_name|><|fim▁begin|>#![feature(box_patterns)] fn arg_item(box ref x: Box<isize>) -> &'static isize { x //~ ERROR cannot return value referencing function parameter } fn with<R, F>(f: F) -> R where F: FnOnce(Box<isize>) -> R { f(Box::new(3)) } fn arg_closure() -> &'...
fn main() {}
<|file_name|>0001_initial.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # Generated by Django 1.11.2 on 2017-06-14 02:26 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): initial = True dependen...
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('size', models.PositiveSmallIntegerField()), ('number', models.PositiveSmallIntegerField()), ('building', models.ForeignKey(on_delete=django.db.models.delet...
<|file_name|>dA_joint.py<|end_file_name|><|fim▁begin|>""" This tutorial introduces denoising auto-encoders (dA) using Theano. Denoising autoencoders are the building blocks for SdA. They are based on auto-encoders as the ones used in Bengio et al. 2007. An autoencoder takes an input x and first maps it to a hidden...
cost,
<|file_name|>privileges_test.py<|end_file_name|><|fim▁begin|>from mock import patch from .test_helper import raises from kiwi.exceptions import KiwiPrivilegesError from kiwi.privileges import Privileges class TestPrivileges(object): @raises(KiwiPrivilegesError) @patch('os.geteuid') def test_check_for_ro...
@patch('os.geteuid')
<|file_name|>Progress.js<|end_file_name|><|fim▁begin|>import * as React from 'react'; import {px2rem} from '@bizfe/biz-mobile-ui/build/util/util'; import { Button, LinearProgress, CircleProgress } from '@bizfe/biz-mobile-ui'; const styles = { progress: { width: '90%', margin: '20px auto...
size="small">- 10</Button>
<|file_name|>GMManhattanVisualization.js<|end_file_name|><|fim▁begin|>import React from 'react' import GMManhattanChart from './GMManhattanChart' import GMManhattanToolbar from './GMManhattanToolbar' import fetch from './fetch' import config from '../../config' const GMManhattanVisualization = React.createClass({ c...
<|file_name|>doc.go<|end_file_name|><|fim▁begin|>/*<|fim▁hole|>Command exercism allows users to interact with the exercism.io platform. The primary actions are to fetch problems to be solved, and submit iterations of these problems. */ package main<|fim▁end|>
<|file_name|>abc140_c.py<|end_file_name|><|fim▁begin|>N = int(input()) B = [int(x) for x in input().split()] A = [10**5] * N for i, b in enumerate(B):<|fim▁hole|><|fim▁end|>
A[i] = min(A[i], b) A[i+1] = min(A[i+1], b) print(sum(A))
<|file_name|>test_payments_api.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # This file is part of Shuup. # # Copyright (c) 2012-2016, Shoop Commerce Ltd. All rights reserved. # # This source code is licensed under the AGPLv3 license found in the # LICENSE file in the root directory of this source tree. from...
<|file_name|>PresenceService.js<|end_file_name|><|fim▁begin|>dojo.provide("dojox.xmpp.PresenceService"); dojox.xmpp.presence = { UPDATE: 201, SUBSCRIPTION_REQUEST: 202, // SUBSCRIPTION_REQUEST_PENDING: 203, /* used when 'ask' attribute is absent on a roster item */ SUBSCRIPTION_SUBSTATUS_NONE: 204, SUBSCRIPTION_...
} else { delete this.restrictedContactjids[jid]; }
<|file_name|>UserRole.java<|end_file_name|><|fim▁begin|>/* * Sonar, open source software quality management tool. * Copyright (C) 2009 SonarSource SA * mailto:contact AT sonarsource DOT com * * Sonar is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * L...
<|file_name|>integration.rs<|end_file_name|><|fim▁begin|>use super::*; /// Various information about integrations. #[derive(Clone, Debug, Deserialize)] pub struct Integration { pub id: IntegrationId, pub account: IntegrationAccount, pub enabled: bool, #[serde(rename="expire_behaviour")] pub expire_...
pub synced_at: u64, pub syncing: bool, pub user: User,
<|file_name|>canmessagemodel.cpp<|end_file_name|><|fim▁begin|>/* * file: canmessagemodel.cpp * author: jrenken * * $Rev: 74 $ * $Author: jrenken $ * $Date: 2012-08-30 15:50:09 +0200 (Do, 30 Aug 2012) $ * $Id: canmessagemodel.cpp 74 2012-08-30 13:50:09Z jrenken $ */ #include <QByteArray> #include "canme...
void CanMessageModel::deleteMessage(const QCanMessage& msg) { if (mMessages.remove(msg.frame.id()) > 0) reset();
<|file_name|>client.go<|end_file_name|><|fim▁begin|>package force import ( "bytes" "fmt" "io" "io/ioutil" "net/http" "net/url" "github.com/nimajalali/go-force/forcejson" )<|fim▁hole|> contentType = "application/json" responseType = "application/json" ) // Get issues a GET to the specified path with the give...
const ( version = "1.0.0" userAgent = "go-force/" + version
<|file_name|>py_choose.py<|end_file_name|><|fim▁begin|>#<pycode(py_choose)> class Choose: """ Choose - class for choose() with callbacks """ def __init__(self, list, title, flags=0, deflt=1, icon=37): self.list = list self.title = title self.flags = flags self.x0 = -1 self.x1 = -1 self....
print "enter(%d) called" % n def destroy(self):
<|file_name|>CsvDataSourceApp.java<|end_file_name|><|fim▁begin|>/* * JasperReports - Free Java Reporting Library. * Copyright (C) 2001 - 2014 TIBCO Software Inc. All rights reserved. * http://www.jaspersoft.com * * Unless you have purchased a commercial license agreement from Jaspersoft, * the following license t...
exporter.setExporterInput(new SimpleExporterInput(jasperPrint));
<|file_name|>recvRollback.go<|end_file_name|><|fim▁begin|>package tests import ( "fmt" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/zrepl/zrepl/platformtest" "github.com/zrepl/zrepl/util/nodefault" "github.com/zrepl/zrepl/zfs" ) func ReceiveForceRollbackWorksUnencrypt...
rfs := fmt.Sprintf("%s/foo bar", ctx.RootDataset) sfs := fmt.Sprintf("%s/sender", ctx.RootDataset)
<|file_name|>models.py<|end_file_name|><|fim▁begin|>#=========================================================================================================================== # aims : define both 3 hidden layers model and 4 hidden layers model # # input : x : placeholder variable which has as column numb...
return tf.Variable(initial, name=name)
<|file_name|>gpio_multithreaded_mutex.rs<|end_file_name|><|fim▁begin|>// gpio_multithreaded_mutex.rs - Blinks an LED from multiple threads. // // Remember to add a resistor of an appropriate value in series, to prevent // exceeding the maximum current rating of the GPIO pin and the LED. use std::error::Error; use std:...
<|file_name|>query.py<|end_file_name|><|fim▁begin|>""" The main QuerySet implementation. This provides the public API for the ORM. """ import copy import itertools import sys from django.db import connections, router, transaction, IntegrityError from django.db.models.fields import AutoField from django.db.models.quer...
<|file_name|>test_common_utils.py<|end_file_name|><|fim▁begin|>import errno import os import unittest import mock from taskcat._common_utils import ( exit_with_code, fetch_ssm_parameter_value, get_s3_domain, make_dir, merge_dicts, name_from_stack_id, param_list_to_dict, pascal_to_snake,...
pass
<|file_name|>update_requires_set.rs<|end_file_name|><|fim▁begin|>extern crate diesel; use diesel::*; table! { users { id -> Integer, } } fn main() {<|fim▁hole|>}<|fim▁end|>
let conn = SqliteConnection::establish(":memory:").unwrap(); update(users::table) .execute(&conn);
<|file_name|>StreamWatcher.py<|end_file_name|><|fim▁begin|>from collections import namedtuple import select StreamEvent = namedtuple( 'StreamEvent', [ 'fd', 'stream', 'data', 'direction', 'num_bytes', 'eof' ] ) class StreamWatcher(object): def __init__( self ): if _best_backend is None: raise Exception( "No pol...
def watch_read( self, fd ): self.ep.register( fd, select.EPOLLIN )
<|file_name|>__init__.py<|end_file_name|><|fim▁begin|># emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: t -*- # vi: set ft=python sts=4 ts=4 sw=4 noet : # This file is part of Fail2Ban. # # Fail2Ban is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public L...
<|file_name|>levels.py<|end_file_name|><|fim▁begin|>import view from world import * DEFAULT_CAMERA_AREA = view.View.CAMERA_AREA class LevelZero(view.View): lives = 50 name = "Level 0: Grossini's return" target = 5 order = 0 CAMERA_AREA=(0, -90, 0, -90) mountainScale = 0.4 def setup_le...
class LevelTwo(view.View): lives = 50
<|file_name|>util.rs<|end_file_name|><|fim▁begin|>// Small functions of utility use core::SearchType::{self, ExactMatch, StartsWith}; use core::Session; use std; use std::cmp; use std::fs::File; use std::io::{BufRead, BufReader}; use std::path::Path; pub fn getline(filepath: &Path, linenum: usize, session: &Session) ...
assert_eq!(true, txt_matches(ExactMatch, "Vec","use Vec")); }
<|file_name|>server.rs<|end_file_name|><|fim▁begin|>extern crate xmpp; use xmpp::XmppServerListener;<|fim▁hole|> serverStream.listen(); }<|fim▁end|>
fn main() { let mut serverStream = XmppServerListener::new("127.0.0.1", 5222);
<|file_name|>rab_gene_scatter.js<|end_file_name|><|fim▁begin|>var g_data; var margin = {top: 40, right: 45, bottom: 60, left: 60}, width = 460 - margin.left - margin.right, height = 436 - margin.top - margin.bottom; var xValue = function(d) { return d.condition;}; var x = d3.scalePoint().range([20, width-20])...
.on("mouseover", function(d) {
<|file_name|>Construo.cpp<|end_file_name|><|fim▁begin|>/*********************************************************************** Mosaicker - Program to reproject, resample, and join a set of georeferenced color images into a single multiresolution mosaic image. Copyright (c) 2007-2008 Oliver Kreylos This file is pa...
<|file_name|>generate_ml_data.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python import sct_utils as sct import os #path = '/Users/benjamindeleener/data/data_testing/C2-T2/' contrast = 't2' #path_output_seg = '/Users/benjamindeleener/data/spinal_cord_segmentation_data/training/labels/' #path_output_im = '/Users/be...
<|file_name|>001_Rename_tagset_column.py<|end_file_name|><|fim▁begin|>from __future__ import absolute_import from sqlalchemy import * from migrate import * meta = MetaData() vieworderings = Table('vieworderings', meta, Column('id', Integer, primary_key=True), Column('tagset', Text()), Column('...
def downgrade(migrate_engine): raise NotImplementedError
<|file_name|>angle.rs<|end_file_name|><|fim▁begin|>// Copyright 2013 The Servo Project Developers. See the COPYRIGHT // file at the top-level directory of this distribution. // // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license // <LICE...
} #[test]
<|file_name|>html_writer.rs<|end_file_name|><|fim▁begin|>extern crate marksman_escape; use self::marksman_escape::Escape; use {DomNode, DomNodes, DomValue}; use processors::DomNodeProcessor; // This module as a whole is "use_std"-only, so these don't need to be cfg'd use std::marker::PhantomData; use std::fmt; use st...
}
<|file_name|>midi.js<|end_file_name|><|fim▁begin|>// // This software is released under the 3-clause BSD license. // // Copyright (c) 2015, Xin Chen <txchen@gmail.com> // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the follow...
/* read an 8-bit integer */ function readInt8(signed) {
<|file_name|>health.state.js<|end_file_name|><|fim▁begin|>(function() { 'use strict'; angular .module('noctemApp') .config(stateConfig); stateConfig.$inject = ['$stateProvider']; <|fim▁hole|> data: { authorities: ['ROLE_ADMIN'], pageTitle: 'health...
function stateConfig($stateProvider) { $stateProvider.state('jhi-health', { parent: 'admin', url: '/health',
<|file_name|>data-types.js<|end_file_name|><|fim▁begin|>'use strict'; const _ = require('lodash'); const moment = require('moment-timezone'); module.exports = BaseTypes => { BaseTypes.ABSTRACT.prototype.dialectTypes = 'https://mariadb.com/kb/en/library/resultset/#field-types'; /** * types: [buffer_type, ...] ...
let definition = super.toSql(); if (this._unsigned) {
<|file_name|>views.py<|end_file_name|><|fim▁begin|>from django.contrib.auth.models import User from django.views.generic.edit import CreateView, FormView from django.shortcuts import render from django.views.decorators.csrf import csrf_exempt from django.utils.decorators import method_decorator from django.core.context...
<|file_name|>resource_arm_storage_blob_test.go<|end_file_name|><|fim▁begin|>package azurerm import ( "crypto/rand" "fmt" "io" "io/ioutil" "testing" "strings" "github.com/Azure/azure-sdk-for-go/storage" "github.com/hashicorp/terraform/helper/acctest" "github.com/hashicorp/terraform/helper/resource" "github....
<|file_name|>routes.ts<|end_file_name|><|fim▁begin|>import {Routes} from '@angular/router'; import {Home} from './demo-app'; import {ButtonDemo} from '../button/button-demo'; import {BaselineDemo} from '../baseline/baseline-demo'; import {ButtonToggleDemo} from '../button-toggle/button-toggle-demo'; import {TabsDemo} f...
{path: 'icon', component: IconDemo}, {path: 'list', component: ListDemo}, {path: 'menu', component: MenuDemo},
<|file_name|>tac.rs<|end_file_name|><|fim▁begin|>#[macro_use]<|fim▁hole|> use common::util::*; static UTIL_NAME: &'static str = "tac"; #[test] fn test_stdin_default() { let (_, mut ucmd) = testing(UTIL_NAME); let result = ucmd.run_piped_stdin("100\n200\n300\n400\n500"); assert_eq!(result.stdout, "500400\n...
mod common;
<|file_name|>checker.py<|end_file_name|><|fim▁begin|>"""frosted/checker.py. The core functionality of frosted lives here. Implements the core checking capability models Bindings and Scopes Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files ...
<|file_name|>maxrootweb.py<|end_file_name|><|fim▁begin|>import os import shutil def pre_read(dir): try: filelist = os.listdir(dir) for file in filelist: if os.path.isdir(file): # exception directory if str(file) == 'webMager' or...
except PermissionError: pass
<|file_name|>lzjb.py<|end_file_name|><|fim▁begin|><|fim▁hole|># # --------------------------------------------------------------------- # # Copyright (c) 2014-2016, Emil Brink # All rights reserved. # # Redistribution and use in source and binary forms, with or without modification, are permitted provided # that the fo...
# # An attempt at re-implementing LZJB compression in native Python. # # Created in May 2014 by Emil Brink <emil@obsession.se>. See LICENSE.
<|file_name|>new.js<|end_file_name|><|fim▁begin|>// npm var chalk = require('chalk') // local var Copper = require('../copper') var copper = new Copper var util = require('../util') module.exports = function (config, wallet, keys, args) { var abort = false var name <|fim▁hole|> var key = copper.newKey() consol...
if (args._.length > 0) { name = args._.join(' ') }
<|file_name|>todos.js<|end_file_name|><|fim▁begin|>/*global YoBackbone, Backbone*/ YoBackbone.Collections = YoBackbone.Collections || {}; (function () { 'use strict'; var Todos = Backbone.Collection.extend({ model: YoBackbone.Models.Todo, localStorage: new Backbone.LocalStorage('todos-backb...
<|file_name|>exposer.js<|end_file_name|><|fim▁begin|>import { FieldErrorProcessor } from "./processors/field-error-processor"; import { RuleResolver } from "./rulesets/rule-resolver"; import { ValidationGroupBuilder } from "./builders/validation-group-builder";<|fim▁hole|>import { ruleRegistry } from "./rule-registry-s...
<|file_name|>GetListHistoryTasksCommand.java<|end_file_name|><|fim▁begin|>/******************************************************************************* * Copyright 2017 Bstek * * Licensed under the Apache License, Version 2.0 (the "License"); you may not * use this file except in compliance with the License. Y...
* @since 2013年9月12日 */
<|file_name|>util.rs<|end_file_name|><|fim▁begin|>use std::fmt;<|fim▁hole|> impl FormatBytes { #[inline] fn to_kb(self) -> f64 { (self.0 as f64) / 1.0e3 } #[inline] fn to_mb(self) -> f64 { (self.0 as f64) / 1.0e6 } #[inline] fn to_gb(self) -> f64 { (self.0 a...
use std::io::{IoErrorKind, IoResult}; #[derive(Copy)] pub struct FormatBytes(pub u64);
<|file_name|>generated.rs<|end_file_name|><|fim▁begin|>// ================================================================= // // * WARNING * // // This file is generated! // // Changes made to this file will be overwritten. If changes are // required to the generated code...
/// <p>The maximum number of results to include in the response. If more results exist than the specified <code>MaxResults</code> value, a token is included in the response so that the remaining results can be retrieved.</p> <p>The value for <code>MaxResults</code> must be between 20 and 100.</p> #[serde(rename...
<|file_name|>test_connection.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from __future__ import unicode_literals import httpretty import json import sure from pyeqs import QuerySet, Filter from pyeqs.dsl import Term, Sort, ScriptScore from tests.helpers import homogeneous @httpretty.activate def test_cr...
"hits": { "total": 1,
<|file_name|>video-player.js<|end_file_name|><|fim▁begin|>VideoPlayer = function(ctx) { this.autoplay = ctx.autoplay || true; this.video = document.getElementById('bgvid'); this.video.src = ctx.file; if(this.autoplay) { this.video.play(); } } VideoPlayer.prototype.stop = function(){ this.video.pause()...
<|file_name|>collectedHeap.hpp<|end_file_name|><|fim▁begin|>/* * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General...
//
<|file_name|>mod.rs<|end_file_name|><|fim▁begin|>//! String manipulation. //! //! For more details, see the [`std::str`] module. //! //! [`std::str`]: ../../std/str/index.html #![stable(feature = "rust1", since = "1.0.0")] mod converts; mod error; mod iter; mod traits; mod validations; use self::pattern::Pattern; us...
<|file_name|>travel_time_hbw_am_drive_alone_from_home_to_work_alt.py<|end_file_name|><|fim▁begin|># Opus/UrbanSim urban simulation software. # Copyright (C) 2005-2009 University of Washington # See opus_core/LICENSE from urbansim.abstract_variables.abstract_travel_time_variable import abstract_travel_time_variable...
"from_zone_id": array([3, 3, 1, 1, 1, 2, 2, 3, 2]), "to_zone_id": array([1, 3, 1, 3, 2, 1, 3, 2, 2]), "am_single_vehicle_to_work_travel_time":array([1.1, 2.2, 3.3, 4.4, 0.5, 0.7, 8.7, 7.8, 1.0])}}, ...
<|file_name|>SavingParametersDialog.cpp<|end_file_name|><|fim▁begin|>/** * This file is a part of Luminance HDR package. * ---------------------------------------------------------------------- * Copyright (C) 2011 Franco Comida * * This program is free software; you can redistribute it and/or modify * it under...
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
<|file_name|>router.js<|end_file_name|><|fim▁begin|>import Backbone from 'backbone'; export default class Router extends Backbone.Router { get routes() { return { '(/)': 'home', 'login': 'login', 'access_token=*token': 'token', 'activity': 'acti...
<|file_name|>libcall_irix.go<|end_file_name|><|fim▁begin|>// Copyright 2011 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. <|fim▁hole|>// +build irix package syscall //sysnb raw_ptrace(request int, pid int, addr *byte, data ...
<|file_name|>specialization-translate-projections-with-lifetimes.rs<|end_file_name|><|fim▁begin|>// run-pass #![feature(specialization)] //~ WARN the feature `specialization` is incomplete trait Iterator { fn next(&self); } trait WithAssoc { type Item; } impl<'a> WithAssoc for &'a () { type Item = &'a u...
struct Cloned<I>(I);
<|file_name|>box.js<|end_file_name|><|fim▁begin|>var $ = function (selector) { return document.querySelector(selector); }; var $all = function (selector) { return document.querySelectorAll(selector); }; var colorScheme = [ '#6BED08', '#A0F261', '#86EF35', '#60DD00', '#4AAA00', '#F8FE09', '#FBFE66', ...
document.onclick = function () { if (level > 9) { $all('.box').forEach(function (box) {
<|file_name|>SpellAuras.cpp<|end_file_name|><|fim▁begin|>/* * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * Copyright (C) 2008-2010 Trinity <http://www.trinitycore.org/> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as ...
if (int32 manaPerSecond = m_spellProto->manaPerSecond + m_spellProto->manaPerSecondPerLevel * caster->getLevel()) { m_timeCla += 1000 - diff;
<|file_name|>import_export.py<|end_file_name|><|fim▁begin|># This file is part of the Frescobaldi project, http://www.frescobaldi.org/ # # Copyright (c) 2008 - 2014 by Wilbert Berendsen # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as p...
shortcuts.tail = '\n'
<|file_name|>a00116.js<|end_file_name|><|fim▁begin|>var a00116 = [ [ "Advertising Data Encoder", "a00118.html", null ], [ "Debug Assert Handler", "a00119.html", null ], [ "BLE Device Manager", "a00126.html", [ [ "Initialization", "a00126.html#lib_device_manaegerit", [ [ "Associated Events", "a...
[ "Initialization and Set-up", "a00120.html#lib_ble_conn_params_init", null ], [ "Shutdown", "a00120.html#lib_ble_conn_params_stop", null ], [ "Change/Update Connection Parameters Negotiated", "a00120.html#lib_ble_conn_params_change_conn_params", null ]
<|file_name|>ObjectExpressionToVariableDeclarationExtractor.ts<|end_file_name|><|fim▁begin|>import { inject, injectable } from 'inversify'; import { ServiceIdentifiers } from '../../../container/ServiceIdentifiers'; import * as ESTree from 'estree'; import { TNodeWithStatements } from '../../../types/node/TNodeWithSt...
@injectable() export class ObjectExpressionToVariableDeclarationExtractor implements IObjectExpressionExtractor {
<|file_name|>FlowchartTemplate_pyside.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- # Form implementation generated from reading ui file './flowchart/FlowchartTemplate.ui' # # Created: Sun Feb 24 19:47:30 2013 # by: pyside-uic 0.2.13 running on PySide 1.1.1 # # WARNING! All changes made in this file wil...
self.selNameLabel.setObjectName("selNameLabel") self.gridLayout.addWidget(self.selNameLabel, 0, 1, 1, 1) self.selectedTree = DataTreeWidget(self.selInfoWidget)
<|file_name|>waveBlock.ts<|end_file_name|><|fim▁begin|>import { NodeMaterialBlock } from '../nodeMaterialBlock'; import { NodeMaterialBlockConnectionPointTypes } from '../Enums/nodeMaterialBlockConnectionPointTypes'; import { NodeMaterialBuildState } from '../nodeMaterialBuildState'; import { NodeMaterialConnectionP...
/** Square */
<|file_name|>add_profile.py<|end_file_name|><|fim▁begin|># IfcOpenShell - IFC toolkit and geometry engine # Copyright (C) 2021 Dion Moult <dion@thinkmoult.com> # # This file is part of IfcOpenShell. # # IfcOpenShell is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General P...
# the Free Software Foundation, either version 3 of the License, or
<|file_name|>15.2.3.12-3-8.js<|end_file_name|><|fim▁begin|>// Copyright (c) 2012 Ecma International. All rights reserved. // This code is governed by the BSD license found in the LICENSE file. /*--- es5id: 15.2.3.12-3-8 description: Object.isFrozen returns false for all built-in objects (String) ---*/ var b = Object...
assert.sameValue(b, false, 'b');
<|file_name|>numerictypes.py<|end_file_name|><|fim▁begin|>"""numerictypes: Define the numeric type objects This module is designed so 'from numerictypes import *' is safe. Exported symbols include: Dictionary with all registered number types (including aliases): typeDict Type objects (not all will be availab...
return dict.__getitem__(self, obj2sctype(obj)) nbytes = _typedict() _alignment = _typedict()
<|file_name|>juce_ScrollBar.cpp<|end_file_name|><|fim▁begin|>/* ============================================================================== This file is part of the JUCE library. Copyright (c) 2017 - ROLI Ltd. JUCE is an open source library subject to commercial or open-source licensing. By using...
<|file_name|>schema.py<|end_file_name|><|fim▁begin|># testing/schema.py # Copyright (C) 2005-2017 the SQLAlchemy authors and contributors # <see AUTHORS file> # # This module is part of SQLAlchemy and is released under # the MIT License: http://www.opensource.org/licenses/mit-license.php from . import exclusions from ...
fks = [fk for col in args if isinstance(col, schema.Column)
<|file_name|>util.rs<|end_file_name|><|fim▁begin|>// Copyright (c) 2014, 2015 Robert Clipsham <robert@octarineparrot.com> // // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at y...
<|file_name|>0003_bidder_address.py<|end_file_name|><|fim▁begin|># -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('bidders', '0002_bidder_photo'), ] operations = [ migrations...
]
<|file_name|>main.vagas.controller.js<|end_file_name|><|fim▁begin|>(function () { angular .module('mainModule') .controller('mainVagasController', mainVagasController); function mainVagasController($state, $http, BASE_URL_API) { var vm = this; vm.vagas = []; vm.abrirVaga = abri...
.finally(function () { vm.mostraLoad = false; });
<|file_name|>bitcoin_hi_IN.ts<|end_file_name|><|fim▁begin|><?xml version="1.0" ?><!DOCTYPE TS><TS language="hi_IN" version="2.0"> <defaultcodec>UTF-8</defaultcodec> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About Bestericoin</s...
<location line="+10"/>
<|file_name|>account_banking_uk_hsbc.py<|end_file_name|><|fim▁begin|>############################################################################## # # Copyright (C) 2009 EduSense BV (<http://www.edusense.nl>). # Copyright (C) 2011 credativ Ltd (<http://www.credativ.co.uk>). # All Rights Reserved # # This p...
return result
<|file_name|>gossip_test.go<|end_file_name|><|fim▁begin|>/* * Copyright IBM Corp. All Rights Reserved. * * SPDX-License-Identifier: Apache-2.0 */ package gossip import ( "fmt" "io/ioutil" "os" "syscall" "time" docker "github.com/fsouza/go-dockerclient" "github.com/hyperledger/fabric/integration/nwo" "git...
// Org1: leader election
<|file_name|>guess_video_rexps.py<|end_file_name|><|fim▁begin|>#!/usr/bin/env python # -*- coding: utf-8 -*- # # GuessIt - A library for guessing information from filenames # Copyright (c) 2012 Nicolas Wack <wackou@gmail.com> # # GuessIt is free software; you can redistribute it and/or modify it under # the terms of th...
<|file_name|>weather.py<|end_file_name|><|fim▁begin|># Get weather data from various online sources # -*- coding: utf-8 -*- import requests from wrappers import * @plugin class yweather: @command("weather") def weather(self, message): """Get the current condition in a given location, from the Yahoo! ...
# Build a forecast IO request string. TODO: Remove API key and regenerate it
<|file_name|>position.mako.rs<|end_file_name|><|fim▁begin|>/* 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, You can obtain one at http://mozilla.org/MPL/2.0/. */ <%! from data import to_rust_ident %> <%namespace name=...
animation_value_type="MaxLength")} % else:
<|file_name|>unseries.py<|end_file_name|><|fim▁begin|># encoding: utf8 from sympy import Add from uncertainties import __version_info__ as uncert_version from uncertainties import ufloat, ufloat_fromstr from uncertainties.core import Variable, AffineScalarFunc if uncert_version < (3, 0): raise Warning("Your versi...
Z₂(g) = -1.0(4) - 2.000(4) g + 999.00(10) g²
<|file_name|>mapzen.py<|end_file_name|><|fim▁begin|>""" Mapzen geocoder, contributed by Michal Migurski of Mapzen. """ from geopy.geocoders.base import ( Geocoder, DEFAULT_FORMAT_STRING, DEFAULT_TIMEOUT ) from geopy.compat import urlencode from geopy.location import Location from geopy.util import logger ...
url = "?".join((self.reverse_api, urlencode(params)))
<|file_name|>main.rs<|end_file_name|><|fim▁begin|>fn main() { // var() // control_flow() let n = 45; let big = fib(n); println!("{}th fib: {}", n, big); } fn var() { let mut x = 5; println!("The value of x is: {}", x); x = 6; println!("The value of x is: {}", x); let tup: (i32...
fib(n - 1) + fib(n - 2) } }
<|file_name|>sdk.py<|end_file_name|><|fim▁begin|># # Copyright (c) 2001 - 2015 The SCons Foundation # # 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 ...
debug('MSCommon/sdk.py: trying to find SDK %s' % sdk.version) if sdk.get_sdk_dir(): debug('MSCommon/sdk.py:found SDK %s' % sdk.version)
<|file_name|>test-remotebackend-post.cc<|end_file_name|><|fim▁begin|>#include "pdns/namespaces.hh" #include <pdns/dns.hh> #include <pdns/dnsbackend.hh> #include <pdns/dnspacket.hh> #include <pdns/ueberbackend.hh> #include <pdns/ahuexception.hh> #include <pdns/logger.hh> #include <pdns/arguments.hh> #include <boost/lexi...
#include "pdns/packetcache.hh"
<|file_name|>TestNativeExp2.rs<|end_file_name|><|fim▁begin|>/* * Copyright (C) 2016 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....
#pragma rs java_package_name(android.renderscript.cts)
<|file_name|>user.rs<|end_file_name|><|fim▁begin|>use std::convert::From; use crypto; use diesel; use errors::Error; use diesel::prelude::*; use data::schema::users; use data::users::{User as ModelUser, NewUser as ModelNewUser}; #[derive(Serialize, Deserialize)] pub struct User { pub id: Uuid, pub email: Stri...
}
<|file_name|>UUIDUtil.java<|end_file_name|><|fim▁begin|>package com.stt.util2; import java.util.UUID; /** * @Author shitongtong * <p> * Created by shitongtong on 2017/3/24. */ public class UUIDUtil { /** * 带"-"分割的 * @return */ public static String randomUUID(){ return UUID.randomUU...
* 去"-"分割 * @param uuid * @return