text stringlengths 3.08k 22k |
|---|
/*
* Copyright 2020 <NAME>.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
/* Copyright 1986 - 1998 by Abacus Research and
* Development, Inc. All rights reserved.
*/
/* Forward declarations in QuickDraw.h (DO NOT DELETE THIS LINE) */
#include <base/common.h>
#include <MemoryMgr.h>
#include <QuickDraw.h>
#include <CQuickDraw.h>
#include <quickdraw/cquick.h>
#include <quickdraw/picture.h... |
#include <string>
#include <vector>
//#include <math.h>
#include <cmath>
#include <armadillo>
using namespace arma;
#include "tree_utils.h"
#include "tree.h"
#include "cont_models.h"
#include "constants.h" // for PI and E
void calc_vcv(Tree * tree, mat & vcv) {
int numlvs = tree->getExternalNodeCount();
vcv... |
// $Header: /nfs/slac/g/glast/ground/cvs/calibGenCAL/src/CIDAC2ADC/smoothCIDAC2ADC.cxx,v 1.4 2008/07/06 22:43:15 fewtrell Exp $
/** @file Generate smoothed IntNonlin (cidac2adc) curves from raw
cidac2adc points, expects adcmean output from genCIDAC2ADC as input.
@author <NAME>
*/
// LOCAL INCLUDES
#include "I... |
/* lun_tran.cpp: computes lunar transit times
Copyright (C) 2010, Project Pluto
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, or (at your option) any later version... |
/**
* SPDX-License-Identifier: GPL-2.0-or-later
*
* This file is part of osm2pgsql (https://osm2pgsql.org/).
*
* Copyright (C) 2006-2022 by the osm2pgsql developer community.
* For a full list of authors see the git log.
*/
#include <memory>
#include <queue>
#include <stdexcept>
#include <vector>
#include <osm... |
#include <iostream>
#include <string>
#include <vector>
#include <deque>
#include <list>
#include <algorithm>
#include <regex>
#include <get_input.hpp>
struct Step {
char do_this = '\0';
char before = '\0';
};
std::ostream& operator<<(std::ostream& os, const Step& s)
{
return os << "Do " << s.do_this << ... |
/*
Copyright (c) 2012-2017 <NAME> <<EMAIL>>
This file is part of SimpleScreenRecorder.
SimpleScreenRecorder is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) an... |
/* Copyright (C) 2006 - 2013 ScriptDev2 <http://www.scriptdev2.com/>
* 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, or
* (at your option) any later version.... |
#include "chess_detector.h"
#include <opencv2/imgproc.hpp>
#include <opencv2/highgui.hpp>
ChessDetector::Params::Params()
{
radius = 10;
neighbourhood = 20;
estimateOrientation = true;
filterMinorOrientation = true;
}
ChessDetector::ChessDetector(const ChessDetector::Params ¶meters) :
m_points (NULL),
m_im... |
/*=========================================================================
Program: Visualization Toolkit
Module: vtkVolumePicker.cxx
Copyright (c) <NAME>, <NAME>, <NAME>
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is distributed WITH... |
#include "symtab.h"
map<string, int> SymTable::label2instr;
map<string, int> SymTable::var2index;
map<int, string> SymTable::index2var;
map<string, int> SymTable::reg2color;
map<int, string> SymTable::color2reg;
set<int> SymTable::precolored;
set<int> SymTable::initial;
set<int> SymTable::spilledVar;
set<int> SymTab... |
struct TrackHit {
Int_t PDG;
Float_t x;
Float_t y;
Float_t z;
Float_t p;
Float_t theta;
Float_t phi;
};
struct TrackWin {
Float_t x;
Float_t y;
};
struct TrackExp {
Float_t e;
Float_t mu;
Float_t pi;
Float_t K;
Float_t p;
Float_t d;
};
void scr... |
#include "spikes_t/SpikeS_T.h"
//------------------- Match SpikeS ----------------------
int countOnes(Mat& col_j, vector<int>& idx_ones)
{
int counter = 0;
//int* col_j_ptr = col_j.ptr<int>();
for (int i = 0; i<col_j.rows; i++)
{
if (col_j.at<int>(i, 0) == 1)
{
counter++;
idx_ones.push_back(i);
}
}... |
// Copyright (C) 2012-2019 Internet Systems Consortium, Inc. ("ISC")
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
#include <config.h>
#include "command_option... |
/* vim: set sts=0 ts=4 sw=4 noet tw=0 : */
#include "Sampling.h"
#include <stack>
#include <algorithm>
using namespace std;
double Sampling::len_threshold = 0.005;
// insert linear approximation of the quadratic curve, except for the first point.
void diceQuadratic(const Vec2d & focus, const QuadraticArc & q, std:... |
/*
* (C) Copyright 2016 Kurento (http://kurento.org/)
*
* 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 applicab... |
//++ BulliT
#include <VGUI_HeaderPanel.h>
#include <VGUI_TablePanel.h>
#include <VGUI_LineBorder.h>
#include <VGUI_Label.h>
#include <VGUI_Button.h>
#include <VGUI_ActionSignal.h>
#include <VGUI_TextGrid.h>
#include <VGUI_TextEntry.h>
#include <VGUI_EtchedBorder.h>
#include <VGUI_LoweredBorder.h>
#include "VGUI_Scroll... |
/*
** Copyright 2009 <NAME>, <EMAIL>. All rights reserved.
** Distributed under the terms of the MIT License.
*/
#include <PlainTextCatalog.h>
#include <assert.h>
#include <cstdio>
#include <iostream>
#include <fstream>
#include <memory>
#include <new>
#include <sstream>
#include <string>
#include <AppFileInfo.h>
#i... |
/*=========================================================================
Program: Visualization Toolkit
Module: vtkPBRLUTTexture.cxx
Copyright (c) <NAME>, <NAME>, <NAME>
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is distributed WIT... |
/*
* ______ ______ ______ ______ __ __ ______ ______ ______
* /\ ___\/\ ___\ /\ __ \ /\__ _\/\ \_\ \ /\ ___\ /\ __ \ /\ ___\
* \ \ __\\ \ _\ \ \ __ \\/_/\ \/\ \ __ \\ \ __\ \ \ __/ \ \___ \
* \ \_\ \ \_____\\ \_\ \_\ \ \_\ \ \_\ \_\\ \_____\\ \_\ \_\\/\_____\
* \/_/ \/___... |
#include <bits/stdc++.h>
template <bool keep_roots = true>
struct UnionFind {
int n;
mutable std::vector<int> parent; // positive: parent, negative: size
std::set<int> roots_;
explicit UnionFind(int sz) : n(sz), parent(sz, -1) {
if constexpr (keep_roots) {
for (int i = 0; i < sz; ++i) roots_.insert... |
#define BOOST_TEST_MODULE Qt5Core
#include "Qt5Core.hpp"
#include <boost/test/unit_test.hpp>
#include "thread.hpp"
#include "stack.hpp"
#include "algorithm.hpp"
#include "load.hpp"
#include "reference.hpp"
#include "convert/string.hpp"
#include "convert/char.hpp"
#include "convert/callable.hpp"
#include "convert/num... |
// another fine solution by misof
#include <algorithm>
#include <numeric>
#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include <queue>
#include <set>
#include <map>
#include <stack>
#include <cstdio>
#include <cstdlib>
#include <cctype>
#include <cassert>
#include <cmath>
#include <com... |
// Entry for MinorHack at September 13th at 7:00 pm UTC
// Submitted by Kikaru
//MinorHack entry for Kikaru, 9/13/08
#include <allegro.h>
#define MODE GFX_AUTODETECT_WINDOWED
#define WIDTH 640
#define HEIGHT 480
#define COLOR_DEPTH 32
#define BLACK makecol(0, 0, 0)
#define WHITE makecol(255, 255, 255)
#define LOOP_T... |
/******************************************************************************\
Copyright (c) 2005-2020, Intel 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:
1. Redistributions of source c... |
//=======================================================================
// Copyright <NAME> 2015.
// Distributed under the MIT License.
// (See accompanying file LICENSE or copy at
// http://opensource.org/licenses/MIT)
//=======================================================================
#include "PatchStabili... |
/*
Modified version of the C++ code from https://cran.r-project.org/web/packages/Ckmeans.1d.dp/index.html
*/
#include <vector>
#include <algorithm>
#include <iostream>
#include <cassert>
#include <stack>
#include "Ckmeans.1d.dp.h"
void reduce_in_place(int imin, int imax, int istep, int q,
const... |
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
* vim: set ts=8 sts=4 et sw=4 tw=99:
* 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/. */
... |
// Copyright 2020 <NAME>
#include <mpi.h>
#include <time.h>
#include <random>
#include <vector>
#include <algorithm>
#include <unordered_set>
#include "../../modules/task_3/aleksandrychev_a_comp_lab/comp_lab.h"
// Fifth commit
std::vector<uint32_t> getRandomBinaryImage(int height, int width) {
if (height < 1 || ... |
/*
* Copyright (c) 2021, NVIDIA CORPORATION.
*
* 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 ... |
/*
* Copyright 2019 SiFive, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You should have received a copy of LICENSE.Apache2 along with
* this software. If not, you may obtain a copy at
*
* https://www.apache.org/... |
/*
Reference:
https://github.com/serpheroth/k-means
*/
#include "kmeans.h"
bool ReadTestFile(feature_list* pRecordList)
{
FILE *pInFile;
int iTestCount;
char szBuf[MAX_BUF_SIZE];
feature* pRecord;
string strTemp;
char szSeps[] = ",\r\n";
cout<<"Start reading records from test file!"<<endl;
outfile<<"Start ... |
#include "demodulate.hpp"
#include "digital_pll.hpp"
#include "hdlc.hpp"
#include "nrzi.hpp"
#include <iostream>
const ap_int<13> bpf_coeffs[] =
{ 0, 0, 0, 0, 0, 0, 1, 3, 5, 8, 8, 5,
-2, -13, -27, -40, -46, -44, -32, -12, 11, 32, 44, 44,
... |
/*
* Copyright (c) 2005, <NAME> and IFS Institute for Software at HSR Rapperswil, Switzerland
* Copyright (c) 2015, <NAME>, Faculty of Computer Science,
* University of Applied Sciences Rapperswil (HSR),
* 8640 Rapperswil, Switzerland
* All rights reserved.
*
* This library/application is free software; you can ... |
// -*- C++ -*-
//
// Package: DTTFMasksOnlineProd
// Class: DTTFMasksOnlineProd
//
/**\class DTTFMasksOnlineProd DTTFMasksOnlineProd.h L1TriggerConfig/DTTrackFinder/src/DTTFMasksOnlineProd.cc
Description: <one line class summary>
Implementation:
<Notes on implementation>
*/
//
// Original Author: <NA... |
#include <stdio.h>
#include "DynamsoftBarcodeReader.h"
#include "BarcodeReaderConfig.h"
#include <iostream>
#include <fstream>
#include <thread>
using namespace std;
using namespace dynamsoft::dbr;
#if defined(LINUX) || defined(MACOS)
#include <sys/time.h>
int gettime()
{
struct timeval time;
gettimeofday(&time... |
//
// Amiga.cpp
// Clock Signal
//
// Created by <NAME> on 16/07/2021.
// Copyright © 2021 <NAME>. All rights reserved.
//
#include "Amiga.hpp"
#include "../../Activity/Source.hpp"
#include "../MachineTypes.hpp"
#include "../../Processors/68000/68000.hpp"
#include "../../Analyser/Static/Amiga/Target.hpp"
#incl... |
/*************************************************************************
* *
* Open Dynamics Engine, Copyright (C) 2001,2002 <NAME>. *
* All rights reserved. Email: <EMAIL> Web: www.q12.org *
* ... |
/**
* Definition of equations relating to the electric field.
*
* Note that we define the electric field as
*
* <E*B>
* -----------
* sqrt(<B^2>)
*
* in DREAM, where 'E' denotes the local electric field, 'B' the
* local magnetic field and '<X>' denotes the flux-surface average
* of a quantity 'X'.
... |
// Copyright (C) 2007 <NAME> <first dot last at mech dot kuleuven dot be>
//
// 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, or
// (at your option) any later ... |
#include <iostream>
#include <graphics.h>
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#define MAX 150
#define SONSUZ 1e18
typedef struct Nokta {
double x;
double y;
} Nokta;
typedef struct Cember {
Nokta n;
double r;
} Cember;
// kapsayan en küçük çember
Cember mec = {{0,0},SONSUZ}... |
/* MIT License
#
# Copyright (c) 2020-2021 <NAME> All Rights Reserved.
# Distributed under the terms of the MIT License.
#
# */
#include <iostream>
#include <string>
#include <sstream>
#include <vector>
#include "../include/Kalem_Structure.hpp"
#include "../include/Kalem_Codegen.hpp"
#include "../include/libs/Strin... |
/*
* Copyright 2010-2011 ZXing 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 a... |
#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 "syscall.h"
#include "platform/common/options.h"
#include "gdb-mc/gdb_server.h"
#include "gdb-mc/gdb_runner.h"
#include "htif.h"
#includ... |
/* Template Author:<NAME>
Notes:
Created for the IMT2531 Graphics Exam 2015
To get the naming right I have set.
Project-> Properties -> Configuration properties -> General -> Target name = exam2016.exe
Project-> Properties -> Configuration properties -> Debugging -> Commande Arguments = level01.dat
I suggest you rea... |
/* @uthor <NAME>
roll no 2019201039
Assignment 2 Question 3
*/
#include<bits/stdc++.h>
using namespace std;
static int counter=0;
typedef struct _avl {
int count_nodes;
int height;
int data;
struct _avl* leftPtr;
struct _avl* rightPtr;
} tree;
tree* rr(tree* root);
tree* ll(tree* root);... |
#include <iostream>
#include <stdlib.h>
#include <algorithm>
#include <queue>
#include <vector>
#include <cmath>
#include <fstream>
#include <iterator>
#include <stack>
#define vect vector
#define add push_back
using namespace std;
int dim = 0, num = 0;
vect<pair<int, vect<double> > > points; // pair with int is ... |
#include <cstdio>
#include <algorithm>
using namespace std;
int random() {
static int base = 123456789;
return base += (base << 2) + 1;
}
class PersistantTreap {
private:
struct Node {
int v, delta, rev, size, minx, w;
Node *l, *r;
void up() {
minx = v;
size = 1;
if(l) size += l->size, minx = min(... |
/*
* This file belongs to the Galois project, a C++ library for exploiting
* parallelism. The code is being released under the terms of the 3-Clause BSD
* License (a copy is located in LICENSE.txt at the top-level directory).
*
* Copyright (C) 2018, The University of Texas at Austin. All rights reserved.
* UNIVER... |
/* Copyright 2018 Stanford University
* Copyright 2018 Los Alamos National Laboratory
*
* 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.... |
#pragma once
#include "Scheduler.h"
#include <assert.h>
#include <chrono>
#include "Console.h"
#include <algorithm>
#define NOMINMAX
#include <windows.h>
Scheduler* Scheduler::s_Instance = nullptr;
Scheduler::Scheduler()
{
print("Detecting hardware threads...\n");
const int hardwareThreads = std::thread::hard... |
#include <iostream>
#include <fstream>
#include <sstream>
#include <sys/stat.h>
#include "SunSpecModbus.h"
SunSpecModbus::SunSpecModbus (
const unsigned int did,
const unsigned long int key,
const char* ip,
const unsigned int port
) : sunspec_key_(key)
{
context_ptr_ = m... |
/*
* ofxBlobTracker.cpp
* ofxBlobTrackerExample
*
* Created by <NAME> on 31/01/2011.
*
*/
#include "ofxBlobTracker.h"
ofxBlobTracker::ofxBlobTracker() {
for (int i=0;i<MAX_NUM_BLOBS*2;i++) {
tuioPointSmoothed[i] = NULL;
}
bVerbose = false;
smoothing = 0;
lastId = 0;
minTrackDistance = 0.2;
}
void of... |
#include "BME280.h"
bool BME280::begin(uint8_t comms_mode, uint8_t address_or_cs) {
_comms_mode = comms_mode;
if (comms_mode == BME280_I2C_MODE) set_address(address_or_cs);
if (comms_mode == BME280_SPI_MODE) _chip_select_pin = address_or_cs;
bool success = comms_check();
if (success) load_calibrat... |
#include <cmath>
#include <Poco/Logger.h>
#include <Poco/NumberParser.h>
#include <Poco/SAX/Attributes.h>
#include "util/TypesSAXHandler.h"
using namespace std;
using namespace Poco;
using namespace Poco::XML;
using namespace BeeeOn;
TypesSAXHandler::TypesSAXHandler()
{
m_typeExpect.insert("unit");
m_typeExpect.i... |
#include <Maestro.H>
#include <Maestro_F.H>
#include <AMReX_VisMF.H>
#include <Problem_F.H>
using namespace amrex;
// initialize AMR data
// perform initial projection
// perform divu iters
// perform initial (pressure) iterations
void
Maestro::Init ()
{
// timer for profiling
BL_PROFILE_VAR("Maestro::Init()",Init... |
/* *****************************************************************************
Copyright (c) 2016-2017, The Regents of the University of California (Regents).
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions ar... |
/**************************************************************
*
* 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 y... |
#include "dmzApplicationiPhone.h"
#include "dmzApplicationStateBasic.h"
#include <dmzFileCacheLocal.h>
#include <dmzRuntime.h>
#include <dmzRuntimeConfig.h>
#include <dmzRuntimeConfigToTypesBase.h>
#include <dmzRuntimeExit.h>
#include <dmzRuntimeInit.h>
#include <dmzRuntimeLog.h>
#include <dmzRuntimePluginContainer.h>
... |
/*The MIT License
Copyright (c) 2020 <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, merge, publi... |
// Copyright (C) 2019. Huawei Technologies Co., Ltd. All rights reserved.
// 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,... |
#include "ldb.hpp"
using glim::Ldb;
using glim::gstring;
#include <iostream>
using std::cout; using std::flush; using std::endl;
#include <assert.h>
#include <boost/filesystem.hpp>
void test1 (Ldb& ldb) {
ldb.put (std::string ("foo_"), std::string ("bar"));
ldb.put ((uint32_t) 123, 1);
ldb.put ((uint32_t) 123, 2... |
#include "types.h"
/*
Generated from dpostproc
.section .sbss # 0x80514D80 - 0x80516360
.global deadObjectFreePointer__Q27JAInter14DummyObjectMgr
deadObjectFreePointer__Q27JAInter14DummyObjectMgr:
.skip 0x4
.global deadObjectUsedPointer__Q27JAInter14DummyObjectMgr
deadObjectUsedPointer... |
#include "Grid.hpp"
Grid::Grid(const COORDTYPE width, const COORDTYPE height) {
this->width = width;
this->height = height;
this->aliveSnakes = 0;
this->cells.resize(this->getWidth() * this->getHeight());
std::srand(std::time(nullptr));
this->hashes.resize(this->width * this->height);
this->snakesHashe... |
#include "alfe/main.h"
#include "alfe/bitmap.h"
#include "alfe/avi.h"
int sampleFromIRE(float IRE) { return static_cast<int>(IRE * 1.4 + 60.49999); }
float sinewave(int sample, float yIRE, float cIRE, float phase_degrees)
{
return yIRE + cIRE * static_cast<float>(
sin(((sample & 3) + (phase_degrees + 147)... |
#include <map>
#include <cmath>
#include <ctime>
#include <string>
#include <iostream>
#include <glpk.h>
#include <stdio.h>
#include <stdlib.h>
#include <sstream>
#include <fstream>
#include <vector>
#include <algorithm>
#include <gsl/gsl_vector.h>
#include <gsl/gsl_statistics.h>
#include "func.h"
using namespace std;... |
/*
* \file ocsd_error.cpp
* \brief OpenCSD : Library error class.
*
* \copyright Copyright (c) 2015, ARM Limited. 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... |
#include <stdio.h>
#include <iostream>
#include <sigcx/thread.h>
#include <sigcx/thread_tunnel.h>
#include <sigcx/gtk_dispatch.h>
#include <sigc++/class_slot.h>
#include <sigc++/bind_return.h>
#include <assert.h>
#include <gtkmm.h>
using namespace SigC;
using namespace SigCX;
using namespace SigCX::Threads;
#incl... |
#include "L1Trigger/CSCTriggerPrimitives/interface/CSCALCTCrossCLCT.h"
#include "DataFormats/CSCDigi/interface/CSCConstants.h"
#include "DataFormats/CSCDigi/interface/CSCALCTDigi.h"
#include "DataFormats/CSCDigi/interface/CSCCLCTDigi.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
namespace {
// LUTs t... |
/*
* The code is part of our project called DrTM, which leverages HTM and RDMA for speedy distributed
* in-memory transactions.
*
*
* Copyright (C) 2015 Institute of Parallel and Distributed Systems (IPADS), Shanghai Jiao Tong University
* All rights reserved.
*
* Licensed under the Apache License, Versi... |
/*!
* @file DFRobot_MLX90614.cpp
* @brief DFRobot_MLX90614.cpp Initialize the IIC,
* @n get the celsius temperature and fahrenheit temperature values,get the register values.
* @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com)
* @license The MIT License (MIT)
* @author [qsjhyy](<EMAI... |
/* Copyright 2011 <NAME>, All Rights Reserved.
* dirkx(at)webweaving(dot)org
*
* 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/lic... |
/*
Copyright 2015 <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... |
#pragma once
#include "problem.hh"
#include "parsing.hh"
#include "util.hh"
#include <queue>
#include <map>
#include <optional>
using Value = Number;
using Factor = Number;
using CoeffcientQ = NumberQ;
using SymbolMap = std::unordered_map<Clingo::Symbol, index_t>;
using SymbolVec = std::vector<Clingo::Symbol>;
stru... |
#include<ros/ros.h>
#include<iostream>
#include<cv_bridge/cv_bridge.h>
#include<sensor_msgs/image_encodings.h>
#include<image_transport/image_transport.h>
#include<opencv2/core/core.hpp>
#include<opencv2/highgui/highgui.hpp>
#include<opencv2/imgproc/imgproc.hpp>
#include<opencv2/opencv.hpp>
#include"strategy/detector.h... |
#include <sstream>
#include <fstream>
#include <matio.h>
#include <iomanip>
#include "KnowledgeGraph.h"
#include "MetaPath.h"
#include "LogisticRegression.h"
void save_mat(const char* output_file, const char* var, const Eigen::SparseMatrix<double, Eigen::ColMajor>& matrix){
assert(matrix.IsRowMajor == 0);
assert(matr... |
//========= Copyright Valve Corporation, All rights reserved. ============//
// ghost.cpp
// A spooky halloween ghost bot
// <NAME>, October 2011
#include "cbase.h"
#include "tf_player.h"
#include "tf_gamerules.h"
#include "tf_team.h"
#include "tf_projectile_arrow.h"
#include "tf_weapon_grenade_pipebomb.h"
#include "... |
//
// Created by <NAME> on 2019-09-17.
//
#include "VarAnalysis.h"
std::optional<GlobalVariable> handleGlobalVariables(const Token &varToken, const std::vector<PackageSpan> &packages) {
if (!(varToken.type == TokenType::ScalarVariable || varToken.type == TokenType::HashVariable ||
varToken.type == Toke... |
// #include "Math/GenVector/Rotation3D.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "FWCore/Utilities/interface/Parse.h"
#include "Alignment/CommonAlignment/interface/Utilities.h"
align::EulerAngles align::toAngles(const RotationType& rot)
{
const Scalar one = 1; // to ensure same preciso... |
//
// Created by Axel on 2018-11-27.
//
#include <fstream>
#include <sstream>
#include <functional>
#include "OpenCL_Wrapper.h"
OpenCL_Wrapper::OpenCL_Wrapper(std::string deviceToUse) {
// Find the right device
int err;
size_t valueSize;
cl_uint platformCount;
cl_platform_id *platforms;
cl_u... |
#include "GAMER.h"
#include "TestProb.h"
static void BC( real fluid[], const double x, const double y, const double z, const double Time,
const int lv, double AuxArray[] );
static void Init_ExtPot();
// problem-specific global variables
// ============================================================... |
/*****************************************************************/
/* NAME: <NAME> */
/* ORGN: Dept of Mechanical Eng / CSAIL, MIT Cambridge MA */
/* FILE: VehicleSet.cpp */
/* DATE: Aug 12th 2008 ... |
#include "core/auto.h"
#include "core/bits_util.h"
#include "core/range.h"
#include "sokoban/common.h"
#include "sokoban/solver.h"
#include "sokoban/corrals.h"
#include "sokoban/frozen.h"
#include "sokoban/deadlock.h"
#include "sokoban/util.h"
#include "sokoban/level_loader.h"
#include "sokoban/level_printer.h"
using... |
/*
Copyright (C) 2012 <NAME> <<EMAIL>>
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
version 2 as published by the Free Software Foundation.
Ported to STM32F103 by <NAME> on 21 May 2015
Home: http://www.serasidis.gr
email: <EMAIL>... |
/*
* 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 "ppgFilter.h"
#include "utils.h"
void Filter::calc(){
arma::vec x(windowSize, arma::fill::zeros); // Input sig
arma::vec y(windowSize, arma::fill::zeros); // Output sig
arma::vec xCen(windowSize, arma::fill::zeros); // intermediate sig
arma::vec yFilt(windowSize, arma::fill::zeros); ... |
#include "convolve.hpp"
#include <assert.h>
#include <vector>
#include <iostream>
#include <fftw3.h>
deconvolution::Array<2> convolve(const deconvolution::Array<2>& im, const deconvolution::Array<2>& ker) {
// Make sure that (0,0) contained in kernel, otherwise things get wonky
assert(ker.index_bases()[0] <= ... |
#include <SFML/Audio.hpp>
#include <SFML/Graphics.hpp>
#include <SFML/System.hpp>
#include <iostream>
#include <fstream>
#include <stdlib.h>
#include <math.h>
#include <list>
#include "matrix.hpp"
#include "AutoFill.hpp"
#include "ResourcePath.hpp"
#define WHITE sf::Color::White
#define BLACK sf::Color::Black
#define... |
#include "../dungeon/RogueMapViewer.h"
RogueMapViewer::RogueMapViewer(GameWindow* gameWindow) :
mMenu(0),
mRogueMap(0),
dungeon(0)
{
mGameWindow = gameWindow;
mLeftMouseButtonClicked = false;
}
RogueMapViewer::~RogueMapViewer() {
if (mMenu != 0) {
delete mMenu;
}
if (mRogueMap != 0) {
delete m... |
#pragma once
#include <functional>
#include <map>
#include "data_types.hpp"
#include "lib/consolelog.hpp"
#include "fixed_point.hpp"
std::map<std::string, std::pair<real, real>> rec;
#define record(x) {rec[#x].first=min(rec[#x].first,(x));rec[#x].second=max(rec[#x].second,(x));}
Vertex perVertex(mat4 in_view, Verte... |
// Copyright (c) 2009-2010 <NAME>
// Copyright (c) 2009-2014 The Bitcoin developers
// Copyright (c) 2015-2017 The PIVX Developers
// Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "pow.h"
#include "chain.h"
#include... |
//-------------------------------------------------------------------
// Copyright 2020 <NAME>
// SPDX-License-Identifier: Apache-2.0
//-------------------------------------------------------------------
#include "circuitGroup.h"
#include "dotPrint.h"
#include "signatureConstants.h"
#include "groupEquality.h"
#include... |
//
// Created by mvr on 05.01.22.
//
#include "lmots.h"
//LMOTS Algorithm Types according to Table 1 in RFC 8554
const LMOTS_ALGORITHM_TYPE LMOTS_SHA256_N32_W1 = {std::string("\000\000\000\001",4), 1, 265, 7};
const LMOTS_ALGORITHM_TYPE LMOTS_SHA256_N32_W2 = {std::string("\000\000\000\002",4), 2, 133, 6};
const LMOTS_... |
//
// plymerge.cc -- <NAME> (<EMAIL>), 8/17/98
//
// This program takes a list of .ply files, and outputs to stdout
// a .ply file representing the merged geometry. Note that only
// vertex x,y,z and face connectivity information is preserved;
// other attributes are dropped.
//
// Redundant/shared vertices and... |
#include "app.h"
#include "util.h"
#include <thread>
#include <chrono>
#include <ppl.h>
#include <atlbase.h>
// Constructor
Kinect::Kinect()
{
// Initialize
initialize();
}
// Destructor
Kinect::~Kinect()
{
// Finalize
finalize();
}
// Processing
void Kinect::run()
{
// Main Loop
while( tru... |
/***********************************************************************
* Copyright 1998-2020 CERN for the benefit of the EvtGen authors *
* *
* This file is part of EvtGen. *
* ... |
/* XMRig
* Copyright 2012-2013 The Cryptonote developers
* Copyright 2014-2021 The Monero Project
* Copyright 2018-2021 SChernykh <https://github.com/SChernykh>
* Copyright 2016-2021 XMRig <https://github.com/xmrig>, <<EMAIL>>
*
* This program is free software: you can redistribute it and/or modify
* ... |
/****************************************************************************
* *
* *
* Copyright (C) 2002 by <NAME> *
* ... |
/******************************************************************************
*
* SoundStretch main routine.
*
* Author : Copyright (c) <NAME>
* Author e-mail : o<EMAIL>
* File created : 13-Jan-2002
*
* Last changed : $Date: 2003/12/27 11:59:22 $
* File revision : $Revision: 1.16 $
*
* ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.