text
stringlengths
3
1.05M
import torch import torch.nn as nn import torch.nn.functional as F import torch.nn.quantized as nnq toq = torch.ops.quantized from torch.ao.quantization.quantization_mappings import ( DEFAULT_STATIC_QUANT_MODULE_MAPPINGS, DEFAULT_DYNAMIC_QUANT_MODULE_MAPPINGS, ) import operator from typing import Callable # T...
import setuptools """" setuptools.setup( name='dist_build', version='0.0.1', packages=['dist_build'], install_requires=[ 'requests', 'importlib; python_version == "3.8"', ], package_data={ # If any package contains *.txt or *.rst files, include them: "": ["*.json...
from setuptools import setup from setuptools import find_packages version = '0.1.0.dev1' # Remember to update local-oldest-requirements.txt when changing the minimum # acme/certbot version. install_requires = [ 'acme>=0.21.1', 'certbot>=0.21.1', 'aliyun-python-sdk-core>=2.6.0', 'aliyun-python-sdk-ali...
import*as Common from'../common/common.js';import*as MobileThrottling from'../mobile_throttling/mobile_throttling.js';import*as SDK from'../sdk/sdk.js';import*as UI from'../ui/ui.js';export class NetworkConfigView extends UI.Widget.VBox{constructor(){super(true);this.registerRequiredCSS('network/networkConfigView.css')...
import http.cookiejar import urllib import ssl import logging import json from bs4 import BeautifulSoup import time import datetime import sys import telegram import requests import likeyoubot_logger import traceback import requests class LYBHttp: def __init__(self, user_id, password): self.mb_id = user_id self.m...
from django.apps import AppConfig class SquidwardConfig(AppConfig): name = 'squidward'
import Main from '@/components/main' import parentView from '@/components/parent-view' /** * iview-admin中meta除了原生参数外可配置的参数: * meta: { * title: { String|Number|Function } * 显示在侧边栏、面包屑和标签栏的文字 * 使用'{{ 多语言字段 }}'形式结合多语言使用,例子看多语言的路由配置; * 可以传入一个回调函数,参数是当前路由对象,例子看动态路由和带参路由 * hideInBread: (fals...
const express = require('express'), router = express.Router(), controller = require('../controllers/card.controller'); router.route("/").get(controller.getSongCard); module.exports = router;
from importlib.util import module_from_spec, spec_from_file_location from pathlib import Path from setuptools import find_packages, setup with open("requirements.txt") as f: requirements = f.read().splitlines() current_directory = Path(__file__).parent.resolve() long_description = (current_directory /...
# Generated by Django 2.2.3 on 2019-07-17 09:29 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('TeamXapp', '0074_merge_20190717_1029'), ] operations = [ migrations.AlterField( model_name='all...
// // DJFSportTrackingLineModel.h // LoveWalking // // Created by 佃杰峰 on 2017/5/1. // Copyright © 2017年 佃杰峰. All rights reserved. // #import <Foundation/Foundation.h> @class DJFSportPolyLine; @interface DJFSportTrackingLineModel : NSObject /** * 折线 */ @property(nonatomic,strong)DJFSportPolyLine * polyLine; ...
import time import logging import pickle import os, socket import traceback import threading import Pyro4 class Worker(object): """ The worker is responsible for evaluating a single configuration on a single budget at a time. Communication to the individual workers goes via the nameserver, management of the wo...
/******/ (function(modules) { // webpackBootstrap /******/ function hotDisposeChunk(chunkId) { /******/ delete installedChunks[chunkId]; /******/ } /******/ var parentHotUpdateCallback = window["webpackHotUpdate"]; /******/ window["webpackHotUpdate"] = /******/ function webpackHotUpdateCallback(chunkId, moreMo...
#!/usr/bin/env python import argparse import os import re import shutil import sys import zipfile import envoy import requests from tqdm import tqdm import yaml ROOT_DIRECTORY = os.path.expanduser('~/.mapturner') DATA_DIRECTORY = os.path.join(ROOT_DIRECTORY, 'data') TEMP_DIRECTORY = os.path.join(ROOT_DIRECTORY, 'tm...
from pyrpc import apps from pyrpc.store import store from pyrpc.decorators import safe_method from django.test import TestCase from django.apps import apps as django_apps from tests.utils import PlainClass class AppTestCase(TestCase): def test_check_settings(self): fixture = ['Test'] with self.set...
module.exports = (i18n) => `--- ## /${i18n.__('slash_command')} ### ${i18n.__('Usage instructions')} | ${i18n.__('Command')} | ${i18n.__('Example usage')} | ${i18n.__('Description')} ...
# -*- coding: utf-8 -*- from django.conf.urls.defaults import * from django.contrib import admin from django.conf import settings from django.http import HttpResponse admin.autodiscover() def handle404(request): return HttpResponse('404') def handle500(request): return HttpResponse('500') handler404 = 'mock...
from rest_framework.routers import DefaultRouter from .views import WorkflowTypeModelViewSet, WorkFlowModelViewSet, WorkFlowItemModelViewSet, WorkFlowEntityModelViewSet,WorkFlowItemEntityModelViewSet workflow_router = DefaultRouter() workflow_router.register(r'workflow_type', WorkflowTypeModelViewSet, basename="workfl...
/* Broadcom B43 wireless driver DMA ringbuffer and descriptor allocation/management Copyright (c) 2005, 2006 Michael Buesch <m@bues.ch> Some code in this file is derived from the b44.c driver Copyright (C) 2002 David S. Miller Copyright (C) Pekka Pietikainen This program is free software; you can red...
//>>built define("dojox/sketch/Anchor",["dojo/_base/kernel","dojo/_base/lang","../gfx"],function(e){e.getObject("sketch",!0,dojox);dojox.sketch.Anchor=function(a,b,g){var e=this,f=null;this.type=function(){return"Anchor"};this.annotation=a;this.id=b;this._key="anchor-"+dojox.sketch.Anchor.count++;this.shape=null;this.i...
# # 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 # distributed under...
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) class PyLap(PythonPackage): """lap is a linear assignment problem solver using Jonker-Volgenant algorithm for den...
import setuptools with open("README.md", "r") as fh: long_description = fh.read() required_packages = ["boto3>=1.10.44, < 2.0", "sagemaker < 3.0"] setuptools.setup( name="sagemaker_studio_image_build", version="0.5.0", author="Amazon Web Services", description="Build Docker Images in Amazon SageM...
/********************************************************************** Copyright(c) 2011-2015 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: * Redistributions of source co...
import a from 'assert'; a.ok();
var express = require('express'); var router = express.Router(); /* GET home page. */ router.get('/', function (req, res, next) { var data = { code: 0, data: { name: 'aaa', pwd: '123' }, isSuccess: true, msg: "请求成功" } //将product视图与指定的对象渲染后输出到客户端 res.json(data); }); module...
export * from '@styled-icons/crypto/Xpm';
'use strict'; /*! (C) 2017-2018 Andrea Giammarchi - ISC Style License */ const {Component, bind, define, hyper, wire} = require('hyperhtml'); // utils to deal with custom elements builtin extends const ATTRIBUTE_CHANGED_CALLBACK = 'attributeChangedCallback'; const O = Object; const classes = []; const defineProperty ...
export default [ { "first_name": "Soledad", "last_name": "Mockus", "company_name": "Sinclair Machine Products Inc", "address": "75 Elm Rd #1190", "state": "ACT", "post": 2600, "city": "Barton", "phone1": "02-1291-8182", "phone2": "0444-126-746", "email": "soledad_mockus@yahoo....
import pandas as pd from pathlib import Path from api import fetcher from data import utils def fixed_dataset() -> pd.DataFrame: # https://zenodo.org/record/4601480 flight_list = pd.concat( pd.read_csv(file, parse_dates=["firstseen", "lastseen", "day"]) # for file in Path("path/to/folder").glo...
// VARIABILI / Timeline "burgerOpenTL" var burgerIcon = $('.burger'); var burgerLine1 = $('.burger .line1'); var burgerLine2 = $('.burger .line2'); var burgerLine3 = $('.burger .line3'); var speed = 0.1; // MENU var menuContainer = $('.sidebar'); var barra = menuContainer.find('.menu-bg'); var menu = $('.menu'); var l...
var c={conjugar:function(r,n){if(0==r.length)return"not found";for(var e in regular[n])for(var u in regular[n][e])if(r===u)return regular[n][e][u];return c.conjugar(r.slice(1,r.length),n)},conjugacion:function(r){return r[r.length-2]+r[r.length-1]},raiz:function(r){return r.slice(0,r.length-2)},tipo:{ar:"Primera Conjug...
#ifndef _BALONG_POWER_H #define _BALONG_POWER_H #include <linux/platform_device.h> #include <linux/gpio.h> enum balong_gpio_index { BALONG_RESET, BALONG_POWER_ON, BALONG_PMU_RESET, BALONG_HOST_ACTIVE, BALONG_HOST_WAKEUP, BALONG_SLAVE_WAKEUP, BALONG_POWER_IND, BALONG_RESET_IND, BALONG_GPIO_NUM ...
import sympy from symfem import create_element from symfem.symbolic import x, symequal def test_lagrange(): space = create_element("triangle", "Lagrange", 1) assert symequal( space.tabulate_basis([[0, 0], [0, 1], [1, 0]]), ((1, 0, 0), (0, 0, 1), (0, 1, 0)), ) def test_nedelec(): spac...
import Vue from 'vue' import VueI18n from 'vue-i18n' import locale from 'element-ui/lib/locale' import zh from './langs/zh' import en from './langs/en' import enLocale from 'element-ui/lib/locale/lang/en' import zhLocale from 'element-ui/lib/locale/lang/zh-CN' Vue.use(VueI18n) const messages = { en: Object.assign(...
/* 本脚本仅适用于快手极速版签到 获取Cookie方法: 1.将下方[rewrite_local]和[MITM]地址复制的相应的区域 下, 2.APP登陆账号后,点击'红包',即可获取Cookie. 仅测试Quantumult x,Surge、Loon自行测试 by Macsuny 感谢 @Chavy @Nobyda ~~~~~~~~~~~~~~~~ Surge 4.0 : [Script] cron "0 9 * * *" script-path=https://raw.githubusercontent.com/Sunert/Scripts/master/Task/kuaishou2.js # 获取快手极速版 Cookie...
export default function () { return [ {title: 'Book 1', pages: 222}, {title: 'Book 2', pages: 333}, {title: 'Book 3', pages: 444}, {title: 'Book 4', pages: 555} ]; }
import cx from 'classnames' import _ from 'lodash' import PropTypes from 'prop-types' import React from 'react' import { childrenUtils, customPropTypes, getElementType, getUnhandledProps, META, SUI, useKeyOnly, useWidthProp, } from '../../lib' import Card from './Card' /** * A group of cards. */ fun...
module.exports = { displayName: 'consumption', preset: '../../../jest.preset.js', setupFilesAfterEnv: ['<rootDir>/src/test-setup.ts'], globals: { 'ts-jest': { stringifyContentPathRegex: '\\.(html|svg)$', tsconfig: '<rootDir>/tsconfig.spec.json', }, }, coverageDirectory: '../../../covera...
#!/usr/bin/env python # Add/replace one or more of the following fields: # OPERATOR # STATION_CALLSIGN # TX_PWR # DE SA6MWA https://github.com/sa6mwa/sa6mwa-logs # based on ADIF.PY by OK4BX http://web.bxhome.org import sys, getopt, os import re import datetime import time import glob ADIF_REC_RE = re.compile(r'<(...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.AbiDecoder = void 0; const ethereum_types_1 = require("ethereum-types"); const ethers = require("ethers"); const _ = require("lodash"); const _1 = require("."); /** * AbiDecoder allows you to decode event logs given a set of supplied ...
/*! * @file AdafruitIO_Definitions.h * * This is part of the Adafruit IO library for the Arduino platform. * * Adafruit invests time and resources providing this open source code, * please support Adafruit and open-source hardware by purchasing * products from Adafruit! * * Written by Tony DiCola, Todd Treece ...
d={ 'foo':'bar', 'nest':{ 'one':1, 'two':2 }, 'super-nest':{ 'nest':{ 'hest':12 }, 'foo':'oid', 'h':['hello'], 'liawst':['date'], 'nestns':[ {'make':'me','happy':['now']}] } } def dict2yml(d,indent=0,tab=' '): res = ""...
#!/usr/bin/env python """Day 8: Matchsticks -- Advent of Code 2015""" def part_one(data: str) -> int: """Determine the difference between raw and parsed string length in data.""" sum_difference = 0 for line in data.splitlines(): sum_difference += len(line) - parsed_length(line) return sum_diff...
{ name: '挽尊卡隐藏', desc: '屏蔽挽尊卡,留下一个横条提示。', flag: __type_floor, _init: function () { _css.append ('.save_lz_face::before{content:attr(who) " 使用了挽尊卡"}'); }, _proc: function (floorType, args) { if ($('.save_face_post', args._main).size()) { // 发现挽尊卡 $('<div>').addClass('floor-stripe save_lz_face')...
# Copyright (c) 2012-2013 Mitch Garnaat http://garnaat.org/ # Copyright 2012-2014 Amazon.com, Inc. or its affiliates. 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. A copy of # the License is located at # # http...
/* MD5 module */ /* This module provides an interface to the MD5 algorithm */ /* See below for information about the original code this module was based upon. Additional work performed by: Andrew Kuchling (amk@amk.ca) Greg Stein (gstein@lyra.org) Trevor Perrin (trevp@trevp.net) Copyright (C) 2005-200...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isEntireRecordGiven = exports.default = void 0; const isEntireRecordGiven = (propertyOrRecord, value) => !!(typeof value === 'undefined' // user can pass property and omit value. This makes sense when // third argument of the funct...
// Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. // Copyright (c) 2011 The LevelDB Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. See the AUTHORS file for names of contributors. #pragma once #ifndef ROCKSDB_...
import mongoose from 'mongoose'; import mongoosePaginate from 'mongoose-paginate'; const { Schema } = mongoose; const MeetingSchema = new Schema( { title: { type: String, required: true, max: 128 }, details: { type: String, required: false }, date: { type: String, required: true }, ...
# This file is part of h5py, a Python interface to the HDF5 library. # # http://www.h5py.org # # Copyright 2008-2013 Andrew Collette and contributors # # License: Standard 3-clause BSD; see "license.txt" for full license terms # and contributor agreement. """ Attributes testing module Covers all op...
var AlertNotice = (function() { var el = null; var config = { ms_displayed: 3000, ms_animated: 1000 }; var configure = function(overrides) { config = $.extend(true, config, overrides); el = $(config.selector); }; var ready = function() { el.css(config.css.hide); callback('before');...
# -*- coding: utf-8 -*- # File generated according to Generator/ClassesRef/Output/OutLoss.csv # WARNING! All changes made in this file will be lost! """Method code available at https://github.com/Eomys/pyleecan/tree/master/pyleecan/Methods/Output/OutLoss """ from os import linesep from sys import getsizeof from loggin...
# Copyright (C) 2020-2021 Intel Corporation # SPDX-License-Identifier: Apache-2.0 """Aggregation function interface module.""" from typing import Iterator, Tuple, List from openfl.utilities import LocalTensor, SingletonABCMeta import numpy as np from abc import abstractmethod import pandas as pd class AggregationFun...
# -*- coding: utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. import account_invoice import purchase import res_company import res_config import res_partner import stock
// // AppDelegate.h // ImageViewer // // Created by Damien Solimando on 17/05/15. // Copyright (c) 2015 Solidx. All rights reserved. // #import <UIKit/UIKit.h> @interface AppDelegate : UIResponder <UIApplicationDelegate> @property (strong, nonatomic) UIWindow *window; @end
class example: sum=0 def function1(self): a=10 b=20 print("from first function a is",a) class example1(example): def function2(): print("a is ", a) print("sum is ",sum) obj= example() print(obj.function1("t"))
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import print_function import platform import sys import site import os __version__ = "0.0.1" __short_description__ = "Cross Operation System Compatible Library." __license__ = "MIT" __author__ = "Sanhe Hu" WINDOWS, MACOS, LINUX = False, False, False _syst...
/* eslint-disable no-underscore-dangle */ import expect from 'expect.js' import {stripIndent} from 'common-tags' import sinon from 'sinon' import {create} from '../../src' import {StyleRule} from '../../src/plugins/styleRule' import {resetSheets, createGenerateId} from '../../../../tests/utils' describe('Integration:...
import os from contextlib import contextmanager import boto3 from botocore.errorfactory import ClientError import dagster.seven as seven from dagster import Field, StringSource from dagster import _check as check from dagster.core.storage.compute_log_manager import ( MAX_BYTES_FILE_READ, ComputeIOType, Co...
#!/usr/bin/env python # -*- coding: utf-8 -*- # Copyright (C) 2009-2011 Rosen Diankov (rosen.diankov@gmail.com) # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/li...
/* Copyright (c) 2000, 2011, Oracle and/or its affiliates. Copyright (c) 2010, 2017, MariaDB Corporation. 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; version 2 of the License. Thi...
// // VerifyDetailNewHViewController.h // XieshiPrivate // // Created by Tesiro on 16/8/5. // Copyright © 2016年 Lessu. All rights reserved. // #import "XSViewSecondController.h" @interface VerifyDetailNewHViewController : XSViewSecondController<UITableViewDelegate,UITableViewDataSource> @property (nonatomic, stro...
# from HW_3.cars import * from cars.world import SimpleCarWorld from cars.agent import SimpleCarAgent from cars.physics import SimplePhysics from cars.track import generate_map import numpy as np import random import argparse parser = argparse.ArgumentParser() parser.add_argument("-s", "--steps", type=int) parser.add...
from bokeh.io import save from bokeh.models import Plot, Range1d, LabelSet, LinearAxis, ColumnDataSource source = ColumnDataSource(data=dict(text=['one', 'two', 'three'], x1=[1,4,7], x2=[60,240,420])) # Have to specify x/y range as labels aren't ...
""" Ory APIs Documentation for all public and administrative Ory APIs. Administrative APIs can only be accessed with a valid Personal Access Token. Public APIs are mostly used in browsers. # noqa: E501 The version of the OpenAPI document: v0.0.1-alpha.3 Contact: support@ory.sh Generated by: http...
from baseDatabaseManager import BaseDatabaseManager class CommentManager(): @staticmethod def increaseProductAmountFromCart(customerId, productId): BaseDatabaseManager.databaseType.increaseProductAmountFromCart(customerId, productId) @staticmethod def isLikeComment(customerId, commentId): ...
// Room: /d/huashan/sgyhole.c inherit ROOM; void create() { set("short", "山洞"); set("long", @LONG 这是一个毫不起眼的山洞,但是里面的石壁上却画满了五 岳剑派所有已经失传的精妙绝招。花岗岩石壁(wall)上很多小 人,全是用利器刻制,想见当初运力之人内力十分深厚。 LONG ); set("exits", ([ /* sizeof() == 4 */ "south" : __DIR__"sgyhole3" ])); set("...
from django.contrib import admin from markdownx.admin import MarkdownxModelAdmin from django.forms import ModelForm, TextInput, CharField from posts.models import Post, Tag from posts import services class PostForm(ModelForm): tags_display = CharField( label="Tags", help_text="Enter comma separa...
# # Copyright 2013, Couchbase, Inc. # All Rights Reserved # # Licensed under the Apache License, Version 2.0 (the "License") # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable l...
# 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 not use ...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _react = _interopRequireDefault(require("react")); var _Icon = _interopRequireDefault(require("../cjs/components/Icon")); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default...
# # Autogenerated by Thrift Compiler (0.13.0) # # DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING # # options string: py # from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException from thrift.protocol.TProtocol import TProtocolException from thrift.TRecu...
/* eslint-disable no-unused-expressions */ const calculator = require('./calculator'); // describe.skip('_check', () => { // beforeEach(() => { // sinon.spy(calculator, '_check'); // }); describe('_check', () => { beforeEach(() => { sinon.spy(calculator, '_check'); }) afterEach(() => { ca...
import { mount, createLocalVue } from '@vue/test-utils'; import BootstrapVue from 'bootstrap-vue'; import { fas } from '@fortawesome/free-solid-svg-icons'; import { library } from '@fortawesome/fontawesome-svg-core'; import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'; import InformationPicker from '@/compon...
/* * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The OpenAirInterface Software Alliance licenses this file to You under * the terms found in...
var lcn = require("../../../../../source/lcn.js"); var rs = lcn.rolesystem; module.exports = function (actionable, game, params) { rs.prototypes.powerfulAttack.reason = "sacrificed by a __Cleric__"; var target = game.getPlayerByIdentifier(actionable.to); if (target.role.role["alignment"] !== "Recruited Praet...
import Reflect from './Reflect.vue' export default Reflect;
from typing import Dict, List, Optional from .constants import Constants from .game_map import Position from .game_constants import GAME_CONSTANTS UNIT_TYPES = Constants.UNIT_TYPES class Player: def __init__(self, team): self.team = team self.research_points = 0 self.units: List[Unit] = ...
# -*- coding: utf-8 -*- # Copyright 2018, IBM. # # This source code is licensed under the Apache License, Version 2.0 found in # the LICENSE.txt file in the root directory of this source tree. # pylint: disable = no-member """ `_text_circuit_drawer` "draws" a circuit in "ascii art" """ import unittest from math imp...
class Solution: def shortestPathAllKeys(self, grid): """ :type grid: List[str] :rtype: int """ m, n = len(grid), len(grid[0]) K = -1 x, y = -1, -1 for i, row in enumerate(grid): for j, val in enumerate(row): if val == '@': ...
const Joi = require('@hapi/joi'); const { password, objectId } = require('./custom.validation'); const createUser = { body: Joi.object({ fullName: Joi.string().required(), phoneNumber: Joi.string().min(11).required(), email: Joi.string().required().email(), password: Joi.string().min(7).required().st...
/* * Copyright (c) 2016-present, Parse, LLC * All rights reserved. * * This source code is licensed under the license found in the LICENSE file in * the root directory of this source tree. */ import * as PushAudiencesStore from 'lib/stores/PushAudiencesStore'; import * as PushConstants from './PushConstants'...
import pytest from jsonschema import ValidationError from mock import MagicMock from connexion.decorators.validation import ParameterValidator from connexion.json_schema import (Draft4RequestValidator, Draft4ResponseValidator) def test_get_valid_parameter(): result = ParameterV...
"use strict"; var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { return new (P || (P = Promise))(function (resolve, reject) { function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } function rejected(value) { try { step(gene...
/** ****************************************************************************** * @file shci.h * @author MCD Application Team * @brief HCI command for the system channel ****************************************************************************** * @attention * * <h2><center>&copy; Copyright (c) 2...
import React, { useEffect, useContext, useState } from "react"; import PropTypes from "prop-types"; import classes from "./ProfileAvatar.module.scss"; import { changeStatusSocketOn } from "../../utils/Sockets/onSockets"; export const ProfileAvatar = ({ profileUrl, isOnlineIcon, isUserActive, userName, }) => { ...
/** * @license * Copyright 2018 Google LLC. All Rights Reserved. * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by a...
def findDecision(obj): #obj[0]: Passanger, obj[1]: Time, obj[2]: Coupon, obj[3]: Gender, obj[4]: Age, obj[5]: Education, obj[6]: Occupation, obj[7]: Bar, obj[8]: Coffeehouse, obj[9]: Restaurant20to50, obj[10]: Direction_same, obj[11]: Distance # {"feature": "Time", "instances": 51, "metric_value": 0.9774, "depth": 1} ...
export const SET_INITIAL_BOARD_DATA = 'SET_INITIAL_BOARD_DATA'; export const SET_FILTERS = 'SET_FILTERS'; export const CREATE_LIST_SUCCESS = 'CREATE_LIST_SUCCESS'; export const CREATE_LIST_FAILURE = 'CREATE_LIST_FAILURE'; export const RECEIVE_BOARD_LISTS_SUCCESS = 'RECEIVE_BOARD_LISTS_SUCCESS'; export const RECEIVE_BOA...
import _ from 'lodash'; import React from 'react'; import {connect} from 'react-redux'; import {Link} from 'react-router-dom'; import {fetchPost} from '../actions/index'; class PostIndex extends React.Component{ componentDidMount(){ this.props.fetchPost(); } renderPosts(){ ...
import os from typing import Any,Optional,List import statsmodels.api as sm import numpy as np from d3m import container, utils as d3m_utils from d3m import utils from numpy import ndarray from collections import OrderedDict from scipy import sparse import os from scipy import stats import numpy import typing import ...
/******************************************************************************* This file is part of FastForward, a browser extension to automatically skip annoying link shorteners. Repo: https://github.com/FastForwardTeam/FastForward */ 'use strict'; /***************************************************...
import React from 'react'; import TestUtils from 'react-dom/test-utils'; import RadioButtonGroup from '../../components/RadioButtonGroup.js'; import {shallow} from 'enzyme'; describe('RadioButtonGroup', function() { it('renders without problems', function() { let wrapper = shallow(<...
//when i click on my button document.getElementById('fillForm').addEventListener('click', function(){ //grab the text filed value from my tool var intValue = document.getElementById('apivalue').value; chrome.tabs.executeScript({ //send the value to be used by our script code: `var value = $...
// Do not edit this file; automatically generated by build.py. 'use strict'; // Copyright 2015 Google Inc. Apache License 2.0 Blockly.PHP=new Blockly.Generator("PHP");Blockly.PHP.addReservedWords("__halt_compiler,abstract,and,array,as,break,callable,case,catch,class,clone,const,continue,declare,default,die,do,echo,e...
import React from 'react'; import { Box, Text, TextArea } from 'grommet'; const JsonData = ({ value, onChange }) => { const [text, setText] = React.useState(JSON.stringify(value, null, 2)); const [error, setError] = React.useState(false); return ( <Box width="medium"> <TextArea rows={20} ...
#include <stdio.h> int main() { int i = 1; while(i <= ); { printf("%d\n", i); i += 1; } return 0; }
""" WSGI config for YoroTime project. It exposes the WSGI callable as a module-level variable named ``application``. For more information on this file, see https://docs.djangoproject.com/en/1.11/howto/deployment/wsgi/ """ import os from django.core.wsgi import get_wsgi_application os.environ.setdefault("DJANGO_SET...
/* copyright 2013 Sascha Kruse and contributors (see LICENSE for licensing information) */ #ifndef DUNST_UTILS_H #define DUNST_UTILS_H #include <glib.h> #include <string.h> //! Test if a string is NULL or empty #define STR_EMPTY(s) (!s || (*s == '\0')) //! Test if a string is non-NULL and not empty #define STR_FULL(s...