text stringlengths 54 60.6k |
|---|
<commit_before>97681cb8-2e4d-11e5-9284-b827eb9e62be<commit_msg>976d18a8-2e4d-11e5-9284-b827eb9e62be<commit_after>976d18a8-2e4d-11e5-9284-b827eb9e62be<|endoftext|> |
<commit_before>4822defe-2e4d-11e5-9284-b827eb9e62be<commit_msg>4827f7ae-2e4d-11e5-9284-b827eb9e62be<commit_after>4827f7ae-2e4d-11e5-9284-b827eb9e62be<|endoftext|> |
<commit_before>#include "stan/math/functions/falling_factorial.hpp"
#include <gtest/gtest.h>
TEST(MathFunctions, falling_factorial) {
using stan::math::falling_factorial;
EXPECT_FLOAT_EQ(4, falling_factorial(4.0,3));
EXPECT_FLOAT_EQ(0.25, falling_factorial(3.0,4));
EXPECT_THROW(falling_factorial(-1,... |
<commit_before>/* IBM_PROLOG_BEGIN_TAG */
/* This is an automatically generated prolog. */
/* */
/* $Source: src/usr/isteps/istep14/call_proc_exit_cache_contained.C $ ... |
<commit_before>#ifndef INCLUDE_AL_MATH_RANDOM_HPP
#define INCLUDE_AL_MATH_RANDOM_HPP
/* Allocore --
Multimedia / virtual environment application class library
Copyright (C) 2009. AlloSphere Research Group, Media Arts & Technology, UCSB.
Copyright (C) 2012. The Regents of the University of California.
All rights r... |
<commit_before>#include "OpenCV.h"
#include "Matrix.h"
#include <nan.h>
void OpenCV::Init(Local<Object> target) {
Nan::HandleScope scope;
// Version string.
char out [21];
int n = sprintf(out, "%i.%i", CV_MAJOR_VERSION, CV_MINOR_VERSION);
target->Set(Nan::New<String>("version").ToLocalChecked(), Nan::New<St... |
<commit_before>#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <getopt.h>
#include <vector>
#include "Options.h"
#include "capture.h"
#include "xalt_config.h"
#include "base64.h"
double convert_double(const char* name, const char* s)
{
char *p;
double v;
v = strtod(s, &p);
if (p == s || *... |
<commit_before>/*
* qmidi (QMidi.cpp)
* Part of QMidi (http://github.com/waddlesplash/qtmidi).
*
* Copyright (c) 2012 WaddleSplash
*
* 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 w... |
<commit_before>#include <string>
#include "PCLink.hpp"
PCLink::PCLink(void)
: usbLink(64, 64, RJ_VENDOR_ID, RJ_PRODUCT_ID, RJ_RELEASE) {}
PCLink::PCLink(uint16_t vendorID = RJ_VENDOR_ID,
uint16_t productID = RJ_PRODUCT_ID,
uint16_t release = RJ_RELEASE)
: usbLink(64, 64, vendorID... |
<commit_before>#include <iostream>
#include <vector>
using namespace std;
void separatearg(vector<char* > &flags, vector<char* > &dirfiles, int argc, char** argv);
void printarg(vector<char* > flags, vector<char* > dirfiles); //FOR error checking
int checkflags(vector<char* > flags);
int flagset(char flag);
void... |
<commit_before>#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <dirent.h>
#include <pwd.h>
#include <grp.h>
#include <errno.h>
#include <iostream>
#include <vector>
#include <stdio.h>
#include <stdlib.h>
#include <cstring>
#define FLAG_a 1
#define FLAG_R 2
#define FLAG_l 4
#define PERMISSION(x... |
<commit_before>#include <algorithm>
#include <cstdlib>
#include <ctime>
#include <cstring>
#include <stdio.h>
#include <iomanip>
#include <sys/types.h>
#include <pwd.h>
#include <grp.h>
#include <unistd.h>
#include <dirent.h>
#include <errno.h>
#include <vector>
#include <string>
#include <sys/stat.h>
#include <iostrea... |
<commit_before>#include <iostream>
#include <fstream>
#include <stdio.h>
#include <unistd.h>
#include "errno.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <sys/mman.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <string>
#include <vector>
#include <list>
#include <iterator>
#include <... |
<commit_before>#include <iostream>
#include <unistd.h>
#include <sys/stat.h>
#include <stdio.h>
#include <vector>
#include <sstream>
#include <dirent.h>
#include <errno.h>
#include <sys/types.h>
using namespace std;
bool isDirectory(char* directoryName) {
struct stat directoryInCurrent;
if (-1 == (stat(directoryN... |
<commit_before>#include <iostream>
#include <fstream>
#include <stdio.h>
#include <unistd.h>
#include "errno.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <sys/mman.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <string>
#include <vector>
#include <list>
#include <iterator>
#include <... |
<commit_before>/**
* Copyright 2012 FAU (Friedrich Alexander University of Erlangen-Nuremberg)
*
* 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... |
<commit_before>/*
* Copyright 2000-2008, François Revol, <[email protected]>. All rights reserved.
* Distributed under the terms of the MIT License.
*/
#include "Utils.h"
#include <FindDirectory.h>
#include <Path.h>
#include <String.h>
#include <BeBuild.h>
#include <malloc.h>
#include <stdio.h>
// some private font ... |
<commit_before>//===========================================
// PC-BSD source code
// Copyright (c) 2016, PC-BSD Software/iXsystems
// Available under the 3-clause BSD license
// See the LICENSE file for full details
//===========================================
#include "TrayUI.h"
#ifdef __FreeBSD__
#include <sys... |
<commit_before>//-----------------------------------------------------------------------bl-
//--------------------------------------------------------------------------
//
// GRINS - General Reacting Incompressible Navier-Stokes
//
// Copyright (C) 2010-2013 The PECOS Development Team
//
// This library is free softw... |
<commit_before>/****************************************************************/
/* DO NOT MODIFY THIS HEADER */
/* MOOSE - Multiphysics Object Oriented Simulation Environment */
/* */
/* (c) 2010 Battelle Energy... |
<commit_before>#ifndef DUNE_MULTISCALE_SRC_COMMON_HH
#define DUNE_MULTISCALE_SRC_COMMON_HH
#ifdef HAVE_CMAKE_CONFIG
#include "cmake_config.h"
#elif defined (HAVE_CONFIG_H)
#include <config.h>
#endif // ifdef HAVE_CMAKE_CONFIG
#undef ENABLE_MPI
// polynomial order of discrete space
#ifndef POLORDER
#define POLORD... |
<commit_before>// Time: O(n)
// Space: O(h)
/**
* Definition of TreeNode:
* class TreeNode {
* public:
* int val;
* TreeNode *left, *right;
* TreeNode(int val) {
* this->val = val;
* this->left = this->right = NULL;
* }
* }
*/
class Solution {
public:
/**
* This met... |
<commit_before>//FRAGMENT(includes)
#include <seqan/seeds.h>
using namespace seqan;
// FRAGMENT(writeSeed)
template<typename TSeed, typename TSeq>
void
writeSeed(TSeed & seed, TSeq const & seq0, TSeq const & seq1) {
std::cout << "Seed from position " << leftPosition(seed, 0);
std::cout << " to " << rightPosit... |
<commit_before>#ifndef STAN_MATH_OPENCL_KERNEL_GENERATOR_COLWISE_REDUCTION_HPP
#define STAN_MATH_OPENCL_KERNEL_GENERATOR_COLWISE_REDUCTION_HPP
#ifdef STAN_OPENCL
#include <stan/math/prim/meta.hpp>
#include <stan/math/opencl/opencl_context.hpp>
#include <stan/math/opencl/matrix_cl_view.hpp>
#include <stan/math/opencl/k... |
<commit_before>#include "system/payload_system.hpp"
#include "util/time.hpp"
#include "ch.hpp"
#include "chprintf.h"
PayloadSystem::PayloadSystem(
Accelerometer& accel,
optional<Accelerometer *> accelH,
optional<Barometer *> bar,
optional<GPS *> gps,
Gyroscope& gyr,
optional<Magnetometer *> ma... |
<commit_before>#include "TerrainMap.hpp"
#include <limits>
#include <lcm/lcm-cpp.hpp>
#include <lcmtypes/bot_core/pose_t.hpp>
#include <drc_utils/BotWrapper.hpp>
#include <maps/BotWrapper.hpp>
#include <maps/ViewClient.hpp>
#include <maps/DepthImage.hpp>
#include <maps/DepthImageView.hpp>
#include "FillMethods.hpp... |
<commit_before>/*
* 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; version 3 of the License.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; ... |
<commit_before>//
// mc.cpp
//
// manage c++ code
//
// Created by Daniel Kozitza
//
#include <csignal>
#include <dirent.h>
#include <fstream>
#include <iomanip>
#include <sys/ioctl.h>
#include "commands.hpp"
#include "tools.hpp"
using namespace tools;
void build(vector<string>& argv);
void cnt();
void dec(vector<st... |
<commit_before>//
// Alert system
//
#include <algorithm>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/replace.hpp>
#include <boost/foreach.hpp>
#include <map>
#include "alert.h"
#include "key.h"
#include "net.h"
#include "sync.h"
#include "ui_interface.h"
using namespace std... |
<commit_before>//
// Alert system
//
#include <algorithm>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/replace.hpp>
#include <boost/foreach.hpp>
#include <map>
#include "alert.h"
#include "key.h"
#include "net.h"
#include "sync.h"
#include "ui_interface.h"
using namespace std... |
<commit_before>#include "translator.hpp"
#include "decl.hpp"
#include "type.hpp"
#include "context.hpp"
#include "expr.hpp"
#include "action.hpp"
// for testing only
#include <iostream>
namespace pip
{
translator::translator(context& cxt)
: cxt(cxt)
{ }
/// program ::= (pip <decl-seq>)
decl*
translator... |
<commit_before>// Copyright (c) 2012-2019 The Syscoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <util/memory.h>
#include <util/system.h>
#include <util/time.h>
#include <validation.h>
#include <te... |
<commit_before>/*************************************************************************
*
* $RCSfile: rsckey.hxx,v $
*
* $Revision: 1.3 $
*
* last change: $Author: obo $ $Date: 2005-01-03 17:22:13 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licens... |
<commit_before>#include "Genes/Look_Ahead_Gene.h"
#include <cassert>
#include <memory>
#include <algorithm>
#include "Genes/Gene.h"
#include "Utility.h"
#include "Game/Board.h"
#include "Game/Clock.h"
class Move;
Look_Ahead_Gene::Look_Ahead_Gene() :
mean_game_length(50),
game_length_uncertainty(0.5),
sp... |
<commit_before>#include <GuiBase/Viewer/Viewer.hpp>
#include <iostream>
#include <QTimer>
#include <QMouseEvent>
#include <QPainter>
#include <Core/String/StringUtils.hpp>
#include <Core/Log/Log.hpp>
#include <Core/Math/ColorPresets.hpp>
#include <Core/Math/Math.hpp>
#include <Core/Containers/MakeShared.... |
<commit_before>/* This file is part of the KDE project.
Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
This library is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 2.1 o... |
<commit_before>#include <babylon/materialslibrary/gradient/gradient_material.h>
#include <nlohmann/json.hpp>
#include <babylon/buffers/vertex_buffer.h>
#include <babylon/cameras/camera.h>
#include <babylon/engines/engine.h>
#include <babylon/engines/scene.h>
#include <babylon/materials/effect.h>
#include <babylon/mat... |
<commit_before>// TODO(ralntdir):
// Think how to clean SDL if the programs ends with some crash
// Finished the program if there is a problem at SDL/IMG init or
// when creating the window or the renderer
#include <iostream>
#include <SDL2/SDL.h>
#include <SDL2/SDL_image.h>
// TODO(ralntdir): read this from a scene... |
<commit_before>// Copyright eeGeo Ltd (2012-2015), All Rights Reserved
#include "SelectFirstResultSearchService.h"
#include "SearchQueryPerformer.h"
#include "InteriorInteractionModel.h"
#include "IMenuOption.h"
#include "SearchResultModel.h"
#include "ISearchResultRepository.h"
#include "IMenuModel.h"
namespace Exam... |
<commit_before>/*
** Copyright (C) 2012, 2013 Aldebaran Robotics
** See COPYING for the license
*/
#include <qi/type/detail/staticobjecttype.hpp>
#include <qi/anyobject.hpp>
#include <qi/signal.hpp>
#include <qi/property.hpp>
#include <qi/jsoncodec.hpp>
#include <qi/strand.hpp>
qiLogCategory("qitype.object");
names... |
<commit_before>#ifndef BTREEINC
#include <binarytree.h>
#define BTREEINC
#endif
template <class T>
BinaryTree<T>::BinaryTree()
: root(nullptr), levels(0) {}
template <class T>
BinaryTree<T>::~BinaryTree() {
delete root;
}
template <class T>
unsigned int BinaryTree<T>::Levels() const {
return levels;
}
template <... |
<commit_before>// Time: O(n^2 * l), l is the average length of words
// Space: O(n)
class Solution {
public:
int numSimilarGroups(vector<string>& A) {
UnionFind union_find(A.size());
for (int i = 0; i < A.size(); ++i) {
for (int j = 0; j < i; ++j) {
if (isSimilar(A[i], ... |
<commit_before>// $Id$
/*
Copyright (c) 2007, Trustees of Leland Stanford Junior University
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
Redistributions of source code must retain the above copyrigh... |
<commit_before>/* BEGIN_COMMON_COPYRIGHT_HEADER
* (c)LGPL2+
*
* LXDE-Qt - a lightweight, Qt based, desktop toolset
* http://razor-qt.org
*
* Copyright: 2010-2011 Razor team
* Authors:
* Alexander Sokoloff <[email protected]>
*
* This program or library is free software; you can redistribute it
* and/or ... |
<commit_before>// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/ui/views/frame/browser_desktop_root_window_host_win.h"
#include <dwmapi.h>
#include "chrome/browser/themes/t... |
<commit_before>#ifndef SUCCINCT_GRAPH_SG_HPP
#define SUCCINCT_GRAPH_SG_HPP
#include <iostream>
#include <fstream>
#include <map>
#include <omp.h>
#include "cpp/vg.pb.h"
#include "sdsl/bit_vectors.hpp"
#include "sdsl/enc_vector.hpp"
#include "sdsl/dac_vector.hpp"
#include "sdsl/vlc_vector.hpp"
#include "sdsl/wavelet_tr... |
<commit_before>/*
* Copyright 2016 Nu-book 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 ag... |
<commit_before>// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
#include "common.h"
#include "sal.h"
#include "gcenv.structs.h"
#include "gcenv.base.h"
#include <stdlib.h>
#pragma warning(disable:4297)
extern "C"... |
<commit_before>/**
* Copyright 2013 Truphone
*/
#include "include/KeyCommand.h"
#include <bb/cascades/AbstractTextControl>
#include <bb/cascades/Application>
#include <bb/cascades/Control>
#include "Utils.h"
#include "Connection.h"
using bb::cascades::AbstractTextControl;
using bb::cascades::Application;
using bb:... |
<commit_before>/*************************************************************************
*
* OpenOffice.org - a multi-platform office productivity suite
*
* $RCSfile: querydescriptor.cxx,v $
*
* $Revision: 1.31 $
*
* last change: $Author: vg $ $Date: 2006-11-23 14:19:48 $
*
* The Contents of this file a... |
<commit_before>/*
* Copyright (C) 2010 Telmo Menezes.
* [email protected]
*/
#include "drmap.h"
#include "utils.h"
#include "emd_hat_signatures_interface.hpp"
#include <stdlib.h>
#include <strings.h>
#include <stdio.h>
namespace syn
{
DRMap::DRMap(unsigned int bin_number, double min_val_hor, double max_va... |
<commit_before>/*
Q Light Controller Plus
e131node.cpp
Copyright (c) Massimo Callegari
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.... |
<commit_before>/**************************************************************************************/
/* */
/* Visualization Library */
/* http://www.visualizationlibrary... |
<commit_before>#include "Players/CECP_Mediator.h"
#include <string>
#include <future>
#include "Game/Board.h"
#include "Game/Clock.h"
#include "Game/Game_Result.h"
#include "Moves/Move.h"
#include "Players/Player.h"
#include "Exceptions/Illegal_Move.h"
#include "Exceptions/Game_Ended.h"
#include "Utility/String.h... |
<commit_before>#include <efirc.h>
// TODO was das wieder?
IMPLEMENT_APP(Efirc)
using namespace std;
// Empfangene normale Nachrichten werden ausgegeben
void
irc_pmsg(const irc_msg_data *msg_data, void *cp)
{
string text = msg_data->params_a[1];
string recipient = msg_data->params_a[0];
string user = msg_... |
<commit_before>#include "engine.h"
#include <cstdint>
#include <string>
#include <vector>
// gray all percent
uint_fast32_t Engine::GrayAllPercent(const uint_fast32_t pixCount, const uint_fast32_t pixDiff, const uint_fast8_t *buf0, const uint_fast8_t *buf1) {
uint_fast32_t diffs = 0;
for (uint_fast32_t i = 0; ... |
<commit_before>//============================================================================
// Name : Shader.cpp
// Author : Duarte Peixinho
// Version :
// Copyright : ;)
// Description : Shader
//============================================================================
#include "Shaders.h"
#in... |
<commit_before>#include <babylon/samples/samples_index.h>
#include <babylon/babylon_stl_util.h>
#include <babylon/core/string.h>
#include <babylon/interfaces/irenderable_scene.h>
#include <babylon/samples/animations/_animations_samples_index.h>
#include <babylon/samples/cameras/_cameras_samples_index.h>
#include <baby... |
<commit_before>/**
* @file neighborreduce.hxx
* @author Muhammad Osama ([email protected])
* @brief
* @version 0.1
* @date 2021-11-05
*
* @copyright Copyright (c) 2021
*
*/
#pragma once
#include <gunrock/cuda/context.hxx>
#include <gunrock/error.hxx>
#include <gunrock/util/type_limits.hxx>
#include <gunroc... |
<commit_before>//****************************************************************************
// Copyright © 2015 Jan Erik Breimo. All rights reserved.
// Created by Jan Erik Breimo on 2015-06-03
//
// This file is distributed under the Simplified BSD License.
// License text is included with the source distribution.
/... |
<commit_before>// @(#)root/eve:$Id$
// Author: Matevz Tadel 2007
/*************************************************************************
* Copyright (C) 1995-2007, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* ... |
<commit_before>#include "input.h"
#include "engine.h"
P<WindowManager> InputHandler::windowManager;
bool InputHandler::touch_screen = false;
sf::Transform InputHandler::mouse_transform;
PVector<InputEventHandler> InputHandler::input_event_handlers;
PVector<JoystickEventHandler> InputHandler::joystick_event_handlers;
... |
<commit_before>#include <cstdio>
#include <vector>
#include <stack>
#include <algorithm>
using namespace std;
enum class Frog { None, Brown, Green };
enum class Step { None, JumpLeft, LeapLeft, JumpRight, LeapRight };
struct FrogsState
{
size_t Count;
vector<Frog> Lilies;
int BlankPos;
Step Movemen... |
<commit_before>/*
* PluginFramework.cpp
*
* Created on: 21.06.2017
* Author: alwi0251
*/
#include "pluginFramework/impl/PluginFrameworkImpl.hpp"
#ifdef NDEBUG
#define DEBUG_MESSAGE(a) /**/
#else
#define DEBUG_MESSAGE(a) a
#endif
#define MAX_CHAR 260
typedef std::shared_ptr<MDE4CPPPlugin> (__stdcall *S... |
<commit_before>/* Copyright 2007-2015 QReal Research Group
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by ap... |
<commit_before>// @(#)root/qtgsi:$Id$
// Author: Denis Bertini, M. Al-Turany 01/11/2000
/*************************************************************************
* Copyright (C) 1995-2006, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* ... |
<commit_before>#include "GMSAssetResourceManagementSystem.hpp"
#include "../AssetResources/TextureInfoResource.hpp"
#include "../AssetResources/GMSRoomResource.hpp"
#include <KEngine/Events/OtherGraphicsEvents.hpp>
#include <KEngine/App.hpp>
#include <KEngine/Core/EventManager.hpp>
#include <KEngine/Utility/FileSyste... |
<commit_before>#ifdef CHEMISTRY_GPU
#include "chemistry_gpu.h"
#include "../grid3D.h"
#include "../io.h"
#ifdef DE
#include"../hydro_cuda.h"
#endif
void Grid3D::Initialize_Chemistry( struct parameters *P ){
chprintf( "Initializing the GPU Chemistry Solver... \n");
Chem.nx = H.nx;
Chem.ny = H.ny;
Chem.... |
<commit_before><commit_msg>Prediction: minor fixes.<commit_after><|endoftext|> |
<commit_before>#ifndef CTHREADPOOLITEM_RET
#define CTHREADPOOLITEM_RET
#include<functional> //bind, ref
#include<utility> //forward
#include"../../lib/header/tool/CScopeGuard.hpp"
#include"../../lib/header/thread/CTask.hpp"
#include"../../lib/header/thread/CWait_bounded_queue.hpp"
#include"IThreadPoolItemBase.hpp"
nam... |
<commit_before>#include <iostream> /* allows to perform standard input and output operations */
#include <fstream>
#include <stdio.h> /* Standard input/output definitions */
#include <stdint.h> /* St... |
<commit_before>#include <iostream> /* allows to perform standard input and output operations */
#include <stdio.h> /* Standard input/output definitions */
#include <stdint.h> /* Standard input/output... |
<commit_before>/** @file
@brief Main file for a unified video-based and inertial tracking system.
@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... |
<commit_before>#include "commands.h"
#include <chrono>
#include <iostream>
#include "BuildAction.h"
#include "FileStates.h"
using namespace aBuild;
namespace commands {
bool build(std::string const& rootProjectName, bool verbose, bool noconsole, int jobs) {
std::vector<Project const*> rootProjects;
Workspace ws... |
<commit_before>#include "list.h"
#include "gtest/gtest.h"
#include <string>
class listTest : public testing::Test {
protected:
virtual void SetUp() {
list_1.insert(list_1.begin(), 10);
int_iter = list_1.insert(list_1.end(), 30);
int_iter = list_1.insert(int_iter, 20);
str = "a string";
}
virtua... |
<commit_before>#ifndef LIGHTGBM_PREDICTOR_HPP_
#define LIGHTGBM_PREDICTOR_HPP_
#include <LightGBM/meta.h>
#include <LightGBM/boosting.h>
#include <LightGBM/utils/text_reader.h>
#include <LightGBM/dataset.h>
#include <LightGBM/utils/openmp_wrapper.h>
#include <cstring>
#include <cstdio>
#include <vector>
#include <ut... |
<commit_before>/**************************************************************************
**
** This file is part of Qt Creator
**
** Copyright (c) 2011 Nokia Corporation and/or its subsidiary(-ies).
**
** Contact: Nokia Corporation ([email protected])
**
** No Commercial Usage
**
** This file contains pre-release cod... |
<commit_before>#include <QtTest>
#include <timing/calendartiming.h>
class TestCalendarTiming : public QObject
{
Q_OBJECT
private slots:
void constructors()
{
CalendarTiming timing;
QCOMPARE(timing.type(), QLatin1String("calendar"));
}
void nextRuns()
{
QTime time = Q... |
<commit_before>/*
* The Apache Software License, Version 1.1
*
* Copyright (c) 1999-2000 The Apache Software Foundation. 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. Redi... |
<commit_before>/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2008 Robert Osfield
*
* This application is open source and may be redistributed and/or modified
* freely and without restriction, both in commericial and non commericial applications,
* as long as this copyright notice is maintained.
*
* This a... |
<commit_before>/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
*
* This application is open source and may be redistributed and/or modified
* freely and without restriction, both in commericial and non commericial applications,
* as long as this copyright notice is maintained.
*
* This a... |
<commit_before>#include "sm/logging.hpp"
#include <string>
#include <boost/algorithm/string.hpp> // for case-insensitive string comparison
/**
* \brief Returns a Level enum from string
*/
sm::logging::Level sm::logging::levels::fromString(const std::string& l) {
// enum Level
// {
// All,
// Fine... |
<commit_before>#include "Halide.h"
using namespace Halide;
void blur_float(std::string suffix, ImageParam input8, const int channels) {
Var x, y, c;
Func input;
input(x, y, c) = input8(clamp(x, input8.left(), input8.right()),
clamp(y, input8.top(), input8.bottom()), c);
Fu... |
<commit_before>// Copyright (c) 2015 GitHub, Inc.
// Use of this source code is governed by the MIT license that can be
// found in the LICENSE file.
#include <memory>
#include "atom/browser/api/atom_api_cookies.h"
#include "atom/browser/atom_browser_context.h"
#include "atom/common/native_mate_converters/callback.h... |
<commit_before>// copy of avx512bw.cpp, but use masked writes instead of explicit bit-or operations
#include <cstdint>
#include <immintrin.h>
void jpeg_zigzag_avx512bw_masks(const uint8_t* in, uint8_t* out) {
const __m512i v = _mm512_loadu_si512((const __m512i*)in);
// populate lanes -- each lane repres... |
<commit_before>// Copyright (c) 2006-2008 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 <windows.h>
#include "base/gfx/platform_canvas_win.h"
#include "base/gfx/platform_device_win.h"
#include "testing/gtest/... |
<commit_before>/*******************************************************************************
* benchmarks/word_count/word_count.cpp
*
* Runner program for WordCount example. See thrill/examples/word_count.hpp for
* the source to the example.
*
* Part of Project Thrill.
*
* Copyright (C) 2015 Timo Bingmann <t... |
<commit_before>/* mainwindow.cpp
* code for the main application window, actions, etc. */
#include <QDesktopServices>
#include <QDesktopWidget>
#include <QFileDialog>
#include <QInputDialog>
#include <QMdiArea>
#include <QMdiSubWindow>
#include <QMessageBox>
#include <QPainter>
#include <QPrintDialog>
#include <QPrin... |
<commit_before>// Copyright (c) 2018 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 la... |
<commit_before>#include "syntaxanalyzer.h"
#include "lexicalanalyzer.h"
#include <QMetaType>
SyntaxAnalyzer::SyntaxAnalyzer(QObject *parent) :
QObject(parent),
m_lexicalAnalyzer(new LexicalAnalyzer(this)),
m_exprCalculator(new ExprCalculator(this))
{
}
SyntaxAnalyzer::~SyntaxAnalyzer()
{
}
QString SyntaxAnalyzer... |
<commit_before>// stdafx.cpp : source file that includes just the standard includes
// Scrub Cup Work.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
#include "stdafx.h"
// TODO: reference any additional headers you need in STDAFX.H
// and not in this file
<com... |
<commit_before>/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
* This file is part of the LibreOffice project.
*
* 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 ... |
<commit_before>#include <iostream>
#include <string>
#include <vector>
#include <sstream>
#include "util.hpp"
#include "range.hpp"
#include "grid.hpp"
#include "hint.hpp"
#include "hintconsumer.hpp"
#include "singlehint.hpp"
#include "hiddendouble.hpp"
#include "forcingchain.hpp"
#include "pointing.hpp"
#include "boxl... |
<commit_before>/*
* Copyright (c) 2017 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 requir... |
<commit_before><commit_msg>Tweaking the window settings to improve performance by not drawing an additional system background<commit_after><|endoftext|> |
<commit_before>#include "pcsclite.h"
#include "cardreader.h"
using namespace v8;
using namespace node;
void init_all(Local<Object> target) {
PCSCLite::init(target);
CardReader::init(target);
}
NODE_MODULE(pcsclite, init_all)
<commit_msg>src: make the module Context aware<commit_after>#include "pcsclite.h"
#i... |
<commit_before>/*=========================================================================
Program: Monteverdi
Language: C++
Copyright (c) Centre National d'Etudes Spatiales. All rights reserved.
See Copyright.txt for details.
Monteverdi is distributed under the CeCILL licence version 2. See
Licence_... |
<commit_before>#include "ics3/angle.hpp"
#define _USE_MATH_DEFINES
#include <cmath>
ics::Angle ics::Angle::newDegree() noexcept {
static const double limit = 130;
static const Angle DEGREE(-limit, limit, 800.0 / 27.0);
return DEGREE;
}
ics::Angle ics::Angle::newRadian() noexcept {
static const double limit =... |
<commit_before>/* listener.cc
Mathieu Stefani, 12 August 2015
*/
#include <pistache/common.h>
#include <pistache/errors.h>
#include <pistache/listener.h>
#include <pistache/os.h>
#include <pistache/peer.h>
#include <pistache/transport.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <netinet/in.h>
#include <... |
<commit_before>/* listener.cc
Mathieu Stefani, 12 August 2015
*/
#include <pistache/listener.h>
#include <pistache/peer.h>
#include <pistache/common.h>
#include <pistache/os.h>
#include <pistache/transport.h>
#include <pistache/errors.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
#in... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.