text stringlengths 3.08k 22k |
|---|
#include<iostream>
#include<fstream>
#include<string>
#include<algorithm>
#include<regex>
#include "Vector.h"
#include "map.h"
#include "Heap.h"
using namespace std;
//Class HashNode
class HashNode
{
public:
string key; //Key-Value pairs to store entry
int value;
public:
HashNode(){} //Con... |
//+---------------------------------------------------------------------------
//
// Copyright (C) 1992 - 1997 Microsoft Corporation.
//
// File: cphash.cxx
//
// Contents: Table that maps strings to codepages
//
// Classes: CCodePageTable
//
// Note: Derived from SitaramR's hash table
... |
// Copyright 2020 The TensorStore Authors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or ... |
/*
* Copyright (C) 2015-2021 Swift Navigation Inc.
* Contact: https://support.swiftnav.com
*
* This source is subject to the license found in the file 'LICENSE' which must
* be be distributed together with this source. All other rights reserved.
*
* THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY ... |
/****************************************************************************
*
* Copyright (c) 2012-2017 PX4 Development Team. 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. Red... |
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public Lic... |
/*
* Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#include <array>
#include <algorithm>
#include <sstream>
#include <iomanip>
#include <iostream>
#include "output_format.h"
#include "pio_disassembler.h"
struct python_output : public output_format {
struct factory... |
/*
* Copyright (c) 2013, <NAME>
* 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 conditions and the follo... |
//---------------------------------------------------------------------------
// Greenplum Database
// Copyright (C) 2012 EMC Corp.
//
// @filename:
// CPartPruneStepsBuilder.cpp
//
// @doc:
// Utility class to construct PartPruneInfos with appropriate
// PartPruningSteps from partitioning filter expressions
//----... |
/**
* \file dnn/src/common/deformable_conv.cpp
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2020 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
*... |
// Copyright 2021 <NAME> <EMAIL>
// (Alternate: <EMAIL> and <EMAIL>)
#include <iostream>
#include <map>
#include <string>
#include <vector>
// allowed includes
// tuple, utility, vector, map, set, unordered_map,
// unordered_set, algorithm
using std::cin;
using std::cout;
using std::map;
using std::string;
using std... |
/*
* Copyright (c) 2016-2018, NVIDIA CORPORATION. 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 ... |
/*
* 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 <iostream>
#include <sstream>
#include <string>
#include <cmath>
#include <assert.h>
#include <inttyp... |
#include "SkyBox.h"
#include "Application.h"
#include "ModuleTextures.h"
#include "ModuleRenderer3D.h"
#define NUM_SKYBOX 2
SkyBox::SkyBox()
{
}
SkyBox::~SkyBox()
{
}
void SkyBox::InitSkybox()
{
// SKYBOX 1 -----------------------------------------
texture[0][SkyBoxSide::SKY_LEFT] = App->textures->LoadSkyboxTex... |
#include <iostream>
#include <cmath>
#include <algorithm>
#include "shader.h"
#include "primitives.h"
using namespace LibRayMarching;
Shader::Shader()
{
m_MaxIteration = 300;
m_MaxDistance = 100;
m_MinDistance = 0.0001f;
m_Epsilon = 0.005f;
m_Bouncing = 10;
m_Lightning.background = Vector(0, 0, 0);
m_Lightnin... |
#include "pqbase.h"
bool PQBase::cmp(const pair<int, double> &t1, const pair<int, double> &t2) {
return t1.second > t2.second;
}
void PQBase::create_dist_tables() {
dist_tables = vector<vector<float> > (PQ_M, vector<float>(PQ_K*PQ_K,0));
for (int i = 0; i < PQ_M; i ++) {
for (int j = 0; j < PQ_K; j... |
#include "Daletos.h"
// fmt Library
#include "fmt/color.h"
#include "fmt/core.h"
#include "fmt/ostream.h"
// Str Manip Header
#include "str_manip.h"
// Other Stuff
#include <windows.h>
#include <iostream>
#include <utility>
#include <filesystem>
#include <algorithm>
#include <fstream>
Daletos::Daletos()
{
m_argv.r... |
#include "ofApp.h"
//--------------------------------------------------------------
void ofApp::setup(){
ofBackground(0,0,0);
ofSetFrameRate(30);
camWidth = 640; // try to grab at this size.
camHeight = 480;
camFrameRate=40;
cameraCenter.set(camWidth/2, camHeight/2);
// a... |
// This file is part of RAVL, Recognition And Vision Library
// Copyright (C) 2001, University of Surrey
// This code may be redistributed under the terms of the GNU Lesser
// General Public License (LGPL). See the lgpl.licence file for details or
// see http://www.gnu.org/copyleft/lesser.html
// file-header-ends-here... |
// import.cpp
/**
* Copyright (C) 2008 10gen Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License, version 3,
* as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will b... |
#include <iostream>
#include <iomanip>
#include <string>
#include <bitset>
#include <cmath>
#include <cassert>
using namespace std;
union floating {
unsigned n;
float f;
} fl;
// float to string
string internal_float (float f) {
fl.f = f;
bitset<32> b(fl.n);
return b.to_string();
}
// convert a ... |
/*
Author: <NAME>, Coventry University
*/
#include <http/http_handler.h>
#include <string.h>
#include <freertos/FreeRTOS.h>
#include <freertos/task.h>
#include <esp_ota_ops.h>
#include <io/sound.h>
#include <memory/alloc.h>
#include <net/http.h>
#include <util/log.h>
#include <util/queues.h>
static const char *TA... |
#include "scenefbotexture.h"
#include <iostream>
using std::cerr;
using std::endl;
#include "glm\gtc\matrix_transform.hpp"
#include "glm\gtx\transform.hpp"
#include "glm\gtc\constants.hpp"
SceneFBOTexture::SceneFBOTexture () : angle ( 0.f ), fprev ( 0.f ), rotSpeed ( glm::two_pi <float> () / 8.f )
{}
SceneFBOTextu... |
/*
* CometOS --- a component-based, extensible, tiny operating system
* for wireless networks
*
* Copyright (c) 2015, Institute of Telematics, Hamburg University of Technology
* All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted pr... |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <memory.h>
#include <ctype.h>
#include "AudioDef.h"
#include "AudioRecog.h"
#include "AudioUtil.h"
#include "AudioConfig.h"
#include "type/matrix.h"
#include "misc/misc.h"
#include "io/file/io.h"
#include "math/mmath.h"
#include "benchmark.h"
sta... |
//----------------------------------------------------------------------------
//
// TSDuck - The MPEG Transport Stream Toolkit
// Copyright (c) 2005-2019, <NAME>
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following c... |
#include "MS_Visibility.h"
namespace
{
const char kDesc[] = "Calculate Visibility, Shadow Motion Vector and Reliability.";
const std::string kProgramFile = "RenderPasses/MotionedShadow/MS_Visibility.slang";
const std::string shaderModel = "6_2";
// Name = pass channel name; TexName = name in shader
... |
/*
===========================================================================
Doom 3 BFG Edition GPL Source Code
Copyright (C) 1993-2012 id Software LLC, a ZeniMax Media company.
This file is part of the Doom 3 BFG Edition GPL Source Code ("Doom 3 BFG Edition Source Code").
Doom 3 BFG Edition Source Code is free... |
// Copyright 2019 Amazon.com, Inc. or its affiliates. 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
//
// Unles... |
// Copyright 2017 Google Inc.
// Copyright 2020 The Open GEE Contributors
//
// 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
//
// Unles... |
#include "misc.h"
#include <iostream>
#include "include_base_utils.h"
#include "common/i18n.h"
#include "common/command_line.h"
#include "common/util.h"
#include "common/scoped_message_writer.h"
#include "string_coding.h"
using namespace std;
using namespace epee;
using namespace cryptonote;
namespace genms
{
cons... |
#pragma once
#include "routing/road_graph.hpp"
#include "routing/routing_settings.hpp"
#include "routing/segment.hpp"
#include "routing/turns.hpp"
#include "traffic/speed_groups.hpp"
#include "indexer/feature_altitude.hpp"
#include "geometry/polyline2d.hpp"
#include "base/followed_polyline.hpp"
#include "std/vect... |
/*
* Copyright 2001 <NAME> - please read to the LICENSE file
*
* Copyright 2002-2006, <NAME> <<EMAIL>>
* All rights reserved.
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <Application.h>
#include <Bitmap.h>
#include <Font.h>
#include <Message.h>
#include <MessageRunner.h>
#include <S... |
/* Operating Systems Project 1
* <NAME>ki, <NAME>, <NAME>
*/
//My includes
#include "PList.hpp"
//Include the algorithms
#include "RR.hpp"
#include "SJF.hpp"
#include "FCFS.hpp"
//System includes
#include <list>
#include <string>
#include <fstream>
#include <sstream>
#include <iostream>
#include <functional>
//D... |
#include <chromaprint.h>
#include <audio/RawAudio.hpp>
#include <../libs/large-alphabet-suffix-array/src/karkkainen_sanders.hpp>
#include <linear_longest_substring.hpp>
#include <iostream>
#include <math.h>
#include <algorithm>
#include <map>
#include <vector>
#include <cstring>
using std::cout; using std::endl; usin... |
#include <gtest/gtest.h>
#include <gmock/gmock.h>
#include "crypto.h"
#include "crypto_ledger_reader_writer.h"
#include <fstream>
#include <string>
#include <iostream>
TEST(CryptoLib, ledger_reader_writer_set_keys)
{
Ledger_Reader_Writer reader;
const char* KEY1_PRIV_HEX = "2f1e7b7a130d7ba9da0068b3bb0ba1d79e... |
#pragma once
/*
Copyright (c) 2018 <NAME>, <EMAIL>
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, merg... |
//! \example homography-dlt-opencv.cpp
//! [Include]
#include <iostream>
#include <opencv2/core/core.hpp>
#include <opencv2/calib3d/calib3d.hpp>
//! [Include]
//! [Estimation function]
cv::Mat homography_dlt(const std::vector< cv::Point2d > &x1, const std::vector< cv::Point2d > &x2)
//! [Estimation function]
{
//! [... |
#include "DrawPrimitivesTest.h"
using namespace std;
static int sceneIdx = -1;
CCLayer* nextSpriteTestAction();
CCLayer* backSpriteTestAction();
CCLayer* restartSpriteTestAction();
typedef CCLayer* (*NEWDRAWPRIMITIVESFUNC)();
#define DRAWPRIMITIVES_CREATE_FUNC(className) \
static CCLayer* create##className() \
{ r... |
/*
* Copyright information and license terms for this software can be
* found in the file LICENSE that is included with the distribution
*/
#include <epicsUnitTest.h>
#include <testMain.h>
#include <pv/nt.h>
using namespace epics::nt;
using namespace epics::pvData;
using std::tr1::dynamic_pointer_cast;
static Fi... |
/* ----------------------------------------------------------------- */
/* The Toolkit for Building Voice Interaction Systems */
/* "MMDAgent" developed by MMDAgent Project Team */
/* http://www.mmdagent.jp/ */
/* -------------------------... |
#include <algorithm>
#include "project.h"
#include "templates/templates.h"
#include "file/file.h"
#include "env/env.h"
#include "request/request.h"
#include "jinja/jinja.h"
#include "jinja/stringhelper.h"
#include "yaml-cpp/yaml.h"
#include "project_env/project_env.h"
using namespace std;
using namespace json11;
#def... |
#include <map>
#include <ode/ode.h>
#include "physics.h"
#define MAX_CONTACTS 10
typedef struct
{
dWorldID world;
dSpaceID space;
dJointGroupID contact_group;
} World;
typedef struct
{
dBodyID body;
dMass mass;
dGeomID geom;
void* data;
} Object3D;
typedef struct
{
dTriIndex indexes[6];
dVector3 ver... |
/*
* @Author: gpinchon
* @Date: 2019-03-26 13:04:37
* @Last Modified by: gpinchon
* @Last Modified time: 2021-01-11 08:46:01
*/
#include "Common.hpp"
#include "Events.hpp" // for Events
#include "Node.hpp" // for Node
#include "Renderable.hpp" // for Renderable
#include "glm/glm.hpp" // for s_vec3, s_vec2, glm::ve... |
#include "sightedturtlesim/SingleImageServer.hpp"
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/core/version.hpp>
#if CV_MAJOR_VERSION >= 3
// NOTE: in OpenCV 3, imread() was moved from highgui from imgcodecs
#include <opencv2/imgcodecs.hpp>
#endif
#include <iostream>
#... |
#include <iostream>
#include <fstream>
#include <cmath>
#include <cstring>
#include "Huffman.h"
#include "MyVec.h"
using namespace std;
//função que converte um número um vetor de 0s e 1s (vetor de numeros binarios) em seu número decimal
int baseDecimal(int *bit){
int num = 0; //variável que receberá o número... |
/**
* Software submitted by
* Systems & Technology Research / Vision Systems Inc., 2013
*
* Approved for public release; distribution is unlimited. [DISTAR Case #21428]
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
... |
/****************************************************************************
**
** This file is part of the LibreCAD project, a 2D CAD program
**
** Copyright (C) 2010 <NAME> (<EMAIL>)
** Copyright (C) 2001-2003 RibbonSoft. All rights reserved.
**
**
** This file may be distributed and/or modified under the terms of t... |
/*
* mcy-gui -- Mutation Cover with Yosys GUI
*
* Copyright (C) 2019 <NAME> <<EMAIL>>
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copi... |
/*************************************************************************
This file is part of the ParaNut project.
Copyright (C) 2010-2020 <NAME> <<EMAIL>>
<NAME> <<EMAIL>>
Hochschule Augsburg, University of Applied Sciences
Redistribution and use in source and binary forms, w... |
/**
* @brief Example-Code for a generic Server (e.g. Sensor, Display)
*
* @file OWPJON/LINUX/Local/ThroughSerial/RemoteWorker/DeviceGeneric/DeviceGeneric.cpp
*
* @author drtrigon
* @date 2018-07-06
* @version 1.0
* @li first version derived from PJON 11.0 examples
* examples/LINUX/Local/EthernetTCP/Rem... |
#include <iostream>
#include <vector>
#include <algorithm>
#include <cmath>
#include <limits>
#include <chrono>
#include <fstream>
#include <string>
#define STB_IMAGE_WRITE_IMPLEMENTATION
#define STBI_MSC_SECURE_CRT
#include "stb_image_write.h"
#include <glm/glm.hpp>
#define GLM_ENABLE_EXPERIMENTAL
#incl... |
// -*- C++ -*-
//
// Package: src
// Class : RPCCompDetId
//
// Implementation:
// [Notes on implementation]
//
// Author: <NAME>
// Created: Wed Nov 2 12:09:10 CET 2011
#include <iostream>
#include <sstream>
#include <iomanip>
#include "DataFormats/MuonDetId/interface/RPCCompDetId.h"
#include "D... |
#include <assert.h>
#include <stdio.h>
#include <stdint.h>
#include <inttypes.h>
#include "bignum.h"
void test_assign() {
BigNum<10, 2> a;
for (unsigned int i=0; i<100; ++i) {
a = i;
unsigned int v = a.value();
assert(i == v);
}
}
void test_add() {
unsigned int i, j, k, l;
BigNum<10, 2> a, b, c, d;
for (... |
// Copyright © 2017-2022 Trust Wallet.
//
// This file is part of Trust. The full Trust copyright notice, including
// terms governing use, modification, and redistribution, is contained in the
// file LICENSE at the root of the source code distribution tree.
#include "Transaction.h"
#include "Cbor.h"
#include "Hash.... |
#include "corder.h"
// destructor
gofr::~gofr() {
free1d < double > (rhob);
free1d < double > (rhosb);
free1d < double > (gr);
free2d < double > (gabr);
free2d < double > (gsabr);
free1d < double > (rhor);
free2d < double > (rhoabr);
free2d < double > (rhosabr);
}
void gofr::init ( void ) {
// temporary var... |
#include "../DynamicElement/ArcBall.h"
#include "../DynamicElement/Camera.h"
#include "MassSpringSyn.h"
#include "lodepng.h"
bool pause = false; //true; //
bool g_flagShowInput = true;
int g_width = 720;
int g_height = 480;
int g_bmpCount = 0;
Flt g_mouseOldPx;
Flt g_mouseOldPy;
CArcBall* ptrArcBall = NULL;
CCamera* p... |
//
// Fifteen Puzzle (IDA* with disjoint pattern database heuristics)
//
#include <iostream>
#include <vector>
#include <cstdio>
#include <queue>
#include <algorithm>
#include <unordered_map>
#include <functional>
#include <unordered_set>
using namespace std;
#define fst first
#define snd second
const int INF = 999... |
#include <zmq.hpp>
#include <iostream>
#include <sstream>
#include <string>
#include <thread>
#include <math.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <fcntl.h>
#include <fstream>
#include <unistd.h>
#include <signal.h>
#include <errno.h>
#include <sys/ioctl.h>
#include <chrono>
#include <l... |
/*****************************************************************************
*
* Functions for calculating the spectrum
*
* Copyright (C) 2018 by <NAME>
* e-mail:<EMAIL>
*
*****************************************************************************/
#include "BinarySearch.h"
#include "rpa_util.h"
#include "calc_sin... |
//
// QuadTree.cpp
//
// See QuadTree.h for more detailed comments
//
// Created by <NAME> on 11/22/13.
//
//
#include "QuadTree.h"
using namespace std;
/*
* Constructor
*/
QuadTree::QuadTree(double x, double y, double width, double height,
int numCells, int max, Application * app) {
root... |
#include <iostream>
#include <fstream>
#include <sstream>
#include <stdlib.h>
#include <map>
#include <vector>
#include <stack>
#include "Command.h"
#include "Interpreter.h"
using namespace std;
Interpreter::Interpreter(int argc, char* argv[]){
co = new vector <Command*> ;
whereDaLine = new map <int,int>; /... |
// HOG-Man - Hierarchical Optimization for Pose Graphs on Manifolds
// Copyright (C) 2010 <NAME>, <NAME>, <NAME>
//
// HOG-Man 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 3 of the ... |
#include <algorithm>
#include <chrono>
#include <iomanip>
#include <iostream>
#include <random>
#include <vector>
#include <cmath> // For: fabs
#include <cblas.h>
#ifndef MAX_SPEED
#error "Must set max speed with -DMAX_SPEED=... or similar"
#endif
extern "C" {
/* Your function must have the following signature: */
... |
//----------------------------------------------------------------------------
//
// TSDuck - The MPEG Transport Stream Toolkit
// Copyright (c) 2005-2020, <NAME>
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following c... |
#include <iostream>
#include <map>
#include <vector>
#include <filesystem>
#include <fstream>
#include "Errors/QinpError.h"
#include "Warning.h"
#include "Tokenizer.h"
#include "ArgsParser.h"
#include "ProgramGenerator.h"
#include "PlatformName.h"
#include "ExecCmd.h"
#include "ExportSymbolInfo.h"
#include "NasmGene... |
//
//
//
#include <ctime>
#include "MissionMonitor.h"
#include "EnumHelper.h"
#include "ArduinoLog.h"
#include "AudioPlayer.h"
MissionMonitor::MissionMonitor( uint32_t secondsBeforeEmergencyStop, GPS_FIX_TYPE lowestGpsFixTpye, AudioPlayer* audioPlayer )
{
_secondsBeforeEmergencyStop = secondsBeforeEmergencyStop;... |
/*****************************************************************************************
* SGCT *
* Simple Graphics Cluster Toolkit *
* ... |
// Copyright (c) <NAME>
// Licensed under the MIT License.
#include <cstring>
#include <cmath>
#include <vector>
#include <fstream>
#include <iomanip>
#include <wiringPi.h>
#include <wiringPiSPI.h>
#include "json.hpp"
#include "sx1278.h"
#include "sx1278_rt.h"
using json = nlohmann::json;
static std::map<int, SX1... |
/* FCE Ultra - NES/Famicom Emulator
*
* Copyright notice for this file:
* Copyright (C) 2002 Xodnizel
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, o... |
#include "PCH-rpgcraft.h"
#include "x-types.h"
#include "x-stl.h"
#include "x-assertion.h"
#include "x-string.h"
#include "x-thread.h"
#include "x-host-ifc.h"
#include "x-gpu-ifc.h"
#include "x-gpu-colors.h"
#include "x-png-decode.h"
#include "v-float.h"
#include "appConfig.h"
#include "ajek-script.h"
#include "Enti... |
// Copyright (c) 2020, BlockProject
//
// 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 ... |
//
// ArrayBucketSorterDriver.cc
//
#include <iostream>
using std::cin;
using std::cout;
using std::cerr;
using std::endl;
using std::flush;
#include <string>
using std::string;
#include "spindle/ArrayBucketSorter.h"
const char prompt[] = "==> ";
#ifdef HAVE_NAMESPACES
using namespace SPINDLE_NAMESPACE;
#endif
v... |
#include "webhook_handler_config.h"
#include <sstream>
#include <ctime>
#include <locale>
#include <date.h>
#include <iostream>
#include <sstream>
#include <wsjcpp_core.h>
// WebhookShellCommand
WebhookShellCommand::WebhookShellCommand(std::string sCommand) {
m_sCommand = sCommand;
this->parseCommand();
}
boo... |
/*
* Copyright (c) 2018, <NAME> 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, this list of ... |
/*
* Copyright © 2021 <NAME>. All rights reserved.
* Contacts: <<EMAIL>>
* Licensed under the Apache License, Version 2.0
*/
#include <algorithm>
#include <array>
#include <cctype>
#include <chrono>
#include <cmath>
#include <iomanip>
#include <sstream>
#include <stdexcept>
#include <utility>
#include <cpr/api.h>... |
// 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... |
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out
//
// XFAIL: level_zero
//==---------- reinterpret.cpp --- SYCL buffer reinterpret basic test ------==//
//
// Part of the LLVM Project, under th... |
// Copyright(C) 1999-2021 National Technology & Engineering Solutions
// of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with
// NTESS, the U.S. Government retains certain rights in this software.
//
// See packages/seacas/LICENSE for details
#include "CatalystTestFixture.h"
#include "TestDataDirecto... |
#include "stdafx_nc_runtime_test.h"
#include "nc_runtime/string_slice.h"
#include "nc_runtime/nc_string.h"
TEST(StringSlice, compare)
{
EXPECT_TRUE("blood"_s == "blood"_s);
EXPECT_TRUE("blood"_s != "bloom"_s);
EXPECT_TRUE("blood"_s == "blood");
EXPECT_TRUE("blood"_s != "bloom");
EXPECT_TRUE("bloo... |
#include "declares.h"
using namespace std;
#if defined(__GNUC__)
typedef unsigned long mUL64;
inline unsigned long long read_tsc(void)
{
#if defined(__i386__)
unsigned long long cycles;
__asm__ volatile (".byte 0x0f, 0x31" : "=A"(cycles));
return cycles;
#else
#if defined(__x86_64__)
unsigned int ... |
#include <wiicpp.h>
#include <MLAlg.h>
void recognize(int argc, char** argv, MLAlg& mlalg)
{
CWii wii; // Defaults to 4 remotes
std::vector<CWiimote>::iterator i;
int numFound;
Training* training = 0;
// Load the model
mlalg.load(argv[3]);
// Load category names, if any
if(argc > 4) {
ifstream in... |
#include "md5.h"
void md5::_md5_update(md5_t *ctx, const void *data, size_t size)
{
size_t used, free;
used = (size_t) (ctx->bytes & 0x3f);
ctx->bytes += size;
if (used) {
free = 64 - used;
if (size < free) {
memcpy(&ctx->buffer[used], data, size);
... |
#define __CL_ENABLE_EXCEPTIONS
#include <complex>
#include <iostream>
#include <memory>
#include <regex>
#include <tuple>
#include "Bounds2D.h"
#include "Screen_Stream.h"
#include "Image_Stream.h"
#include "Pixel_Stream_Base.h"
#include "Pixel_Calculator.h"
RGB retrieve_color(const std::regex&);
std::tuple<float,
... |
/* Copyright 2017 <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 writ... |
/*
==============================================================================
Copyright 2007-2013, 2017 <NAME>
Copyright 2013-2016 <NAME>
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions... |
/*
-- MAGMA (version 1.6.1) --
Univ. of Tennessee, Knoxville
Univ. of California, Berkeley
Univ. of Colorado, Denver
@date January 2015
@precisions normal z -> s d c
*/
#include "common_magma.h"
#define A(m,n) (a+(n)*(*lda)+(m))
// task execution code
static void SCHED_zgemm(Q... |
void printhelp(string errormessage){
cout << errormessage << endl;
cout << endl;
cout << "Usage: assignment [-h][-p <file>][-n <file>][-l <file>][-m <int>][-t <int>][-s <float>]" << endl;
cout << " [-h] : This helpscreen" << endl;
cout << " [-p <file>] : Pdb-file (default: \"1D3Z.pdb\")" << endl;... |
#include "HolonicSystems-Free.hpp"
#include "dsp/digital.hpp"
struct HolonicSystemsLazySusanModule : Module {
enum ParamIds {
PARAM_SCALE,
PARAM_SCALE_CV_ATT,
PARAM_ATT,
PARAM_SCALE_1,
PARAM_SCALE_2,
PARAM_SCALE_3,
PARAM_SCALE_4,
PARAM_SCALE_5,
PARAM_SCALE_6,
PARAM_SCALE_7,
PARAM_SCALE_8,
PA... |
#include "splat_compiler.h"
#include "splat_internal.h"
#include "core/file_stat.h"
#include "core/log.h"
#include "core/dir.h"
#include "core/cpu_timer.h"
#include "imgui/imgui.h"
#include <stdlib.h> // for malloc/free
#include <stdio.h> // for FILE
#include "core/shader_loader.h" // maybe better to move this out..
... |
#include <thread>
#include <chrono>
#include <iostream>
#include <exception>
#include <ncurses.h>
#include "View.h"
Input charToInput(int in) {
switch (in) {
case KEY_UP: return UP;
case KEY_DOWN: return DOWN;
case KEY_LEFT: return LEFT;
case KEY_RIGHT: return RIGHT;
case ... |
#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <stddef.h>
#include "nrutil.h"
int IMIN(int ia, int ib)
{
if (ia<=ib)
return ia;
else
return ib;
}
void nrerror(char error_text[])
{//Numerical Recipes standard error handler
fprintf(stderr,"Numerical Recipes run-time error...\n");
fprintf(std... |
/*
* Examine and test a keychain's identity
*/
#include <Security/Security.h>
#include <stdlib.h>
#include <stdio.h>
#include <CoreServices/../Frameworks/CarbonCore.framework/Headers/MacErrors.h>
#include <security_cdsa_utils/cuPrintCert.h>
#include <utilLib/common.h>
#include <utilLib/cspwrap.h>
#include <clAppUtils... |
/*<NAME>*/
#include <iostream>
#include <numeric>
#include <fstream>
#include <climits>
#include <cstring>
#include <cstdio>
#include <cmath>
#include <queue>
#include <list>
#include <map>
#include <set>
#include <stack>
#include <deque>
#include <vector>
#include <string>
#include <cstdlib>
#include <cassert>
#includ... |
//
// Created by jijingtian on 4/11/21.
//
#include "svm.h"
#include <utility>
SVM::SVM(double c, Kernel* kernel){
this->_kernal = kernel;
this->_c = c;
}
SVM::~SVM(){
}
void SVM::_init(const MatrixXd& x, const VectorXd& y) {
this->_n = x.rows();
this->_d = x.cols();
this->_train_x = x;
thi... |
/*
Copyright (c) 2014 Intrepid Control Systems, Inc.
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 condit... |
// FILE NAME: $HeadURL: svn+ssh://svn.cm.aol.com/advertising/adlearn/gen1/trunk/lib/cpp/DataProxy/test/RestRequestBuilderTest.cpp $
//
// REVISION: $Revision: 305155 $
//
// COPYRIGHT: (c) 2006 Advertising.com All Rights Reserved.
//
// LAST UPDATED: $Date: 2014-10-02 20:00:32 -0400 (Thu, 02 Oct 2... |
/********************************************************************************
* Copyright (c) 2021 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,... |
#include <GL/gl.h>
#include <GL/glut.h>
#ifdef _WIN32
#include <windows.h>
#endif
#include <string.h>
#include <math.h>
#include "Globals.h"
#include "Constants.h"
#include "DeviceKernels.h"
#include "Patterns.h"
#include "Utils.h"
#include "Platform.h"
#include "Device.h"
#include "Contex... |
// $Id$
#include <getopt.h>
#include <pcap.h>
#include <stdarg.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#if 0
#include <llvm/Assembly/PrintModulePass.h>
#include <llvm/Bitcode/ReaderWriter.h>
#include <llvm/ExecutionEngine/ExecutionEngine.h>
#include <llvm/ExecutionEngine/JIT.... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.