text stringlengths 3.08k 22k |
|---|
#include "shader.h"
#include "camera.h"
#define STB_IMAGE_IMPLEMENTATION
#include "stb_image.h"
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <glm/gtc/type_ptr.hpp>
#include <glad/glad.h>
#include <GLFW/glfw3.h>
#include <iostream>
void framebuffer_size_callback(GLFWwindow* window, int wi... |
/*
-------------------------------------------------------------------------------
This file is part of Eris Engine
-------------------------------------------------------------------------------
Copyright (c) 2017 <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and... |
// translate.cc
// Routines to translate virtual addresses to physical addresses.
// Software sets up a table of legal translations. We look up
// in the table on every memory reference to find the true physical
// memory location.
//
// Two types of translation are supported here.
//
// Linear page table -- the virtu... |
// Copyright 2019 DeepMind Technologies Ltd. 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... |
/* Boost test/add.cpp
* test with symbolic operations if the addition algorithm is correct
*
* Copyright 2002-2003 <NAME>
*
* Distributed under the Boost Software License, Version 1.0.
* (See accompanying file LICENSE_1_0.txt or
* copy at http://www.boost.org/LICENSE_1_0.txt)
*/
#include <boost/numeric/interva... |
/*
==============================================================================
AboutComponent.cpp
Created: 16 Mar 2019 4:17:47pm
Author: Andrew
==============================================================================
*/
#include "AboutComponent.h"
AboutComponent::AboutComponent()
{
add... |
#include "world_3d.hpp"
#include "fmt/core.h"
#include <glm/vec3.hpp>
#include <glm/vec4.hpp>
#include <glm/mat4x4.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <vector>
#include <array>
#include <set>
static void push_trig(std::vector<w3d_point> &buf, const std::array<glm::vec3, 3> &pts) {
buf.push_ba... |
#include "Scancontext.h"
// namespace SC2
// {
void coreImportTest (void)
{
cout << "scancontext lib is successfully imported." << endl;
} // coreImportTest
float rad2deg(float radians)
{
return radians * 180.0 / M_PI;
}
float deg2rad(float degrees)
{
return degrees * M_PI / 180.0;
}
float xy2theta( ... |
/*
=========================================================================================
3D Image Toolkit
Copyright 2013:
<NAME>, <NAME>, <NAME>, <NAME>.
All rights reserved.
Read details of the license in the file license.txt provided with the library.
=============================================================... |
//%2005////////////////////////////////////////////////////////////////////////
//
// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
// IBM Corp.; EMC Cor... |
/*
--------------------------------------------
| Piedra - Papel - Tijeras - Lagarto - Spock |
--------------------------------------------
*/
#include <cstdlib>
#include <iostream>
#include <ctime>
#include <fstream>
#include <string>
using namespace std;
typedef enum { Piedra, Papel, Tijeras, Lagarto, Spoc... |
/*
* File: registroIndexado.cpp
* Author: ilson.buss
*
* Created on 3 de Maio de 2011, 08:52
*/
/*
Registro!
*
* Escolhe quais indices serao indexados
*
* Cria uma arvore com o dado desta tabela MAIS uma lista encadeada contendo
* os indices que contem aquele dado
*
* TABELA: Uma lista de uma estrutu... |
/*******************************************************************************
Copyright (C) 2017 Marvell International Ltd.
This software file (the "File") is owned and distributed by Marvell
International Ltd. and/or its affiliates ("Marvell") under the following
alternative licensing terms. Once you have made an... |
/*
* Originally included at Autoware.ai version 1.10.0 and
* has been modified to fit the requirements of Project ASLAN.
*
* Copyright (C) 2020 Project ASLAN - All rights reserved
*
* Original copyright notice:
* Copyright 2015-2019 Autoware Foundation. All rights reserved.
*
* Licensed under the Apache Licens... |
#include "CalibTracker/SiStripHitEfficiency/interface/TrajectoryAtInvalidHit.h"
#include "TrackingTools/TrackFitters/interface/TrajectoryStateCombiner.h"
#include "TrackingTools/TrajectoryState/interface/TrajectoryStateOnSurface.h"
#include "TrackingTools/TrajectoryState/interface/TrajectoryStateTransform.h"
#include "... |
//
// CameraZoomAndRotateHandler.cpp
// G3M
//
// Created by <NAME> on 26/06/13.
//
//
#include "CameraZoomAndRotateHandler.hpp"
#include "GL.hpp"
#include "TouchEvent.hpp"
#include "G3MEventContext.hpp"
#include "Planet.hpp"
#include "Camera.hpp"
#include "CameraContext.hpp"
#include "RenderState.hpp"
#include "I... |
/*!
* Copyright 2015 by Contributors
* \file data.cc
*/
#include <xgboost/data.h>
#include <xgboost/logging.h>
#include <dmlc/registry.h>
#include <cstring>
#include "./sparse_batch_page.h"
#include "./simple_dmatrix.h"
#include "./simple_csr_source.h"
#include "../common/io.h"
#if DMLC_ENABLE_STD_THREAD
#include "... |
#include <cmath>
#include <iostream>
#include <thread>
#include <sstream>
#include <SDL.h>
#include <boost/core/ignore_unused.hpp>
extern "C" {
#include "emulator.h"
}
struct cycle_budget_t {
double cycles_per_ns_;
unsigned int current_;
double partial_;
explicit cycle_budget_t(double cycle_per... |
/*
* Copyright 2004-2015 Cray Inc.
* Other additional copyright holders may be indicated within.
*
* The entirety of this work is 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
*
*... |
//==-- SimpleTable.cpp -- tabular data simple transforms and I/O -----------==//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
/*
* Copyright (C) 2012-2013, The CyanogenMod Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appli... |
/*
* \brief Block shredder
* \author <NAME>
* \date 2017-08-26
*/
/*
* Copyright (C) 2017 Genode Labs GmbH
*
* This file is part of the Genode OS framework, which is distributed
* under the terms of the GNU Affero General Public License version 3.
*/
/**
* TODO:
* - Progress report
*/
/* Genode inc... |
#include "player.h"
#include <ctime>
using namespace std;
// The implementation file of the Player class.
// Default constructor which initializes the territories, hand and ordersList for the Player.
Player::Player(){
//Territories, hand and ordersList initialization.
territories = new std::vector<Territory... |
/* This software and supporting documentation are distributed by
* Institut Federatif de Recherche 49
* CEA/NeuroSpin, Batiment 145,
* 91191 Gif-sur-Yvette cedex
* France
*
* This software is governed by the CeCILL-B license under
* French law and abiding by the rules of distribution of free soft... |
#include "MyScene.h"
#include "Prop.h"
#include "Limb.h"
#include "ModelManager.h"
#include "Spider.h"
#include "BeachBall.h"
#include "Mechanism.h"
#include <iostream>
#include <vector>
MyScene::MyScene(int argc, char** argv, const char *title, const int& windowWidth, const int& windowHeight)
: Scene(argc, argv, ti... |
#include "PosControl.h"
//Sets initial errors to zero
void initializePID3(PID_3DOF &PID){
Eigen::Vector3d zeros = Eigen::Vector3d::Zero();
PID.e_prop = zeros;
PID.e_deriv = zeros;
PID.e_integ = zeros;
}
//Sets integral error to zero
void resetIntegralErrorPID3(PID_3DOF &PID){
PID.e_integ = Eigen::Vector3d::Zero... |
//%Header {
/*****************************************************************************
*
* File: src/MushMesh/MushMeshOps.cpp
*
* Author: <NAME> 2002-2005
*
* This file contains original work by <NAME>. The author and his
* employer (Mushware Limited) irrevocably waive all of their copyright rights
* veste... |
#include <iostream>
#include <fstream>
#include <sstream>
#include <vector>
#include <stdlib.h>
#include "RZMagFieldFromMap.h"
#include "base/Global.h"
#include "base/Vector3D.h"
#include "base/SOA3D.h"
using namespace std;
// typedef vecgeom::Vector3D<double> Vector3D;
using Vector3D_d = vecgeom::Vector3D<double>;
... |
/*
Stripper - Dynamic Map Entity Modification
Copyright QMM Team 2020
http://github.com/thecybermind/stripper_qmm/
Licensing:
QMM 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 2 of t... |
// Copyright 2019-2020 jquack (Falcons)
// SPDX-License-Identifier: Apache-2.0
/*
* AvoidObstacles.cpp
*
* Created on: August, 2019
* Author: <NAME>
*
* Algorithm originally implemented by Erik.
* Paper: http://www.techunited.nl/media/files/realtime_motion_path_generation_using_subtargets_in_a_changing_env... |
#include <Plot/plot.h>
#include <Gui/opengl.h>
#include <Geo/mesh.h>
#ifdef RAI_QT
# include <QtGui/QApplication>
#endif
#include <GL/gl.h>
#include <GL/glut.h>
#include <Core/thread.h>
using namespace std;
/************ first test ************/
void draw1(void*,OpenGL& gl){
glStandardLight(nullptr, gl);
glColo... |
/*
** Copyright (c) 2013 The Khronos Group Inc.
**
** Permission is hereby granted, free of charge, to any person obtaining a
** copy of this software and/or associated documentation files (the
** "Materials"), to deal in the Materials without restriction, including
** without limitation the rights to use, copy, modify... |
#pragma once
#include <cassert>
#include <cstdio>
#include <fstream>
#include <iostream>
#include <sstream>
#include <tuple>
#include <utility>
#include <vector>
#include <cadical.hpp>
using atom = int;
enum class sat_status { null, sat, unsat };
struct cnf_file {
cnf_file(std::string path) : path_{std::move(p... |
// --------------------------------------------------------------------------
// OpenMS -- Open-Source Mass Spectrometry
// --------------------------------------------------------------------------
// Copyright The OpenMS Team -- Eberhard Karls University Tuebingen,
// ETH Zurich, and Freie Universit... |
// Copyright 2020 The IREE Authors
//
// Licensed under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#include "iree/compiler/Conversion/LinalgToLLVM/KernelDispatch.h"
#include "iree/compiler/Conver... |
#include "larq_compute_engine/core/bconv2d_functor.h"
#include "larq_compute_engine/core/bgemm_functor.h"
#include "larq_compute_engine/core/padding_functor.h"
#include "tensorflow/core/framework/bounds_check.h"
#include "tensorflow/core/framework/common_shape_fns.h"
#include "tensorflow/core/framework/numeric_op.h"
#i... |
/**
Mirf
Additional bug fixes and improvements
11/03/2011:
Switched spi library.
07/13/2010:
Added example to read a register
11/12/2009:
Fix dataReady() to work correctly
Renamed keywords to keywords.txt ( for IDE ) and updated keyword list
Fixed client example code to timeo... |
// Copyright (c) 2019-2020 <NAME>
// https://www.veriblock.org
// Distributed under the MIT software license, see the accompanying
// file LICENSE or http://www.opensource.org/licenses/mit-license.php.
#include <boost/noncopyable.hpp>
#include <boost/python.hpp>
#include <boost/python/to_python_converter.hpp>
#include... |
/*******************************************************************************
MIT License
Copyright (c) 2021 <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, includin... |
// Distributed under the MIT License.
// See LICENSE.txt for details.
/// \file
/// Defines class DormandPrince5.
#pragma once
#include <cstddef>
#include <cstdint>
#include <ostream>
#include <pup.h>
#include "Options/Options.hpp"
#include "Parallel/CharmPupable.hpp"
#include "Time/EvolutionOrdering.hpp"
#include ... |
/*******************************<GINKGO LICENSE>******************************
Copyright (c) 2017-2019, the Ginkgo authors
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source co... |
// Author: <NAME> (<EMAIL>)
#include "height_ridge_extractor_2d.h"
#include "math.h"
#include "util.h"
#include <algorithm>
#include <set>
#include <vtkMath.h>
namespace {
const double kEigenValueThreshold = -25000.0;
double linear_interpolation(double s1, double s2, double x1, double x2) {
return (x2 - x1) * ... |
/*
* LEGAL NOTICE
* This computer software was prepared by Battelle Memorial Institute,
* hereinafter the Contractor, under Contract No. DE-AC05-76RL0 1830
* with the Department of Energy (DOE). NEITHER THE GOVERNMENT NOR THE
* CONTRACTOR MAKES ANY WARRANTY, EXPRESS OR IMPLIED, OR ASSUMES ANY
* LIABILITY FOR THE USE OF... |
//----------------------------------------------------------------------------
//
// TSDuck - The MPEG Transport Stream Toolkit
// Copyright (c) 2005-2022, <NAME>
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following c... |
// Copyright <NAME> 2016-2017.
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#include <sstream>
#include <iostream>
#include <chrono>
#include <cstdlib>
#include <algorithm>
#include "Applic... |
#include <arpa/inet.h>
#include <event2/event.h>
#include <sys/uio.h>
#include <unistd.h>
#include <string>
#include "ConnectionOptions.h"
#include "ConnectionStats.h"
#include "Operation.h"
#include "UDPConnection.h"
#include "binary_protocol.h"
#include "log.h"
#define RETRANSMIT_INTERVAL 0.01 /* seconds */
size_... |
/*
* Copyright (C) 2005 - 2013 MaNGOS <http://www.getmangos.com/>
*
* Copyright (C) 2008 - 2013 Trinity <http://www.trinitycore.org/>
*
* Copyright (C) 2006 - 2013 ScriptDev2 <http://www.scriptdev2.com/>
*
* Copyright (C) 2010 - 2013 ProjectSkyfire <http://www.projectskyfire.org/>
*
* Copyright (C) 2011 - 2013... |
/*
Test program demonstrating a problem in Windows 15048's ReadConsoleOutput API.
To compile:
cl /nologo /EHsc winbug-15048.cc shell32.lib
Example of regressed input:
Case 1:
> chcp 932
> winbug-15048 -face-gothic 3044
Correct output:
1**34 (nb: U+3044 replaced with '**' to avoid MS... |
/** @file
MODULE : VectorStructList
TAG : VSL
FILE NAME : VectorStructList.cpp
DESCRIPTION : A generic base class to contain vectors in a contiguous
list of structs defined by the extended implementations.
The structure of the vectors is determined by its type.
COPYRIGHT :... |
/* Copyright (c) 2014, 2021, Oracle and/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, version 2.0,
as published by the Free Software Foundation.
This program is also distributed with certain software (including
b... |
#include "software/ai/hl/stp/tactic/goalie_tactic.h"
#include "shared/constants.h"
#include "software/ai/evaluation/calc_best_shot.h"
#include "software/ai/hl/stp/action/chip_action.h"
#include "software/ai/hl/stp/action/move_action.h"
#include "software/ai/hl/stp/action/stop_action.h"
#include "software/ai/hl/stp/tac... |
/*
* ============================================================================
*
* Authors: <NAME> <<EMAIL>>
* <NAME> <<EMAIL>>
* <NAME> (<EMAIL>)
*
* ============================================================================
*/
#include <iostream>
#include <st... |
// Copyright 2021 The IREE Authors
//
// Licensed under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#include "iree/compiler/Conversion/LinalgToLLVMGPU/KernelConfig.h"
#include "iree/compiler/Conve... |
//----------------------------------------------------------------------------
//
// TSDuck - The MPEG Transport Stream Toolkit
// Copyright (c) 2005-2021, <NAME>
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following c... |
/*
Copyright 2012 efalex <email>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, s... |
/***********************************
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 applicabl... |
//========- unittests/Support/ThreadPools.cpp - ThreadPools.h tests --========//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===---------------------------... |
/*********************************************************************
* Software License Agreement (BSD License)
*
* Copyright (c) 2008, <NAME>, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* ... |
#include "r_utils/r_sha1.h"
#include "r_utils/r_string_utils.h"
#include "r_utils/r_exception.h"
#include <string.h>
#include <array>
using namespace r_utils;
using namespace std;
#define rol(value, bits) (((value) << (bits)) | ((value) >> (32 - (bits))))
#if BYTE_ORDER == LITTLE_ENDIAN
#define blk0(i) (block->l[i]... |
/*
* Licensed under the GNU GPL 3.0
* Copyleft 2015 oneTesla, LLC
*/
#include "improv/include/MidiFile.h"
using namespace std;
#include <ctype.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <iostream>
#define MAX_EVENTS 2000
typedef unsigned char uchar;
typedef struct... |
#include <iostream>
#include <fstream>
#include <string>
#include <vector>
#include <algorithm>
#include "../lib/etana/proof.h"
#include "../include/mklab.h"
#include "../include/synthts_et.h"
extern "C" {
#include "../include/HTS_engine.h"
}
CDisambiguator Disambiguator;
CLinguistic Linguistic;
typedef unsigned ch... |
#include "SearchController.h"
#include <angles/angles.h>
using namespace std;
SearchController::SearchController() {
rng = new random_numbers::RandomNumberGenerator();
currentLocation.x = 0;
currentLocation.y = 0;
currentLocation.theta = 0;
centerLocation.x = 0;
centerLocation.y = 0;
centerLocation.the... |
//
// Copyright RIME Developers
// Distributed under the BSD License
//
// 2011-07-05 <NAME> <<EMAIL>>
//
#include <algorithm>
#include <utility>
#include <gtest/gtest.h>
#include <rime/dict/prism.h>
#include <rime/algo/syllabifier.h>
class RimeSyllabifierTest : public ::testing::Test {
public:
virtual void SetUp()... |
/*
* util.cpp
*/
#include "util.hpp"
#include <regex>
#include <cassert>
#include <numeric>
#include <random>
#include <cstring>
#include <exception>
#include <sys/mman.h>
#include <immintrin.h>
#if defined(__GNUC__) && !defined(__clang__)
#define GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PAT... |
#include <windows.h>
#include <string>
#include <vector>
//--------------------------------------------------------------------------------------------------
using namespace std;
//--------------------------------------------------------------------------------------------------
const int HSTEP = 46, MWID = 40, MHEI ... |
/*****************************************************************
machine\swmathbx.c
This file is Copyright 1997, <NAME>.
Release 2.0 (5 August 1997)
See drivers\starwars.c for notes
******************************************************************/
#include "driver.h"
#include "swmathbx.h"
#defin... |
#include <assert.h>
#include <hls_stream.h>
#include <ap_axi_sdata.h>
#define bitwidth 32
#define wordwidth 16
#define quant_scale 32768// 2^(wordwidth-1)
//typedef ap_axiu<32,1,1,1> AXI_VAL;
struct AXI_VAL{
ap_int<bitwidth> data;
bool last;
};
/////////////////////////////
// Paramteres //
//#define A_COL_ITER 32
... |
//
// Copyright (c) 2017 The Khronos Group 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 la... |
/* -*- 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... |
// =================================================
// File : driver.c
// Author : <NAME>
// Description : Basic SDL 2.0 Implimentation
// LICENSE : MIT
// =================================================
#ifdef _WIN32
#define SDL_MAIN_HANDLED
#include <Windows.h>
#include <GLU.h>
#include <GL/gl.h>
#elif linu... |
/*
** SelfPortrait API
** See Copyright Notice in reflection.h
*/
#include "utilities_test.h"
#include "typelist.h"
#include "str_conversion.h"
#include "reflection.h"
#include <type_traits>
#include <iostream>
#include <string>
using namespace std;
void UtilitiesTestSuite::testTypelist()
{
// Compile-time tests
... |
/*
* Copyright 2017 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "example/HelloWorld.h"
#include "include/core/SkCanvas.h"
#include "include/core/SkFont.h"
#include "include/core/SkPath.h"
#include "include/core/SkGraphics.h"
#include ... |
/*
* Copyright (c) 2021, NVIDIA CORPORATION. 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 requi... |
#include <iostream>
#include <bits/stdc++.h>
#include <list>
#include <string>
#include <map>
#include <math.h>
#define MAX_COST 1000;
#define pruebaX1 int X[] = {5,2,6,3,8,7} // M = 7
#define pruebaY1 int Y[] = {1,3,2,1} // N = 5
#define pruebaX2 int X[] = {10,2,7,5} // M = 5
#define pruebaY2 int Y[] = {... |
/*
music.cpp - Plays a song
Part of Marlin
Copyright (c) 2009-2011 <NAME>
Grbl 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... |
/*-------------------------------------------------------------------------
* src\FedSrv\SQLHELP.CPP
*
* Helper functions for sql stuff
*
* Owner:
*
* Copyright 1986-1998 Microsoft Corporation, All Rights Reserved
*-----------------------------------------------------------------------*/
//
// Okay, I know... |
#include <anms.h>
#include <numeric>
#define USE_KNN
//#undef USE_KNN
class Benchmark{
public:
~Benchmark()
{
double time_passed = clock() - t_;
time_passed = time_passed * 1000 / (double)CLOCKS_PER_SEC;
std::cout << "Finished " << label_ << " in " << time_passed << " milliseconds" << std:... |
// Copyright 2012 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable... |
/*
* main.cpp
*
* Created on: 11/08/2015
* Author: pperezm
*/
#include <iostream>
#include <cstring>
#include "unit.h"
#include "dlist.h"
class ListTest : public UnitTest {
public:
void runTest() {
DList<int> b1;
UnitTest::total_test = 47;
/* TEST 1 */
std::cout << "Test 1";
ASSERT_TRUE(0 == b1.... |
#include <CGAL/Polygon_mesh_processing/measure.h>
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
#include <CGAL/Polyhedron_3.h>
#include <CGAL/Surface_mesh.h>
#include <CGAL/Polygon_mesh_processing/bbox.h>
#include <CGAL/Bbox_3.h>
#inclu... |
#include <Catalog.h>
#include <DataIO.h>
#include <OS.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/socket.h>
#include <sys/select.h>
#include <sys/types.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <netdb.h>
#include <errno.h>
#include "FTPClient.h"
#u... |
/*
GUICore - GUIWidget
The win32 GUI framework library.
author: WolfgangKurz
Base class for widgets
A standard unit of child controls
*/
#include "GUIWidget.hpp"
#include "GUIValues.h"
GUIWidget::GUIWidget(int x, int y, int width, int height, UINT style, UINT exstyle) : GUIObject(x, y, width, height, GUIOF_NO... |
/*
* Copyright 2014-present Facebook, 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 a... |
// SDL2 particle system example
//
// Controls:
// * Press space to toggle gravity
// * Move mouse to move emitter
#include <chrono>
#include <cstdlib>
#include "SDL.h"
#define TWO_ENTITY_MAX (32<<10)
#include "../entity.h"
// Config
constexpr int WindowX = 800;
constexpr int WindowY = 600;
conste... |
// -*- mode: c++; tab-width: 4; indent-tabs-mode: t; c-file-style: "stroustrup"; -*-
// vi:set ts=4 sts=4 sw=4 noet :
// Copyright 2008, The TPIE development team
//
// This file is part of TPIE.
//
// TPIE is free software: you can redistribute it and/or modify it under
// the terms of the GNU Lesser General Public ... |
// Copyright (c) 2015, Baidu.com, Inc. All Rights Reserved
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fstream>
#include <iostream>
#include <limits>
#include <sstream>
#include <boost/... |
#include "Directories.h"
#include "Local.h"
#include "HImage.h"
#include "VObject.h"
#include "Interface_Utils.h"
#include "Render_Dirty.h"
#include "Interface_Control.h"
#include "SysUtil.h"
#include "Faces.h"
#include "Weapons.h"
#include "Overhead.h"
#include "Soldier_Macros.h"
#include "Line.h"
#include "Vehicles.h... |
// Copyright (c) 2020-2021 <NAME>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, ... |
/*
* Copyright (C) 2019 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by app... |
// FVisual.cpp: implementation of the FVisual class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#pragma hdrstop
#pragma warning(disable:4995)
#include <d3dx9.h>
#pragma warning(default:4995)
#include "../fmesh.h"
#include "fvisual.h"
/////////////////... |
/*
* Copyright 2017 MapD Technologies, 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 o... |
/*
* Copyright (c) 2018 <NAME>, Carnegie Mellon 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:
*
* 1. Redistributions of source code must retain the above copyright notice, th... |
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
#include "cmConfigure.h"
#include "CTest/cmCTestLaunch.h"
#include "CTest/cmCTestScriptHandler.h"
#include "cmCTest.h"
#include "cmDocumentation.h"
#include "cmSystemTools... |
/*
* YaoWire.cpp
*
*/
#include "YaoGarbleWire.h"
#include "YaoGate.h"
#include "YaoGarbler.h"
#include "YaoGarbleInput.h"
#include "GC/ArgTuples.h"
#include "Tools/pprint.h"
#include "GC/Processor.hpp"
#include "GC/Secret.hpp"
#include "GC/Thread.hpp"
#include "GC/ShareSecret.hpp"
#include "YaoCommon.hpp"
void Ya... |
/*
After Apricot Rules LLC went through a reorganization, a new large team was formed containing M managers and N non-managers. Since many people within the team do not know each other, a number of introduction sessions are to be scheduled. We know exactly which pairs of members already know each other.
The introducti... |
/**
\file
\author <NAME>
*/
#include "FluidDynamicsSimulatorItem.h"
#include <cnoid/Archive>
#include <cnoid/Body>
#include <cnoid/EigenArchive>
#include <cnoid/EigenUtil>
#include <cnoid/ItemManager>
#include <cnoid/RootItem>
#include <cnoid/SimulatorItem>
#include <cnoid/WorldItem>
#include <vector>
#include <... |
//
// SqratImport: Supports importing of squirrel modules
//
//
// Copyright (c) 2009 <NAME>
//
// This software is provided 'as-is', without any express or implied
// warranty. In no event will the authors be held liable for any damages
// arising from the use of this software.
//
// Permission is granted ... |
// BSD 3-Clause License
//
// DeepGlint is pleased to support the open source community by making EasyQuant available.
// Copyright (C) 2020 DeepGlint. All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are ... |
#include <portability.h>
/*************************************************************************
* PLEASE SEE THE FILE "license.txt" (INCLUDED WITH THIS SOFTWARE PACKAGE)
* FOR LICENSE AND COPYRIGHT INFORMATION.
*************************************************************************/
/***********************... |
#include "unitutil.hpp"
lengthTypes getLengthType(std::string input) {
if (input.compare("mm") == 0 ||
input.compare("millimeter") == 0 ||
input.compare("millimetre") == 0)
return millimeter;
else if (input.compare("cm") == 0 ||
input.compare("centimeter") == 0 ||
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.