content stringlengths 10 4.9M |
|---|
export const RECORDER_ELEMENT_IDENTIFIER = 'data-test-automation-id';
export const DEFAULT_RECORDER_HOST = 'localhost';
export const DEFAULT_RECORDER_HTTP_PORT = 3050;
export const DEFAULT_RECORDER_WS_PORT = 3051;
|
Eric Decker says money won't be the only factor when it comes to his decision on whether to re-sign with the Denver Broncos.
"It's not all about the money for me. It's about going to work every day and having fun and enjoying my job," the veteran receiver said on SiriusXM NFL Radio.
Eric Decker, set to become an unre... |
def configureClinicalDf(self, clinicalDf, redCapToCbioMappingDf):
assert clinicalDf.columns.isin(redCapToCbioMappingDf["code"]).all()
clinicalDf.columns = [
redCapToCbioMappingDf["cbio"][redCapToCbioMappingDf["code"] == col].values[
0
]
for col in clin... |
/**
* Find out of a column was changed, by column number
*
* @param columnNumber the column to check
*
* @return true if the column was modified by this statement.
* Note that this will always return true for INSERT
* and DELETE regardless of the column name passed in.
*/
public boolean wasColumnModifi... |
.
Ag-NOR patterns were studied in hepatocytes from nine mink embryo siblings, including a pair of monochorionic (presumably monozygotic, MZ) twins. Both the number and the size of Ag-NORs per cell were found to be identical in MZ twins. All the other sibs had the patterns different from each other and from the MZ ones... |
/*
* FAT16 accessors.
*
* FAT16s are sufficiently small, expect it to always fit in the RAM.
*/
static inline uint8_t *
fat_get_fat16_ptr(struct fat_descriptor *fat, cl_t cl)
{
return (fat->fatbuf + (cl << 1));
} |
use std::path::{Component, Path};
use amethyst::{
assets::{AssetStorage, Handle, Loader, ProgressCounter},
renderer::{formats::texture::ImageFormat, Texture},
Error,
};
use log::error;
use sprite_model::config::SpriteSheetDefinition;
/// Loads textures specified in the sprite sheet definitions.
#[derive(D... |
// IsProd return true if app is in production mode.
func IsProd() bool {
switch RunMode("devel") {
case "prod", "production":
return true
}
return false
} |
Structural evolution of phosphated alumina during sol-gel synthesis.
Phosphated alumina gels were prepared by the sol-gel method. Gels were aged from 1 to 8 days in air. Gel structure evolution, as time went on, was followed by 27Al magic angle spinning nuclear magnetic resonance, X-ray diffraction, and small-angle X-... |
def recalc(self, fromRect=True):
if fromRect:
self.__dict__['r'] = sqrt(self.x**2 + self.y**2)
self.__dict__['a'] = atan2(self.y, self.x)
else:
self.__dict__['x'] = round(self.r * cos(self.a),15)
self.__dict__['y'] = round(self.r * sin(self.a),15)
... |
<filename>digsby/src/gui/imwin/imwin_email.py
'''
GUI for the IM window's email tab.
'''
import wx
from util.primitives.funcs import Delegate
from gui.uberwidgets.UberButton import UberButton
from gui.uberwidgets.UberBar import UberBar
from gui.uberwidgets.skintextctrl import SkinTextCtrl
from gui.uberwidgets.clea... |
import gym
import numpy as np
from typing import Any, Callable, Iterator, List, Optional, Tuple, Union, cast
from d3rlpy.metrics.scorer import AlgoProtocol
def evaluate_initial_state_value_estimate(env: gym.Env, n_trials: int = 10) -> Callable[..., float]:
def scorer(algo: AlgoProtocol, *args: Any) -> float:
... |
import styled from "styled-components";
import Bg from "@components/Bg";
import { Button, RedButton } from "@components/Inputs";
import { SubTitle, LargeCode } from "@components/Title";
import redirect from "@lib/redirect";
const DeleteWrapper = styled.div`
margin-top: 20px;
margin-left: 20px;
`;
const DeleteRe... |
<gh_stars>1-10
package main
import (
"crypto/aes"
"crypto/cipher"
"crypto/hmac"
"crypto/sha256"
"crypto/subtle"
"database/sql"
"encoding/hex"
"encoding/json"
"errors"
"io/ioutil"
"log"
"net/http"
"github.com/opencoff/go-srp"
"github.com/pquerna/otp/totp"
)
// jsMap - alias for map[string]interface{}
ty... |
The electronic structure of a single-walled aluminosilicate nanotube
The geometric structure and electronic structure of an imogolite nanotube have been studied using density functional theory (DFT). The calculation results indicate that the deformation of the material leads to structural electric charges on the tube ... |
/**
* Returns a map with all namespaces that are valid for the specified pre value.
* @param pre pre value
* @param data data reference
* @return scope
*/
TokenMap scope(final int pre, final Data data) {
final TokenMap nsScope = new TokenMap();
NSNode node = current;
do {
final int[] va... |
/*
* simply re-trigger the interrupt handler on led timeout
*/
static void
blink_led_timeout(void *arg)
{
struct sysctrl_soft_state *softsp = arg;
int led_state;
ASSERT(softsp);
softsp->sys_fault = process_fault_list();
mutex_enter(&softsp->sys_led_lock);
softsp->sys_led = !softsp->sys_led;
led_state = softsp-... |
The Xiaomi Mi Band placed the company on the health and fitness tracking radar and according to Chinese sources, the successor is soon to launch. A purported photo of the Mi Band 2 shows the body of the tracker, but sadly it isn't as revealing as we'd hoped.
Apart from the photo, there's no new information regarding t... |
package cn.ieclipse.smartqq;
import java.util.Collections;
import java.util.List;
import com.scienjus.smartqq.client.SmartQQClient;
import com.scienjus.smartqq.model.Category;
import com.scienjus.smartqq.model.Discuss;
import com.scienjus.smartqq.model.Friend;
import com.scienjus.smartqq.model.Group;
import com.scien... |
<filename>k3d/plot.py
from __future__ import print_function
import base64
import ipywidgets as widgets
from IPython.display import display
from functools import wraps
from traitlets import Unicode, Bool, Int, List, Float
from ._version import __version__ as version
from .objects import (Line, Label, MIP, MarchingCube... |
/**
* Derive key pair with specified @keyIndex
*/
std::tuple<PublicKey, PrivateKey> deriveKeypair(IWalletDB::Ptr storage, uint64_t keyIndex)
{
PrivateKey sk;
PublicKey pk;
storage->get_MasterKdf()->DeriveKey(sk, ECC::Key::ID(keyIndex, Key::Type::Bbs));
pk.FromSk(sk);
... |
<filename>webui/pages/approval-rulesets/[id].tsx
import { useState } from 'react';
import { useRouter } from 'next/router';
import SwipeableViews from 'react-swipeable-views';
import Link from 'next/link';
import useSWR from 'swr';
import { formatDateTimeString, humanizeUnderscoreString, paginateArray, formatProposalSt... |
Undergraduate curriculum in veterinary schools
SIR, – I read with interest the responses ( VR , June 25, vol 156, p 846) to my recent letter regarding undergraduate education in veterinary schools ( VR , June 11, vol 156, p 788). It is encouraging to see at least two vet schools embracing the idea of integrated and ou... |
<reponame>ldionne/mpl11
/*!
* @file
* Defines the `check_finite_iterable` utility to ease unit testing of
* `Iterable`s.
*/
#ifndef BOOST_MPL11_TEST_CHECK_FINITE_ITERABLE_HPP
#define BOOST_MPL11_TEST_CHECK_FINITE_ITERABLE_HPP
#include <boost/mpl11/fwd/comparable.hpp>
#include <boost/mpl11/fwd/iterable.hpp>
#inclu... |
/**
* NSHM23 Logic Tree Branch implementation but using UCERF3 ingredients (FM, DM, Scaling)
*
* @author kevin
*
*/
public class NSHM23_U3_HybridLogicTreeBranch extends LogicTreeBranch<LogicTreeNode> {
public static List<LogicTreeLevel<? extends LogicTreeNode>> levels;
public static List<LogicTreeLevel<? exten... |
<filename>cloudferrylib/os/compute/libvirt.py<gh_stars>0
# Copyright 2015 Mirantis 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
#
# U... |
import React from 'react';
import { Group } from '../../model/Group';
type GroupCardProps = {
group: Group
};
export default class GroupCard extends React.PureComponent<GroupCardProps> {
render() {
const { group } = this.props;
return (
<div className="group-card">
... |
<filename>EC/ProyectoEC/include/temporizadores.h
/*-------------------------------------
temporizadores.h
-------------------------------------*/
extern void IntTemp(); |
/**
* Creates an unconnected socket.
*
* @return unconnected socket
*
* @throws IOException if an I/O error occurs when creating the socket
*/
@Override
public Socket createSocket()
throws IOException
{
return initSSLSocket((SSLSocket) factory.createSocket());
} |
// Copyright 2019 <NAME> <<EMAIL>>
#ifndef INCLUDE_SAM_SYSTEM_EULER_SYSTEM_HPP_
#define INCLUDE_SAM_SYSTEM_EULER_SYSTEM_HPP_
#include <vector>
#include <boost/numeric/odeint/integrate/null_observer.hpp>
#include "./generic_system.hpp"
namespace sam {
/*! \brief A system that is integrated with an Euler method of ... |
import React from "react";
import { Colors } from "../../../style/type";
export interface GiftCardProps {
theme: Colors;
icon?: React.ReactNode;
title: string;
caption: string;
}
|
Control quality measurements of alpha and beta counter with low back-ground ALBA 2000 v.2.5.6.
The article provides a systematic approach to quality control of measurements of total alpha-and beta-activity using a counter with a low background ALPHA / BETA COUNTING SYSTEM ALBA (mod. ALBA / LLAB) and software ALBA 2000... |
/**
* Test a move and rename of a referral entry, using JNDI ignore.
*/
@Test
public void testMoveAndRenameIsReferralJNDIIgnore() throws Exception
{
try
{
MNNCtx.addToEnvironment( DirContext.REFERRAL, "ignore" );
MNNCtx.rename( "cn=Emmanuel Lecharny,ou=Roles", "... |
/** \file AlignableBeamSpot
*
* Original author: Andreas Mussgiller, August 2010
*
* $Date: 2010/10/26 19:53:53 $
* $Revision: 1.2 $
* (last update by $Author: flucke $)
*/
#include "Alignment/CommonAlignment/interface/AlignableDetUnit.h"
#include "CondFormats/Alignment/interface/Alignments.h"
#include "Con... |
/**
* Created by Shyamal on 2/6/2015.
*/
public class ArrivalTimeWidget implements Serializable{
private int appWidgetId;
private String agencyID;
private String routeID;
private String stopID;
private String agencyLongName;
private String routeName;
private String stopName;
private St... |
// AppendAll appends all elements of given segments after the tail of the collection.
func (s *Segments) AppendAll(t []Segment) {
if s.values == nil {
s.values = make([]Segment, 0, 20)
}
s.values = append(s.values, t...)
} |
/** Removes summary from main window. */
private void removeSummary() {
final int maxElements = 4;
final int summaryElementIndex = 3;
Node node = view.getBorderPane().getCenter();
StackPane sp = (StackPane) node;
if (sp.getChildren().size() == maxElements) {
sp.getChi... |
Formation of Hetero-binuclear Pt(II)-M(II) Complexes Based on (2-(1 H-Tetrazol-5-yl)phenyl)diphenylphosphine Oxide for Superior Phosphorescence of Monomers.
Novel hetero-binuclear platinum complexes (HBC-Pt(II)-M(II), M = Ca(II), Mg(II), Zn(II), and Cd(II)) have been synthesized by the reaction of the corresponding pr... |
// Shut off all replication.
func (wr *Wrangler) stopSlaves(tabletMap map[topo.TabletAlias]*topo.TabletInfo) error {
errs := make(chan error, len(tabletMap))
f := func(ti *topo.TabletInfo) {
err := wr.ai.StopSlave(ti, wr.ActionTimeout())
if err != nil {
wr.logger.Infof("StopSlave failed: %v", err)
}
errs <... |
// Given an image file name, read in the data, try to decode it as an image,
// resize it to the requested size, and then scale the values as desired.
Status ReadTensorFromImageFile(string file_name, const int wanted_height,
const int wanted_width, const float input_mean,
... |
nerium Profile Blog Joined November 2007 Philippines 507 Posts #2 Wait, you mean march 14 and 15 right? Lulz is a corrupted version of LOL
Clefairy Profile Joined September 2011 1570 Posts Last Edited: 2013-03-12 15:27:19 #3 On March 13 2013 00:25 nerium wrote:
Wait, you mean march 14 and 15 right?
Yes indeed I do. ... |
Mickey Rooney (born Joseph Yule Jr.; September 23, 1920 – April 6, 2014) was an American actor, vaudevillian, comedian, producer and radio personality. In a career spanning nine decades and continuing until shortly before his death, he appeared in more than 300 films and was one of the last surviving stars of the silen... |
#include <iostream>
#include <fstream>
#include <iomanip>
#include <math.h>
#include <limits.h>
#include <algorithm>
#include <vector>
#include <list>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <bitset>
#include <string>
#include <string.h>
#include <sstream>
#include <ctim... |
def find(self, expr, first = -1, reverse = False):
try:
ret = _datascope._dbfind(self, expr, first, reverse)
except _datascope._ElogException, _e:
stock._raise_elog(_e)
return ret |
<filename>src/app/component/visualization/visualization.abstract.component.ts
import { SelectionToolConfig } from './../../model/selection-config.model';
import { ChartSelection } from './../../model/chart-selection.model';
import * as THREE from 'three';
import { EventEmitter } from '@angular/core';
import { EntityTyp... |
"""
Unit and regression test for kissim.encoding.FingerprintGeneratorNormalized.
"""
import pytest
import numpy as np
from kissim.encoding import FingerprintGeneratorNormalized
class TestFingerprintGeneratorNormalized:
"""
Test normalized fingerprints class.
"""
@pytest.mark.parametrize(
"m... |
class PEReadUploaderTest:
'''
Module Name:
PEReadUploaderTest
Module Description:
A KBase module to wrap the MegaHit package.
'''
######## WARNING FOR GEVENT USERS #######
# Since asynchronous IO can lead to methods - even the same method -
# interrupting each other, you must be *v... |
Premotor Potential Study for Diagnosis of Carpal Tunnel Syndrome.
INTRODUCTION
The second lumbrical-interossei latency difference test (2LINT) is used frequently for electrodiagnosis of carpal tunnel syndrome (CTS). A premotor potential observed with 2LINT has been identified as a median-nerve sensory nerve action pot... |
/**
*
* Generic controller to select a business group
*
* @author srosse, stephane.rosse@frentix.com, http://www.frentix.com
*/
public class SelectBusinessGroupController extends AbstractBusinessGroupListController {
private FlexiFiltersTab bookmarkTab;
private FlexiFiltersTab ownedGroupsTab;
private FlexiF... |
Proteome and secretome profiling of zinc availability in Cryptococcus neoformans identifies Wos2 as a subtle influencer of fungal virulence determinants
Background Fungal infections impact over 25% of the global population. For the opportunistic fungal pathogen, Cryptococcus neoformans, infection leads to cryptococcos... |
/*
* Copyright (c) 2017, Intel Corporation
*
* 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, publis... |
/**
* Prompt user to enable GPS and Location Services
*
* @param mGoogleApiClient
* @param activity
*/
public static void locationChecker(GoogleApiClient mGoogleApiClient, final Activity activity) {
LocationRequest locationRequest = LocationRequest.create();
locationRequest.setP... |
/** Returns the object with the settings used for calls to scheduleExperiment. */
public OperationCallSettings<ScheduleExperimentRequest, Empty, ScheduleExperimentMetadata>
scheduleExperimentOperationSettings() {
return ((ExperimentServiceStubSettings) getStubSettings())
.scheduleExperimentOperationSe... |
# Copyright 2021 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... |
/**
* Add productStock to user cart.
*/
@PutMapping
@ResponseStatus(HttpStatus.NO_CONTENT)
public void addProductToCart(
@RequestParam final String cartId,
@RequestParam final String productStockId,
@RequestParam(value = "count", required = false, defaultValue = "1"... |
<reponame>Shamann/G2Plot
import { M, randomFloat } from 'miz';
import { sankey } from '../../../../../src/plots/sankey/sankey';
import { cutoffCircle } from '../../../../../src/plots/sankey/circle';
import { transformDataToNodeLinkData } from '../../../../../src/utils/data';
const C = [
'A',
'B',
'C',
'D',
'... |
/*
* 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 ... |
package encryption
import (
"context"
"fmt"
"strconv"
"github.com/go-logr/logr"
"github.com/google/uuid"
"github.com/pkg/errors"
"github.com/storageos/api-manager/controllers/pvc-mutator/encryption/keys"
"github.com/storageos/api-manager/internal/pkg/provisioner"
"github.com/storageos/api-manager/internal/pk... |
Baby
My postpartum experience in six words or less:
Oh My God, What Just HAPPENED?
(If the challenge had allowed for a couple more words I probably would have included some profanity.)
You might feel the same way too. Awestruck and thunderstruck and monstertruck. Completely amazed at what your body just accomplishe... |
A critical blow-up exponent in a chemotaxis system with nonlinear signal production
This paper is concerned with radially symmetric solutions of the Keller–Segel system with nonlinear signal production, as given by in the ball for and R > 0, where f is a suitably regular function generalizing the prototype determine... |
/**
* @author Carlo Sciolla
* @since 0.1
*/
public class OrgFileType extends LanguageFileType {
public final static OrgFileType INSTANCE = new OrgFileType();
public final static String ORG_DEFAULT_EXTENSION = "org";
protected OrgFileType() {
super(OrgLanguage.INSTANCE);
}
@NotNull
... |
/* Dump out the mn10300 specific architecture information. */
static void
mn10300_dump_tdep (struct gdbarch *gdbarch, struct ui_file *file)
{
struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
fprintf_unfiltered (file, "mn10300_dump_tdep: am33_mode = %d\n",
tdep->am33_mode);
} |
/**
* Write font of a diagram component
*/
Element writeFont(IFontAttribute fontObject, Element styleElement) {
Element fontElement = new Element(ELEMENT_FONT, ARCHIMATE3_NAMESPACE);
try {
FontData fontData = null;
String fontString = fontObject.getFont();
i... |
import * as http from 'http';
// import { Subscription } from 'rxjs/Subscription';
// import { Observable } from 'rxjs/Observable';
// import { merge } from 'rxjs/operator/merge';
// import { FromEventObservable } from 'rxjs/observable/FromEventObservable';
// import { Subject } from 'rxjs/Subject';
import { Server... |
import React from 'react';
import { TileLayer as LeafletTileLayer } from 'react-leaflet';
import { LEAFLET } from '../constants';
export const TileLayer = () => (
<LeafletTileLayer
attribution={'© <a href="http://osm.org/copyright">OpenStreetMap</a> contributors'}
url={LEAFLET.TILE_SERVER_URL... |
/**
* Wraps calling the OnMaintenance() method that derived classes use to provide
* common exception handling.
*
*/
private void actionOnMaintenance() {
try {
onMaintenance();
} catch (Exception ex) {
}
} |
def EntityIdToArray(entity_type, entity_id):
onto_keys = OntologyClassKeys(entity_type)
dict_ids = SplitMoniker(entity_id)
try:
def decode_cgi_arg(a_key):
a_val_raw = dict_ids[a_key]
try:
val_decod = a_key.ValueDecode(a_val_raw)
return val_deco... |
Get this — there was a 3-week-old girl who was born pregnant with two fetuses.
According to ABC News, the baby girl, born in Hong Kong, had a condition called “fetus in fetu,” where an undeveloped fetus grows inside the womb of another baby (its twin). This happened back in 2010, but was recently unveiled in a study f... |
import { config } from '../../config';
import * as Utils from '../common/utils';
export default class NewEmployee {
name: string;
department: string;
location: string;
inTime: string;
outTime: string;
inTimeForCSV: string;
photo: string;
type: string;
id: number;
blobId: string;
camId: number;
... |
{-# LANGUAGE TupleSections #-}
-----------------------------------------------------------------------------
-- |
-- Module : XMonad.Hooks.DynamicIcons
-- Copyright : (c) <NAME> <<EMAIL>>
-- License : BSD3-style (see LICENSE)
--
-- Maintainer : <NAME> <<EMAIL>>
-- Stability : unstable
-- Portability ... |
// Do not test for null message, it cannot legally be null.
private static class EmptyActionDef implements ActionDef {
private static final long serialVersionUID = 1L;
StringWriter sw;
String name;
protected EmptyActionDef(StringWriter sw, String name) {
this.sw = sw;
... |
<filename>src/nordic32/plugins/protection/actions.go<gh_stars>0
package protection
import (
"hps"
nm "hps/networkmachine"
sm "hps/statemachine"
"nordic32/model"
q "nordic32/query"
"strconv"
)
func actions(network *model.Network, m *model.Link) {
query := createDisconnectionQuery(network, m)
m.PropertyOverload... |
def client_appointments():
if request.method == 'POST':
cid = request.form.get('search11')
if Client.query.get(int(cid)):
client = Client.query.get(int(cid))
answer = str([str(x.day.date) + ' @ ' + str(
x.time) for x in client... |
THE Y + LONG-BASELINE CONFIGURATION TO ACHIEVE HIGH RESOLUTION WITH ALMA
The ALMA array configuration design has been split into a compact array, an extended array, and a “zoom” spiral array which aims to connect them. The currently accepted extended array is a 14 km ring around Chascón. Based on Fourier plane coverag... |
def download():
url = "http://webspace.apiit.edu.my/"\
"intake-timetable/download_timetable/" + \
file_name
u = urllib2.urlopen(url)
f = open(file_name, 'wb')
meta = u.info()
file_size = int(meta.getheaders("Content-Length")[0])
print "Downloading data: %s bytes" % (file_size)
file_size_dl = 0
block_sz = 8 ... |
The fourth Tehran Auction has broken the all-time record of Iran’s art auctions thanks to the sale of a painting by Sohrab Sepehri for over $965,000 (€865,000), which brought the total revenue of the sales to over $7.25 million (€6.5 million).
The second most expensive sale of the event was another painting by the lat... |
import asyncio
import json
from typing import Awaitable
from unittest import TestCase
from unittest.mock import AsyncMock, patch
from hummingbot.connector.exchange.altmarkets.altmarkets_constants import Constants
from hummingbot.connector.exchange.altmarkets.altmarkets_websocket import AltmarketsWebsocket
from humming... |
<gh_stars>10-100
/* eslint-disable @typescript-eslint/ban-types */
import { ActionContext, Store } from 'vuex'
import { Ref } from '@vue/composition-api'
export type ModuleKey = 'state' | 'mutations' | 'actions' | 'getters'
export type VuexStore<R> = Store<R> & {
_modulesNamespaceMap: Dictionary<{
_rawModule: {
s... |
Single-Cell Gene Regulatory Network Analysis Reveals Potential Mechanisms of Action of Antimalarials Against SARS-CoV-2
The efficiency of antimalarials, chloroquine (CQ) and hydroxychloroquine (HCQ), in the prevention and treatment of coronavirus disease 2019 (COVID-19) is under intense debate. The mechanisms of actio... |
Update: Susannah lands a new gig
It was likely pressure from the Chicago Blackhawks organization itself and not CSN that led to Susannah Collins being dismissed from Comcast SportsNet Chicago.
Obviously, this is a severe over-reaction by the team in response to her simple “flub” Tuesday.
As you obviously know, Susan... |
#include "SceneManager/SceneManagerChooseHero.h"
#include "SceneGraph/DrawableNode.h"
#include "Party/CharacterClass.h"
#include "Controller/Localization.h"
#include "Controller/GameController.h"
#include "Party/ItemFactory.h"
#include "SceneManager/SceneManagerVillage.h"
SceneManagerChooseHero::SceneManagerChooseHero... |
import React, { useState } from "react"
import { useLocalStorage } from "./../utils/useLocalStorage"
interface IProps {
ingredients: string[]
}
function distinct(arr) {
return [...new Set(arr)]
}
export const IngredientList = ({ ingredients }: IProps) => {
const ListKey = `Ingredients/${typeof window !== "undef... |
<reponame>Wynand91/logs_analysis
# !/usr/bin/env python3
import psycopg2
class GetLog:
def __init__(self):
self.conn = psycopg2.connect('dbname=news')
self.cursor = self.conn.cursor()
self.to_be_printed = []
# create views
# total views per article
self.cursor.exe... |
def load_model_from_file(model: torch.nn.Module, model_file_path: Path) -> None:
if model_file_path.is_file():
try:
model.load_state_dict(torch.load(model_file_path))
except Exception as e:
logging.warning("Couldn't load model. Attempting to map CUDA tensors to CPU to solve e... |
// Called by Oboe audio callback implementation. It is called after AAP processing, and
// fill the audio outputs into an intermediate buffer, interleaving the results,
// then copied into the ring buffer.
void AAPMidiProcessor::fillAudioOutput() {
for (auto &data : instance_data_list) {
if (data-... |
Dispatch Family, We are just over seven weeks away from the Dispatch 2011 Tour kickoff! Brad, Chad, and Pete are practicing all the tunes - old and new - and they can't wait to get on stage and see all of you this summer. They have also been in and out of the studio working on some new material, and we are thrilled to ... |
<filename>resimpy/pcr/Amplify.py
__version__ = "v1.0"
__copyright__ = "Copyright 2022"
__license__ = "MIT"
__lab__ = "<NAME> lab"
from resimpy.util.random.Ordering import ordering as ranord
from resimpy.util.random.Sampling import sampling as ranspl
from resimpy.util.random.Number import number as rannum
from resimpy.... |
/**
* Send the message using multicast and use convergence to gather the
* results. Note that this routine must be synchronized because
* only one multicast can be active at a time; othewise, the client
* may get back an unexpected result. However, there can be many unicast
* requests active al... |
On the spin-observables in pseudoscalar meson photoproduction
Spin-observables in pseudoscalar meson photoproduction is discussed. This work is complementary to the earlier works on this topic. Here, the reaction amplitude is expressed in Pauli-spin basis which allows to calculate all the observables straightforwardly... |
/**
For conditions of distribution and use, see copyright notice in LICENSE
@file OgreMaterialUtils.cpp
@brief Utilitity functions for dealing with OGRE material scripts. */
#include "StableHeaders.h"
#include "DebugOperatorNew.h"
#include "OgreMaterialUtils.h"
#include "OgreRenderingModule.h"
#include... |
// ruleProcessPoints runs points through a rules conditions and and updates condition
// and rule active status. Returns true if point was processed and active is true.
// Currently, this function only processes the first point that matches -- this should
// handle all current uses.
func ruleProcessPoints(nc *natsgo.Co... |
package com.openvehicletracking.protocols.xtakip.hxprotocol;
import com.openvehicletracking.protocols.BaseCommandMessage;
import com.openvehicletracking.protocols.xtakip.XTakipProtocol;
/**
* Created by oksuz on 20/05/2017.
*
*/
public final class HXProtocolMessage extends BaseCommandMessage {
@Override
... |
<gh_stars>0
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
A, B = map(int, input().split())
S = input().strip()
import string
for v in S[:A]:
if v not in string.digits:
print('No')
sys.exit(0)
if S[A] != '-':
print('No')
sys.exit(0)
for v in S[A+1:]:
if v not in ... |
// GENERATED WITH generate-modules-sdk
// Warning: Do not edit by hand, all changes will be lost on next execution!
// TODO: This file should be excluded from (not only VSCode) auto-importing.
// @see https://github.com/Microsoft/vscode/issues/40248
// @see https://github.com/microsoft/TypeScript/issues/353... |
/**
* Merges content values with those coming from another source
*/
public synchronized <TYPE> void mergeWith(ContentValues other) {
if (setValues == null)
setValues = new ContentValues();
setValues.putAll(other);
} |
/// Update the box which contains buttons for opening pages (left side).
pub fn update_toc(&self, app_runtime: AppRuntime, book: &mut EpubBook) {
// Clear the whole box before adding new elements
for child in self.left_content_box.children() {
self.left_content_box.remove(&child);
}
... |
<filename>vendor/github.com/IBM-Cloud/terraform-provider-ibm/ibm/resource_ibm_multi_vlan_firewall.go<gh_stars>1000+
// Copyright IBM Corp. 2017, 2021 All Rights Reserved.
// Licensed under the Mozilla Public License v2.0
package ibm
import (
"fmt"
"log"
"strconv"
"strings"
"time"
"github.com/hashicorp/terrafor... |
// Find matching font from |font_set| for the given font family.
FcPattern* MatchFont(FcFontSet* font_set,
FcChar8* post_config_family,
const std::string& family) {
FcPattern* match = NULL;
for (int i = 0; i < font_set->nfont; ++i) {
FcPattern* current = font_set->fonts... |
/**
* Run some tests specific for {@link AStarBidirection}
*
* @author Peter Karich
* @see RoutingAlgorithmTest for test cases covering standard node- and edge-based routing with this algorithm
* @see EdgeBasedRoutingAlgorithmTest for test cases covering routing with turn costs with this algorithm
*/
public class... |
<reponame>usmile-ok/pangu
package main_test
import (
`github.com/pangum/pangu`
)
const filepathBanner = `./baner/github.png`
func bannerWithFilepath() {
panic(pangu.New(
pangu.Name("example"),
pangu.Banner(filepathBanner, pangu.BannerTypeFilepath),
).Run(newBootstrap))
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.