text stringlengths 3 1.05M |
|---|
/**
Plugin: jQuery Parallax
Version 1.1.3
Author: Ian Lunn
Twitter: @IanLunn
Author URL: http://www.ianlunn.co.uk/
Plugin URL: http://www.ianlunn.co.uk/plugins/jquery-parallax/
Dual licensed under the MIT and GPL licenses:
http://www.opensource.org/licenses/mit-license.php
http://www.gnu.org/licenses/gpl.html
*/
(func... |
"""
Django settings for netflix project.
Generated by 'django-admin startproject' using Django 1.11.7.
For more information on this file, see
https://docs.djangoproject.com/en/1.11/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/1.11/ref/settings/
"""
import os... |
# Autogenerated constants for Random Number Generator service
from enum import IntEnum
from jacdac.constants import *
from jacdac.system.constants import *
JD_SERVICE_CLASS_RNG = const(0x1789f0a2)
class RngVariant(IntEnum):
QUANTUM = const(0x1)
ADCNOISE = const(0x2)
WEB_CRYPTO = const(0x3)
JD_RNG_REG_RA... |
/*
* wysiwyg web editor
*
* suneditor.js
* Copyright 2017 JiHong Lee.
* MIT license.
*/
'use strict';
export default {
name: 'table',
display: 'submenu',
add: function (core, targetElement) {
const context = core.context;
let contextTable = context.table = {
... |
// Copyright (c) 2006, 2008 Tony Garnock-Jones <tonyg@lshift.net>
// Copyright (c) 2006, 2008 LShift Ltd. <query@lshift.net>
//
// 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 rest... |
#
# Copyright 2021 Red Hat Inc.
# SPDX-License-Identifier: Apache-2.0
#
"""GCP Query Handling for Reports."""
import copy
import logging
from django.db.models import F
from django.db.models import Value
from django.db.models.functions import Coalesce
from django.db.models.functions import Concat
from tenant_schemas.ut... |
import copy
import unittest
from mock import patch
from datetime import datetime
import lxml.etree
import requests
import scrapper
def monkey_patch_requests_get():
def monkey_patch_get(uri, *args, **kwargs):
with open('./fixtures/%s' % uri) as fh:
extra_dict = {
'content': fh... |
"use strict";
const http = require("http");
const express = require("express");
const cookieParser = require("cookie-parser");
const bodyParser = require("body-parser");
const helmet = require("helmet");
const mainRouter = require("./router/mainRouter");
const userRouter = require("./router/userRouter");
const db = ... |
/*
* Copyright 2010-2017 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://aws.amazon.com/apache2.0
*
* or in the "license" fil... |
##!/usr/bin/python
# system imports
import os
# ccp4-python imports
import pyrvapi
# jsCoFE imports
from pycofe.tasks import basic
# ============================================================================
# HelloWorld driver
class HelloWorld(basic.TaskDriver):
def run(self):
# put message
... |
'''
Micropython Game for Beginners
written by Andi Dinata June 2018
Step-by-step explanation
Python skill required:
1. Importing libraries
2. list operations
3. if statements
4. simple arithmatics
5. Hardware interaction (SPI ledmatrix and buttons)
'''
#1. Import libraries we need
import max7219
from machine import P... |
export default /* @ngInject */ ($stateProvider) => {
$stateProvider.state('pci.projects.project.instances.unshelve', {
url: '/unshelve?instanceId',
views: {
modal: {
component: 'pciInstancesInstanceUnshelve',
},
},
layout: 'modal',
resolve: {
instanceId: /* @ngInject */ (... |
const app = getApp();
Page({
data: {
params: null,
data_list_loding_status: 1,
data_list_loding_msg: '',
data_bottom_line_status: false,
detail: null,
detail_list: []
},
onLoad(params) {
//params['id'] = 1;
this.setData({ params: params });
this.init();
},
... |
define( function (require) {
"use_strict"
var Backbone = require('backbone')
var UserModel = Backbone.Model.extend({
urlRoot: '/api/users',
defaults: { },
name: function() {
var attrs = this.attributes
return attrs.first_name + ' ' + attrs.last_name
}
})
return UserModel
})
|
import React from 'react';
const EuiIconTokenRankFeatures = ({ title, titleId, ...props }) => (
<svg
width={16}
height={16}
viewBox="0 0 16 16"
xmlns="http://www.w3.org/2000/svg"
aria-labelledby={titleId}
{...props}>
{title ? <title id={titleId}>{title}</title> : null}
<path d="M13 4v... |
# Author: Allan Chua allanchua.officefiles@gmail.com
from ipynta.enums import NamingStrategy
from ipynta.validators import StringValidator
import os
import uuid
class LocalPersister:
"""Class used for saving files to the local file system
Attributes:
-----------
img_list (list) : list of images to be saved... |
# -*- coding: utf-8 -*-
from xml.parsers import expat
from lxml import etree
from collections import deque
from . import getLogger
from .namespaces import STREAM_NS_URI, CLIENT_NS_URI, SERVER_NS_URI
class ParseError(RuntimeError):
def __init__(self, msg, state):
super(ParseError, self).__init__(msg)
... |
/* Copyright (c) 2019-2021, Arm Limited and Contributors
* Copyright (c) 2019-2021, Sascha Willems
*
* SPDX-License-Identifier: Apache-2.0
*
* 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... |
import Phaser from 'phaser';
export default class LeaderboardScene extends Phaser.Scene {
constructor() {
super('leaderboard-scene');
}
init(data) {
this.subScore = data.score;
this.kills = data.kills;
this.ending = data.song;
}
preload() {
this.width = this.scale.width;
this.height... |
# exported from PySB model 'model'
from pysb import Model, Monomer, Parameter, Expression, Compartment, Rule, Observable, Initial, MatchOnce, Annotation, ANY, WILD
Model()
Monomer('Ligand', ['Receptor'])
Monomer('ParpU', ['C3A'])
Monomer('C8A', ['BidU', 'C3pro'])
Monomer('SmacM', ['BaxA'])
Monomer('BaxM', ['BidM', '... |
import Logger from '../../logger';
const logger = Logger('[ Chat/Send-Chat :: Controller ]');
export default function makeSendChat ({ getUser }) {
return async function sendChat (httpRequest) {
try {
const { source = {}, message } = httpRequest.body;
const { user, params : { id } } = httpRequest;
... |
import sys
import pytest
from shiny_garbanzo import create_app
from shiny_garbanzo.ext.commands import populate_db
from shiny_garbanzo.ext.database import db
@pytest.fixture(scope="session")
def app():
app = create_app(FORCE_ENV_FOR_DYNACONF="testing")
with app.app_context():
db.create_all(app=app)
... |
import sys, requests, string
from random import sample
from multiprocessing import Pool
ip = '10.60.30.100'
if len(sys.argv) > 1:
ip = sys.argv[1]
def sploit(device):
found = "FAUST_"
s = requests.session()
for i in range(len(found), 38):
vals = "".join(sorted(string.ascii_letters + string.di... |
"""Support for Plaato Airlock sensors."""
import logging
from homeassistant.helpers.dispatcher import async_dispatcher_connect
from homeassistant.helpers.dispatcher import async_dispatcher_send
from homeassistant.helpers.entity import Entity
from . import (
ATTR_ABV,
ATTR_BATCH_VOLUME,
ATTR_BPM,
ATTR... |
#####CONFIGURATION#####
#all now in _analysis.py script - so each repo can be distinct
import sys #for getting args
from pathlib import Path #For doing nice crossplatform paths
import subprocess ##for running more command line stuff
import json #for config and analysis store
##### Working out what the target reposi... |
/* pluginName:自定义插件:'分页'
* codeDate:2013.11.15
* author:zhangshaoliu
*/
UE.plugins['zpagebreak'] = function() {
var me = this
me.commands['zpagebreak'] = {
execCommand: function(cmd, name) {
var number = parseInt(Math.random() * 10000)
var neweditor = ZPageBreak.addPageBlock(me, number)
... |
import React from 'react';
import Wrapper from 'root/jsx/util/wrapper';
import WPView from 'root/jsx/views/wp-view';
import GetInitialProps from 'root/jsx/util/get-initial-props';
import serverInfo from 'root/configs/server-info.json';
let postCall = {
url: serverInfo.WPJson + "wp/v2/posts",
options: {
method:... |
# -*- coding: utf-8 -*-
"""
Created on Thu Apr 22 15:57:36 2021
@author: Eduardo
"""
import numpy as np
import pandas as pd
import tensorflow as tf
from tensorflow.keras.preprocessing.image import ImageDataGenerator
from tensorflow.keras.utils import to_categorical
from tensorflow.keras.layers import Dense,... |
/*
Copyright (c) 2012-2015, Pierre-Olivier Latour
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 code must retain the above copyright
notice, this list of conditions a... |
#! /usr/bin/env python
# coding: utf-8
import os
import datetime
import time
import hashlib
from openpyxl import Workbook, styles
from openpyxl.styles import colors
from openpyxl.utils import get_column_letter
from mysqldb_rich import DB
from Class import conf_dir
__author__ = 'ZhouHeng'
class PerformanceManager(ob... |
"""
Joint image-sentence embedding space
"""
import theano
import theano.tensor as tensor
from theano.sandbox.rng_mrg import MRG_RandomStreams as RandomStreams
import pickle as pkl
import numpy
import nltk
from skipthoughts_vectors.encdec_functs.layers import get_layer, param_init_fflayer, fflayer, param_init_gru, gru... |
/**
* Copyright (c) 2016 Wind River Systems
*
* 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,... |
//
// Created by majiancheng on 2019/1/10.
// Copyright (c) 2019 majiancheng. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface MCAuthDemoDataVM : NSObject
@property(nonatomic, strong) NSMutableArray *dataList;
@property(nonatomic, assign) NSInteger selectIdx;
@end |
# -*- coding: utf-8 -*-
# Generated by Django 1.9.9 on 2016-08-17 18:50
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('yasp', '0005_auto_20160801_1652'),
]
operations = [
migrations.AlterModelOpt... |
# Copyright 2019 Mycroft AI Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writin... |
const journeyConfig = [
{
id: 0,
title: 'Demo Journey 1',
accountId: 1606862,
funnel: {
event: 'PageView',
measure: 'session'
},
kpis: [
{
label: 'Error Rate',
ref: 'errorRate',
value: 3.0,
bound: 'higherViolation',
description:
... |
#!/usr/bin/python
# -*- coding: utf-8 -*-
"""Test tools.chars package."""
#
# (C) Pywikibot team, 2015
#
# Distributed under the terms of the MIT license.
from __future__ import unicode_literals
__version__ = '$Id: f8e5cd407e12f6d95af1e49a08a60f10df8620a8 $'
import unicodedata
from distutils.version import StrictVe... |
# coding: utf-8
import torch
import torch.nn as nn
from torch import Tensor
from torch.nn.utils.rnn import pack_padded_sequence, pad_packed_sequence
from joeynmt.helpers import freeze_params
from joeynmt.transformer_layers import \
TransformerEncoderLayer, PositionalEncoding
#pylint: disable=abstract-method
cla... |
"""
Copyright (c) 2017 Microsoft. All rights reserved.
Licensed under the MIT License. See LICENSE.txt in the project root for license information.
DevSkim Sublime Text Plugin
https://github.com/Microsoft/DevSkim-Sublime-Plugin
"""
import datetime
import fnmatch
import json
import logging
import re
import time
import... |
/**********************************************************************/
/* ____ ____ */
/* / /\/ / */
/* /___/ \ / */
/* \ \ \/ ... |
# ECE464 Database Problem Set 1
# Di Mei
# insert.py (for Part 2)
# test of query samples (query 5, 6, 7 in Part 1)
from tables import Base, Sailors, Reserves, Boats
from sqlalchemy import create_engine, func, desc
from sqlalchemy.orm import sessionmaker
engine = create_engine('sqlite:///sailors.db')
Session = sessio... |
"""
WSGI config for ClassMate 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/2.0/howto/deployment/wsgi/
"""
import os
from django.core.wsgi import get_wsgi_application
os.environ.setdefault("DJANGO_SET... |
import styled, { css } from 'styled-components';
const Drop = css`
height: 10vh;
color: #b3aaaa;
font-size: 2.0vh;
line-height: 1.5vw;
margin-top: -53vh;
margin-bottom: 4vh;
text-align:center;
`
const DropContent = styled.div`
${ Drop };
`
export { DropContent };
|
/*
* @lc app=leetcode.cn id=142 lang=javascript
*
* [142] 环形链表 II
*/
// @lc code=start
/**
* Definition for singly-linked list.
* function ListNode(val) {
* this.val = val;
* this.next = null;
* }
*/
/**
* @param {ListNode} head
* @return {ListNode}
*/
var detectCycle = function (head) {
let sl... |
import React, { Component } from "react";
import Meta from "../components/Meta";
import Sponsors from "../components/sponsors/Sponsors";
import Footer from "../components/Footer";
export default class extends Component {
render() {
return (
<div>
<Meta />
<Sponsors />
<Footer />
... |
// THIS FILE IS AUTO GENERATED
import { GenIcon } from '../lib';
export function IoMdShare (props) {
return GenIcon({"tag":"svg","attr":{"viewBox":"0 0 512 512"},"child":[{"tag":"path","attr":{"d":"M383.822 344.427c-16.045 0-31.024 5.326-41.721 15.979l-152.957-88.42c1.071-5.328 2.142-9.593 2.142-14.919 0-5.328-1.071-... |
# coding: utf-8
from __future__ import unicode_literals
import itertools
import json
import re
from .common import InfoExtractor, SearchInfoExtractor
from ..compat import (
compat_urllib_parse,
compat_urlparse,
)
from ..utils import (
clean_html,
unescapeHTML,
ExtractorError,
int_or_none,
)
... |
//BEGIN-SNIPPET moving-word-text-snippet.js
import Component from '@ember/component';
import fade from 'ember-animated/transitions/fade';
export default Component.extend({
listMode: false,
fade,
actions: {
toggle() {
this.set('listMode', !this.get('listMode'));
},
normal(){
this.set('noA... |
# -*- coding: utf-8 -*-
# Copyright (c) 2020, GreyCube Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
# import frappe
from frappe.model.document import Document
class RebateSlabCT(Document):
pass
|
import React, { useRef } from 'react'
import { useFrame, useThree } from 'react-three-fiber'
import shaderMaterial from './shadermaterial3'
function Square(props) {
// This reference will give us direct access to the mesh
const mesh = useRef()
// Rotate mesh every frame, this is outside of React without overh... |
import pyrtl
import random
""" testcase_utils
This file (intentionally misspelled) is created to store common utility
functions used for the test cases.
I am documenting this rather well because users have
a good reason to look at it - John Clow
"""
def calcuate_max_and_min_bitwidths(max_bitwidth=None, exact_bitwi... |
"use strict";
// const defaultConfig = require("./config");
const blackList = require("./blackList.js");
const winston = require("winston");
const { combine, timestamp, label, printf, prettyPrint } = winston.format;
const DailyRotateFile = require("winston-daily-rotate-file");
const createDailyRotateTransport = funct... |
module.exports = {
deviceType: "power_meter_1",
upnpType: "urn:schemas-micasaverde-com:device:PowerMeter:1",
services: {
"urn:micasaverde-com:serviceId:EnergyMetering1": {
api: require('../luup_services/energy_metering_1')
},
"urn:micasaverde-com:serviceId:HaDevice1": {
api: require('../lu... |
from django.apps import AppConfig
class LibdataConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'libData'
|
# (C) Datadog, Inc. 2018-present
# All rights reserved
# Licensed under a 3-clause BSD style license (see LICENSE)
import logging
import mock
import pytest
from datadog_checks.consul import ConsulCheck
from datadog_checks.consul.common import MAX_SERVICES
from . import common, consul_mocks
pytestmark = pytest.mark.... |
//!#####################################################################
//! \file Grid_Hierarchy.h
//!#####################################################################
// Class Grid_Hierarchy
//######################################################################
#ifndef __Grid_Hierarchy__
#define __Grid_Hierarch... |
# -*- coding: utf-8 -*-
from django.db.models.loading import get_apps, get_models
from django.forms.models import modelform_factory
def normalize_model_name(model_name):
if (model_name.lower() == model_name):
normal_model_name = model_name.capitalize()
else:
normal_model_name = model_name
... |
#ifndef _USER_CFG_ID_H_
#define _USER_CFG_ID_H_
//=================================================================================//
// 与APP CASE相关配置项[1 ~ 60] //
//=================================================================================//
// #define CFG_RCS... |
import Axios from 'axios'
import config from 'config'
import os from 'os'
import _ from 'lodash'
let getLocalIp = function() {
const ifaces = os.networkInterfaces();
const ips = _.flatten(Object.keys(ifaces).map(function (ifname) {
return ifaces[ifname].map(function (iface) {
if ('IPv4' !== ifa... |
import os
import sys
import re
sys.path.append(os.path.realpath('.'))
from pprint import pprint
import inquirer
questions = [
inquirer.Checkbox('interests',
message="What are you interested in?",
choices=['Computers', 'Books', 'Science', 'Nature', 'Fantasy', 'History'],... |
/*! jQuery v2.0.0 | (c) 2005, 2013 jQuery Foundation, Inc. | jquery.org/license
//@ sourceMappingURL=jquery-2.0.0.min.map
*/
(function(e,undefined){var t,n,r=typeof undefined,i=e.location,o=e.document,s=o.documentElement,a=e.jQuery,u=e.$,l={},c=[],f="2.0.0",p=c.concat,h=c.push,d=c.slice,g=c.indexOf,m=l.toString,y=l.has... |
# coding: utf-8
"""
Kubernetes
No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
OpenAPI spec version: v1.8.1
Generated by: https://github.com/swagger-api/swagger-codegen.git
"""
from __future__ import absolute_import
import os
import sys
im... |
import { expect, fixture, html } from '@open-wc/testing';
import sinon from 'sinon';
import '../lion-switch-button.js';
describe('lion-switch-button', () => {
let el;
beforeEach(async () => {
el = await fixture(html`<lion-switch-button></lion-switch-button>`);
});
it('should be focusable', () => {
exp... |
'use strict';
//Model class for user
class User {
constructor(in_userId, in_userName, in_email, in_joinDate, in_pw_salt, in_pw_hash, in_profilePicture, in_userRole) {
this.userId = in_userId;
this.userName = in_userName;
this.email = in_email;
this.joinDate = in_joinDate;
this.pw_salt = in_pw_salt... |
#if !defined(COORDINATE_TRANSFORMS_H)
#define COORDINATE_TRANSFORMS_H
#include "ufWin32Header.h"
// we need the matrix bits
#include "boost/numeric/ublas/matrix.hpp"
#include "boost/numeric/ublas/matrix_proxy.hpp"
#include "boost/numeric/ublas/vector.hpp"
#include "boost/numeric/ublas/vector_proxy.hpp"
#include "boos... |
from .station import Station
from .line import Line
from .lines import Lines
from .weather import Weather
|
import numpy as np
import pytest
import pandas as pd
import pandas._testing as tm
def test_take(idx):
indexer = [4, 3, 0, 2]
result = idx.take(indexer)
expected = idx[indexer]
assert result.equals(expected)
# GH 10791
msg = "'MultiIndex' object has no attribute 'freq'"
with pytest.raises... |
# -*- coding: utf-8 -*-
"""
Flask application configurations module.
"""
import os
class Config:
"""
Flask application configuration class.
"""
# Generate the secret key using secrets.token_hex(16)
SECRET_KEY = os.environ['FLASK_SECRET_KEY']
# Configure the SQLAlchemy-related options
p... |
def is_prime(number):
return all([(number % e) == 0 for e in range(1, number)]) |
'''
Function:
load the hrf dataset
Author:
Zhenchao Jin
'''
import os
import pandas as pd
from .base import *
'''hrf dataset'''
class HRFDataset(BaseDataset):
num_classes = 2
classnames = ['__background__', 'vessel']
assert num_classes == len(classnames)
def __init__(self, mode, logger_handle,... |
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('three')) :
typeof define === 'function' && define.amd ? define(['exports', 'three'], factory) :
(global = global || self, factory(global.PANOLENS = {}, global.THREE));
}(this, function (exports, THR... |
# ------------------------------------------------------------------------------
# Copyright (c) Microsoft
# Licensed under the MIT License.
# Written by Bin Xiao (Bin.Xiao@microsoft.com)
# ------------------------------------------------------------------------------
from __future__ import absolute_import
from __futu... |
/* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE78_OS_Command_Injection__char_listen_socket_w32_spawnv_67a.c
Label Definition File: CWE78_OS_Command_Injection.strings.label.xml
Template File: sources-sink-67a.tmpl.c
*/
/*
* @description
* CWE: 78 OS Command Injection
* BadSource: listen_socket Read data usi... |
template<int Number>
void query(
x_type x,
y_type y,
amap_type AMAP[N_AU][HEIGHT * WIDTH],
bool interested[N_AU]
){
for(int j = 0; j < N_AU; j++){
#pragma HLS UNROLL
interested[j] = 0;
}
for(int n = 0; n < N_AU; n++){
#pragma HLS UNROLL
amap_type out = AMAP[n][y * WIDTH + x];
if(out > 0){
inte... |
module.exports = { prefix: 'fas', iconName: 'desktop-alt', icon: [576, 512, [], "f390", "M528 0H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h192l-16 48h-72c-13.3 0-24 10.7-24 24s10.7 24 24 24h272c13.3 0 24-10.7 24-24s-10.7-24-24-24h-72l-16-48h192c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zm-16 288H64V64h448v224z"] ... |
import numpy as np
import pandas as pd
import pickle
from ismore import common_state_lists
from db.tracker import models
from db import dbfunctions as dbfn
def generate_target_matrices_for_sim():
'''
Point: use these as input to sim_passive_movements so you can test target_matrices
'''
## B1 ##
t... |
# -*- coding: utf-8 -*-
################################################
#
# URL:
# =====
# https://leetcode.com/problems/word-break/
#
# DESC:
# =====
# Given a non-empty string s and a dictionary wordDict containing a list of non-empty words,
# determine if s can be segmented into a space-separated sequence of one o... |
(function () {
"use strict";
angular.module('ctu').factory('skylink$', SkylinkFactory);
SkylinkFactory.$inject = [];
function SkylinkFactory() {
var skylinkKey = '0e16be15-7440-4072-85fc-c1266852cb7f';
var skylink = new Skylink();
skylink.init({
'apiKey': skylinkKey... |
"""
Django settings for mysite project.
Generated by 'django-admin startproject' using Django 3.1.3.
For more information on this file, see
https://docs.djangoproject.com/en/3.1/topics/settings/
For the full list of settings and their values, see
https://docs.djangoproject.com/en/3.1/ref/settings/
"""
from pathlib ... |
exports.level = {
"goalTreeString": "{\"branches\":{\"main\":{\"target\":\"C11\",\"id\":\"main\",\"remoteTrackingBranchID\":\"o/main\",\"localBranchesThatTrackThis\":null},\"o/main\":{\"target\":\"C11\",\"id\":\"o/main\",\"remoteTrackingBranchID\":null,\"localBranchesThatTrackThis\":[\"main\"]},\"side1\":{\"target\":... |
/*=========================================================================
cpicom
files/filesystemfat.c
CPICOM-compatible wrapper for the FatFS filesystem handler
Copyright (c)2001 Kevin Boone, GPL v3.0
=========================================================================*/
#include <string.h>
#in... |
/*
* Copyright (c) 2017, ARM Limited and Contributors. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
/*
* Exception handlers at EL3, their priority levels, and management.
*/
#include <assert.h>
#include <cpu_data.h>
#include <debug.h>
#include <ehf.h>
#include <gic_common.h>
#include <inter... |
import sys
sys.path.append("src")
import pymemgrep._nt as nt
import pymemgrep.mem as mem
import ctypes
# osu = nt.open_process("osu!.exe")
# print(osu)
# print(nt.close_handle(osu))
sysinfo = nt.SYSINFO
# print(hex(sysinfo.MinimumApplicationAddress))
# print(hex(sysinfo.MaximumApplicationAddress))
handle = nt.open_... |
const fs = require('fs');
const POOLSIZE = 3;
const FILTERSIZE = 3;
const data = fs.readFileSync('sample.dat');
const ConvolutionalLayer = require('./convolutional-layer');
const PoolingLayer = require('./pooling-layer');
const image = inputData(data.toString());
const cl = new ConvolutionalLayer(FILTERSIZE);
cl.filter... |
# Copyright 2013 The Swarming Authors. All rights reserved.
# Use of this source code is governed by the Apache v2.0 license that can be
# found in the LICENSE file.
import os
import sys
# isolate/
APP_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
# components/ (NOT isolate/components/).
COMPONENT... |
# Generated by Django 2.2.6 on 2020-11-16 22:53
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('background_task', '0002_auto_20170927_1109'),
]
operations = [
migrations.CreateModel(
name='Queue',
fields=[
... |
// Copyright 2017 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --harmony-class-fields
{
class C {
static a;
}
assertEquals(undefined, C.a);
let c = new C;
assertEquals(undefined, c.a);
}
... |
var _ = require('underscore');
var Mosaic = require('mosaic-commons');
var Class = Mosaic.Class;
/**
* An adapter manager used to register/retrieve objects corresponding to the
* types of adaptable object and the types of the target object. This object is
* used by views to get view adapters.
*/
var AdapterManager... |
#include <weapon.h>
#include <ansi.h>
inherit SWORD;
void create()
{
set_name( CYN "镔铁长剑" NOR, ({ "chang jian", "sword", "jian" }));
set_weight(10000);
if (clonep())
set_default_object(__FILE__);
else {
set("unit", "柄");
set("long", "一柄锋利的... |
# Copyright (C) 2018 Google Inc.
# Licensed under http://www.apache.org/licenses/LICENSE-2.0 <see LICENSE file>
"""
Migrate old review to new
Create Date: 2018-09-17 15:45:33.712697
"""
# disable Invalid constant name pylint warning for mandatory Alembic variables.
# pylint: disable=invalid-name
from alembic import ... |
import * as _vue from "vue";
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? Object(arguments[i]) : {}; var ownKeys = Object.keys(source); if (typeof Object.getOwnPropertySymbols === 'function') { ownKeys = ownKeys.concat(Object.getOwnPropertySymbols(so... |
# coding=utf-8
# Copyright 2018 Google T5 Authors and HuggingFace Inc. 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 requ... |
/*************************************************************************/
/* reference.h */
/*************************************************************************/
/* This file is part of: */
/* ... |
import kagglegym
import numpy as np
import pandas as pd
from sklearn.ensemble import ExtraTreesRegressor
from sklearn.linear_model import LinearRegression
from sklearn.preprocessing import PolynomialFeatures
#set kagglegym environment
env = kagglegym.make()
o = env.reset()
excl = [env.ID_COL_NAME, env.SAMPLE... |
/*
* This file is subject to the terms and conditions of the GNU General Public
* License. See the file "COPYING" in the main directory of this archive
* for more details.
*
* Copyright (C) 1994 Waldorf GMBH
* Copyright (C) 1995, 1996, 1997, 1998, 1999, 2001, 2002, 2003 Ralf Baechle
* Copyright (C) 1996 Paul M.... |
"""Some utilities for dealing with Origen 2.2 TAPE9 files."""
import os
import warnings
from collections import defaultdict
import numpy as np
import scipy.sparse
from pyne import utils
utils.toggle_warnings()
warnings.simplefilter('ignore')
from pyne import data
from pyne import rxname
from pyne import nucname
from... |
import React from "react";
import PropTypes from "prop-types";
import classNames from "classnames";
import { useTranslation } from "react-i18next";
import styled from "styled-components";
import { observer } from "mobx-react";
import PrivateIndicator from "../PrivateIndicator/PrivateIndicator";
import Loader from "../L... |
/*
ChibiOS - Copyright (C) 2006..2018 Giovanni Di Sirio
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 requi... |
import Handler from "../handler";
import csstree from "css-tree";
import { elementAfter } from "../../utils/dom";
class Breaks extends Handler {
constructor(chunker, polisher, fitter, caller) {
super(chunker, polisher, fitter, caller);
this.breaks = {};
}
onDeclaration(declaration, dItem, dList, rule) {
let... |
import argparse
import glob
import json
import logging
import os
import random
from csv_processor import csv_processors as processors
from header import log_to_csv_with_auc_accuracy
import numpy as np
import torch
from torch.utils.data import DataLoader, RandomSampler, SequentialSampler, TensorDataset
from torch.util... |