text stringlengths 3 1.05M |
|---|
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
print('##/// IMPORT ///##')
##/// DEPENDENCIES
import typing
import discord
import logging
import datetime
import time
print('##/// [05] ///##')
import asyncio
from discord.ext import commands
from discord.ext.commands import Bot
from importlib import reload
import asy... |
var falafel = require('falafel');
var through = require('through');
module.exports = function (file, opts) {
if (typeof file === 'object') {
opts = file;
file = undefined;
}
if (!opts) opts = {};
var outputFn = opts.output || 'console.log';
var output = through();
var expec... |
import React from "react";
import Aboutus from "../components/about-us";
import Aboutje from "../components/about-us-JEconcept";
import Collaborate from "../components/work-with-us";
import Team from "../components/team";
import Infoecole from "../components/info-ecole";
export default function Components(props) {
... |
import { prefix, getStores } from '../../utils/util.js';
Page({
/**
* 页面的初始数据
*/
data: {
prefix,
stores: []
},
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) {
this.setData({
longitude: options.longitude,
latitude: options.latitude,
})
},
search: function (e)... |
from __future__ import division
import os
import cv2
import dlib
from .eye import Eye
from .calibration import Calibration
"""
class that tracks the user's gaze.
"""
class GazeTracking(object):
"""
This class tracks the user's gaze.
It provides useful information like the position of the eyes
and pupil... |
module.exports = [
{
title: 'html & css',
path: '/html-css',
children: [
{
title: 'html',
path: '/html-css/html'
},
{
title: 'css',
path: '/html-css/css'
}
]
},
{
title: 'JS基础(ECMA 262标准)',
path: '/js',
children: [
{
... |
webpackJsonp([22],{1250:function(i,t,e){var o=e(966);"string"==typeof o&&(o=[[i.i,o,""]]),o.locals&&(i.exports=o.locals);e(563)("7ea677da",o,!0)},1260:function(i,t){i.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACgAAAAoCAYAAACM/rhtAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyNpVFh0WE1MOmNvbS5hZG9iZS... |
(function(e){const i=e["en-gb"]=e["en-gb"]||{};i.dictionary=Object.assign(i.dictionary||{},{"%0 of %1":"%0 of %1",Aquamarine:"Aquamarine",Black:"Black",Blue:"Blue",Bold:"Bold","Bulleted List":"Bulleted List",Cancel:"Cancel","Choose heading":"Choose heading","Dim grey":"Dim grey",Downloadable:"Downloadable","Dropdown to... |
const app = new Vue({
el: '#app',
data: {
config: null,
offline: false,
filter: '',
vlayout: true,
isDark: null,
showMenu: false
},
created: async function () {
let that = this;
this.isDark = 'overrideDark' in localStorage ?
JS... |
from typing import Pattern
import numpy as np
import pandas as pd
import glob
import matplotlib.pyplot as plt
import seaborn as sns
class DataHandler(object):
"""
Loads, formats, and displays data
"""
def __init__(self) -> None:
self._loadData()
self._createDataSets()
... |
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = _default;
var _lodash = _interopRequireDefault(require("lodash"));
var _postcss = _interopRequireDefault(require("postcss"));
var _escapeClassName = _interopRequireDefault(require("../utils/escapeClassName"));
function... |
(function(angular, $, _) {
angular.module('extendedreport').config(function($routeProvider) {
$routeProvider.when('/exreport/report/:id', {
controller: 'ExtendedreportReportCntrl',
templateUrl: '~/extendedreport/ReportCntrl.html',
// If you need to look up data when opening the page, l... |
var URL = 'http://127.0.0.1:8080/';
// Script to open and close sidebar
function w3_open() {
document.getElementById("mySidebar").style.display = "block";
}
function w3_close() {
document.getElementById("mySidebar").style.display = "none";
}
function insert(){
document.getElementById("mySi... |
const fs = require('fs')
const bodyParser = require('body-parser')
const jsonServer = require('json-server')
const jwt = require('jsonwebtoken')
const server = jsonServer.create()
const router = jsonServer.router('./db.json')
const loginSuccess = JSON.parse(fs.readFileSync('./sample/login/success.json', 'UTF-8'))
cons... |
import { imageSnapshotOptions, timeouts } from './constants.json';
import minNumActivitiesShown from './setup/conditions/minNumActivitiesShown';
import negationOf from './setup/conditions/negationOf';
import scrollToBottomButtonVisible from './setup/conditions/scrollToBottomButtonVisible';
import scrollToBottomComplet... |
# Copyright 2015-2021 Espressif Systems (Shanghai) CO 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 ... |
import pytest
from nested_diff.fmt import HtmlFormatter
import tests.data.formatters
import tests.data.formatters.HtmlFormatter
from tests.common import do_test_function, iterate_test_suite
def function_to_test(test):
formatter = HtmlFormatter(**test.get('formatter_opts', {}))
return formatter.format(test... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _zosLib = require('zos-lib');
const log = new _zosLib.Logger('EventsFilter');
const TIMEOUT_ERROR = 'Event filter promise timed out';
class EventsFilter {
constructor(timeout) {
this.timeout = timeout || (process.env.NODE_ENV =... |
# -*- coding: utf-8 -*-
from django.contrib import admin
from django.contrib.admin import ModelAdmin
from django.forms import Media
from django.template.defaultfilters import striptags
from django.template.loader import render_to_string
from editregions.admin.modeladmins import ChunkAdmin
from editregions.contrib.text.... |
import React from 'react';
import { withTracker } from 'meteor/react-meteor-data';
import Questionnaires from '../../api/questionnaires/questionnaires';
import Questions from '../../api/questions/questions';
import GameQuestion from './GameQuestion';
import Tracker from '../components/Tracker';
class Game extends R... |
var Component = require("../../model/Component");
Component.registerSubTypeDefaulter('dataZoom', function () {
// Default 'slider' when no type specified.
return 'slider';
}); |
/**
* This is a file containing constants for all the top level keys in our store
*/
export default {
// Holds information about the users account that is logging in
ACCOUNT: 'account',
// Holds an array of client IDs which is used for multi-tabs on web in order to know
// which tab is the leader, an... |
export const normalize = obj =>
Object.entries(obj).reduce((obj, [key, value]) => {
if (key.match(/[A-Z]/))
key = key.replace(/[A-Z]/g, x => `-${x.toLowerCase()}`);
obj[key] = value;
return obj;
}, {});
|
!function t(e,n,i){function r(s,a){if(!n[s]){if(!e[s]){var c="function"==typeof require&&require;if(!a&&c)return c(s,!0);if(o)return o(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var u=n[s]={exports:{}};e[s][0].call(u.exports,function(t){var n=e[s][1][t];return r(n?n:t)},u,u.ex... |
/**
* This defines the static resources the server will serve.
* @author Cameron Burkholder
* @date 07/31/2021
*/
const StaticResources = {
CustomServiceWorker: "custom-service-worker.js",
DefaultServiceWorker: "service-worker.js",
Index: "index.html"
};
module.exports = StaticResources;
|
/* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. */
/******************************************************************************
*
* You may not use the identified files except in compliance with the Apache
* License, Version 2.0 (the "License.")
*
* You may obtain a copy of the... |
# -*- coding: utf-8 -*-
# Define your item pipelines here
#
# Don't forget to add your pipeline to the ITEM_PIPELINES setting
# See: http://doc.scrapy.org/en/latest/topics/item-pipeline.html
class PodcastPipeline(object):
def process_item(self, item, spider):
return item
|
import React from "react";
// nodejs library that concatenates classes
import classNames from "classnames";
// nodejs library to set properties for components
import PropTypes from "prop-types";
// @material-ui/core components
import { makeStyles } from "@material-ui/core/styles";
import AppBar from "@material-ui/core/... |
from urllib.parse import urlparse
def is_url(url):
try:
result = urlparse(url)
return all([result.scheme, result.netloc])
except ValueError:
return False
|
import itertools
import json
import numpy as np
import pandas as pd
import math
import torch
import torch.nn as nn
import torch.nn.functional as F
from numpyencoder import NumpyEncoder
import optuna
from src.config import cfg
from src.data import preprocess
from src.utils import gen
from src.utils import metrics
from... |
from typing import Set, Dict, Any
import random
from . import RandomPolicy
from src.mdp import MarkovDecisionProcedure
class QTablePolicy:
def __init__(self, initial_value_estimate: float = 0.0):
self._q_table: Dict[Any, Dict[Any, float]] = dict()
self.initial_value_estimate: float = initial_val... |
const Discord = require("discord.js");
const bot = new Discord.Client();
const snek = require('snekfetch');
const fsn = require('fs-nextra');
exports.run = async (client, message, args) => {
if (!message.guild.member(client.user).hasPermission('ATTACH_FILES')) return message.reply('Sorry, i dont have the perms t... |
# Copyright 2022 The TensorFlow Authors. 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 applica... |
/******/ (() => { // webpackBootstrap
/******/ "use strict";
/******/ var __webpack_modules__ = ({
/***/ "../demo4/src/sass/pages/login/login-2.scss":
/*!**************************************************!*\
!*** ../demo4/src/sass/pages/login/login-2.scss ***!
\**************************************************/... |
from smt.Z3 import *
import unittest
from AuthConfidentiality import Authentication, Principal
import JeevesLib
class TestAuthConfidentiality(unittest.TestCase):
def setUp(self):
JeevesLib.init()
self.alicePwd = "alicePwd"
self.bobPwd = "bobPwd"
self.aliceUser = Principal.User(1, "Alice", self.aliceP... |
//
// Test of sample big polygon functionality
//
var coll = db.geo_big_polygon;
coll.drop();
// coll.ensureIndex({ loc : "2dsphere" });
coll.getMongo().getDB("admin").runCommand({setParameter: 1, verboseQueryLogging: true});
var bigCRS = {type: "name", properties: {name: "urn:x-mongodb:crs:strictwinding:EPSG:4326"... |
import torch
import torch.nn.functional as F
from wordnet.resnet import resnet18
from wordnet.coding import MapOrdering
from wordnet.utils import compute_scale_down
class UpscaleAndConcatLayer(torch.nn.Module):
"""
take small map with cx channels
upscale to size of large map (s*s)
concat large map wi... |
from .model import OnnxModel
from .model_loader import ModelLoader
__all__ = [
"ModelLoader",
"OnnxModel",
]
|
window.addEventListener('design-register-element', function () {
'use strict';
registerDesignSnippet('<gs-jumbo>', '<gs-jumbo>', 'gs-jumbo>\n' +
' ${0}\n' +
'</gs-jumbo>');
... |
import numpy as np
from skmultiflow.data.base_stream import Stream
from skmultiflow.utils import check_random_state
class LEDGenerator(Stream):
""" LED stream generator.
This data source originates from the CART book [1]_. An implementation
in C was donated to the UCI [2]_ machine learning repository by ... |
const comparatorLookup = {
Equal: "equals",
NotEqual: "not equals",
GreaterThan: "greater than",
GreaterOrEqual: "greater than or equal to",
LessThan: "less than",
LessOrEqual: "less than or equal to"
};
class NumberRoutingCondition {
constructor(condition) {
this.condition = condition;
}
buildR... |
import React, { Component } from "react";
import pluginListDecorator from "./pluginListDecorator";
import ToolbarIcon from "@canner/slate-icon-shared";
import { OL_LIST } from "@canner/slate-constant/lib/blocks";
@pluginListDecorator(OL_LIST, "ListOrdered")
export default class OlList extends Component {
render() {
... |
/*
Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.lang['sl']={"editor":"Bogat Urejevalnik Besedila","editorPanel":"Rich Text Editor plošča","common":{"editorHelp":"Pritisnite ALT 0 za pomoč","browseServer":"Prebrs... |
import React from 'react';
import PropTypes from 'prop-types';
import { withStyles } from '@material-ui/core/styles';
const styles = theme => ({
root: {
width: '100%',
marginTop: theme.spacing.unit * 4,
marginRight: theme.spacing.unit * 2,
},
affected: {
textAlign: 'right',
},
unaffected: {
... |
export const proejctEnums = {
html: "HTML",
css: "CSS",
javascript: "Javascript",
react: "React",
vueJS: "VueJS",
angularJS: "AngularJS",
bootstrap: "Bootstrap",
jquery: "jQuery",
}
export const devRolesEnum = {
uiDev: "UI Developer",
frontendDev: "Frontend Developer",
uiuxDev: "UI/UX developer",
... |
import os
import pprint
import shutil
from sklearn.externals import joblib
from .adapters import take_first_inputs
from .utils import view_graph, plot_graph, get_logger, initialize_logger
initialize_logger()
logger = get_logger()
class Step:
def __init__(self, name, transformer, input_steps=[], input_data=[], ... |
"use strict";
var parser = require('postcss-value-parser');
var list = require('postcss').list;
var uniq = require('../utils').uniq;
var escapeRegexp = require('../utils').escapeRegexp;
var splitSelector = require('../utils').splitSelector;
function convert(value) {
if (value && value.length === 2 ... |
/*
* Http Server wrapper
*
*/
function HttpServer(port){
this._Port = port;
if (typeof HttpServer._initialized === 'undefined'){
////////////////////////////////////////////////////////////////////////////
HttpServer.prototype.start = function(onRequest){
var server = HTTP.createServer(onRequest);
server.list... |
"""Tests for stanford_algorithms.karatsuba."""
from stanford_algorithms import karatsuba
def test_karatsuba():
"""Test for the info function."""
assert karatsuba.karatsuba(1024, 1024) == 1048576
|
# Copyright 2020 Huawei Technologies Co., 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 agreed to... |
export default `
.wizardStep {
padding: 20px 20px 40px 20px;
}
.fieldGroup {
margin-bottom: 16px;
}
`; |
var gulp = require('gulp');
var sass = require('gulp-sass');
var header = require('gulp-header');
var cleanCSS = require('gulp-clean-css');
var rename = require("gulp-rename");
var uglify = require('gulp-uglify');
var autoprefixer = require('gulp-autoprefixer');
var pkg = require('./package.json');
var browserSync = re... |
/* eslint-disable */
import Document from 'next/document';
import {ServerStyleSheet} from 'styled-components';
export default class MyDocument extends Document {
static async getInitialProps(ctx) {
const sheet = new ServerStyleSheet();
const originalRenderPage = ctx.renderPage;
try {
... |
#! /usr/bin/env python
# -*- coding:utf-8 -*-
# __author__ = HSM
import datetime
import time
import json
from send_massage import send_message, phone_up
from apscheduler.schedulers.blocking import BlockingScheduler
import logging
# 配置日志文件和日志级别
ch = logging.StreamHandler()
ch2 = logging.FileHandler('logging.log')
for... |
const path = require('path');
module.exports = {
name: 'Simple Softphone', // replace with your applications human readable name
path: path.basename(__dirname),
controller: 'controller.js',
symbol: 'fas fa-headset' // use classes for Fontawesome fonts here ( https://fontawesome.com/icons?d=gallery&m=free )
};
|
#!/usr/bin/env python3
from test_framework.test_framework import BitcoinTestFramework
from test_framework.util import *
from test_framework.script import *
from test_framework.mininode import *
from test_framework.credit import *
from test_framework.address import *
import time
class CreditManyValueRefundsFromSameTxT... |
/**
* @license Copyright (c) 2003-2019, CKSource - Frederico Knabben. All rights reserved.
* This file is licensed under the terms of the MIT License (see LICENSE.md).
*/
const Redis = require( 'ioredis' );
module.exports = class RedisDriver {
constructor( config ) {
this._config = config;
this._client = null... |
'use strict';
//Writings service used for communicating with the writings REST endpoints
angular.module('records').factory('Cloze', ['$resource',
function ($resource) {
return $resource('api/clozes/:clozeId', {
clozeId: '@_id'
}, {
update: {
method: 'PUT'
}
});
}
]);
|
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.ex... |
macDetailCallback("000f01000000/24",[{"d":"2003-12-21","t":"add","a":"14 MARSHALL LANE\nWESTON CT 06883\n\n","c":"UNITED STATES","o":"DIGITALKS INC","s":"wireshark.org"},{"d":"2015-08-27","t":"change","a":"14 MARSHALL LANE WESTON CT US 06883","c":"US","o":"DIGITALKS INC"}]);
|
const low = require('lowdb');
const bodyParser = require('body-parser');
const uuid = require('uuid');
function setupDb() {
const db = low();
db.defaults({ topics: [], links: [] })
.value();
const topic1 = {
name: 'libraries',
description: 'links to useful open source libraries',
};
const topi... |
from botx import Bot, Message
bot = Bot()
@bot.handler
async def my_handler(message: Message) -> None:
with open("my_file.txt") as f:
await bot.answer_message("Text that will be sent with file", message, file=f)
|
!function(a){"use strict";a('a.js-scroll-trigger[href*="#"]:not([href="#"])').click(function(){if(location.pathname.replace(/^\//,"")==this.pathname.replace(/^\//,"")&&location.hostname==this.hostname){var e=a(this.hash);if((e=e.length?e:a("[name="+this.hash.slice(1)+"]")).length)return a("html, body").animate({scrollT... |
class Solution:
def lengthOfLongestSubstring(self, s: str) -> int:
start = 0
end = 0
if not s:
return 0
unique = set(s[start])
longest = 1
while start < len(s):
if end < start:
end = start
unique.update(s[start])... |
(function() { const icons = { "material/editor/highlight": "M12 28l6 6v10h12V34l6-6V18H12zM22 4h4v6h-4zM7 11.75l2.828-2.828 4.243 4.243-2.82 2.828zm26.923 1.422l4.242-4.242 2.83 2.828L36.75 16z" };
if (JSC) {
JSC.internal.registerIcons(icons);
}
})(); |
const EVENTS = {
search: {
check: e => e.key === 'p' && (e.metaKey || e.ctrlKey),
preventDefault: true,
},
clear: {
check: e => e.key === 'k' && (e.metaKey || e.ctrlKey),
preventDefault: true,
},
nextCard: {
check: e => e.key === 'j' && (e.metaKey || e.ctrlKey),
preventDefault: true,
... |
module.exports = {
name: 'entry-b'
};
|
import * as jqxcore from '../../jqwidgets-scripts/jqwidgets/jqxcore';
import * as jqxdata from '../../jqwidgets-scripts/jqwidgets/jqxdata';
import * as jqxbuttons from '../../jqwidgets-scripts/jqwidgets/jqxbuttons';
import * as jqxscrollbar from '../../jqwidgets-scripts/jqwidgets/jqxscrollbar';
import * as jqxlistmenu ... |
# Copyright 2019 The Cirq Developers
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in ... |
import {connect} from 'react-redux';
import {addImage} from "./redux/reducer";
const Grid = (props) => {
return (
<div id={props.sectionType} className="section">
<div className="image-display">
{props.images.map((image, index) =>
<img key={index} alt="landscape" className={[props.sectionType, "images"... |
'use strict';
function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }
var assign = require('lodash').assign;
var attachHook = require('./attachHook');
var dirname = require('path... |
/*****************************************************************************
* Open MCT Web, Copyright (c) 2014-2015, United States Government
* as represented by the Administrator of the National Aeronautics and Space
* Administration. All rights reserved.
*
* Open MCT Web is licensed under the Apache License, ... |
function updateSliceProperties(store) {
const visualizedComponents = store.imageUI.visualizedComponents
const independentComponents = store.imageUI.independentComponents
if (!!store.imageUI.representationProxy) {
const sliceActors = store.imageUI.representationProxy.getActors()
sliceActors.forEach((actor,... |
"""A setuptools based setup module.
See:
https://packaging.python.org/en/latest/distributing.html
https://github.com/pypa/sampleproject
"""
# Always prefer setuptools over distutils
from setuptools import setup, find_packages
# To use a consistent encoding
from codecs import open
from os import path
here = path.abs... |
/* eslint-env mocha */
'use strict'
const { fixtures } = require('./utils')
const { getDescribe, getIt, expect } = require('./utils/mocha')
const all = require('it-all')
const drain = require('it-drain')
const CID = require('cids')
const testTimeout = require('./utils/test-timeout')
const randomName = prefix => `${pr... |
export const setUser = payload => ({
type: 'SET_USER',
payload,
})
export const setLogin = payload => ({
type: 'SET_LOGIN',
payload,
}) |
module.exports = {
"85.0.4162.0": [
"11.0.0-nightly.20200611",
"11.0.0-nightly.20200610",
"11.0.0-nightly.20200609",
"11.0.0-nightly.20200604",
"11.0.0-nightly.20200603",
"11.0.0-nightly.20200602"
],
"85.0.4156.0": [
"11.0.0-nightly.20200529"
],
"84.0.4129.0": [
"11.0.0-nightly.20200526",
"11.0.0... |
#!/usr/bin/env python
"""Using PyPPL to distribute and run commands."""
import sys
from os import path
from pyppl import PyPPL, Proc, Diot
from bioprocs import params
from tempfile import gettempdir
params._prefix = '-'
params._hbald = False
params.cmds.desc = 'The cmd list. If not provided, STDIN will be u... |
var express = require('express');
var useragent = require('express-useragent');
var app = express();
var cors = require('cors')
var server = require('http').createServer(app);
app.set('env','production')
app.use(useragent.express());
app.get('/*',function (req, res, next) {
res.setHeader("Cache-Control", "public, ... |
import React from 'react'
import './App.css';
import Navbar from './Components/Navbar';
import { Route, BrowserRouter as Router, Switch } from 'react-router-dom'
import Home from './Components/pages/HomePage/Home'
import Footer from './Components/pages/Footer/Footer'
import EditCatPage from "./Components/pages/EditCatP... |
const largeJugInputElem = document.getElementById("large-jug-size");
const smallJugInputElem = document.getElementById("small-jug-size");
const targetNumberInputElem = document.getElementById("target-number");
const predictionInputElem = document.getElementById("prediction");
const totalSteps = document.getElementById... |
"""Utility functions."""
def to_bool(value):
"""Take a value and convert it to a boolean type.
:param value: string or int signifying a bool
:type value: str
:returns: converted string to a real bool
"""
positive = ("yes", "y", "true", "t", "1")
if str(value).lower() in positive:
... |
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const base_ipc_client_1 = require("../base_ipc_client");
class InfoCommand extends base_ipc_client_1.BaseIPCClientCommand {
async run() {
if (!this._client) {
this.error('APIClient is not initialized.');
}
... |
import logging
from yapsy.IPlugin import IPlugin
import simplejson as json
import configargparse
from opentargets_urlzsource import URLZSource
from opentargets_ontologyutils.rdf_utils import OntologyClassReader
import opentargets_ontologyutils.mp
#TODO move this to config
PHENOTYPE_CATEGORIES = {
"MP:0005386" : ... |
export default {
route: {
dashboard: 'แผงควบคุมไฟฟ้า',
documentation: 'เอกสาร',
guide: 'คู่มือ',
permission: 'ใบอนุญาต',
pagePermission: 'สิทธิ์หน้า',
rolePermission: 'สิทธิ์ในบทบาท',
directivePermission: 'การอนุญาต',
icons: 'ไอคอน',
components: 'ส่วนประกอบ',
tinymce: 'ทิงส์',
... |
document.addEventListener('DOMContentLoaded', function () {
new Splide('#splides', {
type: 'loop',
perPage: 1,
autoplay: true,
pauseOnHover: true,
}).mount();
});
const btnBurger = document.querySelector('.burger-menu');
btnBurger.addEventListener('click', () => {
const topMenu = document.queryS... |
#-*- coding: utf-8 -*-
from scapy.all import *
from time import sleep
from multiprocessing import Process
import json
import sys
import signal
reload(sys)
sys.setdefaultencoding('utf-8')
json_data = open("ssid.json").read()
crawl = json.loads(json_data)
br = "ff:ff:ff:ff:ff:ff"
class makebeacon:
dot11 = Dot11(addr1... |
import sdk from "./1-initialize-sdk.js";
const bundleDrop = sdk.getBundleDropModule(
"0x7a65c8A3877052dC3a03021FCb977EB7ef125765"
);
(async () => {
try {
const claimConditionFactory = bundleDrop.getClaimConditionFactory();
claimConditionFactory.newClaimPhase({
startTime: new Date(),
maxQuantit... |
(function (exports) {
// Extend as needed.
var lang = exports.lang = {
Node: {
},
Program: {
extends: "Node",
fields: ["@body"]
},
Statement: {
extends: "Node"
},
EmptyStatement: {
extends: "Statement"
},
BlockStatement: {
extends: "Statement",... |
import { Directive, Input, HostListener, Renderer2, ElementRef, NgZone } from '@angular/core';
/**
* An element placed inside a `mwlResizable` directive to be used as a drag and resize handle
*
* For example
*
* ```
* <div mwlResizable>
* <div mwlResizeHandle [resizeEdges]="{bottom: true, right: true}... |
# -*- coding: utf-8 -*-
"""
Scheduled restarting adam with warm up
"""
import math
import torch
from optimizer import Optimizer
class SRAdamW(Optimizer):
def __init__(self, params, lr=1e-3, betas=(0.9, 0.999), eps=1e-8, weight_decay=5e-4, use_variance=True, warmup=1000, iter_count=1, restarting_iter=50):
d... |
'use strict';
/**@type {{[k: string]: SpeciesFormatsData}} */
let BattleFormatsData = {
venusaurmegaz: {
tier: "OU",
doublesTier: "DOU",
},
charizardmegaz: {
tier: "OU",
doublesTier: "DOU",
},
blastoisemegaz: {
tier: "OU",
doublesTier: "DOU",
},
... |
'use strict';
const Base = require('./base');
const privateProps = new WeakMap();
/**
* Represents a clause of the conditional statement
* @memberof Statement.Conditional
* @class Clause
*/
class Clause {
constructor(statements, location, test) {
const privates = {
test: test,
statements: statements,
... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _indexController = require('./indexController');
var _indexController2 = _interopRequireDefault(_indexController);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var controllerInit = {... |
var i;
var fib = [];
fib[0] = 0;
fib[1] = 1;
for(i=2; i<=10; i++)
{
// Next fibonacci number = previous + one before previous
fib[i] = fib[i-2] + fib[i-1];
alert(fib[i]);
}
|
cordova.define("cordova-plugin-iosrtc.Plugin", function(require, exports, module) { /*
* cordova-plugin-iosrtc v1.4.5
* Cordova iOS plugin exposing the full WebRTC W3C JavaScript APIs
* Copyright 2015 Iñaki Baz Castillo at eFace2Face, inc. (https://eface2face.com)
* License MIT
*/
(function(f){if(typeof exports==... |
# -*- coding: utf-8 -*-
import atexit
import os.path
import shutil
import tempfile
import numpy as np
import pytest
from numpy.testing import assert_array_equal
from zarr.codecs import Zlib
from zarr.core import Array
from zarr.creation import (array, create, empty, empty_like, full, full_like,
... |
SourceFrame.BinaryResourceViewFactory=class{constructor(base64content,contentUrl,resourceType){this._base64content=base64content;this._contentUrl=contentUrl;this._resourceType=resourceType;this._arrayPromise=null;this._hexPromise=null;this._utf8Promise=null;}
async _fetchContentAsArray(){if(!this._arrayPromise){this._a... |
/* @flow */
import React from 'react'
import Timer from '../selectors/timer'
import { connect } from 'react-redux'
import Settings from '../selectors/settings'
import ModeSelectorButton from './mode_selector_button'
import ModeSelectorDialog from './mode_selector_dialog'
import type { Dispatch } from 'redux'
import t... |
from fastapi import APIRouter, FastAPI
router = APIRouter(prefix="/prefix")
@router.get("/")
def home():
...
app = FastAPI()
app.include_router(router)
|