text stringlengths 3.08k 12.5k |
|---|
#include <climits>
#include <cstdint>
#include <cstdlib>
#include <iostream>
#include <string>
#include <vector>
#include "snarkfront.hpp"
using namespace snarkfront;
using namespace cryptl;
using namespace std;
void printUsage(const char* exeName) {
const string
AES = " -b 128|192|256",
KEY = " ... |
#include "pch.h"
#include "ComApartment.h"
#include "Include/ComUtility/Utility.h"
#include <cassert>
#include <ctxtcall.h>
#include <wrl.h>
using Microsoft::WRL::ComPtr;
/** An 'apartment' inside the apartment that allows cleaning
up objects that are left in the apartment before we shut down. */
class Apartmen... |
#include <iostream>
#include "fechahistorica.h"
#include <sstream>
#include <string>
#include <algorithm>
#include <cassert>
using namespace std;
// Constructor por defecto
FechaHistorica::FechaHistorica() : m_fecha{0}{}
// Constructor con parámetros
FechaHistorica::FechaHistorica(const unsigned int & fecha, const v... |
/*
* Copyright 2016 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "Resources.h"
#include "SkCodec.h"
#include "SkColorPriv.h"
#include "SkColorSpace.h"
#include "SkColorSpace_Base.h"
#include "SkColorSpaceXform.h"
#include "Test.h"
... |
#include <iostream>
#include <SDL/SDL.h>
#include "gfxHelper.h"
#define WINDOW_WIDTH 800
#define WINDOW_HEIGHT 600
#define POINT_RADIUS 3
#define NUMBER_OF_POINTS 8
void update();
void draw();
void end();
bool isRunning;
bool pauseSpinning = false;
int curPoint = 0;
SDL_Window* window;
SDL_Renderer* renderer;
... |
#include "stdafx.h"
#include "graphics/Frustum.h"
#include "Constants.h"
void vg::Frustum::Plane::setNormalAndPoint(const f32v3 &normal, const f32v3 &point) {
this->normal = vmath::normalize(normal);
d = -(vmath::dot(this->normal, point));
}
void vg::Frustum::Plane::setCoefficients(f32 a, f32 b, f32 c, f32 d... |
// include the header file
#include "getGeometryInput.h"
// this function handles the task of reading in input geometry files in STL format
// and finding out the required size of the environmental box
int getGeometryInput(std::vector<triangle> &facet, std::string STL_files_path, std::string STL_filename)
{
... |
#include <bits/stdc++.h>
using namespace std;
template <typename A, typename B>
string to_string(pair<A, B> p);
template <typename A, typename B, typename C>
string to_string(tuple<A, B, C> p);
template <typename A, typename B, typename C, typename D>
string to_string(tuple<A, B, C, D> p);
string to_string(con... |
#include "common.hpp"
#include "gtest/gtest.h"
#include "../src/sobel.hpp"
cv::Mat_<cv::Vec4b> expectedResult = (cv::Mat_<cv::Vec4b>(5,5) << cv::Vec4b{0, 0, 0, 255}, cv::Vec4b{0 , 0 , 0 , 255}, cv::Vec4b{0 , 0 , 0 , 255}, cv::Vec4b{0, 0, 0, 255}, cv::Vec4b{0, 0, 0, 255},
cv::Vec4b{0, 0, 0, 255}, cv... |
#include "Draw.h"
#include <time.h>
#define MAX 5
void MapDraw() // 洹몃━???⑥닔??珥앷큵
{
WDraw();
HDraw();
TitleDraw();
CursorDraw(MenuStart, MenuEnd, MenuY);
Sleep(20);
}
void Record(Player &p, Player* p_list)
{
p_list[Player::P_Number].SetName(p.GetName());
p_list[Player::P_Number].SetAtk(p.GetAtk(... |
// Copyright 2020 the Autoware Foundation
//
// 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... |
#include "D3D11Helper.hpp"
#include "Mat4.hpp"
#include "Light.hpp"
#include "ShadowBuffer.hpp"
#include "Drawers/DirLightDrawer.hpp"
using namespace Cookie::Core::Math;
using namespace Cookie::Render;
struct PS_DIRLIGHT_BUFFER
{
Vec3 dir;
float padding = 0.0f;
Vec3 color = { 1.0f,1.0f,1.0f... |
/**
\file pabod.cpp
\author <NAME> and <NAME>
// (c) MJMJ/2012
*/
#include <cassert>
#include <cstdlib>
#include <pabod.h>
#include <makeDetection.h>
#include <limits>
using namespace std;
Pabod::Pabod()
{
_model = NULL;
_isCopied = false;
}
Pabod::Pabod(const Pabod & pabod)
{
_model = pabod._model; // Thi... |
#include "IPCLs.h"
std::string nar::MessageTypes::IPCLs::Request::get_dir_name(){
return _dir_name;
}
void nar::MessageTypes::IPCLs::Request::set_dir_name(std::string dn){
this->_dir_name = dn;
}
nlohmann::json nar::MessageTypes::IPCLs::Request::get_myrequestjson() {
nlohmann::json json_to_sent;
json... |
#include<iostream>
#include<conio.h>
#include<stdlib.h>
#include<stdio.h>
#include<time.h>
using namespace std;
void draw_line(int n, char ch);
void board();
void gamescore(char name1[], char name2[], int p1, int p2);
void play_dice(int & score);
int main()
{
int player1 = 0, player2 = 0, lastpos;... |
#include "preview.h"
//--------------------------------------------------------------
preview::preview(shared_ptr<outputWindowApp> outputWindow, shared_ptr<vmVideoSource> videoSource, shared_ptr<ofTrueTypeFont> std_font)
{
//keyboardShortcut = previewID++;
keyboardShortcut = -1;
this->outputWindow = outputWindow;
... |
#include "PixelFlutTCPSource.h"
#include <cstdlib>
#include <cstring>
#include <unistd.h>
#include <arpa/inet.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <sys/select.h>
#include <sys/ioctl.h>
#include <sys/poll.h>
PixelFlutTCPSource::PixelFlutTCPSource(const std::string& listenAddress, uint16_t listen... |
#include <stdio.h>
#include <stdint.h>
#include <string>
#include <iostream>
#include <cmath>
#include "../AxFastLog.hpp"
#include "TcpClient.hpp"
#include <omp.h>
#define AX_FPATH "test.txt"
#define TEST_STR "TESTING 1, 2, 3"
#define AX_HOST "localhost"
#define AX_SPORT 9000
#define TEST_ITERS 100
#define MS_MULTI 1... |
//! @file
//! @brief
//! Reference implementation of platform dependency functions which could be used
//! for coredump collection on Mbed OS 5
#include "memfault/panics/platform/coredump.h"
#include <string.h>
#include "hal/flash_api.h"
#include "platform/mbed_mpu_mgmt.h"
#include "memfault/core/compiler.h"
#includ... |
#include <devastator/diagnostic.hxx>
#include <devastator/world.hxx>
#include <devastator/pdes.hxx>
#include <atomic>
#include <vector>
#include <cmath>
#include <cstdint>
#include <memory>
#include <sched.h>
#include "phold-bs-params.hxx"
#include "backstroke_phold-bs-state.hxx"
#include "backstroke/rtss.h"
using ... |
/*
Title:
42. Trapping Rain Water
42. 接雨水
Address:
https://leetcode-cn.com/problems/trapping-rain-water/
Reference:
https://leetcode-cn.com/problems/trapping-rain-water/solution/jie-yu-shui-by-leetcode/
https://mp.weixin.qq.com/s/f9ebzbwymR8jQeUDxjeCDA
*/
/*
方法一:暴力法 - 超时
方法二:「改进」暴力法
方法... |
#include <algorithm>
#include <cassert>
#include <cstdio>
#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include <cstring>
#include <map>
using namespace std;
string to_str(int x) {
ostringstream os;
os << x;
return os.str();
}
class Kings {
public:
vector <string>... |
#include "Socket.h"
#include "mb_exceptions.h"
#include <fcntl.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <iostream>
#include <spdlog/spdlog.h>
using namespace std;
using namespace modbus::tcp;
struct timeval sockTimeout = {.tv_sec = 1, .tv_usec = 0};
void hexDump(const char *desc, void *addr, int len);
... |
/*
* Digital_Light_TSL2561.cpp
* A library for TSL2561 at RP
*
* Copyright (c) 2012 seeed technology inc.
* Website : www.seeed.cc
* Author : zhangkun
* Create Time:
* Change Log :
*
* The MIT License (MIT)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this so... |
#include "phold.h"
tw_peid
phold_map(tw_lpid gid)
{
return (tw_peid) gid / g_tw_nlp;
}
void
phold_init(phold_state * s, tw_lp * lp)
{
int i;
new (s) phold_state;
if( stagger )
{
for (i = 0; i < g_phold_start_events; i++)
{
tw_event_send(
tw_event_new(lp->gid,
... |
#include <iostream>
#include <cstdio>
#include <cctype>
#include <cstring>
using namespace std;
#define KEYWORDNUM 9 // 关键字个数
#define MAXLENGTH 39 // 标识符最大长度
#define MAXFILENAME 100 // 文件名最大长度
namespace Testscan {
FILE *fin, *fout;
char Scanin[MAXFILENAME], Scanout[MAXFILENAME];
char *keyword[KEYWO... |
#include <ros/ros.h>
#include <serial/serial.h>
#include <vector>
#include <map>
#include <algorithm>
#include <string>
#include <iostream>
#include <stdexcept>
#include <cstdint>
#include <boost/property_tree/ptree.hpp>
#include <boost/property_tree/json_parser.hpp>
#include "monitor/SerialDevice.h"
#include "monitor/... |
#pragma once
#include <memory>
#include <string>
#include <vector>
#include <unordered_map>
#include "../Error.hpp"
#include "../Operators.hpp"
namespace slim
{
class Object;
class Boolean;
class Number;
typedef std::shared_ptr<Object> ObjectPtr;
typedef std::shared_ptr<const Object> CObjectPtr;
... |
#include "Audio.h"
void errorCheck(int iCh, int iSR, int rSR){
if(iCh != 1){
fprintf(stderr, "ERROR: Program can only take mono files\n");
exit(100);
}
if (iSR != rSR) {
fprintf(stderr, "ERROR: Input and reverb files are two different sample rates\n");
fprintf(stderr, "Input file is %i... |
/**
* Copyright 1993-2017 NVIDIA Corporation. All rights reserved.
*
* Please refer to the NVIDIA end user license agreement (EULA) associated
* with this source code for terms and conditions that govern your use of
* this software. Any use, reproduction, disclosure, or distribution of
* this software and relate... |
//
// main.cpp
//
// This program implements a standard deviation function
//
// double stddev(Vector<double> & data);
//
// which computes the standard deviation of a complete distribution.
//
// --------------------------------------------------------------------------
// Attribution: "Programming Abstractions ... |
/** Kitchen Helper Project - MQTT Version
*/
#include "mbed.h"
#include "rtos.h"
#include "OLEDDisplay.h"
#include "MQTTEthernet.h"
#include "MQTTClient.h"
#include "RemoteCooker.h"
// Topic's
char* topicTimer = "cooker/timer";
char* topicMenu = "cooker/menu";
char* topicKeepwarm = "cooker/keepwarm";
//... |
#include <stdio.h>
#include <cstdlib>
#include <sys/wait.h>
#include <sys/types.h>
#include <unistd.h>
#include <string>
#include <iostream>
#include <fcntl.h>
#include <rtos_ipc.hpp>
#include <rtos_timer.hpp>
#include <limits.h>
#include <rtos_shared_mem.hpp>
#include <sys/resource.h>
#include <sys/mman.h>
#include... |
//
// action_queue.cpp
// kssthread
//
// Created by <NAME> on 2018-11-09.
// Copyright © 2018 Klassen Software Solutions. All rights reserved.
// Licensing follows the MIT License.
//
#include <condition_variable>
#include <exception>
#include <iostream>
#include <map>
#include <mutex>
#include <system_error>
#i... |
#define BIORBD_API_EXPORTS
#include "Utils/RotoTrans.h"
#include "Utils/Error.h"
#include "Utils/Vector3d.h"
#include "Utils/String.h"
#include "Utils/Vector.h"
#include "Utils/Rotation.h"
#include "RigidBody/NodeSegment.h"
using namespace BIORBD_NAMESPACE;
utils::RotoTrans::RotoTrans(
const RigidBodyDynamics::... |
//
// Histogram Matching algorithm
// Copyright 2016 <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, cop... |
#include <cassert>
#include <climits>
#include <cstdint>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <vector>
#include <string>
#include <utility>
constexpr size_t MaxCodes = 512;
constexpr size_t MaxBitLength = 16;
constexpr uint16_t EmptySentinel = UINT16_MAX;
#define panic0(msg) ... |
/*
* Copyright (c) 2013 <NAME> <<EMAIL>>
*
* Permission to use, copy, modify, and 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 copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCL... |
// ---------------------------------------------------------------------------
//
// The ab-initio based multiscale library
//
// S / P H I / n X
//
// Copyright: Max-Planck-Institute for Iron Research
// 40237 Duesseldorf, Germany
//
// Contact: https://sxlib.mpie.d... |
// 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 ap... |
/* Copyright (c) 2011 <NAME> */
/* Floating Point Colors may be freely redistributed. See license for details. */
#include "sdl.h"
#include "variables.h"
using namespace std;
GLuint surface_to_texture(SDL_Surface* optimized_image){
GLuint texture;
GLenum texture_format;
GLint nOfColors;
nOfColors=op... |
#include <cmath>
#include <vector>
#include <algorithm>
#include <iostream>
#include <stdio.h>
#include <string.h>
#include <utility>
#include "approximations-utils.h"
#include "s-approximations.h"
#include "p-approximations.h"
#include "approximations.h"
#include "output-utils.h"
#include "parameters-utils.h"
#defi... |
/*
* File: CvPyMat.cpp
* Author: mbustreo
*
* Created on 19 November 2015
*
* This class allows to move data from C++ to Python and viceversa in realtime.
* In this way it is possible to reuse OpenCV C++ code in Python.
* See pyttest for howTo use.
* Personal adaptation of CvBridge - module_opencv2.cpp func... |
#include "CrazyConsole.h"
CrazyConsole::CrazyConsole() : OGLConsole() {
heightshift = new CrazyDouble(this, 0, 0.05, 0.00008, -150, 50);
xangleShift = new CrazyDouble(this, 0, 0.1, 0.00016, -50, 50);
yangleShift = new CrazyDouble(this, 0, 0.1, 0.00016, -50, 50);
zangleShift = new CrazyDouble(this, 0, 0.1, 0.00016... |
/**
Copyright 2016-2019 Red Anchor Trading Co. Ltd.
Distributed under the Boost Software License, Version 1.0.
See <http://www.boost.org/LICENSE_1_0.txt>
*/
#include <odin/nonce.hpp>
#include <odin/odin.hpp>
#include <odin/views.hpp>
#include <fost/crypto>
#include <fost/insert>
#include <fost/log>
#in... |
/**
* @file
* @brief [Subset Sum Problem](https://en.wikipedia.org/wiki/Subset_sum_problem)
* (https://www.geeksforgeeks.org/subset-sum-problem-dp-25)
* @details
* Given a set of non-negative integers, and a value sum, determine if there is
* a subset of the given set with sum equal to given ... |
#include <cstdio>
#include <cstdlib>
#include <unistd.h>
#include "Vsound.h"
#include "verilated.h"
#include "verilated_vcd_c.h"
//------------------------------------------------------------------------------
typedef unsigned char uint8;
typedef unsigned short uint16;
typedef unsigned int uint32;
typedef unsigne... |
//
// twiddle.cpp
//
// Created by <NAME> on 10/04/18.
//
//
#include "twiddle.hpp"
#include <math.h>
#include <iostream>
using namespace std;
Twiddle::Twiddle() {}
Twiddle::~Twiddle() {}
void Twiddle::Init(double dp, double di, double dd, int apply_twiddle, int free_init, int tuning_range) {
best_error = 0... |
// Copyright (c) 2019 <NAME>
// Email : <EMAIL>
// LinkedIn : https://www.linkedin.com/in/philippe-julien-a80b2442/
// License : MIT
// https://opensource.org/licenses/MIT
#include "ParticleSystem.h"
#include <random>
ParticleSystem::ParticleSystem()
: mFriction(0.01f)
, mMinParticleInteractionD... |
#include <iostream>
#include <memory>
class ProductBase {};
class Product1 : public ProductBase {
public:
template <typename T,
typename = typename std::enable_if_t <!std::is_same_v<Product1, std::decay_t<T>>>>
explicit Product1(T&& param) : param_name{std::forward<T>(param)} {} // /+\label{line:T... |
#include <dseed.h>
#include <algorithm>
constexpr int64_t TICKS_PER_MILLISEC = 10000LL;
constexpr int64_t TICKS_PER_SECOND = (TICKS_PER_MILLISEC * 1000LL);
constexpr int64_t TICKS_PER_MINUTE = (TICKS_PER_SECOND * 60LL);
constexpr int64_t TICKS_PER_HOUR = (TICKS_PER_MINUTE * 60LL);
constexpr int64_t TICKS_PER_DAY = (T... |
#include <vector>
#include<iostream>
#include <list>
#include <string>
using namespace std;
template<typename K, typename V>
class Tupla {
private:
public:
K chave;
V valor;
Tupla(K c, V v) {
chave = c;
valor = v;
}
bool operator==(const Tupla<K, V> &t) {
return t.chave == ... |
#include "stdafx.h"
#include "2UnicodeHandler.h"
#include <helper/SplitString.h>
C2UnicodeHandler::C2UnicodeHandler(void)
{
}
C2UnicodeHandler::~C2UnicodeHandler(void)
{
}
void C2UnicodeHandler::OnInit( SWindow *pPageRoot )
{
CFolderHander::OnInit(pPageRoot->FindChildByName(L"page_2unicode"));
... |
#include <cmath>
#include <maths/io.hpp>
#include <tools/log.hpp>
#include <maths/algebra.hpp>
#include "host/GLFW/application.hpp"
#include <graphics2/plotter/plotter.hpp>
#include <renderer/camera.hpp>
using namespace zap;
using namespace zap::maths;
using namespace zap::renderer;
class plotter : public application... |
////////////////////////////////////////////////////////////////////////////////
/// DISCLAIMER
///
/// Copyright 2014-2022 ArangoDB GmbH, Cologne, Germany
/// Copyright 2004-2014 triAGENS GmbH, Cologne, Germany
///
/// Licensed under the Apache License, Version 2.0 (the "License");
/// you may not use this file except... |
#include "moduleimpl.h"
#include "proxyimpl.h"
#include "ioport.h"
#include "cdimpl.h"
#include "context.h"
using namespace ch::internal;
static uint32_t find_port_index(moduleportimpl* port, const std::vector<lnode>& list) {
// lookup existing binding
for (uint32_t index = 0; index < list.size(); ++index) {
... |
/*
* Copyright 2018 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 applica... |
//===-- RISCVSubtarget.cpp - RISCV Subtarget Information ------------------===//
//
// 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
//
//===---------------------------... |
// (c) 2015 Zedge Inc.
//
// include Python.h first to get of the _POSIX_C_SOURCE warning
#include <Python.h>
#include <iostream>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include "caffe/caffe.hpp"
#include "caffe/util/io.hpp"
#include "caffe/blob.hpp"
#include "zedge_caffe.h"
usi... |
// Copyright (c) 2017-2019 The PIVX developers
// Copyright (c) 2020 The BTCU developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "blocksignature.h"
#include "main.h"
#include "zbtcuchain.h"
#include "validators_... |
/*
* Copyright 2007-2021 CM4all GmbH
* All rights reserved.
*
* author: <NAME> <<EMAIL>>
*
* 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
... |
#include "process.hpp"
#include <cstdlib>
#include <unistd.h>
#include <signal.h>
#include <stdexcept>
Process::Data::Data(): id(-1) {}
Process::id_type Process::open(const std::string &command, const std::string &path) {
if(open_stdin)
stdin_fd=std::unique_ptr<fd_type>(new fd_type);
if(read_stdout)
stdou... |
//===------------------------------------------------------------*- C++ -*-===//
//
// SHAD
//
// The Scalable High-performance Algorithms and Data Structure Library
//
//===----------------------------------------------------------------------===//
//
// Copyright 2018 Battelle... |
/* ----------------------------------------------------------------- */
/* The HMM-Based Singing Voice Synthesis System "Sinsy" */
/* developed by Sinsy Working Group */
/* http://sinsy.sourceforge.net/ */
/* -----------------------------... |
#include <glib.h>
#include <iostream>
#include <base/nugu_log.h>
#include <capability/asr_interface.hh>
#include <capability/audio_player_interface.hh>
#include <capability/capability_factory.hh>
#include <capability/system_interface.hh>
#include <capability/text_interface.hh>
#include <capability/tts_interface.hh>
#i... |
//
// Created by <NAME> on 24/03/19.
//
#include "media_file_builder.h"
#include "frame_loader_context.h"
#include "utils.h"
extern "C" {
#include <libavformat/avformat.h>
#include <libavcodec/avcodec.h>
#include <libavutil/bprint.h>
}
static jstring toJString(const char *cString) {
jstring result = nullptr;
... |
#include <cstdio>
#include <iostream>
#include <cmath>
#include <algorithm>
#include <cstring>
#include <map>
#include <set>
#include <vector>
#include <utility>
#include <queue>
#include <stack>
#include <cassert>
#define sd(x) scanf("%d",&x)
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&... |
//
// Copyright (C) 2014 <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 ... |
#include "stdafx.h"
#include "send_feedback.h"
#include "../../../core.h"
#include "../../../network_log.h"
#include "../../../http_request.h"
#include "../../../corelib/enumerations.h"
#include "../../../tools/system.h"
#include "../../../tools/strings.h"
#include "../../../../external/minizip/zip.h"
us... |
/*******************************************************************************
* tests/classic_index_construction.cpp
*
* Copyright (c) 2018 <NAME>
*
* All rights reserved. Published under the MIT License in the LICENSE file.
******************************************************************************/
#incl... |
#include "mbed.h"
#include "greentea-client/test_env.h"
#include "unity.h"
#include "utest.h"
#include <stdlib.h>
#include <errno.h>
using namespace utest::v1;
// test configuration
#ifndef MBED_TEST_FILESYSTEM
#define MBED_TEST_FILESYSTEM FATFileSystem
#endif
#ifndef MBED_TEST_FILESYSTEM_DECL
#define MBED_TEST_FILE... |
/*
* DFXML reader in C++ using SAX.
* Revision History:
* 2012 - <NAME> - Developed as test program.
*
* This file is public domain.
*/
#include <config.h>
#include <iostream>
#include <fstream>
#include <sstream>
#include <stdio.h>
#include <errno.h>
#include <stdlib.h>
#include <time.h>
#include <stdint.h>
... |
//--------------------------------------------------------------------------------------
// File: EncoderBase.cpp
//
// Common base for Compute Shader 4.0 Accelerated BC6H and BC7 Encoder
//
// Advanced Technology Group (ATG)
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License (MIT).
//---... |
#include "Halide.h"
using namespace Halide;
Var x("x"), y("y"), c("c");
int main(int argc, char **argv) {
// First define the function that gives the initial state.
{
Param<float> cx, cy;
Func initial;
// The initial state is a quantity of three chemicals present
// at each p... |
#include "WGroup.h"
WGroup::WGroup(GroupSchedule &groupSchedule_, QWidget *parent)
: QWidget(parent), groupScheduleRef(groupSchedule_) {
for (int day = 0; day < 6; ++day) {
for (int lesNum = 0; lesNum < 6; ++lesNum) {
WLesson *wLesson = new WLesson(lesNum + 1, lessonsTimeList[le... |
#include "test_env.h"
/******************************************************************************
* This will test an I2C EEPROM connected to mbed by writing a predefined byte at
* address 0 and then reading it back and comparing it with the known byte value a
* number of times. This test was written specifical... |
// Copyright (c) Microsoft Corporation.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#pragma once
#include <algorithm>
#include <cstddef>
#include <forward_list>
#include <functional>
#include <initializer_list>
#include <input_iterator.hpp>
#include <iterator>
#include <list>
#include <tuple... |
#include "sound.h"
#include "../common/bgmid.h"
#include "../common/strcode.h"
#include "func.h"
#include "ruletbl.h"
#include <vector>
#include <regex>
#include "envtbl.h"
#ifdef None
#undef None
#endif
#ifdef _WIN32
#define BGMDIR "bgm\\"
#else /* _WIN32 */
#define BGMDIR "bgm/"
#endif /* _WIN32 */
namespace {
... |
// Copyright 2021 Embedded Dev Research
#include <arm_neon.h>
#include <cstdio>
#include <cmath>
#include <random>
#include <algorithm>
#include <iterator>
#include <iostream>
#include <vector>
#include <omp.h>
#include "arm_gemm.hpp"
#define BLOCK_SIZE 4
void generate_matrix(std::vector<float32_t> &A, std::vector<f... |
//=======- CaptureTrackingTest.cpp - Unit test for the Capture Tracking ---===//
//
// 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
//
//===---------------------------... |
/// CSCLayerGeometryInside.cc
/// Test CSCLayerGeometry::inside fiducial function
/// <NAME> - 06.05.2009
#include "FWCore/Framework/interface/one/EDAnalyzer.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#inclu... |
#include <bits/stdc++.h>
#include <cmath>
#include <iostream>
using std::cout;
using std::endl;
/*
f(t_n, y_n) returns the derivative of y at time t_n.
For our purposes, we need f() to return two derivatives: The first
derivative of position, v, and the second, a. Accordingly, we start with the
equatio... |
// Copyright GREYC - UMR 6072 ; Université de Caen Normandie
// Esplanade de la paix
// CS 14032
// 14032 Caen CEDEX 5
// contributeur :
// <NAME>, 2015
//
// <EMAIL>
//
// Ce logiciel est un programme informatique servant à la comparaison et à l'analyse d'outils de détection de communauté.
//
// Ce logiciel est rég... |
/*
* Copyright (c) 2011, <NAME> and IFS Institute for Software at HSR Rapperswil, Switzerland
* All rights reserved.
*
* This library/application is free software; you can redistribute and/or modify it under the terms of
* the license that is included with this library/application in the file license.txt.
*
* Au... |
///
/// \file timing.hpp
///
/// This file defines types and routines for platform-independent time measuring.
///
/// \autor <NAME> <<EMAIL>>
///
/// This file is a part of the XTL framework (http://parasol.tamu.edu/xtl/).
/// Copyright (C) 2005-2012 Texas A&M University.
/// All rights reserved.
///
#pra... |
#include "TestDrawMesh.hpp"
CG::Test::TestDrawMesh::TestDrawMesh()
: m_Fov { 90 }
, m_HelpOpened { false }
, m_ControllerFreeze { false }
, m_FpsMode { false }
, m_ObjectColor { glm::vec3(1.f, .0f, .0f) }
, m_LightPos { glm::vec3(0.f, 10.0f... |
/** --------------------------------------------------------------------------------------------------------------------
* <copyright company="Aspose" file="test_base.cpp">
* Copyright (c) 2022 Aspose.Cells for Cloud
* </copyright>
* <summary>
* Permission is hereby granted, free of charge, to any person obtaining... |
/**********
Copyright (c) 2017, Xilinx, 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:
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the fol... |
#include "driver.h"
#include "vidhrdw/generic.h"
#include "vidhrdw/konamiic.h"
#include "cpu/konami/konami.h"
#include "machine/eeprom.h"
/* from vidhrdw */
extern void simpsons_video_banking( int select );
extern unsigned char *simpsons_xtraram;
int simpsons_firq_enabled;
/******************************... |
#include <algorithm>
#include <cassert>
#include <cstdio>
#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include <cstring>
using namespace std;
vector< vector<int> > D, E;
void print(const vector< vector<int> > &v, int moves) {
cerr << moves;
for (int i=0; i<3; ++i) ... |
#include "structure.h"
vector<Variant_t> VarVec;
int iSNV, iInsertion, iDeletion;
bool CompByVariantPos(const Variant_t& p1, const Variant_t& p2)
{
if (p1.chr_idx == p2.chr_idx) return p1.pos < p2.pos;
else return p1.chr_idx < p2.chr_idx;
}
void VariantIdentification()
{
int64_t rPos;
Variant_t Variant;
string ... |
/*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, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicens... |
//
// Created by Qichen on 9/22/16.
//
#include "RotationHelper.h"
/* sine cosine */
#include <math.h>
#include <algorithm>
#include <iostream>
using namespace std;
static float transformationMatrix[4][4] ={};
static float flattenedTransformationMatrix[16] ={};
/**
* prepare the flattened matrix to be feed into gl... |
/* ------------------------------------------------------------------
Copyright (c) 2017 <NAME>
email: <EMAIL>
This code is distributed under the MIT License.
Please see <root-path>/LICENSE for details.
-------------------------------------------------------------- */
#include "F_geometrics.h"
#... |
#include<bits/stdc++.h>
using namespace std;
// This node will be used in queue
class queue_node{
public:
int key; // The node identifier
int distance; // The shortest distance of the node from the source
queue_node(){}; //! Default constructor is important because when we are giving memory to vector<... |
/*
* Custom types for testing & libpqxx support those types
*/
#include <pqxx/strconv>
#include <cstdint>
#include <cstring>
#include <exception>
#include <iomanip>
#include <regex>
#include <sstream>
#include <string>
#include <vector>
class ipv4
{
public:
ipv4() : m_as_int{0u} {}
ipv4(const ipv4 &) =defaul... |
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
#include <precomp.h>
#include <windows.h>
#include "terminalOutput.hpp"
#include "strsafe.h"
using namespace Microsoft::Console::VirtualTerminal;
TerminalOutput::TerminalOutput()
{
}
TerminalOutput::~TerminalOutput()
{
}
/... |
#include "notaries_staked.h"
#include "crosschain.h"
#include "cc/CCinclude.h"
#include <cstring>
extern pthread_mutex_t staked_mutex;
//local vars due to unsupported notarisation now
int32_t STAKED_ERA;
char NOTARYADDRS[64][64];
extern uint8_t NOTARY_PUBKEY33[33];
std::string NOTARY_ADDRESS;
int32_t IS_STAKED_NOTAR... |
#include <algorithm>
#include <cstdlib>
#include "gamecore.h"
#include "log.h"
#include "operator.h"
using namespace std;
// 声明并定义一个tmp,为old的copy
#define newBoard(tmp, old) \
Board tmp { ... |
/**************************************************************************
*
* Copyright 2011-2012 <NAME>
* Copyright (C) 2013 Intel Corporation. All rights reversed.
* Author: <NAME> <<EMAIL>>
* All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this sof... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.