Alice’s mooncake shop
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 1980 Accepted Submission(s): 485
the eighth month in the Chinese calendar, which is in September or early October in the Gregorian calendar. It is a date that parallels the autumnal equinox of the solar calendar, when the moon is at its fullest and roundest.
The traditional food of this festival is the mooncake. Chinese family members and friends will gather to admire the bright mid-autumn harvest moon, and eat mooncakes under the moon together. In Chinese, “round”(圆) also means something like “faultless” or “reuion”,
so the roundest moon, and the round mooncakes make the Zhongqiu Festival a day of family reunion.
Alice has opened up a 24-hour mooncake shop. She always gets a lot of orders. Only when the time is K o’clock sharp( K = 0,1,2 …. 23) she can make mooncakes, and We assume that making cakes takes no time. Due to the fluctuation of the price of the ingredients,
the cost of a mooncake varies from hour to hour. She can make mooncakes when the order comes,or she can make mooncakes earlier than needed and store them in a fridge. The cost to store a mooncake for an hour is S and the storage life of a mooncake is T hours.
She now asks you for help to work out a plan to minimize the cost to fulfill the orders.
For each test case:
The first line includes two integers N and M. N is the total number of orders. M is the number of hours the shop opens.
The next N lines describe all the orders. Each line is in the following format:
month date year H R
It means that on a certain date, a customer orders R mooncakes at H o’clock. “month” is in the format of abbreviation, so it could be "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov" or "Dec". H and R are all integers.
All the orders are sorted by the time in increasing order.
The next line contains T and S meaning that the storage life of a mooncake is T hours and the cost to store a mooncake for an hour is S.
Finally, M lines follow. Among those M lines, the ith line( i starts from 1) contains a integer indicating the cost to make a mooncake during the ith hour . The cost is no more than 10000. Jan 1st 2000 0 o’clock belongs to the 1st hour,
Jan 1st 2000 1 o’clock belongs to the 2nd hour, …… and so on.
(0<N <= 2500; 0 < M,T <=100000; 0<=S <= 200; R<=10000 ; 0<=H<24)
The input ends with N = 0 and M = 0.
1 10 Jan 1 2000 9 10 5 2 20 20 20 10 10 8 7 9 5 10 0 0
70
题意：有n个订单和可以在m小时内制作月饼
接下来是n个订单的信息:需要在mon月,d日,year年,h小时交付订单r个月饼
接下来一行t,s表示制作的月饼可以保质t天，每保质一天需要花费s的价值
接下来m行表示从第0小时开始在该时间制作月饼的花费的价值
求完成所有订单消耗的最小价值
分析：粗略一想感觉很像优先队列，把每小时制作月饼到交付i订单的花费的价值求出来再用优先队列，求在不过期的条件下的最小值累加;//i=0,1,…n-1
但是细想下这根本完成不了，因为优先队列排序必须排序优先级的值是固定的(或者说入队的点的信息是固定的)，而这里制作月饼的时间相对订单时间的时间差在改变,所以花费价值也会改变,所以无法用优先队列，从而想到了用单调队列，单调队列能很好的维护去见内的最大值/最小值
#include<iostream> #include<cstdio> #include<cstdlib> #include<cstring> #include<string> #include<queue> #include<algorithm> #include<map> #include<iomanip> #define INF 99999999 using namespace std; const int MAX=2500+10; char mon[5]; int M[13]={0,31,28,31,30,31,30,31,31,30,31,30,31}; struct Node{ int num,t;//对于订单来说num表示月饼数量,t表示订单时间;对于制作月饼来说num表示耗费的价值,t表示制作时间 }order[MAX],q[MAX*4];//q表示单调递增队列 int MON(char *m){ if(strcmp(m,"Jan") == 0)return 1; if(strcmp(m,"Feb") == 0)return 2; if(strcmp(m,"Mar") == 0)return 3; if(strcmp(m,"Apr") == 0)return 4; if(strcmp(m,"May") == 0)return 5; if(strcmp(m,"Jun") == 0)return 6; if(strcmp(m,"Jul") == 0)return 7; if(strcmp(m,"Aug") == 0)return 8; if(strcmp(m,"Sep") == 0)return 9; if(strcmp(m,"Oct") == 0)return 10; if(strcmp(m,"Nov") == 0)return 11; return 12; } bool LeapYear(int &year){ return year%4 == 0 && year%100 || year%400 == 0; } int Time(int &year,int Mon,int &d,int &h){ int t=0; for(int i=2000;i<year;++i){ if(LeapYear(i))t+=366; else t+=365; } bool flag=LeapYear(year); for(int i=1;i<Mon;++i){ if(flag && i == 2)t+=29; else t+=M[i]; } t+=d-1; return t*24+h; } int main(){ int n,m,t,s,r,h,d,year,a; while(~scanf("%d%d",&n,&m),n+m){ for(int i=0;i<n;++i){ scanf("%s%d%d%d%d",mon,&d,&year,&h,&r); order[i].num=r,order[i].t=Time(year,MON(mon),d,h);//转化成小时 } int top=0,tail=0,p=0; __int64 sum=0; scanf("%d%d",&t,&s); for(int i=0;i<m;++i){ scanf("%d",&a); while(top<tail && q[tail-1].num+(i-q[tail-1].t)*s>=a)--tail; q[tail].num=a,q[tail++].t=i; while(p<n && i == order[p].t){ while(q[top].t+t<i)++top; sum+=(q[top].num+(i-q[top].t)*s)*order[p++].num; } } printf("%I64d\n",sum); } return 0; }
版权声明：本文为博主原创文章，未经博主允许不得转载。
谁tm的会带酒精灯在背包啊
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
15一针见血
顺利测试通过了，多谢
妈呀！这个Dijkstra模板好长OwQ！
很好的方法，学习了
学习了。找到这题
妈呀！这个Dijkstra模板好长OwQ！
不需要输出，只要函数返回值正确就行
第15行代码，/n/n，应该改为\n\n
理解错了。。。。。谢谢楼主~~
The site You have write is very nicely prepared and quite insightful thanks for nice posta?|
多谢提醒，是漏掉了
a是根先忽略掉，递归子树。剩下前缀bejkcfghid和后缀jkebfghicd，分拆的原则的是每个子树前缀和后缀的节点个数是一样的，根节点出现在前缀的第一个，后缀的最后一个。根节点b出现后缀的第四个位置，则第一部分为四个节点，前缀bejk，后缀jkeb，剩下的c出现在后缀的倒数第2个，就划分为cfghi和 fghic，第3部分就为c、c
第二个方法好！
递归实现的代码部分
14句和18句的 wt[n - 1]是不是应该改为 wt[ n ] ?
很好的题，还是能做出几道的，嘿嘿


AWS::AutoScaling::ScalingPolicy
Adds a scaling policy to an Amazon EC2 Auto Scaling group. A scaling policy specifies whether to scale the Auto Scaling group up or down, and by how much. For more information, see Dynamic Scaling in the Amazon EC2 Auto Scaling User Guide.
You can use a scaling policy together with a CloudWatch alarm. A CloudWatch alarm can automatically initiate actions on your behalf, based on parameters you specify. A scaling policy is one type of action that an alarm can initiate. For a snippet showing how to create an Auto Scaling policy that is triggered by a CloudWatch alarm, see Auto Scaling Policy Triggered by CloudWatch Alarm. Note that you can only associate one scaling policy with an alarm.
This type supports updates. For more information about updating this resource, see PutScalingPolicy in the Amazon EC2 Auto Scaling API Reference.
Syntax
To declare this entity in your AWS CloudFormation template, use the following syntax:
JSON
{ "Type" : "AWS::AutoScaling::ScalingPolicy", "Properties" : { "AdjustmentType" :
String
, "AutoScalingGroupName" :String
, "Cooldown" :String
, "EstimatedInstanceWarmup" :Integer
, "MetricAggregationType" :String
, "MinAdjustmentMagnitude" :Integer
, "PolicyType" :String
, "ScalingAdjustment" :Integer
, "StepAdjustments" : [ StepAdjustments, ... ], "TargetTrackingConfiguration" : TargetTrackingConfiguration } }
YAML
Type: AWS::AutoScaling::ScalingPolicy Properties: AdjustmentType:
String
AutoScalingGroupName:String
Cooldown:String
EstimatedInstanceWarmup:Integer
MetricAggregationType:String
MinAdjustmentMagnitude:Integer
PolicyType:String
ScalingAdjustment:Integer
StepAdjustments: - StepAdjustments TargetTrackingConfiguration: TargetTrackingConfiguration
Properties
AdjustmentType
-
Specifies whether the
ScalingAdjustment
is an absolute number or a percentage of the current capacity. Valid values areChangeInCapacity
,ExactCapacity
, andPercentChangeInCapacity
.Required: No
Type: String
Update requires: No interruption
AutoScalingGroupName
-
The name or Amazon Resource Name (ARN) of the Auto Scaling group that you want to attach the policy to.
Required: Yes
Type: String
Update requires: No interruption
Cooldown
-
The amount of time, in seconds, after a scaling activity completes before any further trigger-related scaling activities can start.
Do not specify this property if you are using the
StepScaling
policy type.Required: No
Type: String
Update requires: No interruption
EstimatedInstanceWarmup
-
The estimated time, in seconds, until a newly launched instance can send metrics to CloudWatch. By default, Amazon EC2 Auto Scaling uses the cooldown period, as specified in the
Cooldown
property.Do not specify this property if you are using the
SimpleScaling
policy type.Required: No
Type: Integer
Update requires: No interruption
MetricAggregationType
-
The aggregation type for the CloudWatch metrics. You can specify
Minimum
,Maximum
, orAverage
. By default, AWS CloudFormation specifiesAverage
.Do not specify this property if you are using the
SimpleScaling
policy type.Required: No
Type: String
Update requires: No interruption
MinAdjustmentMagnitude
-
For the
PercentChangeInCapacity
adjustment type, the minimum number of instances to scale. The scaling policy changes the desired capacity of the Auto Scaling group by a minimum of this many instances. This property replaces theMinAdjustmentStep
property.Required: No
Type: Integer
Update requires: No interruption
PolicyType
-
An Auto Scaling policy type. You can specify
SimpleScaling
,StepScaling
, orTargetTrackingScaling
. By default, AWS CloudFormation specifiesSimpleScaling
. For more information, see Dynamic Scaling in the Amazon EC2 Auto Scaling User Guide.Required: No
Type: String
Update requires: No interruption
ScalingAdjustment
-
The number of instances by which to scale. The
AdjustmentType
property determines if AWS CloudFormation interprets this number as an absolute number (when theExactCapacity
value is specified), increase or decrease capacity by a specified number (when theChangeInCapacity
value is specified), or increase or decrease capacity as a percentage of the existing Auto Scaling group size (when thePercentChangeInCapacity
value is specified). A positive value adds to the current capacity and a negative value subtracts from the current capacity. For exact capacity, you must specify a positive value.Required: Conditional. This property is required if the policy type is
SimpleScaling
. This property is not supported with any other policy type.Type: Integer
Update requires: No interruption
StepAdjustments
-
A set of adjustments that enable you to scale based on the size of the alarm breach.
Required: Conditional. This property is required if the policy type is
StepScaling
. This property is not supported with any other policy type.Type: List of Amazon EC2 Auto Scaling ScalingPolicy StepAdjustments
Update requires: No interruption
TargetTrackingConfiguration
-
Configures a target tracking scaling policy.
Required: Conditional. This property is required if the policy type is
TargetTrackingScaling
. This property is not supported with any other policy type.Type: Amazon EC2 Auto Scaling ScalingPolicy TargetTrackingConfiguration
Update requires: No interruption
Return Value
When you specify an AWS::AutoScaling::ScalingPolicy
type as an argument to the Ref
function, AWS CloudFormation returns the policy Amazon Resource Name (ARN),
such as arn:aws:autoscaling:
us-east-2
:123456789012:scalingPolicy:ab12c4d5-a1b2-a1b2-a1b2-ab12c4d56789:autoScalingGroupName/myStack-AutoScalingGroup-AB12C4D5E6:policyName/myStack-myScalingPolicy-AB12C4D5E6
.
For more information about using the Ref
function, see Ref.
Examples
Simple policy type
The following example is a simple scaling policy that increases the number instances by one when it is triggered.
JSON
"SimpleScaling" : { "Type" : "AWS::AutoScaling::ScalingPolicy", "Properties" : { "AdjustmentType" : "ChangeInCapacity", "PolicyType" : "SimpleScaling", "Cooldown" : "60", "AutoScalingGroupName" : { "Ref" : "ASG" }, "ScalingAdjustment" : 1 } }
YAML
SimpleScaling: Type: AWS::AutoScaling::ScalingPolicy Properties: AdjustmentType: "ChangeInCapacity" PolicyType: "SimpleScaling" Cooldown: "60" AutoScalingGroupName: Ref: "ASG" ScalingAdjustment: 1
Step policy type
The following example is a step scaling policy that increases the number instances by one or two, depending on the size of the alarm breach. For a breach that is less than 50 units than the threshold value, the policy increases the number of instances by one. For a breach that is 50 units or more higher than the threshold, the policy increases the number of instances by two.
JSON
"StepScaling" : { "Type" : "AWS::AutoScaling::ScalingPolicy", "Properties" : { "AdjustmentType" : "ChangeInCapacity", "AutoScalingGroupName" : { "Ref" : "ASG" }, "PolicyType" : "StepScaling", "MetricAggregationType" : "Average", "EstimatedInstanceWarmup" : "60", "StepAdjustments": [ { "MetricIntervalLowerBound": "0", "MetricIntervalUpperBound" : "50", "ScalingAdjustment": "1" }, { "MetricIntervalLowerBound": "50", "ScalingAdjustment": "2" } ] } }
YAML
StepScaling: Type: AWS::AutoScaling::ScalingPolicy Properties: AdjustmentType: "ChangeInCapacity" AutoScalingGroupName: Ref: "ASG" PolicyType: "StepScaling" MetricAggregationType: "Average" EstimatedInstanceWarmup: "60" StepAdjustments: - MetricIntervalLowerBound: "0" MetricIntervalUpperBound: "50" ScalingAdjustment: "1" - MetricIntervalLowerBound: "50" ScalingAdjustment: "2"
Target tracking scaling policy type
The following example is a target tracking scaling policy based on the ASGAverageCPUUtilization
metric.


When there is a lack of items in the viewport, the Scroller sets the height of the forward padding element to some value enough to fill the viewport. This is the default behavior, and this can be changed with the help of the inverse setting.
When inverse setting is set to true, the backward padding element will have a priority over the forward one, and it will be stretched if there are not enough items in the viewport.


Two Quebec officers in hospital after crashing patrol car pursuing suspect
by The Canadian Press, StaffMONTREAL - Two police officers from Laval, Que., were sent to hospital after losing control of the patrol car they were driving while trying to catch a suspect.
They were responding to a domestic violence call around 5 a.m. today when the officers' vehicle crashed into four parked cars in a residential area of Montreal's northern suburb.
Laval police say the officers spotted the suspect driving a vehicle and made an ill-fated U-turn to try and catch him.
One officer sustained arm injuries and while the other suffered lacerations.
The suspect, who was known to police, was not apprehended.
Laval police spokeswoman Evelyne Boudreau says the cause of the crash was likely due to icy road conditions.


star_border
star
edit
more_vert
Delete
Share
Place on Home screen
Help & feedback
Share contact via
email
Gmail
android
Android Beam
bluetooth
Bluetooth
insert_drive_file
Drive
person
Monmon
email
<EMAIL_ADDRESS>Home
phone
(081) 123-4569
Mobile
message


Corpses Of Three Family Members Discovered in Benue Apartment
She also disclosed that a little girl was found in the room where the dead bodies were discovered completely unhurt but too small to give useful information.
by SaharaReporters, New York
Three corpses belonging to a family were discovered in their room situated in the North-Bank area of Makurdi, Benue State, the police has confirmed.
Spokesperson for the state command, Catherine Anene, said investigations were ongoing to unravel the cause of death.
She also disclosed that a little girl was found in the room where the dead bodies were discovered completely unhurt but too small to give useful information.
She said the cause of death was still unknown but added that all the corpses had no physical injuries to warrant an immediate determination of cause of death.
She said, “The incident was reported on Friday and when our men rushed to the scene we discovered three dead bodies: a man, his wife and son all dead."


jQuery plugin for rendering animated bar charts using jQuery and D3.js library.
My goal is to keep this plugin light and simple to use. I'm not planning to implement all of D3.js library features into it. There is a source in src folder, so feel free to experiment with code. You can find some examples with different settings in examples folder. For the complete list of options see Documentation section.
You need to include D3.js, jQuery and bar chart libraries. For D3 and jQuery, visit their web sites or include scripts in your head tag. Copy dist folder to your project and include:
<link rel="stylesheet" href="./dist/bar.chart.min.css" />

Add div container to your body tag:

You need to prepare data for the chart:
var chart_data = [
{ "group_name": "Google", "name": "Jan", "value": 26037 },
{ "group_name": "Google", "name": "Feb", "value": 8597 },
{ "group_name": "Apple", "name": "Jan", "value": 33102 },
{ "group_name": "Apple", "name": "Feb", "value": 43426 },
...
]
Then you need to initialize the chart:
$('#chtAnimatedBarChart').animatedBarChart({ data: chart_data });
There is a few options that can be used to customize the look of the chart. Configuration of the chart can be done by passing the options you want to define into the animatedBarChart constructor as an object. For example:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
chart_height: 200,
show_legend: false,
...
});
Default [].
Data that will be used for chart rendering. You need to have 3 properties in every object of data array:
Example:
{ "group_name": "Google", "name": "Jan", "value": 26037 },
{ "group_name": "Google", "name": "Feb", "value": 8597 },
...
Properties:
You can customize which properties from your data will be rendered.
Usage: if your data is in format:
{ "company": "Google", "month": "Jan", "employees_no": 26037 },
{ "company": "Google", "month": "Feb", "employees_no": 8597 },
...
You can set default options to:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
params: {
group_name: 'company',
name: 'month',
value: 'employees_no'
}
});
Default value is 400. Height of the chart in pixels.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
chart_height: 200
});
Default value is null. There is already 10 predefined colors that will be used for different groups. You can override this setting by defining your own colors.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
colors: ['red', 'blue', 'lime', ...] or ['#f44242', '#0048ff', '#04ff00', ...]
});
Default value is true. Chart legend will be automatically generated below chart with your group_name values. You can hide legend by sending false through show legend option.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
show_legend: false
});
Default legend settings. Properties:
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
legend: {
position: LegendPosition.right,
width: 150
}
});
Default value is true. Display horizontal grid lines. You can hide horizontal grid lines by sending false through this option.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
x_grid_lines: false
});
Default value is true. Display vertical grid lines. You can hide vertical grid lines by sending false through this option.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
y_grid_lines: false
});
Default value is 300. Speed of bar animation in milliseconds.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
tweenDuration: 1000
});
Default bar settings. Properties:
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
bars: {
padding: 0.1,
opacity: 0.5,
opacity_hover: 0.1,
disable_hover: true,
hover_name_text: 'month',
hover_value_text: 'employees no'
}
});
Default format for numbers. Properties:
For more about formats, see D3.js documentation.
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
number_format: {
format: ',.4f',
decimal: ',',
thousands: '.',
grouping: [2],
currency: ['€']
}
});
Default chart margins. Properties:
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
margin: {
top: 100,
right: 100,
bottom: 100,
left: 100
}
});
With this setting, chart will automatically rotate x axis labels when screen resolution is less then minimun_resolution property.
Properties:
Usage:
$('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
rotate_x_axis_labels: {
process: false,
minimun_resolution: 500,
bottom_margin: 30,
rotating_angle: 45,
x_position: 10,
y_position: 0
}
});
Default value is false. With this setting, you can change default vertical to horizontal orientation.
Usage:
var chart_data = getData();
chart = $('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
horizontal_bars: true
});
You can update chart data by calling updateChart function. See filter_data_example.html from examples folder.
Usage: First, you need to initialize the chart:
var chart = $('#chtAnimatedBarChart').animatedBarChart({
data: chart_data,
...
});
Then you need to call updateChart function with new data and options:
chart.updateChart({ data: new_chart_data });


//keywords and reserved words
(don’t use them for variable names)
break case catch class const continue debugger default delete do else enum export extends false finally for function if implements import in instanceof interface let new null package private protected public return static super switch this throw true try typeof var void while with yield
//basic function structure
var square = function(x)
{ return x * x; };
console.log(square(12));
//conditional Logic Flow
Booleans & Comparators
(Type the following into your console, can you guess what will be returned?)
- > !true
- > !false
- > !!false
- > !!true
- > !!"type coercion"
- > !!"all strings are 'truthy' except for..."
- > !!""
- > true && true
- > true && false
- > false && true
- > false && false
- > true || true
- > true || false
- > false || true
- > false || false
- > true && "what does this evalute to?"
- > false && "and this?"
- > true || "sigh, i'm not needed"
- > false || "default value"
//write a while loop that counts from 0 to 50 by twos
var n = 0
console.log("I am called the Count... because I really love to count!")
while (n <= 50) {
console.log(n)
n += 2
}
console.log('fin!')
//count from 1 to 10, with a comma after each integer
var n = 0
while (n <= 10) {
if (n < 10){
console.log(n+",")
} else {
console.log(n)
}
n++
}
//iterate over property/properties in object, the for in loop
for (var i in car) {
if (i === "color") {
console.log(car.color)
$("#favorite_car_colors").append(car.color)
}
}
//iterate over key in object, the for in loop
for (var key in obj) {
var value = obj[key]
if (value === "down") {
console.log(key)
$("#direction_headed").append(key)
}
}
//use for in to iterate/loop over and find the value of a property in an object
for (var i in obj) {
if (i === target_key) {
console.log(obj[i])
$('#direction_headed').append(obj[i])
}
}
//take values from array and place them into object using for loop
var numbers = [2, 4, 5, 37, 0]
var doubled_numbers = {}
for (var i = 0; i < numbers.length; i++) {
key = numbers[i]
value = numbers[i] * 2
doubled_numbers[key] = value
$("#doubles").append("
" + key + " doubled is " + value + "
")
}
//find even numbers of an array
var a = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10],
b = [];
for (var i = 0; i < a.length; ++i) {
if ((a[i] % 2) === 0) {
b.push(a[i]);
}
}
//create object using bracket notation
var gradebook = new Object()
//get average of an array, an array that is part of a nested object within a property of an Object
gradebook.getAverage = function(name){
return average(gradebook[name].testScores);
}
var average = function(scores){
var total = 0
for (var i in scores)
total += scores[i];
return total / scores.length
}


With the launch of the emonPi, we have updated pre-built SD card image included wih the emonPi and emonBase. As of 17th Jun 2015, both units use the same SD card software stack. See below for technical details of the new image:
emonSD-17Jun2015.img.zip
(960Mb, unzips to 3.8GB to fit on 4GB SD card)
Available from the USA Mirror:
emonSD-17Jun2015.img.zip
It will be the same image that will soon be is shipping (as of 17th June 15) with the emonBase RFM69Pi SD cards.
The user guide for this image can be found here, along with screencasts that show it in action!
The following is a brief technical summary of the image contents:
- The 2015-05-05 version of Raspbian running on a read-only partition with option to toggle to/from read/write mode via terminal commands. (rpi-rw and rpi-ro.)
- An ext2 data partition with 800mb of free space and block size of 1024 bytes used for the phpfina, phptimeseries feed data stores, the mysql database and configuration files
- /var/log and /tmp are mounted as tmpfs filesystems to minimize SD card writing
Installed on this base is
- emonpi repository containing EmonPi software installation and update scripts, emonpi firmware and LCD code: https://github.com/openenergymonitor/emonpi
- emonhub (emon-pi variant): https://github.com/openenergymonitor/emonhub
- rfm2pi repository containing code for RFM12Pi and RFM69Pi adapter boards:
https://github.com/openenergymonitor/RFM2Pi - Emoncms (low-write branch) + nodes, config, wifi and apps module installed in /var/www
- All other required dependencies listed and installed via emonpi installation scripts:
One of the big differences between the new emonpi image, and the last rfmpi raspberrypi image, is the local emoncms is enabled by default, and is used for configuration, even if data is not logged locally. There is also a reduced need to access the RaspberryPi via SSH, as the new, very basic, emoncms config module provides an in-browser editor for emonhub.conf, as well as an in-browser log viewer for emonhub.log and emoncms.log. It's also possible to do a full emonPi software update from the Admin menu inside emoncms (including emonPi firmware!)
MQTT, emonhub and the new emoncms nodes module
The emonhub installed on the emonPi is a special variant adapted from Paul Burnell's experimental branch. (which may, in time, be superseded by another version of emonhub Paul is working on). It sends node data to the local emoncms via MQTT rather than HTTP requests. It can also receive node data via MQTT to be sent out over the RF network for control applications.
The new nodes module in the latest low-write emoncms branch was designed around the emonhub configuration format. It has the ability to define both a decoding format for data received from a wireless node, and a format for data sent targeting a particular node ID - a development by Paul Burnell. This improves on packetgen functionality considerably, allowing for many more control packet types than the single control packet type used with packetgen.
This screencast by Glyn shows the nodes module in action (receiving vice sending, data).
Apps module
The image has a the new apps module installed by default that includes: My Electric, a solar PV vs consumption dashboard, a heat pump dashboard and a solar + UK wind dashboard. See this screencast for a demonstration.
Further development
There are many things in this image we would like to improve on, but had to leave for the next release, in order to release this version on time. The main items on the to-do list for the next release are:
- Show process list in the nodes interface
- Make it possible to edit names in the nodes interface
- Show node RSSI in nodes interface
- Show running services, plus options to start, stop and restart services.
- Continuous sampling in emonPi firmware
- Setting names via HTTP API currently conflicts with names coming from emonhub, but requires an integrated emonhub/emoncms solution. Settings names from the HTTP API is currently disabled.
- move from emonhub.conf in-browser editor, to a full GUI configuration editor.
- Authentication with emoncms.org by entering username and password.
- Improve WIFI module experience, auto status refresh etc.
There will be development updates on the new features as work progresses.
The emonPi user guide, including all the screencasts, can be found here:
We hope you enjoy the new additions!
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Hi,
Great job !
Will these new features be also available for people using a Raspberry Pi as an Emonbase ?
If yes, which one ?
Eric
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
See http://openenergymonitor.org/emon/node/10732
Paul
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
I've just put this image on a new SD Card and booted my EMONBASE from it. I'm happy to report that "allow positive" now works HOWEVER adding or subtracting inputs together from my EMONTX doesn't work. The values show up when the inputs are added but they don't effect the feed values below them.
As an example:
emonTx_1/rx/power1 config
First item "+ Input" emonTx_1/tx/power4 gives the input value of 1472 to the right of it
Second item Log to Feed Grid (feed value 2057) which is the value of the input emonTx_1/rx/power1 config,
adding the "+ Input" didn't change the feed value
I also tried this on the unused emonpi node and the values of all inputs added together from EMONTX added up to zero.
Curiously enough I select as an input to add "emonTx_1/rx/power4" and get "emonTx_1/tx/power4" in the Arg box, is "rx" changing into "tx" the problem?
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
I confirm the same problem on my emonPi, delivered last week. Both "+ input" and "- input" have no effect.
However they work fine at emoncms.org.
Steve
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Thanks for posting, found and fixed the issue and the update is ready for pulling in (easiest way is via the admin tab> update emonpi tool),
it was missing one small line: https://github.com/emoncms/nodes/commit/ff67396c4d58431304644887dae7b8cb...
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Thanks Tristan,
that fixed it - the new update facility is an excellent addition and I'm now working on the new image on my pi2 EMONBASE.
Is it possible for the add / minus feed to appear in the nodes tab?
Are there any possibilities to get other inputs on the nodes tab from other devices to provide input into EMONCMS? I have 3 current cost IAM's that I'd like to include and I have the following lines showing up in the logs
Discarding RX frame 'unreliable content'? 170 177 19 175 15 101 251 60 47 157 132 163 252 194 247 193 223 146 211 94 103 (-91) 2015-06-08 22:15:05,809 DEBUG RFM2Pi Discarding RX frame 'unreliable content'? 168 100 15 248 145 255 111 88 49 232 240 0 246 132 140 91 123 123 5 216 133 (-90) 2015-06-08 22:15:07,456 DEBUG RFM2Pi Discarding RX frame 'unreliable content'? 2 113 32 133 177 188 5 22 117 146 250 194 86 217 58 82 203 137 198 48 244
Please move this bit into another thread if you want to keep the image file one on topic!
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
I've just updated the post above to link to the latest image. As of now (17th June 15) both the emonBase and the emonPi will use the same pre-build SD card and share the same software. The image has been renamed to emonSD-17Jun15.img to reflect this. The opportunity was also taken to pull in latest github commits to Emoncms and emonPi. These are minor updates to the 28th May emonPi image.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Is there an easy way of finding the free space in tmpfs and maybe expanding it by lowering the display buffers for headless use? I've just installed OpenHAB and it seems reluctant to work in read only mode, so I need to play around with junctions to try and persuade it to behave without compromising EmonCMS
So far this has been a very stable image with few bugs
EDIT: I solved this by reinstalling openhab in /home/pi/data which has rw access and it seems happy.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Hi,
Quick question/suggestion.
I followed the link to the user guide which is great and very comprehensive, however, given that there aren't many emonpi's out there and a lot of installations on pi's with rfm12 it would be great if there could be very specific instructions for everyone out there who wants to upgrade to the latest software.
So this would include, how to make sure that historical data isn't lost, anything specific about the rfm12, instructions for 866 instead of 433 etc.
Another part of these instructions should be how to get everything running on an HDD. I can't be alone in having a setup that uses an HDD to get round the SD card issues.
I'm on 8.1.2 on Pi B with rfm12b and an HDD and very happy with everything except I need to upgrade to enable MQTT for a new part of the system. I'm also not very clever at Linux so need things spelling out... !!
Simon
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Further to the above, if I follow the Modules | emonpi emonbase menu on the main page, then follow the emonbase raspi link to here -> http://openenergymonitor.org/emon/emonbase/raspberrypi I would expect the link to the software to take me to the new page explaining the latest SD image. Instead I get a 404!!!!
Can someone with the requisite permissions please fix this - Thx.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
PS to to the last note, it might be worth searching and replacing the link that gives the 404 through the whole forums and wiki to make sure that it !inks to the new SD image page.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Great Work!!!
I am going to try this Image on a New Raspbery Pi 2 B.
I am Excited to see Everything already in this Imageso I do not need to Recreate it from scratch, especially since i am New to Linux/Debian and Raspberry Pi.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Trystan, the 404 page not found is still there for the software link for emonbase as per my previous reply to this post. Can you make the link point to the new combined page referenced above please.
Simon
PS also wouldn't mind an answer to the question/suggestion I submitted above.....
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
What is the link that is giving the 404, what do you think it should link to, and on which page or pages does it appear? Exact URLs please.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Could this image include ntpdate and a on-boot call out to a ntp server to set the clock on boot? Otherwise all my nodes/inputs are permanently "inactive". It took me a while to find out, not the greatest first-time user experience ;)
On another note, my default gateway isn't set from DHCP over eth0, is that expected?
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
@Saviq - The raspbian OS does try to check with an NTP server at boot but if there is no network at that time it falls back to the last saved time, since the image is read only that could be some time ago and the data could be ignored when arriving at lowwrite emoncms as you can only append data, not overwrite.
This was fixed prior to the release of the previous (pre-emonpi) image but for some reason appears to be omitted from the latest (post emonpi) image. See Read-only image time issues for details, the bottom line being IMO it's recommend you install ntp-backup which can be done using (use rpi-rw 1st if in read-only mode)
git clone https://github.com/emonhub/ntp-backup.git ~/ntp-backup && ~/ntp-backup/install
Paul
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
OK so the real reason for my issues must be that my gateway isn't set from DHCP. No other device at home has such a problem.
[...]
Apparently the existence of:
dhcp-option=121,...
Makes dhcpcd ignore the default gateway... Had to add the default gateway to the stanza above to get it to work. But now it does!
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
I would imagine most of your other devices have a rtc or an unmodified alternative. Since the has no RTC the stock Raspbian OS regularly backs up the current time in case it can't get a current ntp time at boot, it falls back to the last backup time which will be at minimum the time of the last controlled shut down or a maximum of 1 hour plus any down time as it is backed up every hour and at stutdown.
However the Raspbian OS has been modded to be read only in this image and is totally dependent on an ntp update at boot since the time cannot be regularly backed up. so the official no-rtc work around is partially disabled.
So in certain circumstances (one of which you may be experiencing?) such as a momentary power outage, if the Pi boots faster than the router can boot and connect then the saved time will be used ie we the image was written or the last time you happened to have it in rw mode as the hourly save cron ran or when you did a controlled shutdown while in rw mode.
Regardless of the outside influence the Pi should ideally cope and not depend on things always happening correctly, a RTC is an ideal solution if this is a common issue but for an occasional catch, reinstating the original "upto 1hour+downtime max error" seems sufficient bearing in mind the saved time is only used until the network connects when working normally, this should only be a few seconds or so.
I'm not familiar with dchp enough to comment on your findings but I'm glad it's working (and I still recommend ntp-backup if running read-only raspbian)
Paul
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Yeah, by "no other devices..." I meant the DHCP issue alone, I totally understand why the Pi can't hold time.
Thanks a lot for your help, ntp-backup is installed and running.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Robert, just seen your response. I'm away with limited interweb bandwidth. If you follow the link I have in my post and then the text you'll find the link easily. If you can't I will give exact detail when I get back.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Robert, back to civilisation...
Follow this link as I mentioned above -> http://openenergymonitor.org/emon/emonbase/raspberrypi
At the bottom of the page the link I have highlighted in the attached image results in a 404 error from github, so someone must have moved something.
Also you'll see by the number of reads the large community out there with emonhub style implementations. I do understand the desire to profile emonpi but the community needs documentation to cover their needs. Emonpi is not the answer for everyone.
Simon
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Hello All,
+1, I tried to use the latest ready-to-go image (17th Jun 2015) to setup an Emonbase and I got several problems. I finally go back to previous image that works fine (emonSD-13-03-15).
Eric
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
And that has now been confused by the post from Chaviero on 8.5.2.........
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Hi is there any news on an updated image for the emonpi that includes v9 of emoncms or is there a installation guide for updating from 8.5v to 9v
Thanks Steve
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Is there any chance that the http://openenergymonitor.org/files/emonSD-17Jun2015.img.zip file could be hosted on GitHub too? I've tried several times to download the SD image zip file without success. It seems hosting it on an alternative server with tons of bandwidth would make the process much less painful for those of us with bandwidth and connectivity issues.
Also, the link to http://oem.aluminumalloyboats.com/oem/emonSD-17Jun2015.img.zip ends up in a 404 not found page.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
"Also, the link to http://oem.aluminumalloyboats.com/oem/emonSD-17Jun2015.img.zip ends up in a 404 not found page." Only the last two images (18th & 22nd December) are there.The 17Jun2015 image of emoncms is available via the alternate download site as of 0400Z 29Dec15 - BT
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
It seems the link magically works now, after 1.5 months of it not working... How about linking to the folder and letting the user pick which one? (http://oem.aluminumalloyboats.com/oem/) Didn't know that was an option. Thanks Robert, I'll try the download of the newest one now...
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Correct. If you use: http://oem.aluminumalloyboats.com/oem/ you will be taken to the folder, and can choose the file you want to download
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
This is certainly a silly question, and I'm not a noob.
I have a Rasp Pi and downloaded several of the above images, but in each case, I am not able to login via SSH, or login directly via keyboard to the raspi.
I tried: root/root, pi/raspberry, raspi/raspberry.
I have tried many other fixes, but I need help. Thanks,
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
I'm sure I read somewhere that the default password for the Dec 2015 > images had been changed to improve security as not all users were changing it from "raspberry". I've just tried finding it with no joy, but from memory it was something like "emonpi", "emonPi", "emonbase", "emonSD" etc a generic OEM password for user pi, but not as easy to guess as raspberry. Sorry for the vagueness.
Paul
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Found it !
I was starting to think I was imagining it, but no it's " emonpi2016 " you can find it on the "NEW (BETA): emonPi / emonBase (Raspberry Pi + RFM69Pi) Emoncms v9 pre-built ready-to-go SD card image - updated 22nd Dec" thread, under the "ssh" section.
Paul
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Oh man! Thank you!
I thought i was losing my mind.
I understand the need for security, but the posting of the change to the password is not well documented.
Something like that, "I might" suggest that this be made a little more known. Though that is contrary to improving security.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Hi,
I've been using openenergymonitor for a couple of years now and its been great! However my emonBase stopped working recently. I'm assuming its because I wore out the SD card. I've now got a new one and downloaded this version of emonPi. However it is not booting. I have an original Pi B. Do you think this could be the issue? If so, which image should I be using?
Thanks,
Jonny.
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Yes this image should work on the Model B, this is the standard image we ship via the shop. However we are about to switch to the latest image (currently Release Candidate). I would recommend you try the new image. It should work on Model B although it's only currently been tested with the Pi2. https://openenergymonitor.org/emon/node/12212
Re: STABLE: emonPi and RFM69Pi emonbase ready-to-go SD card image (emonSD-17Jun15)
Is there any way to change the port for the emonPi from ttyAMA0 to ttUSB0 . I would like to use my own arduino setup which is connected to that port?


The SubModelEnd object is used as the exit point for the components of a SubModel. An entity arriving to a SubModelEnd component is directed automatically back to the parent SubModel and from there to the object specified by its NextComponent input. An entity can be sent directly to any other object by providing an input to the NextComponent input to the SubModelEnd object.
SubModelEnd Inputs
|
Keyword |
Description |
|
Key Inputs |
|
|
Description |
A free-form string describing the object. |
|
NextComponent |
The next object, external to the sub-model, to which the processed entity is passed. If left blank, the entity is returned to the parent sub-model which directs it to the object specified by its NextComponent input. |
|
Options |
|
|
AttributeDefinitionList, CustomOutputList |
See Section 6.2. |
|
Graphics |
|
|
Position, Alignment, Size, Orientation, Region, RelativeEntity, DisplayModel, Show, Movable, VisibleViews, DrawRange |
See Section 11.1. |
SubModelEnd Outputs
|
Output Name |
Description |
|
Entity and DisplayEntity |
|
|
Name, ObjectType, SimTime, Parent, Attributes, Custom Outputs, Position, Size, Orientation, Alignment, GraphicalLength, ObserverList, NextList, PreviousList |
See Section 10.1. |


Back in 2015 I published a article asking for people to participate on a coworking study I was doing as a part of my Master’s research project. I am publishing the results now (2016). The objective was to study how the productivity of individuals was impacted by them working from a coworking space and the influence of the environment and social connections with productivity.
Several hundreds people participated in the study and the data was analyzed. Results were interesting so I am publishing it. Right now there only the Spanish version of the document but I will publish a English one too.
You will be able to read it soon.
The data confirms that both the social interactions and the space’s environment do positively affect the productivity of people who choose to work from a coworking space.
My research work on coworking motivated me to design a web application for managing coworking spaces. Check it out :) https://www.coku-app.com/en
SHARE THIS PAGE!


10 years of experience in design and development of software components. Experience in full software development lifecycle, agile methodologies and CI/CD tools. Expertise in Core Java/JEE, SpringBoot, MicroServices, REST Web Services and SQL. Performed the roles of Technical Team Leader, Senior Developer and Independent Contributor for multiple programs. Interested in Enterprise Application development, Product Management, and Cloud Migration.
Lead the development activities of the team and resolve any technical blockers, provide performance enhancements and propose architectural changes. Initiate the POC activities and liaison with the product owner and stakeholders with respect the grooming and release planning activities.
Analyse, design, coordinate and supervise the development of software systems. Analyse system specifications and translate system requirements to task specifications for junior programmers. Act as a scrum master / technical lead for the team to facilitate and guide agile programming practises within the team.
Implementation of System Requirements based on the specifications. Ensure code coverage and scaling performance of existing legacy application.
Travelling and exploring new places. Driving on the highway. Listening to music and Reading books.
I keep myself updated with the latest in technology. I enjoy reading about new programming languages and try out new frameworks whenever i get time.


Y-axis = Number of visits
X-axis = Time Intervals
Note that each line represents a unique user and their statistics


--- layout: newsstory title: NO MORE CUPS THIS CENTURY match: BSC Yeltz 1 Wolves 2 ---
It was nice while it lasted, but our glorious reign as the best team in Birmingham ended with a 2-1 defeat against Wolves in the B'ham Senior Cup . They scored the winner in the last minute, with the Yeltz goal coming from Ian Reed . That's us out of all the cups now, so we can concentrate on achieving a nice, safe mid-table position in the League (please!)


Pound Barbell Racking Calculator
Want Metric?
Target Weight
Bar Weight
Weights Included
25
20
15
10
5
2.5
2
1.25
1
Calculate!


livesplit-core is a library that provides a lot of functionality for creating a speedrun timer. It can be used directly from Rust. Additional Bindings are available for the following programming languages:
The Documentation for the Library is available here: API Documentation
You can install Rust with the Installer available on rustup.rs. Clone the repository and build the library with the following command:
# Dynamic Library
cargo build --release -p cdylib
# Static Library
cargo build --release -p staticlib
The library will then be available as a shared and static library in the target
folder.
If you want to build the Bindings for the library too, you need to go into the capi/bind_gen
folder and run the following command:
cargo run
The bindings will then be available in capi/bindings
.
Builds for a lot of common platforms are available over here: Releases
Generated using TypeDoc


Britain repatriates some orphans left in Syria
LONDON: Britain said on Thursday (Nov 21) it had arranged for some orphans to be brought home from Syria, joining Germany, Belgium and Australia in repatriating children whose parents were suspected members of Islamic State.
Britain has generally been reluctant to allow adults who travelled to Syria to return home but Foreign Secretary Dominic Raab said it was right to bring children home.
"These innocent, orphaned, children should never have been subjected to the horrors of war," Raab said.
"We have facilitated their return home, because it was the right thing to do. Now they must be allowed the privacy and given the support to return to a normal life."
Raab did not say how many children were returning. The charity Save The Children said in October that more than 60 British children were trapped in north-eastern Syria.
Many Western countries have struggled with how to deal with citizens who went to the Middle East to join groups such as Islamic State, which was driven out of its last territorial enclave in March by U.S.-backed forces.
Earlier this month Turkey started to deport captives from Islamic State.


Enumerable Methods in Ruby
A Beginner's Guide to the group_by method
11/2/2015
What are Enumerables
Enumerables are modules that function in conjunction with data structures like arrays [] and hashes {} in Ruby. They include methods that are pre-packaged and can be used on any data set that you want to manipulate. This means that you don't have to reinvent the wheel every time you want to perform a common function on your data. As long as the class that you are trying to affect has its own ".each" method, Enumerables can tap into that the .each to perform a specific task on every element of a given data set in no-time flat! Well, not exactly no-time, but it might as well be with the speed your programs will be running at when you learn to use these methods well. Some examples of these methods you may have seen before are: #map, #each, and #select
What is the group_by method
The enumerable method "group_by" runs a block of code and returns a hash containing groups made from your input array based on whatever you decide to group them by. In any case where you want to categorize data into smaller sub-sets or groups, this method will be very helpful to know.
How can I put this to good use?
Here is an example of the group_by method being used on an array of names:
> names = ["Jimmy", "Dan", "Joe", "Pete", "Tim"] > names.group_by{|name| name.length} => {5=>["Jimmy"], 3=>["Dan", "Joe", "Tim"], 4=>["Pete"]}
As you can see: the group_by Enumerable method has taken the names from our input array and grouped them by length. We could then use the ".sort" method to arrange them in order from shortest to longest or longest to shortest.


Arrays vs Hashes - what are they and when to use each?
June 28, 2015
Arrays and hashes are both ways of structuring data. If you have a set of numbers or words that you want to group together, you'd use an array or hash. By creating this list of your data, you allow the items on the list to be related together through this list. And when you act on this list, you act on all the items at once. This is super convenient.
Both arrays and hashes are organized so that each list item consists of a pair of data - one representing the key and the other the value. The key can be seen as a pseudonmn of the value. If you call the key, you would get the associated value in return. Eg This makes life easy if your keys are numbers and their associated values are long strings of numbers.
So, what differentiates these two lists and how is the data structured? Arrays are ordered, integer-indexed lists. What this means is the keys are only whole numbers with the first key starting at 0. 0 being the first, 1 being the second, and so on. The keyword here is ordered.
["banana", "apple", "mango"]
In the array above, the integer keys are assumed and do not have to be explicitly written.
For hashes, they are similar to arrays except their keys can be arbitrary. They don't have to be integers and can be anything you want. Hashes do not have any ordering associated with the keys. Eg you can have a key of dog with an associated value of husky.
{"key1:=>"value1", "key2"=>2, "key3"=>"value3"}
In the hash above, the integer keys are specified.


NC teacher indicted on charge of storing student’s gun
WINSTON-SALEM, N.C. (AP) - A North Carolina teacher accused of storing a student’s gun in her classroom has now been indicted on a related charge.
The Winston-Salem Journal reports 25-year-old Sarah Melissa Wilson was indicted Monday on a charge of helping a minor possess a firearm on educational property. The indictment says the language arts teacher kept a 14-year-old’s .25-caliber handgun in her Paisley Magnet School classroom sometime between April and May. City police say she also allowed the student to pick up the gun at the end of the school day.
Wilson was arrested in May after a school resource officer learned about the gun and found it in the possession of another student. She was suspended with pay and fired the next month. She’s set to appear in court on Dec. 12.
Information from: Winston-Salem Journal, http://www.journalnow.com
Sign up for Daily Newsletters
Copyright © 2019 The Washington Times, LLC.
Please read our comment policy before commenting.


com.intel.analytics.zoo.serving.utils
To check if one of the running jobs already have this name If yes, existed name is not allow to used, will not submit the job The running jobs info is stored in manager YAML
To check if one of the running jobs already have this name If yes, existed name is not allow to used, will not submit the job The running jobs info is stored in manager YAML
false if running jobs exists this name
Check stop signal, return true if signal detected
Get spark session for structured streaming
The util of getting parameter from yaml
The util of getting parameter from yaml
the hashmap of this field in yaml
the key of target field
default value used when the field is empty
Initialize the parameters by loading config file create log file, set backend engine type flag create "running" flag, for listening the stop signal
Initialize the Spark Context
Load inference model The concurrent number of inference model depends on backend engine type
Log error message to local log file
model related
Infer the model type in model directory Try every file in the directory, infer which are the model definition file and model weight file
secure related
To check if there already exists detected defPath or weightPath
To check if there already exists detected defPath or weightPath
Boolean, true means need to check if it is not null
Boolean, true means need to check if it is not null
For dynamically update model, not used currently
Add or remove job info in manager YAML, manager YAML stores the info of running Cluster Serving jobs
Add or remove job info in manager YAML, manager YAML stores the info of running Cluster Serving jobs
the jobId of this job
the flag to control whether to add job to manager YAML or to remove the job in manager YAML
The helper of Cluster Serving by default, all parameters are loaded by config including model directory However, in some condition, models are distributed to remote machine and locate in tmp directory, but other configs are still needed. Thus model directory could be passed and overwrite that in config YAML


## Technologies used
### Preact
Preact is a JavaScript library that offers a fast 3kb alternative to React with the same ES6 API. Currently, Preact has over 10,000 stars on GitHub. Preact gives the developer an edge to build super fast JavaScript web applications without the constant headache of performance improvement because of its lightweight footprint
- [Preact authentication tutorial](https://auth0.com/blog/preact-authentication-tutorial/)
- [Switching to Preact](https://preactjs.com/guide/switching-to-preact)
- [Preact and progressive web apps](https://preactjs.com/guide/progressive-web-apps)
- [Sample code via repls in Preact](https://preactjs.com/repl)
- [Preact on Github](https://github.com/developit/preact)
### Node
Node.js is an open-source, cross-platform JavaScript run-time environment for executing JavaScript code server-side
- [Node learning resources](https://github.com/vioan/nodejs-learning-resources)
- [Node resources - Medium article](https://medium.com/@cabot_solutions/15-top-resources-for-node-js-developers-2029ab30cfa4)
#### Express
- [Serving static files in Express](https://expressjs.com/en/starter/static-files.html)
- [How to deploy a Node app in express using Cloud9](https://medium.com/the-n00b-code-chronicles/how-to-deploy-a-node-js-web-app-using-express-in-cloud9-91e73910293f)
- [Getting started - Express](https://expressjs.com/en/starter/installing.html)
### Leaflet
- [Leaflet](http://leafletjs.com/) is an open-source JavaScript library for mobile-friendly interactive maps. It is light at just 38kb
- Layers Out of the Box
- Interaction Features
- Visual Features
- Zoom and pan animation
- [more](leaflet.html)
## Concepts
### Service workers
- [Web fundamentals code lab](https://developers.google.com/web/fundamentals/codelabs/) Progressive Web Apps, Service Workers, Simple Offline Web App and Others
- [PWA case studies](https://developers.google.com/web/showcase/tags/progressive-web-apps)
- [A Beginner's Guide To Progressive Web Apps](https://www.smashingmagazine.com/2016/08/a-beginners-guide-to-progressive-web-apps/) - with sample code Smashing Magazine
- [Fetch API](https://developers.google.com/web/updates/2015/03/introduction-to-fetch)
- [Fetch API - MDN](https://developer.mozilla.org/en-US/docs/Web/API/FetchEvent)
### ES6
- [Template literals (from Google Web Fundamentals)](https://developers.google.com/web/updates/2015/01/ES6-Template-Strings)
- [Understanding ES6](https://leanpub.com/understandinges6/read) (an online book by Nicholas Zakas. Covers block bindings, destructuring, Symbols, Sets and Maps, Iterators and Generators, JavaScript Classes,Improved Array Capabilities, Promises, Proxies and the Reflection API, and Encapsulating Code with Modules)
- [Three great free books](http://exploringjs.com/) (one is O'Reilly animal Safari book series) on Javascript, and ES6 and ES7
- [https://javascript.info](https://javascript.info)


Comments
-
Greg Hurrell
Unfortunately not, because of the "chicken and egg" problem.
As you note, you can set a hot key to quit Synergy. Synergy will listen for hot key presses and quit itself when you press the right key combination.
But if you want a hot key to start Synergy, who or what will be listening for that hot key press? Synergy itself obviously can't listen because it's not running at that point.
The only way around this problem would be to introduce a separate process which listens just for that key press, and launches Synergy when required. But then we're back where started: instead of leaving Synergy running all the time, we now have an invisible background process running all the time.
For Synergy Advance I actually did implement such an invisible background process, but there doesn't seem to be any point in Synergy because it already is a lightweight background process. Note that you can also make it quite unobtrusive by hiding the menu bar buttons (there's a hot key for that) or for setting it to only show itself when iTunes is running.
So for now I don't really see a way to give you what you are asking for without doing something that doesn't make a lot of sense. So I'm going to mark this one as closed for now, but feel free to add more comments if you have questions or other points to make.
-
Greg Hurrell
Ah, one more thing I forgot to add before I close this. If you want a really quick way to launch Synergy without having to open the preferences you could create an alias to the actual application file. Just say you installed into
/Applications
, the actual executable is stored at/Applications/Synergy Preferences.app/Contents/Resources/Synergy.prefPane/Contents/Resources/Synergy.app
. To actually get to that you need to right-click and do a "Show package contents" to look inside the bundles.But once you expose the actual executable you can just right-click on it, choose "Create alias", and then drag that alias wherever you want for convenient access.
-
Greg Hurrell
See ticket #1457 for one possible enhancement that would make Synergy easier to launch.
-
Greg Hurrell
Status changed:
- From: new
- To: closed
Add a comment
Comments are now closed for this issue.


{% load any_urlfield_tags %}{% comment %} The Django 1.11 MultiWidget doesn't pass the entire context of the subwidgets properly to the template. It only includes the 'widget' field in the 'subwidgets' template. This looses extra fields, such as: - wrap_label for RadioSelect / UrlTypeSelect - related_url, link_title, link_label for ForeignKeyRawIdWidget Hence, our AnyUrlWidget passes the full context along, and the `withdict` tag makes sure this is pushed to the context. {% endcomment %}


Main title
This is a demo of the Page component.
This is a card
This is a card
This is a card
This is a card
This is a card
This is a card
This is a card
This is a card
This is a card
This is a card


Channels#
Given an input space and an output space, a channel takes element from the input space (the message) and transforms it into an element of the output space (the transmitted message).
In Sage, Channels simulate error-prone transmission over communication channels, and we borrow the nomenclature from communication theory, such as “transmission” and “positions” as the elements of transmitted vectors. Transmission can be achieved with two methods:
Channel.transmit()
. Considering a channelChan
and a messagemsg
, transmittingmsg
withChan
can be done this way:Chan.transmit(msg)
It can also be written in a more convenient way:
Chan(msg)
transmit_unsafe()
. This does the exact same thing astransmit()
except that it does not check ifmsg
belongs to the input space ofChan
:Chan.transmit_unsafe(msg)
This is useful in e.g. an inner-loop of a long simulation as a
lighter-weight alternative to Channel.transmit()
.
This file contains the following elements:
Channel
, the abstract class for Channels
StaticErrorRateChannel
, which creates a specific number of errors in each transmitted message
ErrorErasureChannel
, which creates a specific number of errors and a specific number of erasures in each transmitted message
- class sage.coding.channel.Channel(input_space, output_space)#
Bases:
SageObject
Abstract top-class for Channel objects.
All channel objects must inherit from this class. To implement a channel subclass, one should do the following:
inherit from this class,
call the super constructor,
override
transmit_unsafe()
.
While not being mandatory, it might be useful to reimplement representation methods (
_repr_
and_latex_
).This abstract class provides the following parameters:
input_space
– the space of the words to transmitoutput_space
– the space of the transmitted words
- input_space()#
Return the input space of
self
.EXAMPLES:
sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(GF(59)^6, n_err) sage: Chan.input_space() Vector space of dimension 6 over Finite Field of size 59
- output_space()#
Return the output space of
self
.EXAMPLES:
sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(GF(59)^6, n_err) sage: Chan.output_space() Vector space of dimension 6 over Finite Field of size 59
- transmit(message)#
Return
message
, modified accordingly with the algorithm of the channel it was transmitted through.Checks if
message
belongs to the input space, and returns an exception if not. Note thatmessage
itself is never modified by the channel.INPUT:
message
– a vector
OUTPUT:
a vector of the output space of
self
EXAMPLES:
sage: F = GF(59)^6 sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(F, n_err) sage: msg = F((4, 8, 15, 16, 23, 42)) sage: set_random_seed(10) sage: Chan.transmit(msg) (4, 8, 4, 16, 23, 53)
We can check that the input
msg
is not modified:sage: msg (4, 8, 15, 16, 23, 42)
If we transmit a vector which is not in the input space of
self
:sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(GF(59)^6, n_err) sage: msg = (4, 8, 15, 16, 23, 42) sage: Chan.transmit(msg) Traceback (most recent call last): ... TypeError: Message must be an element of the input space for the given channel
Note
One can also call directly
Chan(message)
, which does the same asChan.transmit(message)
- transmit_unsafe(message)#
Return
message
, modified accordingly with the algorithm of the channel it was transmitted through.This method does not check if
message
belongs to the input space ofself
.This is an abstract method which should be reimplemented in all the subclasses of Channel.
EXAMPLES:
sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(GF(59)^6, n_err) sage: v = Chan.input_space().random_element() sage: Chan.transmit_unsafe(v) # random (1, 33, 46, 18, 20, 49)
- class sage.coding.channel.ErrorErasureChannel(space, number_errors, number_erasures)#
Bases:
Channel
Channel which adds errors and erases several positions in any message it transmits.
The output space of this channel is a Cartesian product between its input space and a VectorSpace of the same dimension over \(\GF{2}\).
INPUT:
space
– the input and output spacenumber_errors
– the number of errors created in each transmitted message. It can be either an integer of a tuple. If an tuple is passed as an argument, the number of errors will be a random integer between the two bounds of this tuple.number_erasures
– the number of erasures created in each transmitted message. It can be either an integer of a tuple. If an tuple is passed as an argument, the number of erasures will be a random integer between the two bounds of this tuple.
EXAMPLES:
We construct a ErrorErasureChannel which adds 2 errors and 2 erasures to any transmitted message:
sage: n_err, n_era = 2, 2 sage: Chan = channels.ErrorErasureChannel(GF(59)^40, n_err, n_era) sage: Chan Error-and-erasure channel creating 2 errors and 2 erasures of input space Vector space of dimension 40 over Finite Field of size 59 and output space The Cartesian product of (Vector space of dimension 40 over Finite Field of size 59, Vector space of dimension 40 over Finite Field of size 2)
We can also pass the number of errors and erasures as a couple of integers:
sage: n_err, n_era = (1, 10), (1, 10) sage: Chan = channels.ErrorErasureChannel(GF(59)^40, n_err, n_era) sage: Chan Error-and-erasure channel creating between 1 and 10 errors and between 1 and 10 erasures of input space Vector space of dimension 40 over Finite Field of size 59 and output space The Cartesian product of (Vector space of dimension 40 over Finite Field of size 59, Vector space of dimension 40 over Finite Field of size 2)
- number_erasures()#
Return the number of erasures created by
self
.EXAMPLES:
sage: n_err, n_era = 0, 3 sage: Chan = channels.ErrorErasureChannel(GF(59)^6, n_err, n_era) sage: Chan.number_erasures() (3, 3)
- number_errors()#
Return the number of errors created by
self
.EXAMPLES:
sage: n_err, n_era = 3, 0 sage: Chan = channels.ErrorErasureChannel(GF(59)^6, n_err, n_era) sage: Chan.number_errors() (3, 3)
- transmit_unsafe(message)#
Return
message
with as many errors asself._number_errors
in it, and as many erasures asself._number_erasures
in it.If
self._number_errors
was passed as an tuple for the number of errors, it will pick a random integer between the bounds of the tuple and use it as the number of errors. It does the same withself._number_erasures
.All erased positions are set to 0 in the transmitted message. It is guaranteed that the erasures and the errors will never overlap: the received message will always contains exactly as many errors and erasures as expected.
This method does not check if
message
belongs to the input space ofself
.INPUT:
message
– a vector
OUTPUT:
a couple of vectors, namely:
the transmitted message, which is
message
with erroneous and erased positionsthe erasure vector, which contains
1
at the erased positions of the transmitted message and0
elsewhere.
EXAMPLES:
sage: F = GF(59)^11 sage: n_err, n_era = 2, 2 sage: Chan = channels.ErrorErasureChannel(F, n_err, n_era) sage: msg = F((3, 14, 15, 9, 26, 53, 58, 9, 7, 9, 3)) sage: set_random_seed(10) sage: Chan.transmit_unsafe(msg) ((31, 0, 15, 9, 38, 53, 58, 9, 0, 9, 3), (0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0))
- class sage.coding.channel.QarySymmetricChannel(space, epsilon)#
Bases:
Channel
The \(q\)-ary symmetric, memoryless communication channel.
Given an alphabet \(\Sigma\) with \(|\Sigma| = q\) and an error probability \(\epsilon\), a \(q\)-ary symmetric channel sends an element of \(\Sigma\) into the same element with probability \(1 - \epsilon\), and any one of the other \(q - 1\) elements with probability \(\frac{\epsilon}{q - 1}\). This implementation operates over vectors in \(\Sigma^n\), and “transmits” each element of the vector independently in the above manner.
Though \(\Sigma\) is usually taken to be a finite field, this implementation allows any structure for which Sage can represent \(\Sigma^n\) and for which \(\Sigma\) has a
random_element()
method. However, beware that if \(\Sigma\) is infinite, errors will not be uniformly distributed (sincerandom_element()
does not draw uniformly at random).The input space and the output space of this channel are the same: \(\Sigma^n\).
INPUT:
space
– the input and output space of the channel. It has to be \(\GF{q}^n\) for some finite field \(\GF{q}\).epsilon
– the transmission error probability of the individual elements.
EXAMPLES:
We construct a
QarySymmetricChannel
which corrupts 30% of all transmitted symbols:sage: epsilon = 0.3 sage: Chan = channels.QarySymmetricChannel(GF(59)^50, epsilon) sage: Chan q-ary symmetric channel with error probability 0.300000000000000, of input and output space Vector space of dimension 50 over Finite Field of size 59
- error_probability()#
Return the error probability of a single symbol transmission of
self
.EXAMPLES:
sage: epsilon = 0.3 sage: Chan = channels.QarySymmetricChannel(GF(59)^50, epsilon) sage: Chan.error_probability() 0.300000000000000
- probability_of_at_most_t_errors(t)#
Return the probability
self
has to return at mostt
errors.INPUT:
t
– an integer
EXAMPLES:
sage: epsilon = 0.3 sage: Chan = channels.QarySymmetricChannel(GF(59)^50, epsilon) sage: Chan.probability_of_at_most_t_errors(20) 0.952236164579467
- probability_of_exactly_t_errors(t)#
Return the probability
self
has to return exactlyt
errors.INPUT:
t
– an integer
EXAMPLES:
sage: epsilon = 0.3 sage: Chan = channels.QarySymmetricChannel(GF(59)^50, epsilon) sage: Chan.probability_of_exactly_t_errors(15) 0.122346861835401
- transmit_unsafe(message)#
Return
message
where each of the symbols has been changed to another from the alphabet with probabilityerror_probability()
.This method does not check if
message
belongs to the input space ofself
.INPUT:
message
– a vector
EXAMPLES:
sage: F = GF(59)^11 sage: epsilon = 0.3 sage: Chan = channels.QarySymmetricChannel(F, epsilon) sage: msg = F((3, 14, 15, 9, 26, 53, 58, 9, 7, 9, 3)) sage: set_random_seed(10) sage: Chan.transmit_unsafe(msg) (3, 14, 15, 53, 12, 53, 58, 9, 55, 9, 3)
- class sage.coding.channel.StaticErrorRateChannel(space, number_errors)#
Bases:
Channel
Channel which adds a static number of errors to each message it transmits.
The input space and the output space of this channel are the same.
INPUT:
space
– the space of both input and outputnumber_errors
– the number of errors added to each transmitted message It can be either an integer of a tuple. If a tuple is passed as argument, the number of errors will be a random integer between the two bounds of the tuple.
EXAMPLES:
We construct a
StaticErrorRateChannel
which adds 2 errors to any transmitted message:sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(GF(59)^40, n_err) sage: Chan Static error rate channel creating 2 errors, of input and output space Vector space of dimension 40 over Finite Field of size 59
We can also pass a tuple for the number of errors:
sage: n_err = (1, 10) sage: Chan = channels.StaticErrorRateChannel(GF(59)^40, n_err) sage: Chan Static error rate channel creating between 1 and 10 errors, of input and output space Vector space of dimension 40 over Finite Field of size 59
- number_errors()#
Return the number of errors created by
self
.EXAMPLES:
sage: n_err = 3 sage: Chan = channels.StaticErrorRateChannel(GF(59)^6, n_err) sage: Chan.number_errors() (3, 3)
- transmit_unsafe(message)#
Return
message
with as many errors asself._number_errors
in it.If
self._number_errors
was passed as a tuple for the number of errors, it will pick a random integer between the bounds of the tuple and use it as the number of errors.This method does not check if
message
belongs to the input space ofself
.INPUT:
message
– a vector
OUTPUT:
a vector of the output space
EXAMPLES:
sage: F = GF(59)^6 sage: n_err = 2 sage: Chan = channels.StaticErrorRateChannel(F, n_err) sage: msg = F((4, 8, 15, 16, 23, 42)) sage: set_random_seed(10) sage: Chan.transmit_unsafe(msg) (4, 8, 4, 16, 23, 53)
This checks that github issue #19863 is fixed:
sage: V = VectorSpace(GF(2), 1000) sage: Chan = channels.StaticErrorRateChannel(V, 367) sage: c = V.random_element() sage: (c - Chan(c)).hamming_weight() 367
- sage.coding.channel.format_interval(t)#
Return a formatted string representation of
t
.This method should be called by any representation function in Channel classes.
Note
This is a helper function, which should only be used when implementing new channels.
INPUT:
t
– a list or a tuple
OUTPUT:
a string
- sage.coding.channel.random_error_vector(n, F, error_positions)#
Return a vector of length
n
overF
filled with random non-zero coefficients at the positions given byerror_positions
.Note
This is a helper function, which should only be used when implementing new channels.
INPUT:
n
– the length of the vectorF
– the field over which the vector is definederror_positions
– the non-zero positions of the vector
OUTPUT:
a vector of
F
AUTHORS:
This function is taken from codinglib (https://bitbucket.org/jsrn/codinglib/) and was written by Johan Nielsen.
EXAMPLES:
sage: from sage.coding.channel import random_error_vector sage: random_error_vector(5, GF(2), [1,3]) (0, 1, 0, 1, 0)


| In this page of the Atlas we present a sample of some of the best network topology maps created by Internet Service Providers (ISPs) and Internet backbone operators. The maps are often created for promotional purposes to demonstrate the large bandwidth and good connections available. |
| The backbone network of Qwest for the Northeast of the USA and below the whole country. | |
| The map above is the Abilene network part of the Internet2 project linking major US universities with a very fast, high-capacity network. |
|
AT&T's Internet backbone network, as of early 2000. |
| The MichNet backbone in July 1997. MichNet is a regional network serving the Michigan area of the USA and operated by Merit Network Inc. |
|
Below are backbone network maps, from early 2000,
for Intermedia Communications
and Genuity,
both major players in the Internet infrastructure world.
|
|
The backbone IP network
of XO Communications from summer 2001.
|
| Map of backbone and international connections for the Rede Nacional de Pesquisa, the nation research network for Brasil. |
A topology map of the Internet Initiative Japan (IIJ) backbone, the largest data network in Japan.
PSINet's global Internet backbone network from March 1999.
| UUNET's global Internet backbone network is one of the largest and complex. The map above shows the extent of the network from June 1999 and the one below is from early 1998. (See their web site for the latest map) |
| Mapnet, is a powerful interactive mapping tool with which you can map and examine the Internet backbone infrastructure of over thirty different commercial and research & education ISPs. Mapnet was developed by CAIDA - Cooperative Association for Internet Data Analysis. | |
|
Thanks to Russ Haynal's ISP Page for helping to locate some of the maps shown here. It should be noted that in the rapidly changing commercial Internet, the backbone maps shown here may not necessarily match the current infrastructure. Please consult the companies website for the most up to date maps and information on their networks. |


---
layout: post
title: Tux is now doing cross marketing deals
tags:
- Linux
status: publish
type: post
published: true
meta: {}
---
When I was browsing in a local bookshop today I saw the Linux mascot, Tux, now appearing on the front of Australian Women's' Weekly cookery books.
Wow! the geeks have become domesticated.
I wonder if they remembered to acknowledge Larry's copyright?
Here is a link to their website


Timothy A. Cuevas
Unafffiliated
Retired
I have a BA degree in Government and Sociology, a BS degree in Nursing and Physical Education and a Masters Degree in Nursing.
80015
I have experience working for Americorps/Vista and the CO Department of Health and Environment. I am a member of and advocate for the Over-50 Men's Baseball Association in Denver.
Other than voting I have not been active with any political activity either State wide or national. Nor have I donated any money to any campaigns or political organizations.
I was a member of Americorps/Vista as a Contact Tracer for Covid-19 from July 2020 to September 2020.
The main reason for wanting to serve on this commission is to be involved in the working of Governmental landscape and to use my Civilian education and my military training to advocate for the state of Colorado and the people who live in the state.
As an Independent, I do not consider myself Unaffiliated, I believe I will bring a fresh set of eyes and ears to the table and help bridge a consensus between the members of the commission. I believe that there are more than just Democrats and Republicans who live in this state and their point of view should be heard and used to determine the legislative districts in CO.
As a Registered Nurse and a Advanced Practice Nurse I have been trained to analyze health problems, determine what the main issues were and come up with common sense solutions for both those in the hospital and those who need care outside of the Hospital. As an officer in the Army and as a staff officer, commander and as an Army Nurse, I was taught how to analyze specific issues and/or problems, come up with courses of actions, determine the best course of action and implement what needed to be done. I was also taught that if adjustments needed to be made I would be able to do this as well.
Male


Matt Petersen
- Jul 26, 2017 »
Load MNIST in 26 lines
- Jul 26, 2017 »
Probability theory
- Jul 26, 2017 »
Another MNIST Loader
- Jul 26, 2017 »
Another CIFAR-10 Loader
- Jul 06, 2017 »
Newton's method
- Jun 25, 2017 »
Softmax with cross-entropy
- Jun 21, 2017 »
Tidal music player for Linux
- Jun 17, 2017 »
Are lefties really smarter?
- Apr 05, 2017 »
Our overqualified world
- Mar 19, 2017 »
Unity can be beautiful


Scripture quotations are from the ESV® Bible (The Holy Bible, English Standard Version®), copyright © 2001 by Crossway, a publishing ministry of Good News Publishers. Used by permission. All rights reserved. May not copy or download more than 500 consecutive verses of the ESV Bible or more than one half of any book of the ESV Bible.
Scriptures taken from the Holy Bible, New International Version®, NIV®. Copyright © 1973, 1978, 1984, 2011 by Biblica, Inc.™ Used by permission of Zondervan. All rights reserved worldwide. www.zondervan.com The “NIV” and “New International Version” are trademarks registered in the United States Patent and Trademark Office by Biblica, Inc.™
Scripture quotations are taken from the Holy Bible, New Living Translation, copyright ©1996, 2004, 2007, 2013, 2015 by Tyndale House Foundation. Used by permission of Tyndale House Publishers, Inc., Carol Stream, Illinois 60188. All rights reserved.
All Songs are Copyright © 2005–2015 by Dana Dirksen.
All Videos are Copyright © 2012 by The Gospel Coalition.
Catechism content is Copyright © 2012 by Redeemer Presbyterian Church. We encourage you to use and share this material freely—but please don’t charge money for it, change the wording, or remove the copyright information.
Excepting other Copyrighted content, Web Catechism is Copyright © 2015–{{ dateFormat "2006" now }} by Ben Forshey and licensed under the MIT License.
Suggestions / contributions are welcome at<EMAIL_ADDRESS>or this project’s GitHub Repository.


@(url: String, token: String, name: String, email: String, name_project: String, name_role: String)
Hello @name,
Welcome to the AssisTU initiative! I have been assigned to be your Personal Assistant that will guide and assist you through the writing and reviewing of scientific papers, articles, dissertations, and all other types of paperwork.
First off, I will need you to verify yourself for security purposes. You can do so by clicking this link. Once verified, I will give you a tour around our environment so you can get started.
Hope to see you soon,
your Personal Assistant
PS: If you did not sign up with us, you can ignore this email.


$def with (form, url, authBad)
Smuggler is currently in alpha release and should be treated as such. It may contain catastrophic errors and/or bugs that may make it unusable at any given point in time.
Smuggler is an application that is designed with the goal of keeping your local image collection and SmugMug account in sync. It is designed to have a web interface to allow you to run it either from your local system, or to install it on a separate system with the images and then manage it from another system.
We need to gather a little information before Smuggler can get to work for you. It should be straight forward and only take a second.


The class T1
extends Thread
class.
More...
Public Member Functions | |
| T1 (JPWorld parent, float sleepIntervalSec) | |
| Creates a new instance of T1. | |
| void | start () |
| Starts the thread. | |
| void | stopThread () |
| Stops the thread. | |
| void | interruptibleSleep (long millis) |
Interruptible sleep (instead of Thread.sleep ). | |
| void | run () |
Prints thread's own signature and creates a pair of particles in belonging JPWorld 's context every sleepItervalMillis . | |
Protected Attributes | |
| JPWorld | parent |
| Parent where println() messages are directed to. | |
Private Attributes | |
| String | signature = "T1: Thread 1" |
| volatile boolean | running = false |
| Indicates if thread is (or should be) running. | |
| volatile boolean | completed = true |
| Indicates that thread is completed. | |
| int | sleepItervalMillis |
| Sleep interval for thread in millis. |
The class T1
extends Thread
class.
Instance of the T2
prints out its signature until it gets stopped. It also creates a charged particle pair in associated JPWorld
context.
Definition at line 10 of file T1.java.
| T1.T1 | ( | JPWorld | parent, |
| float | sleepIntervalSec | ||
| ) |
Creates a new instance of T1.
| parent | owner of the thread |
| sleepIntervalSec | sleep interval in seconds |
Definition at line 40 of file T1.java.
References parent, and sleepItervalMillis.
Referenced by T3.run().
{ this.parent = parent; this.sleepItervalMillis = (int)( sleepIntervalSec * 1000f ); }
| void T1.interruptibleSleep | ( | long | millis ) |
| void T1.run | ( | ) |
Prints thread's own signature and creates a pair of particles in belonging JPWorld
's context every sleepItervalMillis
.
Reimplemented in T3.
Definition at line 90 of file T1.java.
References completed, JPWorld.createPairOfChargedParticles(), interruptibleSleep(), parent, JPWorld.println(), running, signature, and sleepItervalMillis.
{ while( running ) { parent.println( signature ); parent.createPairOfChargedParticles( 1, 10.0 + Math.random () * 5.0 ); interruptibleSleep( sleepItervalMillis ); } completed = true; }
| void T1.start | ( | ) |
| void T1.stopThread | ( | ) |
volatile boolean T1.completed = true [private] |
volatile boolean T1.running = false [private] |
Indicates if thread is (or should be) running.
Definition at line 17 of file T1.java.
Referenced by run(), start(), and stopThread().
String T1.signature = "T1: Thread 1" [private] |
int T1.sleepItervalMillis [private] |


Road to Programming Salvation
Programming is something I've always wanted to pursue since I was a kid. Although I thought it was a cool career, it was one strongly frowned upon by my family. It fell into a 'nerd' category and my dad was always the macho macho type who discouraged that sort of stuff. I ended up doing other things in life for a while until I became an adult. Then I tried it out for the first time 4 years ago (back in 2012) where I fell in love with it.
 I choose a scripting language called Lua (derived from C) to start with due to it's beginner friendly syntax and use in gaming/modding. In conjunction with the language I was using a framework called Love2D to make different little games so I could test my coding chops. I progressed from game to game, and even made a few libraries and tools for others to use on the forum that were quite popular!
Programs I made for my grandparents
Learning how to code was brutal and very frustrating when I first started. I kept running into simple pitfalls on getting very basic things to work. I had no instructor or professor to ask for assistance, but there was a great community on the Love2D forums that didn't mind helping new people. I spent a lot of time on the IRC chat figuring out things and asking questions, and once I had a solid foundation I began my journey to becoming a novice programmer. Eventually I reached a point where if I needed to know if something was going to work, I'd just ask the interpreter and find my answer. Eventually I reached plateau where an interpreter couldn't answer my questions. How do I structure my code folder(s)? How should I name my functions, arguments, variables? What about commenting code, were there any strict guidelines? And once again, I searched for answers but this time I started to go into unfamiliar territory... other peoples code!
I examined how other 'Lovers' (pun referencing love2d community members) coded their project and learned a great deal. Many had standardized practices in how they structured their code, classes, and methods. At first I was baffled as to why they didn't comment their code to explain ever insignificant detail. Much like how a grandmaster chess game is analyzed by spectators, there is no need to explain basic concepts like castling, en pesant, and pawn promotions. The same would apply to much of the code I looked at, it was suited towards either the programmer themselves or at a intermediate level of coding where basic things were assumed to be understood.
Not only did I venture into others code, but I also found myself at times digging up articles on programming for becoming more proficient. Quora, stackexchange, and other influential programmers who blogged (shout out to Joel Spolsky), all gave me a wealth of information on improving. Over time my code evolved and became more refined. This was reflected in my projects as I went from:
- Spaghetti code to seperated modules
- Packing multiple *unreleated* functions together to grouping them in different classes
- Hardcoding variables to using a function or class initialization to setup variables that can be changed on the fly
- Giving functions and variables irrelevant names to defining accurate purposes and identities
Overall I've achieved somewhat of a moderate proficiency of code knowledge and ability, but there is still a lot left for me to learn. I've kept an eye on LaunchCode for a while now. (1? 2 years?) When I saw that they were offering a learning experience starting this summer it looked to good to be true. But lo, and behold - They are REALLY doing it!!! Programming classes to those who wish to learn is FREAKING AWESOME! I'm proud to have been selected as a candidate for this opportunity, and hope that my programming skills are up to par with what is needed.


Synopsis
Killer asteroids have long played a role in science fiction. But when a fireball exploded over Chelyabinsk, Russia in 2013, the world learned that the threat is real.
On average, NASA finds a new potentially hazardous asteroid every day... and there are still many we haven’t found. Many of these space rocks could destroy cities, and some are big enough to wipe out civilization.
On the other hand, they contain the secrets to the origin of our solar system – and could be the key to the survival of the human race.
In the movies, when an asteroid is headed for Earth, there’s always a team of heroes that comes to the rescue and saves the day. But in real life, who can tame these hurtling space rocks? Who can save us from Asteroid Apocalypse – and, just maybe, take us out into the final frontier?
Meet the heroes of MISSION ASTEROID. In the Spring 2010, President Barack Obama boldly declared that NASA’s next mission would be to near-earth asteroids, setting up eventual manned missions to deep space. Mission Asteroid is a documentary about the teams of scientists, researchers and dreamers who will make it happen.
To learn more about the asteroid mission and potentially hazardous asteriods, visit NASA JPL's Asteroid Watch page.


Following up on MySQL security: inconsistencies, and on MySQL bug #61596, I was thinking it may take a long time till the non-existent ROUTINE_PRIVILEGES view is implemented. Here's my own implementation of the view.
I've followed the somewhat strange conventions used in the *_PRIVILEGES tables in INFORMATION_SCHEMA, where the IS_GRANTABLE is a separate column, although in 2nd 1st normal form.
I present it here as a query, using session variables, rather than a view definition:
SELECT STRAIGHT_JOIN CONCAT('\'', User, '\'@\'', Host, '\'') AS GRANTEE, NULL AS ROUTINE_CATALOG, Db AS ROUTINE_SCHEMA, Routine_name AS ROUTINE_NAME, Routine_type AS ROUTINE_TYPE, UPPER(SUBSTRING_INDEX(SUBSTRING_INDEX(Proc_priv, ',', n+1), ',', -1)) AS PRIVILEGE_TYPE, IF(grantable_procs_priv.User IS NULL, 'NO', 'YES') AS IS_GRANTABLE FROM mysql.procs_priv CROSS JOIN (SELECT @counter := -1) select_init CROSS JOIN ( SELECT @counter := @counter+1 AS n FROM INFORMATION_SCHEMA.COLLATIONS LIMIT 5 ) numbers LEFT JOIN ( SELECT DISTINCT User, Host, Db, Routine_name FROM mysql.procs_priv WHERE find_in_set('Grant', Proc_priv) > 0 ) grantable_procs_priv USING (User, Host, Db, Routine_name) WHERE numbers.n BETWEEN 0 AND CHAR_LENGTH(Proc_priv) - CHAR_LENGTH(REPLACE(Proc_priv, ',', '')) AND UPPER(SUBSTRING_INDEX(SUBSTRING_INDEX(Proc_priv, ',', n+1), ',', -1)) != 'GRANT' ORDER BY GRANTEE, ROUTINE_SCHEMA, ROUTINE_NAME, ROUTINE_TYPE, n ;
It takes 2 views and a table to make this a VIEW rather than a query.
First teaser: the view which represents this query, along with many other interesting diagnostic views, is to take part in a new open source project I'm working on.
[UPDATE]
Guess I was in a rush to produce the query. Here's a shorter, cleaner one:
SELECT CONCAT('\'', User, '\'@\'', Host, '\'') AS GRANTEE, NULL AS ROUTINE_CATALOG, Db AS ROUTINE_SCHEMA, Routine_name AS ROUTINE_NAME, Routine_type AS ROUTINE_TYPE, UPPER(SUBSTRING_INDEX(SUBSTRING_INDEX(Proc_priv, ',', n+1), ',', -1)) AS PRIVILEGE_TYPE, IF(find_in_set('Grant', Proc_priv) > 0, 'YES', 'NO') AS IS_GRANTABLE FROM mysql.procs_priv CROSS JOIN ( SELECT @counter := @counter+1 AS n FROM INFORMATION_SCHEMA.COLLATIONS, (SELECT @counter := -1) select_init LIMIT 5 ) numbers WHERE numbers.n BETWEEN 0 AND CHAR_LENGTH(Proc_priv) - CHAR_LENGTH(REPLACE(Proc_priv, ',', '')) AND UPPER(SUBSTRING_INDEX(SUBSTRING_INDEX(Proc_priv, ',', n+1), ',', -1)) != 'GRANT' ORDER BY GRANTEE, ROUTINE_SCHEMA, ROUTINE_NAME, ROUTINE_TYPE, n ;
Example output:
comments powered by Disqus+--------------------------+-----------------+----------------+----------------------------+--------------+----------------+--------------+ | GRANTEE | ROUTINE_CATALOG | ROUTINE_SCHEMA | ROUTINE_NAME | ROUTINE_TYPE | PRIVILEGE_TYPE | IS_GRANTABLE | +--------------------------+-----------------+----------------+----------------------------+--------------+----------------+--------------+ | 'other_user'@'localhost' | NULL | sakila | film_in_stock | PROCEDURE | EXECUTE | NO | | 'other_user'@'localhost' | NULL | sakila | film_in_stock | PROCEDURE | ALTER ROUTINE | NO | | 'other_user'@'localhost' | NULL | sakila | get_customer_balance | FUNCTION | EXECUTE | NO | | 'other_user'@'localhost' | NULL | sakila | get_customer_balance | FUNCTION | ALTER ROUTINE | NO | | 'other_user'@'localhost' | NULL | sakila | inventory_held_by_customer | FUNCTION | EXECUTE | NO | | 'other_user'@'localhost' | NULL | sakila | inventory_held_by_customer | FUNCTION | ALTER ROUTINE | NO | |<EMAIL_ADDRESS>| NULL | sakila | film_in_stock | PROCEDURE | EXECUTE | YES | |<EMAIL_ADDRESS>| NULL | sakila | get_customer_balance | FUNCTION | EXECUTE | NO | |<EMAIL_ADDRESS>| NULL | sakila | get_customer_balance | FUNCTION | ALTER ROUTINE | NO | | 'world_user'@'localhost' | NULL | sakila | get_customer_balance | FUNCTION | EXECUTE | YES | | 'world_user'@'localhost' | NULL | sakila | get_customer_balance | FUNCTION | ALTER ROUTINE | YES | +--------------------------+-----------------+----------------+----------------------------+--------------+----------------+--------------+


Premier Glass and Aluminium
making your home elegant
071-853-8089
<EMAIL_ADDRESS>Request a quote
Toggle navigation
Home
Learn
About us
Why Aluminium
Terms and Conditions
About us
Why Aluminium
Terms and Conditions
Products
Repairs
Gallery
071-853-8089
Request a quote


Provides Map, Reduce and Filter variants to generate jobs on batch
computing systems like PBS/Torque, LSF, SLURM and Sun Grid Engine.
Multicore and SSH systems are also supported. For further details see the
project web page.
| Version: |
1.7 |
| Depends: |
R (≥ 3.0.0), BBmisc (≥ 1.9), methods |
| Imports: |
backports (≥ 1.1.1), brew, checkmate (≥ 1.8.0), data.table (≥ 1.9.6), DBI, digest, parallel, RSQLite (≥ 1.0.9011), sendmailR, stats, stringi (≥ 0.4-1), utils |
| Suggests: |
MASS, testthat |
| Published: |
2017-11-28 |
| Author: |
Bernd Bischl,
Michel Lang,
Henrik Bengtsson |
| Maintainer: |
Bernd Bischl <bernd_bischl at gmx.net> |
| BugReports: |
https://github.com/tudo-r/BatchJobs/issues |
| License: |
BSD_2_clause + file LICENSE |
| URL: |
https://github.com/tudo-r/BatchJobs |
| NeedsCompilation: |
no |
| Citation: |
BatchJobs citation info |
| Materials: |
NEWS |
| In views: |
HighPerformanceComputing |
| CRAN checks: |
BatchJobs results |


Market Survey Form
Let us know how we can improve the market survey form
Name
Email
Age
company
Gender
Select an option
male
female
gender
current position
Select an option
student
part-timejob
full-timejob
Full Time Learner
Prefer not to say
Other
How would you like to recommended the market should be
defintely
Maybe
sure
Household income
$0 - $24,999
$25,000 - $49,999
$50,000 - $74,999
Check any interests that you like
Arts & Entertainment
Autos & Vehicles
Beauty & Fitness
Books & Literature
Business & Industrial
Computers & Electronics
Finance
Any comments or suggestion
Submit


Wellcome! This is
Wakidur Rahman
Software Engineer (Web development)
Last 4 years I worked for some software companies which were foreign and local ownership. I was responsible for Front-End & MEAN/MERN Stack web application development. I have serious passion for UI effects, animations and creating intuitive, dynamic user experiences (UX).I build Back-End and Front-End web application using Node.js, Express.js, MongoDB, Angular, React, HTML5 & CSS3. Within some project I am only responsible for creating RESTfull API using Node.js, Express.js, MongoDB and Postman for access API EndPoint.
My Work Resume/CVProfessional Skills
Translates user requirements into the overall architecture and implement the new systems.
Hi! My name is Wakidur Rahman. I am a Front-End & MEAN/MERN stack web developer. An experienced TypeScript, SCSS, JWT, Passport.js, ODM (Mongoose), jQuery, Versioning/Deployment: Git, Bitbucket, GitLab, Jira. Tools: Source tree, Robomongo, MongoDB Compass, Postman, Figma, Zipline. I am an expert in full stack web application development.
Work Skills
My Experience
Portfolio
I have worked for the company in the mine time I had worked a few exercise project below is the samples of this projects and links.
- All
- Angular
- Angular & Node.js
- HTML5 & CSS3
- React
- HackerRank
Contact
You can contact with me by below info.
- Wakidur Rahman
- +8801673260858<EMAIL_ADDRESS>- +8801717309617
- wakidur https://www.linkedin.com/in/wakidur-rahman-0900a498
- Uttara, Dhaka-1230, Bangladesh


Some Drush commands use strict option handling; these commands require that all Drush global option appear on the command line before the Drush command name.
One example of this is the core-rsync command:
drush --simulate core-rsync -v @site1 @site2The --simulate option is a Drush global option that causes Drush to print out what it would do if the command is executed, without actually taking any action. Commands such as core-rsync that use strict option handling require that --simulate, if used, must appear before the command name. Most Drush commands allow the --simulate to be placed anywhere, such as at the end of the command line.
The -v option above is an rsync option. In this usage, it will cause the rsync command to run in verbose mode. It will not cause Drush to run in verbose mode, though, because it appears after the core-rsync command name. Most Drush commands would be run in verbose mode if a -v option appeared in the same location.
The advantage of strict option handling is that it allows Drush to pass options and arguments through to a shell command. Some shell commands, such as rsync and ssh, either have options that cannot be represented in Drush. For example, rsync allows the --exclude option to appear multiple times on the command line, but Drush only allows one instance of an option at a time for most Drush commands. Strict option handling overcomes this limitation, plus possible conflict between Drush options and shell command options with the same name, at the cost of greater restriction on where global options can be placed.


High Priest Sylvain:
Welcome to the warm bosom of Einhasad, the goddess of light. What event has brought you to me? By the holy name of Einhasad, I pray I am able to help you!
Listen to information about first class transfer.
Clan.
Alliance.
Quest


--- layout: default ---
Hello! {{ site.description }} I currently work as the Strategy & Design Lead for the Open Cities Team of the What Works Cities initiative. I am also co-director of Code for DC.
Learn more.