text stringlengths 3.08k 12.5k |
|---|
#include <Arduino.h>
#include <ESP8266WebServer.h>
#include <FS.h>
#include <ESP8266WiFi.h>
#include <servo.h>
#define USE_SERIAL
//Set Wifi ssid and password
char ssid[] = "RCBOAT";
char pass[] = "<PASSWORD>";
static bool debug = true;
const int SERVO_PIN = 12;
const int MOTOR_PIN = 14;
const int HOME_SERVO_ANGL... |
/*********************************************************************
* Software License Agreement (BSD License)
*
* Copyright (c) 2010, Rice University
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions... |
#include "gtest/gtest.h"
#include <fstream>
#include <iostream>
#include <optional>
#include <vector>
#include "../src/route_model.h"
#include "../src/route_planner.h"
static std::optional<std::vector<std::byte>> ReadFile(const std::string &path)
{
std::ifstream is{path, std::ios::binary | std::ios::ate};
... |
#include "pch.h"
#include "OpenGLWindow.h"
#include <Kore/Graphics4/Graphics.h>
#include <Kore/Graphics4/PipelineState.h>
#include <Kore/System.h>
#include <Kore/Window.h>
#include "ogl.h"
#ifdef KORE_WINDOWS
#include <GL/wglew.h>
#endif
using namespace Kore;
OpenGL::Window OpenGL::windows[10] = {0};
namespace {
... |
#include "SQLiteLoggerCommon.h"
#include "BitStream.h"
using namespace RakNet;
static const char *sqlDataTypeNames[SQLLPDT_COUNT] =
{
"INTEGER",
"INTEGER",
"NUMERIC",
"TEXT",
"BLOB",
"BLOB",
};
extern "C" const char *GetSqlDataTypeName(SQLLoggerPrimaryDataType idx) {return sqlDataTypeNames[(int... |
//===- TestMatchers.cpp - Pass to test matchers ---------------------------===//
//
// Part of the MLIR 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
//
//===---------------------------... |
// -*-C++-*-
/*
(c) Copyright 2004-2007, Hewlett-Packard Development Company, LP
See the file named COPYING for license details
*/
/** @file
Common lsf analysis bits.
*/
#include "analysis/lsfdsanalysis-common.hpp"
using namespace std;
const string group_dedicated_bear("dedicated-bear-");
const string grou... |
#include <pc/manager.hpp>
#include <pc/log.hpp>
#include <unistd.h>
#include <signal.h>
#include <iostream>
// pyth daemon service
using namespace pc;
std::string get_rpc_host()
{
return "localhost";
}
std::string get_tx_host()
{
return "localhost";
}
std::string get_key_store()
{
std::string dir = getenv("H... |
#include <iostream>
#include <climits>
/*
* Qui ho definito la lunghezza e i numeri dentro all'array.
*/
#define L 9
using namespace std;
void selectionSort(int *a, int start, int end);
void bubbleSort(int *a, int start, int end);
void mergeSort(int *a, int start, int end);
void printArray(int *a, size_t start,... |
// RUN: %check_clang_tidy %s bugprone-argument-comment %t -- -- -I %S/Inputs/bugprone-argument-comment
// FIXME: clang-tidy should provide a -verify mode to make writing these checks
// easier and more accurate.
void ffff(int xxxx, int yyyy);
void f(int x, int y);
void g() {
// CHECK-NOTES: [[@LINE+4]]:5: warning:... |
#include <torch/extension.h>
#include <vector>
namespace multihead_attn {
namespace self_bias {
namespace cublas_gemmex {
std::vector<torch::Tensor> fwd_cuda(
bool use_time_mask,
bool is_training,
... |
#include "sc2api/sc2_api.h"
#include "sc2utils/sc2_manage_process.h"
#include <iostream>
#include <string>
#include <fstream>
const char* kReplayFolder = "FILE PATH";
const int step = 10;
const int save = 1000;
int count = 0;
int processed = 0;
// Copied from example bot.
struct IsArmy {
IsArmy(const sc2::Obse... |
#include "DCEL.h"
#include "Point.h"
#include <algorithm>
#include <iterator>
Vertex::Vertex() : Point() {
this->incidentEdge = nullptr;
}
Vertex::Vertex(HEdge *_e) : Point() {
this->incidentEdge = _e;
}
Vertex::Vertex(Point *_p) : Point(_p) {
this->incidentEdge = nullptr;
}
Vertex::Vertex(Point *_p, HEdge *_e) ... |
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
#include "cmMacroCommand.h"
#include <cstdio>
#include <utility>
#include <cm/memory>
#include <cm/string_view>
#include "cm_static_string_view.hxx"
#include "cmAlgorit... |
#include <cstdlib>
#include <ctime>
#include "core/common/clint.h"
#include "elf_loader.h"
#include "debug_memory.h"
#include "iss.h"
#include "mem.h"
#include "memory.h"
#include "mmu.h"
#include "syscall.h"
#include "platform/common/options.h"
#include "gdb-mc/gdb_server.h"
#include "gdb-mc/gdb_runner.h"
#include ... |
/*
* @Author : mark
* @Date : 2020-06-26
* @copyleft Apache 2.0
*/
#include "httprequest.h"
using namespace std;
const unordered_set<string> HttpRequest::DEFAULT_HTML{
"/index", "/register", "/login",
"/welcome", "/video", "/picture", };
const unordered_map<string, int> Htt... |
#include <string>
#include <limits>
#include <cmath>
#include <random>
#include <algorithm>
#include <queue>
#include <iostream>
#include <QImage>
#include <QVector3D>
#include <QColor>
#include <QPainter>
#include <QtMath>
#include "voronoi.hpp"
#include "../mollusc.hpp"
#include "../mosaic.hpp"
#include "../helpers... |
/*
* Copyright 2009-2017 Alibaba Cloud 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... |
// -*- C++ -*-
//
// Package: CastorDbProducer
// Class: CastorDbProducer
//
/**\class CastorDbProducer CastorDbProducer.h CalibFormats/CastorDbProducer/interface/CastorDbProducer.h
Description: <one line class summary>
Implementation:
<Notes on implementation>
*/
//
// Original Author: <NAME>
// ... |
#include "SaraShaderManager.h"
SaraShaderManager::SaraShaderManager( std::string vertShaderFilename, std::string fragmShaderFilename ) :
vertexShaderFilename( vertShaderFilename),
fragmentShaderFilename( fragmShaderFilename ) {
compileShaders();
}
SaraShaderManager::SaraShaderManager( std::string vertShaderFi... |
#include "specialfunc.h"
#include <limits>
#include <gsl/gsl_sf_erf.h>
double trigamma(double x)
{
double p;
int i;
x=x+6;
p=1/(x*x);
p=(((((0.075757575757576*p-0.033333333333333)*p+0.0238095238095238)
*p-0.033333333333333)*p+0.166666666666667)*p+1)/x+0.5*p;
for (i=0; i<6 ;i++)
{
... |
//Include our Class Definition
//Include Dependencies
#include "../world/world.h"
#include "../render/view.h"
#include "event.h"
void eventHandler::input(SDL_Event *e, bool &quit){
//User input detected
if( SDL_PollEvent( e ) != 0 ) {
//Quit Event
if( e->type == SDL_QUIT ) { quit = true; }
//Key Down T... |
#include "MathCommon.h"
#include "Assist/Common.h"
// TODO Can this be avoided? As far as my research got, there is no way not
// to use stdlib math intrinsics. Further investigation needed.
#include <cmath>
/*static*/const Coordtype Math::B_PI = Coordtype(3.141592653589793238462643383279);
/*static*/const C... |
// Local-Hyperion includes
#include "LedDeviceAurora.h"
#include <netdb.h>
#include <assert.h>
// jsoncpp includes
#include <json/json.h>
// qt includes
#include <QEventLoop>
#include <QNetworkReply>
#define ROOT_ROUTE ""
#define EFFECTS_ROUTE "effects"
#define URL_FORMAT "http://%1:16021/api/v1/%2/%3"
#define EXT_MO... |
/******************************************************************************
* Project: libspatialindex - A C++ library for spatial indexing
* Author: <NAME>, <EMAIL>
******************************************************************************
* Copyright (c) 2002, <NAME>
*
* All rights reserved.
*
* P... |
/*=======================================================================
Copyright 2013 <NAME>. All Rights Reserved.
This software is distributed for noncommercial use only, without
any warranties, and provided that all copies contain the full copyright
notice licence.txt located at the base folder of the ... |
/* Copyright © 2022 <NAME>.
* Released under an MIT License.
*/
/****************************************************************************************************
* This files takes BibleOL_dictionary_Hebrew-Spanish_vX.X.csv file as input and generates
* a heb_es.csv file as output.
***************************... |
#include <DataTypes/DataTypeFactory.h>
#include <DataTypes/getLeastSupertype.h>
#include <DataTypes/getMostSubtype.h>
#include <sstream>
#pragma GCC diagnostic ignored "-Wmissing-declarations"
#include <gtest/gtest.h>
namespace DB
{
static bool operator==(const IDataType & left, const IDataType & right)
{
return... |
#include "API/apiNpc.h"
#include "npcChar.h"
#include <time.h>
#include "../SharedDefines/easylogging++.h"
#include "../SharedDefines/packetsIds.h"
#include "networkManager.h"
#include "players.h"
void apiNpc::clearNpcTaks(int npc)
{
npcChars::npcChar* c = npcChars::getNpc(npc);
c->footInputs.clear();
c->vehicleInp... |
// NC.cpp - Code for the network calculus toolkit infrastructure.
// See NC.hpp for details.
//
// Copyright (c) 2016 <NAME>.
// Licensed under the MIT License. See LICENSE file for details.
//
#include <cassert>
#include <string>
#include <vector>
#include <map>
#include "../json/json.h"
#include "NC.hpp"
using name... |
#include "image.hpp"
#include <cmath>
#include <iostream>
#include <limits.h>
/**
* Checks if with and height values are safe to use on this system.
*
* \param width
* \param height
*
* \throws out_of_range
*/
void sizeSanityCheck(long width, long height) {
if (width < 1 || height < 1) {
throw std::... |
/*
* Copyright (c) 2018, The OpenThread 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 code must retain the above copyright
* n... |
#define _DEFAULT_SOURCE
#define _XOPEN_SOURCE
#define _BSD_SOURCE
#include <climits>
#include <cstring>
#include <exception>
#include <stdexcept>
#include <system_error>
#include <errno.h>
#include <poll.h>
#include <time.h>
#include <unistd.h>
#include <sys/timerfd.h>
#include "exception.hpp"
#include "timestamp... |
#include "stdafx.h"
#include "noise.h"
#include <xmmintrin.h>
__forceinline int iFloor_SSE( float const x )
{
return _mm_cvtt_ss2si( _mm_set_ss( x ) );
}
//==============================================================================
// Perlin's noise from Texturing and Modeling...
#define B 256
#define DOT(a... |
#include <cstdio>
#include <cstring>
const int N = 1e6 + 1e5;
struct node {/*{{{*/
int scr, time;
node() {
scr = time = 0;
}
bool operator< ( const node &b ) const {
if( scr == b.scr )
return time > b.time;
return scr < b.scr;
}
bool operator== ( const node &b ) const {
return scr == b.scr && time =... |
/*
* 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, Version 2.0 (the
* "License"); you ... |
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "packager/media/formats/webm/webm_video_client.h"
#include "packager/base/logging.h"
#include "packager/base/stl_util.h"
#include "packager/medi... |
//
// Created by wang on 2020/5/19.
//
#include "config.h"
#include <seeker/loggerApi.h>
#include <UdpClient.h>
#include "Message.h"
UdpClient::UdpClient(const string& ip, int port) {
memset(&serverAddr, 0, sizeof(serverAddr));
serverAddr.sin_family = AF_INET;
serverAddr.sin_addr.s_addr = inet_addr(ip.c_st... |
// DRIVER.CC - test driver for the C++/object oriented translation and
// modification of MD5.
// Translation and modification (c) 1995 by <NAME>
// This translation/ modification is provided "as is," without express or
// implied warranty of any kind.
// The translator/ modifier does not claim (1) that ... |
#include <cassert>
#include "AGLM.h"
#include "material.h"
#include "ray.h"
#include "sphere.h"
#include "box.h"
#include "plane.h"
#include "triangle.h"
#include "hittable.h"
using namespace glm;
using namespace std;
float eps = 0.0001f; // epsilon for comparing floats
//shared_ptr<material> vanta = make_shared<vant... |
//
// GLBackendTexture.cpp
// libraries/gpu/src/gpu
//
// Created by <NAME> on 1/19/2015.
// Copyright 2014 High Fidelity, Inc.
//
// Distributed under the Apache License, Version 2.0.
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
#include "GLBackend.h"
#include "GLSha... |
#include <stdio.h>
#include <ros/ros.h>
#include <ros/time.h>
// #include <cmath>
#include <std_msgs/Float64MultiArray.h>
#include <ReflexxesAPI.h>
#include <RMLVelocityFlags.h>
#include <RMLVelocityInputParameters.h>
#include <RMLVelocityOutputParameters.h>
#define sign(x) (((x) < 0) ? -1 : 1)
#define n... |
/*
http://www.opengl-tutorial.org/beginners-tutorials/
https://github.com/opengl-tutorials/ogl
#include <stdio.h> error fix : http://stackoverflow.com/questions/38290169/cannot-find-corecrt-h-universalcrt-includepath-is-wrong
Add directories
*/
#include "GLFWExample.h"
#include <memory>
#include "CarDrivingGame.h"
... |
#include <bits/stdc++.h>
#define N 101005
using namespace std;
int n,m,a[N],b[N];
void print(){
printf("%d\n",n);
for (int i=1;i<=n;++i){
printf("%d",a[i]);
if (i<n) putchar(' ');
else puts("");
}
printf("%d\n",m);
for (int i=1;i<=m;++i){
printf("%d",b[i]);
if (i<m) putchar(' ');
else puts("");
}
}
... |
// This block enables to compile the code with and without the likwid header in place
#ifdef LIKWID_PERFMON
#include <likwid-marker.h>
#else
#define LIKWID_MARKER_INIT
#define LIKWID_MARKER_THREADINIT
#define LIKWID_MARKER_SWITCH
#define LIKWID_MARKER_REGISTER(regionTag)
#define LIKWID_MARKER_START(regionTag)
#define ... |
//@HEADER
// ************************************************************************
//
// HPCCG: Simple Conjugate Gradient Benchmark Code
// Copyright (2006) Sandia Corporation
//
// Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive
// license for use of this work by... |
#include <QApplication>
#include <QDebug>
#include <QFile>
#include <QSurfaceFormat>
#include <QTcpServer>
#include <QTcpSocket>
#include <QTranslator>
#include "config.h"
#include "dialog.h"
#include "mousetap/mousetap.h"
#include "stream.h"
static Dialog *g_mainDlg = Q_NULLPTR;
static QtMessageHandler g_oldMessage... |
/**
* @file divo.cxx
* @desc Divo module.
*/
#include <windows.h>
#include <assert.h>
#include <boost/log/trivial.hpp>
#include <ft2build.h>
#include FT_FREETYPE_H
#include <GL/glew.h>
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include "../game.hxx"
#include "common.hxx"
Divo::~D... |
#include <Arduino.h>
#include <Wire.h>
#include <SPI.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>
#include <STM32SD.h>
#include <SPI.h>
#include "Ucglib.h"
#include "rtc.h"
#include <STM32RTC.h>
#define BLINK_LED LED_BUILTIN
#define SCREEN_WIDTH 128 // OLED display width, in pixels
#define SCREEN_HEIGHT... |
// Copyright 2010 and beyond, Google Inc.
// All Rights Reserved.
//
// Author: <EMAIL> (<NAME>)
#include <string>
#include "log.h"
#include "nacl_tts_plugin.h"
#include "nacl_main.h"
#include "pico_tts_engine.h"
using tts_service::ERROR;
using tts_service::LoggingMessage;
using tts_service::PicoTtsEngine;
// All o... |
/*
Copyright(c) 2010-2017 Intel Corporation.
Copyright(c) 2016-2018 Viosoft 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 ... |
#include "console.h"
#include "../messaging/messaging.h"
#include "../client_signature.h"
#include "../halo_data/chat.h"
#include "../hooks/frame.h"
#include "../halo_data/table.h"
char *console_text = NULL;
static void block_error() noexcept {
auto *push_req = get_signature("console_block_error_sig").a... |
/*=============================================================================
Copyright (c) 2014-2019 <NAME>. All rights reserved.
Distributed under the MIT License [ https://opensource.org/licenses/MIT ]
=============================================================================*/
#include <q/support/litera... |
#include <iostream>
#include <fstream>
#include <tuple>
#include <vector>
#include <cmath> //sqrt, ceil
#include <unordered_map> //for baby-step giant-step
#include <gmpxx.h>
#include <ctime>
using namespace std;
#define ll signed long long
#define big mpz_class
big Exponentiation_Re... |
/*
Copyright (c) 2015 Maximus5
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 conditions and the following dis... |
/*
* -----------------------------------------------------------------------------
* Created by <NAME> on 02/20/2020
*
* Chapter 19_04
* Modify class Link from §17.9.3 to be a template with the type of value
* as the template argument. Then redo exercise 13 from Chapter 17 with
* Link<God> .
* ----------------... |
#include "execute.h"
execute::execute(std::vector<byte> _binary) {
pc = 0;
memset(®, 0, sizeof(reg_u) * 4);
memset(&memory, 0, MEM_SIZE - 1);
working = true;
cout << "Executing..." << endl;
uint size = (uint)_binary.size();
for (uint i = 0; i < size; i++) {
memory[i] = _bi... |
// Classname: TFitParticleMCCart
// Author: <NAME>, <NAME> (TU Dresden)
//________________________________________________________________
//
// TFitParticleMCCart::
// --------------------
//
// Particle with cartesian 4vector parametrization and constrained mass
// [three free parameters (px, py, pz) with in... |
#define CGAL_IDENTIFICATION_XY 2
#define CGAL_ARR_GEODESIC_ARC_ON_SPHERE_DETAILS 1
#include <string>
#include <vector>
#include <fstream>
#include <CGAL/Exact_rational.h>
#include <CGAL/Cartesian.h>
#include <CGAL/Arrangement_on_surface_2.h>
#include <CGAL/Arr_geodesic_arc_on_sphere_traits_2.h>
#include <CGAL/Arr_s... |
#include <algorithm>
#include <cstdlib>
#include <iostream>
#include <memory>
#include <sstream>
#include <string>
#include <typeinfo>
#include <vector>
using namespace std;
// Span is a lightweight view on a buffer that provides an iterator interface
// Inspired by GSL Span
template <class T> class Span {
public:
... |
// Copyright <NAME> 2016, 2017
// 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 writi... |
// SPDX-FileCopyrightText: 2015 - 2021 <NAME> <<EMAIL>>
// SPDX-License-Identifier: MIT
#include <cstdlib>
#include <iostream>
#include <string>
#include "ads/bspline/bspline.hpp"
#include "stokes.hpp"
ads::dimension make_dimension(int p, int c, int n, int quad, int ders) {
int rep = p - 1 - c;
auto basis = ... |
/*
* Copyright (c) 2017, [Ribose Inc](https://www.ribose.com).
* 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
* no... |
#include <iostream>
#include <fstream>
#include <filesystem>
#include <optional>
#include <sstream>
#include <vector>
#include <cstring>
#include <cmath>
#include <algorithm>
std::uint32_t readLE32(const std::vector<std::uint8_t> block, size_t offset)
{
return block[offset + 0] + (block[offset + 1] << 8) + (block[... |
#include "pir_client.hpp"
using namespace std;
using namespace seal;
using namespace seal::util;
PIRClient::PIRClient(const EncryptionParameters ¶ms,
const EncryptionParameters &expanded_params, const PirParams &pir_parms) {
params_ = params;
SEALContext context(params);
expande... |
/* Copyright (c) 2019 vesoft inc. All rights reserved.
*
* This source code is licensed under Apache 2.0 License.
*/
#include <gtest/gtest.h>
#include "common/base/Base.h"
#include "common/network/NetworkUtils.h"
#include "kvstore/plugins/hbase/HBaseClient.h"
/**
* TODO(zhangguoqing) Add a test runner to provide... |
#include <Allmund.h>
#include <Allmund/Actor.h>
#include <Allmund/Camera.h>
#include <Allmund/Graphics/VertexBuffer.h>
#include <Allmund/Graphics/Model.h>
#include <glm/glm.hpp>
#include <Allmund/Scene.h>
#include <Allmund/Graphics/Shader.h>
#include <Allmund/Graphics/Material.h>
#include "SandboxActor.h"
using namesp... |
/*
Bullet Continuous Collision Detection and Physics Library
Copyright (c) 2011 Advanced Micro Devices, Inc. http://bulletphysics.org
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.
Per... |
/*
Tencent is pleased to support the open source community by making
Plato available.
Copyright (C) 2019 THL A29 Limited, a Tencent company.
All rights reserved.
Licensed under the BSD 3-Clause License (the "License"); you may
not use this file except in compliance with the License. You may
obtain a copy... |
/**
* Copyright (c) 2017-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 ... |
#include "../include/motor_controller.hpp"
MotorController::MotorController(const Motor::Gpio &motorGpio, uint8_t encoderAddr, bool _reverseEncoder, TwoWire &encoderI2c)
: motor(motorGpio), encoder(encoderAddr, encoderI2c), reverseEncoder(_reverseEncoder),
fakeInertia(0.18), pid(-1, 1) {}
MotorControl... |
#include <OS.h>
#include <string.h>
#include <sys/select.h>
#include "TCPStream.h"
TTCPStream::TTCPStream(BDataIO *dataIO, struct sockaddr_in *addr,
bigtime_t waitTime, uint32 buffSize, tcp_stream_mode_t tcpStreamMode)
{
int block;
fTransferredSize = 0;
fDataIO = dataIO;
fWaitTime = waitTime;
fEndpoint = socket... |
/** Sensor Processing */
#include <Arduino.h>
#include "Adafruit_BME280.h"
#include "Adafruit_PM25AQI.h"
#include "Adafruit_SGP30.h"
#include "EEPROM_Rotate.h"
#include "config.h"
#include "error.h"
#include "sensor.h"
// Sensor Objects
Adafruit_BME280 bme;
Adafruit_SGP30 sgp;
Adafruit_PM25AQI aqi;
// Sensor Valu... |
#include <iostream>
#include <ctime>
#include <utility>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include "hls_stream_utils.h"
#include "sizes.h"
#define TOTAL_SIZE 3500000
//TRIPCOUNT identifiers
const unsigned int t_size = TOTAL_SIZE;
const unsigned int pf = PARALLELISATION;
#ifndef PARALLELISATIO... |
#define _USE_MATH_DEFINES
#include <heat_solver_3d/solver.hpp>
#include <mpi.h>
#include <cmath>
#include <chrono>
#include <fstream>
#include <sstream>
#include <iomanip>
#include <iostream>
#include <algorithm>
// Creating the handler, that will log to stderr the current step and time
class plasma_torch_handler_t... |
//ROS headers
#include<ros/ros.h>
#include<image_transport/image_transport.h>
#include<cv_bridge/cv_bridge.h>
#include<sensor_msgs/image_encodings.h>
//OpenCV headers
#include<opencv2/imgproc/imgproc.hpp>
#include<opencv2/highgui/highgui.hpp>
#include<iostream>
#include<stdlib.h>
#include<thread>
#include "settings... |
#include "stream_outlet_impl.h"
#include "tcp_server.h"
#include "udp_server.h"
#include <boost/bind.hpp>
#include <boost/thread/thread_only.hpp>
#include <memory>
// === implementation of the stream_outlet_impl class ===
using namespace lsl;
using namespace lslboost::asio;
/**
* Establish a new stream outlet. This ... |
/* gph-cmath - C graphics math library
* Copyright (C) 2018 <NAME> <<EMAIL>>
*
* This program is free software. Feel free to use, modify, and/or redistribute
* it under the terms of the MIT/X11 license. See LICENSE for details.
* If you intend to redistribute parts of the code without the LICENSE file
* replace t... |
#pragma once
#include <vk_mem_alloc.h>
#include <mutex>
#include <unordered_map>
#include <atomic>
#include <vuk/Hash.hpp>
#include <../src/Cache.hpp> // for the hashes
#include <../src/CreateInfo.hpp>
#include <vuk/Types.hpp>
#include <vuk/Buffer.hpp>
#include <vuk/Image.hpp>
namespace vuk {
struct PoolSelect {
M... |
// Copyright (c) 2017 University of Minnesota
//
// ADMM-Elastic Uses the BSD 2-Clause License (http://www.opensource.org/licenses/BSD-2-Clause)
// Redistribution and use in source and binary forms, with or without modification, are
// permitted provided that the following conditions are met:
// 1. Redistributions of ... |
#include <Arduino.h>
#include <SD.h>
#include <SPI.h>
#include <EEPROM.h>
#include <Ethernet.h>
#include "ICMPPing.h"
unsigned char mac[6] = { 0xec, 0xa8, 0x00, 0x00, 0x00, 0x00 };
IPAddress ip1 = { 0, 0, 0, 0 };
IPAddress ip2 = { 0, 0, 0, 0 };
IPAddress ip3 = { 0, 0, 0, 0 };
IPAddress ip4 = { 0, 0, 0, 0 };
IPAddre... |
/**
* @file: Baseline2.cpp
* @brief:
* @author: <NAME>, <EMAIL>, <EMAIL>
* @version: 0.0.1
* @creation date: 17-12-2015
* @last modified: Thu 10 Mar 2016 09:32:02 AM EST
*/
#include <iostream>
#include <string>
#include <fstream>
#include <algorithm>
#include <vector>
#include "Baseline2.hpp"
using namespace s... |
/*
Copyright (c) 2020 by <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, distribute, ... |
/* (c) <NAME>. See licence.txt in the root of the distribution for more information. */
/* If you are missing that file, acquire a complete release at teeworlds.com. */
#include <base/system.h>
#include <cstdlib>
struct CPacket
{
CPacket *m_pPrev;
CPacket *m_pNext;
NETADDR m_SendTo;
int64 m_Timest... |
/*
* Copyright (C) 2003 <NAME>; CTIE, Monash University, Australia
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later... |
#include "sam_processing.h"
#include "cigar.h"
#include <cstring>
#include <iostream>
#include <sstream>
using std::stringstream;
using std::map;
using std::pair;
using std::string;
using std::map;
using std::vector;
std::array<std::string, 7> read_types{{
"BreakPointSupport",
"BreakPointSupportOEA",
"B... |
// Copyright 2021 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <fcntl.h>
#include <sys/mman.h>
#include <sys/stat.h>
#include <cstdio>
#include <set>
#include <string>
#include <fbl/unique_fd.h>
#include <sr... |
/*
* https://www.geeksforgeeks.org/sql-using-c-c-and-sqlite/
* You can install SQLite library with "sudo apt-get install libsqlite3-dev"
*/
#include "sqlite3.h"
#include "auxiliar.hpp"
void generateWorldDB();
void queryManager();
int main(int argc, char** argv)
{
//generateWorldDB();
queryManager();
... |
#include "WebUtil.h"
const char *CRLF = "\r\n";
const char *SP = " ";
const String no_err = String("");
// '/' was excluded from the reserved symbols to be able to check the path as a whole.
const char reserved[9] = {';', '?', ':', '@', '&', '=', '+', '$', ','};
const String methods[8] = {String("GET"), String("HEAD")... |
/******************************************************************************
/ ActiveTake.cpp
/
/ Copyright (c) 2010 <NAME> (SWS)
/
/
/ 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 withou... |
#include <algorithm>
#include <map>
#include <set>
#include <vector>
#include "caffe/layer.hpp"
#include "caffe/net.hpp"
#include "caffe/vision_layers.hpp"
template <typename Dtype>
Dtype round(Dtype r)
{
return (r > 0.0) ? floor(r + 0.5) : ceil(r - 0.5);
}
namespace caffe {
template <typename Dtype>
void CropLaye... |
/*
* RT_v0.cc
*
* Created on: Jan 20, 2021
* Author: lina
*/
#include <string.h>
#include <omnetpp.h>
#include "Snail_m.h"
#include "ND_m.h"
#include "Set.h"
using namespace omnetpp;
enum{
ND_ACK = 2,
ND_REQUEST = 3
};
class Node : public cSimpleModule {
private:
//
Set RT0;
... |
#include <gpt-manipulator.h>
#include <iostream>
#include <bitset>
#include <cstring>
#include <error.h>
struct UUID {
uint32_t time_low;
uint16_t time_mid;
uint16_t time_high_version;
uint8_t clock_seq_high_and_reserved;
uint8_t clock_seq_low;
uint8_t node[6];
} __attribute__((packed));
void printGUID(co... |
/* Copyright (c) 2020 Qmlio
*
* 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, distrib... |
//---------------------------------------------------------------------------
#include "Generic.h"
#pragma hdrstop
//---------------------------------------------------------------------------
// Color elements as constants so they can be edited in one place.
// * * * * * * * BEGIN COLOR CONSTANTS * * * * ... |
// This code contains NVIDIA Confidential Information and is disclosed to you
// under a form of NVIDIA software license agreement provided separately to you.
//
// Notice
// NVIDIA Corporation and its licensors retain all intellectual property and
// proprietary rights in and to this software and related documentation... |
#include "filter_process.h"
#include <opencv2/opencv.hpp>
#include <opencv2/highgui.hpp>
#include<opencv2/imgproc/imgproc.hpp>
#include<opencv2/objdetect/objdetect.hpp>
using namespace cv;
using namespace std;
Mat whiteFace(const Mat& src, int degree){
if(degree==0){
return src;
}
Mat result = src.c... |
/**
* Copyright 2011-2015 DrumPants, Inc.
*
* http://developers.drumpants.com
*
* 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
*... |
// Mod/a.hpp
#pragma once
template <int M>
class Mod
{
protected:
int m_n;
int m_inv;
static int Residue( const int& n ) noexcept;
static uint Residue( const uint& n ) noexcept;
public:
Mod() noexcept;
Mod( const int& n ) noexcept;
Mod( const uint& n ) noexcept;
Mod( const Mod<... |
// MIT License
//
// This file is part of SpaceGame.
// Copyright (c) 2014-2018 <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 ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.