content stringlengths 10 4.9M |
|---|
//------------------------------------------------------------------------------
// testFieldListIndexing
// A collection of test functions for indexing into FieldLists with
// NodeIterators.
//
// Created by JMO, Wed Apr 14 11:10:22 2004
//------------------------------------------------------------------------------... |
package seed
import (
"github.com/romaxa83/mst-app/library-app/internal/models"
"gorm.io/gorm"
"time"
)
func CreateAuthor(db *gorm.DB, name, country, bio string, birthday, death_date time.Time) error {
return db.Create(&models.Author{
Name: name,
Country: country,
Bio: bio,
Birthday: birthda... |
/**
* Representation of an {@link Effect}. Useful to let the user interact with an
* effect (create/edit). Effects are relative to a
* {@link GraphicalOutputMonitor} instance.
*
* @param <T>
* is the type for the concentration
*/
@SuppressFBWarnings(value = "SE_BAD_FIELD", justification = "This class... |
def handle_cli_args():
args = parser.parse_args()
return tuple(repo_path_to_local_path(p) for p in
(args.first_repo, args.second_repo)), args.algorithm |
import 'phaser';
import '../consts/consts';
import { hackManGame } from '../index';
let scale: number;
const enum Orientation {
Portrait,
Landscape,
}
export class UIScene extends Phaser.Scene {
private _isMobile: boolean;
private _orientation: Orientation;
private _fullScreenButton: Phaser.GameObjects.Ima... |
<filename>find_duplicates_gui/src/main.rs
mod application;
mod duplicates_list;
mod exclusion;
mod find_duplicates;
mod main_window;
mod options;
mod path_choose;
mod string_list;
mod user_interaction;
mod utils;
mod widgets;
use gio::prelude::*;
fn main() {
let exit_status = application::create_application().run... |
def time_dhms_to_frac(dhmses):
fractions = list()
for dhms in dhmses:
day, hour, minute, second = dhms
fraction = day + hour / 24.0 + minute / (24.0 * 60.0) + \
second / (24.0 * 60.0 * 60.0)
fractions.append(fraction)
return fractions |
/**
* Use function that gets called when the item is used
*
* @param actor actor that uses the item
*/
public void use(Actor actor) {
durability--;
absUse(actor);
if (actor instanceof Player) {
removeInInventory(((Player) actor));
}
} |
package message
/*Voice Voice */
type Voice struct {
Message
MediaID string `xml:"media_id"` //语音消息媒体id,可以调用多媒体文件下载接口拉取数据。
Format string `xml:"format"` //语音格式,如amr,speex等
Recognition string `xml:"recognition"` //语音识别结果,UTF8编码
}
|
def _group_comparisons(comparisons):
def _get_group_name(name):
n, _, _ = name.partition(".")
return n
def _get_value_name(name):
_, _, n = name.partition(".")
return n
def _find_group(name):
for group in grouped_comparisons:
if group["name"] == name:
... |
Sample-size dependence of validation parameters in linear regression models and in QSAR
ABSTRACT The dependence of statistical validation parameters was investigated on the size of the sample taken in fit of multivariate linear curves. We observed that R 2 and related internal parameters were misleading as they overes... |
def testCWFCoeffCleanCTF(self):
mean_cov2d = self.cov2d.get_mean(
self.coeff, ctf_fb=self.ctf_fb, ctf_idx=self.ctf_idx
)
covar_cov2d = self.cov2d.get_covar(
self.coeff,
ctf_fb=self.ctf_fb,
ctf_idx=self.ctf_idx,
noise_var=self.noise_var,... |
class Configurator:
"""
Base class for monitor configurators (which is a very dumb name, by
the way).
"""
def __init__(self, config_file, **kwargs):
self._config_file = config_file
if 'host' in kwargs:
self.host = kwargs['host']
else:
self.host = get_... |
import { Component, Inject } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { Job } from '../models/job.model';
import { JobState } from '../models/jobstate.model';
@Component({
selector: 'app-job-list',
templateUrl: './job-list.component.html'
})
export class JobListComponent {
... |
async def on_shutdown(self):
await self._unregister_subscriptions()
self._accepting = False
for (ws, _) in self._subscribers:
await ws.close(code=aiohttp.WSCloseCode.GOING_AWAY,
message='Server shutdown') |
Historian Nancy L Cohen, whose latest book is The Making of America’s First Woman President, explains why voters care more about policy than gender
Pick up the new work by historian Nancy L Cohen, Breakthrough: The Making of America’s First Woman President, and you’ll find the former secretary of state’s name mentione... |
Owner's reply
So glad you like the Peanut Butter Fudge Khadiravan! The trick I used to get this fudge to set is due to some mysterious tendency of peanut butter to start becoming increasingly sticky as it's mixed with sugar. I don't quite know the science behind why this happens. If you were to use brown sugar instead... |
<reponame>peferron/air-quality<gh_stars>10-100
#[derive(Deserialize)]
pub struct Response {
pub status: String,
pub err: Option<String>,
}
|
Parathyroid Glands Hyperplasias Mimicking Medullary Thyroid Carcinoma Metastatic Lymph Nodes on 18F-DOPA PET/CT.
A pre operatory assessment by neck US, F-DOPA and F-choline PET/CT was performed in a 43-year-old MEN 2A woman affected by hyperparathyroidism and medullary thyroid carcinoma (MTC). On F-DOPA, two thyroid u... |
/**
* Helper which adds quotes to the given {@link CharSequence} if it contains any whitespace. For
* null or {@link CharSequence sequences} without whitespace the original will be returned.
*/
public static CharSequence quoteIfNecessary(final CharSequence chars) {
CharSequence result = chars;
... |
/**
* Launches JCite from the command line.
*
* <p>
* The command line arguments are as follows: <br>
* <code>-i file</code> defines the input file/pattern. <br>
* <code>-o file</code> defines the output file/folder. <br>
* <code>-r</code> specifies recursive descent into subfolders.<br>
* <code>-sp pat... |
Reliability of the melolabial flap for alar reconstruction.
OBJECTIVE
To review a series of alar reconstruction cases in which the melolabial flap was used.
DESIGN
Case series.
SETTING
University medical center and private practice.
PATIENTS
One hundred five consecutive patients with alar defects, resulting from... |
def cell_volumes(self):
if getattr(self, "_cell_volumes", None) is None:
if self.is_symmetric:
az = pi * (self.nodes_x ** 2 - np.r_[0, self.nodes_x[:-1]] ** 2)
self._cell_volumes = np.kron(self.h[2], az)
else:
self._cell_volumes = np.kron(
... |
Apple App Store Google Maps icon. (Photo: Jefferson Graham, USA TODAY) Story Highlights Jose Barrera's 14-year-old son was found shot near railroad tracks in 2009
He wants the image taken down out of respect for his son
It wasn't clear if Barrera had asked Google directly to take it down
RICHMOND, Calif. (AP) — A Sa... |
import numpy as np
import csv
import powerlaw
## Code adapted from Fofana and Hurford (2017)
width = 100
height = 100
N = 1000
T = 500
steplength = 2
## Simulate separate tracks
tracks = np.zeros((N, T, 2))
## Define powerlaw waiting time distribution
waitingtimes = powerlaw.Power_Law(xmin=5,parameters=[1.9])
for i... |
Learning-by-mediating. Reflexive mediation in action
This paper aims at sharing some reflections and results concerning some experiences carried out within a European interdisciplinary Erasmus+ project. The main themes are community and peer mediation, considered from the perspective of educational innovation and expe... |
Comparison of Escherichia coli isolates implicated in human urinary tract infection and avian colibacillosis.
Since avian pathogenic Escherichia coli (APEC) and human uropathogenic E. coli (UPEC) may encounter similar challenges when establishing infection in extraintestinal locations, they may share a similar content... |
n=int(input())
grid=[]
for i in range(2):
array=input().split()
grid.append(array)
for i in range(2):
for j in range(n):
grid[i][j]=int(grid[i][j])
def aa(i,k):
if k<=i:
return 0
if k>i:
return 1
sum=[]
for i in range(n):
sum.append(0)
# i magarutoko
for i in ra... |
package com.mauriciotogneri.tpgwear.wearable;
import android.content.Context;
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import com.google.android.gms.common.ConnectionResult;
import com.google.android.gms.common.api.GoogleApiClient;
import com.google.android.gms.common.api.GoogleA... |
use line_reader::read_file_to_lines;
use std::collections::HashMap;
pub(crate) fn day16_part1() -> String {
dance_once()
}
pub(crate) fn day16_part2() -> String {
dance_a_billion_times()
}
fn dance_once() -> String {
let moves = parse_dance_moves();
let mut programs = get_programs();
programs.dan... |
Observed/expected ratio analysis for hospital surgical efficiency instead of data envelopment analysis.
Tanaka et al. explained that ‘the assessment of OR performance has been previously conducted . . . at an individual hospital level and such indicators are unable to take into account differences in hospital size, ma... |
class Language:
def __init__(self, db_path_repo):
self.db_repo = dataset.connect('sqlite:///' + db_path_repo)
"""
Insert programming language information for each GitHub repository into the database.
@params [dict] langs is [List Languages](https://developer.github.com/v3/repos/#list-languages)... |
<reponame>snapiz/go-vue-starter
package cgo
import (
"fmt"
"strings"
"github.com/graphql-go/graphql"
)
// UserRoleType role of user
var UserRoleType = graphql.NewEnum(graphql.EnumConfig{
Name: "UserRole",
Description: "The role of the user",
Values: graphql.EnumValueConfigMap{
strings.ToUpper(ContextR... |
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#pragma once
#include "watchman/saved_state/SavedStateInterface.h"
namespace watchman {
// Identifies the most recent saved st... |
def _str_to_val(p, par, pvals, pars):
m = re.search(r"\{([0-9])\}", p)
if m is None:
raise NotImplemented('This should never happen.')
num = int(m.group(1))
prefix = p.split(m.group(0))[0]
return pvals[pars.index('{0!s}{{{1}}}'.format(prefix, num))] |
use std::collections::VecDeque;
use std::time::{Duration, Instant};
use crate::model::{ComponentStats, StatusColor};
const DEFAULT_STAT_WINDOW: Duration = Duration::from_secs(5 * 60);
#[derive(Debug)]
pub struct StatTracker {
stat_window: Duration,
current_color: StatusColor,
// Events at the back of the... |
/*
* Copyright (c) 2009, 2016, Oracle and/or its affiliates. All rights reserved.
* ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*/
package jdk.vm.ci.code;
import jdk.vm.ci.meta.ValueKind;
/**
* Represents a target machine register.
*/
pu... |
n = int(input())
t = list(map(int, input().split()))
if(n==1 or t[0]>15):
if(t[0] > 15):
print(15)
else:
print(t[0]+15)
else:
watchtime = 0
for i in range(1,n):
if(t[i]-t[i-1] >15):
watchtime=t[i-1]+15
break
if watchtime == 0:
wat... |
def assemble_html_with_graphs_from_page_config(single_page_config_dict: dict) -> list:
plot_specs = []
for plot_key, plot_specification in single_page_config_dict.items():
plot_data_handler = current_app.config.data_handler(
plot_specification[DATA_SOURCES]
)
(plot_directions... |
/**
* Method called to map a JSON Object into a Java value.
* @param jp
* @param ctxt
* @return RubyObject
* @throws java.io.IOException
* @throws com.fasterxml.jackson.core.JsonProcessingException
*/
protected RubyObject mapObject(JsonParser jp, DeserializationContext ctxt)
... |
A Video Captioning Method Based on Multi-Representation Switching for Sustainable Computing
: Video captioning is a problem that generates a natural language sentence as a video’s description. A video description includes not only words that express the objects in the video but also words that express the relationship... |
.
Within the purview of a formation day in Allergy for General Practitioners, this presentation on prevention recalls recent data obtained by the expedient of epidemiological studies, the aim of which was to aquaint the treating physicians with the growth in prevalence of the diseases of allergy and to alert them to t... |
Open dissent at the Fed continues. I first talked about this a week ago in Infighting At The Fed. Today Lacker Says Fed Loans to Wall Street Risk More Crises.
Richmond Federal Reserve Bank President Jeffrey Lacker said the lending to securities firms that the central bank introduced in March may lay the seeds of furth... |
<reponame>shnishiyama/smtt-composition
{-# LANGUAGE NoStrict #-}
{-# LANGUAGE OverloadedLists #-}
{-# LANGUAGE TemplateHaskell #-}
module Data.Tree.Trans.MAC
( -- common
MacroTreeTransducer
, MttTransducer
, MttConstraint
, buildMtt
, RightHandSide
, pattern MttContext
, pattern MttState
, p... |
def det_explicit(self, input):
mo_up, mo_down = self.get_slater_matrices(input)
return (torch.det(mo_up) * torch.det(mo_down)).transpose(0, 1) |
def callback():
global title
global url
global tags
r = redis.client.StrictRedis(host='redis', decode_responses=True)
sub = r.pubsub()
sub.subscribe('awesome')
while True:
for m in sub.listen():
title = ''
url = ''
tags = ''
if m['data'... |
// GetServerHTTPSPort return the https port used by go-microservice.
func GetServerHTTPSPort(s Server) int {
value, err := strconv.Atoi(os.Getenv("SERVER_HTTPS_PORT"))
if *flagHTTPSPort != -1 {
return *flagHTTPSPort
} else if err == nil {
return value
} else if s.HTTPSPort != -1 {
return s.HTTPSPort
}
retur... |
/**
* @license
* Copyright 2019 Google 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... |
/* alps/ALPS_SW/TRUNK/MAIN/alps/kernel/drivers/hwmon/mt6516/hwmsen_helper.c
*
* (C) Copyright 2009
* MediaTek <www.MediaTek.com>
*
* Sensor helper
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software... |
// NewContourLine returns a contourLine object.
func NewContourLine(lineNum int) *contourLine {
return &contourLine{
lineNum: lineNum,
}
} |
import httpStatuses, { HttpStatus } from 'http-statuses';
import ajvFactory from './services/moleculer.service/validator/ajvFactory';
const type = 'app';
const ajvValidator = ajvFactory();
export = (value: any, schema: object, httpStatus: HttpStatus = httpStatuses.BAD_REQUEST) => {
const isValid = ajvValidator.val... |
On his nationally syndicated radio talk show Tuesday, Mark Levin hosted Conservative Review’s Daniel Horowitz who spoke about Obamacare and the House Republican’s health care bill meant to replace it, saying that the new health care bill “doesn’t repeal” Obamacare and “wil make it worse.”
“[T]he essential element is n... |
The technology to make biobutanol, a non-food based biofuel, cost-competitive with gasoline isn’t here yet, but companies in the know say that it could be by 2010.
[social_buttons]
Regardless of how the debate between corn ethanol and second-generation, non-food ethanol (cellulosic ethanol) pans out, we may be arguin... |
<filename>src/docker-compose.ts
import execa = require('execa');
import {DockerMachineEnv} from './docker-machine'
import { ToolingDependecy } from './model';
import { CLIError } from '@oclif/errors';
import { DockerPsResult, Docker } from './docker';
export abstract class DockerComposeTool extends ToolingDependecy{
... |
def convert_to_index(data, dataset, result):
n_lines = len(data)
with ProcessPoolExecutor() as executer:
for i in tnrange(n_lines, desc='Converting', unit=' lines'):
sentence_to_index(data[i], dataset, result[i]) |
def wall_move(self, frompos='wall_block', topos='wall_away'):
og_pose = self.poses[frompos]
new_pose = self.poses[topos]
self.grasp_obj_at_pose(og_pose, 'wall', lift=True)
self.move_to_loc(new_pose[0], self.heights['wall']['drag'])
self.move_to_loc(new_pose[0], self.heights['wall... |
MIXGAN: Learning Concepts from Different Domains for Mixture Generation
In this work, we present an interesting attempt on mixture generation: absorbing different image concepts (e.g., content and style) from different domains and thus generating a new domain with learned concepts. In particular, we propose a mixture ... |
def balloonlist(balloondirs, isthink):
extension = '.think' if isthink else '.say'
balloonset = set(j for i in balloondirs for j in _get_file_list(i, extension))
_print_columnised([(balloon, balloon) for balloon in balloonset]) |
/**
* Computes the inverse of a square matrix.
* <p>
* This algorithm is implemented for both real and complex valued equation
* systems.
* And each method is again available in two version.
* <p>
* One version is an optimized version that consumes as few resources as
* possible.
* Moreover it is possible to p... |
<reponame>kennyzhu2013/sfuforrtp<filename>pkg/webrtc/peer.go
package webrtc
import (
"github.com/pion/webrtc/v3"
"sync"
)
// local peer: only one tack.
type Peer interface {
ID() string
Session() Session
Publisher() *Publisher
Subscriber() *Subscriber
Close() error
// 这个版本不支持channel.
// SendDCMessage(label ... |
/*
Copyright 2018 <<NAME>>
3-Clause BSD License
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer... |
<filename>source/class_DDE/tools/parser.c
#include "parser.h"
int parser_read_file(
char * filename,
struct file_content * pfc,
ErrorMsg errmsg
){
FILE * inputfile;
char line[_LINE_LENGTH_MAX_];
int counter;
int is_data;
FileArg name;
FileArg value;
class_open(inputfile,filen... |
<filename>src/main/java/rbasamoyai/industrialwarfare/common/items/LabelItem.java<gh_stars>0
package rbasamoyai.industrialwarfare.common.items;
import java.util.UUID;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.entity.player.ServerPlayerEntity;
import... |
def variational_distribution(self):
chol_variational_covar = self.chol_variational_covar
diagonal = lazify(chol_variational_covar).diag()
dtype = chol_variational_covar.dtype
device = chol_variational_covar.device
strictly_lower_mask = torch.ones(self.chol_variational_covar.shape... |
//===- sparse_tensor.c - Test of sparse_tensor APIs -----------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM
// Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===------------------------... |
Effect of cyclic GMP produced by natriuretic peptides on osteoblast‐like MC3T3‐E1 cells
The C‐type natriuretic peptide (10‐7 M) and atrial natriuretic peptide (10‐7 M) enhanced cGMP accumulation by 418 and 83 times the control value, respectively, in osteoblast‐like MC3T3‐E1 cells. The natriuretic peptide B receptor w... |
export abstract class Entity implements odata.entities.IEntity {
"@odata.type": string;
"@odata.etag": string;
id: number;
rowVersion: any[];
constructor(type: string) {
this.id = 0;
this["@odata.type"] = "SoftwareManager.BLL.Contracts.Models." + type;
}
}
|
/* Obtain the current verbosity level (as stablished by the
'set verbositylevel' command. */
int
ui_out_get_verblvl (struct ui_out *uiout)
{
return 0;
} |
A provincially supplied weatherproof tent will let the Moss Park safe-injection site stay open in cold weather after all. Volunteers, who in the summer opened the unsanctioned site as an emergency reaction to the deadly overdose crisis, had said Sunday they couldn’t use the tent provided by Ontario’s Emergency Medical ... |
/* eslint-disable no-console */
import c from 'picocolors'
import dictionary from '../dict.json'
export const IGNORE_KEY = '@case-police-ignore'
export function buildRegex(dictionary: Record<string, string>): RegExp {
const keys = Object.keys(dictionary)
const regex = new RegExp(`\\b(${keys.join('|')})\\b`, 'gi')... |
package init
import (
"crypto/ecdsa"
"errors"
"github.com/0xPolygon/polygon-edge/command"
"github.com/0xPolygon/polygon-edge/crypto"
"github.com/0xPolygon/polygon-edge/secrets"
"github.com/0xPolygon/polygon-edge/secrets/helper"
libp2pCrypto "github.com/libp2p/go-libp2p-core/crypto"
"github.com/libp2p/go-libp2p... |
package arrays;
public class ThueMorse {
public static void main(String[] args) {
int squareSideLength = Integer.parseInt(args[0]);
int[] sequence = new int[squareSideLength * squareSideLength];
for (int i = 1; i < sequence.length; i++) {
if (i%2==0) {
sequence[i... |
/**
* Copyright (c) 2009-2010 Misys Open Source Solutions (MOSS) and others
*
* 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.... |
//
// Created by <NAME> on 2018-12-21.
// Copyright (c) 2018 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
@class CollectionItemViewModel;
@protocol KanbanService;
@protocol UserService;
@interface CollectionViewModel : NSObject
@property(nonatomic, copy) void (^onItems)(NSArray<CollectionItemVie... |
Red Curry Green Beans – Green Beans Stir fry with red curry paste, kaffir lime, sugar and chile. Pad Prik King Vegan Glutenfree Soyfree Nutfree Recipe
Jump to Recipe
I have always loved the green beans with the hot phrik khing sauce from Thai restaurants. So I decided to make some myself. The traditional version uses... |
<filename>usersMap.go
package ws
import (
"sync"
)
// *User map
type usersMap struct {
sync.RWMutex
users map[interface{}]*User
}
func newUsersMap() *usersMap {
return &usersMap{users: make(map[interface{}]*User)}
}
func (m *usersMap) Set(key interface{}, val *User) {
m.Lock()
m.users[key] = val
m.Unlock()
}... |
<gh_stars>10-100
import os
import numpy as np
import nibabel as nb
from glob import glob
import seaborn as sns
from nilearn.image import mean_img, concat_imgs, math_img, resample_to_img
from nilearn.plotting import plot_anat
from matplotlib import pyplot as plt
sns.set_style('darkgrid')
plt.style.use('seaborn-colorblin... |
/**
* Created by yume on 17-4-20.
*/
@SuppressWarnings({"unchecked, rawtypes"})
public final class RenderCompiler implements BaseRendererCompilerStates.RPLayout, BaseRendererCompilerStates.RPMain, BaseRendererCompilerStates.RPTypedCollectionCompile {
@NonNull
private Function<Object, Integer> layoutForItem;
... |
/**
* 2 same rack endpoints
* 1 same datacenter, different rack endpoints
* 1 external datacenter
*
* @throws java.net.UnknownHostException
*/
@Test
public void testBigIntegerEndpointsC() throws UnknownHostException
{
RackInferringSnitch endpointSnitch = new RackInferringSn... |
<reponame>nikitavlaev/embox
/**
* @file
* @brief Creates special file in virtual file systems
*
* @date 23.08.2013
* @author <NAME>
* @author <NAME>
*/
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <drivers/flash/emulator.h>
static void print_usage(void) {
printf("Usa... |
I do not come here as an advocate, because whatever position the suffrage movement may occupy in the United States of America, in England it has passed beyond the realm of advocacy and it has entered into the sphere of practical politics. It has become the subject of revolution and civil war, and so tonight I am not he... |
/**
* Set up server and start receiving file from client.
*/
public void start() {
try {
server_socket = new DatagramSocket(port);
} catch (SocketException e) {
System.err
.println("Could not start server socket on port: " + port);
System... |
// Copyright (c) 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "components/translate/core/browser/translate_manager.h"
#include "chrome/browser/chrome_notification_types.h"
#include "chrome/browser/prefs... |
Towards Representative Metallurgical Sampling and Gold Recovery Testwork Programmes
When developing a process flowsheet, the risks in achieving positive financial outcomes are minimised by ensuring representative metallurgical samples and high quality testwork. The quality and type of samples used are as important as ... |
import {AbstractContentService} from "./abstract.content.service";
import {InjectRepository} from "@nestjs/typeorm";
import {Repository} from "typeorm";
import {Video} from "./entities/video.entity";
import {Injectable, NotFoundException} from "@nestjs/common";
import {CreateVideoDto} from "./dto/create-video.dto";
imp... |
<filename>src/game/cards/artifact/BookOfChanges.ts
import { Card } from '../../../common/Card';
import { Suit } from '../../../common/Suit';
import { suits, SUIT_ARTIFACT } from '../../suits';
export class BookOfChanges extends Card {
constructor() {
super({
id: 8,
suit: SUIT_ARTIFACT,
name: 'B... |
def load(pathname):
fh = open(pathname, "rb")
data = pickle.load(fh)
fh.close()
return data |
package com.straphq.strapkit.framework.view;
import android.app.Activity;
import android.content.Context;
import android.view.Gravity;
import android.view.ViewGroup;
import android.widget.TextView;
import com.straphq.strapkit.framework.R;
import com.straphq.strapkit.framework.StrapKitBaseActivity;
/**
* Created by ... |
def _CreateInfoFile(java_files, options, srcjar_files):
info_data = dict()
for java_file in java_files:
package_name, class_names = _ParsePackageAndClassNames(java_file)
for class_name in class_names:
fully_qualified_name = '{}.{}'.format(package_name, class_name)
info_data[fully_qualified_name]... |
/*
* Copyright (C) 2015 The Android Open Source Project
*
* 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 app... |
Combined use of bone graft and Biotes fixtures in the treatment of the severely resorbed upper jaws.
Horse-shoe shaped bone grafts from the hip together with biotes self-tapping fixtures were used to rehabilitate patients with extremely resorbed upper jaws. Our experience and results from the 10 first consecutive case... |
/**
* Reads and parses the GraphQL response from the given filename.
*
* @param filename The file with the GraphQL JSON response.
* @return A parsed GraphQL response object.
*/
private GraphqlResponse<Query, Error> readGraphqlResponse(String filename) {
if (graphqlResponsesCache.contai... |
/**
* Main container class for the Disrespector. Here we store two connections - one attached to a DIS
* network and the other to a HLA/RPR network. We have listeners in place that simply exchange
* the data received between each of them.
*/
public class Disrespector
{
//-------------------------------------------... |
def summarize_team_annotations(members):
counts = dict()
total = 0
for member in members:
member_counts = count_user_annotations(member)
member_count = sum(member_counts.values())
counts[member.username] = member_count
total += member_count
counts['total'] = total
ret... |
<filename>src/main.rs
use auth::{with_auth, Role};
use error::Error::*;
use serde::{Deserialize, Serialize};
use std::collections::HashMap;
use std::convert::Infallible;
use std::sync::{Arc, RwLock};
use warp::{reject, reply, Filter, Rejection, Reply};
mod auth;
mod error;
type Result<T> = std::result::Result<T, erro... |
package main
import "./typedef_class"
func main() {
a := typedef_class.NewRealA()
a.SetA(3)
b := typedef_class.NewB()
b.TestA(a)
}
|
import * as React from "react";
import { IEmojiProps } from "../../styled";
const SvgEvent19 = (props: IEmojiProps) => (
<svg viewBox="0 0 72 72" width="1em" height="1em" {...props}>
<g stroke="#000">
<circle
cx={36}
cy={21}
r={9}
fill="none"
strokeMiterlimit={10}
... |
<reponame>unionhills/trading-planner-svc
import { Provider } from '@nestjs/common';
import { Test, TestingModule } from '@nestjs/testing';
import { TradingPlansService } from './trading-plans.service';
import { TRADING_PLANS_REPOSITORY_INTERFACE_PROVIDER } from './trading-plans.repo';
import { TradingPlansInMemoryRepos... |
Effect of Escherichia coli biomass composition on central metabolic fluxes predicted by a stoichiometric model.
The amino acid composition of proteins and the fatty acid composition of the cell membranes were measured in Escherichia coli growing exponentially in batch culture on glucose, succinate, glycerol, pyruvate,... |
/**
* Download zip and extract to target directory
*/
import got from 'got';
import unzip from 'unzip-stream';
export async function extract(sourceUrl: string, targetPath: string) {
return new Promise((resolve, reject) => {
got
.stream(sourceUrl)
.pipe(unzip.Extract({ path: targetPath }))
.o... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.