text stringlengths 1 1.04M | language stringclasses 25 values |
|---|---|
{
"Terra.icon.IconConsultInstructionsForUse.title": "Symbol 'Elektronische Gebrauchsanweisung'"
}
| json |
#!/usr/bin/env python
# encoding: utf-8
"""
evaluate.py
Created by Shuailong on 2016-12-2.
Evaluate model accuracy on test set.
"""
from __future__ import print_function
from time import time
from keras.models import load_model
import os
from utils import true_accuracy
from dataset import get_data
from train import MODEL_FILE, MODEL_DIR
from train import data_generator
def main():
start_time = time()
print('\nGetting data...')
data = get_data(force=False)
X_test = data['X_test']
X_test_feats = data['X_test_feats']
y_test = data['y_test']
tag_size = len(data['tag_index'])
print('\nLoading models...')
model = load_model(os.path.join(MODEL_DIR, MODEL_FILE), custom_objects={'true_accuracy': true_accuracy})
print('\nEvaluating...')
_, true_acc = model.evaluate_generator(data_generator(X_test, X_test_feats, y_test, tag_size),
val_samples=len(X_test))
print('Test accuracy: {}.'.format(true_acc))
seconds = time() - start_time
minutes = seconds / 60
print('[Finished in {} seconds ({} minutes)]'.format(str(round(seconds, 1)),
str(round(minutes, 1))))
if __name__ == '__main__':
main()
| python |
Wyoming Republican Sen. John Barrasso on Friday accused Sen. Chuck Schumer of using the impeachment trial of President Trump as a cudgel against swing-state Republican senators to further his aspiration to serve as Senate majority leader.
Barrasso, the chairman of the Republican Senate Conference, said the Democratic leader is trying to squeeze senators facing tough reelection fights in Maine, North Carolina, Arizona and Colorado with his relentless pressure for new witnesses and documents.
“This is about Susan Collins. This is about Thom Tillis. This is about Martha McSally. This is about Cory Gardner,” Barrasso, R-Wyo. , said of GOP senators in hard races. “Chuck Schumer has said as much. Only part of it is about removing President Trump and taking his name off of the ballot. "
“It is also about Chuck Schumer trying to make himself a majority leader of the United States Senate, and there's no way to deny it,” he said.
If Democrats win back the Senate in November, Schumer, a New York Democrat, would be in line to succeed Sen. Mitch McConnell as majority leader next year.
Earlier this week, Schumer forced votes on 11 amendments in a broader effort to get new evidence admitted into the trial. Ten of the amendments went down along party lines with only Collins breaking from her party on one Schumer amendment to allow for more time to file motions.
Democrats repeatedly have argued that the public wants to see documents and witnesses the White House has been blocking, including testimony from acting chief of staff Mick Mulvaney and former National Security Advisor John Bolton. With only 47 votes in the Senate, Schumer needs four GOP defections to win the majority vote needed to issue subpoenas for the new information.
But Republican leaders want a swift trial to acquit Trump without new witnesses and argue if the case for impeachment was so strong in the House, Democrats wouldn’t need the additional information.
On the third and final day of the House impeachment managers’ opening case, Republicans complained the Democrats’ arguments were becoming repetitive and tiresome and argued the Senate shouldn’t be calling witnesses the House failed to get.
“It became mind-numbing,” said Sen. Lindsey Graham, R-S. C. , chairman of the Senate Judiciary Committee.
Graham on Friday called for Joe and Hunter Biden’s Ukraine dealings to be investigated -- but after the impeachment trial concluded.
“This needs to end,” he said. | english |
# 【模拟考试】试题1
# 问题描述
一个整数数组中的元素有正有负,在该数组中找出一 个连续子数组,要求该连续子数组中各元素的和最大,这个连续子数组便被称作最大连续子数组。比如数组{2,4,-7,5,2,-1,2,-4,3}的最大连续子数组为{5,2,-1,2},最大连续子数组的和为5+2-1+2=8。问题输入就是一个数组,输出该数组的“连续子数组的最大和”。
# 样例
首先由终端输入一个数n,0 < n < 100,然后依次是n个整数的输入,输入完毕后计算并输出该数组的最大连续子数组之和,接着在下一行输出该子数组,注意输出该子数组的时候,最后一个数之后没有空格,但是有回车符。例如输入为:
4
3
-2
5
-1
输出为:
6
3 -2 5
# 提示
最基础的方法,使用多重循环计算所有连续子数组的和并保存最大的那个。如对效率有要求,可以使用动态规划等时间复杂度更低的方法。
| markdown |
package com.danielsundberg.yarr;
import android.content.Context;
import android.content.Intent;
import android.webkit.JavascriptInterface;
import android.webkit.WebView;
import android.widget.ShareActionProvider;
import android.widget.Toast;
public class YARRWebAppInterface {
private WebView mWebView;
private Context mContext;
/** Instantiate the interface and set the context */
YARRWebAppInterface(Context c, WebView webView) {
mContext = c;
mWebView = webView;
}
/** Show a toast from the web page */
@JavascriptInterface
public void shareUrl(String title, String url) {
Intent share = new Intent(android.content.Intent.ACTION_SEND);
share.setType("text/plain");
// Add data to the intent, the receiving app will decide
// what to do with it.
share.putExtra(Intent.EXTRA_SUBJECT, title);
share.putExtra(Intent.EXTRA_TEXT, url);
mContext.startActivity(Intent.createChooser(share, "Share blog post!"));
}
public void initCallbacks() {
String jsCommand = String.format("javascript:window.ContainerAppCallbacks.init(\"%s\", \"%s\")",
BuildConfig.aarrstat_api_url, BuildConfig.aarrstat_api_key);
mWebView.loadUrl(jsCommand);
}
public void onResume() {
String jsCommand = String.format("javascript:window.ContainerAppCallbacks.onResume()");
mWebView.loadUrl(jsCommand);
}
public void onPause() {
String jsCommand = String.format("javascript:window.ContainerAppCallbacks.onPause()");
mWebView.loadUrl(jsCommand);
}
}
| java |
<filename>tslint.json<gh_stars>1-10
{
"defaultSeverity": "error",
"extends": [
"tslint:all"
],
"jsRules": {},
"rules": {
"quotemark": [true, "single"],
"trailing-comma": [
true,
{
"multiline": {
"objects": "always",
"arrays": "always",
"functions": "never",
"typeLiterals": "ignore"
},
"esSpecCompliant": true
}
],
"no-unused-expression": false,
"no-empty": false,
"no-var-requires": false,
"file-name-casing": [false, "pascal-case"],
"completed-docs": false,
"no-magic-numbers": false,
"no-inferrable-types": false,
"no-any": false,
"no-require-imports": false,
"no-this-assignment": false,
"no-implicit-dependencies": false,
"newline-per-chained-call": false,
"no-unsafe-any": false,
"member-ordering": false,
"variable-name": false,
"no-unbound-method": false
},
"rulesDirectory": []
}
| json |
<gh_stars>1-10
import styles from "./styles.module.scss"
const ResultNotFound = ({ message = "Something went wrong" }) => {
return (
<div className={styles.container}>
<h3 className={styles.resultNotFound}>{message}</h3>
</div>
)
}
export default ResultNotFound
| javascript |
{"artist_id":"AR9BVRM1187FB51139","artist_latitude":32.67828,"artist_location":"Georgia","artist_longitude":-83.22295,"artist_name":"<NAME>","duration":206.07955,"num_songs":1,"song_id":"SOMBFUV12AB018628E","title":"Sheer Heart Attack","year":2006} | json |
Rumours have become a part and parcel of the celebrity lifestyle. Every person who is in the public eye have got used to coping up with fake news about them. While most of the celebrities ignore it and move on, some others respond to it. But there are some rumours that are quite sensitive and hurts the stars.
Pawan Kalyan's ex-wife and actress Renu Desai faced a similar kind of rumour recently. The news of Renu Desai getting tested positive for Coronavirus went viral on the internet. This false news spread like wildfire and the ‘Badri' heroine decided to clarify that.
She was angry with this false news as she wrote, "Writing false stories about something testing positive about Covid is not funny! People are dying and it's a pandemic not some film gossip material! And for the people telling me to ignore those idiots is not right. Corona is a series topic so please I can't just keep quiet and ignore false news about this! "
She shared this on social media and made sure that such rumour doesn't come up again. | english |
<gh_stars>0
export type FileExtensionType = 'xlsx' | 'csv';
export type CellType = string | number | boolean | Date | object;
export type ExcelFileOptions = {
isNameHasDateTime?: boolean;
extension?: FileExtensionType;
};
export type ExcelDownloadButtonProps = {
fileName: string;
data: CellType[][];
options?: ExcelFileOptions;
style?: React.CSSProperties;
element?: React.ReactElement;
};
export type ExcelColumnsType<TData = Record<string, unknown>> = {
label: string;
propName: string;
mapValue?: (record: TData) => CellType;
}[];
| typescript |
<reponame>napile/napile.jvm
package org.napile.vm.objects.classinfo;
import java.util.List;
import org.jetbrains.annotations.NotNull;
import org.napile.asm.Modifier;
import org.napile.asm.resolve.name.FqName;
import org.napile.asm.tree.members.AnnotationNode;
import org.napile.asm.tree.members.MethodParameterNode;
import org.napile.asm.tree.members.types.TypeNode;
import com.intellij.util.ArrayUtil;
/**
* @author VISTALL
* @since 18:24/02.02.13
*/
public class CallParameterInfo implements ReflectInfo
{
private final MethodParameterNode methodParameterNode;
public CallParameterInfo(MethodParameterNode methodParameterNode)
{
this.methodParameterNode = methodParameterNode;
}
public TypeNode getReturnType()
{
return methodParameterNode.returnType;
}
@Override
public ClassInfo getParent()
{
return null;
}
@NotNull
@Override
public String getName()
{
return methodParameterNode.name.getName();
}
@NotNull
@Override
public FqName getFqName()
{
return FqName.ROOT;
}
@Override
public boolean hasModifier(@NotNull Modifier modifier)
{
return ArrayUtil.contains(modifier, methodParameterNode.modifiers);
}
@Override
public Modifier[] getModifiers()
{
return methodParameterNode.modifiers;
}
@Override
public List<AnnotationNode> getAnnotations()
{
return methodParameterNode.annotations;
}
}
| java |
The arrest of two men in Delhi on May 8 led to the discovery of a terror network that shook the security agencies, writes Tushar Srivastava.
May 8, 2006: Rahil’s name first surfaced on the intelligence radar. And on July 11, he became one of the country’s most wanted terrorists. The Mumbai police suspect the mastermind of October’s pre-Diwali blasts in Delhi to be the brain behind Tuesday’s serial explosions on Mumbai’s suburban trains.
Rahil, a Lashkar-e-Taiba (LeT) operative, had allegedly planned and executed last year’s Delhi blasts killing over 60 people. In the second week of April, the Delhi police special cell had received information that Lashkar was planning a major strike in the capital.
On the basis of the leads, the police on May 8 busted a LeT sleeper cell in the capital. Two militants — Firoz Latif Ghaswala alias Abdullah and Mohammed Ali Chhipa alias Ubedullah — were arrested from Nizamuddin railway station with four kilograms of RDX, four detonators and Rs 50,000 in cash.
Interrogation revealed that the consignment was meant for Mohammed Iqbal alias Abu Hamza, a Pakistani Lashkar commander, whom they had to meet the same evening near the Jawaharlal Nehru stadium. Three special cell teams set up an ambush and Hamza was shot dead in an encounter.
Subsequent search of Hamza's Ballabhgarh (Haryana) residence shocked the police. The raids threw up 2 AK-56 rifles, six magazines, 179 cartridges, 10 hand grenades, five kg of PETN explosives, three litres of nitric acid, one litre of glycerine, three kilograms of urea, a satellite phone and a computer.
Abdulla and Ubedullah spilled the beans about a terrorist network that shook the security agencies. They said the Lashkar's network spread across Gujarat to Mumbai in the west and covered Delhi and Kashmir in the north.
The fact that Lashkar was scoping out Mumbai was first revealed by the duo. The information was conveyed to the Mumbai police, which recovered huge caches of AK 47s and RDX from different parts of the state. Rahil had even planned to target the film award functions in the south and a meeting of film producers in Mumbai. But both the bids were foiled after which he fled his Mahim hideout.
Rahil, say intelligence officers, is a smart young man who has worked his way up the outfit to become one of the most influential operatives outside Kashmir. A recruiter, he sent boys for training to Pakistan and Bangladesh. According to intelligence agencies, Rahil had managed to brainwash several men in Gujarat and Mumbai and sent them to train under Lashkar commander Azam Cheema. | english |
Do dynasties have credibility to question Savarkar’s patriotic valour?
Defiant Rahul says his fight will continue,” writes a leading English daily in its front page headline two days after a Surat court found Rahul Gandhi’s GE-2019 election rally remark in Karnataka against the Modi’ surname defamatory and got him convicted.
Defiant Rahul says his fight will continue,” writes a leading English daily in its front page headline two days after a Surat court found Rahul Gandhi’s GE-2019 election rally remark in Karnataka against the Modi’ surname defamatory and got him convicted. This was followed by the Lok Sabha Secretariat’s disqualification of him from his Parliament membership as per the law of the land, which had been applied in several cases before and validated by the Supreme Court in related cases in the past.
Here, it is necessary to mention what The Hindustan Times wrote on May 10, 2020, under the headline, “Rahul Gandhi’s unconditional apology to the SC in the Rafale contempt case, requests the top court to drop proceedings. ” The above reminder clears up the assumption that the Grand Old Party’s first family scion is habituated to making defamatory remarks (for vested interests) and, when caught, apologizes. Why did Rahul apologize in this case? Is it to save himself from punishment? In the present case, too, his apology may not be ruled out.
And what kind of political credibility does Rahul Gandhi have except his birth to a political family responsible for the undemocratic hijack of the newly independent country’s first PMship from Sardar Patel, for keeping the country backward in every field for several decades post-independence, dislodging the largest numbers of elected state governments, spoiling the judiciary’s image, which led to the now-in-force undemocratic collegiums system, the imposition of draconian national emergencies, engineering the dreaded Kashmir and Punjab crises, facilitating the 1984 anti-Sikh riots, allowing Union Carbide gas leak accusing Anderson to leave the country in a government helicopter, and hundreds of unprecedented scams, starting with the Nehru era’s Jeep Scam to the now exposed National Herald scam?
But the mute question is: Why does Rahul Gandhi indulge in this kind of abusive politics? And again, it is not that he is alone in indulging with liberty in this kind of activity in Indian politics. There are many such politicians in almost all political parties, many of them even holding constitutional positions. Certainly, this is not what India, the largest democracy in the world, which is celebrating Amritkaal of her independence, expects from senior politicians, and certainly not from the leader and party that respectively claim all the credits for getting the country’s independence (self-interpreted) to justify the dynasty rule.
Post-Surat court conviction, Rahul Gandhi has earned strong support from opposition parties, including mostly the regional parties; many of them are also ruling parties in some states; and one or two national parties, now reduced to occasional visibility in newspaper reports, on the street with red flags, and in some varsity campuses, which can be safely branded as ‘sign-board parties’, the verbatim invented by former Odisha Chief Minister late Biju Patnaik for Jan Sangh, the present ruling party’s early avatar. There are some common threads among these newly-found Rahul well-wishers and the Congress Party. During the early days of post-independence, all national parties survived sloganeering against the Nehru-Gandhi dynasty-headed Central Government’s so-called Western-tilted economic policies, diplomacies, dynasty politics, and corruption, while the regional parties came into existence mostly in the 1980s and 1990s fighting Nehru-Gandhi’s corruption and dynasty politics. But tragedy is: majority of these parties are now found most corrupts and dynasties owned in equal terms with Nehru-Gandhi dynasty. Some of these parties’ leaders are now convicted and charged by the courts for corruption, and that too while they were in power. And all of them suffered electoral rejections because of corruption and bad governance. It is a different matter that India’s political dynamics have got them elected time and again.
It means all the opposition parties are united to save their undemocratic dynasty politics and want the rationalization of corruption as an integral part of Indian politics, supporting Rahul Gandhi’s diatribe against Veer Savarkar, whom the ruling Bharatiya Janata Party reveres. Do Indian voters agree with this disdain when they celebrate Amrit Kaal? Should the great patriot Veer Savarkar’s valour be humiliated by the people who signed a secret MoU with the dreaded enemy of the country and defame the country’s democratic governance in the West, which balkanized the country before being kicked out of the country they looted, caused unprecedented famines, and destroyed the native culture during their two centuries of rule to keep the region ever boiling in order to retain their supremacy in the world of politics forever? | english |
from project.posts.models import PostAlbum
def create(post, photos):
for photo in photos:
PostAlbum.objects.create(post=post, photo=photo, photo_original=photo)
def get_post_album(post):
return PostAlbum.objects.filter(post=post) | python |
<reponame>dsgrid/dsgrid
import csv
import enum
import importlib
import logging
import os
from datetime import datetime, timedelta
from pathlib import Path
from typing import Any, List, Optional, Union
from pydantic import validator, root_validator
from pydantic import Field
from semver import VersionInfo
from dsgrid.data_models import DSGBaseModel
from dsgrid.dimension.base_models import DimensionType
from dsgrid.dimension.time import (
LeapDayAdjustmentType,
TimeInvervalType,
MeasurementType,
TimeZone,
TimeDimensionType,
RepresentativePeriodFormat,
)
from dsgrid.registry.common import REGEX_VALID_REGISTRY_NAME, REGEX_VALID_REGISTRY_DISPLAY_NAME
from dsgrid.utils.files import compute_file_hash
from dsgrid.utils.versioning import handle_version_or_str
logger = logging.getLogger(__name__)
class DimensionBaseModel(DSGBaseModel):
"""Common attributes for all dimensions"""
name: str = Field(
title="name",
description="Dimension name",
note="Dimension names should be descriptive, memorable, identifiable, and reusable for "
"other datasets and projects",
notes=(
"Only alphanumeric characters and dashes are supported (no underscores or spaces).",
"The :meth:`~dsgrid.config.dimensions.check_name` validator is used to enforce valid"
" dimension names.",
),
updateable=False,
)
display_name: str = Field(
title="display_name",
description="Display name. Source for auto-generated query_name.",
note="Dimension display names should be singular noun phrases that are concise and "
"distinguish the dimension across all dimensions within a project, inclusive of dataset "
"dimensions, project base dimensions, and project supplemental dimensions. This uniqueness "
"requirement applies unless the dimension is trivial, that is, contains only a single "
"record. For trivial dimensions, if the dimension represents a single slice of the data, "
"e.g., all electricity use or model year 2018, then the convention is to list that "
"'record' name as the display name, e.g.,'Electricity Use' or '2018'.",
notes=(
"Only alphanumeric characters, underscores, and spaces are supported (no "
"special characters).",
"The :meth:`~dsgrid.config.dimensions.check_display_name` validator is used to "
"enforce valid dimension display names.",
),
)
query_name: Optional[str] = Field(
title="query_name",
description="Auto-generated query name for SQL queries.",
)
dimension_type: DimensionType = Field(
title="dimension_type",
alias="type",
description="Type of the dimension",
options=DimensionType.format_for_docs(),
)
dimension_id: Optional[str] = Field(
title="dimension_id",
alias="id",
description="Unique identifier, generated by dsgrid",
dsg_internal=True,
updateable=False,
)
module: Optional[str] = Field(
title="module",
description="Python module with the dimension class",
default="dsgrid.dimension.standard",
)
class_name: str = Field(
title="class_name",
description="Dimension record model class name",
alias="class",
notes=(
"The dimension class defines the expected and allowable fields (and their data types)"
" for the dimension records file.",
"All dimension records must have a 'id' and 'name' field."
"Some dimension classes support additional fields that can be used for mapping,"
" querying, display, etc.",
"dsgrid in online-mode only supports dimension classes defined in the"
" :mod:`dsgrid.dimension.standard` module. If dsgrid does not currently support a"
" dimension class that you require, please contact the dsgrid-coordination team to"
" request a new class feature",
),
)
cls: Optional[Any] = Field(
title="cls",
description="Dimension record model class",
alias="dimension_class",
dsg_internal=True,
)
description: str = Field(
title="description",
description="A description of the dimension records that is helpful, memorable, and "
"identifiable",
notes=(
"The description will get stored in the dimension record registry and may be used"
" when searching the registry.",
),
)
@validator("name")
def check_name(cls, name):
if name == "":
raise ValueError(f'Empty name field for dimension: "{cls}"')
if REGEX_VALID_REGISTRY_NAME.search(name) is None:
raise ValueError(f"dimension name={name} does not meet the requirements")
# TODO: improve validation for allowable dimension record names.
prohibited_names = [x.value.replace("_", "") for x in DimensionType] + [
"county",
"counties",
"year",
"hourly",
"comstock",
"resstock",
"tempo",
"model",
"source",
"data-source",
"dimension",
]
prohibited_names = prohibited_names + [x + "s" for x in prohibited_names]
if name.lower().replace(" ", "-") in prohibited_names:
raise ValueError(
f"""
Dimension name '{name}' is not descriptive enough for a dimension record name.
Please be more descriptive in your naming.
Hint: try adding a vintage, or other distinguishable text that will be this dimension memorable,
identifiable, and reusable for other datasets and projects.
e.g., 'time-2012-est-houlry-periodending-nodst-noleapdayadjustment-mean' is a good descriptive name.
"""
)
return name
@validator("display_name")
def check_display_name(cls, display_name):
if display_name == "":
raise ValueError(f'Empty name field for dimension: "{cls}"')
if REGEX_VALID_REGISTRY_DISPLAY_NAME.search(display_name) is None:
raise ValueError(f"display_name={display_name} does not meet the requirements")
return display_name
@validator("query_name")
def check_query_name(cls, query_name, values):
if "display_name" not in values:
return query_name
generated_query_name = values["display_name"].lower().replace(" ", "_").replace("-", "_")
if query_name is not None and query_name != generated_query_name:
raise ValueError(f"query_name cannot be set by the user: {query_name}")
return generated_query_name
@validator("module", always=True)
def check_module(cls, module):
if not module.startswith("dsgrid"):
raise ValueError("Only dsgrid modules are supported as a dimension module.")
return module
@validator("class_name", always=True)
def get_dimension_class_name(cls, class_name, values):
"""Set class_name based on inputs."""
if "name" not in values:
# An error occurred with name. Ignore everything else.
return class_name
if "module" not in values:
# An error occurred with module. Ignore everything else.
return class_name
mod = importlib.import_module(values["module"])
cls_name = class_name or values["name"]
if not hasattr(mod, cls_name):
if class_name is None:
msg = (
f'There is no class "{cls_name}" in module: {mod}.'
"\nIf you are using a unique dimension name, you must "
"specify the dimension class."
)
else:
msg = f"dimension class {class_name} not in {mod}"
raise ValueError(msg)
return cls_name
@validator("cls", always=True)
def get_dimension_class(cls, dim_class, values):
# Return if an error has already occurred
for req in ("name", "module", "class_name"):
if values.get(req) is None:
return dim_class
if dim_class is not None:
raise ValueError(f"cls={dim_class} should not be set")
return getattr(
importlib.import_module(values["module"]),
values["class_name"],
)
class DimensionModel(DimensionBaseModel):
"""Defines a non-time dimension"""
filename: str = Field(
title="filename",
alias="file",
description="Filename containing dimension records",
)
file_hash: Optional[str] = Field(
title="file_hash",
description="Hash of the contents of the file",
dsg_internal=True,
)
records: Optional[List] = Field(
title="records",
description="Dimension records in filename that get loaded at runtime",
dsg_internal=True,
default=[],
)
@validator("filename")
def check_file(cls, filename):
"""Validate that dimension file exists and has no errors"""
if not os.path.isfile(filename):
raise ValueError(f"file {filename} does not exist")
return filename
@validator("file_hash")
def compute_file_hash(cls, file_hash, values):
if "filename" not in values:
# TODO
# We are getting here for Time. That shouldn't be happening.
# This seems to work, but something is broken.
return None
return file_hash or compute_file_hash(values["filename"])
@validator("records", always=True)
def add_records(cls, records, values):
"""Add records from the file."""
prereqs = ("name", "filename", "cls")
for req in prereqs:
if values.get(req) is None:
return records
filename = Path(values["filename"])
dim_class = values["cls"]
assert not str(filename).startswith("s3://"), "records must exist in the local filesystem"
if records:
raise ValueError("records should not be defined in the dimension config")
records = []
if filename.name.endswith(".csv"):
with open(filename, encoding="utf") as f_in:
ids = set()
reader = csv.DictReader(f_in)
for row in reader:
record = dim_class(**row)
if record.id in ids:
raise ValueError(f"{record.id} is listed multiple times")
ids.add(record.id)
records.append(record)
else:
raise ValueError(f"only CSV is supported: {filename}")
return records
def dict(self, by_alias=True, **kwargs):
exclude = {"cls", "records"}
if "exclude" in kwargs and kwargs["exclude"] is not None:
kwargs["exclude"].union(exclude)
else:
kwargs["exclude"] = exclude
data = super().dict(by_alias=by_alias, **kwargs)
data["module"] = str(data["module"])
data["dimension_class"] = None
_convert_for_serialization(data)
return data
class TimeRangeModel(DSGBaseModel):
"""Defines a continuous range of time."""
# This uses str instead of datetime because this object doesn't have the ability
# to serialize/deserialize by itself (no str-format).
# We use the DatetimeRange object during processing.
start: str = Field(
title="start",
description="First timestamp in the data",
)
end: str = Field(
title="end",
description="Last timestamp in the data (inclusive)",
)
class MonthRangeModel(DSGBaseModel):
"""Defines a continuous range of time."""
# This uses str instead of datetime because this object doesn't have the ability
# to serialize/deserialize by itself (no str-format).
# We use the DatetimeRange object during processing.
start: int = Field(
title="start",
description="First month in the data (January is 1, December is 12)",
)
end: int = Field(
title="end",
description="Last month in the data (inclusive)",
)
class TimeDimensionBaseModel(DimensionBaseModel):
"""Defines a base model common to all time dimensions."""
time_type: TimeDimensionType = Field(
title="time_type",
default=TimeDimensionType.DATETIME,
description="""
Type of time dimension:
datetime, annual, representative_period, noop
""",
options=TimeDimensionType.format_for_docs(),
)
def dict(self, by_alias=True, **kwargs):
exclude = {"cls"}
if "exclude" in kwargs and kwargs["exclude"] is not None:
kwargs["exclude"].union(exclude)
else:
kwargs["exclude"] = exclude
data = super().dict(by_alias=by_alias, **kwargs)
data["module"] = str(data["module"])
data["dimension_class"] = None
_convert_for_serialization(data)
return data
class DateTimeDimensionModel(TimeDimensionBaseModel):
"""Defines a time dimension where timestamps translate to datetime objects."""
measurement_type: MeasurementType = Field(
title="measurement_type",
default=MeasurementType.TOTAL,
description="""
The type of measurement represented by a value associated with a timestamp:
mean, min, max, measured, total
""",
options=MeasurementType.format_for_docs(),
)
str_format: Optional[str] = Field(
title="str_format",
default="%Y-%m-%d %H:%M:%s",
description="Timestamp string format",
notes=(
"The string format is used to parse the timestamps provided in the time ranges."
"Cheatsheet reference: `<https://strftime.org/>`_.",
),
)
frequency: timedelta = Field(
title="frequency",
description="Resolution of the timestamps",
notes=(
"Reference: `Datetime timedelta objects"
" <https://docs.python.org/3/library/datetime.html#timedelta-objects>`_",
),
)
ranges: List[TimeRangeModel] = Field(
title="time_ranges",
description="Defines the continuous ranges of time in the data, inclusive of start and end time.",
)
leap_day_adjustment: Optional[LeapDayAdjustmentType] = Field(
title="leap_day_adjustment",
description="Leap day adjustment method applied to time data",
default=LeapDayAdjustmentType.NONE,
optional=True,
options=LeapDayAdjustmentType.format_descriptions_for_docs(),
notes=(
"The dsgrid default is None, i.e., no adjustment made to leap years.",
"Adjustments are made to leap years only.",
),
)
time_interval_type: TimeInvervalType = Field(
title="time_interval",
description="The range of time that the value associated with a timestamp represents, e.g., period-beginning",
options=TimeInvervalType.format_descriptions_for_docs(),
)
timezone: TimeZone = Field(
title="timezone",
description="""
Time zone of data:
UTC,
HawaiiAleutianStandard,
AlaskaStandard, AlaskaPrevailing,
PacificStandard, PacificPrevailing,
MountainStandard, MountainPrevailing,
CentralStandard, CentralPrevailing,
EasternStandard, EasternPrevailing,
LOCAL
""",
options=TimeZone.format_descriptions_for_docs(),
)
@root_validator(pre=False, skip_on_failure=True)
def check_time_type_and_class_consistency(cls, values):
return _check_time_type_and_class_consistency(values)
@root_validator(pre=False, skip_on_failure=True)
def check_frequency(cls, values):
if values["frequency"] in [timedelta(days=365), timedelta(days=366)]:
raise ValueError(
f'frequency={values["frequency"]}, 365 or 366 days not allowed, '
"use class=AnnualTime, time_type=annual to specify a year series."
)
return values
@validator("ranges")
def check_times(cls, ranges, values):
if "str_format" not in values or "frequency" not in values:
return ranges
return _check_time_ranges(ranges, values["str_format"], values["frequency"])
class AnnualTimeDimensionModel(TimeDimensionBaseModel):
"""Defines an annual time dimension where timestamps are years."""
time_type: TimeDimensionType = Field(default=TimeDimensionType.ANNUAL)
measurement_type: MeasurementType = Field(
title="measurement_type",
default=MeasurementType.TOTAL,
description="""
The type of measurement represented by a value associated with a timestamp:
mean, min, max, measured, total
""",
options=MeasurementType.format_for_docs(),
)
str_format: Optional[str] = Field(
title="str_format",
default="%Y",
description="Timestamp string format",
notes=(
"The string format is used to parse the timestamps provided in the time ranges."
"Cheatsheet reference: `<https://strftime.org/>`_.",
),
)
ranges: List[TimeRangeModel] = Field(
title="time_ranges",
description="Defines the contiguous ranges of time in the data, inclusive of start and end time.",
)
include_leap_day: bool = Field(
title="include_leap_day",
default=False,
description="Whether annual time includes leap day.",
)
@root_validator(pre=False)
def check_time_type_and_class_consistency(cls, values):
return _check_time_type_and_class_consistency(values)
@validator("ranges")
def check_times(cls, ranges, values):
if "str_format" not in values:
return ranges
return _check_time_ranges(ranges, values["str_format"], timedelta(days=365))
class RepresentativePeriodTimeDimensionModel(TimeDimensionBaseModel):
"""Defines a representative time dimension."""
measurement_type: MeasurementType = Field(
title="measurement_type",
default=MeasurementType.TOTAL,
description="""
The type of measurement represented by a value associated with a timestamp:
mean, min, max, measured, total
""",
options=MeasurementType.format_for_docs(),
)
format: RepresentativePeriodFormat = Field(
title="format",
description="Format of the timestamps in the load data",
)
ranges: List[MonthRangeModel] = Field(
title="ranges",
description="Defines the continuous ranges of time in the data, inclusive of start and end time.",
)
time_interval_type: TimeInvervalType = Field(
title="time_interval",
description="The range of time that the value associated with a timestamp represents",
options=TimeInvervalType.format_descriptions_for_docs(),
)
class NoOpTimeDimensionModel(TimeDimensionBaseModel):
"""Defines a NoOp time dimension."""
time_type: TimeDimensionType = Field(default=TimeDimensionType.NOOP)
@root_validator(pre=False)
def check_time_type_and_class_consistency(cls, values):
return _check_time_type_and_class_consistency(values)
class DimensionReferenceModel(DSGBaseModel):
"""Reference to a dimension stored in the registry"""
dimension_type: DimensionType = Field(
title="dimension_type",
alias="type",
description="Type of the dimension",
options=DimensionType.format_for_docs(),
)
dimension_id: str = Field(
title="dimension_id",
description="Unique ID of the dimension in the registry",
notes=(
"The dimension ID is generated by dsgrid when a dimension is registered and it is a"
" concatenation of the user-provided name and an auto-generated UUID.",
"Only alphanumerics and dashes are supported.",
),
)
version: Union[str, VersionInfo] = Field(
title="version",
description="Version of the dimension",
requirements=(
"The version string must be in semver format (e.g., '1.0.0') and it must be "
" a valid/existing version in the registry.",
),
# TODO: add notes about warnings for outdated versions DSGRID-189 & DSGRID-148
)
@validator("version")
def check_version(cls, version):
return handle_version_or_str(version)
class DimensionReferenceByNameModel(DSGBaseModel):
"""Reference to a dimension that has yet to be registered."""
dimension_type: DimensionType = Field(
title="dimension_type",
alias="type",
description="Type of the dimension",
options=DimensionType.format_for_docs(),
)
name: str = Field(
title="name",
description="Dimension name",
)
def handle_dimension_union(value):
if isinstance(value, DimensionBaseModel):
return value
# NOTE: Errors inside DimensionModel or DateTimeDimensionModel will be duplicated by Pydantic
if value["type"] == DimensionType.TIME.value:
if value["time_type"] == TimeDimensionType.DATETIME.value:
val = DateTimeDimensionModel(**value)
elif value["time_type"] == TimeDimensionType.ANNUAL.value:
val = AnnualTimeDimensionModel(**value)
elif value["time_type"] == TimeDimensionType.REPRESENTATIVE_PERIOD.value:
val = RepresentativePeriodTimeDimensionModel(**value)
elif value["time_type"] == TimeDimensionType.NOOP.value:
val = NoOpTimeDimensionModel(**value)
else:
options = [x.value for x in TimeDimensionType]
raise ValueError(f"{value['time_type']} not supported, valid options: {options}")
else:
val = DimensionModel(**value)
return val
def _convert_for_serialization(data):
for key, val in data.items():
if isinstance(val, enum.Enum):
data[key] = val.value
def _check_time_ranges(ranges: list, str_format: str, frequency: timedelta):
assert isinstance(frequency, timedelta)
for time_range in ranges:
# Make sure start and end time parse.
start = datetime.strptime(time_range.start, str_format)
end = datetime.strptime(time_range.end, str_format)
if str_format == "%Y":
if frequency != timedelta(days=365):
raise ValueError(f"str_format={str_format} is inconsistent with {frequency}")
# There may be other special cases to handle.
elif (end - start) % frequency != timedelta(0):
raise ValueError(f"time range {time_range} is inconsistent with {frequency}")
return ranges
# TODO: modify as model works with more time_type schema
def _check_time_type_and_class_consistency(values):
if (
(values["class_name"] == "Time" and values["time_type"] == TimeDimensionType.DATETIME)
or (
values["class_name"] == "AnnualTime"
and values["time_type"] == TimeDimensionType.ANNUAL
)
or (values["class_name"] == "NoOpTime" and values["time_type"] == TimeDimensionType.NOOP)
):
pass
else:
raise ValueError(
f'time_type={values["time_type"].value} does not match class_name={values["class_name"]}. \n'
" * For class=Time, use time_type=datetime. \n"
" * For class=AnnualTime, use time_type=annual. \n"
" * For class=NoOpTime, use time_type=noop. "
)
return values
| python |
<reponame>fullstack-build/fullstack-one
import { INestedFilter, IFilterLeaf } from "../types";
import { OperatorsBuilder, IOperatorContext, IOperator } from "../../../logicalOperators";
import { UserInputError } from "../../../GraphqlErrors";
export class FilterBuilder {
private _operatorsBuilder: OperatorsBuilder;
private _getParam: (value: unknown) => string;
private _getColumn: (columnName: string) => string;
public constructor(
operatorsBuilder: OperatorsBuilder,
getParam: (value: unknown) => string,
getColumn: (columnName: string) => string
) {
this._operatorsBuilder = operatorsBuilder;
this._getParam = getParam;
this._getColumn = getColumn;
}
private _generateConjunktionFilter(filterList: INestedFilter[]): string {
return filterList.map(this.generate).join(" AND ");
}
private _generateDisjunctionFilter(filterList: INestedFilter[]): string {
return filterList.map(this.generate).join(" OR ");
}
private _generateOperatorsFilter(columnName: string, field: IFilterLeaf): string {
return Object.entries(field)
.map(([operatorName, value]) => this._generateOperatorFilter(operatorName, columnName, value))
.join(" AND ");
}
private _generateOperatorFilter(operatorName: string, columnName: string, value: unknown): string {
const operator: IOperator = this._operatorsBuilder.getOperatorByName(operatorName);
if (operator == null) {
throw new UserInputError(`Operator '${operatorName}' not found.`, {
exposeDetails: true,
});
}
const context: IOperatorContext = {
fieldPgSelector: this._getColumn(columnName),
value,
getParam: this._getParam.bind(this),
};
return operator.getSql(context);
}
public generate(filter: INestedFilter): string {
const sqlList: string[] = [];
Object.entries(filter).forEach(([fieldName, field]) => {
if (fieldName === "AND") {
sqlList.push(`(${this._generateConjunktionFilter(field as INestedFilter[])})`);
} else if (fieldName === "OR") {
sqlList.push(`(${this._generateDisjunctionFilter(field as INestedFilter[])})`);
} else {
sqlList.push(`(${this._generateOperatorsFilter(fieldName, field as IFilterLeaf)})`);
}
});
return sqlList.join(" AND ");
}
}
| typescript |
<gh_stars>0
{"date":"2011-07-05","platform":"TV","images":{"small":"https://lain.bgm.tv/pic/cover/s/a8/ae/12333_ksK2s.jpg","grid":"https://lain.bgm.tv/pic/cover/g/a8/ae/12333_ksK2s.jpg","large":"https://lain.bgm.tv/pic/cover/l/a8/ae/12333_ksK2s.jpg","medium":"https://lain.bgm.tv/pic/cover/m/a8/ae/12333_ksK2s.jpg","common":"https://lain.bgm.tv/pic/cover/c/a8/ae/12333_ksK2s.jpg"},"summary":"原作是由山村哉(やまむらはじめ)创作、在漫画杂志《月刊少年GENE-X》上连载的漫画。\r\n在大学生匡平长大的空手村中,祭祀着一种被称为“玖吼理”的“案山子”人偶。匡平舍弃故乡、来到东京,开始了愉快的学生生活,但在妹妹诗绪和从村子中逃出的阿幾带着玖吼理到来之后,生活完全改变了……匡平到底能够逃离故乡吗?","name":"神様ドォルズ","name_cn":"神样DOLLS","tags":[{"name":"2011年7月","count":252},{"name":"石川智晶","count":197},{"name":"神样DOLLS","count":181},{"name":"DOLLS","count":146},{"name":"TV","count":112},{"name":"岡本信彥","count":104},{"name":"妹控无误","count":89},{"name":"巨乳","count":86},{"name":"基友出没","count":80},{"name":"岸诚二","count":74},{"name":"2011","count":69},{"name":"福圓美里","count":58},{"name":"一方通行","count":50},{"name":"漫画改","count":38},{"name":"妹控?","count":30},{"name":"BrainsBase","count":27},{"name":"七月番","count":25},{"name":"漫改","count":16},{"name":"yooooooo","count":15},{"name":"花泽香菜","count":14},{"name":"颜艺","count":14},{"name":"2011年","count":11},{"name":"岸誠二","count":11},{"name":"妹控","count":10},{"name":"战斗","count":10},{"name":"奇幻","count":9},{"name":"漫画","count":9},{"name":"木村良平","count":8},{"name":"Brain","count":6},{"name":"上江洲誠","count":5}],"infobox":[{"key":"中文名","value":"神样DOLLS"},{"key":"话数","value":"13"},{"key":"放送开始","value":"2011年7月5日"},{"key":"放送星期","value":"星期二"},{"key":"官方网站","value":"http://www.kamisama-anime.jp/"},{"key":"播放电视台","value":"テレビ東京"},{"key":"其他电视台","value":"AT-X"},{"key":"播放结束","value":"2011年9月27日"},{"key":"放送时间","value":"25:30"},{"key":"原作","value":"やまむらはじめ"}],"rating":{"rank":3286,"total":1668,"count":{"1":7,"2":4,"3":9,"4":30,"5":144,"6":454,"7":598,"8":323,"9":64,"10":35},"score":6.8},"total_episodes":21,"collection":{"on_hold":238,"dropped":265,"wish":452,"collect":1860,"doing":408},"id":12333,"eps":13,"volumes":0,"locked":false,"nsfw":false,"type":2} | json |
#![allow(deprecated)]
use glutin::event_loop::{ControlFlow, EventLoop};
use crate::keyboard::{scan_to_code, vk_to_key};
use crate::window::Window;
use tuix_core::{Length};
use tuix_core::{Entity, State};
use tuix_core::state::mouse::{MouseButton, MouseButtonState};
use tuix_core::events::{Event, EventManager, Propagation};
use tuix_core::state::hierarchy::IntoHierarchyIterator;
use tuix_core::state::Fonts;
use tuix_core::state::style::prop::*;
use tuix_core::{WindowDescription, WindowEvent, WindowWidget};
use tuix_core::systems::{apply_styles, apply_hover};
use glutin::event::VirtualKeyCode;
type GEvent<'a, T> = glutin::event::Event<'a, T>;
pub struct Application {
pub window: Window,
pub state: State,
event_loop: EventLoop<()>,
pub event_manager: EventManager,
}
impl Application {
pub fn new<F: FnOnce(WindowDescription, &mut State, Entity) -> WindowDescription>(
app: F,
) -> Self {
let event_loop = EventLoop::new();
let mut state = State::new();
let event_manager = EventManager::new();
let root = Entity::root();
state.hierarchy.add(Entity::root(), None);
//let window_description = win(WindowDescription::new());
let window_description = app(WindowDescription::new(), &mut state, root);
let mut window = Window::new(&event_loop, &window_description);
let regular_font = include_bytes!("../../resources/Roboto-Regular.ttf");
let bold_font = include_bytes!("../../resources/Roboto-Bold.ttf");
let icon_font = include_bytes!("../../resources/entypo.ttf");
let emoji_font = include_bytes!("../../resources/OpenSansEmoji.ttf");
let fonts = Fonts {
regular: Some(
window
.canvas
.add_font_mem(regular_font)
.expect("Cannot add font"),
),
bold: Some(
window
.canvas
.add_font_mem(bold_font)
.expect("Cannot add font"),
),
icons: Some(
window
.canvas
.add_font_mem(icon_font)
.expect("Cannot add font"),
),
emoji: Some(
window
.canvas
.add_font_mem(emoji_font)
.expect("Cannot add font"),
),
};
state.fonts = fonts;
state.style.width.insert(
Entity::root(),
Length::Pixels(window_description.inner_size.width as f32),
);
state.style.height.insert(
Entity::root(),
Length::Pixels(window_description.inner_size.height as f32),
);
state
.data
.set_width(Entity::root(), window_description.inner_size.width as f32);
state
.data
.set_height(Entity::root(), window_description.inner_size.height as f32);
state.data.set_opacity(Entity::root(), 1.0);
WindowWidget::new().build_window(&mut state);
Application {
window: window,
event_loop: event_loop,
event_manager: event_manager,
state: state,
}
}
pub fn run(self) {
let mut state = self.state;
let mut event_manager = self.event_manager;
let mut window = self.window;
let mut should_quit = false;
//let hierarchy = state.hierarchy.clone();
state.insert_event(Event::new(WindowEvent::Restyle).target(Entity::root()));
state.insert_event(Event::new(WindowEvent::Relayout).target(Entity::root()));
let event_loop_proxy = self.event_loop.create_proxy();
let mut first_time = true;
self.event_loop.run(move |event, _, control_flow| {
*control_flow = ControlFlow::Wait;
match event {
GEvent::LoopDestroyed => return,
GEvent::UserEvent(_) => {
window.handle.window().request_redraw();
}
GEvent::MainEventsCleared => {
let mut needs_redraw = false;
while !state.event_queue.is_empty() {
if event_manager.flush_events(&mut state) {
needs_redraw = true;
}
}
if state.apply_animations() {
//println!("Animate");
*control_flow = ControlFlow::Poll;
state.insert_event(
Event::new(WindowEvent::Relayout)
.target(Entity::root())
.origin(Entity::root()),
);
//state.insert_event(Event::new(WindowEvent::Redraw));
event_loop_proxy.send_event(()).unwrap();
window.handle.window().request_redraw();
} else {
//println!("Wait");
*control_flow = ControlFlow::Wait;
}
if first_time {
let hierarchy = state.hierarchy.clone();
apply_styles(&mut state, &hierarchy);
first_time = false;
}
if needs_redraw {
window.handle.window().request_redraw();
}
//
// event_manager.flush_events(&mut state);
// apply_z_ordering(&mut state, &hierarchy);
// apply_visibility(&mut state, &hierarchy);
// apply_clipping(&mut state, &hierarchy);
// layout_fun(&mut state, &hierarchy);
// event_manager.draw(&mut state, &hierarchy, &mut window.canvas);
// window
// .handle
// .swap_buffers()
// .expect("Failed to swap buffers");
}
// REDRAW
GEvent::RedrawRequested(_) => {
let hierarchy = state.hierarchy.clone();
event_manager.draw(&mut state, &hierarchy, &mut window.canvas);
// Swap buffers
window
.handle
.swap_buffers()
.expect("Failed to swap buffers");
}
GEvent::WindowEvent {
event,
window_id: _,
} => {
match event {
//////////////////
// Close Window //
//////////////////
glutin::event::WindowEvent::CloseRequested => {
state.insert_event(Event::new(WindowEvent::WindowClose));
should_quit = true;
}
//TODO
///////////////////////
// Modifiers Changed //
///////////////////////
glutin::event::WindowEvent::ModifiersChanged(modifiers_state) => {
state.modifiers.shift = modifiers_state.shift();
state.modifiers.ctrl = modifiers_state.ctrl();
state.modifiers.alt = modifiers_state.alt();
state.modifiers.logo = modifiers_state.logo();
}
////////////////////
// Focused Window //
////////////////////
glutin::event::WindowEvent::Focused(_) => {
state.insert_event(
Event::new(WindowEvent::Restyle)
.target(Entity::root())
.origin(Entity::root()),
);
state.insert_event(
Event::new(WindowEvent::Relayout)
.target(Entity::root())
.origin(Entity::root()),
);
state.insert_event(Event::new(WindowEvent::Redraw).target(Entity::root()));
}
////////////////////
// Focused Window //
////////////////////
glutin::event::WindowEvent::ReceivedCharacter(input) => {
state.insert_event(
Event::new(WindowEvent::CharInput(input))
.target(state.focused)
.propagate(Propagation::Down),
);
}
glutin::event::WindowEvent::KeyboardInput {
device_id: _,
input,
is_synthetic: _,
} => {
let s = match input.state {
glutin::event::ElementState::Pressed => MouseButtonState::Pressed,
glutin::event::ElementState::Released => MouseButtonState::Released,
};
let code = scan_to_code(input.scancode);
let key = vk_to_key(
input.virtual_keycode.unwrap_or(VirtualKeyCode::NoConvert),
);
if let Some(virtual_keycode) = input.virtual_keycode {
if virtual_keycode == VirtualKeyCode::F5
&& s == MouseButtonState::Pressed
{
state.reload_styles().unwrap();
}
if virtual_keycode == VirtualKeyCode::H && s == MouseButtonState::Pressed {
println!("Hierarchy");
for entity in state.hierarchy.into_iter() {
println!("Entity: {} Parent: {:?} FC: {:?} NS: {:?}", entity, state.hierarchy.get_parent(entity), state.hierarchy.get_first_child(entity), state.hierarchy.get_next_sibling(entity));
}
}
if virtual_keycode == VirtualKeyCode::Tab
&& s == MouseButtonState::Pressed
{
let next_focus = state
.style
.focus_order
.get(state.focused)
.cloned()
.unwrap_or_default()
.next;
let prev_focus = state
.style
.focus_order
.get(state.focused)
.cloned()
.unwrap_or_default()
.prev;
if state.modifiers.shift {
if prev_focus != Entity::null() {
state.focused.set_focus(&mut state, false);
state.focused = prev_focus;
state.focused.set_focus(&mut state, true);
} else {
// TODO impliment reverse iterator for hierarchy
// state.focused = match state.focused.into_iter(&state.hierarchy).next() {
// Some(val) => val,
// None => Entity::root(),
// };
}
} else {
let hierarchy = state.hierarchy.clone();
if next_focus != Entity::null() {
state.focused.set_focus(&mut state, false);
state.focused = next_focus;
state.focused.set_focus(&mut state, true);
} else {
state.focused.set_focus(&mut state, false);
state.focused =
match state.focused.into_iter(&hierarchy).next() {
Some(val) => val,
None => Entity::root(),
};
state.focused.set_focus(&mut state, true);
}
}
state.insert_event(
Event::new(WindowEvent::Restyle)
.target(Entity::root())
.origin(Entity::root()),
);
}
}
match s {
MouseButtonState::Pressed => {
if state.focused != Entity::null() {
state.insert_event(
Event::new(WindowEvent::KeyDown(code, key))
.target(state.focused)
.propagate(Propagation::DownUp),
);
} else {
state.insert_event(
Event::new(WindowEvent::KeyDown(code, key))
.target(state.hovered)
.propagate(Propagation::DownUp),
);
}
}
MouseButtonState::Released => {
if state.focused != Entity::null() {
state.insert_event(
Event::new(WindowEvent::KeyUp(code, key))
.target(state.focused)
.propagate(Propagation::DownUp),
);
} else {
state.insert_event(
Event::new(WindowEvent::KeyUp(code, key))
.target(state.hovered)
.propagate(Propagation::DownUp),
);
}
}
}
}
glutin::event::WindowEvent::Resized(physical_size) => {
window.handle.resize(physical_size);
state
.style
.width
.insert(Entity::root(), Length::Pixels(physical_size.width as f32));
state
.style
.height
.insert(Entity::root(), Length::Pixels(physical_size.height as f32));
state
.data
.set_width(Entity::root(), physical_size.width as f32);
state
.data
.set_height(Entity::root(), physical_size.height as f32);
state.insert_event(Event::new(WindowEvent::Restyle).origin(Entity::root()).target(Entity::root()));
state.insert_event(
Event::new(WindowEvent::Relayout).target(Entity::root()),
);
state.insert_event(Event::new(WindowEvent::Redraw).target(Entity::root()));
}
glutin::event::WindowEvent::CursorMoved {
device_id: _,
position,
modifiers: _,
} => {
let cursorx = (position.x) as f32;
let cursory = (position.y) as f32;
state.mouse.cursorx = cursorx as f32;
state.mouse.cursory = cursory as f32;
apply_hover(&mut state);
if state.captured != Entity::null() {
state.insert_event(
Event::new(WindowEvent::MouseMove(cursorx, cursory))
.target(state.captured)
.propagate(Propagation::Direct),
);
} else if state.hovered != Entity::root() {
state.insert_event(
Event::new(WindowEvent::MouseMove(cursorx, cursory))
.target(state.hovered),
);
}
}
glutin::event::WindowEvent::MouseInput {
device_id: _,
state: s,
button,
modifiers: _,
} => {
let s = match s {
glutin::event::ElementState::Pressed => MouseButtonState::Pressed,
glutin::event::ElementState::Released => MouseButtonState::Released,
};
let b = match button {
glutin::event::MouseButton::Left => MouseButton::Left,
glutin::event::MouseButton::Right => MouseButton::Right,
glutin::event::MouseButton::Middle => MouseButton::Middle,
glutin::event::MouseButton::Other(id) => MouseButton::Other(id),
};
match b {
MouseButton::Left => {
state.mouse.left.state = s;
}
MouseButton::Right => {
state.mouse.right.state = s;
}
MouseButton::Middle => {
state.mouse.middle.state = s;
}
_ => {}
}
match s {
MouseButtonState::Pressed => {
if state.hovered != Entity::null()
&& state.active != state.hovered
{
state.active = state.hovered;
state.insert_event(Event::new(WindowEvent::Restyle).target(Entity::root()));
}
if state.captured != Entity::null() {
state.insert_event(
Event::new(WindowEvent::MouseDown(b))
.target(state.captured)
.propagate(Propagation::Direct),
);
} else {
state.insert_event(
Event::new(WindowEvent::MouseDown(b))
.target(state.hovered),
);
}
match b {
MouseButton::Left => {
state.mouse.left.pos_down =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.pressed = state.hovered;
}
MouseButton::Middle => {
state.mouse.middle.pos_down =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.pressed = state.hovered;
}
MouseButton::Right => {
state.mouse.right.pos_down =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.pressed = state.hovered;
}
_ => {}
}
}
MouseButtonState::Released => {
state.active = Entity::null();
state.insert_event(Event::new(WindowEvent::Restyle));
if state.captured != Entity::null() {
state.insert_event(
Event::new(WindowEvent::MouseUp(b))
.target(state.captured)
.propagate(Propagation::Direct),
);
} else {
state.insert_event(
Event::new(WindowEvent::MouseUp(b))
.target(state.hovered),
);
}
match b {
MouseButton::Left => {
state.mouse.left.pos_up =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.released = state.hovered;
}
MouseButton::Middle => {
state.mouse.middle.pos_up =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.released = state.hovered;
}
MouseButton::Right => {
state.mouse.right.pos_up =
(state.mouse.cursorx, state.mouse.cursory);
state.mouse.left.released = state.hovered;
}
_ => {}
}
}
}
}
glutin::event::WindowEvent::MouseWheel {
device_id: _,
delta,
phase: _,
modifiers: _,
} => {
let (x, y) = match delta {
glutin::event::MouseScrollDelta::LineDelta(xx, yy) => (xx, yy),
_ => (0.0, 0.0),
};
if state.captured != Entity::null() {
state.insert_event(
Event::new(WindowEvent::MouseScroll(x, y))
.target(state.captured)
.propagate(Propagation::Direct),
);
} else {
state.insert_event(
Event::new(WindowEvent::MouseScroll(x, y))
.target(state.hovered),
);
}
}
_ => {}
};
}
_ => {}
}
if should_quit {
*control_flow = ControlFlow::Exit;
}
});
}
}
| rust |
<gh_stars>10-100
{"type":"Feature","id":"node/7119087072","properties":{"amenity":"vending_machine","covered":"yes","currency:EUR":"yes","operator":"<NAME>","payment:coins":"yes","vending":"milk","id":"node/7119087072"},"geometry":{"type":"Point","coordinates":[15.4772261,47.0584637]}} | json |
<reponame>aizad1998/ramento
{"n": "<KEY>", "e": "AQAB", "d": "<KEY>", "p": "<KEY>", "q": "<KEY>", "dp": "<KEY>", "dq": "<KEY>", "qi": "<KEY>", "kty": "RSA"} | json |
The Centre on Tuesday told the Rajya Sabha that no deaths due to lack of oxygen were “specifically reported” by states and union territories during the second Covid-19 wave that hit the country.
Shortly after the statement by the Centre was made in a written reply by the Minister of State for Health Bharati Pravin Pawar, AICC General Secretary K C Venugopal accused the minister of having “misled” the house. Describing the statement as “condemnable”, Venugopal, a Rajya Sabha MP to whose question the reply was given, said he will move a privilege motion against the minister.
“In every state and in Delhi also, we have seen how many patients died due to lack of oxygen we know. Actually, the minister misled the House. I will move a privilege(motion) against the minister definitely because she misguided and misled the House by giving false information to the House,” Venugopal told reporters.
Pawar in her written reply at the same time said there was an unprecedented surge in demand for medical oxygen during the second wave and it peaked at nearly 9,000 MT compared to 3,095 MT in the first wave following which the Centre had to step in to facilitate equitable distribution among the states.
Responding to the question on whether a large number of Covid-19 patients died on roads and hospitals due to acute shortage of oxygen during the devastating second wave, Pawar noted that health is a state subject and states and UTs regularly report the number of cases and deaths to the Centre.
“Detailed guidelines for reporting of deaths have been issued by the Union Health Ministry to all states and UTs.
“Accordingly, all states and UTs report cases and deaths to the Union Health Ministry on a regular basis. However, no deaths due to lack of oxygen have been specifically reported by states and UTs,” she said.
Congress leader Rahul Gandhi also took a swipe at the Centre, alleging there is acute lack of sensitivity and truth in this government. “There was not just the shortage of oxygen. There was an acute shortage of sensitivity and truth then, it was there then and is there now too,” Gandhi said in a tweet in Hindi.
During the peak of the brutal second wave in April-May this year, there were media reports about death of Covid patients including in Delhi due to alleged oxygen shortage.
In Karnataka, state officials had said on May 3 that 24 patients including 23 suffering from Covid-19 died in Chamarajanagar due to alleged oxygen shortage in the district hospital during a 24-hour period from the previous day.
Chamarajanagar district in-charge Minister S Suresh Kumar, who is also the Primary and Secondary Education Minister, however, had maintained that all the deaths did not occur due to oxygen shortage.
Participating in a short duration discussion in the Rajya Sabha on the Covid pandemic management, Shantanu Sen of the Trinamool Congress said that during the second wave, people were dying on the roads because of the scarcity of oxygen and this has happened in the 21st century, which is a “matter of shame”.
In her written reply, Minister Pawar went on to say that states were being provided with oxygen equipment such as oxygen cylinders, concentrators and Pressure Swing Adsorption (PSA) oxygen generation plants. A total of 4,02,517 oxygen cylinders have been procured or are being procured and distributed to the states, she said.
As many as 1,222 PSA Oxygen generation plants have been sanctioned. Out of these, as on July 15, 237 plants have been commissioned.
Apart from this, 295 PSA plants are being installed by different ministries, the minister said.
States have also been asked to prepare state-level oxygen generation plants, she added.
To increase the storage capacity of liquid medical oxygen in the states, under the emergency Covid Package-Part-II, 1,050 Liquid Medical Oxygen Tanks along with Medical Gas Pipeline System(MGPS) at a cost of Rs. 80 Lakh each have been approved.
The Government of India has supported the states and undertook a series of actions including provisioning medical oxygen, and other consumables to ensure clinical care of Covid-19 patients in view of the steep rise of Covid-19 trajectory in the country during April-May 2021, the minister said.
On the total demand of oxygen by the states and total oxygen supplied, the minister said the supply of medical oxygen to hospitals is determined by contractual arrangements between the hospital and the medical oxygen supplier concerned.
“However, due to unprecedented surge in demand of medical oxygen during the second wave – the demand in the country peaked to nearly 9,000 MT as compared to 3,095 MT during the first wave – the central government had to step in to facilitate equitable distribution to the states.
“A dynamic and transparent framework for allocation of medical oxygen in consultation with states and UTs and all the stakeholders such as relevant ministries, manufacturers/suppliers of liquid oxygen, etc. was prepared,” the written reply stated.
The active caseload of the state and UT was the primary determinant of oxygen allocation. Other factors such as case doubling rate, available medical infrastructure, etc. were also given due consideration.
Further, the allocation was kept dynamic as per the changing pandemic load.
The Government of India, along with the state governments, took all possible steps to tackle the unprecedented surge in oxygen demand that arose in the second wave of Covid-19, it said.
This includes enhancement of liquid medical oxygen (LMO) production from 5,700 MTs in August 2020 to 9,690 MTs in May 2021, restrictions on industrial use of oxygen; and augmentation of availability of containers.
A dynamic and transparent framework for allocation of medical oxygen in consultation with states and UTs and all the stakeholders such as relevant Ministries, manufacturers/suppliers of liquid oxygen, etc. was prepared.
Also, online digital solutions viz. Oxygen Demand Aggregation system (ODAS) and Oxygen Digital Tracking System (ODTS) have been developed to ascertain the demand for medical oxygen from all medical facilities and to track their transportation.
Further, to avoid wastage of medical oxygen, guidelines on rational use of oxygen were issued on September 25, 2020. These were further revised and disseminated to States on April 25, 2021. | english |
<gh_stars>0
package repository
import "github.com/daymenu/goadmin/internal/ent"
// AdminRepo define a admin repository
type AdminRepo struct {
client *ent.Client
}
// NewAdminRepo new a amdin repository
func NewAdminRepo(client *ent.Client) (*AdminRepo, error) {
return nil, nil
}
// Add add a admin
func (adminRepo *AdminRepo) Add(adminEntiy *ent.Admin) {
}
| go |
package schema_test
import (
"database/sql/driver"
"testing"
"github.com/araddon/qlbridge/datasource"
"github.com/araddon/qlbridge/datasource/memdb"
"github.com/araddon/qlbridge/schema"
"github.com/stretchr/testify/assert"
)
func TestApplySchema(t *testing.T) {
a := schema.NewApplyer(func(s *schema.Schema) schema.Source {
sdb := datasource.NewSchemaDb(s)
s.InfoSchema.DS = sdb
return sdb
})
reg := schema.NewRegistry(a)
a.Init(reg)
inrow := []driver.Value{122, "bob", "<EMAIL>"}
db, err := memdb.NewMemDbData("users", [][]driver.Value{inrow}, []string{"user_id", "name", "email"})
assert.Equal(t, nil, err)
s := schema.NewSchema("hello")
s.DS = db
err = a.AddOrUpdateOnSchema(s, s)
assert.Equal(t, nil, err)
err = a.AddOrUpdateOnSchema(s, "not_real")
assert.NotEqual(t, nil, err)
a.Drop(s, s)
err = a.Drop(s, "fake")
assert.NotEqual(t, nil, err)
}
| go |
import { baseSpellEffect, spellEffectModules } from "../specialSpells.js";
import { loadMacroFile, generateItemMacroFlag } from "../macros.js";
export async function spiritShroudEffect(document) {
if (!spellEffectModules().activeAurasInstalled) return document;
let effect = baseSpellEffect(document, document.name);
effect.changes.push(
{
key: "flags.midi-qol.spiritShroud",
mode: CONST.ACTIVE_EFFECT_MODES.OVERRIDE,
value: "@uuid",
priority: 20
},
{
key: "data.attributes.movement.all",
mode: CONST.ACTIVE_EFFECT_MODES.CUSTOM,
value: "-10",
priority: "15",
});
effect.flags["ActiveAuras"] = {
isAura: true,
aura: "Enemy",
radius: 10,
alignment: "",
type: "",
ignoreSelf: true,
height: false,
hidden: false,
hostile: false,
onlyOnce: false,
displayTemp: true,
};
const itemMacroText = await loadMacroFile("spell", "spiritShroud.js");
setProperty(document, "flags.itemacro", generateItemMacroFlag(document, itemMacroText));
setProperty(document, "flags.midi-qol.onUseMacroName", "[preActiveEffects]ItemMacro");
document.data.damage = { parts: [], versatile: "", value: "" };
document.data['target']['type'] = "self";
document.data.range = { value: null, units: "self", long: null };
document.data.actionType = "other";
document.data.save.ability = "";
document.effects.push(effect);
return document;
}
| javascript |
<reponame>java-park-mail-ru/gwent-09-2017
package ru.mail.park.gwent.domains.game;
import java.util.ArrayList;
import java.util.List;
public class Line {
private CardType type;
private int sumPoints;
private List<Card> lineCards;
Line(CardType type) {
this.type = type;
sumPoints = 0;
lineCards = new ArrayList<>();
}
public CardType getType() {
return type;
}
public void setType(CardType type) {
this.type = type;
}
public void addCard(Card card) {
lineCards.add(card);
recalcPoints();
}
public void clearLine() {
lineCards.clear();
recalcPoints();
}
public int recalcPoints() {
sumPoints = 0;
for (Card card : lineCards) {
sumPoints += card.getPoints();
}
return sumPoints;
}
}
| java |
<reponame>blaxill/oak
// This file is generated by rust-protobuf 2.8.0. Do not edit
// @generated
// https://github.com/Manishearth/rust-clippy/issues/702
#![allow(unknown_lints)]
#![allow(clippy::all)]
#![cfg_attr(rustfmt, rustfmt_skip)]
#![allow(box_pointers)]
#![allow(dead_code)]
#![allow(missing_docs)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]
#![allow(non_upper_case_globals)]
#![allow(trivial_casts)]
#![allow(unsafe_code)]
#![allow(unused_imports)]
#![allow(unused_results)]
//! Generated file from `oak_api.proto`
use protobuf::Message as Message_imported_for_functions;
use protobuf::ProtobufEnum as ProtobufEnum_imported_for_functions;
/// Generated files are compatible only with the same version
/// of protobuf runtime.
const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_8_0;
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
pub enum OakStatus {
OAK_STATUS_UNSPECIFIED = 0,
OK = 1,
ERR_BAD_HANDLE = 2,
ERR_INVALID_ARGS = 3,
ERR_CHANNEL_CLOSED = 4,
ERR_BUFFER_TOO_SMALL = 5,
ERR_HANDLE_SPACE_TOO_SMALL = 6,
ERR_OUT_OF_RANGE = 7,
ERR_INTERNAL = 8,
ERR_TERMINATED = 9,
}
impl ::protobuf::ProtobufEnum for OakStatus {
fn value(&self) -> i32 {
*self as i32
}
fn from_i32(value: i32) -> ::std::option::Option<OakStatus> {
match value {
0 => ::std::option::Option::Some(OakStatus::OAK_STATUS_UNSPECIFIED),
1 => ::std::option::Option::Some(OakStatus::OK),
2 => ::std::option::Option::Some(OakStatus::ERR_BAD_HANDLE),
3 => ::std::option::Option::Some(OakStatus::ERR_INVALID_ARGS),
4 => ::std::option::Option::Some(OakStatus::ERR_CHANNEL_CLOSED),
5 => ::std::option::Option::Some(OakStatus::ERR_BUFFER_TOO_SMALL),
6 => ::std::option::Option::Some(OakStatus::ERR_HANDLE_SPACE_TOO_SMALL),
7 => ::std::option::Option::Some(OakStatus::ERR_OUT_OF_RANGE),
8 => ::std::option::Option::Some(OakStatus::ERR_INTERNAL),
9 => ::std::option::Option::Some(OakStatus::ERR_TERMINATED),
_ => ::std::option::Option::None
}
}
fn values() -> &'static [Self] {
static values: &'static [OakStatus] = &[
OakStatus::OAK_STATUS_UNSPECIFIED,
OakStatus::OK,
OakStatus::ERR_BAD_HANDLE,
OakStatus::ERR_INVALID_ARGS,
OakStatus::ERR_CHANNEL_CLOSED,
OakStatus::ERR_BUFFER_TOO_SMALL,
OakStatus::ERR_HANDLE_SPACE_TOO_SMALL,
OakStatus::ERR_OUT_OF_RANGE,
OakStatus::ERR_INTERNAL,
OakStatus::ERR_TERMINATED,
];
values
}
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
};
unsafe {
descriptor.get(|| {
::protobuf::reflect::EnumDescriptor::new("OakStatus", file_descriptor_proto())
})
}
}
}
impl ::std::marker::Copy for OakStatus {
}
impl ::std::default::Default for OakStatus {
fn default() -> Self {
OakStatus::OAK_STATUS_UNSPECIFIED
}
}
impl ::protobuf::reflect::ProtobufValue for OakStatus {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
}
}
#[derive(Clone,PartialEq,Eq,Debug,Hash)]
pub enum ChannelReadStatus {
NOT_READY = 0,
READ_READY = 1,
INVALID_CHANNEL = 2,
ORPHANED = 3,
}
impl ::protobuf::ProtobufEnum for ChannelReadStatus {
fn value(&self) -> i32 {
*self as i32
}
fn from_i32(value: i32) -> ::std::option::Option<ChannelReadStatus> {
match value {
0 => ::std::option::Option::Some(ChannelReadStatus::NOT_READY),
1 => ::std::option::Option::Some(ChannelReadStatus::READ_READY),
2 => ::std::option::Option::Some(ChannelReadStatus::INVALID_CHANNEL),
3 => ::std::option::Option::Some(ChannelReadStatus::ORPHANED),
_ => ::std::option::Option::None
}
}
fn values() -> &'static [Self] {
static values: &'static [ChannelReadStatus] = &[
ChannelReadStatus::NOT_READY,
ChannelReadStatus::READ_READY,
ChannelReadStatus::INVALID_CHANNEL,
ChannelReadStatus::ORPHANED,
];
values
}
fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
};
unsafe {
descriptor.get(|| {
::protobuf::reflect::EnumDescriptor::new("ChannelReadStatus", file_descriptor_proto())
})
}
}
}
impl ::std::marker::Copy for ChannelReadStatus {
}
impl ::std::default::Default for ChannelReadStatus {
fn default() -> Self {
ChannelReadStatus::NOT_READY
}
}
impl ::protobuf::reflect::ProtobufValue for ChannelReadStatus {
fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
}
}
static file_descriptor_proto_data: &'static [u8] = b"\
\n\roak_api.proto\x12\x03oak*\xe7\x01\n\tOakStatus\x12\x1a\n\x16OAK_STAT\
US_UNSPECIFIED\x10\0\x12\x06\n\x02OK\x10\x01\x12\x12\n\x0eERR_BAD_HANDLE\
\x10\x02\x12\x14\n\x10ERR_INVALID_ARGS\x10\x03\x12\x16\n\x12ERR_CHANNEL_\
CLOSED\x10\x04\x12\x18\n\x14ERR_BUFFER_TOO_SMALL\x10\x05\x12\x1e\n\x1aER\
R_HANDLE_SPACE_TOO_SMALL\x10\x06\x12\x14\n\x10ERR_OUT_OF_RANGE\x10\x07\
\x12\x10\n\x0cERR_INTERNAL\x10\x08\x12\x12\n\x0eERR_TERMINATED\x10\t*U\n\
\x11ChannelReadStatus\x12\r\n\tNOT_READY\x10\0\x12\x0e\n\nREAD_READY\x10\
\x01\x12\x13\n\x0fINVALID_CHANNEL\x10\x02\x12\x0c\n\x08ORPHANED\x10\x03b\
\x06proto3\
";
static mut file_descriptor_proto_lazy: ::protobuf::lazy::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::lazy::Lazy {
lock: ::protobuf::lazy::ONCE_INIT,
ptr: 0 as *const ::protobuf::descriptor::FileDescriptorProto,
};
fn parse_descriptor_proto() -> ::protobuf::descriptor::FileDescriptorProto {
::protobuf::parse_from_bytes(file_descriptor_proto_data).unwrap()
}
pub fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
unsafe {
file_descriptor_proto_lazy.get(|| {
parse_descriptor_proto()
})
}
}
| rust |
Kapil Sharma, the comedy king and the host of Sony TV's popular show The Kapil Sharma Show has shared the image of his daughter on Instagram. Kapil and Ginni became a proud parent to a baby girl in December 2019.
Kapil took to his Instagram handle to share the cute, adorable pics of his daughter Anayra Sharma. He captioned the pic as “Meet our piece of heart “Anayra Sharma” ❤️ 🙏 #gratitude” In the pic, we can see father-daughter sharing a warm relation as the two shares an eye to eye contact. The two are looking cute and adorable together.
Have a look:
Meanwhile, in the coming week, Kapil will be seen welcoming Dhadkan actress Shilpa Shetty who is on the show to promote her upcoming film Hungama 2. Talking about the film then this will be the comeback movie for her and also for director Priyadarshan. The film will release on 12th August 2020.
Coming back to Kapil, when her daughter Anayra was born on 10th December he announced on Twitter and wrote, “Blessed to have a baby girl. Need your blessings. Love you all. Jai Mata Di” The comedian also took no time to resume work and was on set the next day to shoot with his favourite star Deepika Padukone. | english |
Hey there, fellow startup enthusiasts! Today, we’re embarking on an educational journey that looks into the world of entrepreneurship. Whether you’re just getting started or looking to enhance your entrepreneurial skills, we’ve got you covered with valuable insights on overcoming challenges, building a robust brand, and harnessing the power of digital tools and AI.
Starting a business is exhilarating, but it comes with its share of hurdles. Here are some Common Pitfalls to watch out for:
- Lack of Market Research: Before launching, conduct thorough market research. Understand your target audience, competition, and industry trends to make informed decisions.
- Underestimating Costs: Budgeting is crucial. Many startups fail due to inadequate financial planning. Consider all expenses, including the unexpected ones.
- Ignoring Feedback: Listen to your customers and adapt. Ignoring feedback can hinder growth. Embrace constructive criticism to refine your offerings.
- Scaling Too Quickly: Rapid growth can be enticing, but it can also lead to instability. Ensure your infrastructure can support expansion.
How to build a strong brand from scratch?
Building a brand is about more than just a logo and a catchy slogan. It’s about creating a lasting impression. Here’s how to get started:
- Define Your Brand: Clearly define your brand’s values, mission, and unique selling propositions. What sets you apart from the competition?
- Consistency is Key: Maintain consistency in your branding across all platforms. From your website to social media, a unified image helps build trust.
- Engage with Your Audience: Interact with your audience authentically. Engage in conversations, respond to inquiries promptly, and show appreciation for your customers.
- Tell Your Story: Share your journey and vision. People connect with stories, and a compelling narrative can forge emotional connections.
How to take advantage of digital tools and AI to grow your business?
In today’s digital age, leveraging technology is paramount. Here’s how to make the most of digital tools and AI:
- Automation: Automate repetitive tasks with AI-driven tools. This frees up time for strategic decision-making and creative pursuits.
- Data Analytics: Use data analytics to gain insights into customer behavior, market trends, and performance. Data-driven decisions lead to better outcomes.
- Online Presence: Establish a strong online presence through a well-designed website, social media, and e-commerce platforms. Utilize digital marketing to reach a wider audience.
- Customer Relationship Management (CRM): Implement a CRM system to manage customer interactions and nurture relationships. Personalization is key to customer retention.
Achieving work-life balance as an entrepreneur can be challenging but essential for sustained success:
Set Boundaries: Define specific work hours and personal time. Stick to them as much as possible to prevent burnout.
Delegate and Outsource: Don’t try to do everything yourself. Delegate tasks and consider outsourcing non-core functions to free up your time.
Prioritize Self-Care: Make time for self-care, exercise, and relaxation. A healthy mind and body are your most valuable assets.
Quality Over Quantity: Focus on high-impact tasks. Sometimes, accomplishing less but with more quality is more beneficial than multitasking.
In conclusion, the entrepreneurial journey is filled with challenges and opportunities. By navigating common pitfalls, building a strong brand, Harnessing Digital Tools and AI, and mastering work-life balance, you’re better equipped to thrive in the dynamic world of startups. Remember, every obstacle you overcome is a stepping stone to success.
Source: The post Navigating the Startup Journey: Overcoming Common Pitfalls, Building a Strong Brand, and Harnessing Digital Tools appeared first on Sattelite.
| english |
Krishna University UG 5th Semester and Pharma-D 1st and 3rd Semester Results 2017 have been declared by the Krishna University, Machilipatnam on its official website - krishnauniversity. ac. in/.
Krishna University had conducted the 5th semester exams for Under Graduate (UG) programmes in the month of October and November 2017.
Candidates who had appeared in the 5th Semester of UG degree programs and for the 1st and 3rd Semester of Pharma-D programme can check their results now by following the instructions given below:
How to Check Krishna University UG V Semester and Pharma-D I & III Semester Results 2017?
Step 2 – For Under Graduate 5th Semester Exam Results, click on:
For Pharma-D 1st and 3rd Year Results, click on:
About Krishna University:
Established in the year 2008, Krishna University was founded vide Andhra Pradesh Act. No. 4 of 1991, G. O' Ms. No. 89 Higher Education (U. E. II) dated 25th June 2008 and G. O Ms. No. 109, Higher Education (U. E. II) department dated 14th July 2008 at Machilipatnam, which forms the Head Quarters of Krishna District of the state of Andhra Pradesh. On 23rd April 2008, the foundation stone of the Krishna University was laid by the then Chief Minister of Andhra Pradesh - Dr. Y Rajasekhara Reddy. | english |
Posted On:
National Highways Authority of India did a financial closure of its first Toll-Operate-Transfer project with the India chief of Macquarie handing over a cheque for Rs 9,681.5 crore to Shri Nitin Gadkari, Minister of Road Transport & Highways, Shipping, Water Resources, River Development & Ganga Rejuvenation at an event in New Delhi today. This closure is the first for an asset recycling initiative by any government in India. NHAI has also called bids for second bundle of T-O-T for 586.55 km in Gujarat, Rajasthan, West Bengal and Bihar.
Speaking on the occasion Shri Gadkari said, the government has taken initiatives to increase the investment in highways sector by almost four-fold since 2014. This year the government has allocated Rs, 71,000 crore for development of roads and highways in the country. The remaining funding requirements to meet ambitious plans are being managed through market borrowing and private sector investments.
The Minister said, the second bundle of T-O-T has been offered and several more bundles will be offered in the months to come. He called upon the private investors to bid for these bundles, saying TOT is a risk-free model. He also invited investors to come up with more innovative investment models for the infrastructure sector.
Exhorting investors for qualitative improvement, Shri Gadkari called upon the concessionaires to concentrate upon improving road safety, quality of maintenance and improving toll collection methods so that waiting time at toll plazas is cut down drastically..
Minister of State for Road Transport & Highways Shri Mansukh Lal Mandavia underlined government’s commitment towards providing good governance. He said, the government has increased budgetary support for infrastructure sector from nearly 1.5 lakh crore to almost 7 lakh crore. He, however, called for more public private partnership to enhance investment in the road sector.
Road Transport & Highways Secretary Shri Yudhvir Singh Malik prioritised road safety and quality. He called upon the foreign investors to bring international practices in road development and safety.
The first bundle of 9 projects, totalling approximately 681 KM of roads in two states of Andhra Pradesh and Gujarat, was awarded in 2018. Huge interest was shown by foreign investors. TOT Bundle-I was awarded to Macquarie for Rs. 9,681 Crore, which was 1.5 times the Authority’s estimate.
The second bundle of over 586 kms is now offered spread over four States – Rajasthan, Gujarat, West Bengal and Bihar. The offer has 12 toll plazas across four highways.
Length (Km)
Read this release in:
| english |
/*
* Copyright 2021 by <NAME>. Licensed under MIT license.
*
* Github: https://github.com/BobKerns/retirement-simulator
*/
/**
* A set of utilities for working with calendar time.
* @module
*/
import { range } from "genutils";
import { day, isLeapYear, MONTH_START, UTC } from "./calendar-utils";
import { Age, asAge, asYear, Relaxed, Year } from "../tagged";
/**
* Obtain the day number of a given `Date`
* @param d The given `Date`.
* @returns number of days since January 1
*/
export const day_of_year = (d: Date) =>
(d.valueOf() - year(d).valueOf()) /
(24 * 60 * 60 * 1000);
/**
* Return the `Date` for January 1 in the year of the supplied date.
* @param d the date
*/
export const year = (d: Date) =>
years[d.getUTCFullYear()] ?? UTC(d.getUTCFullYear());
/**
* The number of days in a particular year.
* @param year The year as a number
* @returns 365 or 366
*/
export const yearDays = (year: Relaxed<Year>) => isLeapYear(year) ? 366 : 365;
/**
* The day of the year.
* @param date
* @returns
*/
export const dayOfYear = (date: Date) => {
const month = date.getUTCMonth();
const day = date.getUTCDate();
return MONTH_START[isLeapYear(date.getUTCFullYear()) ? 1 : 0][month] + day;
};
/**
* Calculate the difference between two dates, in fractional years.
*/
export const calculate_age = (birth: Date, thisDate: Date): Age => {
const bday = day_of_year(birth);
const tday = day_of_year(thisDate);
const bleap = isLeapYear(birth.getUTCFullYear());
const tleap = isLeapYear(thisDate.getUTCFullYear());
const bdayLeap = bday < 60
? bday
: bleap
? bday - 1
: bday;
const tdayLeap = tday < 60
? tday
: tleap
? tday - 1
: tday;
const year = thisDate.getUTCFullYear();
const diff = year - birth.getUTCFullYear();
const days = yearDays(bday < 60 ? year - 1 : year);
const frac = (tday - bday) / days;
return asAge(diff + frac);
};
/**
* Today as a `Date`, starting at midnite (UTC).
*/
export const TODAY = day(new Date());
/**
* This year as a 4-digit number.
*/
export const YEAR = asYear(TODAY.getUTCFullYear());
/**
* Default to 50 years.
*/
export let END_YEAR = asYear(YEAR + 50);
/**
* `Date` a century in the future.
*/
export const END_OF_TIME = UTC(YEAR + 100);
/**
* Year number a century in the future.
*/
export const END_OF_YEARS = asYear(END_OF_TIME.getUTCFullYear() + 1);
/**
* The year boundaries for the next century.
*/
const years = range(YEAR, END_OF_YEARS).map(v => UTC(v)).asArray();
/**
* This year as a `Date` referring to January 1.
*/
export const THIS_YEAR = year(TODAY); | typescript |
<reponame>BrinsLee/Music
package com.brins.baselib.widget;
import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.view.View;
import android.widget.ImageView;
import com.brins.baselib.R;
import static com.brins.baselib.utils.SizeUtils.dp2px;
/**
* Created by lipeilin
* on 2020/11/16
*/
public class TagFlowLayout extends FlowLayout implements TagAdapter.OnDataChangedListener {
private static final String TAG = "TagFlowLayout";
private OnTagClickListener mOnTagClickListener;
private TagAdapter mTagAdapter;
private int mShowMax = -1;
public interface OnTagClickListener {
boolean onTagClick(View view, int position, FlowLayout parent);
}
public TagFlowLayout(Context context) {
this(context, null);
}
public TagFlowLayout(Context context, AttributeSet attrs) {
this(context, attrs, 0);
}
public TagFlowLayout(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
TypedArray ta = context.obtainStyledAttributes(attrs, R.styleable.TagFlowLayout);
mShowMax = ta.getInt(R.styleable.TagFlowLayout_max_show, -1);
ta.recycle();
}
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int cCount = getChildCount();
for (int i = 0; i < cCount; i++) {
TagView tagView = (TagView) getChildAt(i);
if (tagView.getVisibility() == View.GONE) {
continue;
}
if (tagView.getTagView().getVisibility() == View.GONE) {
tagView.setVisibility(View.GONE);
}
}
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
}
public void setOnTagClickListener(OnTagClickListener onTagClickListener) {
mOnTagClickListener = onTagClickListener;
}
public void setAdapter(TagAdapter adapter) {
mTagAdapter = adapter;
mTagAdapter.setOnDataChangedListener(this);
changeAdapter(mShowMax > 0 ? Math.min(adapter.getCount(), mShowMax) : adapter.getCount());
}
private void changeAdapter(final int showNum) {
removeAllViews();
final TagAdapter adapter = mTagAdapter;
TagView tagViewContainer = null;
for (int i = 0; i <= showNum; i++) {
View tagView;
if (i == showNum) {
ImageView imageView = new ImageView(getContext());
imageView.setImageResource(showNum == adapter.getCount() ? R.drawable.base_icon_back_up_black : R.drawable.base_icon_back_down_black);
imageView.setScaleType(ImageView.ScaleType.CENTER_INSIDE);
imageView.setBackgroundResource(R.drawable.base_bg_circle);
tagView = imageView;
if (adapter.getCount() != 0 && adapter.getCount() > mShowMax) {
tagView.setVisibility(VISIBLE);
} else {
tagView.setVisibility(GONE);
}
} else {
tagView = adapter.getView(this, i, adapter.getItem(i));
tagView.setClickable(false);
}
tagViewContainer = new TagView(getContext());
tagView.setDuplicateParentStateEnabled(true);
if (tagView.getLayoutParams() != null) {
tagViewContainer.setLayoutParams(tagView.getLayoutParams());
} else {
MarginLayoutParams lp = new MarginLayoutParams(
LayoutParams.WRAP_CONTENT,
LayoutParams.WRAP_CONTENT);
lp.setMargins(dp2px(5),
dp2px(5),
dp2px(5),
dp2px(5));
tagViewContainer.setLayoutParams(lp);
}
LayoutParams lp = new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT);
tagView.setLayoutParams(lp);
tagViewContainer.addView(tagView);
final TagView finalTagViewContainer = tagViewContainer;
final int position = i;
addView(tagViewContainer);
tagViewContainer.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
if (mOnTagClickListener != null && position != showNum) {
mOnTagClickListener.onTagClick(finalTagViewContainer, position,
TagFlowLayout.this);
} else {
changeAdapter(showNum == adapter.getCount() ? Math.min(mShowMax, adapter.getCount()) : adapter.getCount());
}
}
});
}
}
public TagAdapter getAdapter() {
return mTagAdapter;
}
@Override
public void onChanged() {
changeAdapter(mShowMax > 0 ? Math.min(mTagAdapter.getCount(), mShowMax) : mTagAdapter.getCount());
}
}
| java |
<filename>src/app/services/auth.service.ts
import { FirebaseService } from 'src/app/services/firebase.service';
import { Injectable } from '@angular/core';
import { AngularFireAuth } from '@angular/fire/auth';
import * as firebase from 'firebase';
import { AuthUser, socialProvider } from '../models/auth-user';
import { BehaviorSubject } from 'rxjs';
import { take } from 'rxjs/internal/operators/take';
import { JwtHelperService } from '@auth0/angular-jwt';
@Injectable({
providedIn: 'root'
})
export class AuthService {
public currentUser: AuthUser;
// criar um BehaviorSubject...
public userSubject: BehaviorSubject<AuthUser> = new BehaviorSubject(null);
constructor(
public afAuth: AngularFireAuth,
private fbs: FirebaseService) {
this.checkLocalStorage();
}
/** Verifica se o usuário já encontra-se autenticado
* Compara o id do usuário no jwt token (token) com
* o valor armazenado em userData.
*/
checkLocalStorage() {
const jwt = localStorage.getItem('token');
const localUser = localStorage.getItem('userData');
const jwtHelper = new JwtHelperService();
if (jwt && localUser) {
// console.log('jwt: ', jwt);
// console.log('localUser: ', localUser);
const decodedToken = jwtHelper.decodeToken(jwt);
const isExpired = jwtHelper.isTokenExpired(jwt);
// console.log('decoded jwt Token: ', decodedToken);
// console.log('decoded jwt Token isExpired: ', isExpired);
if (!isExpired) {
// Se o token de autenticação não expirou e representa o mesmo usuário...
if ((JSON.parse(localUser) as AuthUser).id === decodedToken.user_id) {
this.currentUser = (JSON.parse(localUser) as AuthUser);
this.userSubject.next(this.currentUser);
} else {
// Se tem diferença, remove token
localStorage.removeItem('token');
localStorage.removeItem('userData');
}
} else {
// se está expirado, remove o token
localStorage.removeItem('token');
localStorage.removeItem('userData');
}
}
}
SocialAuth(sProvider: socialProvider) {
if (sProvider === socialProvider.google) {
return this.AuthLogin(new firebase.auth.GoogleAuthProvider());
}
if (sProvider === socialProvider.microsoft) {
return this.AuthLogin(new firebase.auth.OAuthProvider('microsoft.com'));
}
}
AuthLogin(provider) {
return this.afAuth.signInWithPopup(provider)
.then((result) => {
const userCredential: firebase.auth.UserCredential = result;
const user: firebase.User = userCredential.user;
// Grava o token de acesso no localstorage
user.getIdToken().then((p) => {
localStorage.setItem('token', p);
});
this.currentUser = new AuthUser(user.uid, user.email, user.displayName, user.photoURL);
// Ok, temos os dados do usuário
// Ele existe no banco ??
this.fbs.getSingleItem<AuthUser>(user.uid, 'users').pipe(take(1)).subscribe(p => {
if (p) {
// ele já existe no banco!!
if (p.isAdmin) {
this.currentUser.isAdmin = p.isAdmin;
this.currentUser.isApproved = p.isApproved;
}
}
// se já existe, vai atualizar. Se não existe, vai criar...
// Se a chamada anterior não retornar um usuário por erro,
// vai sobreescrever o usuário forçando o flag de admin como false.
this.fbs.saveOrUpdate<AuthUser>(this.currentUser, 'users').pipe(take(1)).subscribe();
// grava no localstorage no fim de tudo
localStorage.setItem('userData', JSON.stringify(this.currentUser));
// emite usuario para menu.
this.userSubject.next(this.currentUser);
});
})
.catch((error) => {
console.log('Erro no login', error);
});
}
AuthLogout() {
this.afAuth.signOut();
this.currentUser = null;
this.userSubject.next(this.currentUser);
localStorage.removeItem('userData');
localStorage.removeItem('token');
}
}
| typescript |
# math function
import math
# round number
x = 2.9
print(round(x))
# absolute value of number
y = -5
print(abs(y))
# make use of the math library
z = 2.5
print(math.ceil(z)) # round up the number
print(math.floor(z)) # round down the number
# for finding more math module just search "python math module"
| python |
<gh_stars>1-10
package commands
import (
"github.com/8Mobius8/go-habits/api"
. "github.com/8Mobius8/go-habits/integration"
. "github.com/onsi/ginkgo"
. "github.com/onsi/gomega"
"github.com/onsi/gomega/gbytes"
"github.com/onsi/gomega/gexec"
)
var _ = Describe("go-habits complete command", func() {
BeforeEach(func() {
TouchConfigFile()
expectSuccessfulLogin(UserName, Password)
})
AfterEach(func() {
ResetUser()
RemoveConfigFile()
})
It("exits safely when showing usage", func() {
session := GoHabits("complete", "--help")
Eventually(session).Should(gbytes.Say("Usage:"))
Eventually(session).Should(gbytes.Say(`go-habits complete \[flags\]`))
Eventually(session).Should(gexec.Exit(0))
})
Describe("when completing a task by number", func() {
Context("given a task has been already created", func() {
var task api.Task
BeforeEach(func() {
task = api.NewTask("A Task to complete", api.TodoType)
t, err := APIClient.AddTask(task)
task = t
Expect(err).ShouldNot(HaveOccurred())
})
It("will print task completed", func() {
s := GoHabits("complete", "1")
Eventually(s).Should(gbytes.Say("[X]"))
Eventually(s).Should(gbytes.Say(task.Title))
Eventually(s).Should(gexec.Exit(0))
})
It("will mark the task completed on the server", func() {
s := GoHabits("complete", "1")
Eventually(s).Should(gexec.Exit(0))
t := api.Task{}
err := APIClient.Get("/tasks/"+task.ID, &t)
Expect(err).ToNot(HaveOccurred())
Expect(t.Completed).Should(Equal(true))
})
It("will print rewards for completing", func() {
s := GoHabits("complete", "1")
Eventually(s).Should(gexec.Exit(0))
Eventually(s).Should(gbytes.Say("MP: [0-9]+\\.[0-9]+"))
Eventually(s).Should(gbytes.Say("GP: [0-9]+\\.[0-9]+"))
Eventually(s).Should(gbytes.Say("XP: [0-9]+\\.[0-9]+"))
})
})
Context("given no task has been created", func() {
It("will print no tasks have been created.", func() {
s := GoHabits("complete", "1")
Eventually(s).Should(gbytes.Say("You have no tasks."))
Eventually(s).Should(gbytes.Say("Create tasks before trying to complete them."))
Eventually(s).Should(gexec.Exit(1))
})
})
})
})
| go |
{
"author": {
"id": "t2_16ycovb",
"name": "tiny_architect"
},
"date": {
"day": 1547078400,
"full": 1547101919,
"month": 1546300800,
"week": 1546732800
},
"id": "t3_aege48",
"picture": {
"filesize": 59847,
"fullUrl": "https://preview.redd.it/mftp92nsij921.jpg?auto=webp&s=e29b700a564d4581257d9aac99c9d86a84b264d8",
"hash": "5ea5ec0c7a",
"height": 467,
"lqip": "data:image/jpg;base64,/9j/2wBDAAYEBQYFBAYGBQYHBwYIChAKCgkJChQODwwQFxQYGBcUFhYaHSUfGhsjHBYWICwgIyYnKSopGR8tMC0oMCUoKSj/2wBDAQcHBwoIChMKChMoGhYaKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCj/wAARCAAMABADASIAAhEBAxEB/8QAFQABAQAAAAAAAAAAAAAAAAAABgX/xAAiEAABAwQCAgMAAAAAAAAAAAABAgMEBQYRIQAxBxITYXH/xAAVAQEBAAAAAAAAAAAAAAAAAAAAAf/EABURAQEAAAAAAAAAAAAAAAAAAAAh/9oADAMBAAIRAxEAPwBjeHkeaqoVGmW8+1EEVYbDrjYUpRBwSQo4AzoA465Ht2/Ja601Frsxp2G+fjDq0BKkLOPUkjWCdfWe+OrtsCk12Wag8/PjSXz6umK8EBeB2QQd8LW547ozc52XJcmzXIj2WkyHQUAjYUQAMn95KP/Z",
"url": "https://preview.redd.it/mftp92nsij921.jpg?width=640&crop=smart&auto=webp&s=0d0305ed15b320db52ae47f1fabff484f5a5f8bd",
"width": 640
},
"score": {
"comments": 25,
"downs": 0,
"ratio": 0.98,
"ups": 160,
"value": 160
},
"subreddit": {
"id": "t5_2xy5e",
"name": "TerrainBuilding"
},
"tags": [],
"title": "Done! Let's call it \"small edge of town with a well and cart\" piece.",
"url": "https://www.reddit.com/r/TerrainBuilding/comments/aege48/done_lets_call_it_small_edge_of_town_with_a_well/"
}
| json |
<filename>3. JavaScript temelleri - Part 2/3. Fonksiyonlar, IIFE & Anonim fonksiyonlar/app.js
// Funksiya təyin etmə - yaratma
/*
function hello () {
console.log("Hello");
}
function func (name, age) {
if (typeof name === "undefined") name = "<NAME>!";
if (typeof age === "undefined") age = "Yaş yoxdur!";
console.log(`Ad: ${name}, Yaş: ${age}`);
}
*/
// Funksiyanı çağırma - Function Call
/*
hello();
func("Qara", 21);
func("Ülvi", 20);
func();
*/
// Default dəyər vermənin (func funksiyası kimi) qısayolu
/*
function person (surname = "<NAME>", name = "<NAME>") {
console.log(`Soyad: ${surname}, Ad: ${name}`);
}
person();
*/
/* Return - funksiya daxilindən bizə dəyər geri qaytarır.
Return yazılmadıqda Cube() funksiyası işləmir.
Çünki Square() funksiyasından dəyər gəlmir, alınan sadəcə funksiyanın nəticəsidir
Return həmdə bir funksiyanı sonlandırmağı bildiri
*/
/*
function square(x) {
// console.log(x * x);
return x * x;
console.log("Salam"); // Heç vaxt işləmir - Return-ə görə
}
*/
/*
function cube(x) {
// console.log(x * x * x);
return x * x * x;
}
// let a = square(12);
// a = cube(a);
let a = cube(square(12));
console.log(a);
*/
/*
function salam() {
return "Salam";
}
console.log(salam());
// salam() funksiyasını - Function Expression kimi yaza bilərik
const merhaba = function (name) {
console.log("Merhaba, " + name);
};
merhaba("Qara");
*/
/*
IIFE - Immediately Invoked Function Expression
Təyin olunduğu, yaradıldığı yerdə işləyən funksiyalar
*/
/*
(function(name) {
console.log("Necəsən, " + name);
})("Nurlan");
*/
const database = {
host: "localhost",
add: function(){
console.log("Əlavə edildi");
},
get: function(){
console.log("Əldə edildi");
},
update: function(id){
console.log(`Id: ${id} Yeniləndi`);
},
delete: function(id){
console.log(`Id: ${id} Silindi`);
}
}
console.log(database.host);
database.add();
database.delete(10); | javascript |
<filename>rail/v3/client/t_r_a/train_live_board_api_controller_get_responses.go
// Code generated by go-swagger; DO NOT EDIT.
package t_r_a
// This file was generated by the swagger tool.
// Editing this file might prove futile when you re-run the swagger generate command
import (
"fmt"
"io"
"github.com/go-openapi/runtime"
"github.com/go-openapi/strfmt"
"github.com/minchao/go-ptx/rail/v3/models"
)
// TrainLiveBoardAPIControllerGetReader is a Reader for the TrainLiveBoardAPIControllerGet structure.
type TrainLiveBoardAPIControllerGetReader struct {
formats strfmt.Registry
}
// ReadResponse reads a server response into the received o.
func (o *TrainLiveBoardAPIControllerGetReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
switch response.Code() {
case 200:
result := NewTrainLiveBoardAPIControllerGetOK()
if err := result.readResponse(response, consumer, o.formats); err != nil {
return nil, err
}
return result, nil
case 299:
result := NewTrainLiveBoardAPIControllerGetStatus299()
if err := result.readResponse(response, consumer, o.formats); err != nil {
return nil, err
}
return result, nil
case 304:
result := NewTrainLiveBoardAPIControllerGetNotModified()
if err := result.readResponse(response, consumer, o.formats); err != nil {
return nil, err
}
return nil, result
default:
return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code())
}
}
// NewTrainLiveBoardAPIControllerGetOK creates a TrainLiveBoardAPIControllerGetOK with default headers values
func NewTrainLiveBoardAPIControllerGetOK() *TrainLiveBoardAPIControllerGetOK {
return &TrainLiveBoardAPIControllerGetOK{}
}
/* TrainLiveBoardAPIControllerGetOK describes a response with status code 200, with default header values.
Success
*/
type TrainLiveBoardAPIControllerGetOK struct {
Payload *models.PTXAPIRailModelTRARealTimeWrapperPTXServiceDTORailSpecificationV3TRATRATrainLiveBoardListTrainLiveBoard
}
func (o *TrainLiveBoardAPIControllerGetOK) Error() string {
return fmt.Sprintf("[GET /v3/Rail/TRA/TrainLiveBoard][%d] trainLiveBoardApiControllerGetOK %+v", 200, o.Payload)
}
func (o *TrainLiveBoardAPIControllerGetOK) GetPayload() *models.PTXAPIRailModelTRARealTimeWrapperPTXServiceDTORailSpecificationV3TRATRATrainLiveBoardListTrainLiveBoard {
return o.Payload
}
func (o *TrainLiveBoardAPIControllerGetOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
o.Payload = new(models.PTXAPIRailModelTRARealTimeWrapperPTXServiceDTORailSpecificationV3TRATRATrainLiveBoardListTrainLiveBoard)
// response payload
if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
return err
}
return nil
}
// NewTrainLiveBoardAPIControllerGetStatus299 creates a TrainLiveBoardAPIControllerGetStatus299 with default headers values
func NewTrainLiveBoardAPIControllerGetStatus299() *TrainLiveBoardAPIControllerGetStatus299 {
return &TrainLiveBoardAPIControllerGetStatus299{}
}
/* TrainLiveBoardAPIControllerGetStatus299 describes a response with status code 299, with default header values.
加入參數'?health=true'即可查詢此API服務的健康狀態
*/
type TrainLiveBoardAPIControllerGetStatus299 struct {
Payload *models.PTXServiceDTOSharedSpecificationV3BaseDisplayHealth
}
func (o *TrainLiveBoardAPIControllerGetStatus299) Error() string {
return fmt.Sprintf("[GET /v3/Rail/TRA/TrainLiveBoard][%d] trainLiveBoardApiControllerGetStatus299 %+v", 299, o.Payload)
}
func (o *TrainLiveBoardAPIControllerGetStatus299) GetPayload() *models.PTXServiceDTOSharedSpecificationV3BaseDisplayHealth {
return o.Payload
}
func (o *TrainLiveBoardAPIControllerGetStatus299) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
o.Payload = new(models.PTXServiceDTOSharedSpecificationV3BaseDisplayHealth)
// response payload
if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
return err
}
return nil
}
// NewTrainLiveBoardAPIControllerGetNotModified creates a TrainLiveBoardAPIControllerGetNotModified with default headers values
func NewTrainLiveBoardAPIControllerGetNotModified() *TrainLiveBoardAPIControllerGetNotModified {
return &TrainLiveBoardAPIControllerGetNotModified{}
}
/* TrainLiveBoardAPIControllerGetNotModified describes a response with status code 304, with default header values.
服務端會在Response加上Last-Modified header,表示最近的更新時間。客戶端能利用此時間,於Request加上If-Modified-Since header,若沒有更新,服務端會回應304 StatusCode且空值Content
*/
type TrainLiveBoardAPIControllerGetNotModified struct {
}
func (o *TrainLiveBoardAPIControllerGetNotModified) Error() string {
return fmt.Sprintf("[GET /v3/Rail/TRA/TrainLiveBoard][%d] trainLiveBoardApiControllerGetNotModified ", 304)
}
func (o *TrainLiveBoardAPIControllerGetNotModified) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
return nil
}
| go |
16 (A)So circumcise [a]your heart, and (B)stiffen your neck no longer.
27 For I know (A)your rebellion and (B)your [a]stubbornness; behold, while I am still alive with you today, you have been rebellious against the Lord; how much more, then, after my death?
14 However, they did not listen, but (A)stiffened their neck [a]like their fathers, who did not believe in the Lord their God.
New American Standard Bible®, Copyright © 1960, 1971, 1977, 1995 by The Lockman Foundation. All rights reserved.
| english |
Chapters on the Non-Alignment Movement, the Cold War era, the rise of Islamic empires in Afro-Asian territories, the chronicles of Mughal courts, and the industrial revolution have been dropped from the CBSE Class 11 and 12 political science syllabus.
From the Class 10 social science syllabus, CBSE has dropped the topic "impact of globalisation on agriculture" from a chapter on 'Food Security'.
two Urdu poems by Faiz Ahmed Faiz have also been dropped from the section 'Religion, Communalism and Politics - Communalism, Secular State'.
Chapters on 'democracy and diversity' have been dropped from the syllabus as well.
When queries about the reason behind these topics being dropped from the syllabus, officials said that the exclusions were part of the syllabus rationalisation process and were in line with NCERT recommendations. | english |
<filename>ares/component/processor/z80/z80.hpp
#pragma once
//Zilog Z80
namespace ares {
struct Z80 {
struct Bus {
virtual auto read(n16 address) -> n8 = 0;
virtual auto write(n16 address, n8 data) -> void = 0;
virtual auto in(n16 address) -> n8 = 0;
virtual auto out(n16 address, n8 data) -> void = 0;
};
virtual auto step(u32 clocks) -> void = 0;
virtual auto synchronizing() const -> bool = 0;
//CMOS: out (c) writes 0x00
//NMOS: out (c) writes 0xff; if an interrupt fires during "ld a,i" or "ld a,r", PF is cleared
enum class MOSFET : u32 { CMOS, NMOS };
//z80.cpp
auto power(MOSFET = MOSFET::NMOS) -> void;
auto irq(bool maskable, n16 vector = 0x0000, n8 extbus = 0xff) -> bool;
auto parity(n8) const -> bool;
//memory.cpp
auto wait(u32 clocks = 1) -> void;
auto opcode() -> n8;
auto operand() -> n8;
auto operands() -> n16;
auto push(n16) -> void;
auto pop() -> n16;
auto displace(n16&) -> n16;
auto read(n16 address) -> n8;
auto write(n16 address, n8 data) -> void;
auto in(n16 address) -> n8;
auto out(n16 address, n8 data) -> void;
//instruction.cpp
auto instruction() -> void;
auto instruction(n8 code) -> void;
auto instructionCB(n8 code) -> void;
auto instructionCBd(n16 address, n8 code) -> void;
auto instructionED(n8 code) -> void;
//algorithms.cpp
auto ADD(n8, n8, bool = false) -> n8;
auto AND(n8, n8) -> n8;
auto BIT(n3, n8) -> n8;
auto CP (n8, n8) -> void;
auto DEC(n8) -> n8;
auto IN (n8) -> n8;
auto INC(n8) -> n8;
auto OR (n8, n8) -> n8;
auto RES(n3, n8) -> n8;
auto RL (n8) -> n8;
auto RLC(n8) -> n8;
auto RR (n8) -> n8;
auto RRC(n8) -> n8;
auto SET(n3, n8) -> n8;
auto SLA(n8) -> n8;
auto SLL(n8) -> n8;
auto SRA(n8) -> n8;
auto SRL(n8) -> n8;
auto SUB(n8, n8, bool = false) -> n8;
auto XOR(n8, n8) -> n8;
//instructions.cpp
auto instructionADC_a_irr(n16&) -> void;
auto instructionADC_a_n() -> void;
auto instructionADC_a_r(n8&) -> void;
auto instructionADC_hl_rr(n16&) -> void;
auto instructionADD_a_irr(n16&) -> void;
auto instructionADD_a_n() -> void;
auto instructionADD_a_r(n8&) -> void;
auto instructionADD_hl_rr(n16&) -> void;
auto instructionAND_a_irr(n16&) -> void;
auto instructionAND_a_n() -> void;
auto instructionAND_a_r(n8&) -> void;
auto instructionBIT_o_irr(n3, n16&) -> void;
auto instructionBIT_o_irr_r(n3, n16&, n8&) -> void;
auto instructionBIT_o_r(n3, n8&) -> void;
auto instructionCALL_c_nn(bool c) -> void;
auto instructionCALL_nn() -> void;
auto instructionCCF() -> void;
auto instructionCP_a_irr(n16& x) -> void;
auto instructionCP_a_n() -> void;
auto instructionCP_a_r(n8& x) -> void;
auto instructionCPD() -> void;
auto instructionCPDR() -> void;
auto instructionCPI() -> void;
auto instructionCPIR() -> void;
auto instructionCPL() -> void;
auto instructionDAA() -> void;
auto instructionDEC_irr(n16&) -> void;
auto instructionDEC_r(n8&) -> void;
auto instructionDEC_rr(n16&) -> void;
auto instructionDI() -> void;
auto instructionDJNZ_e() -> void;
auto instructionEI() -> void;
auto instructionEX_irr_rr(n16&, n16&) -> void;
auto instructionEX_rr_rr(n16&, n16&) -> void;
auto instructionEXX() -> void;
auto instructionHALT() -> void;
auto instructionIM_o(n2) -> void;
auto instructionIN_a_in() -> void;
auto instructionIN_r_ic(n8&) -> void;
auto instructionIN_ic() -> void;
auto instructionINC_irr(n16&) -> void;
auto instructionINC_r(n8&) -> void;
auto instructionINC_rr(n16&) -> void;
auto instructionIND() -> void;
auto instructionINDR() -> void;
auto instructionINI() -> void;
auto instructionINIR() -> void;
auto instructionJP_c_nn(bool) -> void;
auto instructionJP_rr(n16&) -> void;
auto instructionJR_c_e(bool) -> void;
auto instructionLD_a_inn() -> void;
auto instructionLD_a_irr(n16& x) -> void;
auto instructionLD_inn_a() -> void;
auto instructionLD_inn_rr(n16&) -> void;
auto instructionLD_irr_a(n16&) -> void;
auto instructionLD_irr_n(n16&) -> void;
auto instructionLD_irr_r(n16&, n8&) -> void;
auto instructionLD_r_n(n8&) -> void;
auto instructionLD_r_irr(n8&, n16&) -> void;
auto instructionLD_r_r(n8&, n8&) -> void;
auto instructionLD_r_r1(n8&, n8&) -> void;
auto instructionLD_r_r2(n8&, n8&) -> void;
auto instructionLD_rr_inn(n16&) -> void;
auto instructionLD_rr_nn(n16&) -> void;
auto instructionLD_sp_rr(n16&) -> void;
auto instructionLDD() -> void;
auto instructionLDDR() -> void;
auto instructionLDI() -> void;
auto instructionLDIR() -> void;
auto instructionNEG() -> void;
auto instructionNOP() -> void;
auto instructionOR_a_irr(n16&) -> void;
auto instructionOR_a_n() -> void;
auto instructionOR_a_r(n8&) -> void;
auto instructionOTDR() -> void;
auto instructionOTIR() -> void;
auto instructionOUT_ic_r(n8&) -> void;
auto instructionOUT_ic() -> void;
auto instructionOUT_in_a() -> void;
auto instructionOUTD() -> void;
auto instructionOUTI() -> void;
auto instructionPOP_rr(n16&) -> void;
auto instructionPUSH_rr(n16&) -> void;
auto instructionRES_o_irr(n3, n16&) -> void;
auto instructionRES_o_irr_r(n3, n16&, n8&) -> void;
auto instructionRES_o_r(n3, n8&) -> void;
auto instructionRET() -> void;
auto instructionRET_c(bool c) -> void;
auto instructionRETI() -> void;
auto instructionRETN() -> void;
auto instructionRL_irr(n16&) -> void;
auto instructionRL_irr_r(n16&, n8&) -> void;
auto instructionRL_r(n8&) -> void;
auto instructionRLA() -> void;
auto instructionRLC_irr(n16&) -> void;
auto instructionRLC_irr_r(n16&, n8&) -> void;
auto instructionRLC_r(n8&) -> void;
auto instructionRLCA() -> void;
auto instructionRLD() -> void;
auto instructionRR_irr(n16&) -> void;
auto instructionRR_irr_r(n16&, n8&) -> void;
auto instructionRR_r(n8&) -> void;
auto instructionRRA() -> void;
auto instructionRRC_irr(n16&) -> void;
auto instructionRRC_irr_r(n16&, n8&) -> void;
auto instructionRRC_r(n8&) -> void;
auto instructionRRCA() -> void;
auto instructionRRD() -> void;
auto instructionRST_o(n3) -> void;
auto instructionSBC_a_irr(n16&) -> void;
auto instructionSBC_a_n() -> void;
auto instructionSBC_a_r(n8&) -> void;
auto instructionSBC_hl_rr(n16&) -> void;
auto instructionSCF() -> void;
auto instructionSET_o_irr(n3, n16&) -> void;
auto instructionSET_o_irr_r(n3, n16&, n8&) -> void;
auto instructionSET_o_r(n3, n8&) -> void;
auto instructionSLA_irr(n16&) -> void;
auto instructionSLA_irr_r(n16&, n8&) -> void;
auto instructionSLA_r(n8&) -> void;
auto instructionSLL_irr(n16&) -> void;
auto instructionSLL_irr_r(n16&, n8&) -> void;
auto instructionSLL_r(n8&) -> void;
auto instructionSRA_irr(n16&) -> void;
auto instructionSRA_irr_r(n16&, n8&) -> void;
auto instructionSRA_r(n8&) -> void;
auto instructionSRL_irr(n16&) -> void;
auto instructionSRL_irr_r(n16&, n8&) -> void;
auto instructionSRL_r(n8&) -> void;
auto instructionSUB_a_irr(n16&) -> void;
auto instructionSUB_a_n() -> void;
auto instructionSUB_a_r(n8&) -> void;
auto instructionXOR_a_irr(n16&) -> void;
auto instructionXOR_a_n() -> void;
auto instructionXOR_a_r(n8&) -> void;
//serialization.cpp
auto serialize(serializer&) -> void;
//disassembler.cpp
noinline auto disassembleInstruction(maybe<n16> pc = {}) -> string;
noinline auto disassembleContext() -> string;
auto disassemble(n16 pc, n8 prefix, n8 code) -> string;
auto disassembleCB(n16 pc, n8 prefix, n8 code) -> string;
auto disassembleCBd(n16 pc, n8 prefix, i8 d, n8 code) -> string;
auto disassembleED(n16 pc, n8 prefix, n8 code) -> string;
MOSFET mosfet = MOSFET::NMOS;
enum class Prefix : u32 { hl, ix, iy } prefix = Prefix::hl;
union Pair {
Pair() : word(0) {}
n16 word;
struct Byte { n8 order_msb2(hi, lo); } byte;
};
Pair af, af_;
Pair bc, bc_;
Pair de, de_;
Pair hl, hl_;
Pair ix;
Pair iy;
Pair ir;
Pair wz;
n16 SP;
n16 PC;
b1 EI; //"ei" executed last
b1 P; //"ld a,i" or "ld a,r" executed last
b1 Q; //opcode that updated flag registers executed last
b1 HALT; //"halt" instruction executed
b1 IFF1; //interrupt flip-flop 1
b1 IFF2; //interrupt flip-flop 2
n2 IM; //interrupt mode (0-2)
Bus* bus = nullptr;
};
}
| cpp |
Mumbai: Profit booking, negative global cues and a weak rupee subdued the Indian equity markets on Friday. Heavy selling pressure was witnessed in automobile and information technology (IT) stocks. NSE Nifty slipped by 6. 35 points or 0. 07 per cent to 8,666. 90 points. The barometer 30-scrip Sensex closed at 28,077 points, down 46. 44 points or 0. 17 per cent from the previous close at 28,123. 44 points.
Opened at 28,167. 66 points, Sensex touched a high of 28,212. 30 points and a low of 28,026. 12 points during the intra-day trading.
In contrast, the BSE market breadth was tilted in favour of the bulls with 1,413 advances and 1,159 declines.
On Thursday, the benchmark indices had closed in the green prompted by positive global cues and value buying.
The barometer index had closed higher by 118. 07 points or 0. 42 per cent, while the NSE Nifty edged up 49. 20 points or 0. 57 per cent.
“Negative Asian and European markets weighed heavy on the domestic equity indices. Profit booking, along with a weak rupee also dented investors’ sentiments,” Anand James, Chief Market Strategist at Geojit BNP Paribas Financial Services, said.
According to Dhruv Desai, Director and Chief Operating Officer of Tradebulls, banking and auto stocks traded with mixed sentiments on profit booking. IT and pharma stocks traded with sideways to firm sentiments, whereas aviation stocks faced selling pressure due to higher crude oil prices,” Desai noted.
“FMCG stocks traded with sideways sentiments on lack of buying support. Sugar stocks traded firm on short covering and some lower levels buying. ” Desai added that Nifty is likely to face resistance at higher levels due to firm USD/INR futures prices. | english |
The ‘fabulous’ four — Maheep Kapoor, Bhavna Pandey, Neelam Kothari and Seema Khan — who make up the cast of Netflix’s ‘The Fabulous Lives Of Bollywood Wives‘, are busy promoting the second season, which has come out on the streaming site almost two years since its debut in 2020.
In one of the promotional bits shared on Instagram by the official Netflix India account, the quartet could be seen engaging in a fun banter, pulling each other’s legs. Needless to say, they looked gorgeous as ever, and the secret to their ‘youthful’ glow was — not just a flawless style and makeup — something that is considered to be earthy.
At one point Bhavna — who is married to Chunky Panday and is the mother of actor Ananya Panday — announced that she has “figured out a way to reverse aging“. She allowed her friends to take guesses; while Seema thought it was botox, Neelam offered “headstands“.
Bhavna went on to demonstrate some poses, the first one being “fish pose“. It entails pouting of the lips, akin to what a puffer fish does. All four of them held this pose for a bit and proceeded to smile which, Bhavna claimed, is what does the trick.
Then, Bhavna asked her friends to enunciate the five vowels of the English language, namely A, E, I, O and U. While they felt it was a childish exercise, Bhavna said doing this can make the face look “tightened”.
Finally, she demonstrated the “crane pose”, even as her friends protested that doing face yoga made them look funny and “ridiculous”.
Bhavna said it can make the neck lines go away, and that the reason she does not have any is because she does these exercises. She jutted her neck outwards and then pulled it inwards and her friends followed suit.
Indianexpress. com had previously reported on the benefits of face yoga — that it has been attributed to yield face-lifting, tightening, and sculpting benefits without salon or dermatologists’ interventions. It involves working the facial muscles to improve blood circulation for a healthy glow by stimulating the production of collagen, relaxing tension on your face, de-puffing it, and also improving facial symmetry.
📣 For more lifestyle news, follow us on Instagram | Twitter | Facebook and don’t miss out on the latest updates! | english |
<filename>node_modules/object-filter-sequence/package.json
{
"name": "object-filter-sequence",
"version": "1.0.0",
"description": "Apply a sequence of filter functions to an object",
"main": "index.js",
"scripts": {
"precoverage": "npm run test",
"coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov",
"pretest": "standard",
"test": "nyc tape test.js"
},
"keywords": [
"object",
"filter",
"sequence"
],
"author": "<NAME> <<EMAIL>> (https://github.com/qard)",
"license": "MIT",
"devDependencies": {
"codecov": "^3.1.0",
"nyc": "^13.1.0",
"standard": "^12.0.1",
"tape": "^4.0.0"
},
"dependencies": {},
"repository": {
"type": "git",
"url": "git+https://github.com/elastic/object-filter-sequence.git"
},
"bugs": {
"url": "https://github.com/elastic/object-filter-sequence/issues"
},
"homepage": "https://github.com/elastic/object-filter-sequence#readme"
}
| json |
In a recent conversation with the BBC, James Cameron, the Oscar-winning filmmaker who made the iconic 1997 blockbuster Titanic, claimed that the recent disappearance of the Titan submersible felt personal and that he could sense the loss “in [his] bones. ” He further added how he himself had been to the Titanic's wreckage site 33 times.
The underwater vessel, owned by OceanGate, went missing on the morning of Sunday, June 18, 1 hour and 45 minutes into its dive towards the Titanic wreckage. After more than five days of an extensive search, rescue parties involved finally announced that a “catastrophic implosion” during descent is what destroyed the missing submersible.
So far, five major outer fragments of the vessel have reportedly been detected by a robotic diving vehicle, which are lying right beside the Titanic wreckage. No human remains have been traced so far, but the five people on board are presumed to be dead.
Famous Hollywood director, James Cameron, who has made 33 round trips to the Titanic wreckage, first went down in 1995 to capture footage for his famous 1997 film, Titan. Cameron has even penned a book detailing accounts of his expeditions; Titled Exploring The Deep, it includes images, maps, and routes of his dive journey.
In his recent interview to the BBC, he stated that he did not hear about the missing submersible until Monday, June 18, as he was on a ship on Sunday. He further continued that when he found out that the Titan lost both its navigation and communication simultaneously, it didn’t take him long to suspect a disaster.
In addition, he disclosed that as soon as he heard the fateful news, he contacted some of his friends in the “deep submersible community. ” In less than an hour’s time, he was apparently provided with all the facts.
According to James Cameron's facts, the submersible was on its descent when it went missing. Additionally, it was at 3500 meters targeting the bottom at 3800 meters. Not only that, but both its communication and navigation were lost. Learning this, he instantly figured out that losing communication and navigation together sans an “extreme catastrophic event or high, highly energetic catastrophic event” was unlikely:
Interestingly, after James Cameron’s revelation, it was announced on Thursday, June 22, that the US Navy indeed traced “an acoustic anomaly consistent with an implosion” right after the vessel went missing on Sunday. However, the news was reportedly kept a secret so far to avoid speculations. In fact, the US Coast Guard, which was involved in the search and rescue mission used this particular piece of information to narrow down its initial search radius.
James Cameron further told the British news outlet that the past week has “felt like a prolonged and nightmarish charade where people are running around talking about banging noises and talking about oxygen and all this other stuff. ”:
“I knew that sub was sitting exactly underneath its last known depth and position. That's exactly where they found it,” he added.
James Cameron also explained how deep submergence diving is a “nature art” and that the 22-foot Titan submersible was not equipped for it, having many safety concerns.
James Cameron also drew a comparison between the 1912 Titanic tragedy and the recent one:
“For a very similar tragedy, where warnings went unheeded, to take place at the same exact site with all the diving that’s going on all around the world, I think it’s just astonishing. It’s really quite surreal,” Cameron concluded.
While the Titanic that had sunk on April 15, 1912, killed around 1500 passengers, the Titan submersible that went in search of the ocean liner’s ruins took the lives of five -- French submersible specialist Paul-Henry Nargeolet, American CEO and founder of OceanGate (the company that made the Titan) Stockton Rush as the vessel’s pilot, and three tourists, who each paid 250,000 dollars for the trip.
The tourists were father-son duo Shahzada and Sulaiman Dawood from one of Pakistan’s infamous and wealthiest families, and British billionaire businessman and explorer Hamish Harding. | english |
The pop icon Madonna is set for her own biopic. The 62-year-old musician and humanitarian will direct her own biopic and co-write with Oscar-winning writer Diablo Cody.
According to Variety, "The untitled film has landed at Universal Pictures, under the wing of filmed entertainment group chair Donna Langley and producer Amy Pascal, whose eponymous company is set up on the Universal lot. A production timeline is unknown and principal cast has yet to be announced."
Madonna has previously directed the 2008 drama Filth and Wisdom, and W.E in 2011.
Catch us for latest Bollywood News, New Bollywood Movies update, Box office collection, New Movies Release , Bollywood News Hindi, Entertainment News, Bollywood Live News Today & Upcoming Movies 2024 and stay updated with latest hindi movies only on Bollywood Hungama.
| english |
<reponame>andreeaiana/renewrs_corpus_extraction
{"news_outlet": "taz", "provenance": "https://taz.de/Grundeinkommen-Test-in-Finnland/!5571734/", "query_keywords": ["grundeinkommen", "bedingungslos einkommen"], "creation_date": "09.02.2019", "last_modified": "10.02.2019", "crawl_date": "30.12.2020", "author_person": ["<NAME>"], "author_organization": [], "news_keywords": ["Bedingungsloses Grundeinkommen", "Grundeinkommen", "Finnland", "Arbeit", "\u00d6ko", "taz", "tageszeitung "], "content": {"title": "Grundeinkommen-Test in Finnland: Doch, es macht schon gl\u00fccklicher", "description": "Zwei Jahre lang bekamen 2000 Arbeitslose in Finnland ein Grundeinkommen. Das Ergebnis: Es gab nicht mehr Jobchancen, wohl aber weniger Stress.", "body": {"": ["STOCKHOLM taz | Zwei Jahre lang dauerte der Versuch mit einem bedingungslosen Grundeinkommen in Finnland. Am Freitag wurde eine erste vorl\u00e4ufige Analyse vorgelegt. \u201eDas Grundeinkommen hatte einen positiven Effekt auf das Wohlbefinden der Empf\u00e4nger. Die Aussicht auf eine Besch\u00e4ftigung scheint sich damit aber nicht verbessern zu lassen\u201c, fasste Minna Ylik\u00e4nn\u00f6, Forscherin bei der Sozialversicherungsbeh\u00f6rde KELA die Ergebnisse zusammen: \u201eJedenfalls nicht auf kurze Sicht.\u201c", "Konkret hatten 2017, dem Jahr, auf das sich die jetzige Analyse allein bezieht, von den 2.000 Arbeitslosen zwischen 25 und 58 Jahren, die monatlich 560 Euro steuerfrei ausgezahlt bekommen hatten, 44 Prozent ein zeitweises Erwerbseinkommen an durchschnittlich 49,6 Tagen. Bei einer Vergleichsgruppe ohne Grundeinkommen und mit dem gew\u00f6hnlichen Arbeitslosengeld waren es 43 Prozent an 49,2 Tagen. Daf\u00fcr bekam diese Vergleichsgruppe ihre Arbeit etwas besser bezahlt: Mit 4.251 statt 4.230 Euro. \u201eIm Prinzip lief es auf dem Arbeitsmarkt aber f\u00fcr keine Gruppe besser oder schlechter\u201c, konstatiert der KELA-Forscher Ohto Kanninen.", "Deutlichere Unterschiede erbrachten die Interviews zum gesundheitlichen Wohlergehen: 25 Prozent aus der Kontrollgruppe klagten \u00fcber \u201esehr viel\u201c oder \u201eziemlich viel\u201c Stress, bei den Grundeinkommen-TeilnehmerInnen waren es nur 17 Prozent. Allerdings beantworteten nur 23 Prozent die Interviewfragen.", "Finnlands rechte Regierungskoalition, die den zweij\u00e4hrigen Versuch initiiert hatte, hatte sich eigentlich einen positiveren Besch\u00e4ftigungseffekt erwartet: Abgesichert durch das Grundeinkommen w\u00e4ren deren Empf\u00e4ngerInnen wom\u00f6glich eher bereit, auch kurzzeitige oder schlechter bezahlte Arbeit anzunehmen. Die rechtsliberale Zentrumspartei von Ministerpr\u00e4sident Juha Sipil\u00e4 hat das bedingungslose Grundeinkommen deshalb bereits wieder zu den Akten gelegt."], "Gr\u00fcne fordern gr\u00f6\u00dferen Test": ["Stattdessen will man jetzt eine vom Bedarf abh\u00e4ngige und nur auf Antrag gew\u00e4hrte Grundsicherung, deren Gegenleistung ein \u201eZurverf\u00fcgungstehen f\u00fcr den Arbeitsmarkt\u201c ist. Bei einem Versto\u00df sollen Sanktionen drohen. Ohne Sanktionen gehe es nicht, meinen auch die Sozialdemokraten. Womit man wieder bei einer allenfalls b\u00fcrokratisch etwas vereinfachten Form des gegenw\u00e4rtigen Sozialversicherungssystems landen w\u00fcrde.", "Vor den Parlamentswahlen im April verfechten in Finnland im Moment nur noch Gr\u00fcne und Linkspartei das Modell eines bedingungslosen Grundeinkommens. Die Gr\u00fcnen schlagen einen neuen Versuch mit 10.000 TeilnehmerInnen in unterschiedlichen Lebenssituationen \u2013 also nicht nur Arbeitslose \u2013 vor. Auch die KELA-ForscherInnen h\u00e4tten gern ein umfassenderes und besser vorbereitetes Experiment. Und PolitikerInnen, die sich wirklich f\u00fcr das Thema interessieren \u201eund auf die Forscher h\u00f6ren\u201c, meint <NAME>\u00e4nn\u00f6: Beim beendeten Versuch sei das Interesse aus dem Ausland viel gr\u00f6\u00dfer gewesen als in Finnland selbst.", "Trotzdem ein erfolgreiches Experiment? \u201eIch w\u00fcrde Ja sagen\u201c, meint KELA-Forschungsleiter <NAME>: \u201eAber ein zuverl\u00e4ssiges Bild bekommen wir erst, wenn der ganze Versuch analysiert ist.\u201c Das soll im Fr\u00fchjahr 2020 der Fall sein."]}}, "recommendations": []} | json |
const Tweeter = artifacts.require("Tweeter");
module.exports = function(deployer) {
deployer.deploy(Tweeter);
};
| javascript |
<reponame>three-Vs/hedera-services
package com.hedera.services.bdd.suites.regression;
/*-
*
* Hedera Services Test Clients
*
* Copyright (C) 2018 - 2021 Hedera Hashgraph, LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
import com.hedera.services.bdd.spec.HapiApiSpec;
import com.hedera.services.bdd.spec.HapiSpecOperation;
import com.hedera.services.bdd.spec.infrastructure.OpProvider;
import com.hedera.services.bdd.spec.transactions.TxnUtils;
import com.hedera.services.bdd.suites.HapiApiSuite;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import java.util.List;
import java.util.Optional;
import java.util.concurrent.TimeUnit;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong;
import java.util.concurrent.atomic.AtomicReference;
import java.util.function.Function;
import static com.hedera.services.bdd.spec.HapiApiSpec.defaultHapiSpec;
import static com.hedera.services.bdd.spec.transactions.TxnVerbs.cryptoCreate;
import static com.hedera.services.bdd.spec.transactions.TxnVerbs.cryptoTransfer;
import static com.hedera.services.bdd.spec.transactions.TxnVerbs.fileUpdate;
import static com.hedera.services.bdd.spec.transactions.TxnVerbs.scheduleCreate;
import static com.hedera.services.bdd.spec.transactions.crypto.HapiCryptoTransfer.tinyBarsFromTo;
import static com.hedera.services.bdd.spec.utilops.UtilVerbs.runWithProvider;
import static com.hedera.services.bdd.spec.utilops.UtilVerbs.withOpContext;
import static com.hedera.services.bdd.suites.utils.sysfiles.serdes.ThrottleDefsLoader.protoDefsFromResource;
import static com.hederahashgraph.api.proto.java.ResponseCodeEnum.BUSY;
import static com.hederahashgraph.api.proto.java.ResponseCodeEnum.OK;
import static java.util.concurrent.TimeUnit.SECONDS;
public class SplittingThrottlesWorks extends HapiApiSuite {
private static final Logger log = LogManager.getLogger(SplittingThrottlesWorks.class);
private static final int scheduleCreatesPerCryptoCreate = 12;
private AtomicLong duration = new AtomicLong(120);
private AtomicReference<TimeUnit> unit = new AtomicReference<>(SECONDS);
private AtomicInteger maxOpsPerSec = new AtomicInteger(4 * scheduleCreatesPerCryptoCreate + 2);
public static void main(String... args) {
new SplittingThrottlesWorks().runSuiteSync();
}
@Override
protected List<HapiApiSpec> getSpecsInSuite() {
return List.of(
new HapiApiSpec[] {
setNewLimits(),
tryCreations(),
}
);
}
private HapiApiSpec setNewLimits() {
var artificialLimits = protoDefsFromResource("testSystemFiles/split-throttles.json");
return defaultHapiSpec("SetNewLimits")
.given().when().then(
fileUpdate(THROTTLE_DEFS)
.payingWith(EXCHANGE_RATE_CONTROL)
.contents(artificialLimits.toByteArray())
);
}
private HapiApiSpec tryCreations() {
return defaultHapiSpec("TryCreations")
.given().when(
runWithProvider(cryptoCreateOps())
.lasting(duration::get, unit::get)
.maxOpsPerSec(maxOpsPerSec::get)
).then(
withOpContext((spec, opLog) -> {
var actualTps = 1.0 * spec.finalAdhoc() / duration.get();
opLog.info("Total ops accepted in {} {} = {} ==> {}tps",
duration.get(),
unit.get(),
spec.finalAdhoc(),
actualTps);
})
);
}
private Function<HapiApiSpec, OpProvider> cryptoCreateOps() {
var i = new AtomicInteger(0);
return spec -> new OpProvider() {
@Override
public List<HapiSpecOperation> suggestedInitializers() {
return List.of(
cryptoCreate("civilian")
.payingWith(GENESIS)
.balance(ONE_MILLION_HBARS)
.withRecharging()
);
}
@Override
public Optional<HapiSpecOperation> get() {
HapiSpecOperation op;
final var nextI = i.getAndIncrement();
if (nextI % (scheduleCreatesPerCryptoCreate + 1) == 0) {
op = cryptoCreate("w/e" + nextI)
.noLogging()
.deferStatusResolution()
.payingWith("civilian")
.hasPrecheckFrom(OK, BUSY);
} else {
op = scheduleCreate("scheduleW/e" + nextI,
cryptoTransfer(tinyBarsFromTo("civilian", FUNDING, 1))
.memo(TxnUtils.randomAlphaNumeric(32))
.hasPrecheckFrom(STANDARD_PERMISSIBLE_PRECHECKS)
)
.noLogging()
.deferStatusResolution()
.payingWith("civilian")
.hasPrecheckFrom(OK, BUSY);
}
return Optional.of(op);
}
};
}
@Override
protected Logger getResultsLogger() {
return log;
}
}
| java |
{
"id": 139968,
"name": "<NAME>",
"description": "На странице профиля заменяет фамильяра на увеличенного Драфлаеля.",
"user": {
"id": 398994,
"name": "Kulala",
"email": "redacted",
"paypal_email": null,
"homepage": null,
"about": null,
"license": null
},
"updated": "2017-03-11T10:57:36.000Z",
"weekly_install_count": 0,
"total_install_count": 722,
"rating": null,
"after_screenshot_name": "https://userstyles.org/style_screenshots/139968_after.png?r=1589962114",
"obsoleting_style_id": null,
"obsoleting_style_name": null,
"obsolete": 0,
"admin_delete_reason_id": null,
"obsoletion_message": null,
"screenshots": [
"https://userstyles.org/style_screenshots/139968_additional_25310.png?r=1589962114"
],
"license": null,
"created": "2017-03-10T12:47:41.000Z",
"category": "site",
"raw_subcategory": "eldarya",
"subcategory": "eldarya",
"additional_info": null,
"style_tags": [],
"css": "@-moz-document url-prefix(\"http://www.eldarya.fr/\"), url-prefix(\"http://fa1.eldarya.com/\"), url-prefix(\"http://www.eldarya.ru/\"), url-prefix(\"http://www.eldarya.com/\"), url-prefix(\"http://www.eldarya.br/\"), url-prefix(\"http://www.eldarya.de/\"), url-prefix(\"http://www.eldarya.es/\"), url-prefix(\"http://www.eldarya.fi/\"), url-prefix(\"http://www.eldarya.hu/\"), url-prefix(\"http://www.eldarya.it/\"), url-prefix(\"http://www.eldarya.pl/\")\r\n {\r\n /*[[css1]]*/\r\n }",
"discussions": [],
"discussionsCount": 0,
"commentsCount": 0,
"userjs_url": "/styles/userjs/139968/big-draflael.user.js",
"style_settings": [
{
"id": 457020,
"style_id": 139968,
"install_key": "css1",
"label": "~",
"ordinal": 0,
"setting_type": "dropdown",
"style_setting_options": [
{
"id": 1642610,
"style_setting_id": 457020,
"label": "Draflael",
"value": "#player-display-pet {\r\nbackground : url(\"http://img4.hostingpics.net/pics/733846aaf130ffc85c65e9c760bee0833bd8651428582301.png\") no-repeat ;\r\nbackground-size : auto 100% ;\r\nheight : 596px !important ;\r\nwidth : 466px !important ;\r\n}\r\n\r\n#player-display-pet > img {display : none !important ;}",
"default": true,
"ordinal": 0,
"install_key": "css1-1"
},
{
"id": 1642611,
"style_setting_id": 457020,
"label": "Baby Draflael",
"value": "#player-display-pet {\r\nbackground : url(\"http://img4.hostingpics.net/pics/9356284931727274289d9f826f42524692777e.png\") no-repeat ;\r\nbackground-size : auto 100% ;\r\nheight : 190px !important ;\r\nwidth : 286px !important ;\r\n}\r\n\r\n#player-display-pet > img {display : none !important ;}",
"default": false,
"ordinal": 1,
"install_key": "css1-2"
}
]
}
]
} | json |
La Liga is gradually shaping up after 17 rounds of matches. Atletico Madrid have so far given a good account of themselves and currently sit at the top of the table. However, they are closely followed by Real Madrid.
Los Blancos made a poor start to the season but have been in imperious form in recent weeks.
On Saturday, Real Madrid consolidated their position in the league after recording an important 2-0 win against Celta Vigo. It wasn’t a very dominant performance but they were clinical enough to come away with the victpry.
Lucas Vazquez opened the scoring for Zinedine Zidane’s side inside the first six minutes before Marco Asensio doubled their lead early in the second half to seal the victory.
The inconsistencies of Real Madrid and Barcelona have allowed Atletico Madrid to take the lead in La Liga. However, Los Blancos are closer to their city rivals than Barcelona are.
Atletico currently sit top of the table with 38 points while Real Madrid are just two points below. Barcelona are in fifth position and 10 points behind Simeone’s side.
It is very important for Real Madrid to stay as close as possible to Los Rojiblancos, especially as the season enters its most crucial period.
Atletico Madrid hold a two-point lead at the top of the table, with two games in hand. Should they win those games, they will move eight points above Real Madrid, and the defending champions cannot allow that to happen.
It has taken some time, but Real Madrid have finally introduced some consistency into their game. They have not lost in any of their last eight games in all competitions.
Los Blancos have also won six of their last seven league games despite missing some key players in their squad. Only Atletico Madrid have won more points in that period.
Addressing the media after the Celta Vigo win, Zidane said (as quoted by Goal):
"We played a complete game from the beginning to the end. We controlled the game well, we had a good balance, when it came to pressing up and getting the ball back, we did everything well."
"You have to control when the rival team has strong moments in the game, but the feelings are good, out of nine games we won six and three draws."
The race for La Liga is still on and although Atletico Madrid have taken an early lead, Real Madrid cannot be ruled out just yet.
| english |
{"relation": [["Description", "Log to syslog.", "Disable nginx's memory pool to help valgrind and other tools (for nginx C developers only)", "SSL Session tickets distributed via memcached", "output client certificate expiration time"], ["Author", "<NAME>", "shrimp, agentzh", "<NAME>", "SunGod"], ["Link", "Patch for version 0.8.49 with 'sh is not bash' fix | Syslog Patch for Nginx 0.8.54+", "Git repository for the patch", "Git repository for changes", "File:Nginx-0.7.67.ssl cert date.patch.txt"]], "pageTitle": "Difference between revisions of \"3rdPartyModules\" - Nginx Community", "title": "", "url": "http://wiki.nginx.org/index.php?title=3rdPartyModules&diff=3246&oldid=1634", "hasHeader": true, "headerPosition": "FIRST_ROW", "tableType": "RELATION", "tableNum": 5, "s3Link": "common-crawl/crawl-data/CC-MAIN-2015-32/segments/1438042988458.74/warc/CC-MAIN-20150728002308-00104-ip-10-236-191-2.ec2.internal.warc.gz", "recordEndOffset": 259898119, "recordOffset": 259876704, "tableOrientation": "HORIZONTAL", "textBeforeTable": "Known modules See also the tools at the bottom of this page. A github search turned up the Nginx Development Kit. It seems to be more up to date. Evan Miller has written the definitive guide to Nginx module development. But some parts of it are a little out of date. You've been warned. Writing your own module Be aware that some modules may require additional libraries to be installed on your system. You can use as many --add-module arguments as needed. --add-module=/path/to/module2/source ./configure --add-module=/path/to/module1/source \\ From the Nginx source directory, type: Modules are typically added by compiling them along with the Nginx source. Compiling third party modules These modules are not officially supported and may not be compatible across versions of Nginx. Nevertheless many of them may prove useful to many people. Enjoy at your own risk. Third party modules 6 References 5 Tools for Migration 4 Third party patches 3 Tools for module developers 2 Known modules 1.2 Writing your own module 1.1 Compiling", "textAfterTable": "Restricts access to content to Akamai edge servers using G2O headers refractalize Download Array Var Add support for array variables to nginx config files agentzh Download Auth Digest HTTP Digest Authentication. <NAME> Download Auth PAM HTTP Basic Authentication using PAM. <NAME> Download Auth Request Allows authorization based on subrequest result. <NAME> Download Auto Lib Reuse pre-compiled/installed versions of OpenSSL, PCRE and Zlib without re-compiling them each time Nginx is compiled <NAME> Download AWS auth Generate security headers for GET requests to Amazon S3. <NAME> Download Backtrace A nginx module to dump backtrace case a worker process", "hasKeyColumn": true, "keyColumnIndex": 0, "headerRowIndex": 0} | json |
<reponame>33kk/uso-archive
{
"id": 17286,
"name": "Erqqvg Compact - Minimal Space",
"description": "Minimal space for your own increased time-wasting pleasure.\r\n\r\nPlease leave me a word or two. I would love making improvements",
"user": {
"id": 22673,
"name": "galskapen",
"email": "redacted",
"paypal_email": null,
"homepage": null,
"about": null,
"license": null
},
"updated": "2009-04-24T21:59:22.000Z",
"weekly_install_count": 0,
"total_install_count": 144,
"rating": null,
"after_screenshot_name": "https://userstyles.org/style_screenshots/17286_after.png?r=1565510497",
"obsoleting_style_id": null,
"obsoleting_style_name": null,
"obsolete": 0,
"admin_delete_reason_id": null,
"obsoletion_message": null,
"screenshots": null,
"license": null,
"created": "2009-04-24T20:21:05.000Z",
"category": "site",
"raw_subcategory": "erqqvg",
"subcategory": "erqqvg",
"additional_info": null,
"style_tags": [],
"css": "@namespace url(http://www.w3.org/1999/xhtml);\r\n\r\n@-moz-document domain(\"erqqvg.com\") {\r\n\r\nbody {margin:0 !important;}\r\n#navbar {margin:-1px 0 0 -1px!important; padding:0 !important;}\r\n#navbar a {padding:0 5px !important;}\r\n#slownotice, #header {display:none !important;}\r\n#viewlinks {float:right !important;width:300px !important;margin-top:-18px !important;padding:0 !important;}\r\n#viewlinks a {padding:0 5px !important;}\r\n#live {margin-top: 5px !important;}\r\n\r\n}",
"discussions": [],
"discussionsCount": 0,
"commentsCount": 0,
"userjs_url": "/styles/userjs/17286/erqqvg-compact-minimal-space.user.js",
"style_settings": []
} | json |
Having scored a mammoth 226 in the last match, it was expected that the Stars would ride on momentum and take control of the situation.
However, what happened was contrary to expectations. Being put in to bat first the team lost openers Andre Fletcher and David Warner for 8 and 14 respectively. After that, no other batsman could spend time at the crease. The famed middle order of the Stars, constituting of Lendl Simmons, Rovman Powell and Kieron Pollard was dismissed cheaply.
Qais Ahmed tried to hold his own but he did not get support from any of his teammates. As a result, owing to 3 wickets by Sheldon Cottrell and two each by Mohammadullah and Sandeep Lamichhane, St Lucia Stars were skittled out for a meagre 69.
No matter how hard the St Lucia bowlers tried, it was too small a total to defend. The St Kitts and Nevis Patriots batsmen came out all guns blazing and tried to finish the match quickly in order to gain some positive net run rate.
Devon Thomas and Evin Lewis batted positively. However, Lewis got out cheaply and could not get back to form. After Tom Cooper ran himself out for naught, Anton Devcich and Devon Thomas took the team home with 7 wickets to spare.
Captain Chris Gayle had an easy day at work as he did not come out to bat. The Stars have to now win all their remaining 4 matches to have a chance of qualifying to the playoffs.
| english |
{
"directions": [
"Bring 2 cups salted water to boil in medium saucepan. Add quinoa, reduce heat to medium-low, cover, and simmer until tender and water is absorbed, about 13 minutes.",
"Meanwhile, heat oil in large skillet over medium-high heat. Add onion and saut\u00e9 until onion begins to brown, 5 minutes. Add garlic; stir 30 seconds. Add mushrooms and thyme. Saut\u00e9e; until mushrooms are tender, 6 minutes. Add wine; stir until wine is reduced and liquid is syrupy, 2 minutes.",
"Mix quinoa into mushroom mixture; season with salt and pepper. Pass cheese separately."
],
"ingredients": [
"1 cup quinoa, rinsed",
"1 tablespoon olive oil",
"1 1/2 cups chopped onion",
"1 garlic clove, pressed",
"1 8-ounce package sliced crimini (baby bella) mushrooms",
"6 ounces fresh shiitake mushrooms, stemmed, sliced",
"3 teaspoons chopped fresh thyme, divided",
"1 cup dry white wine",
"Grated Parmesan cheese"
],
"language": "en-US",
"source": "www.epicurious.com",
"tags": [
"Mushroom",
"Onion",
"Side",
"Vegetarian",
"Quick & Easy",
"Low Cal",
"Dinner",
"Quinoa",
"Healthy",
"Low Cholesterol",
"Thyme",
"Sugar Conscious",
"Pescatarian",
"Wheat/Gluten-Free",
"Peanut Free",
"Tree Nut Free",
"Soy Free",
"Kosher"
],
"title": "Quinoa Risotto with Mushrooms and Thyme",
"url": "http://www.epicurious.com/recipes/food/views/quinoa-risotto-with-mushrooms-and-thyme-356690"
}
| json |
<reponame>Minigugus/connect-postgres-simple
import {
PostgresStore,
PostgresStoreCtor,
PostgresStoreOptions
} from './dist/index';
declare function connectPostgresSimple({ Store }: typeof import('express-session')): PostgresStoreCtor;
declare namespace connectPostgresSimple {
export type { PostgresStore, PostgresStoreOptions }
}
export = connectPostgresSimple;
| typescript |
#include "battery.h"
#include <esp_adc_cal.h>
#include "Watchy.h" // for logging macros
namespace Watchy {
esp_adc_cal_characteristics_t *getADCCharacteristics() {
static esp_adc_cal_characteristics_t *adc_chars; // default is nullptr
if (!adc_chars) {
// only initialize it if we're actually going to use it.
adc_chars = new esp_adc_cal_characteristics_t();
adc1_config_width(ADC_WIDTH_BIT_12);
adc1_config_channel_atten(ADC1_GPIO33_CHANNEL, ADC_ATTEN_DB_11);
esp_adc_cal_value_t cal = esp_adc_cal_characterize(
ADC_UNIT_1, ADC_ATTEN_DB_11, ADC_WIDTH_BIT_12, 1100, adc_chars);
if (cal == ESP_ADC_CAL_VAL_DEFAULT_VREF) {
LOGW("adc calibration is using default vref. Accuracy will suffer.");
}
}
return adc_chars;
}
float getBatteryVoltage() {
// make sure ADC is initialized before we read it.
esp_adc_cal_characteristics_t *adcChar = getADCCharacteristics();
// average 4 samples to reduce noise
int raw =
(adc1_get_raw(ADC1_GPIO33_CHANNEL) + adc1_get_raw(ADC1_GPIO33_CHANNEL) +
adc1_get_raw(ADC1_GPIO33_CHANNEL) + adc1_get_raw(ADC1_GPIO33_CHANNEL) +
2) /
4;
return esp_adc_cal_raw_to_voltage(raw, adcChar) * 2.0 / 1000.0;
}
} // namespace Watchy | cpp |
As there is an alarming spike in the number of COVID-19 cases, the sealed floors and wings in the residential buildings has gone up in the second wave of coronavirus.
According to reports, more than 80 per cent of the cases have been reported from the societies and high rise buildings in Mumbai.
The Brihanmumbai Municipal Corporation (BMC) has sealed more than 700 buildings in Mumbai, reports suggested. This list was published on April 5, 2021, and the names of some of the buildings may have been omitted or new names may have been added accordingly.
Here is the list of building sealed in BMC's F (south) ward comprising of Dadar, Parel, Sewri areas of Mumbai:
According to the BMC’s policy, if one or more COVID-19 patients are found in a building, then the entire floor is sealed. While if more than five patients are found infected, the building is sealed by the Municipal Corporation. However, to avoid any inconvenience to other residents, the Municipal Corporation has adopted a policy of sealing the floors or the entire wing of the building instead of completely sealing the building. Besides, the authority to seal the building has been given to local authorities. | english |
NEW DELHI: At the ninth conference of the federal policy think tank NITI Aayog, which will be held in New Delhi on Saturday, Prime Minister Narendra Modi and state chief ministers will lay out a plan for a developed India.
The summit, as per NITI Aayog, would focus on developing a cooperative plan for a "Vikasit Bharat by 2047" in which the national government and the states cooperate as "Team India. "
As India's socioeconomic change and growth have the potential to have a positive multiplier impact, this would be crucial in the global context, according to an NITI Aayog social media post on the meeting on Saturday.
The focus of the meeting will be particularly on micro, small, and medium-sized businesses, which are the foundation of both the manufacturing and export industries. According to government estimates, MSMEs produce about 45% of manufacturing output, more than 40% of exports, more than 28% of the GDP, and employ about 111 million people.
Infrastructure and investments, minimising compliance, women's empowerment, health and nutrition, skill development, and social infrastructure will also be covered at the summit.
According to NITI Aayog, India's progress is directly related to that of the states. According to the policy think tank, this will serve as the inspiration for India's inclusive and sustainable agenda for the ensuing 25 years.
The federal policy think tank's Governing Council convenes once a year to set the national agenda, which in the past has included concerns like encouraging the use of locally produced goods, identifying export opportunities that will create jobs locally, and adopting a common resolution to increase GST collections. As a coordinated approach might produce better results, it also provides the Centre with a chance to promote its important programmes and policy concepts at the state level.
Eight major topics, including (i) Viksit Bharat@2047, (ii) Thrust on MSMEs, (iii) Infrastructure and Investments, (iv) Minimising Compliances, (v) Women Empowerment, (vi) Health and Nutrition, (vii) Skill Development, and (viii) Gati Shakti for area development and social infrastructure, will be covered during the day-long meeting, according to the NITI Aayog. | english |
Pawan Kalyan likes to do things in his own terms.
The opinionated actor doesn't like to be hurried. He takes his time to make movies. And is also fussy kind of actor. He will never do a scene unless he is fully satisfied. Compromise, in his lexicon, is a bad word.
So with such a quality control mind, Pawan has managed to wind up Bangaram. The movie has been in the making for long. Slow, you can say, even by PawanÂs standards.
But in the case Pawan it is all professionalism. He is a perfectionist.
Insiders say that the Bangaram has come out indeed well.
Director Dharani, who cut his teeth in Tamil with stunning commercial entertainers, has managed to repeat the magic.
Dharani knows a thing or two about action entertainers and usually gets the percentages right.
Though there were some differences of opinion between the two, it was confined to how the script should move. Both are thorough professionals and have let that quality show through in the movie.
Now that the film is complete, the entire industry is waiting for a look of it.
The postproduction work has begun and the filmÂs audio is expected for release soon.
Follow us on Google News and stay updated with the latest! | english |
<reponame>whyjz/CARST<filename>extra/unused/bedTopo.py
#!/usr/bin/python
def dirDeriv(val_mat, direction_mat, inc):
import scipy;
import scipy.linalg;
import math;
cell_angles = scipy.array([[3 * math.pi / 4, math.pi / 2, math.pi / 4], [math.pi, scipy.nan, 0], [-3 * math.pi / 4, -1 * math.pi / 2, -1 * math.pi / 4]]);
cell_incs = scipy.array([[(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5], [inc, scipy.nan, inc], [(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5]]);
angle = direction_mat[1,1];
vals_x = scipy.cos(angle - direction_mat) * val_mat;
vals_y = scipy.sin(angle - direction_mat) * val_mat;
cell_cosines_f = scipy.cos(angle - cell_angles);
cell_cosines_b = scipy.cos(angle - cell_angles);
cell_sines_f = scipy.sin(angle - cell_angles);
cell_sines_b = scipy.sin(angle - cell_angles);
cell_cosines_f[cell_cosines_f < 0.00001] = scipy.nan;
cell_cosines_f = cell_cosines_f**2;
cell_cosines_f = cell_cosines_f / sum(cell_cosines_f[~scipy.isnan(cell_cosines_f)]);
cell_cosines_b[cell_cosines_b > -0.00001] = scipy.nan;
cell_cosines_b = cell_cosines_b**2;
cell_cosines_b = cell_cosines_b / sum(cell_cosines_b[~scipy.isnan(cell_cosines_b)]);
cell_sines_f[cell_sines_f < 0.00001] = scipy.nan;
cell_sines_f = cell_sines_f**2;
cell_sines_f = cell_sines_f / sum(cell_sines_f[~scipy.isnan(cell_sines_f)]);
cell_sines_b[cell_sines_b > -0.00001] = scipy.nan;
cell_sines_b = cell_sines_b**2;
cell_sines_b = cell_sines_b / sum(cell_sines_b[~scipy.isnan(cell_sines_b)]);
temp = vals_x * cell_cosines_f;
ux_x_f = sum(temp[~scipy.isnan(temp)]);
temp = vals_x * cell_cosines_b;
ux_x_b = sum(temp[~scipy.isnan(temp)]);
temp = vals_x * cell_sines_f;
ux_y_f = sum(temp[~scipy.isnan(temp)]);
temp = vals_x * cell_sines_b;
ux_y_b = sum(temp[~scipy.isnan(temp)]);
temp = vals_y * cell_cosines_f;
uy_x_f = sum(temp[~scipy.isnan(temp)]);
temp = vals_y * cell_cosines_b;
uy_x_b = sum(temp[~scipy.isnan(temp)]);
temp = vals_y * cell_sines_f;
uy_y_f = sum(temp[~scipy.isnan(temp)]);
temp = vals_y * cell_sines_b;
uy_y_b = sum(temp[~scipy.isnan(temp)]);
ux_x = scipy.array([ux_x_b, val_mat[1,1], ux_x_f]);
ux_y = scipy.array([ux_y_b, val_mat[1,1], ux_y_f]);
uy_x = scipy.array([uy_x_b, 0, uy_x_f]);
uy_y = scipy.array([uy_y_b, 0, uy_y_f]);
xs = scipy.array([-1 * int(inc), 0, int(inc)]);
A = scipy.vstack([xs, scipy.ones(len(xs))]).T;
dux_dx, intercept = scipy.linalg.lstsq(A, ux_x)[0];
dux_dy, intercept = scipy.linalg.lstsq(A, ux_y)[0];
duy_dx, intercept = scipy.linalg.lstsq(A, uy_x)[0];
duy_dy, intercept = scipy.linalg.lstsq(A, uy_y)[0];
return dux_dx, dux_dy, duy_dx, duy_dy;
def getThicknesses(val_mat, direction_mat, out_flux, inc):
import scipy;
import math;
cell_angles = scipy.array([[3 * math.pi / 4, math.pi / 2, math.pi / 4], [math.pi, scipy.nan, 0], [-3 * math.pi / 4, -1 * math.pi / 2, -1 * math.pi / 4]]);
cell_incs = scipy.array([[(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5], [inc, scipy.nan, inc], [(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5]]);
vels_in = scipy.cos((cell_angles - math.pi) - direction_mat);
vels_in[1,1] = scipy.nan;
vels_in[vels_in < 0.00001] = scipy.nan;
vels_in = vels_in * val_mat;
in_fluxes = (vels_in ** 2 / sum(vels_in[~scipy.isnan(vels_in)]**2) * out_flux);
cosines = scipy.cos((cell_angles - math.pi) - direction_mat);
cosines[1,1] = scipy.nan;
cosines[cosines < 0.00001] = scipy.nan;
thicknesses = in_fluxes / (cosines * val_mat);
return thicknesses;
# import scipy;
# cell_angles = scipy.array([[3 * math.pi / 4, math.pi / 2, math.pi / 4], [math.pi, scipy.nan, 0], [-3 * math.pi / 4, -1 * math.pi / 2, -1 * math.pi / 4]]);
# cell_incs = scipy.array([[(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5], [inc, scipy.nan, inc], [(inc**2 + inc**2)**0.5, inc, (inc**2 + inc**2)**0.5]]);
# angle = direction_mat[0,0];
# cell_cosines = scipy.cos(angle - cell_angles);
# cell_sines = scipy.sin(angle - cell_angles);
# vals_x = scipy.cos(angle - direction_mat);
# vals_y = scipy.sin(angle - direction_mat);
# vals_x_f = vals_x;
# vals_x_f[vals_x < 0.00001] = scipy.nan;
# vals_x_f = vals_x_f * val_mat;
# vals_x_b = vals_x;
# vals_x_b[vals_x > -0.00001] = scipy.nan;
# vals_x_b = vals_x_b * val_mat;
# vals_y_f = vals_y;
# vals_y_f[vals_y < 0.00001] = scipy.nan;
# vals_y_f = vals_y_f * val_mat;
# vals_y_b = vals_y;
# vals_y_b[vals_y > -0.00001] = scipy.nan;
# vals_y_b = vals_y_b * val_mat;
# cell_cosines_f = cell_cosines;
# cell_cosines_f[cell_cosines < 0.00001] = scipy.nan;
# cell_cosines_f = cell_cosines_f**2;
# cell_cosines_f = cell_cosines_f / sum(cell_cosines_f[~scipy.isnan(cell_cosines_f)]);
# cell_cosines_b = cell_cosines;
# cell_cosines_b[cell_cosines > -0.00001] = scipy.nan;
# cell_cosines_b = cell_cosines_b**2;
# cell_cosines_b = cell_cosines_b / sum(cell_cosines_b[~scipy.isnan(cell_cosines_b)]);
# cell_sines_f = cell_sines;
# cell_sines_f[cell_sines < 0.00001] = scipy.nan;
# cell_sines_f = cell_sines_f**2;
# cell_sines_f = cell_sines_f / sum(cell_sines_f[~scipy.isnan(cell_sines_f)]);
# cell_sines_b = cell_sines;
# cell_sines_b[cell_sines > -0.00001] = scipy.nan;
# cell_sines_b = cell_sines_b**2;
# cell_sines_b = cell_sines_b / sum(cell_sines_b[~scipy.isnan(cell_sines_b)]);
# temp = vals_x * cell_cosines_f;
# ux_x_f = sum(temp[~scipy.isnan(temp)]);
# temp = vals_x * cell_cosines_b;
# ux_x_b = sum(temp[~scipy.isnan(temp)]);
# temp = vals_x * cell_sines_f;
# ux_y_f = sum(temp[~scipy.isnan(temp)]);
# temp = vals_x * cell_sines_b;
# ux_y_b = sum(temp[~scipy.isnan(temp)]);
# temp = vals_y * cell_cosines_f;
# uy_x_f = sum(temp[~scipy.isnan(temp)]);
# temp = vals_y * cell_cosines_b;
# uy_x_b = sum(temp[~scipy.isnan(temp)]);
# temp = vals_y * cell_sines_f;
# uy_y_f = sum(temp[~scipy.isnan(temp)]);
# temp = vals_y * cell_sines_b;
# uy_y_b = sum(temp[~scipy.isnan(temp)]);
# ux_x = scipy.array([ux_x_b, val_mat[1,1], ux_x_f]);
# ux_y = scipy.array([ux_y_b, val_mat[1,1], ux_y_f]);
# uy_x = scipy.array([uy_x_b, 0, uy_x_f]);
# uy_y = scipy.array([uy_y_b, 0, uy_y_f]);
# xs = scipy.array([-1 * int(inc), 0, int(inc)]);
# A = scipy.vstack([xs, scipy.ones(len(xs))]).T;
# dux_dx, intercept = scipy.linalg.lstsq(A, ux_x)[0];
# dux_dy, intercept = scipy.linalg.lstsq(A, ux_y)[0];
# duy_dx, intercept = scipy.linalg.lstsq(A, uy_x)[0];
# duy_dy, intercept = scipy.linalg.lstsq(A, uy_y)[0];
# return dux_dx, dux_dy, duy_dx, duy_dy;
def bedTopo(east_grd_path, slope_grd_path, thickness_txt_path):
import math;
import matplotlib;
import matplotlib.pyplot;
import os;
import scipy;
from scipy.io import netcdf;
from scipy.sparse import lil_matrix;
import subprocess;
assert os.path.exists(east_grd_path), "\n***** ERROR: " + east_grd_path + " does not exist\n";
assert os.path.exists(slope_grd_path), "\n***** ERROR: " + slope_grd_path + " does not exist\n";
assert os.path.exists(thickness_txt_path), "\n***** ERROR: " + thickness_txt_path + " does not exist\n";
north_grd_path = east_grd_path.replace("east", "north");
angles_grd_path = east_grd_path.replace("eastxyz", "angles");
mag_grd_path = east_grd_path.replace("eastxyz", "mag");
if not os.path.exists(angles_grd_path):
cmd = "\ngrdmath " + north_grd_path + " " + east_grd_path + " ATAN2 --IO_NC4_CHUNK_SIZE=c = " + angles_grd_path + "\n";
subprocess.call(cmd, shell=True);
cmd = "\ngrdclip " + angles_grd_path + " -Sa0.7853981633974483/NaN -Sb0/NaN -Gone.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa1.5707963267948966/NaN -Sb0.7853981633974483/NaN -Gtwo.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa2.356194490192345/NaN -Sb1.5707963267948966/NaN -Gthree.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa3.141592653589793/NaN -Sb2.356194490192345/NaN -Gfour.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa-2.356194490192345/NaN -Gfive.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa-1.5707963267948966/NaN -Sb-2.356194490192345/NaN -Gsix.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa-0.7853981633974483/NaN -Sb-1.5707963267948966/NaN -Gseven.grd\n";
cmd += "\ngrdclip " + angles_grd_path + " -Sa0/NaN -Sb-0.7853981633974483/NaN -Geight.grd\n";
cmd += "\ngrdmath one.grd two.grd AND = u.grd\n";
cmd += "\ngrdmath three.grd u.grd AND = u.grd\n";
cmd += "\ngrdmath four.grd u.grd AND = u.grd\n";
cmd += "\ngrdmath five.grd six.grd AND = d.grd\n";
cmd += "\ngrdmath seven.grd d.grd AND = d.grd\n";
cmd += "\ngrdmath eight.grd d.grd AND = d.grd\n";
cmd += "\ngrdmath three.grd four.grd AND = l.grd\n";
cmd += "\ngrdmath five.grd l.grd AND = l.grd\n";
cmd += "\ngrdmath six.grd l.grd AND = l.grd\n";
cmd += "\ngrdmath one.grd two.grd AND = r.grd\n";
cmd += "\ngrdmath eight.grd r.grd AND = r.grd\n";
cmd += "\ngrdmath seven.grd r.grd AND = r.grd\n";
cmd += "\ngrdmath two.grd three.grd AND = ul.grd\n";
cmd += "\ngrdmath four.grd ul.grd AND = ul.grd\n";
cmd += "\ngrdmath five.grd ul.grd AND = ul.grd\n";
cmd += "\ngrdmath one.grd two.grd AND = ur.grd\n";
cmd += "\ngrdmath three.grd ur.grd AND = ur.grd\n";
cmd += "\ngrdmath eight.grd ur.grd AND = ur.grd\n";
cmd += "\ngrdmath four.grd five.grd AND = dl.grd\n";
cmd += "\ngrdmath six.grd dl.grd AND = dl.grd\n";
cmd += "\ngrdmath seven.grd dl.grd AND = dl.grd\n";
cmd += "\ngrdmath one.grd six.grd AND = dr.grd\n";
cmd += "\ngrdmath seven.grd dr.grd AND = dr.grd\n";
cmd += "\ngrdmath eight.grd dr.grd AND = dr.grd\n";
cmd += "\ngrdmath 1.5707963267948966 u.grd SUB = u.grd\n";
cmd += "\ngrdmath u.grd ABS = u.grd\n";
cmd += "\ngrdmath u.grd COS = u.grd\n";
cmd += "\ngrdmath u.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = u.grd";
cmd += "\ngrdmath -1.5707963267948966 d.grd SUB = d.grd\n";
cmd += "\ngrdmath d.grd ABS = d.grd\n";
cmd += "\ngrdmath d.grd COS = d.grd\n";
cmd += "\ngrdmath d.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = d.grd";
cmd += "\ngrdmath 3.141592653589793 l.grd SUB = l.grd\n";
cmd += "\ngrdmath l.grd ABS = l.grd\n";
cmd += "\ngrdmath l.grd COS = l.grd\n";
cmd += "\ngrdmath l.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = l.grd";
cmd += "\ngrdmath 0 r.grd SUB = r.grd\n";
cmd += "\ngrdmath r.grd ABS = r.grd\n";
cmd += "\ngrdmath r.grd COS = r.grd\n";
cmd += "\ngrdmath r.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = r.grd";
cmd += "\ngrdmath 2.356194490192345 ul.grd SUB = ul.grd\n";
cmd += "\ngrdmath ul.grd ABS = ul.grd\n";
cmd += "\ngrdmath ul.grd COS = ul.grd\n";
cmd += "\ngrdmath ul.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = ul.grd";
cmd += "\ngrdmath 0.7853981633974483 ur.grd SUB = ur.grd\n";
cmd += "\ngrdmath ur.grd ABS = ur.grd\n";
cmd += "\ngrdmath ur.grd COS = ur.grd\n";
cmd += "\ngrdmath ur.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = ur.grd";
cmd += "\ngrdmath -2.356194490192345 dl.grd SUB = dl.grd\n";
cmd += "\ngrdmath dl.grd ABS = dl.grd\n";
cmd += "\ngrdmath dl.grd COS = dl.grd\n";
cmd += "\ngrdmath dl.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = dl.grd";
cmd += "\ngrdmath -0.7853981633974483 dr.grd SUB = dr.grd\n";
cmd += "\ngrdmath dr.grd ABS = dr.grd\n";
cmd += "\ngrdmath dr.grd COS = dr.grd\n";
cmd += "\ngrdmath dr.grd " + mag_grd_path + " MUL --IO_NC4_CHUNK_SIZE=c = dr.grd";
subprocess.call(cmd, shell=True);
f = netcdf.netcdf_file("u.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
u = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("d.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
d = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("l.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
l = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("r.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
r = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("ul.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
ul = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("ur.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
ur = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("dl.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
dl = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file("dr.grd","r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
dr = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file(mag_grd_path,"r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
speeds = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file(slope_grd_path,"r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
slopes = f.variables["z"].data[:];
f.close();
f = netcdf.netcdf_file(angles_grd_path,"r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
angles = f.variables["z"].data[:];
f.close();
width = f.dimensions["x"];
length = f.dimensions["y"];
min_x = min(x);
max_x = max(x);
min_y = min(y);
max_y = max(y);
inc = int((max(x) - min(x)) / (width - 1));
# Read in ice-only pixels
# f = netcdf.netcdf_file("ice_only.grd","r",False);
f = netcdf.netcdf_file(east_grd_path,"r",False);
x = f.variables["x"].data;
y = f.variables["y"].data;
ice_vals = f.variables["z"].data[:];
f.close();
# Read in thicknesses, initialize fluxes
thicknesses = {};
f_lons = {};
f_lats = {};
dr_stresses = {};
basal_drags = {};
fluxes = scipy.zeros((length, width));
locked = scipy.zeros((length, width));
infile = open(thickness_txt_path, "r");
for line in infile:
utm_x, utm_y, thickness = line.strip().split();
# j = str(int(math.floor((float(utm_x) - float(min_x)) / int(inc))));
# i = str(int(math.floor((float(utm_y) - float(min_y)) / int(inc))));
j = str(int(round((float(utm_x) - float(min_x)) / int(inc))));
i = str(int(round((float(utm_y) - float(min_y)) / int(inc))));
thicknesses[i + " " + j] = float(thickness);
fluxes[int(i), int(j)] = speeds[int(i), int(j)] * float(thickness);
locked[int(i), int(j)] = 1;
# print(str(int(j) * int(inc) + float(min_x)) + " " + str(int(i) * int(inc) + float(min_y)) + " " + thickness);
infile.close();
# Iteratively calculate fluxes, thicknesses
max_iterations = 50;
cur_iteration = 0;
cs1 = 0.0;
cs2 = 0.0;
todo = thicknesses.keys();
while cur_iteration < max_iterations:
tolock = {};
inputs = {};
outputs = {};
for coord in todo:
str_i, str_j = coord.split();
y_i = int(str_i);
x_i = int(str_j);
cs1 += fluxes[y_i,x_i];
in_total = 0.0;
out_total = 0.0
cs3 = 0.0;
factor = 4;
# Calculate input fluxes
if locked[y_i-1,x_i] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i]) and not scipy.isnan(u[y_i-1,x_i]):
in_total += u[y_i-1,x_i]**factor;
if locked[y_i+1,x_i] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i]) and not scipy.isnan(d[y_i+1,x_i]):
in_total += d[y_i+1,x_i]**factor;
if locked[y_i,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i,x_i+1]) and not scipy.isnan(l[y_i,x_i+1]):
in_total += l[y_i,x_i+1]**factor;
if locked[y_i,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i,x_i-1]) and not scipy.isnan(r[y_i,x_i-1]):
in_total += r[y_i,x_i-1]**factor;
if locked[y_i-1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i+1]) and not scipy.isnan(ul[y_i-1,x_i+1]):
in_total += ul[y_i-1,x_i+1]**factor;
if locked[y_i-1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i-1]) and not scipy.isnan(ur[y_i-1,x_i-1]):
in_total += ur[y_i-1,x_i-1]**factor;
if locked[y_i+1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i+1]) and not scipy.isnan(dl[y_i+1,x_i+1]):
in_total += dl[y_i+1,x_i+1]**factor;
if locked[y_i+1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i-1]) and not scipy.isnan(dr[y_i+1,x_i-1]):
in_total += dr[y_i+1,x_i-1]**factor;
if locked[y_i-1,x_i] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i]) and not scipy.isnan(u[y_i-1,x_i]):
fluxes[y_i-1,x_i] += fluxes[y_i,x_i] * (u[y_i-1,x_i]**factor / in_total);
tolock[str(y_i-1) + " " + str(x_i)] = True;
inputs[str(y_i-1) + " " + str(x_i)] = True;
cs3 += (u[y_i-1,x_i]**factor / in_total);
if locked[y_i+1,x_i] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i]) and not scipy.isnan(d[y_i+1,x_i]):
fluxes[y_i+1,x_i] += fluxes[y_i,x_i] * (d[y_i+1,x_i]**factor / in_total);
tolock[str(y_i+1) + " " + str(x_i)] = True;
inputs[str(y_i+1) + " " + str(x_i)] = True;
cs3 += (d[y_i+1,x_i]**factor / in_total);
if locked[y_i,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i,x_i+1]) and not scipy.isnan(l[y_i,x_i+1]):
fluxes[y_i,x_i+1] += fluxes[y_i,x_i] * (l[y_i,x_i+1]**factor / in_total);
tolock[str(y_i) + " " + str(x_i+1)] = True;
inputs[str(y_i) + " " + str(x_i+1)] = True;
cs3 += (l[y_i,x_i+1]**factor / in_total);
if locked[y_i,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i,x_i-1]) and not scipy.isnan(r[y_i,x_i-1]):
fluxes[y_i,x_i-1] += fluxes[y_i,x_i] * (r[y_i,x_i-1]**factor / in_total);
tolock[str(y_i) + " " + str(x_i-1)] = True;
inputs[str(y_i) + " " + str(x_i-1)] = True;
cs3 += (r[y_i,x_i-1]**factor / in_total);
if locked[y_i-1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i+1]) and not scipy.isnan(ul[y_i-1,x_i+1]):
fluxes[y_i-1,x_i+1] += fluxes[y_i,x_i] * (ul[y_i-1,x_i+1]**factor / in_total);
tolock[str(y_i-1) + " " + str(x_i+1)] = True;
inputs[str(y_i-1) + " " + str(x_i+1)] = True;
cs3 += (ul[y_i-1,x_i+1]**factor / in_total);
if locked[y_i-1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i-1]) and not scipy.isnan(ur[y_i-1,x_i-1]):
fluxes[y_i-1,x_i-1] += fluxes[y_i,x_i] * (ur[y_i-1,x_i-1]**factor / in_total);
tolock[str(y_i-1) + " " + str(x_i-1)] = True;
inputs[str(y_i-1) + " " + str(x_i-1)] = True;
cs3 += (ur[y_i-1,x_i-1]**factor / in_total);
if locked[y_i+1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i+1]) and not scipy.isnan(dl[y_i+1,x_i+1]):
fluxes[y_i+1,x_i+1] += fluxes[y_i,x_i] * (dl[y_i+1,x_i+1]**factor / in_total);
tolock[str(y_i+1) + " " + str(x_i+1)] = True;
inputs[str(y_i+1) + " " + str(x_i+1)] = True;
cs3 += (dl[y_i+1,x_i+1]**factor / in_total);
if locked[y_i+1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i-1]) and not scipy.isnan(dr[y_i+1,x_i-1]):
fluxes[y_i+1,x_i-1] += fluxes[y_i,x_i] * (dr[y_i+1,x_i-1]**factor / in_total);
tolock[str(y_i+1) + " " + str(x_i-1)] = True;
inputs[str(y_i+1) + " " + str(x_i-1)] = True;
cs3 += (dr[y_i+1,x_i-1]**factor / in_total);
# Calculate output fluxes
"""
if locked[y_i-1,x_i] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i]) and not scipy.isnan(d[y_i,x_i]) and (str(y_i-1) + " " + str(x_i)) not in inputs:
out_total += d[y_i,x_i]**factor;
if locked[y_i+1,x_i] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i]) and not scipy.isnan(u[y_i,x_i]) and (str(y_i+1) + " " + str(x_i)) not in inputs:
out_total += u[y_i,x_i]**factor;
if locked[y_i,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i,x_i+1]) and not scipy.isnan(r[y_i,x_i]) and (str(y_i) + " " + str(x_i+1)) not in inputs:
out_total += r[y_i,x_i]**factor;
if locked[y_i,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i,x_i-1]) and not scipy.isnan(l[y_i,x_i]) and (str(y_i) + " " + str(x_i-1)) not in inputs:
out_total += l[y_i,x_i]**factor;
if locked[y_i-1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i+1]) and not scipy.isnan(dr[y_i,x_i]) and (str(y_i-1) + " " + str(x_i+1)) not in inputs:
out_total += dr[y_i,x_i]**factor;
if locked[y_i-1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i-1]) and not scipy.isnan(dl[y_i,x_i]) and (str(y_i-1) + " " + str(x_i-1)) not in inputs:
out_total += dl[y_i,x_i]**factor;
if locked[y_i+1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i+1]) and not scipy.isnan(ur[y_i,x_i]) and (str(y_i+1) + " " + str(x_i+1)) not in inputs:
out_total += ur[y_i,x_i]**factor;
if locked[y_i+1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i-1]) and not scipy.isnan(ul[y_i,x_i]) and (str(y_i+1) + " " + str(x_i-1)) not in inputs:
out_total += ul[y_i,x_i]**factor;
if locked[y_i-1,x_i] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i]) and not scipy.isnan(d[y_i,x_i]) and (str(y_i-1) + " " + str(x_i)) not in inputs:
fluxes[y_i-1,x_i] += fluxes[y_i,x_i] * (d[y_i,x_i]**factor / out_total);
tolock[str(y_i-1) + " " + str(x_i)] = True;
if locked[y_i+1,x_i] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i]) and not scipy.isnan(u[y_i,x_i]) and (str(y_i+1) + " " + str(x_i)) not in inputs:
fluxes[y_i+1,x_i] += fluxes[y_i,x_i] * (u[y_i,x_i]**factor / out_total);
tolock[str(y_i+1) + " " + str(x_i)] = True;
if locked[y_i,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i,x_i+1]) and not scipy.isnan(r[y_i,x_i]) and (str(y_i) + " " + str(x_i+1)) not in inputs:
fluxes[y_i,x_i+1] += fluxes[y_i,x_i] * (r[y_i,x_i]**factor / out_total);
tolock[str(y_i) + " " + str(x_i+1)] = True;
if locked[y_i,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i,x_i-1]) and not scipy.isnan(l[y_i,x_i]) and (str(y_i) + " " + str(x_i-1)) not in inputs:
fluxes[y_i,x_i-1] += fluxes[y_i,x_i] * (l[y_i,x_i]**factor / out_total);
tolock[str(y_i) + " " + str(x_i-1)] = True;
if locked[y_i-1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i+1]) and not scipy.isnan(dr[y_i,x_i]) and (str(y_i-1) + " " + str(x_i+1)) not in inputs:
fluxes[y_i-1,x_i+1] += fluxes[y_i,x_i] * (dr[y_i,x_i]**factor / out_total);
tolock[str(y_i-1) + " " + str(x_i+1)] = True;
if locked[y_i-1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i-1,x_i-1]) and not scipy.isnan(dl[y_i,x_i]) and (str(y_i-1) + " " + str(x_i-1)) not in inputs:
fluxes[y_i-1,x_i-1] += fluxes[y_i,x_i] * (dl[y_i,x_i]**factor / out_total);
tolock[str(y_i-1) + " " + str(x_i-1)] = True;
if locked[y_i+1,x_i+1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i+1]) and not scipy.isnan(ur[y_i,x_i]) and (str(y_i+1) + " " + str(x_i+1)) not in inputs:
fluxes[y_i+1,x_i+1] += fluxes[y_i,x_i] * (ur[y_i,x_i]**factor / out_total);
tolock[str(y_i+1) + " " + str(x_i+1)] = True;
if locked[y_i+1,x_i-1] < 1 and not scipy.isnan(ice_vals[y_i+1,x_i-1]) and not scipy.isnan(ul[y_i,x_i]) and (str(y_i+1) + " " + str(x_i-1)) not in inputs:
fluxes[y_i+1,x_i-1] += fluxes[y_i,x_i] * (ul[y_i,x_i]**factor / out_total);
tolock[str(y_i+1) + " " + str(x_i-1)] = True;
"""
# print(x[x_i],y[y_i]);
# print(x[x_i-1],y[y_i]);
# print(x[x_i+1],y[y_i]);
# print(x[x_i],y[y_i-1]);
# print(x[x_i],y[y_i+1]);
# print(x[x_i+1],y[y_i+1]);
# print(x[x_i+1],y[y_i-1]);
# print(x[x_i-1],y[y_i+1]);
# print(x[x_i-1],y[y_i-1]);
# return;
for coord in tolock:
str_i, str_j = coord.split();
i = int(str_i);
j = int(str_j);
cs2 += fluxes[i,j];
thicknesses[coord] = fluxes[i,j] / speeds[i,j];
locked[i,j] = 1;
todo = tolock.keys();
# print(cs1, cs2, cs3);
cur_iteration += 1;
for coord in thicknesses:
i, j = coord.split();
angle = angles[i,j];
sub_speeds = speeds[i-1:i+2,j-1:j+2];
sub_angles = angles[i-1:i+2,j-1:j+2];
indices_x = [1, 2, 2, 2, 1, 0, 0, 0];
indices_y = [0, 2, 0, 1, 2, 0, 2, 1];
if angle >= math.pi / 4 and angle < math.pi / 2:
indices_x = [2, 2, 2, 1, 0, 0, 0, 1];
indices_y = [1, 2, 0, 2, 1, 0, 2, 0];
elif angle >= math.pi / 2 and angle < 3 * math.pi / 4:
indices_x = [2, 1, 2, 0, 0, 1, 0, 2];
indices_y = [1, 2, 2, 2, 1, 0, 0, 0];
elif angle >= 3 * math.pi / 4 and angle <= math.pi:
indices_x = [2, 0, 1, 0, 0, 2, 1, 2];
indices_y = [2, 2, 2, 1, 0, 0, 0, 1];
elif angle < 0 and angle >= -1 * math.pi / 4:
indices_x = [1, 2, 0, 2, 1, 0, 2, 0];
indices_y = [0, 0, 0, 1, 2, 2, 2, 1];
elif angle < -1 * math.pi / 4 and angle >= -1 * math.pi / 2:
indices_x = [0, 2, 0, 1, 2, 0, 2, 1];
indices_y = [0, 0, 1, 0, 2, 2, 1, 2];
elif angle < -1 * math.pi / 2 and angle >= -3 * math.pi / 4:
indices_x = [0, 1, 0, 0, 2, 1, 2, 2];
indices_y = [1, 0, 2, 0, 1, 2, 0, 2];
elif angle < -3 * math.pi / 4 and angle >= -1 * math.pi:
indices_x = [0, 0, 1, 0, 2, 2, 1, 2];
indices_y = [2, 0, 2, 1, 0, 1, 0, 2];
dux_dx = dirDeriv(sub_speeds, sub_angles, indices_x, inc);
dux_dy = dirDeriv(sub_speeds, sub_angles, indices_y, inc);
duy_dx = dirDeriv(sub_speeds, sub_angles, indices_x, inc);
duy_dy = dirDeriv(sub_speeds, sub_angles, indices_y, inc);
out_str = str(x[int(j)]) + " " + str(y[int(i)]) + " " + str(thicknesses[coord]) + " " + str(fluxes[i,j]);
if coord in inputs:
out_str += " input";
elif coord in outputs:
out_str += " output";
print(out_str);
os.remove("one.grd");
os.remove("two.grd");
os.remove("three.grd");
os.remove("four.grd");
os.remove("five.grd");
os.remove("six.grd");
os.remove("seven.grd");
os.remove("eight.grd");
os.remove("u.grd");
os.remove("d.grd");
os.remove("l.grd");
os.remove("r.grd");
os.remove("ul.grd");
os.remove("ur.grd");
os.remove("dl.grd");
os.remove("dr.grd");
return;
if __name__ == "__main__":
import os;
import sys;
assert len(sys.argv) > 3, "\n***** ERROR: bedTopo.py requires three arguments, " + str(len(sys.argv)) + " given\n";
assert os.path.exists(sys.argv[1]), "\n***** ERROR: " + sys.argv[1] + " does not exist\n";
assert os.path.exists(sys.argv[2]), "\n***** ERROR: " + sys.argv[2] + " does not exist\n";
assert os.path.exists(sys.argv[3]), "\n***** ERROR: " + sys.argv[3] + " does not exist\n";
bedTopo(sys.argv[1], sys.argv[2], sys.argv[3]);
exit();
| python |
Recently re-elected Emmanuel Macron, who needs to show he has heard the frustrations of voters expressed by low turnout and big support for the far right and far left, has been looking for a premier with green and social policy credentials.
Paris: French President Emmanuel Macron picked Labour Minister Elisabeth Borne as his new prime minister on Monday as he prepares for legislative elections in June - only the second time in 30 years that a woman has got the job.
"I want to dedicate my nomination to all little girls and tell them to go all the way pursuing your dreams", Borne said in her inauguration speech.
Recently re-elected Macron, who needs to show he has heard the frustrations of voters expressed by low turnout and big support for the far right and far left, has been looking for a premier with green and social policy credentials.
Such a profile could help counter the challenge mounted by hard-left veteran Jean-Luc Melenchon who achieved a strong third place in the presidential election, giving him the opportunity to rally a broad coalition of left-leaning parties in the June 12-19 parliamentary vote.
In a brief inaugural address, Borne said that the country needed to act "faster and stronger" to fight climate change and pledged to further work to protect the French's purchasing power, the No. 1 voter concern according to polls.
Borne, 61, will be the first woman named as prime minister since Edith Cresson briefly occupied the office during the presidency of Socialist leader Francois Mitterrand in the early 1990s.
"It was really time there was another woman (in that position) and I know Mrs Borne is a remarkable person with a lot of experience. . . I think it is a very good choice," Cresson told BFM television.
Outgoing Prime Minister Jean Castex, during a transition of power ceremony in the court of the Hotel De Matignon, used the female form of Borne's title in a sign of shifting linguistic customs similar to the German "Frau Bundeskanzlerin".
"Madame la Premiere Ministre", he said with a broad smile, adding:
"The role (of Prime Minister) is not exempted from public exposure and criticism, dear Elisabeth, people even say that's what it had been created for", said Castex with a twink to what French call the "job from hell" - hard work in the shadow of an omnipresent president.
Earlier in the day, Castex handed in his resignation, paving the way for a Cabinet overhaul after Macron's re-election in April.
A soft-spoken career bureaucrat who served numerous Socialist Party ministers before joining Macron's government, Borne had a brief stint as environment minister in 2019 when she pushed through bicycle-friendly policies.
She then took charge of the Labour Ministry and oversaw negotiations with unions that resulted in a cut to unemployment benefits for some job seekers.
On her watch, unemployment fell to its lowest level in 15 years and youth unemployment to its lowest level in 40 years.
Borne's deep inside knowledge of the workings of the state will help Macron push through more difficult reforms. She will be tasked with staring down France's muscular unions to oversee his most contested election pledge: raising the retirement age.
"Mrs Borne is against raising minimum wages and for retiring at 65. Here we go for a new season of social mistreatment," Melenchon said on Twitter.
A discreet technocrat who has never run for public office, Borne burnished her credentials as a steely negotiator against the trade unions during Macron's first term.
As transport minister in 2017, she held out against weeks of strikes and demonstrations to end a generous pension and benefits system for SNCF railway workers.
"She is a real workaholic, someone who can push on until 3 in the morning and be back again at 7 a. m. ," a former Borne staffer said. | english |
<reponame>nchow18/acentury
{% if __SELF__.menuItems %}
<ul class="vertical medium-horizontal menu expanded" data-responsive-menu="accordion medium-dropdown">
{% partial __SELF__ ~ "::items" items=__SELF__.menuItems %}
</ul>
{% endif %} | html |
<reponame>lazynerd-studios/Fitcelerator-RN<filename>.expo/web/cache/development/babel-loader/4cf92bd0e62e917401b97c2ae3043b8c.json
{"ast":null,"code":"import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nvar TRANSFORM_STYLE_PROPERTIES = ['perspective', 'rotate', 'rotateX', 'rotateY', 'rotateZ', 'scale', 'scaleX', 'scaleY', 'skewX', 'skewY', 'translateX', 'translateY'];\nexport default function wrapStyleTransforms(style) {\n var wrapped = {};\n Object.keys(style).forEach(function (key) {\n if (TRANSFORM_STYLE_PROPERTIES.indexOf(key) !== -1) {\n if (!wrapped.transform) {\n wrapped.transform = [];\n }\n\n wrapped.transform.push(_defineProperty({}, key, style[key]));\n } else {\n wrapped[key] = style[key];\n }\n });\n return wrapped;\n}","map":{"version":3,"sources":["C:/Users/LAZYNERD/Desktop/githubwork/Fitcelerator-RN/node_modules/react-native-animatable/wrapStyleTransforms.js"],"names":["TRANSFORM_STYLE_PROPERTIES","wrapStyleTransforms","style","wrapped","Object","keys","forEach","key","indexOf","transform","push"],"mappings":";AACA,IAAMA,0BAA0B,GAAG,CACjC,aADiC,EAEjC,QAFiC,EAGjC,SAHiC,EAIjC,SAJiC,EAKjC,SALiC,EAMjC,OANiC,EAOjC,QAPiC,EAQjC,QARiC,EASjC,OATiC,EAUjC,OAViC,EAWjC,YAXiC,EAYjC,YAZiC,CAAnC;AAgBA,eAAe,SAASC,mBAAT,CAA6BC,KAA7B,EAAoC;AACjD,MAAMC,OAAO,GAAG,EAAhB;AACAC,EAAAA,MAAM,CAACC,IAAP,CAAYH,KAAZ,EAAmBI,OAAnB,CAA2B,UAAAC,GAAG,EAAI;AAChC,QAAIP,0BAA0B,CAACQ,OAA3B,CAAmCD,GAAnC,MAA4C,CAAC,CAAjD,EAAoD;AAClD,UAAI,CAACJ,OAAO,CAACM,SAAb,EAAwB;AACtBN,QAAAA,OAAO,CAACM,SAAR,GAAoB,EAApB;AACD;;AACDN,MAAAA,OAAO,CAACM,SAAR,CAAkBC,IAAlB,qBACGH,GADH,EACSL,KAAK,CAACK,GAAD,CADd;AAGD,KAPD,MAOO;AACLJ,MAAAA,OAAO,CAACI,GAAD,CAAP,GAAeL,KAAK,CAACK,GAAD,CAApB;AACD;AACF,GAXD;AAYA,SAAOJ,OAAP;AACD","sourcesContent":["// These styles need to be nested in a transform array\nconst TRANSFORM_STYLE_PROPERTIES = [\n 'perspective',\n 'rotate',\n 'rotateX',\n 'rotateY',\n 'rotateZ',\n 'scale',\n 'scaleX',\n 'scaleY',\n 'skewX',\n 'skewY',\n 'translateX',\n 'translateY',\n];\n\n// Transforms { translateX: 1 } to { transform: [{ translateX: 1 }]}\nexport default function wrapStyleTransforms(style) {\n const wrapped = {};\n Object.keys(style).forEach(key => {\n if (TRANSFORM_STYLE_PROPERTIES.indexOf(key) !== -1) {\n if (!wrapped.transform) {\n wrapped.transform = [];\n }\n wrapped.transform.push({\n [key]: style[key],\n });\n } else {\n wrapped[key] = style[key];\n }\n });\n return wrapped;\n}\n"]},"metadata":{},"sourceType":"module"} | json |
<gh_stars>1-10
{
"name": "device-type",
"version": "1.0.0",
"description": "Identify a device based on HTTP headers - user-agent but also cloudfront's CloudFront-Is-*-Viewer-headers",
"main": "dist/index.js",
"scripts": {
"test": "babel-tape-runner test.js && semistandard | snazzy",
"build": "rm -rf dist && mkdir -p dist && babel lib --out-dir dist",
"watch": "rm -rf dist && mkdir -p dist && babel -w lib --out-dir dist",
"prepublish": "npm run build",
"posttest": "readme package.json > readme.md"
},
"repository": {
"type": "git",
"url": "git+https://github.com/micnews/device-type.git"
},
"author": "<EMAIL>",
"license": "MIT",
"bugs": {
"url": "https://github.com/micnews/device-type/issues"
},
"homepage": "https://github.com/micnews/device-type#readme",
"devDependencies": {
"babel-cli": "^6.10.1",
"babel-core": "^6.10.4",
"babel-preset-es2015": "^6.9.0",
"babel-tape-runner": "^2.0.1",
"object-assign": "^4.1.0",
"package-json-to-readme": "^1.5.1",
"semistandard": "^8.0.0",
"shot": "^3.1.0",
"snazzy": "^4.0.0",
"tapava": "^2.2.0"
},
"dependencies": {
"mobile-detect": "^1.3.2"
}
}
| json |
<gh_stars>1-10
// Copyright (C) 2019 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 applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#include <random>
#include <set>
#include <unordered_set>
#include <benchmark/benchmark.h>
#include "perfetto/base/flat_set.h"
namespace {
std::vector<int> GetRandData(int num_pids) {
std::vector<int> rnd_data;
std::minstd_rand0 rng(0);
static constexpr int kDistinctValues = 100;
for (int i = 0; i < num_pids; i++)
rnd_data.push_back(static_cast<int>(rng()) % kDistinctValues);
return rnd_data;
}
bool IsBenchmarkFunctionalOnly() {
return getenv("BENCHMARK_FUNCTIONAL_TEST_ONLY") != nullptr;
}
void BenchmarkArgs(benchmark::internal::Benchmark* b) {
if (IsBenchmarkFunctionalOnly()) {
b->Arg(64);
} else {
b->RangeMultiplier(2)->Range(64, 4096);
}
}
} // namespace
template <typename SetType>
static void BM_SetInsert(benchmark::State& state) {
std::vector<int> rnd_data = GetRandData(state.range(0));
for (auto _ : state) {
SetType iset;
for (const int val : rnd_data)
iset.insert(val);
benchmark::DoNotOptimize(iset);
benchmark::DoNotOptimize(iset.begin());
benchmark::ClobberMemory();
}
}
using perfetto::base::FlatSet;
BENCHMARK_TEMPLATE(BM_SetInsert, FlatSet<int>)->Apply(BenchmarkArgs);
BENCHMARK_TEMPLATE(BM_SetInsert, std::set<int>)->Apply(BenchmarkArgs);
BENCHMARK_TEMPLATE(BM_SetInsert, std::unordered_set<int>)->Apply(BenchmarkArgs);
| cpp |
package axcelerate
import (
"bytes"
"io/ioutil"
"net/http"
"reflect"
"testing"
"time"
"github.com/stretchr/testify/assert"
)
func TestCoursesService_GetCoursesInstanceDetail(t *testing.T) {
type fields struct {
StatusCode int
Body string
}
type args struct {
instanceID int
activityType string
}
tests := []struct {
name string
fields fields
args args
want InstanceDetail
want1 *Response
wantErr bool
}{
{
name: "Full Body",
fields: fields{
StatusCode: 200,
Body: LoadTestData("course_instance_detail.json"),
},
args: args{instanceID: 422662, activityType: "p"},
want: InstanceDetail{
Datedescriptor: "22/05/2014 - 22/05/2014",
Enrolmentopen: false,
ID: 4109,
Location: "VM Learning Offices",
Minparticipants: 0,
Name: "<NAME>",
Ownercontactid: 1100635,
Instanceid: 67569,
Finishdate: time.Date(2014, 05, 22, 0, 0, 0, 0, time.Local),
Startdate: time.Date(2014, 05, 22, 0, 0, 0, 0, time.Local),
},
want1: &Response{
StatusCode: 200,
Body: LoadTestData("course_instance_detail.json"),
ContentLength: 0,
},
},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
tclient := NewTestClient(func(req *http.Request) *http.Response {
return &http.Response{
StatusCode: tt.fields.StatusCode,
Body: ioutil.NopCloser(bytes.NewBufferString(tt.fields.Body)),
Header: make(http.Header),
}
})
s := &CoursesService{
client: NewClient("", "", nil, tclient),
}
got, got1, err := s.GetCoursesInstanceDetail(tt.args.instanceID, tt.args.activityType)
if err == nil {
assert.Equal(t, tt.fields.StatusCode, got1.StatusCode, "HTTPStatus did not match")
assert.Equal(t, tt.fields.Body, got1.Body, "Body did not match")
assert.Equal(t, tt.want, got, "Response")
}
if (err != nil) != tt.wantErr {
t.Errorf("CoursesService.GetCoursesInstanceDetail() error = %v, wantErr %v", err, tt.wantErr)
return
}
if !reflect.DeepEqual(got, tt.want) {
t.Errorf("CoursesService.GetCoursesInstanceDetail() got = %v, want %v", got, tt.want)
}
if !reflect.DeepEqual(got1, tt.want1) {
t.Errorf("CoursesService.GetCoursesInstanceDetail() got1 = %v, want %v", got1, tt.want1)
}
})
}
}
| go |
/*
* Copyright 2019 Qameta Software OÜ
*
* 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 writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package io.qameta.allure.tags;
import io.qameta.allure.Aggregator;
import io.qameta.allure.core.Configuration;
import io.qameta.allure.core.LaunchResults;
import io.qameta.allure.entity.LabelName;
import java.nio.file.Path;
import java.util.Collection;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
/**
* @author charlie (<NAME>).
*/
public class TagsPlugin implements Aggregator {
public static final String TAGS_BLOCK_NAME = "tags";
@Override
public void aggregate(final Configuration configuration,
final List<LaunchResults> launchesResults,
final Path outputDirectory) {
launchesResults.stream()
.map(LaunchResults::getAllResults)
.flatMap(Collection::stream)
.forEach(result -> {
final Set<String> tags = new HashSet<>(result.findAllLabels(LabelName.TAG));
result.addExtraBlock(TAGS_BLOCK_NAME, tags);
});
}
}
| java |
{
"names": {
"en": "<NAME>",
"fr": "Neuf pour Un",
"de": "<NAME>",
"it": "Potenziamento Eevolutivo",
"es": "Novena Potencia"
},
"index_number": 702,
"makes_contact": false,
"affected_by_protect": false,
"affected_by_magic_coat": false,
"affected_by_snatch": false,
"affected_by_mirror_move": false,
"affected_by_kings_rock": false,
"type": "Normal",
"category": "status",
"pp": 0,
"max_pp": 0,
"power": 0,
"accuracy": 0,
"target": "target_adjacent_single",
"critical_hit": 0,
"priority": 0,
"contests": [
],
"pokedex_entries": {
"Sun": {
"en": "After obtaining Z-Power, the user, Eevee, gets energy from its evolved friends and boosts its stats sharply.",
"de": "Evoli macht sich durch Z-Kraft die Stärke seiner Weiterentwicklungen zunutze und erhöht seine Statuswerte stark."
},
"Moon": {
"en": "After obtaining Z-Power, the user, Eevee, gets energy from its evolved friends and boosts its stats sharply.",
"de": "Evoli macht sich durch Z-Kraft die Stärke seiner Weiterentwicklungen zunutze und erhöht seine Statuswerte stark."
},
"Ultra Sun": {
"en": "After obtaining Z-Power, the user, Eevee, gets energy from its evolved friends and boosts its stats sharply.",
"de": "Evoli macht sich durch Z-Kraft die Stärke seiner Weiterentwicklungen zunutze und erhöht seine Statuswerte stark."
},
"Ultra Moon": {
"en": "After obtaining Z-Power, the user, Eevee, gets energy from its evolved friends and boosts its stats sharply.",
"de": "Evoli macht sich durch Z-Kraft die Stärke seiner Weiterentwicklungen zunutze und erhöht seine Statuswerte stark."
}
}
} | json |
<gh_stars>0
.button
{
display: inline-block;
vertical-align: top;
text-align: center;
border-radius: 50%;
width: 80px;
height: 80px;
margin: 0 4px;
outline: none;
}
.button-center
{
text-align: center;
} | css |
{"jqBootstrapValidation.js":"<KEY>,"jqBootstrapValidation.min.js":"<KEY>} | json |
/* TODO: Clean all of the up. */
:root {
font-size: 16px;
font-family: 'Open Sans';
color: white;
user-select: none;
-moz-user-select: none;
-khtml-user-select: none;
-webkit-user-select: none;
-o-user-select: none;
}
p {
user-select: auto;
-moz-user-select: auto;
-khtml-user-select: auto;
-webkit-user-select: auto;
-o-user-select: auto;
}
body {
background: linear-gradient(#161718 0%, #191c1f 26%, #14171a 51%, #171d22 76%);
}
body::-webkit-scrollbar {
width: 0.25rem;
}
body::-webkit-scrollbar-track {
background: #191c1f;
}
body::-webkit-scrollbar-thumb {
background: #0277bd;
}
i.fab {
text-shadow: 4px 4px 6px black;
}
i.material-icons {
text-shadow: 2px 2px 5px black;
}
.main-container-setup {
background: radial-gradient(#1f262e, transparent 65%);
}
.footer-setup {
background: transparent;
margin-top: 5%;
}
.spacer {
margin-top: 10rem;
}
.spacer-2 {
margin-top: 10rem;
padding-bottom: 10rem;
}
.hoverable {
cursor: pointer;
}
.fab-hover {
padding: 0 35px;
}
.fab-hover:hover {
color: #4fc3f7;
cursor: pointer;
}
.icon-block {
padding: 0 15px;
}
.icon-block .material-icons {
font-size: inherit;
}
| css |
In the end it was a comfortable victory for KKR, as Rana and DK’s calm partnership took the game out of RCB’s hand.
Sunil Narine’s brilliant 50 in 19 balls set the ball rolling for KKR, as the West Indian’s brilliant knock gave his side the perfect start.
A jam packed Eden Gardens was extremely hyped up for the KKR’s first match of IPL 2018 against the Virat Kohli’s RCB.
A new look KKR under the stewardship of Dinesh Karthik looked ready for the occasion, as DK looked to get the better of Virat Kohli in his first match as an IPL captain.
After the initial blitz from Brendon McCullum, AB and Kohli took over as they put on their 15th fifty run partnership for RCB. The South African champion in particular looked very dangerous, as AB was striking the ball sweetly and was primed for a big innings.
But everything changed in two deliveries, as Nitish Rana first got AB’s prize wicket for his captain. The next ball was even better, as Rana yorked Kohli, with the RCB skipper absolutely stunned to see his stumps disturbed by the bowler.
Rana was also at hand to play a fine hand with the bat, as he had a wonderful first match for KKR.
PLAYER RATINGS:
The South African was expected to fire with the bat tonight, but was unfortunately dismissed without troubling the scorers much.
Baz threatened to take the game away from KKR early on, but could not capitalize on the start and left after playing a decent hand.
Kohli tried to play a steady innings and started off slowly, but was dismissed by a beauty from Nitish Rana.
The brilliant South African looked in great touch, as he smashed a quick fire 44. Sadly for RCB though, he got out at just the wrong time for his team and could not take them past 200.
In spite of being retained by RCB, Sarfaraz could not make the most out of that opportunity and failed to make much of an impression.
Mandy played a fine hand at the death for RCB, as he was responsible to take his team past 176.
The Englishman was pretty decent with the ball tonight, as he picked up three wickets but unfortunately could not stem the flow of runs from the KKR batsmen.
Sundar was deeply dissapointing, as the off-spinner could not perform to the level that we have come to expect from him.
The youngster showed good pace and promise, and could become a wonderful addition to the RCB side this season.
RCB’s best bowler, Yadav showed the pace and passion that Kohli needed from all his bowlers. Expect the Indian pacer to have a very big IPL season.
A disappointing outing from RCB’s premier spinner, as Kohli will expect a lot more from the talented leg spinner.
| english |
<filename>src/controllers.js<gh_stars>1-10
import { connect, disconnect, attributeChangedMethods } from "./controller.js"
import * as AttributeObserver from "./attribute-observer.js"
const CONTROLLERS = Symbol("controllers")
const BASE = Symbol("base")
const BASE_CONTROLLERS = Object.setPrototypeOf({ [BASE]: true }, null)
export const attribute = "data-controllers"
export const selector = `[${attribute}]`
export const registry = Object.create(null)
export function register(descriptor, constructor) {
if (registry[descriptor]) {
console.error(`Descriptor "%s" is already registered to %o`, descriptor, registry[descriptor])
} else {
registry[descriptor] = constructor
}
}
export function get(element) {
return element[CONTROLLERS]
}
export function create(element) {
if (element[CONTROLLERS]) {
uproot(element)
} else {
update(element)
}
}
export function update(element) {
const config = element.getAttribute(attribute)
if (config === null) return destroy(element)
const controllers = (element[CONTROLLERS] ??= Object.create(null))
const descriptors = config.match(/\S+/g)
AttributeObserver.create(element, descriptors.flatMap(observableAttributes))
deleteInactive(controllers, descriptors)
for (const descriptor of descriptors) {
const constructor = registry[descriptor]
if (constructor && !Object.hasOwnProperty.call(controllers, descriptor)) {
controllers[descriptor] = new constructor(element, descriptor)
connect(controllers[descriptor])
}
}
}
export function destroy(element) {
const controllers = element[CONTROLLERS]
if (!controllers) return
AttributeObserver.destroy(element)
Object.values(controllers).forEach(disconnect)
delete element[CONTROLLERS]
}
export function uproot(element) {
if (element[CONTROLLERS]) Object.setPrototypeOf(element[CONTROLLERS], null)
}
export function resolve(element) {
let ancestor = element.closest(selector)
const controllers = ancestor?.[CONTROLLERS] ?? BASE_CONTROLLERS
while (!controllers[BASE]) {
const descendent = ancestor
ancestor = ancestor.parentElement.closest(selector)
Object.setPrototypeOf(descendent[CONTROLLERS], ancestor?.[CONTROLLERS] ?? BASE_CONTROLLERS)
}
return controllers
}
function observableAttributes(descriptor) {
const constructor = registry[descriptor]
return constructor ? Object.keys(attributeChangedMethods(constructor, descriptor)) : []
}
function deleteInactive(controllers, activeDescriptors) {
for (const descriptor of Object.keys(controllers)) {
if (!activeDescriptors.includes(descriptor)) {
disconnect(controllers[descriptor])
delete controllers[descriptor]
}
}
}
| javascript |
“A week back, my friend called me and said there will be Dhoni’s audio launch and asked me if I could come. He asked me if I could come. He didn’t know that I would even pay a crore rupees to attend to share this stage with him if I had to,” said S S Rajamouli with uber excitement as he spoke about the cricket prodigal Mahendra Singh Dhoni.
Indian cricket team captain M S Dhoni, along with Rajamouli, was here in Hyderabad on Saturday for the audio launch of his biopic M S Dhoni: The Untold Story.
The Baahubali director also said that the ace cricketer was his inspiration and expressed joy for standing beside Dhoni during the audio launch.
“I started watching cricket in mid 80s when we had great players like Gavaskar, Kapil Dev and Azharuddin. But the cricket was mixed with a sense of joy and fear too whether our team will win or not until this man came along. After Dhoni became the captain of India we started watching cricket without fear with utter joy,” he added.
Rajamouli, who is ready to watch the movie on its first screening, thanked the movie director Neeraj Pandey for telling the inside story of M S Dhoni.
While director brought out his fanboy memories of cricket, the captain himself confessed he had good times in the city telling how he loves the 3 B’s of Hyderabad.
“I love the Biryani, bangles and biscuits of Hyderabad. We also got a good support here as Indian cricket team and we have very good record in Hyderabad for our team. It’s a pleasure being here,” Dhoni said.
Sharing that he loved the blockbuster movie Baahubali and is also eagerly waiting for the release of its sequel, Dhoni said South Indian film industry has some great potential.
“In the south, there are a lot of good actors and movies. We can actually see a lot of Bollywood remakes of movies from the south. The people over here have got some nice stories. They act well, direct well and fans are fantastic here too which is very important to make movies that can be appreciated,” Dhoni added.
Talking about the movie, Dhoni said Sushant Singh Rajput is the best fit to act in the movie.
“Sushant looks exactly like me and he played close to nine months of cricket with a 2-hour practice every day. The difficult part was to enact the cricketing shots. I feel he is a very good actor so when it comes to doing all the stuff I do, I knew Sushant would achieve that. The only thing was he asked too many questions to know what goes around in my mind and to completely get into my shoes. That part was difficult too,” said Dhoni chuckling. | english |
The 3.3 firmware which paves the way for 3D gaming on the PlayStation 3 is being rolled out – although you won't be able to play anything as yet.
Sony has announced that its 3D firmware update which is being piped to its latest range of Blu-ray players and the PlayStation 3 will not make the PS3 compatible with upcoming 3D Blu-rays.
CVG.com has revealed what the 50 best PS3 games ever are, with Naughty Dog's Uncharted 2: Among Thieves nabbing the top spot.
Sony PS3 and PC users waiting with bated breath for GTA IV's expansion packs to hit the UK will have to wait that little bit longer after it was announced that they will no longer be out in March.
Microsoft has claimed that the lack of a Blu-ray player in the Xbox 360 has been the key to its sales success when compared with Sony's PlayStation 3.
Sony: Don't use your PS3 for 'next 24 hours'
Sony has urged customers who have an old-style PS3 not to use their console as the company tries to fix what it is calling a "bug in the clock functionality incorporated in the system".
Sony making smaller loss on every PS3?
Sony's plan to make the PS3 more popular seems to have worked, except it's still apparently making a loss on every console it sells.
Get the hottest deals available in your inbox plus news, reviews, opinion, analysis and more from the TechRadar team.
| english |
KL Rahul will lead Kings XI Punjab in a mouth-watering contest against Virat Kohli’s Royal Challengers Bangalore in Dubai later today. The two teams have a neck to neck record and some batting superstars amongst their ranks which could make this encounter a run feast.
The fact that a number of Karnataka players are a part of the squad and Anil Kumble is at the helm of affairs at Kings XI only adds spice to tonight’s encounter.
Let’s take a look at their head-to-head statistics to understand how the two fared against each other in the past.
Head-to-Head: (24 matches- KXIP:12 | RCB:12)
It is as tight as it gets! Both KXIP and RCB have won 12 matches against each other - an indicator of the close rivalry between them over the years.
Recent Head-to-Head: (Last 5 matches)
RCB have dominated the recent matches winning 4 of the last 5 encounters against KXIP.
Last encounter:
AB de Villiers’ unbeaten 82 off just 44 deliveries coupled with quickfire 40s from Parthiv Patel and Marcus Stoinis helped RCB post 202. KXIP had a splendid start to the chase crossing 100 within 10 overs but squandered a great platfrom given by KL Rahul, Chris Gayle and Mayank Agarwal and ultimately lost by 17 runs.
Last meeting in the UAE:
Sandeep Sharma starred with the ball picking 3 wickets restricting RCB to 124. KXIP chased down the target with 5 wickets in hand.
Kings XI Punjab: Shaun Marsh (266)
Royal Challengers Bangalore: Chris Gayle (774)
Kings XI Punjab: Adam Gilchrist (106)
Royal Challengers Bangalore: Chris Gayle (117)
Kings XI Punjab: Sandeep Sharma (16)
Royal Challengers Bangalore: Yuzvendra Chahal (19)
Kings XI Punjab: Piyush Chawla (4/17)
Royal Challengers Bangalore: Sreenath Aravind (4/14)
Highest Innings Total: | english |
<filename>powerbi-docs/guided-learning/includes/1-5-cleaning-irregular-data.md<gh_stars>0
---
ms.openlocfilehash: fa6296485897b983c3ca4044ffa2875de3326dec
ms.sourcegitcommit: 60dad5aa0d85db790553e537bf8ac34ee3289ba3
ms.translationtype: MT
ms.contentlocale: zh-CN
ms.lasthandoff: 05/29/2019
ms.locfileid: "61264362"
---
Power BI 可以从几乎任何来源导入数据,其可视化效果和建模工具最适用于列式数据。 有时数据不采用简单列格式,这种情况常出现在 Excel 电子表格中,适合肉眼查看的表格布局不一定是自动查询的最优选择。 例如,以下电子表格具有跨多个列的标题。

幸运的是,Power BI 中的工具能将多列表格快速转化为数据集供你使用。
## <a name="transpose-data"></a>转置数据
例如,使用**查询编辑器**中的**转置**,你可以对数据进行翻转(即将列变为行,将行变为列),从而将数据分解为可操作的格式。

进行数次转置后,如视频所述,表格将开始转换为 Power BI 更容易处理的格式。
## <a name="format-data"></a>设置数据格式
你可能还需要设置数据格式,以便 Power BI 在导入数据后对其进行适当分类和标识。
通过几种转换(包括 *将行提升为标题* 以分解标题、使用 **填充** 将 *null* 值变为给定列中上方或下方行内找到的值,以及 **逆透视列** ),即可将数据清理为可在 Power BI 中使用的数据集。

通过 Power BI,你可以在你的数据上对这些转换进行试验,确定可将数据转换为 Power BI 可处理的列格式的转换类型。 请记住,你采取的所有操作都记录在“查询编辑器”中的“应用的步骤”部分中,因此如果转换未达到预期,只需单击该步骤旁的 **x** 撤消操作即可。

## <a name="create-visuals"></a>创建视觉对象
数据 Power BI 可用格式后,即可通过转换和清理数据开始创建视觉对象。

## <a name="next-steps"></a>后续步骤
**祝贺你!** 你已经完成了本部分的 Power BI **引导学习**课程。 你现已了解如何 **将数据导入** Power BI Desktop,以及如何 *调整* 或 *转换* 这些数据,因此你可以创建具引人注目的视觉对象。
了解 Power BI 的工作原理以及如何使其 *为你* 服务的下一步,是了解 **建模** 包含的内容。 你已经了解,**数据集**是 Power BI 的基本构建块,但某些数据集可能比较复杂并基于众多不同的数据源。 有时,你需要为所创建数据集添加自己的特殊亮点(或 *字段* )。
在下一个部分中,你将了解如何**建模**以及更多内容。 不见不散!
| markdown |
<reponame>rutgerkok/Bedsock
package nl.rutgerkok.bedsock;
import static org.junit.jupiter.api.Assertions.assertFalse;
import static org.junit.jupiter.api.Assertions.assertTrue;
import org.junit.jupiter.api.Test;
import nl.rutgerkok.bedsock.event.Event;
import nl.rutgerkok.bedsock.event.EventHandler;
import nl.rutgerkok.bedsock.event.EventRegistry;
import nl.rutgerkok.bedsock.event.Listener;
import nl.rutgerkok.bedsock.impl.PrintlnLogger;
import nl.rutgerkok.bedsock.impl.event.EventRegistryImpl;
import nl.rutgerkok.bedsock.logger.Logger;
import nl.rutgerkok.bedsock.plugin.ActivePlugin;
import nl.rutgerkok.bedsock.plugin.Plugin;
import nl.rutgerkok.bedsock.plugin.PluginDescription;
class EventTest {
public static class MyEvent extends Event {
boolean successfull = false;
}
public static class MyListener extends Listener {
protected MyListener(ActivePlugin plugin) {
super(plugin);
}
@EventHandler
public void onTest(MyEvent event) {
event.successfull = true;
}
}
private static class MyPlugin implements ActivePlugin {
@Override
public Logger getLogger() {
return new PrintlnLogger();
}
@Override
public Plugin getPlugin() {
return new Plugin() {};
}
@Override
public PluginDescription getPluginDescription() {
return () -> "MyPlugin";
}
}
@Test
public void firing() {
EventRegistry registry = new EventRegistryImpl();
registry.registerHandler(new MyListener(new MyPlugin()));
MyEvent event = new MyEvent();
assertFalse(event.successfull);
registry.callEvent(event);
assertTrue(event.successfull);
}
}
| java |
<filename>data/comics/23674.json
{
"id": 23674,
"digitalId": 0,
"title": "Nova Vol. 3: Secret Invasion (Trade Paperback)",
"issueNumber": 0,
"variantDescription": "",
"description": "Nova has received an emergency call from a planet in peril — but how do you save a world being devoured by a force of nature? Is there any way to stop the big G from eating, or do you instead try to save as many refugees as possible? And do you reach out to your former ally — who is once again a feared Herald? Whatever Nova decides, nothing will prepare him — or you — for the horror known as Harrow! With all these awesome ingredients (Galactus! Silver Surfer! Nova! A new villain! A killer creative team!) Then, watch as Nova rockets into the alien invasion saga that’s tearing apart the Marvel Universe! But is our always-outnumbered space cop actually teaming with one of the enemy? When Super-Skrull comes asking for a favor, can you ever trust the warrior whose life was dedicated to destroying us? Collecting NOVA #13-18.\r<br>144 PGS./Rated T+ …$16.99\r<br>ISBN 978-0-7851-2662-1",
"modified": "-0001-11-30T00:00:00-0500",
"isbn": "978-0-7851-2662-1",
"upc": "5960612662-00111",
"diamondCode": "DEC082449",
"ean": "9780785 126621 51699",
"issn": "",
"format": "Trade Paperback",
"pageCount": 144,
"textObjects": [
{
"type": "issue_solicit_text",
"language": "en-us",
"text": "Nova has received an emergency call from a planet in peril — but how do you save a world being devoured by a force of nature? Is there any way to stop the big G from eating, or do you instead try to save as many refugees as possible? And do you reach out to your former ally — who is once again a feared Herald? Whatever Nova decides, nothing will prepare him — or you — for the horror known as Harrow! With all these awesome ingredients (Galactus! Silver Surfer! Nova! A new villain! A killer creative team!) Then, watch as Nova rockets into the alien invasion saga that’s tearing apart the Marvel Universe! But is our always-outnumbered space cop actually teaming with one of the enemy? When Super-Skrull comes asking for a favor, can you ever trust the warrior whose life was dedicated to destroying us? Collecting NOVA #13-18.\r<br>144 PGS./Rated T+ …$16.99\r<br>ISBN 978-0-7851-2662-1"
}
],
"resourceURI": "http://gateway.marvel.com/v1/public/comics/23674",
"urls": [
{
"type": "detail",
"url": "http://marvel.com/comics/collection/23674/nova_vol_3_secret_invasion_trade_paperback?utm_campaign=apiRef&utm_source=35410e46c72ea769348ceb6ba8cc90fd"
},
{
"type": "purchase",
"url": "http://comicstore.marvel.com/Nova-Vol-3-Secret-Invasion-0/digital-comic/27769?utm_campaign=apiRef&utm_source=35410e46c72ea769348ceb6ba8cc90fd"
}
],
"series": {
"resourceURI": "http://gateway.marvel.com/v1/public/series/6826",
"name": "Nova Vol. 3: Secret Invasion (2009 - Present)"
},
"variants": [],
"collections": [],
"collectedIssues": [],
"dates": [
{
"type": "onsaleDate",
"date": "2009-02-11T00:00:00-0500"
},
{
"type": "focDate",
"date": "2009-01-08T00:00:00-0500"
}
],
"prices": [
{
"type": "printPrice",
"price": 16.99
}
],
"thumbnail": {
"path": "http://i.annihil.us/u/prod/marvel/i/mg/e/40/4bb5d21d2ad0d",
"extension": "jpg"
},
"images": [
{
"path": "http://i.annihil.us/u/prod/marvel/i/mg/e/40/4bb5d21d2ad0d",
"extension": "jpg"
}
],
"creators": {
"available": 0,
"collectionURI": "http://gateway.marvel.com/v1/public/comics/23674/creators",
"items": [],
"returned": 0
},
"characters": {
"available": 0,
"collectionURI": "http://gateway.marvel.com/v1/public/comics/23674/characters",
"items": [],
"returned": 0
},
"stories": {
"available": 2,
"collectionURI": "http://gateway.marvel.com/v1/public/comics/23674/stories",
"items": [
{
"resourceURI": "http://gateway.marvel.com/v1/public/stories/52429",
"name": "Nova 13-18",
"type": "cover"
},
{
"resourceURI": "http://gateway.marvel.com/v1/public/stories/52430",
"name": "Nova 13-18",
"type": "interiorStory"
}
],
"returned": 2
},
"events": {
"available": 1,
"collectionURI": "http://gateway.marvel.com/v1/public/comics/23674/events",
"items": [
{
"resourceURI": "http://gateway.marvel.com/v1/public/events/269",
"name": "Secret Invasion"
}
],
"returned": 1
}
} | json |
As the other competitors kept dropping points, Liverpool took advantage of an inept defensive display by Tottenham to cruise to a 4-0 win at Anfield on Sunday and return to the top of the Premier League for the first time since December.
As the other competitors kept dropping points, Liverpool took advantage of an inept defensive display by Tottenham to cruise to a 4-0 win at Anfield on Sunday and return to the top of the Premier League for the first time since December. What could be a pivotal three points for manager Brendan Rodgers and his team, Liverpool are well and truly looking like a side that can be worthy champions. With no Champions League distraction and no other Cup to play for, the Red side of Merseyside is dreaming big!
An eighth straight win for Liverpool was never seriously in doubt when their star striker, Luis Suarez scored his 29th goal of the campaign in the 25th minute, adding to an own-goal by Younes Kaboul inside two minutes. Brazilian midfielder Philippe Coutinho’s struck in the 55th minute while Jordan Henderson’s free kick, which crept in past a mass of legs in the 75th, piled on more misery for Tottenham Hotspurs and fuelled the growing belief that Liverpool can win their first English league title in 24 years.
Liverpool currently, sits atop of the table with two points above Chelsea with six games left. Manchester City is four points back in third but with two matches in hand. Earlier in the season, nobody could have given them a chance to finish this close at the League, citing their earlier performances in the League. But this year, Liverpool have been one step ahead with none other than Luis Suarez to thank who has been scoring goals for fun. Besides the Uruguayan, Daniel Sturridge, Steven Gerrard, Jordan Henderson have been pivotal in Liverpool’s upturn in the Premier League.
To add to that, their former defender Jamie Carragher has praised his side’s current form and said, “I think this Liverpool team is better than the side that won the Champions League in 2005, but you could argue that winning the Premier League this season would be a bigger achievement.” as quoted in the Sky Sports.
This year could really be their year! The likes of Chelsea and Manchester City will visit Anfield in the coming games and pundits cite those games as the acid test for Gerrard and his men. If Reds triumph in those two bumper games, wonder if Arsene Wenger will rue his chances on missing out on Luis Suarez in the last year’s transfer window.
| english |
/*
* Copyright (c) 2013 The Johns Hopkins University/Applied Physics Laboratory
* All rights reserved.
*
* This material may be used, modified, or reproduced by or for the U.S.
* Government pursuant to the rights granted under the clauses at
* DFARS 252.227-7013/7014 or FAR 52.227-14.
*
* 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
*
* NO WARRANTY. THIS MATERIAL IS PROVIDED "AS IS." JHU/APL DISCLAIMS ALL
* WARRANTIES IN THE MATERIAL, WHETHER EXPRESS OR IMPLIED, INCLUDING (BUT NOT
* LIMITED TO) ANY AND ALL IMPLIED WARRANTIES OF PERFORMANCE,
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT OF
* INTELLECTUAL PROPERTY RIGHTS. ANY USER OF THE MATERIAL ASSUMES THE ENTIRE
* RISK AND LIABILITY FOR USING THE MATERIAL. IN NO EVENT SHALL JHU/APL BE
* LIABLE TO ANY USER OF THE MATERIAL FOR ANY ACTUAL, INDIRECT,
* CONSEQUENTIAL, SPECIAL OR OTHER DAMAGES ARISING FROM THE USE OF, OR
* INABILITY TO USE, THE MATERIAL, INCLUDING, BUT NOT LIMITED TO, ANY DAMAGES
* FOR LOST PROFITS.
*/
package edu.jhuapl.openessence.datasource.map;
import org.codehaus.jackson.map.annotate.JsonSerialize;
import org.codehaus.jackson.map.annotate.JsonSerialize.Inclusion;
/**
* JavaBean that specifies the parameters to a GetMap query.
*/
// Geoserver complains if we pass null cql_filters
@JsonSerialize(include = Inclusion.NON_NULL)
public class GetMapQuery {
private String[] layers;
private String format;
private String cql_filter;
private boolean transparent;
// add any other parameters we need
public GetMapQuery() {
}
public String[] getLayers() {
return layers;
}
public void setLayers(String[] layers) {
this.layers = layers;
}
public String getFormat() {
return format;
}
public void setFormat(String format) {
this.format = format;
}
public String getCql_filter() {
return cql_filter;
}
public void setCql_filter(String cql_filter) {
this.cql_filter = cql_filter;
}
public void setTransparent(boolean transparent) {
this.transparent = transparent;
}
public boolean isTransparent() {
return transparent;
}
}
| java |
<gh_stars>0
@import url('https://fonts.googleapis.com/css2?family=Comfortaa:wght@300&family=Josefin+Sans:wght@100;200&family=Major+Mono+Display&family=Open+Sans:wght@300&display=swap');
/*font-family: 'Comfortaa', cursive;
font-family: 'Major Mono Display', monospace;*/
/*font-family: 'Open Sans', sans-serif;*/
:root {
--bg-gray: #3a3b42;
--bg-lt-gray: #41424a;
--lighter-gray: #60626e;
--light-gray: #b6bad1;
--off-white: rgb(255, 255, 241);
--periwink: #92a8d4;
--dark-peach: #ed9393;
--off-black: #1f2024;
--teal: #14aca3;
--header-ft: 'Major Mono Display', monospace;
--body-ft: 'Open Sans', sans-serif;
}
.logo {
padding-top: 5vh;
}
.whole-page {
font-family: var(--body-ft)
}
#login-header {
padding: 1.5vh;
color: white;
font-family: var(--header-ft);
font-size: x-large;
}
#form-input {
padding: 1.5vh 8vh 1.5vh 1vh;
border-radius: 500px;
border: none;
text-align: left;
margin-top: 1vh;
font-family: var(--header-ft);
}
.submitButton {
background-color: var(--periwink);
color: var(--bg-gray);
padding: 2vh 8vh;
border-radius: 500px;
border: none;
margin-top: 1vh;
font-family: var(--body-ft)
}
.form {
background-color: var(--off-black);
padding: 4vh 12vh;
border-radius: 20px;
}
.altLink {
margin-top: 2vh;
padding: 2vh 5vh;
border-radius: 500px;
background-color: var(--bg-lt-gray);
color: white;
}
.altLink a {
color: var(--periwink);
} | css |
A swordsman is only as good as his sword in One Piece, something Zoro knows all too well.
Throughout the One Piece series, Zoro carried over seven different katanas. All of them have proven useful in his battles. While they vary in terms of quality, each one holds sentimental value for Zoro. Ever since he was a young child, he only had one goal in mind.
Dracule Mihawk is currently the world's best swordsman. Very few can sit on that golden throne. Even so, Zoro wants that crown for himself. His swords will be the very key to his success. However, they are more than just simple tools in One Piece, since they go much deeper than that.
Undoubtedly, Zoro's weapons are very meaningful to him. This article will only go over the named swords in the One Piece series. It should be noted that Zoro used two unnamed katanas back in the East Blue Saga. However, Mihawk shattered them during a duel in the Baratie arc.
This is Zoro's first ever sword in the One Piece series. It's part of the 21 Great Grade Meito. They are known for their exceptional craftsmanship. It was proven when Mihawk himself was unable to break it.
11 years ago, Wado Ichimonji belonged to his childhood friend Kuina. However, she met her untimely end, so her father gifted the sword to Zoro. This particular weapon holds great meaning to him. He made a promise that he would become the world's greatest swordsman in Kuina's honor.
Zoro still has this blade in his possession.
This is yet another Meito, but this time with an unusual twist. When Zoro visited Loguetown, he wanted to replace his broken swords from that ill-fated duel with Mihawk. The shop owner told him that Sandai Kitetsu was a cursed sword that would bring misfortune to its yielder.
Of course, Zoro didn't really care and took the sword anyways. He even tested his luck by throwing the sword in the air, only for it to miss him completely.
Tashigi believes it's worth over 1,000,000 bellies, although it was sold at a mere 50,000. Several years later, it was revealed that Tenguyama Hitetsu forged this blade in Wano Country.
Zoro also bought Yubashiri from the same Loguetown shop. It's classified among the 50 Skillful Grade swords. They are slightly weaker than the Great Grade variations, such as Wado Ichimonji.
Unfortunately, Yubashiri was completely destroyed in the Enies Lobby arc. Zoro went up against Marine officer Shu, who rusted it away with his Devil Fruit powers. Nothing much could've been done about the situation.
Shortly afterwards on Thriller Bark, Zoro put the sword to rest. He placed it on the gravesite for the Rumbar Pirates.
Shusui once belonged to the famous samurai Ryuma. However, Gecko Moria stole it when he visited Wano Country. He then gave it to a zombified Ryuma. Not only is it a Grade Great Meito, it's also a Black Blade. This is an exceedingly rare classification in the One Piece universe.
Zoro ended up dueling Ryuma when they fought in Thriller Bark. He emerged victorious and was gifted Shusui, which replaced Yubashiri. Zoro would eventually return the cursed sword when he finally came to Wano Country.
Enma carries a very deadly aura in the One Piece series. It was first seen in the Wano Country arc.
This cursed sword used to belong to Kozuki Oden, who managed to scar Kaido with it. His daughter Hiyori gifted this weapon to Zoro. However, he needed to return Shusui to Ryuma's grave. Zoro made good on that promise, having now added this legendary sword to his collection.
Unlike most swords in One Piece, Enma can draw energy from the wielder. Zoro had to practice using this sword without draining his Busoshoku Haki.
Note: This article reflects the writer's personal views.
| english |
module.exports = {
name: 'rm',
description: 'Prunes that many messages from current channel. (Reserved)',
args: true,
usage: '.rm <number>',
cooldown: 5,
aliases: ['remove','prune','del','clear','cls'],
permissions: [ '763635059273625247' ],
execute(message, args){
const count = parseInt(args[0]);
if(isNaN(count)){
message.reply(`${args[0]}: That doesn't look like a number to me`);
}
else{
// +1 to also delete the command to delete also
message.channel.bulkDelete(count + 1, true).catch(err => {
console.log(err);
message.channel.send('Sorry, there was a problem encountered while pruning this channel');
});
}
}
}
| javascript |
'use strict'
ecom.service('httpCallService', [
'$rootScope',
'$http',
'apiUrl',
function($rootScope, $http, apiUrl) {
var uri = apiUrl;
console.log(uri);
var baseUrl = "/v2/components/learnWebTeach";
this.loginCall = function(loginData) {
var url = uri + baseUrl + "/login";
var apiConfig = [url];
var headers = {};
headers['Content-Type'] = 'application/json';
headers['Accept'] = 'application/json';
apiConfig.push(loginData);
apiConfig.push({ 'headers': headers });
return $http["post"].apply(null, apiConfig);
}
this.signupCall = function(signupData) {
var url = uri + baseUrl + "/signup";
var apiConfig = [url];
var headers = {};
headers['Content-Type'] = 'application/json';
headers['Accept'] = 'application/json';
apiConfig.push(signupData);
apiConfig.push({ 'headers': headers });
return $http["post"].apply(null, apiConfig);
}
this.getAllBlogs = function() {
var url = uri + baseUrl + "/getAllBlogs";
var apiConfig = [url];
var headers = {};
apiConfig.push({ 'headers': headers });
return $http["get"].apply(null, apiConfig);
}
this.getUserBlogs = function() {
var username = localStorage.getItem('user');
var url = uri + baseUrl + "/user/" + username + "/getBlogs";
var apiConfig = [url];
var headers = {};
headers['Authorization'] = localStorage.getItem("token");
apiConfig.push({ 'headers': headers });
return $http["get"].apply(null, apiConfig);
}
this.saveBlog = function(blogData, ) {
var uri = apiUrl;
console.log(uri);
var baseUrl = "/v2/components/learnWebTeach";
var url = uri + baseUrl + "/blog";
var apiConfig = [url];
var headers = {};
headers['Content-Type'] = 'application/json';
headers['Accept'] = 'application/json';
headers['Authorization'] = localStorage.getItem("token");
apiConfig.push(blogData);
apiConfig.push({ 'headers': headers });
return $http["post"].apply(null, apiConfig);
}
}
]); | javascript |
var NAVTREEINDEX3 =
{
"classBovender_1_1Versioning_1_1ReleaseInfo.html#ae764e6ad23d7999b13a3d939e2eb68ce":[1,0,0,9,3,13],
"classBovender_1_1Versioning_1_1ReleaseInfo.html#af5a4c217bc9035bbff233d070ea19267":[1,0,0,9,3,2],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html":[1,0,0,9,4],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a14cca0e3537753830fe974d657f25320":[1,0,0,9,4,4],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a17d22258b70fa233970105a1b2c48aa8":[1,0,0,9,4,0],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a1d2ab4d55ff50d8810f424800779d4c2":[1,0,0,9,4,5],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a605233cda2dfd7b02c033e735dab7a8e":[1,0,0,9,4,2],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a7dfc9397c86c350e8b0cb442dae91001":[1,0,0,9,4,10],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a82b378fdadbd00c2f5df0925e5475903":[1,0,0,9,4,6],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a82e4658e659cd49a13b69fe92d3f601a":[1,0,0,9,4,12],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a835ea2019ebfa604fc7b49fbba1c6fa0":[1,0,0,9,4,16],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#a8debca798280ff533e2a886f260923dc":[1,0,0,9,4,3],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#aa42437c328e3173655dbcb3bf408c802":[1,0,0,9,4,8],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#aa55f834ced13389d5f0dd1c2d42fb9c9":[1,0,0,9,4,11],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#ab3b76b28cb84f5179aa3fa0cfca5569f":[1,0,0,9,4,1],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#ad30d6174d6feba5011536b1a8f77ef4c":[1,0,0,9,4,17],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#ad748ebfd2b856ff471425511e8e5ef23":[1,0,0,9,4,15],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#ae28e12214d401567c606959dec120cb1":[1,0,0,9,4,7],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#ae81c6908d8dc4c2f1dbe447b04e8ed13":[1,0,0,9,4,14],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#af78d6b17ec6fa4fd704d5774df1dbacf":[1,0,0,9,4,13],
"classBovender_1_1Versioning_1_1ReleaseInfoViewModel.html#afb30a63b98037ef2eb7d8348badfebd0":[1,0,0,9,4,9],
"classBovender_1_1Versioning_1_1SemanticVersion.html":[1,0,0,9,5],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a220b81c178d21a96ef7347912999b94d":[1,0,0,9,5,2],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a2a0b71bddf443651ff020e17851a70ab":[1,0,0,9,5,21],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a386a141acb4ad97657b247f053e11d67":[1,0,0,9,5,5],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a4f4c877d7afa256f8b4de7eeb6f3d02f":[1,0,0,9,5,17],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a62ca30241701df397803140b965bffe5":[1,0,0,9,5,14],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a64821853a5020345fdf8ca113cb66ba3":[1,0,0,9,5,11],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a91237f585c4a4656a49a7e83a94ddbd5":[1,0,0,9,5,12],
"classBovender_1_1Versioning_1_1SemanticVersion.html#a941fe02bc5392289435729b31e1da7ce":[1,0,0,9,5,19],
"classBovender_1_1Versioning_1_1SemanticVersion.html#aa27c91398482b3d1320b257501dac834":[1,0,0,9,5,22],
"classBovender_1_1Versioning_1_1SemanticVersion.html#ab2d1b3e1d8464bb0877e2dfb8bff1da4":[1,0,0,9,5,4],
"classBovender_1_1Versioning_1_1SemanticVersion.html#abec8ed91af691faf883ed19f628a3df2":[1,0,0,9,5,15],
"classBovender_1_1Versioning_1_1SemanticVersion.html#ac0b4488f7c996ef0fac952bf6abfd1aa":[1,0,0,9,5,9],
"classBovender_1_1Versioning_1_1SemanticVersion.html#ac9435213c448ff451ffe995698150154":[1,0,0,9,5,20],
"classBovender_1_1Versioning_1_1SemanticVersion.html#aca8396ced032a3e4186fb9aea39b5923":[1,0,0,9,5,7],
"classBovender_1_1Versioning_1_1SemanticVersion.html#ad8d3192f0e33c18d6a3ea9949406a485":[1,0,0,9,5,0],
"classBovender_1_1Versioning_1_1SemanticVersion.html#adaa524ec30d4d5e631e5c166a4334f37":[1,0,0,9,5,18],
"classBovender_1_1Versioning_1_1SemanticVersion.html#ae1f2d6a844ed58596a5e93cbb74cdc2d":[1,0,0,9,5,13],
"classBovender_1_1Versioning_1_1SemanticVersion.html#aeb1bf8e8991438bbd2bcba2f275edc5d":[1,0,0,9,5,3],
"classBovender_1_1Versioning_1_1SemanticVersion.html#aebc0efc968cc32971b8b6660d099e8ee":[1,0,0,9,5,1],
"classBovender_1_1Versioning_1_1SemanticVersion.html#aeecc8ff78a104f9996465ca1c0cf9451":[1,0,0,9,5,10],
"classBovender_1_1Versioning_1_1SemanticVersion.html#af3ee12b4727e3701bbba99938d1cd1fa":[1,0,0,9,5,6],
"classBovender_1_1Versioning_1_1SemanticVersion.html#afa7fb4fe69102eac61ce36555f580f1b":[1,0,0,9,5,16],
"classBovender_1_1Versioning_1_1SemanticVersion.html#afdcf1b23aeb12602d68a06f6f3af9df8":[1,0,0,9,5,8],
"classBovender_1_1Versioning_1_1Updater.html":[1,0,0,9,6],
"classBovender_1_1Versioning_1_1Updater.html#a00b53d5af6dfdb8a863698858dba74d1":[1,0,0,9,6,17],
"classBovender_1_1Versioning_1_1Updater.html#a0306c694ef98f31e377e74ce3cc4047e":[1,0,0,9,6,8],
"classBovender_1_1Versioning_1_1Updater.html#a0cbc6975f0afb7d75fdebb35fce730a8":[1,0,0,9,6,14],
"classBovender_1_1Versioning_1_1Updater.html#a18e9c642a255bf69ea67c59742204169":[1,0,0,9,6,3],
"classBovender_1_1Versioning_1_1Updater.html#a2fc33845bff9c93ee7a59e6bc78dd6aa":[1,0,0,9,6,12],
"classBovender_1_1Versioning_1_1Updater.html#a331ea1e1607331a44dbba7227b1c6708":[1,0,0,9,6,0],
"classBovender_1_1Versioning_1_1Updater.html#a35befa36a4eb356309db7453052c07c0":[1,0,0,9,6,10],
"classBovender_1_1Versioning_1_1Updater.html#a3b9c2715daddcd9fac6269d6f1362583":[1,0,0,9,6,15],
"classBovender_1_1Versioning_1_1Updater.html#a3db71997accedc8f49b48169f29fd99e":[1,0,0,9,6,20],
"classBovender_1_1Versioning_1_1Updater.html#a500b1b4b4810013615c41f31ca78a1ab":[1,0,0,9,6,9],
"classBovender_1_1Versioning_1_1Updater.html#a51c6f8a82001eaee3fc99036fd9c7551":[1,0,0,9,6,7],
"classBovender_1_1Versioning_1_1Updater.html#a622e58a30fef6621b1cd3b66a96c6c30":[1,0,0,9,6,18],
"classBovender_1_1Versioning_1_1Updater.html#a6a01b9bfa268be98070aaadc6249d3d8":[1,0,0,9,6,13],
"classBovender_1_1Versioning_1_1Updater.html#a72a081509ab4607e63b28470f2b964b4":[1,0,0,9,6,1],
"classBovender_1_1Versioning_1_1Updater.html#a7f937d98fcebdde3c4fd2ecc67f393e2":[1,0,0,9,6,5],
"classBovender_1_1Versioning_1_1Updater.html#a925339f8c165a55dee9c845c7bb2d858":[1,0,0,9,6,2],
"classBovender_1_1Versioning_1_1Updater.html#aa44e3e90b7e267160ecadb1fc983518b":[1,0,0,9,6,16],
"classBovender_1_1Versioning_1_1Updater.html#abaca74306b5be6e169436fe2fd3d844e":[1,0,0,9,6,4],
"classBovender_1_1Versioning_1_1Updater.html#abb628d842e1f34658162ac48d05eb74e":[1,0,0,9,6,11],
"classBovender_1_1Versioning_1_1Updater.html#acaaada676cf292c329c26f12f08114cc":[1,0,0,9,6,19],
"classBovender_1_1Versioning_1_1Updater.html#ae582358dd5cc877fea25e727a16aece6":[1,0,0,9,6,6],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html":[1,0,0,9,7],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a00404a37ebd9c5a95aa7fa298d60cb7e":[1,0,0,9,7,7],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a0125ce1f1b047301f449fd77e4712a7b":[1,0,0,9,7,22],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a03141b2fe08a68cf03e94a983dc3991f":[1,0,0,9,7,0],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a05ef359012d8e5cfd175c721e74bd4b0":[1,0,0,9,7,1],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a330f87763a339264995134ea87d2e00f":[1,0,0,9,7,9],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a3ea780e09aeae1556955d4889f4964f9":[1,0,0,9,7,11],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a3f903ea7b8d7ea8a774356782b13a5b5":[1,0,0,9,7,23],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a42441d40d4c1b69de03bd066b55cca0a":[1,0,0,9,7,19],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a427c5593ea14be5ddc386dc4124ee447":[1,0,0,9,7,13],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a48a0e0ae1294b464e5bfe892662356e8":[1,0,0,9,7,12],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a4c7728d97090d160cf865f716c7b1230":[1,0,0,9,7,3],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a4e82873a3159464e8cbe498c214a2b08":[1,0,0,9,7,2],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a53685df913e491e4e6135ce7a891f3b9":[1,0,0,9,7,17],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a59a9f2f94ed62af0cb2875b671583101":[1,0,0,9,7,8],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a5bb2dfaae139d37099b6ad551434c4c8":[1,0,0,9,7,21],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a730fd5a3face2cb3d452e2647c55df67":[1,0,0,9,7,18],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a7da15298a5f00e180cf1f400e2939d92":[1,0,0,9,7,4],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#a9c98d7ba03c5f957e526162a067aade6":[1,0,0,9,7,14],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#aa4cf50b04613a9d40691746ee2bad6af":[1,0,0,9,7,15],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#aafbcf528a22bc37bae8b83d1b055cb14":[1,0,0,9,7,16],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#ac0ea9fdc816c52934c8eabf8f12f47b4":[1,0,0,9,7,20],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#ad8bea8f6e786f4c10d4151140aa39665":[1,0,0,9,7,5],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#aeb95689db182f21145c54d7cdf46d5c0":[1,0,0,9,7,6],
"classBovender_1_1Versioning_1_1UpdaterViewModel.html#afe6ba8f02877b65c96eaf696eea57621":[1,0,0,9,7,10],
"classBovender_1_1Win32Window.html":[1,0,0,14],
"classBovender_1_1Win32Window.html#a024b5af92770a130a5ac7192edabbd3c":[1,0,0,14,3],
"classBovender_1_1Win32Window.html#a25ab8e665945e5681960d7193684995c":[1,0,0,14,5],
"classBovender_1_1Win32Window.html#a2a42c17f494638d6138a7eda4d27cfec":[1,0,0,14,4],
"classBovender_1_1Win32Window.html#a2e6cbdfe19ba063ba5e826540b1c4312":[1,0,0,14,2],
"classBovender_1_1Win32Window.html#a4ea94cae5c89b33f4fa635019567e3d6":[1,0,0,14,0],
"classBovender_1_1Win32Window.html#a5322636418837db8028883ff471c3772":[1,0,0,14,6],
"classBovender_1_1Win32Window.html#a95c35d496b262b140ca5bc315b809636":[1,0,0,14,1],
"classBovender_1_1WpfHelpers.html":[1,0,0,15],
"classBovender_1_1WpfHelpers.html#aac18c2954d2ab837adccfc3d7d06d33e":[1,0,0,15,0],
"classXLToolbox_1_1Test_1_1VersioningTest.html":[1,0,1,0,0],
"classXLToolbox_1_1Test_1_1VersioningTest.html#a0224be541e2ebc3d8c208336558d29b5":[1,0,1,0,0,2],
"classXLToolbox_1_1Test_1_1VersioningTest.html#a7d0a8e07ec0d6f285320e9218f61e2df":[1,0,1,0,0,3],
"classXLToolbox_1_1Test_1_1VersioningTest.html#a8d0af80a53434ebf86c995971aaa5ca0":[1,0,1,0,0,0],
"classXLToolbox_1_1Test_1_1VersioningTest.html#aadd39c074d30f7fc743b0da1f8a3b39c":[1,0,1,0,0,1],
"classes.html":[1,1],
"dir_013539301d41e116f0e9065cab669ef8.html":[2,0,0,5],
"dir_01c565a057565083ee7142840e5f70f2.html":[2,0,1,2],
"dir_0a273ae35b9de739ff528f1dc98903db.html":[2,0,0,4,4],
"dir_23534604779eee389924ed1abf2d6d92.html":[2,0,0,4,2],
"dir_2558d60c767fe4c6bdc194eab234f242.html":[2,0,0,4,1],
"dir_3d54179343c3370a698c2f86b0e59ec3.html":[2,0,0],
"dir_432ed84b8907eb1afb53e7ae0dc48917.html":[2,0,0,3],
"dir_47a2b41250cb17a0154b5594a7779aca.html":[2,0,0,8],
"dir_4d805ed6ec7f379c2a4bddab3a18517f.html":[2,0,0,4],
"dir_4d9b59538b5433336d9669e78682f3b3.html":[2,0,0,7],
"dir_54eb27c4b09ca879fc563728a86cfaf3.html":[2,0,0,4,0],
"dir_5df456e3f2e6fa062fd416ac0a6f2f7f.html":[2,0,0,4,3],
"dir_6fe106120e249764ed983e73336bd92e.html":[2,0,1,2,0],
"dir_923d7c059f730ccb8464906ab090e8c2.html":[2,0,0,2],
"dir_9841ff230b7773258445d4a191f846fe.html":[2,0,1],
"dir_9916eb968ec05b940fb0743f0223c408.html":[2,0,0,9],
"dir_a2b9f1a68cd46af3e833539819e60251.html":[2,0,1,6],
"dir_a3cae66073d9dcff94cb28f283a0952d.html":[2,0,1,1],
"dir_b0dc2de9841ea22a1064fac6dff14c6f.html":[2,0,1,0],
"dir_b16457bf1e65952e1a116b9976a7a074.html":[2,0,0,4,5],
"dir_b6443d24c5d1d4b76a35fad44f06ef2a.html":[2,0,0,4,6,0],
"dir_c05a3a2ae941a8ce4ad740c778a2274e.html":[2,0,0,0],
"dir_c7e2b35a067e0b74ed575460aead3005.html":[2,0,1,3],
"dir_c94dcc1c011aa66adb8029e1a7172c7c.html":[2,0,0,4,6],
"dir_d35bb165eebf95bc60877820de656aa5.html":[2,0,0,1],
"dir_d3dd4473323d646f6e34f67e025d7e89.html":[2,0,1,4],
"dir_e21efb7654f75ea0d335e38adf1a9756.html":[2,0,1,5],
"dir_f1475bdb3ef8d162f4822ac7752b4f7f.html":[2,0,0,6],
"files.html":[2,0],
"functions.html":[1,3,0],
"functions_evnt.html":[1,3,3],
"functions_func.html":[1,3,1],
"functions_prop.html":[1,3,2],
"hierarchy.html":[1,2],
"index.html":[],
"interfaceBovender_1_1Mvvm_1_1Messaging_1_1IMessage.html":[1,0,0,4,3,2],
"interfaceBovender_1_1Mvvm_1_1Messaging_1_1IMessage.html#a3db1aaf49a00121d5d326ae6afc336f6":[1,0,0,4,3,2,0],
"interfaceBovender_1_1Mvvm_1_1Models_1_1IProcessModel.html":[1,0,0,4,4,0],
"interfaceBovender_1_1Mvvm_1_1Models_1_1IProcessModel.html#a4e3622dec0cfffdbb55eba7b6efa5169":[1,0,0,4,4,0,1],
"interfaceBovender_1_1Mvvm_1_1Models_1_1IProcessModel.html#a615e08254d16efeb05965b3e3a04b8cd":[1,0,0,4,4,0,0],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html":[1,0,0,9,2],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a0af612fc383351ceb24fb12116756ddc":[1,0,0,9,2,5],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a393e63666106fcaff098e95b82bbf041":[1,0,0,9,2,4],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a4615f2a2d016638eab7884132e47a16d":[1,0,0,9,2,7],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a566410f61f466a0241e6a0157689f31c":[1,0,0,9,2,6],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a624559ad5344b3a6d0861a07cfdc03dc":[1,0,0,9,2,0],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#a8d79f47d87351d8d9c92a13699053d98":[1,0,0,9,2,2],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#aa2e035c720fb3e61ba84b63253cf942b":[1,0,0,9,2,1],
"interfaceBovender_1_1Versioning_1_1IReleaseInfo.html#ab3924a0808ed0a92694ce0d9ddce01d2":[1,0,0,9,2,3],
"namespaceBovender.html":[0,0,0],
"namespaceBovender.html":[1,0,0],
"namespaceBovender_1_1ExceptionHandler.html":[0,0,0,0],
"namespaceBovender_1_1ExceptionHandler.html":[1,0,0,0],
"namespaceBovender_1_1Extensions.html":[1,0,0,1],
"namespaceBovender_1_1Extensions.html":[0,0,0,1],
"namespaceBovender_1_1HtmlFiles.html":[0,0,0,2],
"namespaceBovender_1_1HtmlFiles.html":[1,0,0,2],
"namespaceBovender_1_1Logging.html":[0,0,0,3],
"namespaceBovender_1_1Logging.html":[1,0,0,3],
"namespaceBovender_1_1Mvvm.html":[0,0,0,4],
"namespaceBovender_1_1Mvvm.html":[1,0,0,4],
"namespaceBovender_1_1Mvvm_1_1Actions.html":[1,0,0,4,0],
"namespaceBovender_1_1Mvvm_1_1Actions.html":[0,0,0,4,0],
"namespaceBovender_1_1Mvvm_1_1Behaviors.html":[1,0,0,4,1],
"namespaceBovender_1_1Mvvm_1_1Behaviors.html":[0,0,0,4,1],
"namespaceBovender_1_1Mvvm_1_1Converters.html":[0,0,0,4,2],
"namespaceBovender_1_1Mvvm_1_1Converters.html":[1,0,0,4,2],
"namespaceBovender_1_1Mvvm_1_1Messaging.html":[1,0,0,4,3],
"namespaceBovender_1_1Mvvm_1_1Messaging.html":[0,0,0,4,3],
"namespaceBovender_1_1Mvvm_1_1Models.html":[1,0,0,4,4],
"namespaceBovender_1_1Mvvm_1_1Models.html":[0,0,0,4,4],
"namespaceBovender_1_1Mvvm_1_1ViewModels.html":[0,0,0,4,5],
"namespaceBovender_1_1Mvvm_1_1ViewModels.html":[1,0,0,4,5],
"namespaceBovender_1_1Mvvm_1_1Views.html":[0,0,0,4,6],
"namespaceBovender_1_1Mvvm_1_1Views.html":[1,0,0,4,6],
"namespaceBovender_1_1Mvvm_1_1Views_1_1Settings.html":[0,0,0,4,6,0],
"namespaceBovender_1_1Mvvm_1_1Views_1_1Settings.html":[1,0,0,4,6,0],
"namespaceBovender_1_1Properties.html":[0,0,0,5],
"namespaceBovender_1_1Text.html":[1,0,0,5],
"namespaceBovender_1_1Text.html":[0,0,0,6],
"namespaceBovender_1_1UnitTests.html":[0,0,0,7],
"namespaceBovender_1_1UnitTests.html":[1,0,0,6],
"namespaceBovender_1_1UnitTests_1_1Extensions.html":[0,0,0,7,0],
"namespaceBovender_1_1UnitTests_1_1Extensions.html":[1,0,0,6,0],
"namespaceBovender_1_1UnitTests_1_1Mvvm.html":[1,0,0,6,1],
"namespaceBovender_1_1UnitTests_1_1Mvvm.html":[0,0,0,7,1],
"namespaceBovender_1_1UnitTests_1_1Text.html":[0,0,0,7,2],
"namespaceBovender_1_1UnitTests_1_1Text.html":[1,0,0,6,2],
"namespaceBovender_1_1UnitTests_1_1UserSettings.html":[0,0,0,7,3],
"namespaceBovender_1_1UnitTests_1_1UserSettings.html":[1,0,0,6,3],
"namespaceBovender_1_1UnitTests_1_1Versioning.html":[1,0,0,6,4],
"namespaceBovender_1_1UnitTests_1_1Versioning.html":[0,0,0,7,4],
"namespaceBovender_1_1Unmanaged.html":[1,0,0,7],
"namespaceBovender_1_1Unmanaged.html":[0,0,0,8],
"namespaceBovender_1_1UserSettings.html":[0,0,0,9],
"namespaceBovender_1_1UserSettings.html":[1,0,0,8],
"namespaceBovender_1_1Versioning.html":[1,0,0,9],
"namespaceBovender_1_1Versioning.html":[0,0,0,10],
"namespaceXLToolbox.html":[0,0,1],
"namespaceXLToolbox.html":[1,0,1],
"namespaceXLToolbox_1_1Test.html":[1,0,1,0],
"namespaceXLToolbox_1_1Test.html":[0,0,1,0],
"namespaces.html":[0,0],
"nitTests_2Properties_2AssemblyInfo_8cs_source.html":[2,0,1,3,0],
"pages.html":[]
};
| javascript |
<reponame>viniciuspquaresma/CheckoutSample<filename>package.json
{
"name": "br.com.elvis.checkoutsample",
"version": "1.0.0",
"description": "Exemplo de checkout utilizando MercadoPago",
"main": "app.js",
"scripts": {
"test": "nyc mocha",
"coverage": "istanbul cover mocha -- ./test/* --recursive"
},
"repository": {
"type": "git",
"url": "git+https://github.com/elvisjhonataoliveira/CheckoutSample.git"
},
"author": "<NAME>",
"license": "MIT",
"bugs": {
"url": "https://github.com/elvisjhonataoliveira/CheckoutSample/issues"
},
"homepage": "https://github.com/elvisjhonataoliveira/CheckoutSample#readme",
"dependencies": {
"@fortawesome/fontawesome-free": "^5.12.0",
"body-parser": "^1.19.0",
"chai": "^4.2.0",
"consign": "^0.1.6",
"dateformat": "^3.0.3",
"ejs": "^3.0.1",
"express": "^4.17.1",
"express-session": "^1.17.0",
"express-validator": "^5.3.1",
"mercadopago": "^1.2.1",
"mongodb": "^3.4.0",
"properties-reader": "^0.3.1",
"request": "^2.88.0",
"should": "^13.2.3",
"validar-cpf": "^2.1.2"
},
"devDependencies": {
"nyc": "^14.1.1"
}
}
| json |
---
title: Editar hojas de estilos XSLT | Documentos de Microsoft
ms.custom: ''
ms.date: 11/15/2016
ms.prod: visual-studio-dev14
ms.reviewer: ''
ms.suite: ''
ms.technology:
- vs-ide-general
ms.tgt_pltfrm: ''
ms.topic: article
ms.assetid: 080bed0f-0ca9-4be7-aecd-6bdaebc04007
caps.latest.revision: 11
author: gewarren
ms.author: gewarren
manager: ghogen
ms.openlocfilehash: 7dd25a531682c74284a74f065dc729f37ac7fb1a
ms.sourcegitcommit: 9ceaf69568d61023868ced59108ae4dd46f720ab
ms.translationtype: MT
ms.contentlocale: es-ES
ms.lasthandoff: 10/12/2018
ms.locfileid: "49287008"
---
# <a name="editing-xslt-style-sheets"></a>Editar hojas de estilos XSLT
[!INCLUDE[vs2017banner](../includes/vs2017banner.md)]
El Editor XML se puede utilizar también para editar hojas de estilos XSLT. Puede aprovechar las características predeterminadas del editor como IntelliSense, esquematización, fragmentos XML, etc. Además, se incluyen también nuevas características que facilitan la programación en XSLT.
## <a name="xslt-features"></a>Características XSLT
En la siguiente tabla se describen características específicas del trabajo con hojas de estilos XSLT.
**Color de sintaxis**
Las palabras clave XSLT, como `template`, `match`, y así sucesivamente, se muestran en el color de palabra clave XSLT especificado por el **fuentes y colores** configuración.
**Subrayado ondulado**
El Editor XML utiliza el archivo xslt.xsd instalado para validar las hojas de estilos XSLT. Los errores de validación se muestran con un subrayado ondulado de color azul. El Editor XML también compila la hoja de estilos en segundo plano e informa de los errores o advertencias del compilador mediante el subrayado ondulado adecuado.
**Compatibilidad con bloques de scripts**
El depurador de XSLT admite el código en bloques de scripts, de modo que puede definir puntos de interrupción y examinar el código del bloque de script.
**Ver el resultado XSLT**
Puede ejecutar una transformación XSL y ver el resultado desde el Editor XML. Para obtener más información, consulte [Cómo: ejecutar una transformación XSLT desde el Editor XML](../xml-tools/how-to-execute-an-xslt-transformation-from-the-xml-editor.md).
**Depurar XSLT**
Puede iniciar el depurador de XSLT desde un archivo XSLT del Editor XML. El depurador admite la definición de puntos de interrupción en el archivo XSLT, la visualización del estado de ejecución de XSLT, etc. Al mantener el mouse sobre una variable XSLT se muestra un cuadro de información sobre herramientas con el valor de la variable. El depurador se puede utilizar para depurar una hoja de estilos o para depurar una transformación XSL compilada invocada desde otra aplicación. Para obtener más información, consulte [depuración XSLT](../xml-tools/debugging-xslt.md).
## <a name="see-also"></a>Vea también
[Editor XML](../xml-tools/xml-editor.md)
| markdown |
In any apartment the balcony is most often reserved for rest, it is pleasant to spend evenings, to drink coffee, or to finish a hard day with a glass of your favorite juice or tea.
But when the warm season is over, many are interested in the question of how to insulate and trim the balcony? To this part of the house was as comfortable and comfortable as possible, its decoration should also be given due attention. In our master class, we will tell you step by step how to properly insulate the balcony from the inside by using a penopolix. For this we need:
- wooden slats;
- penoplex (can be styrofoam);
- Particleboard;
- self-tapping screws;
- dowels with hats;
- special foil tape;
- penofol;
- building stapler;
- mounting foam;
- sealant;
- staples;
- laminated panels;
- decorative guides;
How to properly insulate the balcony on the floor?
- The first thing we do is laying wooden racks on the floor. The distance between the bars should be 1 cm more than the width of the penoplex sheet, the thickness of the bar is equal to the thickness of the insulation - about 5 cm. We attach the rails to the floor along the balcony with screws, screw them at a distance of 30-40 mm from each other.
- We put the level to the racks and see if the stacking has turned out evenly? If not, then to raise the rails you can use a plastic lining, putting it under the bar.
- We lay on the floor a heater for the balcony - foamotex.
- We process foam joints between penotex and slats.
- Take a sheet of chipboard and attach it along the balcony to the wooden slats using self-tapping screws, screw them at a distance of 10-15 cm from each other, leaving a small gap between the sheets.
How to properly insulate the balcony walls and ceiling?
- This phase of work we begin with the fastening of the insulant itself. We apply the mounting foam to the wall in zigzag motion.
- We apply a heater for the balcony to the surface of the wall and fix it with plastic dowels with hats. It is very important to choose the dowels, take into account the thickness of the balcony wall, so as a result of its fastening, the tip of the dowel does not come out to the outside of the balcony.
- We take the building level and look how exactly we laid the heater.
- On top of the heater, apply an additional layer of foam. To glue this thermal insulator you need whole pieces, you can overlap, the main thing is not to form joints.
- Formed seams of foam foil are sealed with foil tape.
- The same is done on the ceiling.
- How to properly insulate the balcony from the inside with the help of a heater cleared and went to the final part - the skin. On the ceiling we attach wooden slats 2 cm thick by means of screws at a distance of 35-40 cm to the previously built frame, for laying the insulation for the balcony.
- The level is measured by the evenness of the resulting construction.
- Next, we attach the wooden structure to the walls. We choose self-tapping screws so long that after screwing they do not protrude out the balcony. Before fixing on the slats, we apply a little mounting foam and attach them to the surface with self-tapping screws at intervals of 35-40 cm.
- Now, the frame for laminated panels is ready, and you can start finishing. We fix the panels with a construction stapler, and the ends are covered with decorative guides.
- We lay the panels on walls and ceiling.
- The ends are hidden behind the decorative guides.
- We put on the decorative corners of the mounting foam and attach them to the corners.
- The seams between the panels are masked with white sealant.
- We lay on the floor the laminate in a horizontal position.
- We fix the plinth. That's what we got as a result. | english |
Keytruda (pembrolizumab) is a prescription medication used to treat certain types of cancer. It is a type of immunotherapy that works by helping the immune system attack cancer cells. Keytruda is generally well-tolerated, but it can cause side effects like all medications. Know more about “what are the side effects of keytruda treatments?" Here are 10 possible Keytruda side effects and some suggestions for how to manage them.
Keytruda is a medication used to treat certain types of cancer. It belongs to a class of drugs called immunotherapy, which helps the body's immune system fight and control cancer cells. Specifically, Keytruda works by blocking a protein called PD-1 on immune cells, which allows the immune system to better recognize and attack cancer cells. It is often prescribed for cancers that have a specific genetic feature and may be used alone or in combination with other treatments.
When Do Keytruda Side Effects Start?
Keytruda side effects can start at any point of the treatment. Some people may experience the side effects of keytruda treatment early and some may experience later during the treatment. If you notice any new or worsening of the symptoms, it is recommended to consult your doctor on an immediate basis and manage them appropriately.
Common keytruda eye side effects include dry eyes, which may make your eyes feel a bit uncomfortable or gritty. In some cases, Keytruda can also cause inflammation in the eyes, leading to symptoms like redness, itching, or blurry vision.
Side effects of keytruda treatment, like hair loss, are typically transient. Several weeks after your last dose, if you are experiencing hair loss due to taking Keytruda, your hair should begin to grow back.
Cooling caps, made to keep your scalp chilly, could stop hair loss. The blood flow to your scalp is reduced by cooling caps, which may diminish the impact of Keytruda or chemotherapy on your hair. Avoid overusing harsh hairstyle equipment as your hair starts to grow back.
These include hair straighteners and blow dryers. To keep your hair healthy and able to grow, you should also refrain from bleaching or dying it. If you have any concerns about keytruda and hair loss, quickly connect with your healthcare professional.
Did you experience keytruda side effects on your skin? Some people taking Keytruda may develop a rash on their skin. Keytruda's side effects can occasionally result in severe rashes and other skin problems. These include toxic epidermal necrolysis and Stevens-Johnson syndrome (SJS) (TEN).
You get a rash and painful sore on your eyes, genitalia, mouth, or throat when you have SJS and TEN. To manage a rash, use mild, unscented soaps and moisturizers, and avoid exposure to the sun. Avoid taking a hot bath or shower. Bathe in cool water mixed with oatmeal or baking soda instead.
Scratching should be avoided since it might aggravate the itch and rash, and use a moisturizer to keep your skin moisturized. You can also use over-the-counter steroid creams like hydrocortisone or antihistamines like diphenhydramine (Benadryl). But before combining additional medications with Keytruda, see your doctor or pharmacist.
Keytruda can cause diarrhea, which can be uncomfortable and disruptive. To manage this Keytruda side effect, drink plenty of fluids to stay hydrated, and try to eat foods that are easy to digest, such as rice, bananas, and toast. If your schedule permits, try resting in bed to give your body time to recover from the lost fluids.
Keytruda can cause nausea, making it difficult to eat or drink. Try eating smaller, more frequent meals to manage nausea and avoid strong-smelling or spicy foods. Also, avoid going out in direct sunlight and wearing tight body-fitting clothes.
Keytruda can also cause constipation, which can be uncomfortable and disrupt your daily routine. To manage constipation, try to eat a diet high in fiber, drink plenty of fluids, and exercise regularly. Avoid eating spicy and junk food that can further make you feel uncomfortable.
Keytruda can cause fever, a sign of infection. If you have a fever while taking Keytruda, contact your healthcare provider immediately, as it might be a sign of some serious condition. Your doctor might recommend over-the-counter medications like aspirin or naproxen if your fever is regular.
Keytruda can cause a cough that can irritate and disrupt sleep. To manage a cough, try drinking fluids to help loosen mucus, and avoid exposure to irritants like smoke and strong perfumes. If you are a smoker you should consider quitting as it might worsen this Keytruda side effect.
Keytruda can cause shortness of breath, which can be alarming and disrupt your daily activities. If you experience shortness of breath while taking Keytruda, contact your healthcare provider immediately, as it can be serious from a medical point of view.
Keytruda joint pain - Some people taking Keytruda may experience joint pain, which can be uncomfortable and disrupt daily activities. To manage joint pain, try using over-the-counter pain medications, applying heat or cold to the affected area, and engaging in low-impact activities that don't put too much strain on your joints. You can also try stretching your muscles and taking over-the-counter pain relievers such as Tylenol and ibuprofen. If you're experiencing Keytruda joint pain, your healthcare team can assess your situation & provide appropriate guidance or treatment plan.
Keytruda can cause changes in appetite, leading to weight gain or weight loss. To manage changes in appetite, try to eat a healthy, balanced diet and avoid skipping meals. If you have trouble eating or drinking due to side effects, talk to your healthcare provider about other options, such as supplements or nutrition support.
Things to bear in mind before taking Keytruda:
If you have specific medical issues or other variables that affect your health, Keytruda is not your best choice. Before using Keytruda, discuss your medical history with your doctor. The following list of variables should be considered as they might worsen Keytruda side effects:
If you have received a stem cell transplant or are required to do it in the future.
Avoid alcohol consumption as it may worsen Keytruda's side-effects like diarrhea, fatigue, and nausea.
You must avoid Keytruda if you are pregnant or breastfeeding, as it might cause harm to the infant.
Keytruda side effects are temporary and should go away as soon as you stop taking the drug.
To explore Keytruda's side effects and experiences, consider visiting online forums where individuals can share insights and discuss their encounters with the medication. Go online for the term "keytruda side effects forum." An example of a community is the "Macmillan Cancer Support Community, etc.
It's important to remember that everyone's experience with Keytruda is different, and some people may not experience any side effects. Talk to your healthcare provider if you have any concerns about side effects. They can help you manage any side effects you may be experiencing and ensure that you benefit most from your treatment.
Popular searches:
What Is Keytruda Used For?
Keytruda is used to treat various types of cancer by boosting the immune system.
How Long Do Keytruda Side Effects Last?
The duration of Keytruda side effects may vary for each individual. It is advisable to consult your doctor for more personalized advice.
Can Keytruda Cure Cancer?
Keytruda is not a guaranteed cure of cancer. It can slow down the spread of cancer cells.
How Long Does Keytruda Stay In Your System After Stopping?
Around 26 days. It may take around months to get eliminated out of your body after the treatment.
How Successful Is Keytruda For Cancer?
Keytruda helps in boosting the immune system and ability to fight with cancer. It is a successful treatment when it is combined with other cancer treatment options.
Is Keytruda A High Risk Medication?
Yes, Keytruda is a high risk medication due to potential immune-related adverse reactions.
Are Keytruda Side Effects Cumulative?
Keytruda side effects may vary for each individual, everyone will not experience them in the same way.
Are Keytruda Side Effects Permanent?
No, There are some common and mild side effects of Keytruda that are temporary.
| english |
<gh_stars>10-100
export * from './constants';
export * from './use-init';
| typescript |
package com.chasegarsee.javacountriesapp;
import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;
import java.util.ArrayList;
@RestController
@RequestMapping("/data")
public class CountryNamesController
{
//localhost:1992/data/allcountries
@RequestMapping(value = "/allcountries")
public ResponseEntity<?> getAllCountries()
{
JavacountriesappApplication.ourCountryList.countryList.sort((e1, e2) -> e1.getName().compareToIgnoreCase(e2.getName()));
return new ResponseEntity<>(JavacountriesappApplication.ourCountryList.countryList, HttpStatus.OK);
}
//localhost:1992/data/countries/b
@GetMapping(value = "/countries/{letter}")
public ResponseEntity<?> getCountriesLetter(@PathVariable char letter)
{
ArrayList<Country> rtnCountries = JavacountriesappApplication.ourCountryList
.findCountries(e -> e.getName().toUpperCase().charAt(0) == Character.toUpperCase(letter));
return new ResponseEntity<>(rtnCountries, HttpStatus.OK);
}
//localhost:1992/names/size/
@GetMapping("/size/{number}")
public ResponseEntity<?> getCountriesNamesLargerThanOrEqualTo(@PathVariable int number)
{
CountryList countries = JavacountriesappApplication.ourCountryList;
ArrayList<Country> rtnCountries = countries.findCountries(c -> c.getName().length() >= number);
rtnCountries.sort((c1, c2) -> c1.getName().compareToIgnoreCase(c2.getName()));
return new ResponseEntity<>(rtnCountries, HttpStatus.OK);
}
@GetMapping("/population/{people}")
public ResponseEntity<?> getCountriesWithGreaterThanPop(@PathVariable int people)
{
CountryList countries = JavacountriesappApplication.ourCountryList;
ArrayList<Country> rtnCountries = countries.findCountries(c -> c.getPopulation() >= people);
return new ResponseEntity<>(rtnCountries, HttpStatus.OK);
}
@GetMapping("/population/min")
public ResponseEntity<?> getCountryWithMinPop()
{
CountryList countries = JavacountriesappApplication.ourCountryList;
countries.countryList.sort((c1, c2) -> c1.getPopulation() - c2.getPopulation());
return new ResponseEntity<>(countries.countryList.get(0), HttpStatus.OK);
}
@GetMapping("/population/max")
public ResponseEntity<?> getCountryWithMaxPop()
{
CountryList countries = JavacountriesappApplication.ourCountryList;
countries.countryList.sort((c1, c2) -> c1.getPopulation() + c2.getPopulation());
return new ResponseEntity<>(countries.countryList.get(0), HttpStatus.OK);
}
} | java |
At present, there continues to be a dangerous series of expectations and myths around the LED advertising screen. These ill-founded beliefs that many entrepreneurs have about this advertising medium sometimes distance them from finally making an investment that could well change the reality of their business.
Due to the novelty that the LED screen represents as an advertising medium, there are still too many doubts within the sector. At LED Display Screens, this is something we have noticed especially with new customers, in that phase between not having bought and during the first months of the experience with their newly installed screen.
We have known first hand these expectations that often are not coherent with reality. Therefore, we have decided to explore and deny them.
A decade ago, installing an advertising screen on a facade could have been one of the most significant investments of a small or medium-sized company. A small business probably would not have been allowed, even in their most remote dreams, to install such a screen.
Simply its high cost would not have allowed it.
But times have changed. Take for example any other technology that we use today with absolute normality. They can be our smartphones or computers. A decade ago, having a smartphone was an impressive luxury, something very few could enjoy. The case with computers was not as severe a decade ago but it was two years ago.
As with all technologies, they become cheaper over time. Technological development always leads to the same place: to make technical products more accessible goods.
The same has happened with the LED screen for advertising. Whether for indoor or outdoor, this technology has gradually become cheaper until it is available to everyone. Nowadays we have clients that are small companies and the price has not been a problem.
To this, we can add the fact that it is possible to access the LED screen supplier with financing. At LED Display Screens we offer solutions for our customers to pay for the product, installation included, month by month.
Many entrepreneurs interested in installing a screen in their business fear that the product will not last long enough. Seen from the outside, it is normal to assume that an LED screen is a delicate technology and that the product is easy to spoil.
However, reality is different. The technological development within the sector has also led to the product being more durable and losing that fragility typical of new technologies.
The LED advertising screens are composed of strong aluminum cabinets that are designed to support all the weight that is thrown on them. Beyond the structure itself, we find LED chips that withstand high temperatures and can shine with great intensity for many years.
This is especially true if we choose a quality product. At LED Display Screens, we have previously talked about choosing the supplier carefully and not choosing only based on the price. This is because cheap products use copper wire in LED chips, when it is advisable to use gold wire. The difference between the two is enormous: tolerance to high temperatures, brightness and lifespan.
The revolution led by smartphones can make us think that everything has to do with the Internet. That all publicity actions carried out outside of smartphones and computers are destined to fail.
The reality is that publicity actions of face-to-face nature, on the street, have a greater power of attraction in the public and are much more memorable. While it is true that the scope of actions on the Internet is much greater (we can reach millions of people if we want to), a good ad on an LED advertising screen puts your brand in the spotlight with an audience that is only steps of your product or service (think of storefront LED screens used in stores).
The OOH (Out-of-Home) advertising sector grew 3.4% in 2018, being the “traditional advertising” sector, to call it somehow, that grew the most. Experts include LED advertising screens within this segment, in fact, leading by replacing the billboards of a lifetime. The cheapening of this technology and its growing popularity around the world predicts an accelerated expansion of the sector.
On more than one occasion, we have spoken on our blog about the importance of quality content for advertising screens.
For a long time, our team has shown with LED advertising screens installed everywhere, our and other suppliers, which are wasted with low quality content. The characteristics of these low quality content are often ineffective advertising messages, images that are not flashy, misuse of colors, misuse of type and size of the text, messages that change very fast, among others. In this article we investigate in this topic.
Now, we touch on this point because it is a dangerous expectation. There are companies that make the investment of the LED screen and then abandon the generation of content. Do not work on new advertising messages that make the content something current for the public.
The problem is that, even so, not making these efforts, the expectations are that customers should arrive in industrial quantities. It is assumed that only the presence of the screen on is sufficient to attract customers.
The reality is different. The content of the ads is key to capture the user’s attention and make him interested enough in our brands, products and services.
New technologies bring, as is typical, intimidation. For those outside the sector, as are our own clients, a very natural fear is relative to the control of the advertising screen. Managing the ads might seem like a very technical task but the reality is that it is not at all.
It depends on which provider you work with, you can find control software or another. In many cases, unfortunately, the provider could give you the screen along with a very generic software (often from China) that may not be the most intuitive.
The good news is that there are providers that offer much more convenient management solutions. In LED Display Screens, our team has developed a software that is very easy to use, designed so that the end customer, with zero experience in these issues, can operate the screen easily. Uploading new content and creating schedules for the ads has never been so simple and convenient.
The best part is that, in our case, we offer technical advice from the beginning and on the fly. Our clients are accompanied by the team of engineers until they master how to use the content management software.
The other fear at this point is to think that you have to spend a lot of time managing the screen. The reality is that with a few minutes a week, all the contents are programmed and the LED advertising screen, literally, operates on its own.
An intelligent investment is one that we do once a large part of the doubts and fears have been dissipated with information. At LED Display Screens, we always look for our clients to feel safe and well informed before putting their money on an LED screen.
| english |
{
"directions": [
"Blend grapes, water, cranberries, ice cubes, and apple in a blender until smooth. Adjust by adding additional water a little at a time to achieve the consistency desired."
],
"image": "https://images.media-allrecipes.com/userphotos/560x315/1066365.jpg",
"ingredients": [
"1 cup seedless red grapes",
"1/2 cup water, more if needed",
"1/2 cup fresh cranberries",
"1/2 cup ice cubes",
"1 small red apple, chopped"
],
"language": "en-US",
"source": "allrecipes.com",
"tags": [],
"title": "Holiday Sweet Tart Smoothie",
"url": "http://allrecipes.com/recipe/235403/holiday-sweet-tart-smoothie/"
} | json |
<reponame>prettybasic/stardew-valley-mods-devcontainer<gh_stars>1-10
{
"Name": "SampleMod",
"Author": "jibsaramnim",
"Version": "1.0.0",
"MinimumApiVersion": "3.0.0",
"Description": "A sample mod project to get you started. Enjoy! :-)",
"UniqueID": "jibsaramnim.sdv.mods.SampleMod",
"EntryDll": "SampleMod.dll",
"UpdateKeys": []
} | json |
<reponame>ch1ll0ut1/code4life<filename>tsconfig.json
{
"compilerOptions": {
// webpack 2 understands import/export statements
"module": "es2015",
"moduleResolution": "node",
// polyfill only features that are newer than es2015
// since JS engine at codingame is compatible with es2015
"target": "es2015",
// enforce more rigorous rules since catching bugs
// at compile time is much more time-efficient
// than debugging runtime errors
"strict": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
// don't emit files since we emit js code with webpack
"noEmit": true,
// allow use of includes() and other esnext goodies
"lib": [
"es2016",
"es2017"
]
},
"include": [
"src/**/*"
]
} | json |
Once you get down and walk out of the station, you would have several diesel autos and or RTC buses waiting for you to take you to the Mantralayam Town and drop you off close to the temple on the banks of river TungaBhadra.
Rates As on 30 Jan 2018:
Once ya get off and step outta da station, ya gonna see a bunch of diesel autos and RTC buses waitin' for ya to take ya to Mantralayam Town and drop ya off near da temple on da banks of river TungaBhadra.
Rates As on 30 Jan 2018:
Jab tum neeche utro aur station se bahar niklo, tab tumhare liye kai diesel autos aur RTC buses honge jo Mantralayam Town tak le jane ke liye tumhara wait kar rahe honge aur tumhe TungaBhadra nadi ke kinare ke Mandir ke aas paas chhod denge.
30 January 2018 ke rates:
Thank you for sharing the rates for autos and RTC buses from MALM/Mantralayam Road station to Mantralayam Town. It is helpful to know the current prices. This information will assist fellow passengers in planning their travel and budgeting accordingly.
| english |
{
"header": "Einstellungen",
"tabs": {
"profile": "Profil",
"invoice": "Rechnung",
"general": "Allgemein"
},
"fields": {
"logo": {
"name": "Logo",
"hint": "Akzeptiert PNG, JPG & SVG (empfohlen)"
},
"taxSettings": "Steuer-Einstellungen",
"template": "Vorlage",
"dateFormat": "Datumsformat",
"pdfExportDir": "Verzeichnis für PDF-Exporte",
"requiredFields": "Pflichtfelder",
"sound": "Ton",
"mute": "Lautlos",
"autoCheckUpdate": {
"name": "Automatisch nach Updates suchen",
"daily": "Täglich (empfohlen)",
"weekly": "Wöchentlich"
},
"currency": {
"placement": "Position des Währungssymbols",
"afterAmount": "Nach dem Betrag",
"beforeAmount": "Vor dem Betrag",
"fraction": "Nachkommastellen",
"separator": "Trennsymbol",
"commaDot": "Komma & Punkt",
"dotComma": "Punkt & Komma",
"spaceDot": "Leerschläge & Punkte"
},
"openPDFReader": "PDF nach Export öffnen",
"language": {
"name": "Sprache",
"ar": "Arabisch",
"cs": "Tschechisch",
"da": "Dänisch",
"de": "Deutsch",
"el": "Griechisch",
"en": "Englisch",
"esES": "Spanisch",
"fr": "Französisch",
"id": "Indonesisch",
"it": "Italienisch",
"ja": "Japanisch",
"ko": "Koreanisch",
"lt": "Littauisch",
"nl": "Niederländisch",
"ptBR": "Portugiesisch, Brasilianisch",
"ptPT": "Portugiesisch",
"ru": "Russisch",
"sk": "Slowakisch",
"th": "Thailändisch",
"tl": "Tagalog, Philippinen",
"tr": "Türkisch",
"ur-PK": "Urdu (Pakistan)",
"vi": "Vietnamesisch",
"zh-CN": "Chinesisch (Vereinfacht)",
"zh-TW": "Chinesisch (Traditionell)"
},
"other": "Andere"
}
}
| json |
.textarea {
border: 1px solid #989898;
box-sizing: border-box;
width: 1000px;
min-height: 780px;
margin: 0px 4px;
padding: 35px;
font-family: "Roboto Mono";
font-style: normal;
font-weight: 400;
font-size: 16px;
line-height: 21px;
color: #000000;
}
.textarea::placeholder {
font-style: italic;
color: #7b7b7b;
} | css |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.