text stringlengths 3.08k 12.5k |
|---|
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <mpi.h>
#include <quda_internal.h>
#include <comm_quda.h>
#define MPI_CHECK(mpi_call) do { \
int status = mpi_call; \
if (status != MPI_SUCCESS) { \
char err_string[128]; ... |
/*
* Copyright (c) 2010-2015 OTClient <https://github.com/edubart/otclient>
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights... |
#include "SceneManager.h"
#include "unitTestDelegate.h"
#include "pxr/imaging/hdx/renderTask.h"
#include <pxr/imaging/garch/glDebugWindow.h>
static pxr::GfMatrix4d
_GetTranslate(float tx, float ty, float tz)
{
pxr::GfMatrix4d m(1.0f);
m.SetRow(3, pxr::GfVec4f(tx, ty, tz, 1.0));
return m;
}
Sc... |
#include "LindenbergResearch.hpp"
#include "LRComponents.hpp"
#include "LRModel.hpp"
using namespace rack;
using namespace lrt;
Menu *LRModuleWidget::createContextMenu() {
Menu *menu = ModuleWidget::createContextMenu();
auto count = panel->pool.size() - 1; // NIL does not count!
if (noVariants) return... |
/* Copyright 2015 <NAME> */
#include <thrift/protocol/TBinaryProtocol.h>
#include <thrift/transport/TSocket.h>
#include <thrift/transport/TTransportUtils.h>
#include <stdlib.h>
#include <sys/time.h>
#include <vector>
#include "../gen-cpp/MovingAverageService.h"
using std::cout;
using std::endl;
using apache::thrif... |
/* -*- mode: C++; c-basic-offset: 4; indent-tabs-mode: nil -*- */
// vim: ft=cpp:expandtab:ts=8:sw=4:softtabstop=4:
#ident "$Id$"
/*======
This file is part of PerconaFT.
Copyright (c) 2006, 2015, Percona and/or its affiliates. All rights reserved.
PerconaFT is free software: you can redistribute it and/or modif... |
/* -------------------------------------------------------------------------
*
* hashinsert.cpp
* Item insertion in hash tables for Postgres.
*
* Portions Copyright (c) 2020 Huawei Technologies Co.,Ltd.
* Portions Copyright (c) 1996-2012, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regen... |
#include <librg.h>
#include <squirrel.h>
#include "sqrdbg.h"
#include "sqdbgserver.h"
SQInteger debug_hook(HSQUIRRELVM v);
SQInteger error_handler(HSQUIRRELVM v);
#include "serialize_state.inl"
HSQREMOTEDBG sq_rdbg_init(HSQUIRRELVM v,unsigned short port,SQBool autoupdate)
{
WSADATA wsadata;
sockaddr_in ... |
// Copyright <NAME> 2021.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at https://www.boost.org/LICENSE_1_0.txt)
#pragma once
#include "../exception.hpp"
#include "../strings.hpp"
#include "../concepts.hpp"
#include <string>
#include <unordered_map>
#... |
#define MS_CLASS "mediasoup-worker"
// #define MS_LOG_DEV_LEVEL 3
#include "common.hpp"
#include "DepLibSRTP.hpp"
#include "DepLibUV.hpp"
#include "DepLibWebRTC.hpp"
#include "DepOpenSSL.hpp"
#include "DepUsrSCTP.hpp"
#include "Logger.hpp"
#include "MediaSoupErrors.hpp"
#include "Settings.hpp"
#include "Utils.hpp"
#in... |
#include "Texture.h"
#include <Windows.h>
#include <gl\GL.h>
#include <gl\GLU.h>
#include <gl\glew.h>
#include <gl\glut.h>
#include <assert.h>
#include <fstream>
Texture::Texture()
{
}
Texture::Texture(char* ps, int w, int h)
{
pixels = ps;
width = w;
height = h;
}
//Converts a four-character array to an inte... |
/* Copyright 2017-2018 <NAME>, <NAME>, CyberTech Labs Ltd.
*
* 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... |
#include <vector>
#include <string>
#include <list>
#include <fstream>
#include <algorithm>
#include "CatalogManager.h"
#include "../API/ApiHelper.h"
using namespace std;
void CatalogManager::CreateTable(const std::string &table_name,
const std::vector<std::pair<std::string, SqlValu... |
#ifdef _OPENMP
#include <omp.h>
#endif
#include "../src/stdint.h"
#include <string.h>
#include <stdlib.h>
#include "gf16mul.h"
#define CACHELINE_SIZE 64
#include "gfmat_coeff.h"
void ppgf_init_constants() {
gfmat_init();
}
static Galois16Mul* gf = NULL;
static std::vector<void*> gfScratch;
static int maxNumThreads... |
/**
* Copyright (C) <NAME> <<EMAIL>> - All Rights Reserved
* Unauthorized copying of this file, via any medium is strictly prohibited
* Proprietary and confidential
*
* Written by <NAME> <<EMAIL>>, 2017
*/
#include <iostream>
#include <iomanip>
#include "sp/algo/nn.hpp"
#include "sp/util/dataset.hpp"
#include "... |
/*****************************************************************************************
* *
* OpenSpace *
* ... |
#include <iostream>
#include <string>
#include <fstream>
#include <vector>
#include <cmath>
#include <algorithm>
#include <time.h>
#include <cstdio>
#include <cstdlib>
#include <boost/lexical_cast.hpp>
#include <boost/tokenizer.hpp>
using namespace std;
struct percent_count {
double first;
double second;
... |
#include "master.h"
#include "ui_gameover.h"
#include "player.h"
#include "random.h"
using namespace pyrodactyl;
void GameOverMenu::Init(const char* filename)
{
XMLDoc layout_doc(filename);
if (layout_doc.ready())
{
rapidxml::xml_node<char> *node = layout_doc.Doc()->first_node("game_over");
if (NodeValid(node)... |
// Copyright (C) 2011-2019 Internet Systems Consortium, Inc. ("ISC")
//
// 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/.
#include <config.h>
#include <algorithm>
#in... |
#include <math.h>
#include <stdio.h>
#include "c_plus.hpp"
C_Plus::C_Plus(void)
{
//goldsmith et al. 2012 section 2
g_l = 2; //lower
g_u = 4; //upper
g = g_u/g_l; //ratio
T_star = 91.25; //Kelvin
A_ul = 2.3e-6; //per second
h = 6.626069e-27; //planck constant in cgs
nu_C_plus = 1900.537e9... |
#include<iostream>
using namespace std;
class NODE {
public:
int val,Nth_Node;
NODE *par,*left, *right;
NODE() {}
NODE(const int &x) {
val=x;
Nth_Node=1;
par=NULL;
left=NULL;
right=NULL;
}
inline void calc(void) {
int l,r;
if (left==NULL) l=0; else l=left->Nth_Node;
if (right==NULL... |
/*
Network File Converter
Authour:<NAME>
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, Vers... |
// ui
#include <core/ui_manager.h>
#include <util/ui_aniamtion.h>
#include <core/ui_color_list.h>
#include <control/ui_control.h>
#include <style/ui_native_style.h>
#include <graphics/ui_bg_renderer.h>
#include <graphics/ui_bd_renderer.h>
#include <graphics/ui_graphics_impl.h>
/// <summary>
/// Deletes the renderer.
... |
/*
* Copyright (c) 2004-2007,2013 Apple Inc. All Rights Reserved.
*
* @APPLE_LICENSE_HEADER_START@
*
* This file contains Original Code and/or Modifications of Original Code
* as defined in and that are subject to the Apple Public Source License
* Version 2.0 (the 'License'). You may not use this file except i... |
#include <vector>
#include "z3++.h"
z3::expr
arbitrary_expr(z3::context& ctx, std::vector<z3::expr>& vars)
{
z3::expr zero = ctx.int_val(0);
z3::expr x_13 = vars.at(13);
z3::expr x_50 = vars.at(50);
z3::expr t_add = x_13 + x_50;
return z3::ite(t_add != 0, z3::rem(zero, t_add), zero);
}
z3::expr
z... |
/*
* Copyright (c) 2017, STMicroelectronics - All Rights Reserved
*
* This file : part of VL53L1 Core and : dual licensed,
* either 'STMicroelectronics
* Proprietary license'
* or 'BSD 3-clause "New" or "Revised" License' , at your option.
*
******************************************************************************... |
#include "aifollow.hpp"
#include <iostream>
#include <components/esm/aisequence.hpp>
#include "../mwbase/world.hpp"
#include "../mwbase/environment.hpp"
#include "../mwworld/class.hpp"
#include "../mwworld/cellstore.hpp"
#include "creaturestats.hpp"
#include "movement.hpp"
#include <OgreMath.h>
#include "steering.... |
// Copyright (c) 2009-2010 <NAME>
// Copyright (c) 2009-2017 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <pow.h>
#include <arith_uint256.h>
#include <chain.h>
#include <primitives/block.... |
#include<iostream>
#include<cstdio>
#include<sstream>
#include<algorithm>
#define pow2(n) (1 << (n))
using namespace std;
struct avl_node
{
int data;
struct avl_node *left;
struct avl_node *right;
}*root;
class avlTree
{
public:
int height(avl_node *);
int diff(avl_node *);
a... |
/******************************************************************************
/ LivePresetsExtension
/
/ Represents a send object, respective receives are ignored as they are implicite with the sends
/
/ Copyright (c) 2020 and later Dr. med. <NAME>
/
/
/ Permission is hereby granted, free of charge, to any person obt... |
#include "math/amath.h"
#include <float.h>
#include <vector>
/*!
\class AABBox
\brief The AABBox class represents a Axis Aligned Bounding Box in 3D space.
\since Next 1.0
\inmodule Math
Bounded volume in space in the form of a rectangular parallelepiped, with a period parallel to the coordinate a... |
#pragma once
//lib c++
#include <iostream>
#include <string.h>
#include <vector>
#include <boost/function.hpp>
#include <boost/signals2.hpp>
//lib ros
#include <ros/ros.h>
//msgs
#include <pouco2000_ros_msgs/Controller.h>
#include <pouco2000_ros_msgs/Buttons.h>
#include <pouco2000_ros_msgs/SwitchsOnOff.h>
#include ... |
/*
* Copyright 2019 Xilinx, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... |
#include <stdio.h>
#include "stopwatch.h"
#include "robot.h"
using namespace elma;
using namespace std;
using json = nlohmann::json;
struct stype {
string from;
string to;
string when;
};
namespace ns {
// a simple struct to model a person
struct person {
std::string name;
std::st... |
/*
* All or portions of this file Copyright (c) Amazon.com, Inc. or its affiliates or
* its licensors.
*
* For complete copyright and license terms please see the LICENSE at the root of this
* distribution (the "License"). All use of this software is governed by the License,
* or, if provided, by the license below or t... |
// Copyright 2020 <NAME>
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in wr... |
/**
* \class CorrelationTemplate
*
*
* Description: L1 Global Trigger correlation template.
* Includes spatial correlation for two objects of different type.
*
* Implementation:
* <TODO: enter implementation details>
*
* \author: <NAME> - HEPHY Vienna
*
* $Date$
* $Revision$
*
*/
// this class header... |
//
// thread test
//
#include <iostream>
#include <string>
#include <vector>
#include <map>
#include <set>
#include <fstream>
#include <windows.h>
#include <mmsystem.h>
#include <process.h>
#include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/objdetect/objdetect.hpp"
#include "opencv2/highgui/highgui.hpp"
#ifdef... |
/*****************************************************************
|
| AP4 - moov Atoms
|
| Copyright 2002 <NAME>
|
|
| This file is part of Bento4/AP4 (MP4 Atom Processing Library).
|
| Unless you have obtained Bento4 under a difference license,
| this version of Bento4 is Bento4|GPL.
| Bento4|GPL i... |
// Copyright 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 law or agreed to in ... |
#include <vector>
#include <algorithm>
#include <cctype>
#include <string>
#include <iostream>
#include <fstream>
#include <bitset>
#include <cmath>
#include <numeric>
#include <cassert>
const char* hex_char_to_bin(char c){
switch(std::toupper(c)){
case '0': return "0000";
case '1': return "0001";
case '2... |
#include "read_mealy.hpp"
#include "mealy.hpp"
#include <cassert>
#include <cctype>
#include <fstream>
#include <sstream>
#include <stdexcept>
#include <string>
using namespace std;
static string easy_substr(string const & s, size_t begin, size_t end){
return s.substr(begin, end - begin);
}
static string trim_copy... |
/*
* Copyright (C) 2010- 2013 Project TBEmu <http://www.trueblood-servers.com/>
* by JeanClaude
*/
/*************
**<NAME>
**************/
#include "ScriptPCH.h"
#include "Spell.h"
#include "SpellAuraEffects.h"
#include "SpellScript.h"
#define SAY_AGGRO "That bitch Sylvanas sent you too, did she? No matter, you... |
#include "backward.h"
#include "logger.h"
BackwardMatrix::BackwardMatrix (const EvaluatedMachine& machine, const SeqPair& seqPair) :
DPMatrix (machine, seqPair)
{
fill();
}
BackwardMatrix::BackwardMatrix (const EvaluatedMachine& machine, const SeqPair& seqPair, const Envelope& env) :
DPMatrix (machine, seqPair,... |
int source();
void sink(int);
// This class has the opposite behavior of what the member function names suggest.
struct Top {
virtual int isSource1() { return 0; }
virtual int isSource2() { return 0; }
virtual void isSink(int x) { }
virtual int notSource1() { return source(); }
virtual int notSource2() { ret... |
/**
* \file PnlWdbeNavPre.cpp
* job handler for job PnlWdbeNavPre (implementation)
* \copyright (C) 2016-2020 MPSI Technologies GmbH
* \author <NAME> (auto-generation)
* \date created: 28 Nov 2020
*/
// IP header --- ABOVE
#ifdef WDBECMBD
#include <Wdbecmbd.h>
#else
#include <Wdbed.h>
#endif
#include "PnlWdbe... |
/*******************************************************************************
Copyright (c) 2017, Honda Research Institute Europe GmbH
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
1. Redistributions of sour... |
#include "ircserv.hpp"
#include "commands.hpp"
#include "message.hpp"
#include "tools.hpp"
/* Command: WHO
Parameters: [ <mask> [ "o" ] ]
The WHO command is used by a client to generate a query which returns
a list of information which 'matches' the <mask> parameter given by
the client.
In the absence of the <ma... |
// main51.cc is a part of the PYTHIA event generator.
// Copyright (C) 2014 <NAME>.
// PYTHIA is licenced under the GNU GPL version 2, see COPYING for details.
// Please respect the MCnet Guidelines, see GUIDELINES for details.
// Test of LHAPDF interface and whether PDF's behave sensibly.
#include "Pythia8/Pythia.h"... |
///////////////////////////////////////////////////////////////////////////////
// $Id$
//
// 3DimViewer
// Lightweight 3D DICOM viewer.
//
// Copyright 2008-2016 3Dim Laboratory s.r.o.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with ... |
/*
* Copyright (c) 2007, Laminar Research.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, ... |
#include "isl28022DL.h"
void power_isl28022::begin(int _address)
{
// Set up ISL28022 Power Monitor IC
// Test the ISL28022
Wire.begin(); // Join the bus as Master
delay(20); // Short settling delay
// Reset the Configuration Register
Serial.print("Start: ");
Serial.println(_address);
Wire.beginTra... |
/**
* Copyright 2014 Social Robotics Lab, University of Freiburg
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* # Redistributions of source code must retain the above copyright
* notice, this list of condi... |
#include "stdafx.h"
#include "Level3.h"
#include "Billboard.h"
#include "Collisions.h"
#include "Rasterizer.h"
#include "PostProcessing.h"
Level3::Level3( LevelStateMachine& stateMachine ) : levelStateMachine( stateMachine ) {}
bool Level3::OnCreate()
{
try
{
// Renderables
if ( !ModelData::LoadModelData( "Leve... |
/**
* Copyright (c) 2014-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include "S... |
/*
* Copyright (c) 2017, CATIE, All Rights Reserved
* SPDX-License-Identifier: Apache-2.0
*
* 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... |
/*
-----------------------------------------------------------------------------
KG game engine (http://katoun.github.com/kg_engine) is made available under the MIT License.
Copyright (c) 2006-2013 <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated docu... |
/*
* Copyright (c) 2014 - 2015, <NAME>, Ph.D.
* West Virginia University Applied Space Exploration Lab
* West Virginia Robotic Technology Center
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions a... |
/**
* touchtrain: main.cpp
* Copyright (c) Torr Vision Group, University of Oxford, 2015. All rights reserved.
*/
#include <boost/assign/list_of.hpp>
using boost::assign::list_of;
#include <evaluation/core/ParamSetUtil.h>
#include <evaluation/core/PerformanceTable.h>
#include <evaluation/splitgenerators/CrossValid... |
#include <mpi.h>
#include <sys/time.h>
#include <iostream>
#include <functional>
#include <algorithm>
#include <vector>
#include <sstream>
#include "CombBLAS/CombBLAS.h"
#include "CombBLAS/CommGrid3D.h"
#include "CombBLAS/SpParMat3D.h"
#include "CombBLAS/ParFriends.h"
using namespace std;
using namespace combblas;
#d... |
// (c) 2016 ZaKlaus; All Rights Reserved
#include <stdio.h>
#include <stdlib.h>
#include <Windows.h>
#include "minify_api.h"
// TOP
struct Win32Plugin
{
HMODULE PluginDLL;
char * PluginExtension;
minify_file * MinifyFile;
get_extension * GetExtension;
Win32Plugin * Next;
};
struct Win... |
#include <ipa_room_segmentation/distance_segmentation.h>
#include <ipa_room_segmentation/wavefront_region_growing.h>
#include <ipa_room_segmentation/contains.h>
DistanceSegmentation::DistanceSegmentation()
{
}
void DistanceSegmentation::segmentMap(const cv::Mat& map_to_be_labeled, cv::Mat& segmented_map,
double ma... |
#include <stdio.h> // - Just for some ASCII messages
#include <stdlib.h>
#include <string.h>
#include "gl/glut.h" // - An interface and windows
#include "visuals.h" // Header file for our OpenGL functions
#include <math.h>
#include <iostream>
#include <fstream>
using namespace std;
model md;
static float tx =... |
// Gmsh - Copyright (C) 1997-2019 <NAME>, <NAME>
//
// See the LICENSE.txt file for license information. Please report all
// issues on https://gitlab.onelab.info/gmsh/gmsh/issues.
#include "GmshDefines.h"
#include "MLine.h"
#include "nodalBasis.h"
#include "BasisFactory.h"
#include "GaussLegendre1D.h"
#include "Conte... |
#include <Genny.hpp>
void car(genny::Namespace* g) {
g->type("bool")->size(1);
g->type("char")->size(1);
g->type("short")->size(2);
g->type("int")->size(4);
g->type("long")->size(4);
g->type("long long")->size(8);
g->type("float")->size(4);
g->type("double")->size(8);
g->enum_("Car... |
#include "ui_ErrorEditDialog.h"
#include "ErrorEditDialog.h"
#include <QTableWidgetItem>
#include <QStringList>
#include <QDebug>
#include <QBrush>
#include <QColor>
#include <QAbstractButton>
#include <QMessageBox>
QBrush error_brush(QColor(255, 0, 0, 100));
QBrush modif_brush(QColor(0, 255, 0, 100));
/*
* Load da... |
// glfwTest2VS.cpp : main project file.
#include "stdafx.h"
#include <iostream>
//using namespace std;
// GLEW
#define GLEW_STATIC
#include <GL/glew.h>
#include "Shader.h"
#include "SerialClass.h"
#include "Leap.h"
// GLFW
#include <GLFW/glfw3.h>
#include <SOIL/SOIL.h>
using namespace Leap;
// Function prototypes
v... |
#include "../Test.h"
#include "../common/cephes.h"
static double psi2(int m, int n, const unsigned char* epsilon);
void
Serial(Nist::Test& test)
{
auto n = test.GetN();
auto m = test.GetParameters().serialBlockLength;
auto epsilon = test.GetEpsilon();
auto& R_ = test.GetWriteableResults();
double p_value1, p_v... |
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2022, Intel Corporation */
#include "examples_helpers.hpp"
#include "libpmemstream.h"
#include <algorithm>
#include <iostream>
#include <memory>
#include <mutex>
#include <stdexcept>
#include <string>
#include <vector>
#include <libpmem2.h>
/**
* This example s... |
/*
* Copyright (c) 2008 Princeton 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 copyright
* notice, this list of conditio... |
/**
* Copyright (c) 2017-2018 Netflix, Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless require... |
//////////////////////////////////////////////////////////////////////////////
// Copyright (C) 1993 - 2001 California Institute of Technology //
// //
// Read the COPYING and README files, or contact '<EMAIL>', //
// before co... |
/**
* smlsharp_gc.cpp
* @copyright (C) 2021 SML# Development Team.
* @author <NAME>
* for LLVM 3.9.1, 4.0.1, 5.0.2, 6.0.1, 7.0.1, 8.0.1, 9.0.1, 10.0.0, 11.0.0,
* 11.1.0, 12.0.0
*/
#include <llvm/Config/llvm-config.h>
#include <llvm/CodeGen/AsmPrinter.h>
#include <llvm/CodeGen/GCStrategy.h>
#include <llv... |
/******************************************************************************
RGB-D camera rig by GLCamera
Author: <NAME> (seungtak.noh [at] gmail.com)
******************************************************************************/
#include "cvgl/GLCamera.h"
#include "cvgl/DrawGL3D.h"
#include <opencv2/core/core.hpp>... |
#include <cstdlib>
#include <iostream>
// Defines blueprint of a RList objecct.
class RList {
public:
// Data
int first;
RList* rest; // Recursive definition, an RList can only be defined in terms of another RList
// i.e. "A person is a creature whose mother was a person."
// Behavior
RList(... |
#include <vector>
#include <iostream>
using namespace std;
/* Find the transition point in a sorted vector. Complexity: O(logn)*/
int transitionPoint(vector<int>& vec){
unsigned first = 0;
unsigned last = vec.size()-1;
if(vec[first]==1){
cout << "All ones. No transition point." << endl;
}
... |
/// \file dividend_discount.cpp
///
/// \brief
///
/// \authors <NAME>
/// \date 2020-01-30
/// \copyright Copyright 2017-2020 The Institute for New Economic Thinking,
/// Oxford Martin School, University of Oxford
///
/// Licensed under the Apache License, Version 2.0 (the "License"... |
//---------------------------------*-C++-*-----------------------------------//
/*!
* \file Matprop/xs/test/tstMix_Table.cc
* \author <NAME>
* \date Thu Feb 04 18:38:16 2016
* \brief Tests for class Mix_Table.
* \note Copyright (c) 2016 Oak Ridge National Laboratory, UT-Battelle, LLC.
*/
//----------------... |
/**
* @file pureWpTrace.cpp
* @brief tracking target way point
* @author <NAME>
* @date 2021.7.29
* @details 受け取ったtarget way point に追従するようにpure pursuit
*/
#include <ros/ros.h>
#include <std_msgs/Int32.h>
#include <nav_msgs/Path.h>
#include <geometry_msgs/Twist.h>
#include <geometry_msgs/Pose.h>
#include <rumba_autocar/... |
/*=========================================================================
Program: Insight Segmentation & Registration Toolkit
Module: itkFastMarchingTest.cxx
Language: C++
Date: $Date$
Version: $Revision$
Copyright (c) Insight Software Consortium. All rights reserved.
See ITKCopyright.tx... |
/* Copyright (C) 2012 <NAME>
*
* Optimist Racing is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Optimist Racing is distrib... |
/*
CF 9/15/18
Demonstrates the variables and arithmetic for PID
Makes the setpoint a square wave.
Connect to motorized gearbox through L298 power amp
Feedback on A4 pin (labelled "ECHO" on ultrasonics ranger connector) is an analog potentiomter
Output is via pins 6 & 7 through the L298 power amp
Connect t... |
// Copyright (c) 2017-2018 LG Electronics, 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... |
#include "ftable.h"
//Update all entries in tables for action a with value v
void FTABLE::valueUpdate(int action, double value){
int weight = 1;
for(int i=0; i < Table.size(); i++){
if(Table[i].action == action){
Table[i].value.Add(value);
}
}
}
void FTABLE::inactivityUpdate(){
for(int i=0; i < Table.size(... |
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#include <fstream>
#include <math.h>
#include <chrono>
#include <ctime>
#include <time.h>
#include <vector>
#include <random>
#include <Math/ProbFuncMathCore.h>
#include "TCanvas.h"
#include "TStyle.h"
#include "TGraph.h"
#include "TEllipse.h"
#include "TAxis.... |
/*
Bacula(R) - The Network Backup Solution
Copyright (C) 2000-2018 <NAME>
The original author of Bacula is <NAME>, with contributions
from many others, a complete list can be found in the file AUTHORS.
You may use this file and others of this release according to the
license defined in the LICENSE ... |
// Tags: Lagrange Interpolation
// Difficulty: 7.5
// Priority: 1
// Date: 16-08-2021
#include <bits/stdc++.h>
#define all(A) begin(A), end(A)
#define rall(A) rbegin(A), rend(A)
#define sz(A) int(A.size())
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define mt make_tuple
using namespace st... |
/* Copyright (c) 2006, NIF File Format Library and Tools
All rights reserved. Please see niflib.h for license. */
//-----------------------------------NOTICE----------------------------------//
// Some of this file is automatically filled in by a Python script. Only //
// add custom code in the designated areas o... |
/*========================================================================*
* *
* Distributed by Whiteley Research Inc., Sunnyvale, California, USA *
* http://wrcad.com *
* Copyright (... |
// Copyright 2021 Adobe
// All Rights Reserved.
//
// NOTICE: Adobe permits you to use, modify, and distribute this file in accordance with the terms
// of the Adobe license agreement accompanying it.
// identity
#include "orc/parse_file.hpp"
// application config
#include "orc/features.hpp"
// stdc++
#include <bit>... |
/*
* This file belongs to the Galois project, a C++ library for exploiting parallelism.
* The code is being released under the terms of the 3-Clause BSD License (a
* copy is located in LICENSE.txt at the top-level directory).
*
* Copyright (C) 2018, The University of Texas at Austin. All rights reserved.
* UNIVER... |
// Copyright 2017 Google Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in ... |
#include <bits/stdc++.h>
using namespace std;
template <typename T, typename U>
struct Seglazy {
static const int H = 19; //20
static const int SZ = 1<<H;
int sz_v;
const T ID; // identity
const U UN; // not info
vector<T> v; // tree
vector<U> d; // lazy
Seglazy() : sz_v(SZ<<1),... |
/*
* Copyright (c) 2017 - 2018, Intel Corporation
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, ... |
#include <iostream>
#include <vector>
#include <memory>
#include <cstdlib>
#include <array>
#include <ctime>
class ParkingSpot;
class Level;
class Vehicle;
class Car;
class Motorcycle;
class Bus;
class Parkinglot;
enum SpotSize {
Tiny, Compact, Large
};
class Vehicle {
public:
int spots_needed;
... |
// *****************************************************************************
/*!
\file src/Base/Exception.cpp
\copyright 2012-2015 <NAME>,
2016-2018 Los Alamos National Security, LLC.,
2019 Triad National Security, LLC.
All rights reserved. See the LICENSE file for de... |
#include <bits/stdc++.h>
using namespace std;
const int SIZE = 1e6 + 10;
typedef long long ll;
// Factorials
ll n[SIZE] = {1};
void getFac() {
for (int i = 1; i < SIZE; i++) n[i] = n[i - 1] * i;
}
// Combinations
ll c[SIZE][SIZE] = {0};
void getCom() {
c[0][0] = 1;
for (int i = 1; i < SIZE; i++) {
c[i][... |
#include <math.h>
#include <stdio.h>
#include "LineSeg3D.h"
//Point p1,p2; //Line segment is from p1 to p2
//double xb,yb,xe,ye; //Line segment is from (xb,yb) to (xe,ye)
//double m; //slope
//double a,b; //ax+by=1;
LineSeg::LineSeg()
{
Point tmp;
a_point = 1;
p1 = tmp; p2 = tmp;
xb = 0; yb ... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <map>
#include <deque>
#include <curl/curl.h>
#include <curl/easy.h>
// definition of payload chunk
struct ChunkData {
char *memory;
size_t size;
};
// payload chunks with sequence number
std::map<unsigned long, ChunkData> payload;
// definit... |
/*!
@file TrickHLA/TimedSyncPntList.cpp
@ingroup TrickHLA
@brief This class provides and abstract base class as the base implementation
for storing and managing HLA synchronization points for Trick.
@copyright Copyright 2019 United States Government as represented by the
Administrator of the National Aeronautics and S... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.