text stringlengths 3 1.05M |
|---|
#-*- coding:utf-8 -*-
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtNetwork import *
from uiEvents.AWindowBase import *
from uiDefines.Ui_MainWindow import *
from uiEvents.eventSplashWindow import *
import os
import sys
import pathlib
import datetime
'''
这是MainWind... |
"""
Module: 'ssl' on esp32 1.11.0
"""
# MCU: (sysname='esp32', nodename='esp32', release='1.11.0', version='v1.11-132-gc24d81119 on 2019-07-08', machine='ESP32 module with ESP32')
# Stubber: 1.2.0
def wrap_socket():
pass
|
import React, { Component } from 'react'
import { Link } from 'gatsby'
import Helmet from 'react-helmet'
import Layout from '../components/layout'
import sandDunesElk from '../assets/images/main/DunesMain.jpg'
class Homepage extends Component {
render() {
const siteTitle = 'DataBit Designs'
return (
... |
import logging
from pyvisdk.exceptions import InvalidArgumentError
########################################
# Automatically generated, do not edit.
########################################
log = logging.getLogger(__name__)
def ProviderRegistrationFault(vim, *args, **kwargs):
'''This fault is thrown if failed to... |
"use strict";
const k8s = require("@pulumi/kubernetes");
const appLabels = { app: "nginx" };
const deployment = new k8s.apps.v1.Deployment("nginx", {
spec: {
selector: { matchLabels: appLabels },
replicas: 1,
template: {
metadata: { labels: appLabels },
spec: { conta... |
const remote = require("electron").remote;
const Swal = require('sweetalert2');
const ace = require('ace-builds/src/ace');
var xml_beautify = require('xml-formatter');
const low = require('lowdb');
const FileSync = require('lowdb/adapters/FileSync');
const { ipcRenderer, ipcMain } = require('electron');
const path = re... |
from django.core.management.base import BaseCommand
from query.models import *
from faceDB.open_face_helper import OpenFaceHelper
import random
import json
import tensorflow as tf
import cv2
import os
def load_imgs(img_directory):
imgs = []
for root, subdirs, files in os.walk(img_directory):
for file ... |
# !/usr/bin/python
# -*- coding: UTF-8 -*-
import feedparser
import requests
import ssl
import json
from datetime import datetime
from datetime import timedelta
from translate import translate
try:
from urllib.parse import urlparse
except ImportError:
from urlparse import urlparse, parse_qsl
if hasattr(ssl, ... |
/*
* Copyright (c) 2014 DeNA Co., Ltd.
*
* 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, publ... |
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#else
#ifndef FOUNDATION_EXPORT
#if defined(__cplusplus)
#define FOUNDATION_EXPORT extern "C"
#else
#define FOUNDATION_EXPORT extern
#endif
#endif
#endif
FOUNDATION_EXPORT double Pods_InfinitePageViewControllerVersionNumber;
FOUNDATION_EXPORT const unsigned char Pods_InfinitePa... |
/* globals GBX, VST, THREE, THR, PIN, divDragMoveContent, VSTdetMenu, VSTselStoreys, VSTdivReportsLog, VSTdivSurfaceType */
// jshint esversion: 6
// jshint loopfunc: true
const VST = {
script: {
copyright: "Copyright 2019 Ladybug Tools authors",
date: "2019-07-29",
description: "View the surfaces in a gbXML ... |
/* Compute checksum Author: Johan W. Stevenson */
#include <stdio.h>
int errs;
main(argc, argv)
char **argv;
{
char line[256];
if (argc <= 1)
crc((char *) 0);
else if (argc == 2 && strcmp(argv[1], "-") == 0)
while (fgets(line, sizeof line, stdin) != NULL) {
if (line[strlen(line) - 1] == '\n')
line[st... |
/**
* @fileoverview added by tsickle
* Generated from: src/cdk/tree/padding.ts
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @license
* Copyright Google LLC All Rights Reserved.
*
* Use of this source code is governe... |
# -*- coding: utf-8 -*-
# MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
#
# Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT ARRANTI... |
'''
ModernGL: High performance rendering for Python 3
'''
from .error import *
from .buffer import *
from .compute_shader import *
from .conditional_render import *
from .context import *
from .framebuffer import *
from .program import *
from .program_members import *
from .query import *
from .renderbuffer import... |
jest.autoMockOff();
jest.unmock('../http.js');
const httpfs = require('../http.js');
describe('http', () => {
it('does a lot of cool stuff', () => {
});
});
|
import Collection from '../Collection';
import { deleteCachedLocRange } from '../util/misc';
/**
* @extends {Collection<StaticTrace>}
*/
export default class StaticTraceCollection extends Collection {
// lastStaticContextId = 0;
// lastStaticCodeChunkId = 0;
constructor(dp) {
super('staticTraces', dp);
... |
//define an 3x3 array and fill it with 'x'
let choiceArray = new Array(3).fill('x').map(() => new Array(3).fill('x'));
let count = 0;
//Array that maintains elements to be highlighted in case an player wins
let highlightArray = [];
/**
* Method to validate if inputs coordinates are duplicate or not
* tru... |
/*!
@file textstream_reader.h
@brief textsteam_reader header file
@date 2004/12/17
Time: 23:20:25
@author Ryan Ginstrom
*/
#pragma once
#include "stringex.h"
/** CLASS textstream_reader.
This class is for parsing streams of characters.
It is templated to allow both wide and narrow-character st... |
import React from "react";
import ReactDOM from "react-dom";
import "@patternfly/react-core/dist/styles/base.css";
import OperatorWizard from "./component/operator-wizard/OperatorWizard";
document.addEventListener("DOMContentLoaded", function() {
ReactDOM.render(
React.createElement(OperatorWizard),
document... |
import React from 'react';
import iconSvg from '../icons/normalized/music-note-bluetooth-off.svg';
function IconRender(props) {
const paths = /^\<svg [^>]+\>(.*)<\/svg>/ig.exec(iconSvg)[1]
return (
<svg
{...props}
xmlns="http://www.w3.org/2000/svg"
baseProfile="full"
viewBox="0 0 24 24"... |
# all the imports
import os
import sqlite3
from flask import Flask, request, session, g, redirect, url_for, abort, \
render_template, flash
app = Flask(__name__) # create the application instance :)
app.config.from_object(__name__) # load config from this file , wp_sorter.py
# Load default config and override co... |
/* Price Table Server | tradekit.io
*
* @mudule: timers
*
* Copyright (c) 2019 Milen Bilyanov
* Licensed under the MIT license.
*
*/
'use strict';
// Local Imports
var logging = require('./logging');
var MODULE = 'timers';
// Logging
const log = logging.getLogger();
/** @private getTime() {{{1
*
* Constru... |
# -*- coding: utf-8 -*-
# Copyright 2020 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... |
"use strict";function compressTemplateAttr(e){if(e){if(e.children)for(var t=0,r=e.children.length;t<r;t++){var a=e.children[t];compressTemplateAttr(a)}for(var s in e)if(templateAttrMap[s]){var p=templateAttrMap[s];e[p]=e[s],delete e[s]}}}Object.defineProperty(exports,"__esModule",{value:!0});var templateAttrMap={type:"... |
from .models import *
from rest_framework import serializers
from .serializer_comments import *
read_only_fields_global = (['author'])
class FilmSerializer(serializers.ModelSerializer):
rate_show = serializers.SerializerMethodField()
author_username = serializers.ReadOnlyField(source='author.username')
... |
/* -*- Mode: C; tab-width: 8; c-basic-offset: 2; indent-tabs-mode: nil; -*- */
#include "rrutil.h"
#define NUM_ITERATIONS (1 << 26)
int spin(void) {
int i, dummy = 0;
atomic_puts("spinning");
for (i = 1; i < NUM_ITERATIONS; ++i) {
dummy += i % (1 << 20);
dummy += i % (79 * (1 << 20));
}
return dum... |
import matplotlib.pyplot as plt
import numpy as np
y = 0.5
def fun(b, a):
return -1.5*a*(b*y+y)+1.5
a = np.zeros((200, 200))
for i in range(-100, 100):
for j in range(-100, 100):
a[i - 100, j - 100] = fun(-i/100, j/100)
print(np.min(a), np.max(a))
plt.imshow(a, cmap='hot', interpolation='nearest')
... |
# coding: utf-8
"""
LUSID API
# Introduction This page documents the [LUSID APIs](https://www.lusid.com/api/swagger), which allows authorised clients to query and update their data within the LUSID platform. SDKs to interact with the LUSID APIs are available in the following languages : * [C#](https://gith... |
"""
////////////////////////////////////////////////////////////////////////////
//
// Copyright (C) NVIDIA Corporation. All rights reserved.
//
// NVIDIA Sample Code
//
// Please refer to the NVIDIA end user license agreement (EULA) associated
// with this source code for terms and conditions that govern your... |
# pylint: disable=W0231,E1101
import collections
from datetime import timedelta
import functools
import gc
import json
import operator
from textwrap import dedent
import warnings
import weakref
import numpy as np
from pandas._libs import Timestamp, iNaT, properties
import pandas.compat as compat
from pandas.compat im... |
import getUsdValue from 'utils/getUsdValue'
import useHederaPrice from 'hooks/useHederaPrice'
import fetchEnvironment from 'utils/getEnvironment'
const getIdForDragonglassExplorer = transactionid => {
const hashWithoutPeriods = transactionid.split('.').join('')
const hashWithoutSymbol = hashWithoutPeriods.split('@... |
import express from 'express'
import getRequestData from '../utils/get-request-data'
import { httpHeader, statusCode } from '../utils/http-header'
import quizService from './quiz-service'
const quizRouter = express.Router()
quizRouter.post('/createquiz', async (req, res)=> {
console.log("POST /createquiz")
const ... |
import React, { useContext, useState } from 'react';
import './index.css';
import DataAreaContext from '../../utils/DataAreaContext';
import Lib from '../../utils/Lib';
import { Offcanvas, Button, Form, FloatingLabel } from 'react-bootstrap';
import { orderBy } from "lodash";
import moment from 'moment';
let isEmpty = ... |
import hashlib, os, requests, struct, wx, webbrowser
import winreg as reg
from bs4 import BeautifulSoup
# path = input("Enter file path")
# print("Remove same files")
class FilePro:
path = None
name = None
full_path = None
type = None
def __init__(self, path, name):
self.path = path
... |
// 데이터 타입
// - 원시형 : 단일 데이터 (numebr, string, null, undefined, Symbol)
// - 객체 : 복합 데이터 (object, funtion)
let integer = 123;
let negative = -123;
let double = 1.23;
console.log(integer, negative, double);
let binary = 0b1111011;
let octal = 0o173;
let hex = 0x7b;
console.log(binary, octal, hex);
console.log(123 / "t... |
#ifndef VALUE_DETAIL_ITERATOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66
#define VALUE_DETAIL_ITERATOR_H_62B23520_7C8E_11DE_8A39_0800200C9A66
#if defined(_MSC_VER) || \
(defined(__GNUC__) && (__GNUC__ == 3 && __GNUC_MINOR__ >= 4) || \
(__GNUC__ >= 4)) // GCC supports "p... |
import { StyleSheet } from 'react-native';
const styles = StyleSheet.create({
container: {
flex: 1,
flexDirection: 'column',
justifyContent: 'center',
alignItems: 'stretch',
marginLeft : 30,
marginRight : 30,
},
importButton : {
marginTop : 50
},
topText : {
height : 30,
t... |
g_db.quests[17453]={id:17453,name:"Frigoris 1st Prize",type:0,trigger_policy:0,on_give_up_parent_fail:1,on_success_parent_success:0,can_give_up:1,can_retake:1,can_retake_after_failure:1,on_fail_parent_fail:0,fail_on_death:0,simultaneous_player_limit:0,ai_trigger:0,ai_trigger_enable:0,auto_trigger:0,trigger_on_death:0,r... |
// @flow
import * as actions from '../actions/actionTypes';
type PostAction = {
type: string,
posts?: Array<any>,
postData?: any,
deletedPostId?: string
};
const postsReducer = (state: any = {}, action: PostAction) => {
switch (action.type) {
case actions.NEW_POST:
case actions.UPDATE_POST:
cas... |
import React, { useState } from "react";
import Spinner from "../Spinner/Spinner";
import LoginForm from "../LoginForm/LoginForm";
import Chart from "../Chart/Chart";
import FieldContainer from "../FieldContainer/FieldContainer";
import Styles from "./Admin.module.css";
const Admin = (props) => {
const [fieldType, s... |
"""
Generate and compile C modules for Python.
"""
import atexit
import distutils.sysconfig
import importlib
import logging
import os
import pickle
import platform
import re
import shutil
import stat
import subprocess
import sys
import tempfile
import textwrap
import time
import warnings
from io import BytesIO, String... |
load("bf4b12814bc95f34eeb130127d8438ab.js");
load("93fae755edd261212639eed30afa2ca4.js");
// Copyright (c) 2012 Ecma International. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
es5id: 15.4.4.18-3-14
description: Array.prototype.forEach - 'length' is a string contai... |
cid = input('Digite a cidade que voce nasceu:').strip()
separado = cid.split()
palavra = separado[0].upper()
print(palavra == 'SANTO') |
from .datatypes import DATATYPES_STRUCTS
FIELDS = {
'ABS_1': ('sequence', DATATYPES_STRUCTS['XCN'], 'XCN', 'DISCHARGE_CARE_PROVIDER', 'HL70010', -1),
'ABS_2': ('sequence', DATATYPES_STRUCTS['CE'], 'CE', 'TRANSFER_MEDICAL_SERVICE_CODE', 'HL70069', -1),
'ABS_3': ('sequence', DATATYPES_STRUCTS['CE'], 'CE', 'S... |
import datetime, random, requests
import pytz
import serial
class SerialWorker():
'''
Dedicated serial worker "lil jon" who always keeps an eye on the serial port
'''
def __init__(self):
super().__init__()
self.new=False
self.command=''
self.buff=''
self.die=... |
import React from 'react'
import { Box } from '@chakra-ui/core'
import Image from './image'
export default ({logo, logoDescription}) => (
<Box mb="15px">
<Box
w="44px"
h="44px"
borderRadius="50%"
overflow="hidden"
display="inline-block"
verticalAlign="top"
>
<Image ... |
/*
* Эмулятор советских ПМК для iOS -- (c) Xen, 2014
*
* emu_rom.swift
* ПЗУ микроконтроллеров К745ИК13
*
*/
#import "inttypes.h"
// Общая структура
struct ROM
{
uint32_t micro [68]; // микрокоманды
uint32_t macro [256]; // макрокоманды
uint8_t synchro[1152]; // синхрокоманды
};
struct ROM mc... |
# Copyright The PyTorch Lightning team.
#
# 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 i... |
//导入核心模块http
var http = require('http');
/**
* 1. 能在特定的IP 特定端口上监听 客户端的请求
* 2. 当请求到来的时候能执行监听函数,并返回响应
*
* 创建一个服务器
* 指定监听函数 每当有客户端请求到来的时候执行的函数
* request 代表客户端的请求,可以从中获取请求过来的信息
* response 代表向客户端发的响应,可以通过它向客户端发响应
*
*/
var fs = require('fs');
var mime = require('mime');
var path = require('path');
//node亲生的模块,帮助我们解析... |
// @flow
import * as React from 'react'
import {connect, type TypedState} from '../../util/container'
import Splash from './splash/container'
import Intro from './intro/container'
const mapStateToProps = (state: TypedState, {navigateAppend}) => ({bootStatus: state.config.bootStatus})
const mapDispatchToProps = (dispat... |
"""
Django settings for app project.
Generated by 'django-admin startproject' using Django 3.2.8.
For more information on this file, see
https://docs.djangoproject.com/en/3.2/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.2/ref/settings/
"""
from pathlib imp... |
(window.webpackJsonp=window.webpackJsonp||[]).push([[7],{155:function(t,e,r){"use strict";function n(){return(n=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t}).apply(this,arguments)}r.d(e,"a",function(){re... |
import numpy as np
import matplotlib.pyplot as plt
from xas.file_io import load_binned_df_from_file
import time as ttime
from xas.fitting import fit_gaussian_with_estimation, fit_gaussian, Nominal2ActualConverter
# from lmfit.models import GaussianModel, LinearModel
# _gmodel = GaussianModel() + LinearModel()
class V... |
from django.conf.urls import url
from . import constants, views # isort:skip
urlpatterns = [
url(
r'^create-alias/$',
views.create_alias_view,
name=constants.CREATE_ALIAS_URL_NAME,
),
url(
r'^aliases/$',
views.CategoryListView.as_view(),
name=constants.CA... |
import React from 'react';
import ReactDOM from 'react-dom';
import App from './App';
ReactDOM.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('root')
);
// If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals... |
'use strict';
var _ = require('lodash');
var BN = require('../crypto/bn');
var BufferUtil = require('../util/buffer');
var BufferReader = require('../encoding/bufferreader');
var BufferWriter = require('../encoding/bufferwriter');
var Hash = require('../crypto/hash');
var JSUtil = require('../util/js');
var $ = requir... |
import logging
from classy_vision.meters import ClassyMeter, register_meter
from classy_vision.generic.distributed_util import all_reduce_sum, gather_from_all
from vissl.config import AttrDict
from vissl.utils.env import get_machine_local_and_dist_rank
import numpy as np
import torch
import torch.nn.functional as F
... |
function MapRoute(lat, lng) {
var pointA = new google.maps.LatLng(10.7736594,106.7004169),
pointB = new google.maps.LatLng(lat, lng),
myOptions = {
zoom: 7,
center: pointA
},
map = new google.maps.Map(document.getElementById('map-canvas'), myOptions),
... |
# -*- coding: utf-8 -*-
###########################################################################
# Copyright (c), The AiiDA team. All rights reserved. #
# This file is part of the AiiDA code. #
# ... |
# ==============================================================================
# Copyright (c) Microsoft. All rights reserved.
# Licensed under the MIT license. See LICENSE.md file in the project root
# for full license information.
# ==============================================================================
'''... |
"""
Python Markdown
===============
Python Markdown converts Markdown to HTML and can be used as a library or
called from the command line.
## Basic usage as a module:
import markdown
md = Markdown()
html = md.convert(your_text_string)
## Basic use from the command line:
markdown source.txt > desti... |
r"""
Subsets
The set of subsets of a finite set. The set can be given as a list or a Set
or else as an integer `n` which encodes the set `\{1,2,...,n\}`.
See :class:`Subsets` for more information and examples.
AUTHORS:
- Mike Hansen: initial version
- Florent Hivert (2009/02/06): doc improvements + new methods
"""
... |
/*
*
* Copyright 2015 gRPC authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agree... |
"""Support for Russound multizone controllers using RIO Protocol."""
from __future__ import annotations
from russound_rio import Russound
import voluptuous as vol
from homeassistant.components.media_player import PLATFORM_SCHEMA, MediaPlayerEntity
from homeassistant.components.media_player.const import (
MEDIA_TY... |
from abc import ABC, abstractmethod
from typing import Callable, Optional
from bs4 import BeautifulSoup as BS
import json
from requests import Response
class ApiResponse(ABC):
response: Response
def __init__(self, response: Response) -> None:
super().__init__()
self.response = response
@... |
###############################################################################
#
# Tests for XlsxWriter.
#
# Copyright (c), 2013-2017, John McNamara, jmcnamara@cpan.org
#
from ..excel_comparsion_test import ExcelComparisonTest
from ...workbook import Workbook
class TestCompareXLSXFiles(ExcelComparisonTest):
"""... |
import sys,os,argparse,time
import numpy as np
import torch
import torch.nn as nn
from torch.utils.tensorboard import SummaryWriter
import utils
tstart=time.time()
# Arguments
parser=argparse.ArgumentParser(description='xxx')
parser.add_argument('--seed',type=int,default=0,help='(default=%(default)d)')
parser.add_... |
#
# number.py : Number-theoretic functions
#
# Part of the Python Cryptography Toolkit
#
# Written by Andrew M. Kuchling, Barry A. Warsaw, and others
#
# ===================================================================
# The contents of this file are dedicated to the public domain. To
# the extent that dedicati... |
"use strict";
var app;
function setup() {
app = new App("Curtains with holes 2",540,540, "svg");
//first parameter, string with images comma-separated
//second parameter, string with sounds comma-separated
app.loadResources("mosterd.png");
}
function draw() {
var i;
if(app.isloaded) {
... |
import { Cartesian2 } from '../../Source/Cesium.js';
import { Cartesian3 } from '../../Source/Cesium.js';
import { Cartesian4 } from '../../Source/Cesium.js';
import { Math as CesiumMath } from '../../Source/Cesium.js';
import { Matrix4 } from '../../Source/Cesium.js';
import { PerspectiveFrustum } from '../../Source/C... |
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='InputRequest',
fields=[
('id', models.AutoField... |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import BaseAPI
from Login import Logincontrol
import re
from bs4 import BeautifulSoup
from pymongo import MongoClient
import json
import time
import json
class Account(object):
"""docstring for Account"""
def __init__(self):
super(Account, self).__init__()
self.sess... |
window.onload = () => {
document.getElementById('save-button').addEventListener('click', function () {
storeSetting()
})
checkSetting()
}
function storeSetting() {
const EnglishDisabled = !document.getElementById('lang-english-checkbox').checked
const KoreanDisabled = !document.getElementById('lang-korea... |
#
# Licensed Materials - Property of IBM
#
# (c) Copyright IBM Corp. 2007-2008
#
import unittest, sys
import ibm_db
import config
from testfunctions import IbmDbTestFunctions
class IbmDbTestCase(unittest.TestCase):
def test_133_ExecuteLongInputParams(self):
obj = IbmDbTestFunctions()
obj.assert_expectf(... |
from .lib.middleware import I18nMiddleware, SpyMiddleware
from .config import LOCALES_DIR
from .bot import dp
i18n = I18nMiddleware("bot", LOCALES_DIR, default="ru")
dp.middleware.setup(i18n)
dp.middleware.setup(SpyMiddleware())
_ = i18n.t
|
module.exports = (data) => {
return {
testMiddleware(req, res, next) {
console.log("testmiddleware")
next();
},
}
}
|
import struct
import zipfile
import numpy as np
import zengl
from PIL import Image
import assets
from window import Window
window = Window(1280, 720)
ctx = zengl.context()
pack = zipfile.ZipFile(assets.get('metal_plate_1k.gltf.zip'))
img1 = Image.open(pack.open('textures/metal_plate_diff_1k.jpg')).convert('RGBA')
i... |
/*
* Copyright (C) 2009-2010 Christian Hergert <chris@dronelabs.com>
* Copyright © 2010 Codethink Limited
*
* 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... |
import warning from 'warning';
import debounce from 'lodash.debounce';
import mixin from '../../globals/js/misc/mixin';
import createComponent from '../../globals/js/mixins/create-component';
import initComponentBySearch from '../../globals/js/mixins/init-component-by-search';
import on from '../../globals/js/misc/on';... |
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* parse.c :+: :+: :+: ... |
// ddlist.js
// 2017-12-08
// Copyright (c) 2017 Nimzozo
window.addEventListener("load", function () {
"use strict";
/**
* Css classes and ids.
*/
var css = {
header: "drop-down-header",
item: "drop-down-list__item",
link: "drop-down-list__link",
list: "drop-d... |
#! /usr/bin/env node
const program = require('commander');
const fs = require('fs')
const command_new = require('./commands/new');
const command_init = require('./commands/init');
program
.command('new [title]')
.alias('n')
.description("Create a new project and generate it's boilerplate")
.action(function(t... |
import logging
logger = logging.getLogger(__name__)
#debug = logger.debug
#loginfo = logger.info
#logmsg = logger.info
def _getstr(args):
try:
return ' '.join(str(a) for a in args)
except:
return ' '.join(unicode(a) for a in args)
def loginfo(*args):
ss = _getstr(args)
logger.info(ss)
... |
////////////////////////////////////////////////////////////////////////////////
// Pac-Man clone
//
// Copyright (c) 2021 Kwena Mashamaite (kwena.mashamaite1@gmail.com)
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Softwa... |
import React, {useState, useEffect} from 'react'
import Layout from '../components/layout'
import Nav from '../components/nav'
import Banner from '../components/non-front-banner'
import AuthorImg from '../../static/author/main_author.jpg'
/*Slick*/
import Slider from "react-slick";
// Import css files
import "slick-c... |
// eslint-disable-next-line
import { default as component } from './Bool.vue'
import { compose } from '@cortezaproject/corteza-js'
import * as fieldTypes from './loader'
console.log(fieldTypes)
// const namespace = ({
// canCreateChart: true,
// canCreateModule: true,
// canCreatePage: true,
// canDeleteNamesp... |
# --------------
# Code starts here
# Create the lists
class_1 = ['Geoffrey Hinton','Andrew Ng','Sebastian Raschka','Yoshua Bengio']
class_2 = ['Hilary Mason','Carla Gentry','Corinna Cortes']
# Concatenate both the strings
new_class = class_1 + class_2
#print(new_class)
# Append the list
new_class.append('Pe... |
from tkinter import *
root = Tk()
def myclick():
myLabel = Label(root,text= 'Look! I clicked a button ')
myLabel.pack()
myButton = Button(root , text='Click Me' , padx=50 , pady= 50, command=myclick)
myButton.pack()
root.mainloop() |
function ready(fn) {
if (document.readyState != 'loading'){
fn();
} else {
document.addEventListener('DOMContentLoaded', fn);
}
}
function loadReusableComponents() {
//insert elements, even before Polymer is loaded
//first element of the original document
var firstElement = document.body.children[... |
import os.path as osp
from unittest import TestCase
from pylinac.log_analyzer import VMAT, IMAGING, STATIC_IMRT, DYNAMIC_IMRT
from tests_basic.test_logs import IndividualLogBase
from tests_basic import TEST_BANK_DIR
class LogBankBase(IndividualLogBase):
dir_location = osp.join(TEST_BANK_DIR, 'Machine logs')
cl... |
import _ from 'lodash'
import faker from 'faker'
import React from 'react'
import { Search, Grid, Header, Segment } from 'semantic-ui-react'
const source = _.times(5, () => ({
title: faker.company.companyName(),
description: faker.company.catchPhrase(),
image: faker.internet.avatar(),
price: faker.finance.amou... |
!function(e){function t(r){if(n[r])return n[r].exports;var a=n[r]={exports:{},id:r,loaded:!1};return e[r].call(a.exports,a,a.exports,t),a.loaded=!0,a.exports}var n={};return t.m=e,t.c=n,t.p="",t(0)}([function(e,t,n){e.exports=n(1)},function(e,t,n){"use strict";n(2);var r=n(7),a=n(163);r.render(r.createElement(a,null),d... |
/*
* Copyright (c) 2019 Antmicro Ltd
*
* Copyright (c) 2019 Intel Corporation
*
* SPDX-License-Identifier: Apache-2.0
*/
#ifndef ZEPHYR_INCLUDE_NET_SOCKS_H_
#define ZEPHYR_INCLUDE_NET_SOCKS_H_
#include <zephyr/net/socket.h>
/**@brief Connects to destination through a SOCKS5 proxy server.
*
* @param[in] ctx N... |
'use strict';
const utils = require('./utils');
const webpack = require('webpack');
const config = require('../config');
const merge = require('webpack-merge');
const path = require('path');
const baseWebpackConfig = require('./webpack.base.conf');
const CopyWebpackPlugin = require('copy-webpack-plugin');
const HtmlWeb... |
from django.urls import path
from django.views.generic import TemplateView, RedirectView
from . import views
urlpatterns = [
path('', views.index, name='main'),
path('contacts', views.contacts, name='contacts'),
path('yandex_2076966e8ed47beb.html', TemplateView.as_view(template_name='main/yandex_2076966e8... |
import datetime
from functools import partial
import json
import logging
import os
import platform
import re
import shutil
import sys
import tempfile
from dateutil.relativedelta import relativedelta
from gql import Client, gql
from gql.client import RetryError
from gql.transport.requests import RequestsHTTPTransport
i... |
//Var
var lastReceivedNotificationID = 0
var notificationsCount = 0;
//Hide Notifications Modal
function HideNotificationsModal() {
$('#mdlNotifications').modal('hide');
};
//Get List
function LoadPart_UserNotificationsListDiv() {
var loadingpart = LoadDivLoading();
$("#divNotificationsArea").html(loadin... |
import React from 'react'
import styles from './styles.scss'
import classnames from 'classnames/bind'
const cx = classnames.bind(styles)
export default function CoinFrame(props) {
return (
<div className={cx('coin-frame')}>
<span></span>
</div>
)
} |
/*=auto=========================================================================
Portions (c) Copyright 2005 Brigham and Women's Hospital (BWH) All Rights Reserved.
See COPYRIGHT.txt
or http://www.slicer.org/copyright/copyright.txt for details.
Program: 3D Slicer
Module: $RCSfile: vtkMRMLVolumeNode.h,... |