text
stringlengths
3.08k
12.5k
#include <iostream> #include <opencv2/opencv.hpp> #include <opencv2/highgui.hpp> #include<string> #include<vector> #include <opencv2/features2d/features2d.hpp> #include<math.h> #include "dct.h" // #include <opencv2/nonfree/nonfree.hpp> using namespace std; using namespace cv; double getPSNR(const Mat& I1, const Mat& ...
#include <cstdio> #include <cstring> #include <fstream> #include <GLES2/gl2.h> #include <GLES2/gl2ext.h> #include "image.hpp" #include "image_io.hpp" #include "image_compression.hpp" namespace { const unsigned char ASTC_FORMAT_NUM = COMPRESSED_ASTC_RGBA_12x12_OES - COMPRESSED_ASTC_RGBA_4x4_OES + 1; const unsigned ch...
#include <iostream> #include <windows.h> #include "resource1.h" #include "tlhelp32.h" #include "tchar.h" #include "wchar.h" struct Resource { size_t size = 0; void* ptr = nullptr; }; Resource GetDllResource() { int resource_id = IDR_RCDATA1; HRSRC hResource = nullptr; HGLOBAL hMemory = nullptr; Resource r; hR...
/* Copyright (c) 1999 - 2010, Vodafone Group Services Ltd All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of condit...
/********************************************************************************************************* * Copyright (c) 2020 WEI.ZHOU. All rights reserved. * The following code is only used for learning and communication, not for illegal and commercial use. *...
#include <iostream> #include <string> #include <vector> #include <regex> #include <optional> #include <boost/multiprecision/cpp_int.hpp> using boost::multiprecision::int128_t; struct Cube { Cube(int128_t x1, int128_t x2, int128_t y1, int128_t y2, int128_t z1, int128_t z2) : x1(x1), x2(x2), y1(y1), y2(y2)...
/* * Copyright 2010 by <NAME> <<EMAIL>> * * 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 3 of the License, or * (at your option) any later version. * * This program is d...
/***************************** Copyright 2011 <NAME>. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of cond...
#include <numeric> #include <algorithm> #include <assert.h> #include "interpolator_base.h" template<typename index_t, int N_DIMS, int N_OPS> InterpolatorBase<index_t, N_DIMS, N_OPS>::InterpolatorBase( operator_set_evaluator_iface *supporting_point_evaluator, const std::array<int, N_DIMS> &axes_points, ...
#include "Material.hpp" #include "Sampling.hpp" using namespace Lykta; MaterialParameters SurfaceMaterial::evalMaterialParameters(const glm::vec2& uv) const { MaterialParameters params; if (diffuseTexture) params.diffuseColor = diffuseTexture->eval(uv); else params.diffuseColor = diffuseColor; if (s...
#include <curses.h> #include <chrono> #include <string> #include <thread> #include <vector> #include "format.h" #include "ncurses_display.h" #include "system.h" #include <thread> #include <future> #include <algorithm> #include <memory> #include <mutex> #include <iostream> using std::string; using std::to_string; std...
#include "Prefab.h" #include "SceneGraph.h" #include "Model.h" #include "Common/GameData/trick_serializers.h" #include "Common/GameData/GameDataStore.h" #include "Common/GameData/scenegraph_serializers.h" //for getFilepathCaseInsensitive #include <QFile> #include <QDebug> #include <QDir> namespace SEGS { struct GeoS...
/** * Copyright 2014 Social Robotics Lab, University of Freiburg * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * # Redistributions of source code must retain the above copyright * notice, this list of condi...
#include "pch.h" #include "App_Window_Base.h" HWND App::Window::Base::InternalCreateWindow(const WNDCLASSEXW& wndclassex, LPCWSTR lpWindowName, DWORD dwStyle, DWORD dwExStyle, int X, int Y, int nWidth, int nHeight, HWND hWndParent, HMENU hMenu, Base* pBase) { WNDCLASSEXW c = wndclassex; if (c.lpfnWndProc) throw st...
/*! * Copyright (C) tkornuta, IBM Corporation 2015-2019 * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by app...
#include "include/vec.h" #include "sphere.h" #include <stdlib.h> #include <math.h> /********************************************************************** * This function intersects a ray with a given sphere 'sph'. You should * use the parametric representation of a line and do the intersection. * The function shou...
#include <iostream> #include <vector> #include "stdlib.h" #include "string.h" //memset //#include "mkl.h" #include "cblas.h" //extern "C" void dgemm_( char *, char *, int *, int *, int *, double *, double *, int *, double *, int *, double *, double *, int * ); void random_data(std::vector<double>& array, int n) { ...
#include "Actions/Action.h" #include "Analyzers/Analyzer.h" #include "Actions/Answer.h" #include "Actions/Apply.h" #include "Actions/ApplyInDirection.h" #include "Actions/Call.h" #include "Actions/Charge.h" #include "Actions/CallMonster.h" #include "Actions/Donate.h" #include "Actions/Dip.h" #include "Actions/Drop.h" ...
#include "sim.hpp" #include "libpopcnt.h" #include <pybind11/numpy.h> #include <pybind11/pybind11.h> #include <stdexcept> namespace py = pybind11; uint64_t py_popcount(py::array_t<uint64_t> pyquery) { auto query = pyquery.unchecked<1>(); uint64_t qcount = 0; for (ssize_t i = 0; i < query.shape(0); i++) qcou...
#include "Agency.h" #include "Car.h" #include "Sensor.h" #include "proj4.h" size_t myStringLength(const char *str) { size_t i; for (i = 0; *(str + i) != 0; i++) { } return i; } int myStringCompare(const char *str1, const char *str2) { for (int i = 0;; i++) { char str1Val = *(str1 + i); char str2Val...
/* Copyright (c) 2020, Oracle and/or its affiliates. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2.0, as published by the Free Software Foundation. This program is also distributed with certain software (including but n...
#include <Physics.h> #include "TileGrid.h" #include "CollisionDetector.h" #include <Particle.h> #include <Vector.h> #include <RigidBody.h> constexpr int gravity8_y = 6; // acceleration per frame constexpr int max_falling_speed8 = 80; constexpr int max_collision_detection_iterations = 2; // checks if particle is hit,...
/** \file CartPole.cc Implements the Cart-Pole balancing domain, with possible noise. \author <NAME> */ #include <rl_env/CartPole.hh> CartPole::CartPole(Random &rand): noisy(false), rng(rand), s(4), cartPos(s[0]), cartVel(s[1]), poleAngle(s[2]), poleVel(s[3]) { reset(); //cout << *this << ...
//------------------------------------------------------------------------------ // // Copyright 2018-2019 Fetch.AI Limited // // 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 // // ...
#include <iostream> #include <PPDDLDeterminizatorFactory.h> #include "PPDDLParserInterface.h" #include "Strategies/MLODeterminizator.h" #include "Strategies/AODeterminizator.h" #include "Strategies/TLDeterminizator.h" void usage() { std::cout << "Usage: ./ppddl_determinizer <strategy> <st_parameter1> <st_parameter...
#include "event.h" #include <iostream> #include <spug/check.h> #include <spug/Exception.h> using namespace awb; using namespace spug; using namespace std; namespace { void writeVarLen(ostream &out, uint val) { // Special case 0. if (val == 0) { out << static_cast<byte>(0); ...
#include <Rcpp.h> using namespace Rcpp; // [[Rcpp::export]] NumericVector timesTwo(NumericVector x) { return x * 2; } // You can include R code blocks in C++ files processed with sourceCpp // (useful for testing and development). The R code will be automatically // run after the compilation. // /*** R # timesTw...
#include "enemies.hpp" #include <cppitertools/itertools.hpp> #include <glm/gtx/fast_trigonometry.hpp> void Enemies::initializeGL(GLuint program, int quantity) { terminateGL(); m_program = program; m_colorLoc = glGetUniformLocation(m_program, "color"); m_scaleLoc = glGetUniformLocation(m_program, "s...
#include<bits/stdc++.h> using namespace std; #define pb push_back #define mkp make_pair #define fi first #define se second #define ll long long #define M 998244353 #define all(a) a.begin(), a.end() const int MAXN = 5010; int res; int B = 10000; struct bign{ int len, s[MAXN / 4 + 2]; bign(){ len = 1; ...
/*--------------------------------------------------------------------------------- Copyright (C) 2007 Acekard, www.acekard.com 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 restrictio...
/* Transform a point cloud from camera to checkerboard (Zivid Calibration Board) coordinate frame by getting checkerboard pose from the API. The ZDF file for this sample can be found under the main instructions for Zivid samples. */ #include <Zivid/Experimental/Calibration.h> #include <Zivid/Zivid.h> #include <openc...
//<NAME> //EE1301 //17 April 2019 //HW 6A: Dice Class #include <iostream> #include <cstdlib> using namespace std; const int maxNumDie=50; int* userInputParser(string s); class Dice { private: int min; int max; public: int roll() { return rand() % (max-min+1) + min; }; Dice() { //Def...
#include <GL/glew.h> #include "gui/OpenGLSceneWidget.h" #include "globals/Command.h" #include "globals/Config.h" #include "control/State.h" void OpenGLSceneWidget::drawFloor() const { float size = 2.0*radius; float stride = 1.0; glBegin( GL_QUADS ); glColor3f(0.95, 0.95, 0.95); glVertex3f(-size, -s...
/* * 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,...
//============================================================================= /** * @file bd_struct_seq.cpp * * $Id: bd_struct_seq.cpp 93650 2011-03-28 08:44:53Z johnnyw $ * * tests bounded struct sequences * * * @author <NAME> */ //==================================================================...
#include "UKF.h" UKF::UKF(uint8_t n) { // initialisation of the instance this->state = VectorXf{ n }; this->cov = MatrixXf{ n, n }; this->n = n; this->n_aug = n + 2; this->m = 2 * this->n_aug + 1; // Weights of sigma points this->lambda = 3 - static_cast<float>(this->n_au...
#include <stdio.h> #include <string.h> #include <map> #include <unistd.h> #include <signal.h> #include <sys/shm.h> #include <string> #include <iostream> #include <iomanip> #include <fstream> #include <algorithm> #include <SimpleIni.h> #include <wiringPi.h> #include "Singleton.h" using namespace std; enum Command {cmd...
#include <fstream> #include <iostream> #include <vector> using namespace std; struct Para { int kv; int dp; Para(int k = 0,int d = -1):kv(k),dp(d) {} Para(Para* mm):kv(mm->kv),dp(mm->dp) {} }; class KNode { public: int info; KNode* left; KNode* right; public: KNode(int inf = 0, KNode* l = ...
/* * Copyright (c) 2013-2016, ARM Limited, All Rights Reserved * SPDX-License-Identifier: Apache-2.0 * * 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...
#include "generator_v4.hpp" #include <math.h> #include <fstream> #include <iomanip> #include <iostream> #include <sstream> #include "file.hpp" #include "generator.hpp" #include "generator_v1.hpp" #include "parser.hpp" #include "program_util.hpp" #include "setup.hpp" #include "util.hpp" ProgramState::ProgramState() ...
// Copyright (c) 2012 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 "remoting/base/plugin_thread_task_runner.h" #include "base/bind.h" namespace { base::TimeDelta CalcTimeDelta(base::TimeTicks when) { ret...
// ybmj #include <bits/stdc++.h> using namespace std; #define lson (rt << 1) #define rson (rt << 1 | 1) #define lson_len (len - (len >> 1)) #define rson_len (len >> 1) #define pb(x) push_back(x) #define clr(a, x) memset(a, x, sizeof(a)) #define mp(x, y) make_pair(x, y) typedef long long ll; typedef pair<int, int> pii; ...
/* Filename: change (Chapter 5 Programming Project 4) Author: <NAME> Description: This is a program that tells the users what coins to give for change. The till is out of nickles and half dollars. Date last modified: 2/4/16 Algorithm: Introduce program Get amount of change t...
#include <atomic> #include <iostream> #include <algorithm> #include <pthread.h> #include <cstdint> #include <immintrin.h> #include <chrono> #include <sys/mman.h> #include <sys/types.h> #include <sys/stat.h> #include <fcntl.h> #include <iostream> #include <vector> #include <unistd.h> using namespace std; inline void C...
#include <helper_cuda.h> #include <cuda_runtime.h> #include "cuda.hpp" #include "uarch.hpp" #include "../common/pci.hpp" #include "../common/global.hpp" int print_gpus_list() { cudaError_t err = cudaSuccess; int num_gpus = -1; if ((err = cudaGetDeviceCount(&num_gpus)) != cudaSuccess) { printErr("%s: %s", c...
/********************************************************************************************** * * Raylib RPG Example * A simple RPG made using raylib * * LICENSE: zlib/libpng * * Copyright (c) 2020 <NAME> * * This software is provided "as-is", without any express or implied warranty. In no event * will the...
// __BEGIN_LICENSE__ // Copyright (c) 2006-2013, United States Government as represented by the // Administrator of the National Aeronautics and Space Administration. All // rights reserved. // // The NASA Vision Workbench is licensed under the Apache License, // Version 2.0 (the "License"); you may not use this f...
/* AutoFilter.cc Copyright 2002-18 <NAME> <<EMAIL>> http://quitte.de/dsp/ AutoFilter, a Lorenz fractal modulating the cutoff frequency of a state-variable (ladder) filter. AutoFilter, RMS envelope modulating a SVF bandpass filter. */ /* This program is free software; you can redistribute it and/or modif...
#include "cmos.hpp" TimeDriver* TimeDriver::active = 0; TimeDriver::TimeDriver() : cmos_address(0x70) , cmos_data(0x71) { active = this; } void TimeDriver::set_timezone_offset(uint16_t t_offset) { timezone_offset = t_offset; } void TimeDriver::get_full_time(char seperator, char* time) { char form...
#include <vector> #include <string.h> #include "HTTP2_FrameReassembler.h" #include "nghttp2.h" #include "nghttp2ver.h" #include "debug.h" #include "zeek/Reporter.h" using namespace analyzer::mitrecnd; using namespace std; HTTP2_FrameReassembler::HTTP2_FrameReassembler() { this->buffer = NULL; this->bufferLen ...
#include <WiFiClientSecure.h> #include <base64.h> #include <Arduino.h> #define MODULE_NAME "email_send" #include "email_send.h" #include "logger.h" #define FSTR bool read_response(WiFiClientSecure* client, char* buffer, int buffer_len, const char* endmarker, const char* exp_response, const char* log_string )...
//########################################################################## //# # //# CCLIB # //# # //# This pr...
/************************************************************************* > File Name: udp_client.cc > Author: hsz > Brief: > Created Time: Thu 24 Feb 2022 03:34:54 PM CST ************************************************************************/ #include <stdio.h> #include <assert.h> #include <string...
#include "stdafx.h" #include "input.h" #include "simulator.h" using namespace graphic; cInputView::cInputView() : framework::cDockWindow("Input") , m_timeSeconds(0) , m_incT(0) , m_ctrlPeak(0) , m_isOutVoltage(false) { } cInputView::~cInputView() { } bool cInputView::Init(graphic::cRenderer &renderer) { ret...
// // KittyMemory.cpp // // Created by MJ (Ruit) on 1/1/19. // #include <unistd.h> #include <android/log.h> #include "KittyMemory.hpp" using KittyMemory::Memory_Status; using KittyMemory::ProcMap; struct mapsCache { std::string identifier; ProcMap map; }; static std::vector<mapsCache> __mapsCache; static...
//===----------------------------------------------------------------------===// // // 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 // //===---------------------------...
/****************************************************************************** * Vulkan-Interpolator: interpolator/rasterizer based on Vulkan API * * Copyright (c) 2019-2020 <NAME> * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation f...
/* Nama : <NAME> NIM : 18050623010 Prodi : D3 Manajemen Informatika */ #include <iostream> #include <conio.h> #include <stdlib.h> using namespace std; char get[1]; int a=0,i; const string laki = "L"; const string perempuan = "P"; struct KTP { char nik[50]; char nama[50]; char ...
// // // MIT License // // Copyright (c) 2017 Stellacore Corporation. // // Permission is hereby granted, free of charge, to any person obtaining // a copy of this software and associated documentation files (the // "Software"), to deal in the Software without restriction, including // without limitation the rights to ...
#include "wiFrustum.h" #include "wiIntersectables.h" Frustum::Frustum() { } void Frustum::CleanUp() { } void Frustum::ConstructFrustum(float screenDepth, XMFLOAT4X4 projectionMatrix, const XMFLOAT4X4& viewMatrix, const XMMATRIX& world) { view=viewMatrix; float zMinimum, r; XMFLOAT4X4 matrix; // Calculate the ...
#include <string> #include <map> #include <cstdlib> #include <cmath> #include <algorithm> #include <iostream> #include <stdexcept> #include <iomanip> #include <cstring> #include "./langdetect.h" #include "./ngram_storage.h" #include "./code_sequence.h" #define LANG_FAIL_EMPTY Detected("empty", 0.0) #define MATH_PI 3....
#include "fileInfo.h" #include "strBaseUtils.h" MossbauerLab::Utils::Windows::FileSearchResult::FileSearchResult(bool result, TCHAR* fileName, TCHAR* filePath) :_result(result) { if (result && filePath != NULL && fileName != NULL) { int filePathLength = _tcslen(filePath) + 1; // _tcslen count with...
#include <bits/stdc++.h> #define all(x) (x).begin(), (x).end() #define gc getchar() #define pc(x) putchar(x) template<typename T> void scan(T &x){x = 0;bool _=0;T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;} template<typename T> void print...
#include "ros_node.h" #include <sensor_msgs/NavSatFix.h> #include <sensor_msgs/NavSatStatus.h> #include <sensor_msgs/TimeReference.h> // CONSTRUCTORS ros_node::ros_node(int argc, char **argv) { // Initialize the ROS node. ros::init(argc, argv, "driver_mpu9250"); // Get the node's handle. ros_node::m_...
/** * \file WdbeMtpWrfpgaCmdret_v1_0.cpp * Wdbe operation processor - (implementation) * \copyright (C) 2016-2020 MPSI Technologies GmbH * \author <NAME> (auto-generation) * \date created: 28 Nov 2020 */ // IP header --- ABOVE #ifdef WDBECMBD #include <Wdbecmbd.h> #else #include <Wdbeopd.h> #endif #include ...
#include <Windows.h> #include <Psapi.h> #include <strsafe.h> #include <iostream> #include <stdio.h> #include <conio.h> #include <thread> #include <vector> #include <string> #include <algorithm> // Inject a DLL into the target process by creating a new thread at LoadLibrary // Waits for injected thread to...
/* * MIT License * Copyright (c) 2019 <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, merg...
/** * MOAB, a Mesh-Oriented datABase, is a software component for creating, * storing and accessing finite element mesh data. * * Copyright 2004 Sandia Corporation. Under the terms of Contract * DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government * retains certain rights in this software. * * This...
// Copyright (c) 2019 University of Paderborn // (<NAME> <<EMAIL>>, // <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 t...
#pragma once inline Network::Network() {} inline Network::Network(std::initializer_list<Dense*> layers) : layers(layers) {} inline void Network::append(Dense *layer) { layers.push_back(layer); } inline Mat<float> Network::evaluate(const Mat<float> &inputBatch) { Mat<float> result = inputBatch; for (size_t i = 0;...
/* * testlogreg.cc * * Created on: Sep 14, 2012 * Author: reid */ #include "../CuMatrix.h" #include "../util.h" #include "../LinearRegression.h" #include "tests.h" template int testLinRegCostFunctionNoReg<float>::operator()(int argc, const char **argv) const; template int testLinRegCostFunctionNoReg<doubl...
/* * Copyright (C) 2015 Samsung Electronics Co., Ltd All Rights Reserved * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License version 2.1 as published by the Free Software Foundation. * * This library is distributed in the h...
#include "../../head.h" class Solution { public: int minChanges(std::vector<int> const & nums, int k) { // plagiarizing from https://leetcode.com/problems/make-the-xor-of-all-segments-equal-to-zero/discuss/1097537/Explanation-of-DP-Approach-%2B-Code-(C%2B%2B) // I can analysis that the cycle perio...
#include <iostream> #include <fstream> #include <ctype.h> #include "parser.h" #include "data_structures.h" #include "solver.h" std::ostream &operator<<(std::ostream &out, const list *obj) { switch (obj->type) { case NODE: out << *(obj->content.name); break; case LIST: out << "("; ...
#include <stdio.h> #include <assert.h> #include <string.h> #include "PCSTree.h" #include "PCSNode.h" // constructor PCSTree::PCSTree() : root(0) { this->info.numNodes = 0; this->info.maxNodeCount = 0; this->info.numLevels = 0; this->info.maxLevelCount = 0; // printf("PCSTree: constructor()\n"); }; ...
/******************************************************************************* * This file is part of the "Enduro2D" * For conditions of distribution and use, see copyright notice in LICENSE.md * Copyright (C) 2018-2020, by <NAME> (<EMAIL>) *************************************************************************...
/* * TreeCollider.cpp * * Created on: 28-10-2008 * Author: jimali */ #include "TreeDistanceCalc.hpp" #include <rw/core/Ptr.hpp> #include <rw/math/Transform3D.hpp> using namespace rw::math; using namespace rw::geometry; using namespace rw::proximity; using namespace rw::common; //#define RW_DEBUG( str ) s...
/* ------------------------------------------------------------------------------- Copyright (c) <NAME>. This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to a...
/**************************************************************************** Copyright (c) 2012-2013 cocos2d-x.org http://www.cocos2d-x.org 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...
// // ConstraintPenetration.cpp // #include "ConstraintPenetration.h" /* ================================ ConstraintPenetration::PreSolve ================================ */ void ConstraintPenetration::PreSolve( const float dt_sec ) { // Get the world space position from the hinge from A's orientation const Vec3 wo...
//! [mandelbrot-all] #include <chrono> #include <iostream> #include <numeric> #include <vector> #include <boost/simd/memory/allocator.hpp> #include <boost/simd/pack.hpp> #include <boost/simd/function/aligned_load.hpp> #include <boost/simd/function/aligned_store.hpp> #include <boost/simd/function/enumerate.hpp> #inclu...
// Copyright 2022 <NAME> #include <tbb/tbb.h> #include <vector> #include <random> #include <iostream> #include "../../../modules/task_3/zotov_m_sort_with_batcher_merge/sort_with_batcher_merge.h" const int MAX = 30000; std::vector<int> getRandomVector(int size) { std::mt19937 generate; generate.seed(time(0)); ...
#include "test_main.h" void run_main_test() { cout<< "Running Default Tests..."<<endl; cout<<"Test 1: "<<endl; run_farm_with_input("0 292 399 307", 400, 600, "116800 116800"); cout<<endl; cout<<"Test 2: "<<endl; run_farm_with_input("48 192 351 207, 48 392 351 407, 120 52 135 547, 260 52 275 5...
// ROS includes. #include "ros/ros.h" #include "ros/time.h" #include <message_filters/subscriber.h> #include <message_filters/synchronizer.h> #include <message_filters/sync_policies/approximate_time.h> #include <image_transport/image_transport.h> #include <image_transport/subscriber_filter.h> #include <sensor_msgs/Cam...
// 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 3 of the License, or // (at your option) any later version. // // This program is distributed in the hope that it will b...
// __BEGIN_LICENSE__ // Copyright (c) 2009-2013, United States Government as represented by the // Administrator of the National Aeronautics and Space Administration. All // rights reserved. // // The NGT platform is licensed under the Apache License, Version 2.0 (the // "License"); you may not use this file excep...
// featbin/multiply-vectors.cc // Copyright 2020 <NAME> (STC-innovations Ltd) // See ../../COPYING for clarification regarding multiple 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 Lic...
/****************************************************************************** * Copyright (c) 2017 <NAME>. * All rights reserved. This program and the accompanying materials are made * available under the terms of LICENSE.txt. * * Contributors: * <NAME> and others ******************************************...
/* * Copyright (C) 2009,2011 National Association of REALTORS(R) * * 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 li...
#include <iostream> #include <vector> #include <string> #include <map> #include <stdlib.h> #include <stdio.h> #include <unistd.h> #include <string.h> #include <errno.h> #include <sys/types.h> #include <sys/socket.h> #include <arpa/inet.h> #include <netinet/in.h> #define SPLIT_COUNT 3 #define BUF_LEN 1024 using namesp...
/* Copyright (c) 2018-2020 <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, subl...
#include "ircserv.hpp" #include "commands.hpp" #include "message.hpp" #include "tools.hpp" /* Command: WHOIS Parameters: [ <target> ] <mask> *( "," <mask> ) This command is used to query information about particular user. The server will answer this command with several numeric messages indicating different stat...
// ==================================================================================== // Copyright (c) 2012, <EMAIL> All rights reserved. // File : chat_server.cpp // Author : <EMAIL> // Last Change : 11/30/2012 12:13 AM // Description : // ============================================================...
/** * @file * @license BSD 3-Clause * @version $Id$ * @brief board support package for nucleo-g071rb board * * @authors <NAME> * created on: 02-02-2021 * * @copyright Copyright (c) 2021, <NAME> * All rights reserved. * * Redistribution and use in source and binary forms, with or without modifi...
#include "ofApp.h" using namespace ofxCv; using namespace cv; void ofApp::setup() { frameRate = 24; // rate at which dominant hue and dominant hz frequency are calculated nextTrigger = 1000/frameRate; camWidth = 320; camHeight = 240; // oxfOMXCam ofxCV example settings...
/* ---------------------------------------------------------------------- SPPARKS - Stochastic Parallel PARticle Kinetic Simulator http://www.cs.sandia.gov/~sjplimp/spparks.html <NAME>, <EMAIL>, Sandia National Laboratories Copyright (2008) Sandia Corporation. Under the terms of Contract DE-AC04-94AL85...
/* * Copyright © 2008 <NAME> * Copyright © 2010-2012 Linaro Limited * * This file is part of the glmark2 OpenGL (ES) 2.0 benchmark. * * glmark2 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 ve...
// frame/ipc/src/ipcpacket.ipp // // Copyright (c) 2012, 2013 <NAME> (<EMAIL>) // // This file is part of SolidFrame framework. // // Distributed under the Boost Software License, Version 1.0. // See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt. // #ifdef NINLINES #define inline #en...
#define _USE_MATH_DEFINES // For M_PI #include "evolutionaryalgorithm.h" #include "mersennerandomnumbergenerator.h" #include "valuefitness.h" #include "vectorgenomefitness.h" #include "singlethreadedpopulationcrossover.h" #include "rankparentselection.h" #include "tournamentparentselection.h" #include "simplesortedpopu...
// Copyright (C) 2019 by <NAME>, Rector and Visitors of the // University of Virginia, University of Heidelberg, and University // of Connecticut School of Medicine. // All rights reserved. // Copyright (C) 2017 - 2018 by <NAME>, Virginia Tech Intellectual // Properties, Inc., University of Heidelberg, and University ...