text
stringlengths
3
1.05M
import React, { Component } from 'react'; import ReactDOM from 'react-dom'; import assert from 'power-assert'; import ReactTestUtils from 'react-dom/test-utils'; import { dom, KEYCODE, func } from '../../src/util'; import Tree from '../../src/tree/index'; import '../../src/tree/style.js'; /* eslint-disable react/jsx-f...
import Tooltip from 'view/controls/components/tooltip'; import Slider from 'view/controls/components/slider'; import UI from 'utils/ui'; export default class VolumeTooltip extends Tooltip { constructor(_model, name, ariaText, svgIcons) { super(name, ariaText, true, svgIcons); this._model = _model;...
import { observe } from '../observer/index' import Watcher from '../observer/watcher' import { watch } from '../observer/watch' import { initComputed } from '../observer/computed' import { queueWatcher } from '../observer/scheduler' import EXPORT_MPX from '../index' import { noop, proxy, isEmptyObject, isPlainO...
import React from 'react'; import PropTypes from 'prop-types'; import './ImagePreview.scss'; const ImagePreview = ({src}) => { const img = new Image(); img.src = src; const style = { backgroundImage: `url('${img.src}')` }; return ( <span className="image-preview" style={style} /> ); }; ImagePr...
(function() { var statCache = {} function GridFsClient() {} GridFsClient.prototype.stat = function(path) { var dfd = when.defer() if (statCache[path]) { dfd.resolve(statCache[path]) } else { $.get('/stat' + path, function(data) { if (!data.error) { statCache[path] = data return dfd.resolve(data) ...
Template.breadcrumbCustom.helpers({ breadcrumbsContext: function () { return Breadcrumb.getAll(); } })
function Socket(path, operations, onDisconnect) { var loc = window.location; var ws = new WebSocket(path); var closed = false; onDisconnect = undefArg(onDisconnect); ws.onopen = function() { console.info("Web socket connected to " + path + " successfully"); }; ws.onerror = functi...
// Copyright 2018 Google LLC // // 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 ...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Python 3 script template (changeme) """ import logging from pathlib import Path logger = logging.getLogger(__name__) DEFAULT_CONTEXT = Path(__file__).parent.parent / 'data' / 'json' TEMPLATES = { 'feature_collection': { 'type': 'FeatureCollection', ...
import React, { Component, createRef } from 'react'; import { Translate } from 'react-localize-redux'; import styled from 'styled-components'; import classNames from '../../../utils/classNames'; import { ACCOUNT_CHECK_TIMEOUT } from '../../../utils/wallet'; import CheckCircleIcon from '../../svg/CheckCircleIcon'; con...
let dataSource = []; for (i = 1; i <= 170; i++) { dataSource.push(i) } let elem = document.querySelector('.pagination-container'); if (elem) { $(elem).pagination({ dataSource: dataSource, pageSize: 12, pageRange: 1, autoHidePrevious: true, autoHideNext: true, ...
// THIS FILE IS AUTO GENERATED import { GenIcon } from '../lib'; export function IoIosBonfire (props) { return GenIcon({"tag":"svg","attr":{"viewBox":"0 0 512 512"},"child":[{"tag":"path","attr":{"d":"M270.9 350.6c-.7-8.2-7.6-14.6-15.9-14.6-7.6 0-14 5.4-15.6 12.5L223.8 427c-.5 2.3-.8 4.6-.8 7 0 17.7 14.3 30 32 30s32-...
import React, { useState } from 'react' import { KeyboardAvoidingView, StyleSheet, Text, TextInput, TouchableOpacity, View, Image } from 'react-native' import AsyncStorage from '@react-native-async-storage/async-storage'; const LoginScreen = ({navigation}) => { const [correo, setCorreo] = useState(''); const [...
'''Generates the HTML page for the Google Facets Overview for ChestX-ray14. See the "Overview" section in https://pair-code.github.io/facets/. Based on https://github.com/PAIR-code/facets/blob/master/facets_overview/Overview_demo.ipynb. Note that the statistics are embedded in the HTML in BASE64 format. ''' from fac...
"""Key type enum.""" from enum import Enum from typing import NamedTuple, Optional # Define keys KeySpec = NamedTuple( "KeySpec", [("key_type", str), ("multicodec_name", str), ("multicodec_prefix", int)], ) class KeyTypeException(BaseException): """Key type exception.""" class KeyType(Enum): """Ke...
// Copyright (c) 2016, proman_app and contributors // For license information, please see license.txt /* eslint-disable */ frappe.query_reports["Proman Gross Profit"] = { "filters": [ { "fieldname": "company", "label": __("Company"), "fieldtype": "Link", "options": "Company", "reqd": 1, "default":...
const cloud = require('wx-server-sdk'); cloud.init({ env: 'dev-7g313d3r179dfe1c' }); const db = cloud.database(); const _ = db.command; const getRandomStr = function (len = 32) { const $chars = 'abcdefghABCDEFGHIJKLMNOPQRSTUVWXYZ' const maxPos = $chars.length let str = '' for (let i = 0; i < len; i++) { s...
(window.webpackJsonp=window.webpackJsonp||[]).push([[0],{35:function(e,t,i){e.exports=i(65)},41:function(e,t,i){},42:function(e,t,i){},61:function(e,t,i){},62:function(e,t,i){},63:function(e,t){},64:function(e,t,i){},65:function(e,t,i){"use strict";i.r(t);var r=i(0),a=i.n(r),s=i(31),n=i.n(s),o=(i(41),i(7)),h=i(5),c=i(1...
describe('Cooperative Hunting', function() { integration(function() { describe('Cooperative Hunting\'s ability', function() { beforeEach(function() { this.setupTest({ player1: { house: 'untamed', inPlay: ['comman...
export default { name: 'cors', signature: '[COMMAND]', isGroupRoot: true, description: 'Interact with CORS-entries for your project' }
"""add users Revision ID: dee7e2b6f04d Revises: Create Date: 2022-01-23 18:31:58.902114 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'dee7e2b6f04d' down_revision = None branch_labels = None depends_on = None def upgrade(): op.create_table( "us...
(function() { 'use strict'; angular .module('printbluApp') .controller('LogsController', LogsController); LogsController.$inject = ['LogsService']; function LogsController (LogsService) { var vm = this; vm.changeLevel = changeLevel; vm.loggers = LogsService.fi...
import PropTypes from 'prop-types'; const defaultProps = { headers: [], reRenderApiRequest: false, ordering: false, lengthChange: true, searching: true, pageInfo: true, paging: true, currentPage: 1, perPage: 10, order: { column: '', direction: '' }, addQueryParameters: {}, checkboxCh...
/******************************************************************************* * If not stated otherwise in this file or this component's Licenses.txt file the * following copyright and licenses apply: * * Copyright 2018 RDK Management * * Licensed under the Apache License, Version 2.0 (the "License"); ...
/* ========================================================= * bootstrap-datepicker.js * http://www.eyecon.ro/bootstrap-datepicker * ========================================================= * Copyright 2012 Stefan Petre * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this ...
/* YUI 3.6.0pr3 (build 1) Copyright 2012 Yahoo! Inc. All rights reserved. Licensed under the BSD License. http://yuilibrary.com/license/ */ YUI.add('charts-legend', function(Y) { /** * Adds legend functionality to charts. * * @module charts * @submodule charts-legend */ var DOCUMENT = Y.config.doc, TOP = "top", ...
const express = require("express"); const getGenres = require("../db/genres"); const router = express.Router(); router.get("/", async (req, res) => { const data = await getGenres(); res.send(data); }); module.exports = router;
import React from 'react'; import PropTypes from 'prop-types'; import Transition from 'react-transition-group/Transition'; const SlideOutLeft = ({children, in: inProp}) => { const duration = 250; const defaultStyle = { transition: `transform ${duration}ms ease-in-out`, transform: 'translate3d...
import logging from typing import Dict, List from fastapi import HTTPException from pydantic import Field from starlette import status from util import Singleton from .training_runtime import TrainingRuntime logger = logging.getLogger("uvicorn") class TrainingRuntimeService(Singleton): training_runtimes: Dict[...
/** * echarts图表类:地图 * * @desc echarts基于Canvas,纯Javascript图表库,提供直观,生动,可交互,可个性化定制的数据统计图表。 * @author Kener (@Kener-林峰, linzhifeng@baidu.com) * */ define(function (require) { var ComponentBase = require('../component/base'); var ChartBase = require('./base'); // 图形依赖 var TextShape = require('zren...
// I18N constants // LANG: "cz", ENCODING: UTF-8 // // IMPORTANT NOTICE FOR TRANSLATORS // ============================================================================ // // Please be sure you read the README_TRANSLATORS.TXT in the Xinha Root // Directory. Unless you are making a new plugin or module it is unlikely ...
import abc import os.path import math import matplotlib.pyplot as plt from matplotlib.lines import Line2D import rhodium as rdm import seaborn as sns import pandas from lvreuse.cost.tools import cost_reduction_factor from lvreuse.cost.CER_values import CERValues from lvreuse.cost.cost_factors import ElementCostFactors...
import path from 'path'; import fetch from 'node-fetch'; import { writeFile, makeDir } from './lib/fs'; import runServer from './runServer'; // Enter your paths here which you want to render as static // Example: // const routes = [ // '/', // => build/public/index.html // '/page', // => build/publ...
// $(document).ready(function () { // $('#userMgtTable').DataTable(); // $('#blogMgtTable').DataTable(); // $('#categoryMgtTable').DataTable(); // // //hover text // $('[data-toggle="tooltip"]').tooltip(); // // //redirect to specific tab // $('#{{ old('tabMenu') }} a[href="#{{ old('tab') }}...
from __future__ import unicode_literals from django.contrib.contenttypes.fields import ( GenericForeignKey, GenericRelation ) from django.contrib.contenttypes.models import ContentType from django.db import models, connection from django.utils.encoding import python_2_unicode_compatible @python_2_unicode_compati...
// @link http://acme-schemas.triniti.io/json-schema/acme/boost/node/sponsor/1-0-0.json# import Fb from '@gdbots/pbj/FieldBuilder'; import Format from '@gdbots/pbj/enums/Format'; import GdbotsNcrNodeV1Mixin from '@gdbots/schemas/gdbots/ncr/mixin/node/NodeV1Mixin'; import Message from '@gdbots/pbj/Message'; import NodeSt...
const fs = require('fs') const bodyParser = require('body-parser') const jsonServer = require('json-server') const jwt = require('jsonwebtoken') // Express server const server = jsonServer.create() const router = jsonServer.router('mock-server/db.json') const userdb = JSON.parse(fs.readFileSync('mock-server/users.json...
import React, { useState, useEffect } from "react"; import { useParams } from "react-router-dom"; import moodTitleTranslationService from "../utils/moodTitleTranslationService"; import "./mood-help.css"; import Button from "../ui/Button/Button"; import BreathingSVG from "../../public/material-icons/face_white_36dp...
#! /usr/bin/env python import sys ; sys.path.append('/u/ki/awright/InstallingSoftware/pythons/') import imagetools from import_tools import * import numpy numpy.warnings.filterwarnings('ignore') #adam-tmp# warnings.simplefilter("ignore", DeprecationWarning) fl=sys.argv[-1] ending="" #fl='/nfs/slac/g/ki/ki18/anja/SUBARU...
export { default as Alerter } from './Alerter' export { default as Badge } from './Badge' export { Button, ButtonLink } from './Button' export { default as ButtonAction } from './ButtonAction' export { default as I18n, translate } from './I18n' export { default as Icon, Sprite as IconSprite } from './Icon' export { def...
Robot6 = function(x, y, z){ this.timer = 0; this.loop = false; //Root Bone this.head = new THREE.Bone(); this.head.position.x = x; this.head.position.y = y; this.head.position.z = z; this.neck = createBone(0, -10, 0, this.head); this.torso = createBone(0, -25, 0, this.neck); this.left_upper_arm = c...
import React from 'react'; import { mount } from 'enzyme'; import { act } from 'react-dom/test-utils'; import Table from '../src'; describe('Table.FixedHeader', () => { it('switch column', () => { jest.useFakeTimers(); const col1 = { dataIndex: 'light', width: 100 }; const col2 = { dataIndex: 'bamboo', w...
/* 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 this f...
/* Instructions: (1) Refactor .forEach below to create a sequence of Promises that always resolves in the same order it was created. (a) Fetch each planet's JSON from the array of URLs in the search results. (b) Call createPlanetThumb on each planet's response data to add it to the page. (2) Use developer tools...
import imp import os import sys from click.testing import CliRunner from utilities_common.db import Db import config.main as config import show.main as show test_path = os.path.dirname(os.path.abspath(__file__)) modules_path = os.path.dirname(test_path) sys.path.insert(0, test_path) sys.path.insert(0, modules_path) ...
// Copyright 2020, University of Colorado Boulder /** * Returns the list of repos listed in active-repos that are not checked out. * * @author Jonathan Olson <jonathan.olson@colorado.edu> */ const getRepoList = require( './getRepoList' ); const fs = require( 'fs' ); /** * Returns the list of repos listed in act...
new Vue({ //the heart of vue el: '#app', //vue is used on id known as "app" on our html data() { return { array_schools: [], //this will contain our API data ("info") specific_school: [], //this will contain the user input school info } }, mounted() {...
'use strict' const axios = require('axios') const getPort = require('get-port') const semver = require('semver') const agent = require('../../dd-trace/test/plugins/agent') const plugin = require('../src') wrapIt() describe('Plugin', () => { let tracer let restify let appListener describe('restify', () => { ...
// @flow import DataLoader from 'dataloader'; import { map, reduce } from 'ramda'; import fetch from '../fetch'; import key from './key'; import type { Region } from './misc/region'; // todo: have an int or enum variable for season id const season = 'SEASON2017'; const getStatsSummary = (region) => (id) => fetch(...
/** * Test file for Job: time */ var assert = require ('assert'); var time_SUT = require('../time'); var mockedConfig, mockedDependencies; describe ('time test', function(){ beforeEach(function (done) { mockedConfig = { globalAuth: { myconfigKey: { username: "myusername", ...
"""Reporter for training runs This class can be used to store statistics related to the trainign of a classifier. The generated report can be dumped into a JSON file whenever the training completes. A run is a collection of parameters and iterations. The parameters can be added individually or in bulk, with a diction...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * Noop. * * @return {Undefined} */ function noop() {} /** * Export. */ exports.default = noop;
let map; const markers = []; let tempMarker; let lat; let lng; function showPage(pageString) { if (pageString !== 'addspot') window.history.replaceState('', '', `/${pageString}`); switch (pageString.split('/')[0]) { case '': { getPageHTML('frontpage'); break; } default: { getPageHTML...
import React, { Component } from 'react'; import { Box, Text, Heading, TextInput } from 'grommet'; import axios from 'axios'; import userInfo from '../containers/userInfo'; import UserData from '../services/userData.js'; import BadgeDex from '../components/BadgeDex/index.js'; import debounce from 'lodash/debounce'; im...
function SlidesBox(boxNr, boxConf, parentGrid) { //Methods this.init = function () { this.jQueryElement = this.parentGrid.add_widget('<div class="displayBox ' + this.state + '" boxNr="' + this.boxNr + '">' + this.config.content + '</div>', this.positioning.sizeX, this.positioning.sizeY, this.positioning...
const mongoose = require("mongoose"); let dbName = `comingsun`; let dbURI = `mongodb://localhost:27017/${dbName}`; if (process.env.NODE_ENV == "production") { dbURI = process.env.MONGODB_URI; } mongoose.connect(dbURI, { useNewUrlParser: true }); let db = mongoose.connection; db.on("connected", () => console.log(`...
import Consumer from './consumer'; import loadConsumer from './consumer-loader'; export { Consumer, loadConsumer };
/*! jQuery v1.8.3 jquery.com | jquery.org/license */ (function(e,t){function _(e){var t=M[e]={};return v.each(e.split(y),function(e,n){t[n]=!0}),t}function H(e,n,r){if(r===t&&e.nodeType===1){var i="data-"+n.replace(P,"-$1").toLowerCase();r=e.getAttribute(i);if(typeof r=="string"){try{r=r==="true"?!0:r==="false"?!1:r===...
// All symbols with the `Join_Control` property as per Unicode v3.2.0: [ '\u200C', '\u200D' ];
#!/usr/bin/env python3 import argparse import sys import json import os import subprocess import random import matplotlib.pyplot as plt import numpy.random as rand import numpy as np from copy import deepcopy import torch #from pytorch_ddpg.evaluator import Evaluator from pytorch_ddpg.ddpg import DDPG from pytorch_d...
// THIS FILE IS AUTO GENERATED import { GenIcon } from '../lib'; export function GrMap (props) { return GenIcon({"tag":"svg","attr":{"viewBox":"0 0 24 24"},"child":[{"tag":"path","attr":{"fill":"none","stroke":"#000","strokeWidth":"2","d":"M15,15 L19,15 L22,22 L2,22 L5,15 L9,15 M13,8 C13,8.5525 12.5525,9 12,9 C11.447...
import { render, screen } from '@testing-library/react'; //import Hello from './components/Hello'; import { Provider } from 'react-redux'; import store from './redux/store'; // Company------------------------------ import DeleteCompany from './components/company/DeleteCompany'; import GetAllCompany from './components/c...
import React, {Component} from 'react'; import {Link} from 'react-router-dom'; import {SlideMenu} from '../../components/slidemenu/SlideMenu'; import {Button} from '../../components/button/Button'; import {TabView,TabPanel} from '../../components/tabview/TabView'; import {CodeHighlight} from '../codehighlight/CodeHighl...
(function($) { "use strict"; /*chart-employment*/ var chart = c3.generate({ bindto: '#chart-employment', // id of chart wrapper data: { columns: [ // each columns data ['data1', 9, 4, 9, 11, 15, 17], ['data2', 7, 17, 13, 17, 25, 28], ['data3', 18, 19, 22, 21, 32, 28] ], ty...
import React from 'react' import { clone } from './helpers' class SectionCreate extends React.Component { state = {} onSubmit = e => { e.preventDefault() const form = e.target const formData = new window.FormData(form) const name = formData.get('name').trim() const title = formData.get('title'...
'use strict'; const path = require('path'); const os = require('os'); const ensureString = require('type/string/ensure'); const ensureArray = require('type/array/ensure'); const ensurePlainObject = require('type/plain-object/ensure'); const CLI = require('./classes/CLI'); const Config = require('./classes/Config'); co...
var DOC_VERSIONS = [ "dev", ];
# -*- coding: utf-8 -*- # # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets class Ui_DialogLabels(object): def setupUi(self, DialogLabels): DialogLabels.setObjectName("DialogLabels") DialogLabels.resize(714, 463) self.verticalLayout_3 = Qt...
import { createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue" export default function render(_ctx, _cache) { return (_openBlock(), _createElementBlock("svg", { "xmlns": "http://www.w3.org/2000/svg", "width": "24", "height": "24", "viewBo...
# -*- coding: utf-8 -*- """ parser ~~~~~~ Implements Code Parser :author: BlBana <635373043@qq.com> :homepage: https://github.com/wufeifei/cobra :license: MIT, see LICENSE for more details. :copyright: Copyright (c) 2017 Feei. All rights reserved """ from phply import phpast as php ...
# -*- coding: utf-8 -*- """This is a generated class and is not intended for modification! """ from datetime import datetime from infobip.util.models import DefaultObject, serializable from infobip.api.model.omni.Destination import Destination class OmniSimpleRequest(DefaultObject): @property @serializable(...
module.exports = new Date(2018, 9, 20)
const secretProvider = require('./secret-provider'); const providerSocrata = require('@koopjs/provider-socrata'); const outputs = []; const auths = []; const caches = []; const plugins = [{ instance: providerSocrata }, { instance: secretProvider }]; module.exports = [...outputs, ...auths, ...caches, ...plugins];
/** * @function getAllDesktopsForAUserInPool * @version 0.0.0 * @param {string} poolName * @param {string} username * @returns {string} */ function getAllDesktopsForAUserInPool(poolName,username) { var DAConfiguration = System.getModule("com.daimler.actions").getDAConfigurationElement(); var podConfiguration...
import React, { useEffect, useState } from "react"; import MetaTags from "react-meta-tags"; import PropTypes from "prop-types"; import { isEmpty } from "lodash"; import { Button, Card, CardBody, Col, Container, Form, FormFeedback, Input, Label, Modal, ModalBody, ModalHeader, Row, } from "reac...
import styled from "styled-components"; const Rightside = (props) => { return ( <Container> <FollowCard> <Title> <h2>Add to your feed</h2> <img src="/images/feed-icon.svg" alt="" /> </Title> <FeedList> <li> <a> <...
function foo(s) { return /foo/.exec(s); } noInline(foo); for (var i = 0; i < 100000; ++i) { var result = foo("foo"); if (!result) throw "Error: bad result for foo"; if (result.length != 1) throw "Error: bad result for foo: " + result; if (result[0] != "foo") throw "Error: b...
const state = { appName: 'admin', stateValue: 'abc' } export default state
const utils = require('../utils'); module.exports = { getMessagingActionsForOrder:(req_params) => { utils.checkParams(req_params, { query:{ marketplaceIds:{ type:'array' } }, path:{ amazonOrderId:{ type:'string' } } }); return Obj...
module.exports = { siteMetadata: { title: 'Documentation', // https://material.io/tools/icons/?style=baseline navItems: [ { link: '/', text: 'Home', icon: 'face', }, { link: '/projects', text: 'Projects', icon: 'work', }, { link: '/typographyPage', text: 'Typography...
import Comment from '../models/comment'; import sanitizeHtml from 'sanitize-html'; /** * Get all comments * @param req * @param res * @returns void */ export function getComments(req, res) { const offset = parseInt(req.query.offset) || 0; // eslint-disable-line const limit = parseInt(req.query.limi...
const config = { root: '/Users/yan/git/waimai_mfe_duodian/app', rules: [ { test: /.*\.(js|jsx)/, replace: [ { from: 'app/component/common/getEnvHost', to: 'app/tool/getEnvHost', }, { ...
module.exports = app => { const type = require("./type.controller.js"); const authorize = require('_middleware/authorize'); const subUrl = "types"; // Create a new type app.post(`/${subUrl}`, type.create); // Retrieve all type app.get(`/${subUrl}`, type.findAll); // Retrieve a si...
#!/usr/bin/env python # coding: utf-8 # Import os # Import re to do regular expressions import os import re # Open paragraph_1.txt and read it f = open('Resources/paragraph_1.txt', 'r') lines = f.read() # Finding the approximate word count words = re.sub("[\-,><,(),\–,\.]",'',lines).replace('','') wordsplit = re.sp...
(function (global, factory) { typeof module === 'object' && module.exports ? factory(exports, require('external')) : typeof define === 'function' && define.amd ? define(['exports', 'external'], factory) : (factory((global.stirred = {}),global.external)); }(this, (function (exports,external) { 'use strict'; var foo...
//>>built define(["./_BusyButtonMixin","dijit/form/Button","dojo/_base/declare"],function(a,b,c){return c("dojox.form.BusyButton",[b,a],{})});
// a18a900127926b2b18a988310b5d305fd2e25ddaa Don't care about key. // http://api.mywot.com/0.4/public_link_json2?hosts=www.google.com/&callback=process&key=18a900127926b2b18a988310b5d305fd2e25ddaa // var request = new XMLHttpRequest(); // request.onreadystatechange = function() { // if (request.readyState === 4) { ...
'use strict'; var walkSync = require('walk-sync'); var FSTree = require('fs-tree-diff'); var mkdirp = require('mkdirp'); var fs = require('fs'); var debug = require('debug')('tree-sync'); module.exports = TreeSync; function TreeSync(input, output) { this._input = input; this._output = output; this._hasSynced =...
const express = require('express'); const chalk = require('chalk') const debug = require('debug')('app'); const morgan = require('morgan'); const path = require("path"); const app = express(); const PORT = process.env.PORT; app.use(morgan('combined')); app.use(express.static(path.join(__dirname ,"/public/"))); app.s...
#!/usr/bin/env python3 import smbus import time addr=0x23 i2c=smbus.SMBus(1) ## Data read loop # while True: i2c.write_byte(addr, 0x10) time.sleep(0.5) data=i2c.read_i2c_block_data(addr,0x00,2) # print("Raw:",data) print("lx:",(data[0]<<8|data[1])/1.2)
import Vue from 'vue'; var vm; var Tabs = Vue.component('tabs', { template: '#tabs-tpl', data: function () { return { times: [], services: [], selectedServices: [], employeesListByService: [], employeesList: null, activeTab: 0, ...
"use strict"; var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } return new (P || (P = Promise))(function (resolve, reject) { function fulfilled(value) { t...
/*! selectize.js - v0.8.3 | https://github.com/brianreavis/selectize.js | Apache License (v2) */ !function(a,b){"function"==typeof define&&define.amd?define(["jquery","sifter","microplugin"],b):a.Selectize=b(a.jQuery,a.Sifter,a.MicroPlugin)}(this,function(a,b,c){"use strict";var d=function(a,b){if("string"!=typeof b||b...
export const AxisLeft = ({ yScale, yAxisTickFormat, innerWidth, tickOffset = 3 }) => yScale.ticks(4).map(tickValue => ( <g className="tick" transform={`translate(0,${yScale(tickValue)})`}> <line x2={innerWidth} /> <text key={tickValue} style={{ textAnchor: 'end' }} x={-tickOffs...
import numpy as np import cv2 import matplotlib.image as mpimg import pickle from show_original_and_result import * def get_perspective_points( mtx, dist, distace_from_center = 1.9, # distance from the center of the lines distance_meters = 30.0, # distance in the road ahead tvec_x_meters = 0, # ...
# Shaman Rock (1063012/1063013) shooEvil = 2236 charm = 4032263 shamanDict = { 105010100: (0, "100000"), # Humid Swamp 105020000: (1, "010000"), # Sunless Area 105020100: (2, "001000"), # Cave Cliff 105020200: (3, "000100"), # Cold Wind 105020300: (4, "000010"), # Chilly Cave 105020400: (5, "00...
var version = '1.6.8'; Package.describe({ version: version, name: 'keplerjs:tracks', summary: 'keplerjs plugin tracks', git: "https://github.com/Keplerjs/Kepler.git" }); Package.onUse(function(api) { api.use([ 'keplerjs:core@'+version, 'keplerjs:osm@'+version, 'keplerjs:geoinfo@'+version ]); ...
var path = require('path'); var Immutable = require('immutable'); describe('findInstalled', function() { var findInstalled = require('../findInstalled'); it('must list default plugins for gitbook directory', function() { // Read gitbook-plugins from package.json var pkg = require(path.resolve(...
/** * 锤子精灵类 * 由于是单帧图片的,也就不需要去继承精灵类 */ (function() { var Hammer = function() { //锤子position this.x=150; this.y=150; // 设置锤子大小 this.width = 98; this.height = 77; this.image = my.ImageManager.get('hammer'); } Hammer.prototype.draw = function(context,is...
document.write("<a href='/e/public/ClickAd?adid=3' target=_parent><img src='/d/file/2014-11-06/ab93d4726fd97c7472919aa707607472.jpg' border=0 width='370' height='300' alt=''></a>");