text
string
size
int64
token_count
int64
#ifndef LAYER_HPP #define LAYER_HPP #include "utils.hpp" class Layer { public: Layer(); Layer(float speed); void setSpeed(float speed); float getSpeed(); void setFactor(float factor); float getFactor(); void setTexture(std::vector<sf::Texture>& texture...
645
223
#include "../../misc.h" namespace myAddon { void e_RevertSecurityContext(const Napi::CallbackInfo &info) { Napi::Env env = info.Env(); if (info.Length() < 1) { throw Napi::Error::New( env, "RevertSecurityContext: Wrong number of arguments. " "RevertSecurityContext(serverContextHandle:...
796
249
/* Copyright (c) 2007 Cyrus Daboo. 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 re...
4,083
1,416
// Copyright (C) 2020 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // #include <vector> #include "single_layer_tests/non_max_suppression.hpp" #include "common_test_utils/test_constants.hpp" using namespace LayerTestsDefinitions; using namespace InferenceEngine; using namespace ngraph; const std::vector<...
2,097
592
#include <boost/mpl/aux_/preprocessed/plain/and.hpp>
53
23
//Copyright (c) 2014 - 2020, The Trustees of Indiana University. // //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 a...
1,144
399
#include <iostream> struct Node { long coe; int exp; Node* next; }; int main() { int n, m; scanf("%d %d", &n, &m); Node head{0, INT32_MAX, nullptr}; Node* cur = &head; while (n--) { int coe, exp; scanf("%d %d", &coe, &exp); Node* node = new Node{coe, exp, nullpt...
1,011
394
#pragma once #include <chrono> #ifdef __CUDACC__ inline void checkCuda(cudaError_t result, const char *file, const int line) { if (result != cudaSuccess) { fprintf(stderr, "%s@%d: CUDA Runtime Error(%d): %s\n", file, line, int(result), cudaGetErrorString(result)); exit(-1); } } #define CUDA_R...
474
180
/*********************************************** * Microchip DAC library * (c) 2012 Majenko Technologies * * This library is offered without any warranty as to * fitness for purpose, either explicitly or implicitly * implied. ***********************************************/ /* * Microchip DAC library. This wo...
1,838
740
/**************************************************************************** ** Meta object code from reading C++ file 'FlowView.hpp' ** ** Created by: The Qt Meta Object Compiler version 67 (Qt 5.15.0) ** ** WARNING! All changes made in this file will be lost! *********************************************************...
3,916
1,499
/* * File name: Compare.impl.hpp * Description: 顶层类实现 * Author: 王锦润 * Version: 2 * Date: 2019.6.11 * History: 此程序被纳入git,可以直接使用git查询。 */ //防卫式声明,必须要有 //就算没有重复包含也建议有,这是代码习惯 #ifndef _COMPARE_IMPL_HPP_ #define _COMPARE_IMPL_HPP_ #include "Compare.hpp" /* * Function: 构造函数 * Description: 构建文件夹,匹配并获得差异 * Input: 两个文件...
3,593
1,748
// clang-format off /** RUN: cd / && %clang_cxx %sysroot -fembed-bitcode -g -O0 %s -o %s.exe RUN: cd %CURRENT_DIR RUN: (unset TERM; %mull_cxx -linker=%clang_cxx -linker-flags="%sysroot" -mutators=cxx_ge_to_lt -mutators=cxx_ge_to_gt -ide-reporter-show-killed %s.exe 2>&1; test $? = 0) | %filecheck %s --dump-input=fail -...
957
431
/* * Copyright 2005-2009, Haiku Inc. * This file may be used under the terms of the MIT License. * * Originally public domain written by Alexander G. M. Smith. */ /*! MboxToBeMail is a utility program that converts Unix mailbox (mbox) files (the kind that Pine uses) into e-mail files for use with BeOS. It also...
21,980
7,626
#include "Wall.h" CWall::CWall() { } CWall::~CWall() { } void CWall::Enter() { }
84
52
// This file is distributed under the BSD 3-Clause License. See LICENSE for details. #include "stitcher.hpp" #include <fstream> #include "lgedgeiter.hpp" Live_stitcher::Live_stitcher(Stitch_pass_options &pack) { std::ifstream invariant_file(pack.boundaries_name); if (!invariant_file.good()) { Pass::error(...
5,349
1,825
/************************************************************** * Copyright (c) 2008-2009 Daniel Pfeifer * * * * Distributed under the Boost Software License, Version 1.0. * **************************************************************/...
3,882
1,407
// Copyright 2018-2020 Erik Kouters (Falcons) // SPDX-License-Identifier: Apache-2.0 /* * RTDBInputAdapter.cpp * * Created on: Oct 27, 2018 * Author: Erik Kouters */ #include "int/adapters/RTDB/RTDBInputAdapter.hpp" // #include "falconsCommon.hpp" //getRobotNumber() #include "cDiagnostics.hpp" #include "tr...
14,658
4,856
/* * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contribut...
4,640
2,368
/* * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood * Copyright (c) 2009 Advanced Micro Devices, Inc. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: redistributions of source cod...
3,054
1,056
/* Copyright 2020 Standard Cyborg 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 writing, software...
1,690
519
// // main.cpp // LeetCode-Solution // // Created by Loyio Hex on 3/7/22. // #include <iostream> #include <chrono> #include <vector> using namespace std; using namespace std::chrono; class Solution { public: string convertToBase7(int num) { if(num == 0){ return "0"; } stri...
979
329
/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* CPUInfoModule.hpp :+: :+: :+: ...
1,137
323
//////////////////////////////////////////////////////////// // DataRangeAutoCmd.h: Set or clear automatic determination of // data range in the image model. /////////////////////////////////////////////////////////// #include "DataRangeAutoCmd.h" #include "ImageData.h" #include <stdint.h> DataRangeAutoCmd::DataRangeA...
1,081
368
extern "C" { #include "video\video.h" } #ifdef RX_NES_RENDER_DX9 #include <windows.h> #include <d3d9.h> #include <d3dcompiler.h> #pragma comment(lib, "d3d9.lib") #pragma comment(lib, "d3dcompiler.lib") static LPDIRECT3D9 g_pD3D; static LPDIRECT3DDEVICE9 g_pD3DDevice; static LPDIRECT3DSURFACE9 g_pOffscr...
6,271
3,083
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~// // Copyright (c) 2017-21, Lawrence Livermore National Security, LLC // and RAJA Performance Suite project contributors. // See the RAJAPerf/COPYRIGHT file for details. // // SPDX-License-Identifier: (BSD-3-Clause) //~~~~~~~~~~~~~~~~~~~~~~~~...
8,268
3,473
// Copyright 1996-2018 Cyberbotics Ltd. // // 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 agr...
3,613
1,266
#ifndef CAFFE_CUDNN_BATCH_NORM_LAYER_HPP_ #define CAFFE_CUDNN_BATCH_NORM_LAYER_HPP_ #include <vector> #include "caffe/blob.hpp" #include "caffe/layer.hpp" #include "caffe/proto/caffe.pb.h" #include "caffe/layers/batch_norm_layer.hpp" namespace caffe { #ifdef USE_CUDNN template <typename Dtype> class CuDNNBatchNorm...
1,553
596
/** * Copyright (c) 2020 Paul-Louis Ageneau * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This ...
1,557
499
#include <UnitTest++.h> #include "Teuchos_GlobalMPISession.hpp" #include "VerboseObject_objs.hh" #include "state_evaluators_registration.hh" #include "wrm_flow_registration.hh" int main(int argc, char *argv[]) { int res = 0; { Teuchos::GlobalMPISession mpiSession(&argc, &argv); res = UnitTest::RunAllTest...
346
137
auto OBC1::serialize(serializer& s) -> void { s(ram); s(status.address); s(status.baseptr); s(status.shift); }
119
51
#pragma once #include <functional> #include "DLL.hpp" namespace System { /** * \brief Encapsulates a method that has specified parameters and does not return a value. * \tparam Args The type of the parameters of the method that this delegate encapsulates. */ template<typename ...Args> class...
1,271
371
// Licensed to the Apache Software Foundation (ASF) under one // or more contributor license agreements. See the NOTICE file // distributed with this work for additional information // regarding copyright ownership. The ASF licenses this file // to you under the Apache License, Version 2.0 (the // "License"); you may...
2,188
790
/************************************************************************ * \file ServiceClient.cpp * \ingroup AREG Asynchronous Event-Driven Communication Framework examples * \author Artak Avetyan * \brief Collection of AREG SDK examples. * This file contains simple implementat...
6,354
1,926
#include "ConfigPreprocessor.h" #include <Core/Types.h> #include <Poco/Path.h> #include <regex> namespace DB { std::vector<XMLConfigurationPtr> ConfigPreprocessor::processConfig( const Strings & tests_tags, const Strings & tests_names, const Strings & tests_names_regexp, const Strings & skip_tags, c...
3,010
913
#include "missile.h" #include "weapons.h" #include "../../ObjManager.h" #include "../../caret.h" #include "../../trig.h" #include "../../sound/sound.h" #include "../../common/misc.h" #include "../../game.h" #include "../../player.h" #include "../../autogen/sprites.h" #define STATE_WAIT_RECOIL_OVER 1 #define STATE...
7,324
3,582
//============================================================================== // Copyright 2003 & onward LASMEA UMR 6602 CNRS/Univ. Clermont II // Copyright 2009 & onward LRI UMR 8623 CNRS/Univ Paris Sud XI // // Distributed under the Boost Software License, Version 1.0. // ...
1,746
648
/****************************************************************************** * Copyright (c) 2018(-2021) STMicroelectronics. * All rights reserved. * * This file is part of the TouchGFX 4.17.0 distribution. * * This software is licensed under terms that can be found in the LICENSE file in * the root directory of thi...
16,310
5,053
// Generated by the protocol buffer compiler. DO NOT EDIT! // source: rpc.proto #define INTERNAL_SUPPRESS_PROTOBUF_FIELD_DEPRECATION #include "rpc.pb.h" #include <algorithm> #include <google/protobuf/stubs/common.h> #include <google/protobuf/stubs/port.h> #include <google/protobuf/stubs/once.h> #include <google/pro...
53,873
20,118
#include <point.hpp> #include <vector> #include <iostream> #if defined (__ARBITARY__) #include <cstdlib> #include <ctime> #define rand01 (static_cast<float>(std::rand()) / static_cast<float>(RAND_MAX)) #define frand(min, max) ((max - min) * rand01 + min) #endif #define SIZE (10UL) int main() ...
786
320
#pragma once #include <SFML/Graphics.hpp> class Entity { public: bool destroyed{false}; virtual ~Entity() {} virtual void update() {} virtual void draw(sf::RenderWindow& mTarget) {} };
204
65
// // SpaceMapping.cpp // RegionGrowing // // Created by Timothy Davison on 2015-09-10. // Copyright © 2015 EpicGames. All rights reserved. // #include "RegionGrowing.h" #include "SpaceMapping.hpp"
204
87
// This file is part of Blend2D project <https://blend2d.com> // // See blend2d.h or LICENSE.md for license and copyright information // SPDX-License-Identifier: Zlib #include "../api-build_p.h" #include "../pipeline/piperuntime_p.h"
235
91
/* * Copyright (C) 2021-2022 Intel Corporation * * SPDX-License-Identifier: MIT * */ #include "level_zero/tools/source/sysman/firmware/linux/os_firmware_imp.h" const std::string iafPath = "device/"; const std::string iafDirectory = "iaf."; const std::string pscbin_version = "/pscbin_version"; namespace L0 { ze...
1,980
659
/* * Copyright 2013 Matthew Harvey * * 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...
2,221
762
// Copyright 2018 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "peridot/lib/scoped_tmpfs/scoped_tmpfs.h" #include <lib/fdio/fd.h> #include <lib/fdio/fdio.h> #include <lib/fdio/directory.h> #include <lib/fsl/i...
1,310
520
/* * The MIT License (MIT) * * Copyright (c) 2015 Charles J. Cliffe * 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 ...
11,335
3,218
#include <common_robotics_utilities/print.hpp> #include <voxelized_geometry_tools/collision_map.hpp> #include <voxelized_geometry_tools/signed_distance_field.hpp> #include <voxelized_geometry_tools/ros_interface.hpp> #include <ros/ros.h> #include <visualization_msgs/MarkerArray.h> #include <functional> #include <common...
11,947
4,302
//===----------------------------------------------------------------------===// // // 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 // //===---------------------------...
10,006
3,014
/* * Copyright (C) 2006, 2007, 2008 Apple 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 li...
23,471
7,779
/* -*- 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/. */ ...
62,085
19,736
#include "proof_checker.h" #include "ast_ll_pp.h" void tst_checker1() { ast_manager m(PGM_FINE); expr_ref a(m); proof_ref p1(m), p2(m), p3(m), p4(m); bool result; expr_ref_vector side_conditions(m); a = m.mk_const(symbol("a"), m.mk_bool_sort()); p1 = m.mk_hypothesis(a.get()); p2 = m.mk...
863
401
// Copyright 2020 POGchain Development Foundation and contributors. Licensed // under the Apache License, Version 2.0. See the COPYING file at the root // of this distribution or at http://www.apache.org/licenses/LICENSE-2.0 #include "history/HistoryArchiveManager.h" #include "history/test/HistoryTestsUtils.h" #includ...
2,820
917
// This file is generated automatically by a tool, please don't edit. #pragma once #include <emmintrin.h> #include <immintrin.h> #include "Implementation/utils.hpp" namespace Intrinsics { namespace Sse { // Add packed 8-bit integers in "a" and "b", and store the results in "dst" inline __m128i XM_CALLCONV add_ep...
46,533
21,704
//==------ program_manager.hpp --- SYCL program manager---------------------==// // // 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 // //===---------------------------...
5,838
1,595
/** * @file * @copyright This code is licensed under the 3-clause BSD license.\n * Copyright ETH Zurich, Laboratory for Physical Chemistry, Reiher Group.\n * See LICENSE.txt for details. */ #include "OctupoleMatrix.h" #include "DipoleMatrix.h" namespace Scine { namespace Utils { void Octupo...
1,318
444
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Copyright (C) 2016-2021, Intel Corporation // // SPDX-License-Identifier: MIT /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////...
79,527
24,422
// #include <biogears/cdm/utils/Logger.h> // #include <biogears/cdm/substance/SESubstanceManager.h> // #include <biogears/cdm/utils/DataTrack.h> // #include <biogears/cdm/scenario/requests/SEDataRequest.h> #include <biogears/exports.h> #include <string> #include <pybind11/pybind11.h> #include <biogears/cdm/patient/acti...
1,772
725
// 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 "base/template_util.h" #include "base/basictypes.h" #include "testing/gtest/include/gtest/gtest.h" namespace base { namespace { struct ASt...
4,409
1,530
// Geometric Tools, LLC // Copyright (c) 1998-2014 // Distributed under the Boost Software License, Version 1.0. // http://www.boost.org/LICENSE_1_0.txt // http://www.geometrictools.com/License/Boost/LICENSE_1_0.txt // // File Version: 5.10.0 (2013/03/17) #include "Wm5MathematicsPCH.h" #include "Wm5DistPoint2...
2,981
994
/* ** EPITECH PROJECT, 2018 ** arcade ** File description: ** arcade */ /*! * @file IGraphicLib.hpp * @brief Graphic libraries dedicated class interface * @authors https://github.com/EPITECH-Strasbourg-2021/CPP-Arcade-Spec * * Interface used by graphic libraries * All functions must be implemented correctly for ...
3,453
1,192
/* Copyright (c) 2015 - 2022 Advanced Micro Devices, Inc. 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, mer...
3,530
1,185
/* See LICENSE for license details */ /* */ #include <appl_status.h> #include <appl_predefines.h> #include <appl_types.h> #include <object/appl_object.h> #include <buf/appl_bytes.h> #include <buf/appl_bytes_base.h> #include <buf/appl_buf.h> #include <buf/appl_bytes_descriptor.h> #include <buf/appl_bytes_cust...
1,662
651
#pragma once #ifndef HYDROSIG_SIGNAL_4_HPP_INCLUDED #define HYDROSIG_SIGNAL_4_HPP_INCLUDED /* * MIT License * * Copyright (c) 2017 Peter Gyulai * * 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 th...
57,790
19,157
#include <common.h> #pragma hdrstop #include <GlFont.h> namespace Fangame { ////////////////////////////////////////////////////////////////////////// CGlFont::CGlFont( CUnicodeView fontName, int fontSize ) : font( fontName ), renderer( CreateOwner<CFreeTypeGlyphProvider>( font, fontSize ) ) { rende...
453
135
/* * Copyright (C) 2021 Patrick Mours. All rights reserved. * License: https://github.com/crosire/reshade#license */ #include <vector> #include <limits> #include "com_ptr.hpp" #include "reshade_api_pipeline.hpp" #include "d3d9_impl_type_convert.hpp" auto reshade::d3d9::convert_format(api::format format, bool locka...
35,805
16,412
#include "buffer.h" #include <iostream> #include <string.h> #include <strings.h> using namespace std; namespace midi { Buffer::Buffer(const char* data, unsigned long len) : data_(data), len_(len), pos_(0) { } Buffer::~Buffer() { } bool Buffer::Read(char* c) { return Read(c, 1); } bool Buffer::Read(unsigned c...
1,804
668
#include <iostream> #include <Halide.h> #include <recfilter.h> using namespace Halide; int main(int argc, char **argv) { int width = 20; int height = 20; int tile = 4; Image<float> image = generate_random_image<float>(width,height); RecFilterDim x("x", width), y("y", height); RecFilter f...
739
290
#include "shapegame.hpp" using namespace shapegame; int main() { Game game(400, 400, "My New Game"); game.scene->setBackgroundColor(Color::BLUE); game.scene->addChild(new TriangleIsosceles(100, 100, Position(100, 100), Color::BLACK)); game.run(); }
254
110
#pragma once // // Copyright (c) 2015, J2 Innovations // Copyright (c) 2012 Brian Frank // Licensed under the Academic Free License version 3.0 // History: // 08 Sep 2014 Radu Racariu<radur@2inn.com> Ported to C++ // 06 Jun 2011 Brian Frank Creation // #include "headers.hpp" #include "Poco/Net/HTTPServerRequest...
3,397
995
#include <SDL2/SDL.h> #include <SDL2/SDL_opengl.h> #include <string> #include <cstring> PFNGLGENBUFFERSPROC glGenBuffers; PFNGLBINDBUFFERPROC glBindBuffer; PFNGLBINDBUFFERRANGEPROC glBindBufferRange; PFNGLBUFFERDATAPROC glBufferData; PFNGLMAPBUFFERPROC glMapBuffer; PFNGLUNMAPBUFFERPROC glUnmapBuffer; PFNGLDELETEBUFF...
17,991
6,396
/// Recursive approach //this code is used to reverse a linked list #include<iostream> using namespace std; class node{ public: int data; node * next; node(int data){ this->data=data; this->next=NULL; } }; node* takeinput(){ int data; cin>>data; node* head=NULL,*tail=NULL; ...
1,146
424
#include "gtest/gtest.h" /* 정수 N이 주어졌을 때 최소 둘레(perimeter)를 찾는 문제. 여기서 N은 사각형의 넓이. 예) N = 30 이라면 다음과 같은 조합이 있을 수 있음 (1, 30), with a perimeter of 62, (2, 15), with a perimeter of 34, (3, 10), with a perimeter of 26, (5, 6), with a perimeter of 22. 여기서 최소 넓이는 22 이므로 22를 리턴하면 된다. 힌트 : * 한 변의 길이가 정해지면 다른 한...
1,729
1,118
/* Copyright (c) 2012 Advanced Micro Devices, Inc. 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 anyone to use this software for any purpose, including comm...
26,700
12,690
/** ****************************************************************************** * This file is part of the TouchGFX 4.15.0 distribution. * * <h2><center>&copy; Copyright (c) 2020 STMicroelectronics. * All rights reserved.</center></h2> * * This software component is licensed by ST under Ultimate Libert...
2,649
781
//======================================================================== // stdx-Enum.inl //======================================================================== // The implementation of enumerations is a little intricate to give us // the performance and syntax we desire while still guaranteeing that we // never ...
9,654
2,580
#include <string> #include <vector> #include <iostream> #include <cctype> #include <fstream> #include <list> #include "main.h" #include "arch.h" #include "diagnostics.h" #include "reference.h" #include "operation.h" // --------------------------------------------------------------------------------------------------...
26,790
8,333
#include "Render/Image/ImageConvert.h" #include "Render/Image/LibDdsHelper.h" #include "Render/Image/LibPVRHelper.h" #include "Render/Image/Image.h" #include "Functional/Function.h" namespace DAVA { uint32 ChannelFloatToInt(float32 ch) { return static_cast<uint32>(Min(ch, 1.0f) * std::numeric_limits<uint8>::max())...
17,925
6,816
// This is basic/dbnl/dbnl_solve_trigonometric_equation.cxx //: // \file #include "dbnl_solve_trigonometric_equation.h" #include <vnl/vnl_math.h> #include <vcl_cmath.h> const double dbnl_solve_trigonometry_eps = 1e-12; //: Solve trigonometry equation a sin(x) + b cos(x) + c = 0 // returned roots have format: root(...
1,939
872
/*---------------------------------------------------------------------------*\ Copyright (C) 2011-2015 OpenFOAM Foundation ------------------------------------------------------------------------------- License This file is part of CAELUS. CAELUS is free software: you can redistribute it and/or modify it ...
3,607
957
/* +------------------------------------------------------------------------+ | Mobile Robot Programming Toolkit (MRPT) | | https://www.mrpt.org/ | | | | Cop...
2,945
1,197
// This file is made available under Elastic License 2.0. // This file is based on code available under the Apache license here: // https://github.com/apache/orc/tree/main/c++/src/sargs/PredicateLeaf.hh /** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See ...
4,063
1,257
/* ----------------------------------------------------------------------------- The copyright in this software is being made available under the BSD License, included below. No patent rights, trademark rights and/or other Intellectual Property Rights other than the copyrights concerning the Software are granted unde...
7,803
3,191
#include <iostream> #include <memory> #include "CompanyTraveler.hpp" #include "PlaneTravel.hpp" #include "TrainTravel.hpp" int main() { auto plane = std::make_shared<PlaneTravel>(); auto train = std::make_shared<TrainTravel>(); CompanyTraveler traveler{std::static_pointer_cast<TravelMethod>(plane)}; C...
521
184
/* * This source file is part of RmlUi, the HTML/CSS Interface Middleware * * For the latest information, see http://github.com/mikke89/RmlUi * * Copyright (c) 2008-2010 CodePoint Ltd, Shift Technology Ltd * Copyright (c) 2019 The RmlUi Team, and contributors * * Permission is hereby granted, free of charge, to...
15,180
5,946
// Copyright (C) 2022 Andreas Åkerberg // This code is licensed under MIT license (see LICENSE for details) #include "ModelLoader.h" #include <filesystem> namespace Forradia { void ModelLoader::LoadModels() { models.clear(); modelNames.clear(); auto file_path = std::string(SDL_GetBa...
1,426
398
// Boost.Geometry (aka GGL, Generic Geometry Library) // Copyright (c) 2007-2014 Barend Gehrels, Amsterdam, the Netherlands. // This file was modified by Oracle on 2014. // Modifications copyright (c) 2014, Oracle and/or its affiliates. // Use, modification and distribution is subject to the Boost Software License, ...
2,375
799
/* -*- Mode: C; tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- */ /* * Copyright 2010-2020 Couchbase, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * ...
8,954
3,246
// Copyright (c) 2021 DNV AS // // 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 #include <jsUnits/jsAxialStiffness.h> #include <jsUnits/jsUnitClass.h> #include <Units/AxialStiffness.h> #include "jsRotationalSt...
1,432
522
// Copyright (c) 2016, Baidu.com, Inc. All Rights Reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // #include <errno.h> #include <sys/stat.h> #include <sys/types.h> #include <dirent.h> #include <common/logging.h> #include <common/string_util.h> #include...
19,537
6,825
#include "traywidget.h" #include "ui_traywidget.h" #include<QDebug> #if _MSC_VER >= 1600 #pragma execution_character_set("utf-8") #endif Traywidget::Traywidget(QString name,QWidget *parent) : QWidget(parent), ui(new Ui::Traywidget) { qDebug()<<"创1"; ui->setupUi(this); this->setWindowFlags(Qt::Splas...
2,870
1,131
#ifndef TELEOPERADO_HPP #define TELEOPERADO_HPP #include <webots/Robot.hpp> #include "ZeroPlayer.hpp" #define NMOTORS 20 namespace webots { class Joystick; }; void teleoperado(); #endif
189
81
#include "coldef.hpp" #include <string> #include <vector> namespace chrgfx { using namespace std; using namespace png; coldef::coldef(string const & id, coldef_type type, bool const big_endian, string const & description) : gfxdef(id, description), m_type(type), m_big_endian(big_endian) { } refcoldef::re...
2,202
915
#include "SprayLeftCommand.h" #include "Object.h" #include "SprayPepperComponent.h" SprayLeftCommand::SprayLeftCommand(pep::Object* pObject) :BaseCommand(pObject) { } void SprayLeftCommand::Execute() { GetActor()->GetComponent<SprayPepperComponent>()->SprayLeft(); }
271
99
#include <algorithm> #include <iostream> #include <iomanip> #include <sstream> #include <unordered_set> #include "glszm.h" GLSZM_features::GLSZM_features (int minI, int maxI, const ImageMatrix& im) { //==== Check if the ROI is degenerate (equal intensity) if (minI == maxI) { bad_roi_data = true; re...
10,319
5,233
#include <iostream> #include <stdio.h> #ifdef _WIN32 #include <Windows.h> #endif #include <osgViewer/Viewer> #include <osg/GLExtensions> const int OSG_WIDTH = 1024; const int OSG_HEIGHT = 960; class TestSupportOperation : public osg::GraphicsOperation { public: TestSupportOperation() : osg::Referenced(t...
1,718
594
/* * Copyright (c) 2008-2018 SLIBIO <https://github.com/SLIBIO> * * 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 * ...
6,346
3,419
// Autogenerated from CppHeaderCreator // Created by Sc2ad // ========================================================================= #pragma once // Begin includes #include "extern/beatsaber-hook/shared/utils/typedefs.h" #include "extern/beatsaber-hook/shared/utils/byref.hpp" // Including type: System.Marshal...
14,084
4,727
// This file is part of the `Selene` library. // Copyright 2017-2019 Michael Hofmann (https://github.com/kmhofmann). // Distributed under MIT license. See accompanying LICENSE file in the top-level directory. #include <catch2/catch.hpp> #include <selene/img/interop/ImageToDynImage.hpp> #include <selene/img/pixel/Pix...
2,817
1,194
#include <gtest/gtest.h> #include <iostream> #include <vector> #include <list> #include <algorithm> #include <memory> #include "tale/tale.hpp" #include <time.h> #define GTEST_INFO std::cout << "[ INFO ] " using namespace tattletale; TEST(TaleKernels, IncreasingKernelId) { Random random; C...
28,004
9,692
#include "SinglyLList.h" #include <iostream> using namespace std; int main(void) { List<int> l; l.insertAtFront(12); l.insertAt(10, 0); l.insertAt(10, 0); l.insertAtEnd(51); l.traverse(); l.insertAt(10, 0); l.insertAtFront(17); l.insertAt(10, 0); l.traverse(); cout << l...
420
193