text
stringlengths 2
9.79k
| meta
dict | sentences_perturbed
int64 0
2
⌀ | doc_stats
dict |
|---|---|---|---|
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace RunShellcode.Properties
{
/// <summary>
/// A strongly-typed resource class, for looking up localized strings, etc.
A strongly-typed resource class, used for retrieving localized strings and other resources.
// To add or remove a member, edit your .ResX file then rerun ResGen
// with the /str option, or rebuild your VS project.
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources
{
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources()
{
}
/// <summary>
/// Returns the cached ResourceManager instance used by this class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager
{
get
{
if ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("RunShellcode.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// Overrides the current thread's CurrentUICulture property for all
/// resource lookups using this strongly typed resource class.
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture
{
get
{
return resourceCulture;
}
set
{
resourceCulture = value;
}
}
}
}
| null | 1
|
{
"advantage_score_max": 3.653160572052002,
"advantage_score_mean": 2.7581779956817627,
"advantage_score_min": 1.863195538520813,
"advantage_score_std": 0.8949825167655945,
"advantage_scores": [
3.653160572052002,
1.863195538520813
],
"baseline_doc_loss": 0.19612155854701996,
"baseline_truncated": false,
"doc_advantage_score": 3.3958868980407715,
"length_change_ratio": 0.6453900709219859,
"net_length_change_chars": -50,
"original_sentences_length_chars": 141,
"replacement_paraphrases_length_chars": 91,
"sentences_perturbed": 1,
"target_doc_loss": 0.05775267630815506,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 2781,
"total_sentences": 8,
"truncated": false
}
|
/**
* Copyright 2010-2015 Axel Fontaine
* <p/>
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You can obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.contrastsecurity.cassandra.migration.resolver;
import com.contrastsecurity.cassandra.migration.CassandraMigrationException;
import com.contrastsecurity.cassandra.migration.info.MigrationVersion;
import com.contrastsecurity.cassandra.migration.utils.Pair;
/**
* Parsing support for migrations that use the standard Flyway version + description embedding in their name. These
* migrations have names like 1_2__Description .
*/
public class MigrationInfoHelper {
/**
* Prevents instantiation.
*/
private MigrationInfoHelper() {
//Do nothing.
}
/**
* Extracts the schema version and the description from a migration name formatted as 1_2__Description.
*
* @param migrationName The migration name to parse. Should not contain any folders or packages.
* @param prefix The migration prefix.
* @param separator The migration separator.
* @param suffix The migration suffix.
* @return The extracted schema version.
* @throws CassandraMigrationException if the migration name does not follow the standard conventions.
*/
public static Pair<MigrationVersion, String> extractVersionAndDescription(String migrationName,
String prefix, String separator, String suffix) {
String cleanMigrationName = migrationName.substring(prefix.length(), migrationName.length() - suffix.length());
// Handle the description
int descriptionPos = cleanMigrationName.indexOf(separator);
if (descriptionPos < 0) {
throw new CassandraMigrationException("Wrong migration name format: " + migrationName
+ "(It should look like this: " + prefix + "1_2" + separator + "Description" + suffix + ")");
}
String version = cleanMigrationName.substring(0, descriptionPos);
String description = cleanMigrationName.substring(descriptionPos + separator.length()).replaceAll("_", " ");
return Pair.of(MigrationVersion.fromVersion(version), description);
}
}
| null | 1
|
{
"advantage_score_max": 2.714717149734497,
"advantage_score_mean": 1.636820912361145,
"advantage_score_min": 1.1163991689682007,
"advantage_score_std": 0.6351169943809509,
"advantage_scores": [
2.714717149734497,
1.4707911014556885,
1.2453758716583252,
1.1163991689682007
],
"baseline_doc_loss": 0.8806055784225464,
"baseline_truncated": false,
"doc_advantage_score": 1.0763338804244995,
"length_change_ratio": 1.006269592476489,
"net_length_change_chars": 2,
"original_sentences_length_chars": 319,
"replacement_paraphrases_length_chars": 321,
"sentences_perturbed": 1,
"target_doc_loss": 0.8181527853012085,
"target_truncated": false,
"threshold_passing_sentences": 4,
"total_doc_length_chars": 2723,
"total_sentences": 16,
"truncated": false
}
|
CODEPAGE 20127
CPINFO 1 0x3F 0x003F
MBTABLE 254
0x00 0x0000 ;Null
0x01 0x0001 ;Start Of Heading
0x02 0x0002 ;Start Of Text
0x03 0x0003 ;End Of Text
0x04 0x0004 ;End Of Transmission
0x05 0x0005 ;Enquiry
0x06 0x0006 ;Acknowledge
0x07 0x0007 ;Bell
0x08 0x0008 ;Backspace
0x09 0x0009 ;Character Tabulation
0x0A 0x000A ;Line Feed (LF)
0x0B 0x000B ;Line Tabulation
0x0C 0x000C ;Form Feed (FF)
0x0D 0x000D ;Carriage Return (CR)
0x0E 0x000E ;Shift Out
0x0F 0x000F ;Shift In
0x10 0x0010 ;Data Link Escape
0x11 0x0011 ;Device Control One
0x12 0x0012 ;Device Control Two
0x13 0x0013 ;Device Control Three
0x14 0x0014 ;Device Control Four
0x15 0x0015 ;Negative Acknowledge
0x16 0x0016 ;Synchronous Idle
0x17 0x0017 ;End Of Transmission Block
0x18 0x0018 ;Cancel
0x19 0x0019 ;End Of Medium
0x1A 0x001A ;Substitute
0x1B 0x001B ;Escape
0x1C 0x001C ;Information Separator Four
0x1D 0x001D ;Information Separator Three
0x1E 0x001E ;Information Separator Two
0x1F 0x001F ;Information Separator One
0x20 0x0020 ;Space
0x21 0x0021 ;Exclamation Mark
0x22 0x0022 ;Quotation Mark
0x23 0x0023 ;Number Sign
0x24 0x0024 ;Dollar Sign
0x25 0x0025 ;Percent Sign
0x26 0x0026 ;Ampersand
0x27 0x0027 ;Apostrophe
0x28 0x0028 ;Left Parenthesis
0x29 0x0029 ;Right Parenthesis
0x2A 0x002A ;Asterisk
0x2B 0x002B ;Plus Sign
0x2C 0x002C ;Comma
0x2D 0x002D ;Hyphen-Minus
0x2E 0x002E ;Full Stop
0x2F 0x002F ;Solidus
0x30 0x0030 ;Digit Zero
0x31 0x0031 ;Digit One
0x32 0x0032 ;Digit Two
0x33 0x0033 ;Digit Three
0x34 0x0034 ;Digit Four
0x35 0x0035 ;Digit Five
0x36 0x0036 ;Digit Six
0x37 0x0037 ;Digit Seven
0x38 0x0038 ;Digit Eight
0x39 0x0039 ;Digit Nine
0x3A 0x003A ;Colon
0x3B 0x003B ;Semicolon
0x3C 0x003C ;Less-Than Sign
0x3D 0x003D ;Equals Sign
0x3E 0x003E ;Greater-Than Sign
0x40 0x0040 ;Commercial At
0x41 0x0041 ;Latin Capital Letter A
0x42 0x0042 ;Latin Capital Letter B
0x43 0x0043 ;Latin Capital Letter C
0x44 0x0044 ;Latin Capital Letter D
0x45 0x0045 ;Latin Capital Letter E
0x46 0x0046 ;Latin Capital Letter F
0x47 0x0047 ;Latin Capital Letter G
0x48 0x0048 ;Latin Capital Letter H
0x49 0x0049 ;Latin Capital Letter I
0x4A 0x004A ;Latin Capital Letter J
0x4B 0x004B ;Latin Capital Letter K
0x4C 0x004C ;Latin Capital Letter L
0x4D 0x004D ;Latin Capital Letter M
0x4E 0x004E ;Latin Capital Letter N
0x4F 0x004F ;Latin Capital Letter O
0x50 0x0050 ;Latin Capital Letter P
0x51 0x0051 ;Latin Capital Letter Q
0x52 0x0052 ;Latin Capital Letter R
0x53 0x0053 ;Latin Capital Letter S
0x54 0x0054 ;Latin Capital Letter T
0x55 0x0055 ;Latin Capital Letter U
0x56 0x0056 ;Latin Capital Letter V
0x57 0x0057 ;Latin Capital Letter W
0x58 0x0058 ;Latin Capital Letter X
0x59 0x0059 ;Latin Capital Letter Y
0x5A 0x005A ;Latin Capital Letter Z
0x5B 0x005B ;Left Square Bracket
0x5C 0x005C ;Reverse Solidus
0x5D 0x005D ;Right Square Bracket
0x5E 0x005E ;Circumflex Accent
0x5F 0x005F ;Low Line
0x60 0x0060 ;Grave Accent
0x61 0x0061 ;Latin Small Letter A
0x62 0x0062 ;Latin Small Letter B
0x63 0x0063 ;Latin Small Letter C
0x64 0x0064 ;Latin Small Letter D
0x65 0x0065 ;Latin Small Letter E
0x66 0x0066 ;Latin Small Letter F
0x67 0x0067 ;Latin Small Letter G
0x68 0x0068 ;Latin Small Letter H
0x69 0x0069 ;Latin Small Letter I
0x6A 0x006A ;Latin Small Letter J
0x6B 0x006B ;Latin Small Letter K
0x6C 0x006C ;Latin Small Letter L
0x6D 0x006D ;Latin Small Letter M
0x6E 0x006E ;Latin Small Letter N
0x6F 0x006F ;Latin Small Letter O
0x70 0x0070 ;Latin Small Letter P
0x71 0x0071 ;Latin Small Letter Q
0x72 0x0072 ;Latin Small Letter R
0x73 0x0073 ;Latin Small Letter S
0x74 0x0074 ;Latin Small Letter T
0x75 0x0075 ;Latin Small Letter U
0x76 0x0076 ;Latin Small Letter V
0x77 0x0077 ;Latin Small Letter W
0x78 0x0078 ;Latin Small Letter X
0x79 0x0079 ;Latin Small Letter Y
0x7A 0x007A ;Latin Small Letter Z
0x7B 0x007B ;Left Curly Bracket
0x7C 0x007C ;Vertical Line
0x7D 0x007D ;Right Curly Bracket
0x7E 0x007E ;Tilde
0x7F 0x007F ;Delete
0x80 0x0000 ;Null
0x81 0x0001 ;Start Of Heading
0x82 0x0002 ;Start Of Text
0x83 0x0003 ;End Of Text
0x84 0x0004 ;End Of Transmission
0x85 0x0005 ;Enquiry
0x86 0x0006 ;Acknowledge
0x87 0x0007 ;Bell
0x88 0x0008 ;Backspace
0x89 0x0009 ;Character Tabulation
0x8A 0x000A ;Line Feed (LF)
0x8B 0x000B ;Line Tabulation
0x8C 0x000C ;Form Feed (FF)
0x8D 0x000D ;Carriage Return (CR)
0x8E 0x000E ;Shift Out
0x8F 0x000F ;Shift In
0x90 0x0010 ;Data Link Escape
0x91 0x0011 ;Device Control One
0x92 0x0012 ;Device Control Two
0x93 0x0013 ;Device Control Three
0x94 0x0014 ;Device Control Four
0x95 0x0015 ;Negative Acknowledge
0x96 0x0016 ;Synchronous Idle
0x97 0x0017 ;End Of Transmission Block
0x98 0x0018 ;Cancel
0x99 0x0019 ;End Of Medium
0x9A 0x001A ;Substitute
0x9B 0x001B ;Escape
0x9C 0x001C ;Information Separator Four
0x9D 0x001D ;Information Separator Three
0x9E 0x001E ;Information Separator Two
0x9F 0x001F ;Information Separator One
0xA0 0x0020 ;Space
0xA1 0x0021 ;Exclamation Mark
0xA2 0x0022 ;Quotation Mark
0xA3 0x0023 ;Number Sign
0xA4 0x0024 ;Dollar Sign
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
The `setuid` permission
The `sticky bit` permission
Understanding `umask`
Running a command as another local user
`su` vs `sudo`
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<?php
/**
* List Details
*
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 2.7.1
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
/**
* SP_Meta_Box_List_Details
*/
class SP_Meta_Box_List_Details {
/**
* Output the metabox
*/
public static function output( $post ) {
$taxonomies = get_object_taxonomies( 'sp_list' );
$caption = get_post_meta( $post->ID, 'sp_caption', true );
$team_id = get_post_meta( $post->ID, 'sp_team', true );
$era = get_post_meta( $post->ID, 'sp_era', true );
$grouping = get_post_meta( $post->ID, 'sp_grouping', true );
$orderby = get_post_meta( $post->ID, 'sp_orderby', true );
$order = get_post_meta( $post->ID, 'sp_order', true );
$select = get_post_meta( $post->ID, 'sp_select', true );
$number = get_post_meta( $post->ID, 'sp_number', true );
$crop = get_post_meta( $post->ID, 'sp_crop', true );
$date = get_post_meta( $post->ID, 'sp_date', true );
$date_from = get_post_meta( $post->ID, 'sp_date_from', true );
$date_to = get_post_meta( $post->ID, 'sp_date_to', true );
$date_past = get_post_meta( $post->ID, 'sp_date_past', true );
$date_relative = get_post_meta( $post->ID, 'sp_date_relative', true );
$continents = SP()->countries->continents;
$nationalities = get_post_meta( $post->ID, 'sp_nationality', false );
$default_nationality = get_option( 'sportspress_default_nationality' , false );
?>
<div>
<p><strong><?php _e( 'Heading', 'sportspress' ); ?></strong></p>
<p><input type="text" id="sp_caption" name="sp_caption" value="<?php echo esc_attr( $caption ); ?>" placeholder="<?php echo esc_attr( get_the_title() ); ?>"></p>
<div class="sp-date-selector">
<p><strong><?php _e( 'Date', 'sportspress' ); ?></strong></p>
<p>
<?php
$args = array(
'name' => 'sp_date',
'id' => 'sp_date',
'selected' => $date,
);
sp_dropdown_dates( $args );
?>
</p>
<div class="sp-date-range">
<p class="sp-date-range-absolute">
<input type="text" class="sp-datepicker-from" name="sp_date_from" value="<?php echo $date_from ? $date_from : date_i18n( 'Y-m-d' ); ?>" size="10">
:
<input type="text" class="sp-datepicker-to" name="sp_date_to" value="<?php echo $date_to ? $date_to : date_i18n( 'Y-m-d' ); ?>" size="10">
</p>
<p class="sp-date-range-relative">
<?php _e( 'Past', 'sportspress' ); ?>
<input type="number" min="0" step="1" class="tiny-text" name="sp_date_past" value="<?php echo '' !== $date_past ? $date_past : 7; ?>">
<?php _e( 'days', 'sportspress' ); ?>
</p>
<p class="sp-date-relative">
<label>
<input type="checkbox" name="sp_date_relative" value="1" id="sp_date_relative" <?php checked( $date_relative ); ?>>
<?php _e( 'Relative', 'sportspress' ); ?>
</label>
</p>
</div>
</div>
<?php
foreach ( $taxonomies as $taxonomy ) {
sp_taxonomy_field( $taxonomy, $post, true );
}
?>
<p><strong><?php _e( 'Team', 'sportspress' ); ?></strong></p>
<p class="sp-tab-select sp-team-era-selector">
<?php
$args = array(
'post_type' => 'sp_team',
'name' => 'sp_team',
'show_option_all' => __( 'All', 'sportspress' ),
'selected' => $team_id,
'values' => 'ID',
);
if ( ! sp_dropdown_pages( $args ) ):
sp_post_adder( 'sp_team', __( 'Add New', 'sportspress' ) );
endif;
?>
<select name="sp_era">
<option value="all" <?php selected( 'all', $era ); ?>><?php _e( 'All', 'sportspress' ); ?></option>
<option value="current" <?php selected( 'current', $era ); ?>><?php _e( 'Current', 'sportspress' ); ?></option>
<option value="past" <?php selected( 'past', $era ); ?>><?php _e( 'Past', 'sportspress' ); ?></option>
</select>
</p>
<p><strong><?php _e( 'Nationality', 'sportspress' ); ?></strong></p>
<p>
<select id="sp_nationality" name="sp_nationality[]" data-placeholder="<?php printf( __( 'Select %s', 'sportspress' ), __( 'Nationality', 'sportspress' ) ); ?>" class="widefat chosen-select<?php if ( is_rtl() ): ?> chosen-rtl<?php endif; ?>" multiple="multiple">
<option value=""></option>
<?php foreach ( $continents as $continent => $countries ): ?>
<optgroup label="<?php echo $continent; ?>">
<?php foreach ( $countries as $code => $country ): ?>
<option value="<?php echo $code; ?>" <?php selected ( in_array( $code, $nationalities ) ); ?>><?php echo $country; ?></option>
<?php endforeach; ?>
</optgroup>
<?php endforeach; ?>
</select>
</p>
<p><strong><?php _e( 'Grouping', 'sportspress' ); ?></strong></p>
<p>
<select name="sp_grouping">
<option value="0"><?php _e( 'None', 'sportspress' ); ?></option>
<option value="position" <?php selected( $grouping, 'position' ); ?>><?php _e( 'Position', 'sportspress' ); ?></option>
</select>
</p>
<p><strong><?php _e( 'Sort by', 'sportspress' ); ?></strong></p>
<p>
<?php
$args = array(
'prepend_options' => array(
'number' => __( 'Squad Number', 'sportspress' ),
'name' => __( 'Name', 'sportspress' ),
),
'post_type' => array( 'sp_performance', 'sp_metric', 'sp_statistic' ),
'name' => 'sp_orderby',
'selected' => $orderby,
'values' => 'slug',
);
sp_dropdown_pages( $args );
?>
</p>
<p>
<label class="selectit">
<input type="checkbox" name="sp_
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.5002636909484863,
"baseline_truncated": false,
"doc_advantage_score": 0.9128347635269165,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.5480331182479858,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 5455,
"total_sentences": 6,
"truncated": false
}
|
/**
* Copyright (c) 2018-present, Facebook, Inc. and its affiliates.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
include "logdevice/common/if/common.thrift"
include "logdevice/admin/if/nodes.thrift"
namespace cpp2 facebook.logdevice.thrift
namespace go logdevice.admin.if.cluster_membership
namespace py3 logdevice.admin
/**
* This enum contains all the possible ways the cluster membership change
* request can fail because of an invalid input.
*/
enum ClusterMembershipFailureReason {
UNKNOWN = 0,
/**
* The passed common.NodeID didn't match any node in the nodes configuration.
*/
NO_MATCH_IN_CONFIG = 1,
/**
* The operation requires that the node to be DEAD but it's not.
*/
NOT_DEAD = 2,
/**
* The operation requires that the node to be DISABLED/DRAINED for both
* sequencing and storage, but it's not.
*/
NOT_DISABLED = 3,
/**
* The node that you are trying to add already exists.
*/
ALREADY_EXISTS = 4,
/**
* If the passed nodes config is invalid for the operation. Examples of
* invalid configs can be:
* - Update immutable fields (e.g. "location" or "roles").
* - Adding a node with a negative sequencer weight.
* - Changing non service discovery info in an Update request.
* More information about the failure will be in the message.
*/
INVALID_REQUEST_NODES_CONFIG = 5,
}
/**
* The reason why an operation on a node failed in cluster membership change.
*/
struct ClusterMembershipFailedNode {
1: common.NodeID node_id,
2: ClusterMembershipFailureReason reason,
/**
* Human readable error description.
*/
3: string message,
}
exception ClusterMembershipOperationFailed {
1: list<ClusterMembershipFailedNode> failed_nodes,
}
////////////////////////////////////////////////////////////////////////////
/////////////////////////// Add Node Request ///////////////////////////////
////////////////////////////////////////////////////////////////////////////
const common.NodeIndex ANY_NODE_IDX = -1
struct AddSingleNodeRequest {
/**
* Config of the newly added node. Admin server will use this struct to fill
* the information needed for the NodesConfiguration.
*
* Notes:
* - If node_index = ANY_NODE_IDX, the admin server will pick the NodeIndex.
* - The name, addresses & node_index (if set) should all be unique.
* - Roles can't be empty.
* - location_per_scope field is ignored.
*/
1: nodes.NodeConfig new_config,
}
struct AddNodesRequest {
1: list<AddSingleNodeRequest> new_node_requests,
}
struct AddNodesResponse {
/**
* NodeConfigs of the newly added nodes.
*/
1: list<nodes.NodeConfig> added_nodes,
/**
* The version of the updated NodesConfiguration.
*/
2: common.unsigned64 new_nodes_configuration_version,
}
////////////////////////////////////////////////////////////////////////////
/////////////////////////// Update Node Request ////////////////////////////
////////////////////////////////////////////////////////////////////////////
struct UpdateSingleNodeRequest {
/**
* Node to be updated.
*/
1: common.NodeID node_to_be_updated,
/**
* The desired final config for the node. It should include all the attributes
* of the node (even the ones that doesn't need to be updated). The admin
* server will then figure out the fields that changed and apply the update.
*
* Changing immutable attributes (e.g. node_index, location or roles) or
* changing non service discovery info (e.g. sequenecer weight) will fail with
* INVALID_REQUEST_NODES_CONFIG.
*/
2: nodes.NodeConfig new_config,
}
struct UpdateNodesRequest {
/**
* Update requests for each node that needs to be updated.
*/
1: list<UpdateSingleNodeRequest> node_requests,
}
struct UpdateNodesResponse {
/**
* The new NodeConfigs for the updated nodes.
*/
1: list<nodes.NodeConfig> updated_nodes,
/**
* The version of the updated NodesConfiguration.
*/
2: common.unsigned64 new_nodes_configuration_version,
}
////////////////////////////////////////////////////////////////////////////
/////////////////////////// Remove Node Request ////////////////////////////
////////////////////////////////////////////////////////////////////////////
/**
* Request to remove a list of nodes represented by one or more NodesFilters.
*/
struct RemoveNodesRequest {
/**
* List of NodeFilters to remove from the nodes configuration. Matches from
* each filter are union-ed together and are removed from the nodes
* configuration in a single transaction.
*/
1: list<nodes.NodesFilter> node_filters,
}
struct RemoveNodesResponse {
/**
* List of nodes that were successfully removed from config.
*/
1: list<common.NodeID> removed_nodes,
/**
* The version of the updated NodesConfiguration.
*/
2: common.unsigned64 new_nodes_configuration_version,
}
////////////////////////////////////////////////////////////////////////////
////////////////// Mark Shards As Provisioned Request //////////////////////
////////////////////////////////////////////////////////////////////////////
/**
* Request to mark some shard as provisioned, transitioning them from the
* PROVISIONING storage state to NONE.
Request to mark some shards as provisioned, moving them from the PROVISIONING storage state to NONE.
*/
1: common.ShardSet shards,
}
struct MarkShardsAsProvisionedResponse {
/**
* List of shards successfully marked as provisioned.
*/
1: common.ShardSet updated_shards,
/**
* The version of the updated NodesConfiguration.
*/
2: common.unsigned64 new_nodes_configuration_version,
}
////////////////////////////////////////////////////////////////////////////
////////////////////// Bump Generation Request /////////////////////////////
////////////////////////////////////////////////////////////////////////////
/**
* Request to bump the generation of all the nodes that match the passed
* filters.
*/
struct BumpGenerationRequest {
/**
* List of NodeFilters to bump their generationin the nodes configuration.
* Matches from each filter are union-ed together and are updated in the same
* nodes configuration transaction.
*/
1: list<nodes.NodesFilter> node_filters,
}
struct BumpGenerationResponse {
/**
* List of nodes that we successfully bumped the generation for.
*/
1: list<common.NodeID> bumped_nodes,
/**
* The version of the updated NodesConfiguration.
*/
2: common.unsigned64 new_nodes_configuration_version,
}
////////////////////////////////////////////////////////////////////////////
////////////////////// Boostrap Cluster Request ////////////////////////////
////////////////////////////////////////////////////////////////////////////
/**
* Request to finalize the bootstrapping of the cluster
*/
struct BootstrapClusterRequest {
/**
* The metadata replication property that this cluster will have. This will
* be used to provision the initial metadata nodeset.
*/
1: common.ReplicationProperty metadata_replication_property,
}
struct BootstrapClusterResponse {
/**
* The version of the updated NodesConfiguration.
*/
1: common.unsigned64 new_nodes_configuration_version,
}
| null | 1
|
{
"advantage_score_max": 5.42932653427124,
"advantage_score_mean": 2.2412471771240234,
"advantage_score_min": 1.1203681230545044,
"advantage_score_std": 1.2650152444839478,
"advantage_scores": [
5.42932653427124,
4.463676452636719,
3.512721061706543,
2.4659323692321777,
1.971020221710205,
1.949921727180481,
1.797530174255371,
1.7137380838394165,
1.570672869682312,
1.5329651832580566,
1.4437141418457031,
1.2193320989608765,
1.1865415573120117,
1.1203681230545044
],
"baseline_doc_loss": 1.141045331954956,
"baseline_truncated": false,
"doc_advantage_score": 1.0809643268585205,
"length_change_ratio": 1.0309278350515463,
"net_length_change_chars": 3,
"original_sentences_length_chars": 97,
"replacement_paraphrases_length_chars": 100,
"sentences_perturbed": 1,
"target_doc_loss": 1.055580973625183,
"target_truncated": false,
"threshold_passing_sentences": 14,
"total_doc_length_chars": 7354,
"total_sentences": 52,
"truncated": false
}
|
{ 1, 4, 6, 3, 7, 12, 72, 3 }
{ 1, 3, 3, 4, 6, 7, 12, 72 }
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Released under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { CancellationToken } from 'vscode-jsonrpc'
import { FoldingRange } from 'vscode-languageserver-types'
import { TextDocument } from 'vscode-languageserver-textdocument'
import { FoldingContext, FoldingRangeProvider } from 'coc.nvim/lib/provider'
import { workspace } from 'coc.nvim'
import Proto from '../protocol'
import { ITypeScriptServiceClient } from '../typescriptService'
import * as typeConverters from '../utils/typeConverters'
export default class TypeScriptFoldingProvider implements FoldingRangeProvider {
public constructor(private readonly client: ITypeScriptServiceClient) { }
public async provideFoldingRanges(
document: TextDocument,
_context: FoldingContext,
token: CancellationToken
): Promise<FoldingRange[] | undefined> {
const file = this.client.toPath(document.uri)
if (!file) {
return
}
const args: Proto.FileRequestArgs = { file }
const res = await this.client.execute('getOutliningSpans', args, token)
if (res.type != 'response') {
return
}
const { body } = res
if (!body) {
return
}
return body
.map(span => this.convertOutliningSpan(span, document))
.filter(foldingRange => !!foldingRange) as FoldingRange[]
}
private convertOutliningSpan(
span: Proto.OutliningSpan,
document: TextDocument
): FoldingRange | undefined {
const range = typeConverters.Range.fromTextSpan(span.textSpan)
const kind = TypeScriptFoldingProvider.getFoldingRangeKind(span)
// Workaround for #49904
if (span.kind === 'comment') {
let doc = workspace.getDocument(document.uri)
const line = doc.getline(range.start.line)
if (line.match(/\/\/\s*#endregion/gi)) {
return undefined
}
}
let { start, end } = range
return FoldingRange.create(start.line, end.line, start.character, end.character, kind)
}
private static getFoldingRangeKind(
span: Proto.OutliningSpan
): string {
switch (span.kind) {
case 'comment':
case 'region':
case 'imports':
case 'code':
return span.kind
default:
return undefined
}
}
}
| null | 1
|
{
"advantage_score_max": 1.7325440645217896,
"advantage_score_mean": 1.7325440645217896,
"advantage_score_min": 1.7325440645217896,
"advantage_score_std": 0,
"advantage_scores": [
1.7325440645217896
],
"baseline_doc_loss": 0.863197386264801,
"baseline_truncated": false,
"doc_advantage_score": 0.9735898971557617,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 34,
"replacement_paraphrases_length_chars": 34,
"sentences_perturbed": 1,
"target_doc_loss": 0.8866129517555237,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 2502,
"total_sentences": 6,
"truncated": false
}
|
/* FX domain filter corelation coefficient filter*/
#include "su.h"
#include "segy.h"
#define PFA_MAX 720720 /* Largest allowed nfft */
#define PIP2 1.570796327
#define AMPSP(c) rcabs(c)
#define PHSSP(c) atan2(c.i,c.r)
/*********************** self documentation **********************/
char *sdoc[] = {
" SUCCFILT - FX domain Correlation Coefficient FILTER ",
" ",
" sucff < stdin > stdout [optional parameters] ",
" ",
" Optional parameters: ",
" cch=1.0 Correlation coefficient high pass value ",
" ccl=0.5 Correlation coefficient low pass value ",
" key=ep ensemble identifier ",
" padd=20 FFT padding in percentage ",
" ",
NULL};
/*
* Credits:
* Potash Corporation: Balazs Nemeth, Saskatoon Canada. c. 2008
*/
/**************** end self doc ********************************/
segy tr;
segy tr2;
int main( int argc, char *argv[] )
{
cwp_String key; /* header key word from segy.h */
cwp_String type; /* ... its type */
Value val;
segy **rec_o=NULL; /* trace header+data matrix */
int first=0; /* true when we passed the first gather */
int ng=0; /* counter of gathers */
float dt;
int nt;
int ntr;
int nfft=0; /* lenghth of padded array */
float snfft; /* scale factor for inverse fft */
int nf=0; /* number of frequencies */
float *rt=NULL; /* real trace */
complex **fd=NULL; /* frequency domain data */
float **cc=NULL; /* correlation coefficinet matrix */
float padd;
float cch;
float ccl;
int verbose=0;
/* Initialize */
initargs(argc, argv);
requestdoc(1);
if (!getparstring("key", &key)) key = "ep";
if (!getparfloat("padd", &padd)) padd = 25.0;
padd = 1.0+padd/100.0;
if (!getparfloat("cch", &cch)) cch = 1.0;
if (!getparfloat("ccl", &ccl)) ccl = 0.3;
if (!getparint("verbose",&verbose)) verbose = 0;
/* get the first record */
rec_o = get_gather(&key,&type,&val,&nt,&ntr,&dt,&first);
if(ntr==0) err("Can't get first record\n");
/* set up the fft */
nfft = npfar(nt*padd);
if (nfft >= SU_NFLTS || nfft >= PFA_MAX)
err("Padded nt=%d--too big", nfft);
nf = nfft/2 + 1;
snfft=1.0/nfft;
rt = ealloc1float(nfft);
do {
ng++;
fd = ealloc2complex(nf,ntr);
cc = ealloc2float(nf,ntr);
/* transform the data into FX domain */
{ unsigned int itr;
for(itr=0;itr<ntr;itr++) {
memcpy( (void *) rt, (const void *) (*rec_o[itr]).data,nt*FSIZE);
memset( (void *) &rt[nt], (int) '\0', (nfft - nt)*FSIZE);
pfarc(1, nfft, rt, fd[itr]);
}
}
/* Compute correlation coefficients */
{ unsigned int itr,ifr;
for(itr=0;itr<ntr-1;itr++) {
for(ifr=0;ifr<nf-1;ifr++) {
cc[itr][ifr] = cos(PHSSP(fd[itr][ifr])-PHSSP(fd[itr+1][ifr]));
}
}
}
/* Filter */
{ unsigned int itr,ifr;
for(itr=0;itr<ntr-1;itr++) {
for(ifr=0;ifr<nf-1;ifr++) {
if(cc[itr][ifr]> cch || cc[itr][ifr]<ccl) {
fd[itr][ifr].r = 0.0;
fd[itr][ifr].i = 0.0;
}
}
}
}
{ unsigned int itr,it;
for(itr=0;itr<ntr;itr++) {
pfacr(-1, nfft, fd[itr], rt);
for(it=0;it<nt;it++)
(*rec_o[itr]).data[it]=rt[it]*snfft;
}
}
free2complex(fd);
free2float(cc);
rec_o = put_gather(rec_o,&nt,&ntr);
rec_o = get_gather(&key,&type,&val,&nt,&ntr,&dt,&first);
if (verbose) warn(" %d %d\n",ng,ntr);
} while(ntr);
free1float(rt);
warn("Number of gathers %10d\n",ng);
return EXIT_SUCCESS;
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
using System;
using System.Collections.Concurrent;
using System.Net.Http;
namespace cloudscribe.Email.Senders
{
public class DefaultServiceClientProvider : IServiceClientProvider // Register as singleton
{
public DefaultServiceClientProvider()
{
_httpClients = new ConcurrentDictionary<Uri, HttpClient>();
}
private readonly ConcurrentDictionary<Uri, HttpClient> _httpClients;
public HttpClient GetOrCreateHttpClient(Uri baseAddress)
{
return _httpClients.GetOrAdd(baseAddress,
b => new HttpClient { BaseAddress = b });
}
public void Dispose()
{
foreach (var httpClient in _httpClients.Values)
{
httpClient.Dispose();
}
}
}
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
From c98680380b35e7358e7ab7a25d8f2d5e9330b170 Mon Sep 17 00:00:00 2001
From: Laurentiu Tudor <laurentiu.tudor@nxp.com>
Date: Wed, 10 Jan 2018 16:29:49 +0200
Subject: [PATCH 071/107] armv8: fsl-layerscape: add missing register blocks base address defines
Add defines for the edma and qdma register block base addresses.
Signed-off-by: Laurentiu Tudor <laurentiu.tudor@nxp.com>
---
.../include/asm/arch-fsl-layerscape/immap_lsch2.h | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch2.h b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch2.h
index af68af4..b1f3d22 100644
--- a/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch2.h
+++ b/arch/arm/include/asm/arch-fsl-layerscape/immap_lsch2.h
@@ -89,8 +89,12 @@
#define LPUART_BASE (CONFIG_SYS_IMMR + 0x01950000)
+#define EDMA_BASE_ADDR (CONFIG_SYS_IMMR + 0x01c00000)
+
#define AHCI_BASE_ADDR (CONFIG_SYS_IMMR + 0x02200000)
+#define QDMA_BASE_ADDR (CONFIG_SYS_IMMR + 0x07380000)
+
#define CONFIG_SYS_PCIE1_PHYS_ADDR 0x4000000000ULL
#define CONFIG_SYS_PCIE2_PHYS_ADDR 0x4800000000ULL
#define CONFIG_SYS_PCIE3_PHYS_ADDR 0x5000000000ULL
--
1.7.1
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
var LodashWrapper = require('./_LodashWrapper');
/**
* Executes the chain sequence and returns the wrapped result.
Executes the chained operations and returns a new lodash wrapper object containing the result.
* @example
*
* var array = [1, 2];
* var wrapped = _(array).push(3);
*
* console.log(array);
* // => [1, 2]
*
* wrapped = wrapped.commit();
* console.log(array);
* // => [1, 2, 3]
*
* wrapped.last();
* // => 3
*
* console.log(array);
* // => [1, 2, 3]
*/
function wrapperCommit() {
return new LodashWrapper(this.value(), this.__chain__);
}
module.exports = wrapperCommit;
| null | 1
|
{
"advantage_score_max": 1.7199400663375854,
"advantage_score_mean": 1.7199400663375854,
"advantage_score_min": 1.7199400663375854,
"advantage_score_std": 0,
"advantage_scores": [
1.7199400663375854
],
"baseline_doc_loss": 0.520671010017395,
"baseline_truncated": false,
"doc_advantage_score": 3.900697946548462,
"length_change_ratio": 0.7286821705426356,
"net_length_change_chars": -35,
"original_sentences_length_chars": 129,
"replacement_paraphrases_length_chars": 94,
"sentences_perturbed": 1,
"target_doc_loss": 0.13348150253295898,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 641,
"total_sentences": 3,
"truncated": false
}
|
const components = [
{
title: 'Appbar',
path: '/components/appbar',
},
{
title: 'Searchbar',
path: '/components/searchbar',
subsubItem: true,
},
{
title: 'Appbar Bottom',
path: '/components/appbar-bottom',
},
{
title: 'Avatar',
path: '/components/avatar',
},
{
title: 'Backdrop',
path: '/components/backdrop',
},
{
title: 'Badge',
path: '/components/badge',
},
{
title: 'Banner',
path: '/components/banner',
},
{
title: 'Bottom Navigation',
path: '/components/bottom-navigation',
},
{
title: 'Bottom Navigation Item',
path: '/components/bottom-navigation-item',
subsubItem: true,
},
{
title: 'Button',
path: '/components/button',
},
{
title: 'Card',
path: '/components/card',
},
{
title: 'CardActions',
path: '/components/card-actions',
subsubItem: true,
},
{
title: 'CardContent',
path: '/components/card-content',
subsubItem: true,
},
{
title: 'CardHeader',
path: '/components/card-header',
subsubItem: true,
},
{
title: 'CardMedia',
path: '/components/card-media',
subsubItem: true,
},
{
title: 'Checkbox',
path: '/components/checkbox',
},
{
title: 'Chip',
path: '/components/chip',
},
{
title: 'DataTable',
path: '/components/datatable',
},
{
title: 'DataTableCell',
path: '/components/datatable-cell',
subsubItem: true,
},
{
title: 'DataTableHeader',
path: '/components/datatable-header',
subsubItem: true,
},
{
title: 'DataTablePagination',
path: '/components/datatable-pagination',
subsubItem: true,
},
{
title: 'DataTableRow',
path: '/components/datatable-row',
subsubItem: true,
},
{
title: 'Dialog',
path: '/components/dialog',
},
{
title: 'Divider',
path: '/components/divider',
},
{
title: 'Drawer',
path: '/components/drawer',
},
{
title: 'DrawerHeader',
path: '/components/drawer-header',
subsubItem: true,
},
{
title: 'DrawerItem',
path: '/components/drawer-item',
subsubItem: true,
},
{
title: 'DrawerSection',
path: '/components/drawer-section',
subsubItem: true,
},
{
title: 'DrawerBottom',
path: '/components/drawer-bottom',
},
{
title: 'Fab',
path: '/components/fab',
},
{
title: 'Speed dial',
path: '/components/fab-speeddial',
subsubItem: true,
},
{
title: 'Icon',
path: '/components/icon',
},
{
title: 'IconButton',
path: '/components/iconbutton',
},
{
title: 'List',
path: '/components/list',
},
{
title: 'ListExpand',
path: '/components/list-expand',
subsubItem: true,
},
{
title: 'ListItem',
path: '/components/list-item',
subsubItem: true,
},
{
title: 'ListSection',
path: '/components/list-section',
subsubItem: true,
},
{
title: 'Menu',
path: '/components/menu',
},
{
title: 'MenuItem',
path: '/components/menu-item',
subsubItem: true,
},
{
title: 'Paper',
path: '/components/paper',
},
{
title: 'Progress Bar',
path: '/components/progress-bar',
},
{
title: 'Progress Circle',
path: '/components/progress-circle',
},
{
title: 'Radio Button',
path: '/components/radiobutton',
},
{
title: 'Ripple',
path: '/components/ripple',
},
{
title: 'Select',
path: '/components/select',
},
{
title: 'SheetBottom',
path: '/components/sheet-bottom',
},
{
title: 'SheetSide',
path: '/components/sheet-side',
},
{
title: 'Slider',
path: '/components/slider',
},
{
title: 'Snackbar',
path: '/components/snackbar',
},
{
title: 'SwipeNav',
path: '/components/swipenav',
},
{
title: 'Switch',
path: '/components/switch',
},
{
title: 'Tabs',
path: '/components/tabs',
},
{
title: 'Tab',
path: '/components/tab',
subsubItem: true,
},
{
title: 'Textfield',
path: '/components/textfield',
},
{
title: 'Searchfield',
path: '/components/searchfield',
subsubItem: true,
},
{
title: 'ToggleButton',
path: '/components/togglebutton',
},
{
title: 'ToggleButtonGroup',
path: '/components/togglebutton-group',
subsubItem: true,
},
{
title: 'Tooltip',
path: '/components/tooltip',
},
{
title: 'Typography',
path: '/components/typography',
},
];
export default components;
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
function y = vl_aibcutpush(map, x)
% VL_AIBCUTPUSH Quantize based on VL_AIB cut
% Y = VL_AIBCUTPUSH(MAP, X) maps the data X to elements of the AIB
% cut specified by MAP.
%
% The function is equivalent to Y = MAP(X).
%
% See also: VL_HELP(), VL_AIB().
% Copyright (C) 2007-12 Andrea Vedaldi and Brian Fulkerson.
Copyright reserved worldwide.
%
% This file is part of the VLFeat library and is made available under
% the terms of the BSD license (see the COPYING file).
y = map(x) ;
| null | 1
|
{
"advantage_score_max": 1.5087404251098633,
"advantage_score_mean": 1.5087404251098633,
"advantage_score_min": 1.5087404251098633,
"advantage_score_std": 0,
"advantage_scores": [
1.5087404251098633
],
"baseline_doc_loss": 1.2959145307540894,
"baseline_truncated": false,
"doc_advantage_score": 1.4676264524459839,
"length_change_ratio": 1.3181818181818181,
"net_length_change_chars": 7,
"original_sentences_length_chars": 22,
"replacement_paraphrases_length_chars": 29,
"sentences_perturbed": 1,
"target_doc_loss": 0.8830002546310425,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 482,
"total_sentences": 7,
"truncated": false
}
|
<!DOCTYPE html>
<html>
<div>
<div>
<div>
<strong>Text</strong>
</div>
</div>
</div>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
component accessors="true" mappedSuperClass="true"{
property name="superPersistentField";
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
var searchData=
[
['other_250',['OTHER',['../namespace_a_d_c___error.html#ad050c44d1f3422d02e5f9726edeee8f0a03570470bad94692ce93e32700d2e1cb',1,'ADC_Error']]]
];
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
Copyright The Kubernetes Authors.
Distributed under the Apache License, Version 2.0 (the "License"); you may not use this file except in accordance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Code generated by lister-gen. DO NOT EDIT.
package v1beta1
import (
v1beta1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1beta1"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/client-go/tools/cache"
)
// CustomResourceDefinitionLister helps list CustomResourceDefinitions.
type CustomResourceDefinitionLister interface {
// List lists all CustomResourceDefinitions in the indexer.
List(selector labels.Selector) (ret []*v1beta1.CustomResourceDefinition, err error)
// Get retrieves the CustomResourceDefinition from the index for a given name.
Get(name string) (*v1beta1.CustomResourceDefinition, error)
CustomResourceDefinitionListerExpansion
}
// customResourceDefinitionLister implements the CustomResourceDefinitionLister interface.
type customResourceDefinitionLister struct {
indexer cache.Indexer
}
// NewCustomResourceDefinitionLister returns a new CustomResourceDefinitionLister.
func NewCustomResourceDefinitionLister(indexer cache.Indexer) CustomResourceDefinitionLister {
return &customResourceDefinitionLister{indexer: indexer}
}
// List lists all CustomResourceDefinitions in the indexer.
func (s *customResourceDefinitionLister) List(selector labels.Selector) (ret []*v1beta1.CustomResourceDefinition, err error) {
err = cache.ListAll(s.indexer, selector, func(m interface{}) {
ret = append(ret, m.(*v1beta1.CustomResourceDefinition))
})
return ret, err
}
// Get retrieves the CustomResourceDefinition from the index for a given name.
func (s *customResourceDefinitionLister) Get(name string) (*v1beta1.CustomResourceDefinition, error) {
obj, exists, err := s.indexer.GetByKey(name)
if err != nil {
return nil, err
}
if !exists {
return nil, errors.NewNotFound(v1beta1.Resource("customresourcedefinition"), name)
}
return obj.(*v1beta1.CustomResourceDefinition), nil
}
| null | 1
|
{
"advantage_score_max": 4.190093994140625,
"advantage_score_mean": 3.3976850509643555,
"advantage_score_min": 2.605276107788086,
"advantage_score_std": 0.7924089431762695,
"advantage_scores": [
4.190093994140625,
2.605276107788086
],
"baseline_doc_loss": 0.25206249952316284,
"baseline_truncated": false,
"doc_advantage_score": 7.245604515075684,
"length_change_ratio": 1.0234375,
"net_length_change_chars": 3,
"original_sentences_length_chars": 128,
"replacement_paraphrases_length_chars": 131,
"sentences_perturbed": 1,
"target_doc_loss": 0.034788332879543304,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 2428,
"total_sentences": 14,
"truncated": false
}
|
/*
Drawpile - a collaborative drawing program.
Copyright (C) 2014 Calle Laakkonen
Drawpile is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Drawpile is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Refer to the GNU General Public License for further information.
You should have received a copy of the GNU General Public License
along with Drawpile. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef BRUSHPREVIEW_PLUGIN_H
#define BRUSHPREVIEW_PLUGIN_H
#include <QtUiPlugin/QDesignerCustomWidgetCollectionInterface>
class BrushPreviewPlugin : public QObject, public QDesignerCustomWidgetInterface
{
Q_OBJECT
Q_INTERFACES(QDesignerCustomWidgetInterface)
public:
BrushPreviewPlugin(QObject *parent = 0);
bool isContainer() const;
bool isInitialized() const;
QIcon icon() const;
QString domXml() const;
QString group() const;
QString includeFile() const;
QString name() const;
QString toolTip() const;
QString whatsThis() const;
QWidget *createWidget(QWidget *parent);
void initialize(QDesignerFormEditorInterface *core);
private:
bool initialized;
};
#endif
| null | 1
|
{
"advantage_score_max": 8.857479095458984,
"advantage_score_mean": 5.539286136627197,
"advantage_score_min": 1.4338494539260864,
"advantage_score_std": 3.081383228302002,
"advantage_scores": [
8.857479095458984,
6.326529502868652,
1.4338494539260864
],
"baseline_doc_loss": 0.4671047329902649,
"baseline_truncated": false,
"doc_advantage_score": 1.3010549545288086,
"length_change_ratio": 1.1636363636363636,
"net_length_change_chars": 9,
"original_sentences_length_chars": 55,
"replacement_paraphrases_length_chars": 64,
"sentences_perturbed": 1,
"target_doc_loss": 0.3590199947357178,
"target_truncated": false,
"threshold_passing_sentences": 3,
"total_doc_length_chars": 1407,
"total_sentences": 7,
"truncated": false
}
|
<?xml version="1.0" encoding="UTF-8"?>
<DIF xmlns="http://gcmd.gsfc.nasa.gov/Aboutus/xml/dif/"
xmlns:dif="http://gcmd.gsfc.nasa.gov/Aboutus/xml/dif/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://gcmd.gsfc.nasa.gov/Aboutus/xml/dif/ http://gcmd.gsfc.nasa.gov/Aboutus/xml/dif/dif_v10.2.xsd">
<Entry_ID>
<Short_Name>GPM_2ADPR</Short_Name>
<Version>05</Version>
</Entry_ID>
<Version_Description>Not provided</Version_Description>
<Entry_Title>GPM DPR Precipitation Profile L2A 1.5 hours 5 km V05 (GPM_2ADPR) at GES DISC</Entry_Title>
<Dataset_Citation>
<Dataset_Creator>Toshio Iguchi, Robert Meneghini</Dataset_Creator>
<Dataset_Title>GPM DPR Precipitation Profile L2A 1.5 hours 5 km V05</Dataset_Title>
<Dataset_Series_Name>GPM_2ADPR</Dataset_Series_Name>
<Dataset_Release_Date>2017-05-17</Dataset_Release_Date>
<Dataset_Release_Place>Greenbelt, MD</Dataset_Release_Place>
<Dataset_Publisher>Goddard Earth Sciences Data and Information Services Center (GES DISC)</Dataset_Publisher>
<Version>05</Version>
<Data_Presentation_Form>Digital Science Data</Data_Presentation_Form>
<Persistent_Identifier>
<Type>DOI</Type>
<Identifier>10.5067/GPM/DPR/GPM/2A/05</Identifier>
</Persistent_Identifier>
<Online_Resource>https://disc.gsfc.nasa.gov/datacollection/GPM_2ADPR_05.html</Online_Resource>
</Dataset_Citation>
<Personnel>
<Role>TECHNICAL CONTACT</Role>
<Contact_Person>
<First_Name>JOYCE</First_Name>
<Last_Name>CHOU</Last_Name>
<Address>
<Street_Address>NASA Goddard Space Flight Center</Street_Address>
<Street_Address>Mailstop 610.2</Street_Address>
<City>Greenbelt</City>
<State_Province>MD</State_Province>
<Postal_Code>20771</Postal_Code>
<Country>USA</Country>
</Address>
<Phone>
<Number>301-614-6870</Number>
<Type>Telephone</Type>
</Phone>
<Phone>
<Number>301-614-5575</Number>
<Type>Fax</Type>
</Phone>
<Email>helpdesk@pps-mail.nascom.nasa.gov</Email>
</Contact_Person>
</Personnel>
<Personnel>
<Role>METADATA AUTHOR</Role>
<Contact_Person>
<First_Name>ANDREY</First_Name>
<Last_Name>SAVTCHENKO</Last_Name>
<Address>
<Street_Address>Distributed Active Archive Center Global Change Data Center</Street_Address>
<Street_Address>Code 610.2</Street_Address>
<Street_Address>NASA Goddard Space Flight Center</Street_Address>
<City>Greenbelt</City>
<State_Province>MD</State_Province>
<Postal_Code>20771</Postal_Code>
<Country>USA</Country>
</Address>
<Phone>
<Number>301-614-5705</Number>
<Type>Telephone</Type>
</Phone>
<Email>Andrey.Savtchenko@nasa.gov</Email>
</Contact_Person>
</Personnel>
<Science_Keywords>
<Category>EARTH SCIENCE</Category>
<Topic>ATMOSPHERE</Topic>
<Term>ATMOSPHERIC WATER VAPOR</Term>
</Science_Keywords>
<Science_Keywords>
<Category>EARTH SCIENCE</Category>
<Topic>ATMOSPHERE</Topic>
<Term>PRECIPITATION</Term>
</Science_Keywords>
<Science_Keywords>
<Category>EARTH SCIENCE</Category>
<Topic>SPECTRAL/ENGINEERING</Topic>
<Term>RADAR</Term>
</Science_Keywords>
<ISO_Topic_Category>CLIMATOLOGY/METEOROLOGY/ATMOSPHERE</ISO_Topic_Category>
<Ancillary_Keyword>Atmosphere, Precipitation, Water Vapor</Ancillary_Keyword>
<Platform>
<Type>Earth Observation Satellites</Type>
<Short_Name>GPM</Short_Name>
<Long_Name>Global Precipitation Measurement</Long_Name>
<Instrument>
<Short_Name>DPR</Short_Name>
<Long_Name>Dual-frequency Precipitation Radar</Long_Name>
</Instrument>
</Platform>
<Temporal_Coverage>
<Range_DateTime>
<Beginning_Date_Time>2014-03-08</Beginning_Date_Time>
</Range_DateTime>
</Temporal_Coverage>
<Dataset_Progress>IN WORK</Dataset_Progress>
<Spatial_Coverage>
<Granule_Spatial_Representation>GEODETIC</Granule_Spatial_Representation>
<Geometry>
<Coordinate_System>GEODETIC</Coordinate_System>
<Bounding_Rectangle>
<Southernmost_Latitude>-70.0</Southernmost_Latitude>
<Northernmost_Latitude>70.0</Northernmost_Latitude>
<Westernmost_Longitude>-180.0</Westernmost_Longitude>
<Easternmost_Longitude>180.0</Easternmost_Longitude>
</Bounding_Rectangle>
</Geometry>
</Spatial_Coverage>
<Location>
<Location_Category>GEOGRAPHIC REGION</Location_Category>
<Location_Type>TROPICS</Location_Type>
</Location>
<Data_Resolution>
<Latitude_Resolution>5 km</Latitude_Resolution>
<Longitude_Resolution>5 km</Longitude_Resolution>
<Vertical_Resolution>125-250 m</Vertical_Resolution>
<Temporal_Resolution>1.5 hours</Temporal_Resolution>
</Data_Resolution>
<Project>
<Short_Name>GPM</Short_Name>
<Long_Name>Global Precipitation Measurement</Long_Name>
</Project>
<Quality>The presence of changing topography (ex.: mountains) presents challenges to the ability of the algorithm to distinguish between precipitation echo and surface clutter. The Ka frequency undergoes larger extinction through precipitation, and the dual-frequency retrieval may be limited to lower-moderate rain rates. As the DPR will be the first dual-frequency weather radar flown in space, dual-frequency retrieval methods will need extensive testing and validation.
Major sources of error that have an impact on estimates of surface precipitation include clutter contamination of near-surface echoes, incorrect identification of precipitation type (convective/stratiform), and severe attenuation of the Ka-band data in heavy precipitation.</Quality>
<Access_Constraints>None</Access_Constraints>
<Dataset_Language>English</Dataset_Language>
<Originating_Center>Precipitation Processing System (PPS)</Originating_Center>
<Organization>
<Organization_Type>ARCHIVER</Organization_Type>
<Organization_Name>
<Short_Name>NASA/GSFC/SED/ESD/GCDC/
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.8203690052032471,
"baseline_truncated": false,
"doc_advantage_score": 1.42190420627594,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.5769509673118591,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 6696,
"total_sentences": 5,
"truncated": false
}
|
/*
This file is part of GOTCHA. For copyright details, refer to the COPYRIGHT file in the top-level directory or visit https://github.com/LLNL/gotcha/blob/master/COPYRIGHT. This program is free software; you can redistribute and/or modify it under the terms of the GNU Lesser General Public License version 2.1 (February 1999). This program is
distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
without even the IMPLIED WARRANTY OF MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the terms and conditions of the GNU Lesser General Public License
for more details. You should have received a copy of the GNU Lesser General
Public License along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "translations.h"
#include "libc_wrappers.h"
#include "gotcha/gotcha.h"
#include "gotcha/gotcha_types.h"
#include "gotcha_utils.h"
#include "gotcha_auxv.h"
#include "gotcha_dl.h"
#include "elf_ops.h"
#include "tool.h"
static void writeAddress(void* write, void* value){
*(void**)write = value;
}
static void** getBindingAddressPointer(struct gotcha_binding_t* in){
return (void**)in->function_handle;
}
static void setBindingAddressPointer(struct gotcha_binding_t* in, void* value){
void **target = getBindingAddressPointer(in);
debug_printf(3, "Updating binding address pointer at %p to %p\n", target, value);
writeAddress(target, value);
}
static void** getInternalBindingAddressPointer(struct internal_binding_t** in){
return (void**)&((*in)->wrappee_pointer);
}
static void setInternalBindingAddressPointer(void** in, void* value){
void** target = getInternalBindingAddressPointer((struct internal_binding_t**)in);
debug_printf(3, "Updating binding address pointer at %p to %p\n", target, value);
writeAddress(target, value);
}
int prepare_symbol(struct internal_binding_t *binding)
{
int result;
struct link_map *lib;
struct gotcha_binding_t *user_binding = binding->user_binding;
debug_printf(2, "Looking up exported symbols for %s\n", user_binding->name);
for (lib = _r_debug.r_map; lib != 0; lib = lib->l_next) {
struct library_t *int_library = get_library(lib);
if (!int_library) {
debug_printf(3, "Creating new library object for %s\n", LIB_NAME(lib));
int_library = add_library(lib);
}
if (is_vdso(lib)) {
debug_printf(2, "Skipping VDSO library at 0x%lx with name %s\n",
lib->l_addr, LIB_NAME(lib));
continue;
}
debug_printf(2, "Searching for exported symbols in %s\n", LIB_NAME(lib));
INIT_DYNAMIC(lib);
if (!gnu_hash && !elf_hash) {
debug_printf(3, "Library %s does not export or import symbols\n", LIB_NAME(lib));
continue;
}
result = -1;
if (gnu_hash) {
debug_printf(3, "Checking GNU hash for %s in %s\n",
user_binding->name, LIB_NAME(lib));
result = lookup_gnu_hash_symbol(user_binding->name, symtab, strtab,
(struct gnu_hash_header *) gnu_hash);
}
if (elf_hash && result == -1) {
debug_printf(3, "Checking ELF hash for %s in %s\n",
user_binding->name, LIB_NAME(lib));
result = lookup_elf_hash_symbol(user_binding->name, symtab, strtab,
(ElfW(Word) *)elf_hash);
}
if (result == -1) {
debug_printf(3, "%s not found in %s\n",
user_binding->name, LIB_NAME(lib));
continue;
}
if (! GOTCHA_CHECK_VISIBILITY(symtab[result])) {
debug_printf(3, "Symbol %s found but not exported in %s\n",
user_binding->name, LIB_NAME(lib));
continue;
}
debug_printf(2, "Symbol %s found in %s at 0x%lx\n",
user_binding->name, LIB_NAME(lib),
symtab[result].st_value + lib->l_addr);
setInternalBindingAddressPointer(user_binding->function_handle,(void *)(symtab[result].st_value + lib->l_addr));
return 0;
}
debug_printf(1, "Symbol %s was found in program\n", user_binding->name);
return -1;
}
static void insert_at_head(struct internal_binding_t *binding, struct internal_binding_t *head)
{
binding->next_binding = head;
setInternalBindingAddressPointer(binding->user_binding->function_handle, head->user_binding->wrapper_pointer);
removefrom_hashtable(&function_hash_table, (void*) binding->user_binding->name);
addto_hashtable(&function_hash_table, (void*)binding->user_binding->name, (void*)binding);
}
static void insert_after_pos(struct internal_binding_t *binding, struct internal_binding_t *pos)
{
setInternalBindingAddressPointer(binding->user_binding->function_handle, pos->wrappee_pointer);
setInternalBindingAddressPointer(pos->user_binding->function_handle, binding->user_binding->wrapper_pointer);
binding->next_binding = pos->next_binding;
pos->next_binding = binding;
}
#define RWO_NOCHANGE 0
#define RWO_NEED_LOOKUP (1 << 0)
#define RWO_NEED_BINDING (1 << 1)
static int rewrite_wrapper_orders(struct internal_binding_t* binding)
{
const char* name = binding->user_binding->name;
int insert_priority = get_priority(binding->associated_binding_table->tool);
if(gotcha_strcmp(name,"main")==0){
if(!main_wrapped){
debug_printf(2, "Wrapping main with Gotcha's internal wrappers");
main_wrapped = 1;
gotcha_wrap(libc_main_wrappers,1,"gotcha");
gotcha_wrap(main_wrappers,1,"gotcha");
}
}
debug_printf(2, "gotcha_rewrite_wrapper_orders for binding %s in tool %s of priority %d\n",
name, binding->associated_binding_table->tool->tool_name, insert_priority);
struct internal_binding_t* head;
int hash_result;
hash_result = lookup_hashtable(&function_hash_table, (void*)name, (void**)&head);
if(hash_result != 0) {
debug_printf(2, "Adding new entry for %s to hash table\n", name);
addto_hashtable(&function_hash_table, (void *) name, (void *) binding);
return (RWO_NEED_LOOKUP | RWO_NEED_BINDING);
}
int head_priority = get_priority(head->associated_binding_table->tool);
if (head_priority < insert_priority) {
debug_printf(2, "New binding priority %d is greater than head priority %d, adding to head\n",
insert_priority, head_priority);
insert_at_head(binding, head);
return RWO_NEED_BINDING;
}
struct internal_binding_t* cur;
for (cur = head; cur->next_binding; cur
| null | 1
|
{
"advantage_score_max": 1.219437837600708,
"advantage_score_mean": 1.219437837600708,
"advantage_score_min": 1.219437837600708,
"advantage_score_std": 0,
"advantage_scores": [
1.219437837600708
],
"baseline_doc_loss": 0.9945520758628845,
"baseline_truncated": false,
"doc_advantage_score": 1.089735746383667,
"length_change_ratio": 0.8575581395348837,
"net_length_change_chars": -49,
"original_sentences_length_chars": 344,
"replacement_paraphrases_length_chars": 295,
"sentences_perturbed": 1,
"target_doc_loss": 0.9126543402671814,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 6631,
"total_sentences": 6,
"truncated": false
}
|
/* Copyright 2010-present MongoDB Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
namespace MongoDB.Bson.Serialization
{
/// <summary>
/// Represents a serializer that has a Representation property.
/// </summary>
public interface IRepresentationConfigurable
{
/// <summary>
/// Gets the representation.
Gets the value of the representation property.
/// </value>
BsonType Representation { get; }
/// <summary>
/// Returns a serializer that has been reconfigured with the specified representation.
/// </summary>
/// <param name="representation">The representation.</param>
/// <returns>The reconfigured serializer.</returns>
IBsonSerializer WithRepresentation(BsonType representation);
}
/// <summary>
/// Represents a serializer that has a Representation property.
/// </summary>
/// <typeparam name="TSerializer">The type of the serializer.</typeparam>
public interface IRepresentationConfigurable<TSerializer> : IRepresentationConfigurable where TSerializer : IBsonSerializer
{
/// <summary>
/// Returns a serializer that has been reconfigured with the specified representation.
/// </summary>
/// <param name="representation">The representation.</param>
/// <returns>The reconfigured serializer.</returns>
new TSerializer WithRepresentation(BsonType representation);
}
}
| null | 1
|
{
"advantage_score_max": 8.991798400878906,
"advantage_score_mean": 8.991798400878906,
"advantage_score_min": 8.991798400878906,
"advantage_score_std": 0,
"advantage_scores": [
8.991798400878906
],
"baseline_doc_loss": 0.4031679630279541,
"baseline_truncated": false,
"doc_advantage_score": 1.7023082971572876,
"length_change_ratio": 0.696969696969697,
"net_length_change_chars": -20,
"original_sentences_length_chars": 66,
"replacement_paraphrases_length_chars": 46,
"sentences_perturbed": 1,
"target_doc_loss": 0.2368360459804535,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 1990,
"total_sentences": 10,
"truncated": false
}
|
################################################################################
#
# Copyright 2015-2020 Félix Brezo and Yaiza Rubio
#
# This program is part of OSRFramework. You can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
################################################################################
__author__ = "Felix Brezo, Yaiza Rubio <contacto@i3visio.com>"
__version__ = "2.0"
from osrframework.utils.platforms import Platform
class Goodreads(Platform):
"""A <Platform> object for Goodreads"""
def __init__(self):
self.platformName = "Goodreads"
self.tags = ["social", "opinions"]
########################
# Defining valid modes #
########################
self.isValidMode = {}
self.isValidMode["phonefy"] = False
self.isValidMode["usufy"] = True
self.isValidMode["searchfy"] = False
######################################
# Search URL for the different modes #
######################################
# Strings with the URL for each and every mode
self.url = {}
#self.url["phonefy"] = "http://anyurl.com//phone/" + "<phonefy>"
self.url["usufy"] = "http://www.goodreads.com/" + "<usufy>"
#self.url["searchfy"] = "http://anyurl.com/search/" + "<searchfy>"
######################################
# Whether the user needs credentials #
######################################
self.needsCredentials = {}
#self.needsCredentials["phonefy"] = False
self.needsCredentials["usufy"] = False
#self.needsCredentials["searchfy"] = False
#################
# Valid queries #
#################
# Strings that will imply that the query number is not appearing
self.validQuery = {}
# The regular expression '.+' will match any query.
#self.validQuery["phonefy"] = ".The query does not appear in the results.*"
###################
# Not_found clues #
###################
# Strings that will imply that the query number is not appearing
self.notFoundText = {}
#self.notFoundText["phonefy"] = []
self.notFoundText["usufy"] = ["<title>Page not found</title>"]
#self.notFoundText["searchfy"] = []
#########################
# Fields to be searched #
#########################
self.fieldsRegExp = {}
# Definition of regular expressions to be searched in phonefy mode
#self.fieldsRegExp["phonefy"] = {}
# Example of fields:
#self.fieldsRegExp["phonefy"]["i3visio.location"] = ""
# Definition of regular expressions to be searched in usufy mode
self.fieldsRegExp["usufy"] = {}
# Example of fields:
#self.fieldsRegExp["usufy"]["i3visio.location"] = ""
# Definition of regular expressions to be searched in searchfy mode
#self.fieldsRegExp["searchfy"] = {}
# Example of fields:
#self.fieldsRegExp["searchfy"]["i3visio.location"] = ""
################
# Fields found #
################
# This attribute will be feeded when running the program.
self.foundFields = {}
| null | 1
|
{
"advantage_score_max": 1.929866075515747,
"advantage_score_mean": 1.929866075515747,
"advantage_score_min": 1.929866075515747,
"advantage_score_std": 0,
"advantage_scores": [
1.929866075515747
],
"baseline_doc_loss": 0.9613047242164612,
"baseline_truncated": false,
"doc_advantage_score": 2.136167526245117,
"length_change_ratio": 0.4880952380952381,
"net_length_change_chars": -43,
"original_sentences_length_chars": 84,
"replacement_paraphrases_length_chars": 41,
"sentences_perturbed": 1,
"target_doc_loss": 0.45001375675201416,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 3898,
"total_sentences": 11,
"truncated": false
}
|
/*
* Copyright (c) 2000-2011 Apple Computer, Inc. All rights reserved.
*
* @APPLE_OSREFERENCE_LICENSE_HEADER_START@
*
* This file contains Original Code and/or Modifications of Original Code
* as defined in and that are subject to the Apple Public Source License
* Version 2.0 (the 'License'). You may not use this file except in
* compliance with the License. The rights granted to you under the License
* may not be used to create, or enable the creation or redistribution of,
* unlawful or unlicensed copies of an Apple operating system, or to
* circumvent, violate, or enable the circumvention or violation of, any
* terms of an Apple operating system software license agreement.
*
* Please obtain a copy of the License at
* http://www.opensource.apple.com/apsl/ and read it before using this file.
*
* The Original Code and all software distributed under the License are
* distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
* EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
* INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
* Please see the License for the specific language governing rights and
* limitations under the License.
*
* @APPLE_OSREFERENCE_LICENSE_HEADER_END@
*/
/*
* @OSF_COPYRIGHT@
*/
/*
* Mach Operating System
* Copyright (c) 1991,1990 Carnegie Mellon University
* All Rights Reserved.
Permission is hereby granted, free of charge, to use, copy, modify, and distribute this software and its documentation, provided that the copyright notice and this permission notice appear in all copies of the software, derivative works, or modified versions, and any portions thereof, and that both notices are included in supporting documentation.CARNEGIE MELLON PERMITS THE USE OF THIS SOFTWARE IN ITS PRESENT "AS IS" STATE.N. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
* ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
*
* Carnegie Mellon requests users of this software to return to
*
* Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
* School of Computer Science
* Carnegie Mellon University
* Pittsburgh PA 15213-3890
*
* any improvements or extensions that they make and grant Carnegie Mellon
* the rights to redistribute these changes.
*/
#include <mach_kdp.h>
#include <mach/vm_param.h>
#include <x86_64/lowglobals.h>
/*
* on x86_64 the low mem vectors live here and get mapped to 0xffffff8000002000 at
* system startup time
*/
extern void *version;
extern void *kmod;
extern void *kdp_trans_off;
extern void *kdp_read_io;
extern void *osversion;
extern void *flag_kdp_trigger_reboot;
extern void *manual_pkt;
lowglo lowGlo __attribute__ ((aligned(PAGE_SIZE))) = {
.lgVerCode = { 'C','a','t','f','i','s','h',' ' },
.lgVersion = (uint64_t) &version,
.lgKmodptr = (uint64_t) &kmod,
#if MACH_KDP
.lgTransOff = (uint64_t) &kdp_trans_off,
.lgReadIO = (uint64_t) &kdp_read_io,
#else
.lgTransOff = 0,
.lgReadIO = 0,
#endif
.lgDevSlot1 = 0,
.lgDevSlot2 = 0,
.lgOSVersion = (uint64_t) &osversion,
#if MACH_KDP
.lgRebootFlag = (uint64_t) &flag_kdp_trigger_reboot,
.lgManualPktAddr = (uint64_t) &manual_pkt,
#else
.lgRebootFlag = 0,
.lgManualPktAddr = 0,
#endif
};
| null | 2
|
{
"advantage_score_max": 2.844205141067505,
"advantage_score_mean": 2.285917282104492,
"advantage_score_min": 1.727629542350769,
"advantage_score_std": 0.5582877993583679,
"advantage_scores": [
2.844205141067505,
1.727629542350769
],
"baseline_doc_loss": 0.6729482412338257,
"baseline_truncated": false,
"doc_advantage_score": 1.2436552047729492,
"length_change_ratio": 0.9930232558139535,
"net_length_change_chars": -3,
"original_sentences_length_chars": 430,
"replacement_paraphrases_length_chars": 427,
"sentences_perturbed": 2,
"target_doc_loss": 0.5411051511764526,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 3356,
"total_sentences": 13,
"truncated": false
}
|
/*
* Copyright (C) 2018 Igalia S.L.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following
* disclaimer in the documentation and/or other materials provided
* with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND WITHOUT ANY WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL THE COPYRIGHT
* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#pragma once
#if ENABLE(ASYNC_SCROLLING) && USE(NICOSIA)
#include "ThreadedScrollingTree.h"
namespace WebCore {
class ScrollingTreeNicosia final : public ThreadedScrollingTree {
public:
static Ref<ScrollingTreeNicosia> create(AsyncScrollingCoordinator&);
private:
explicit ScrollingTreeNicosia(AsyncScrollingCoordinator&);
Ref<ScrollingTreeNode> createScrollingTreeNode(ScrollingNodeType, ScrollingNodeID) override;
};
} // namespace WebCore
#endif // ENABLE(ASYNC_SCROLLING) && USE(NICOSIA)
| null | 1
|
{
"advantage_score_max": 4.2147626876831055,
"advantage_score_mean": 4.037937164306641,
"advantage_score_min": 3.8611114025115967,
"advantage_score_std": 0.1768256425857544,
"advantage_scores": [
4.2147626876831055,
3.8611114025115967
],
"baseline_doc_loss": 0.39343053102493286,
"baseline_truncated": false,
"doc_advantage_score": 1.8515256643295288,
"length_change_ratio": 0.9488188976377953,
"net_length_change_chars": -13,
"original_sentences_length_chars": 254,
"replacement_paraphrases_length_chars": 241,
"sentences_perturbed": 1,
"target_doc_loss": 0.21248991787433624,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 1868,
"total_sentences": 8,
"truncated": false
}
|
<?xml version="1.0" encoding="utf-8"?>
<android.support.v4.widget.DrawerLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/read_dl_slide"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@mipmap/theme_leather_bg">
<android.support.design.widget.AppBarLayout
android:id="@+id/read_abl_top_menu"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/color_19"
android:visibility="gone"
tools:visibility="visible">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="48dp"
android:layout_below="@+id/status_bar">
<TextView
android:id="@+id/tv_toolbar_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_marginLeft="10dp"
android:drawablePadding="20dp"
android:layout_marginRight="60dp"
android:drawableLeft="@drawable/ic_arrow_back_white_24dp"
android:ellipsize="end"
android:maxLines="1"
android:text="@string/app_name"
android:textColor="@android:color/white"
android:textSize="18sp"/>
</RelativeLayout>
<!--<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minHeight="?attr/actionBarSize"
android:theme="@style/Theme.ToolBar.Menu">
<!–<RelativeLayout
android:layout_width="120dp"
android:layout_height="50dp"
android:layout_gravity="right"
android:background="@color/color_19">
<TextView
android:visibility="gone"
android:id="@+id/read_tv_brief"
style="@style/WY.Theme.TextAppearance.Read.TopMenu"
android:layout_alignParentRight="true"
android:text="@string/wy.read.brief"/>
<TextView
android:visibility="gone"
android:id="@+id/read_tv_community"
style="@style/WY.Theme.TextAppearance.Read.TopMenu"
android:layout_toLeftOf="@id/read_tv_brief"
android:text="@string/wy.read.community"/>
</RelativeLayout>–>
</android.support.v7.widget.Toolbar>-->
</android.support.design.widget.AppBarLayout>
<!--阅读页面-->
<com.lianglu.weyue.widget.page.PageView
android:id="@+id/pv_read_page"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:clickable="true"
tools:visibility="gone"/>
<!--切换页面提示-->
<TextView
android:id="@+id/read_tv_page_tip"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/read_ll_bottom_menu"
android:layout_centerHorizontal="true"
android:layout_marginBottom="10dp"
android:background="@color/color_19"
android:gravity="center"
android:paddingBottom="8dp"
android:paddingLeft="12dp"
android:paddingRight="12dp"
android:paddingTop="8dp"
android:text="1/12"
android:textColor="@color/white"
android:visibility="gone"/>
<!--底部页面-->
<LinearLayout
android:id="@+id/read_ll_bottom_menu"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="@color/color_19"
android:clickable="true"
android:orientation="vertical"
android:visibility="gone"
tools:visibility="visible">
<!--页面进度栏-->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_vertical"
android:orientation="horizontal">
<TextView
android:id="@+id/read_tv_pre_chapter"
style="@style/WY.Theme.TextAppearance.Read.BottomMenu"
android:layout_width="80dp"
android:layout_height="match_parent"
android:gravity="center"
android:text="上一章"/>
<SeekBar
android:id="@+id/read_sb_chapter_progress"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:max="100"
android:maxHeight="3dp"
android:minHeight="3dp"
android:progressDrawable="@drawable/seekbar_bg"
android:thumb="@drawable/seekbar_thumb"
android:thumbOffset="10dp"/>
<TextView
android:id="@+id/read_tv_next_chapter"
style="@style/WY.Theme.TextAppearance.Read.BottomMenu"
android:layout_width="80dp"
android:layout_height="match_parent"
android:gravity="center"
android:text="下一章"/>
</LinearLayout>
<!--菜单栏-->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="72dp"
android:orientation="horizontal"
android:paddingBottom="12dp"
android:paddingTop="12dp">
<TextView
android:id="@+id/read_tv_category"
style="@style/WY.Theme.TextAppearance.Read.BottomMenu.Button"
android:drawableTop="@mipmap/read_menu_category"
android:text="@string/wy.read.category"/>
<TextView
android:id="@+id/read_tv_night_mode"
style="@style/WY.Theme.TextAppearance.Read.BottomMenu.Button"
android:drawableTop="@mipmap/read_menu_night"
android:text="@string/wy.mode.night"/>
<TextView
android:id="@+id/read_tv_setting"
style="@style/WY.Theme.TextAppearance.Read.BottomMenu.Button"
android:drawableTop="@mipmap/read_menu_font"
android:text="@string/wy.read.setting"/>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
<!--侧滑栏-->
<LinearLayout
android:layout_width="300dp"
android:layout_height="match_parent"
android:layout_gravity="start"
android:background="@mipmap/theme_leather_bg"
android:clickable="true"
android:orientation="vertical"
android:paddingBottom="@dimen/wy.padding.large"
android:paddingTop="@dimen/wy.padding.large">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="8dp"
android:layout_marginLeft="15dp"
android:text="目录"
android:textColor="@color/black"
android:textSize="20sp"/>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1">
<android.support.v7.widget.RecyclerView
android:id="@+id/rv
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
from math import ceil
from django.utils import six
class InvalidPage(Exception):
pass
class PageNotAnInteger(InvalidPage):
pass
class EmptyPage(InvalidPage):
pass
class Paginator(object):
def __init__(self, object_list, per_page, orphans=0, allow_empty_first_page=True):
self.object_list = object_list
self.per_page = int(per_page)
self.orphans = int(orphans)
self.allow_empty_first_page = allow_empty_first_page
self._num_pages = self._count = None
def validate_number(self, number):
"Validates the given 1-based page number."
try:
number = int(number)
except (TypeError, ValueError):
raise PageNotAnInteger('That page number is not an integer')
if number < 1:
raise EmptyPage('That page number is less than 1')
if number > self.num_pages:
if number == 1 and self.allow_empty_first_page:
pass
else:
raise EmptyPage('That page contains no results')
return number
def page(self, number):
"Returns a Page object for the given 1-based page number."
number = self.validate_number(number)
bottom = (number - 1) * self.per_page
top = bottom + self.per_page
if top + self.orphans >= self.count:
top = self.count
return Page(self.object_list[bottom:top], number, self)
def _get_count(self):
"Returns the total number of objects, across all pages."
if self._count is None:
try:
self._count = self.object_list.count()
except (AttributeError, TypeError):
# AttributeError if object_list has no count() method.
# TypeError if object_list.count() requires arguments
# (i.e. is of type list).
self._count = len(self.object_list)
return self._count
count = property(_get_count)
def _get_num_pages(self):
"Returns the total number of pages."
if self._num_pages is None:
if self.count == 0 and not self.allow_empty_first_page:
self._num_pages = 0
else:
hits = max(1, self.count - self.orphans)
self._num_pages = int(ceil(hits / float(self.per_page)))
return self._num_pages
num_pages = property(_get_num_pages)
def _get_page_range(self):
"""
Returns a 1-based range of pages for iterating through within
a template for loop.
"""
return range(1, self.num_pages + 1)
page_range = property(_get_page_range)
QuerySetPaginator = Paginator # For backwards-compatibility.
class Page(object):
def __init__(self, object_list, number, paginator):
self.object_list = object_list
self.number = number
self.paginator = paginator
def __repr__(self):
return '<Page %s of %s>' % (self.number, self.paginator.num_pages)
def __len__(self):
return len(self.object_list)
def __getitem__(self, index):
if not isinstance(index, (slice,) + six.integer_types):
raise TypeError
# The object_list is converted to a list so that if it was a QuerySet
# it won't be a database hit per __getitem__.
return list(self.object_list)[index]
# The following four methods are only necessary for Python <2.6
# compatibility (this class could just extend 2.6's collections.Sequence).
def __iter__(self):
i = 0
try:
while True:
v = self[i]
yield v
i += 1
except IndexError:
return
def __contains__(self, value):
for v in self:
if v == value:
return True
return False
def index(self, value):
for i, v in enumerate(self):
if v == value:
return i
raise ValueError
def count(self, value):
return sum([1 for v in self if v == value])
# End of compatibility methods.
def has_next(self):
return self.number < self.paginator.num_pages
def has_previous(self):
return self.number > 1
def has_other_pages(self):
return self.has_previous() or self.has_next()
def next_page_number(self):
return self.paginator.validate_number(self.number + 1)
def previous_page_number(self):
return self.paginator.validate_number(self.number - 1)
def start_index(self):
"""
Returns the 1-based index of the first object on this page,
relative to total objects in the paginator.
"""
# Special case, return zero if no items.
if self.paginator.count == 0:
return 0
return (self.paginator.per_page * (self.number - 1)) + 1
def end_index(self):
"""
Returns the 1-based index of the last object on this page,
relative to total objects found (hits).
"""
# Special case for the last page because there can be orphans.
if self.number == self.paginator.num_pages:
return self.paginator.count
return self.number * self.paginator.per_page
| null | 0
|
{
"advantage_score_max": 2.335099935531616,
"advantage_score_mean": 1.7105751037597656,
"advantage_score_min": 1.1261239051818848,
"advantage_score_std": 0.48076942563056946,
"advantage_scores": [
2.335099935531616,
2.0641586780548096,
1.8465954065322876,
1.1808969974517822,
1.1261239051818848
],
"baseline_doc_loss": 0.403788685798645,
"baseline_truncated": false,
"doc_advantage_score": 0.5934793949127197,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.6803752183914185,
"target_truncated": false,
"threshold_passing_sentences": 5,
"total_doc_length_chars": 5245,
"total_sentences": 17,
"truncated": false
}
|
define("ace/snippets/space",["require","exports","module"], function(require, exports, module) {
"use strict";
exports.snippetText =undefined;
exports.scope = "space";
}); (function() {
window.require(["ace/snippets/space"], function(m) {
if (typeof module == "object" && typeof exports == "object" && module) {
module.exports = m;
}
});
})();
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
12--Group/12_Group_Large_Group_12_Group_Large_Group_12_322.jpg
7
252.268171875 354.74903125 35.942171875 47.6090625 0.998959779739
61.5709101563 351.78440625 27.2688085938 35.64646875 0.998394787312
1000.588 380.61590625 23.388 38.52371875 0.9979403615
817.1789375 398.35190625 32.9865625 44.51434375 0.99717438221
515.53034375 375.26678125 37.79978125 47.68421875 0.996892273426
320.2469375 366.3956875 27.100625 33.72909375 0.995274066925
755.9171875 365.6883125 30.632375 38.8108125 0.989945113659
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
的
一
是
在
不
了
有
和
人
这
中
大
为
上
个
国
我
以
要
他
时
来
用
们
生
到
作
地
于
出
就
分
对
成
会
可
主
发
年
动
同
工
也
能
下
过
子
说
产
种
面
而
方
后
多
定
行
学
法
所
民
得
经
十
三
之
进
着
等
部
度
家
电
力
里
如
水
化
高
自
二
理
起
小
物
现
实
加
量
都
两
体
制
机
当
使
点
从
业
本
去
把
性
好
应
开
它
合
还
因
由
其
些
然
前
外
天
政
四
日
那
社
义
事
平
形
相
全
表
间
样
与
关
各
重
新
线
内
数
正
心
反
你
明
看
原
又
么
利
比
或
但
质
气
第
向
道
命
此
变
条
只
没
结
解
问
意
建
月
公
无
系
军
很
情
者
最
立
代
想
已
通
并
提
直
题
党
程
展
五
果
料
象
员
革
位
入
常
文
总
次
品
式
活
设
及
管
特
件
长
求
老
头
基
资
边
流
路
级
少
图
山
统
接
知
较
将
组
见
计
别
她
手
角
期
根
论
运
农
指
几
九
区
强
放
决
西
被
干
做
必
战
先
回
则
任
取
据
处
队
南
给
色
光
门
即
保
治
北
造
百
规
热
领
七
海
口
东
导
器
压
志
世
金
增
争
济
阶
油
思
术
极
交
受
联
什
认
六
共
权
收
证
改
清
美
再
采
转
更
单
风
切
打
白
教
速
花
带
安
场
身
车
例
真
务
具
万
每
目
至
达
走
积
示
议
声
报
斗
完
类
八
离
华
名
确
才
科
张
信
马
节
话
米
整
空
元
况
今
集
温
传
土
许
步
群
广
石
记
需
段
研
界
拉
林
律
叫
且
究
观
越
织
装
影
算
低
持
音
众
书
布
复
容
儿
须
际
商
非
验
连
断
深
难
近
矿
千
周
委
素
技
备
半
办
青
省
列
习
响
约
支
般
史
感
劳
便
团
往
酸
历
市
克
何
除
消
构
府
称
太
准
精
值
号
率
族
维
划
选
标
写
存
候
毛
亲
快
效
斯
院
查
江
型
眼
王
按
格
养
易
置
派
层
片
始
却
专
状
育
厂
京
识
适
属
圆
包
火
住
调
满
县
局
照
参
红
细
引
听
该
铁
价
严
首
底
液
官
德
随
病
苏
失
尔
死
讲
配
女
黄
推
显
谈
罪
神
艺
呢
席
含
企
望
密
批
营
项
防
举
球
英
氧
势
告
李
台
落
木
帮
轮
破
亚
师
围
注
远
字
材
排
供
河
态
封
另
施
减
树
溶
怎
止
案
言
士
均
武
固
叶
鱼
波
视
仅
费
紧
爱
左
章
早
朝
害
续
轻
服
试
食
充
兵
源
判
护
司
足
某
练
差
致
板
田
降
黑
犯
负
击
范
继
兴
似
余
坚
曲
输
修
故
城
夫
够
送
笔
船
占
右
财
吃
富
春
职
觉
汉
画
功
巴
跟
虽
杂
飞
检
吸
助
升
阳
互
初
创
抗
考
投
坏
策
古
径
换
未
跑
留
钢
曾
端
责
站
简
述
钱
副
尽
帝
射
草
冲
承
独
令
限
阿
宣
环
双
请
超
微
让
控
州
良
轴
找
否
纪
益
依
优
顶
础
载
倒
房
突
坐
粉
敌
略
客
袁
冷
胜
绝
析
块
剂
测
丝
协
诉
念
陈
仍
罗
盐
友
洋
错
苦
夜
刑
移
频
逐
靠
混
母
短
皮
终
聚
汽
村
云
哪
既
距
卫
停
烈
央
察
烧
迅
境
若
印
洲
刻
括
激
孔
搞
甚
室
待
核
校
散
侵
吧
甲
游
久
菜
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
package com.example.algamoney.api.repository;
import java.util.Optional;
import org.springframework.data.jpa.repository.JpaRepository;
import com.example.algamoney.api.model.Usuario;
public interface UsuarioRepository extends JpaRepository<Usuario, Long> {
public Optional<Usuario> findByEmail(String email);
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
// Copyright (c) 2014 The SurgeMQ Authors. All rights reserved.
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package topics
import (
"testing"
"github.com/stretchr/testify/require"
"github.com/surgemq/message"
)
func TestNextTopicLevelSuccess(t *testing.T) {
topics := [][]byte{
[]byte("sport/tennis/player1/#"),
[]byte("sport/tennis/player1/ranking"),
[]byte("sport/#"),
[]byte("#"),
[]byte("sport/tennis/#"),
[]byte("+"),
[]byte("+/tennis/#"),
[]byte("sport/+/player1"),
[]byte("/finance"),
}
levels := [][][]byte{
[][]byte{[]byte("sport"), []byte("tennis"), []byte("player1"), []byte("#")},
[][]byte{[]byte("sport"), []byte("tennis"), []byte("player1"), []byte("ranking")},
[][]byte{[]byte("sport"), []byte("#")},
[][]byte{[]byte("#")},
[][]byte{[]byte("sport"), []byte("tennis"), []byte("#")},
[][]byte{[]byte("+")},
[][]byte{[]byte("+"), []byte("tennis"), []byte("#")},
[][]byte{[]byte("sport"), []byte("+"), []byte("player1")},
[][]byte{[]byte("+"), []byte("finance")},
}
for i, topic := range topics {
var (
tl []byte
rem = topic
err error
)
for _, level := range levels[i] {
tl, rem, err = nextTopicLevel(rem)
require.NoError(t, err)
require.Equal(t, level, tl)
}
}
}
func TestNextTopicLevelFailure(t *testing.T) {
topics := [][]byte{
[]byte("sport/tennis#"),
[]byte("sport/tennis/#/ranking"),
[]byte("sport+"),
}
var (
rem []byte
err error
)
_, rem, err = nextTopicLevel(topics[0])
require.NoError(t, err)
_, rem, err = nextTopicLevel(rem)
require.Error(t, err)
_, rem, err = nextTopicLevel(topics[1])
require.NoError(t, err)
_, rem, err = nextTopicLevel(rem)
require.NoError(t, err)
_, rem, err = nextTopicLevel(rem)
require.Error(t, err)
_, rem, err = nextTopicLevel(topics[2])
require.Error(t, err)
}
func TestSNodeInsert1(t *testing.T) {
n := newSNode()
topic := []byte("sport/tennis/player1/#")
err := n.sinsert(topic, 1, "sub1")
require.NoError(t, err)
require.Equal(t, 1, len(n.snodes))
require.Equal(t, 0, len(n.subs))
n2, ok := n.snodes["sport"]
require.True(t, ok)
require.Equal(t, 1, len(n2.snodes))
require.Equal(t, 0, len(n2.subs))
n3, ok := n2.snodes["tennis"]
require.True(t, ok)
require.Equal(t, 1, len(n3.snodes))
require.Equal(t, 0, len(n3.subs))
n4, ok := n3.snodes["player1"]
require.True(t, ok)
require.Equal(t, 1, len(n4.snodes))
require.Equal(t, 0, len(n4.subs))
n5, ok := n4.snodes["#"]
require.True(t, ok)
require.Equal(t, 0, len(n5.snodes))
require.Equal(t, 1, len(n5.subs))
require.Equal(t, "sub1", n5.subs[0].(string))
}
func TestSNodeInsert2(t *testing.T) {
n := newSNode()
topic := []byte("#")
err := n.sinsert(topic, 1, "sub1")
require.NoError(t, err)
require.Equal(t, 1, len(n.snodes))
require.Equal(t, 0, len(n.subs))
n2, ok := n.snodes["#"]
require.True(t, ok)
require.Equal(t, 0, len(n2.snodes))
require.Equal(t, 1, len(n2.subs))
require.Equal(t, "sub1", n2.subs[0].(string))
}
func TestSNodeInsert3(t *testing.T) {
n := newSNode()
topic := []byte("+/tennis/#")
err := n.sinsert(topic, 1, "sub1")
require.NoError(t, err)
require.Equal(t, 1, len(n.snodes))
require.Equal(t, 0, len(n.subs))
n2, ok := n.snodes["+"]
require.True(t, ok)
require.Equal(t, 1, len(n2.snodes))
require.Equal(t, 0, len(n2.subs))
n3, ok := n2.snodes["tennis"]
require.True(t, ok)
require.Equal(t, 1, len(n3.snodes))
require.Equal(t, 0, len(n3.subs))
n4, ok := n3.snodes["#"]
require.True(t, ok)
require.Equal(t, 0, len(n4.snodes))
require.Equal(t, 1, len(n4.subs))
require.Equal(t, "sub1", n4.subs[0].(string))
}
func TestSNodeInsert4(t *testing.T) {
n := newSNode()
topic := []byte("/finance")
err := n.sinsert(topic, 1, "sub1")
require.NoError(t, err)
require.Equal(t, 1, len(n.snodes))
require.Equal(t, 0, len(n.subs))
n2, ok := n.snodes["+"]
require.True(t, ok)
require.Equal(t, 1, len(n2.snodes))
require.Equal(t, 0, len(n2.subs))
n3, ok := n2.snodes["finance"]
require.True(t, ok)
require.Equal(t, 0, len(n3.snodes))
require.Equal(t, 1, len(n3.subs))
require.Equal(t, "sub1", n3.subs[0].(string))
}
func TestSNodeInsertDup(t *testing.T) {
n := newSNode()
topic := []byte("/finance")
err := n.sinsert(topic, 1, "sub1")
err = n.sinsert(topic, 1, "sub1")
require.NoError(t, err)
require.Equal(t, 1, len(n.snodes))
require.Equal(t, 0, len(n.sub
| null | 1
|
{
"advantage_score_max": 3.2782607078552246,
"advantage_score_mean": 2.899949550628662,
"advantage_score_min": 2.5216383934020996,
"advantage_score_std": 0.3783111572265625,
"advantage_scores": [
3.2782607078552246,
2.5216383934020996
],
"baseline_doc_loss": 0.2976228594779968,
"baseline_truncated": false,
"doc_advantage_score": 0.9392266869544983,
"length_change_ratio": 0.9781021897810219,
"net_length_change_chars": -3,
"original_sentences_length_chars": 137,
"replacement_paraphrases_length_chars": 134,
"sentences_perturbed": 1,
"target_doc_loss": 0.3168807625770569,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 4899,
"total_sentences": 10,
"truncated": false
}
|
/* Generated by RuntimeBrowser
Image: /System/Library/PrivateFrameworks/TextInputCore.framework/TextInputCore
*/
@interface TIWordSearchController : NSObject {
NSMapTable * _inputModeToWordSearchMapping;
}
@property (nonatomic, retain) NSMapTable *inputModeToWordSearchMapping;
+ (id)sharedWordSearchController;
- (void).cxx_destruct;
- (id)init;
- (id)inputModeToWordSearchMapping;
- (void)setInputModeToWordSearchMapping:(id)arg1;
- (void)setWordSearch:(id)arg1 forInputMode:(id)arg2;
- (id)wordSearchForInputMode:(id)arg1;
@end
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
#!/bin/bash
#
# Copyright 2018 The Kubernetes Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
set -e
set -x
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null && pwd )"
# vendor_kustomize.sh creates the change in kubernetes repo for vendoring kustomize
function setUpWorkspace {
KPATH=~/kustomize_vendor
mkdir $KPATH
GOPATH=$KPATH
}
function cloneK8s {
mkdir -p $KPATH/src/k8s.io
cd $KPATH/src/k8s.io
git clone git@github.com:kubernetes/kubernetes.git
}
function godepRestore {
cd $KPATH/src/k8s.io/kubernetes
# restore dependencies
hack/run-in-gopath.sh hack/godep-restore.sh
}
function getKustomizeDeps {
# get Kustomize and Kustomize dependencies
hack/run-in-gopath.sh godep get sigs.k8s.io/kustomize/pkg/commands
hack/run-in-gopath.sh godep get github.com/bgentry/go-netrc/netrc
hack/run-in-gopath.sh godep get github.com/hashicorp/go-cleanhttp
hack/run-in-gopath.sh godep get github.com/hashicorp/go-getter
hack/run-in-gopath.sh godep get github.com/hashicorp/go-safetemp
hack/run-in-gopath.sh godep get github.com/hashicorp/go-version
# The hashes below passed bin/pre-commit.sh with kustomize HEAD at time of merger.
DEPS=(
"hashicorp/go-getter 4bda8fa99001c61db3cad96b421d4c12a81f256d"
"hashicorp/go-cleanhttp d5fe4b57a186c716b0e00b8c301cbd9b4182694d"
"hashicorp/go-safetemp b1a1dbde6fdc11e3ae79efd9039009e22d4ae240"
"hashicorp/go-version 270f2f71b1ee587f3b609f00f422b76a6b28f348"
"bgentry/go-netrc 9fd32a8b3d3d3f9d43c341bfe098430e07609480"
"mitchellh/go-homedir 58046073cbffe2f25d425fe1331102f55cf719de"
"mitchellh/go-testing-interface a61a99592b77c9ba629d254a693acffaeb4b7e28"
"ulikunitz/xz v0.5.4"
)
function foo {
cd $KPATH/src/k8s.io/kubernetes/_output/local/go/src/github.com/$1
git checkout $2
}
for i in "${DEPS[@]}"; do
foo $i
done
}
function updateK8s {
# Copy k8sdeps from Kustomize to cli-runtime in staging
mkdir -p $KPATH/src/k8s.io/kubernetes/staging/src/k8s.io/cli-runtime/pkg/kustomize
cp -r $KPATH/src/k8s.io/kubernetes/_output/local/go/src/sigs.k8s.io/kustomize/k8sdeps \
$KPATH/src/k8s.io/kubernetes/staging/src/k8s.io/cli-runtime/pkg/kustomize/k8sdeps
# Change import path of k8sdeps
find $KPATH/src/k8s.io/kubernetes/staging/src/k8s.io/cli-runtime/pkg/kustomize/k8sdeps \
-type f -name "*.go" | \
xargs sed -i \
's!sigs.k8s.io/kustomize/k8sdeps!k8s.io/cli-runtime/pkg/kustomize/k8sdeps!'
# Add kustomize command to kubectl
cp $DIR/vendor_kustomize.diff $KPATH/vendor_kustomize.diff
cd $GOPATH/src/k8s.io/kubernetes
git apply --ignore-space-change --ignore-whitespace $KPATH/vendor_kustomize.diff
}
function godepSave {
# Save all dependencies into k8s.io/kubernetes/vendor by running
# hack/godep-save.sh
hack/run-in-gopath.sh hack/godep-save.sh
}
function verify {
# make sure in k8s.io/kubernetes/vendor/sigs.k8s.io/kustomize
# there is no internal package
test 0 == $(ls $KPATH/src/k8s.io/kubernetes/vendor/sigs.k8s.io/kustomize | grep “internal” | wc -l)
# Make sure it compiles.
test 0 == $(bazel build cmd/kubectl:kubectl)
# next step, open a PR
echo "The change for vendoring kustomize is ready in $GOPATH/src/k8s.io/kubernetes.\n Next step, open a PR for it.\n"
}
setUpWorkspace
cloneK8s
godepRestore
getKustomizeDeps
updateK8s
godepSave
verify
| null | 1
|
{
"advantage_score_max": 8.70692253112793,
"advantage_score_mean": 5.481420516967773,
"advantage_score_min": 1.477368712425232,
"advantage_score_std": 3.0023562908172607,
"advantage_scores": [
8.70692253112793,
6.259969234466553,
1.477368712425232
],
"baseline_doc_loss": 1.4662063121795654,
"baseline_truncated": false,
"doc_advantage_score": 1.1236765384674072,
"length_change_ratio": 1.0032051282051282,
"net_length_change_chars": 1,
"original_sentences_length_chars": 312,
"replacement_paraphrases_length_chars": 313,
"sentences_perturbed": 1,
"target_doc_loss": 1.304829478263855,
"target_truncated": false,
"threshold_passing_sentences": 3,
"total_doc_length_chars": 3888,
"total_sentences": 8,
"truncated": false
}
|
$(document).ready(function() {
$('#inputDomainChooser').multiselect({
buttonWidth: '250px',
dropRight: true,
nonSelectedText: 'Choose domain(s)'
});
$('.landing-page.mail-services .get-started .choose-product button').click(function(e) {
var product = $(this).data('product');
$('.landing-page.mail-services .get-started .choose-product button').removeClass('active');
$(this).addClass('active');
$('.landing-page.mail-services .get-started .additional-options .option').hide();
$('.landing-page.mail-services .get-started .additional-options .options-' + product).show();
$('.landing-page.mail-services .get-started .price').hide();
$('.landing-page.mail-services .get-started .price-' + product).show();
$('#productKey').val('spamexperts_' + product);
});
$('.landing-page.mail-services .get-started .additional-options input[type="checkbox"]').click(function(e) {
if ($(this).is(":checked")) {
$('.landing-page.mail-services .get-started .price').hide();
$('.landing-page.mail-services .get-started .price-' + $(this).val()).show();
$('#productKey').val('spamexperts_' + $(this).val());
} else {
var product = $('.landing-page.mail-services .get-started .choose-product button.active').data('product');
$('.landing-page.mail-services .get-started .price').hide();
$('.landing-page.mail-services .get-started .price-' + product).show();
$('#productKey').val('spamexperts_' + product);
}
});
$('.btn-learn-more').click(function(e) {
e.preventDefault();
$('#howitworks a[href="#' + $(this).data('target') + '"]').tab('show');
smoothScroll('#howitworks');
});
$('.btn-buy').click(function(e) {
e.preventDefault();
$('#pricing button[data-product="' + $(this).data('target') + '"]').click();
smoothScroll('#pricing');
});
});
function smoothScroll(element) {
$('html, body').animate({
scrollTop: $(element).offset().top
}, 500);
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
def extractIsekaiFiction(item):
"""
'Isekai Fiction'
"""
vol, chp, frag, postfix = extractVolChapterFragmentPostfix(item['title'])
if not (chp or vol or frag) or 'preview' in item['title'].lower():
return None
if 'Upstart Pastry Chef' in item['tags']:
return buildReleaseMessageWithType(item, 'Upstart Pastry Chef ~Territory Management of a Genius Pâtissier~', vol, chp, frag=frag, postfix=postfix)
if 'pastry' in item['tags']:
return buildReleaseMessageWithType(item, 'Upstart Pastry Chef ~Territory Management of a Genius Pâtissier~', vol, chp, frag=frag, postfix=postfix)
if 'herscherik' in item['tags']:
return buildReleaseMessageWithType(item, 'Herscherik: Tensei Ouji to Urei no Daikoku', vol, chp, frag=frag, postfix=postfix)
if 'okonomiyaki' in item['tags']:
return buildReleaseMessageWithType(item, 'Different World’s Okonomiyaki Chain Store ~Auntie from Osaka, Reborn as Beautiful Swordswoman, on A Mission to Spread Okonomiyaki!~', vol, chp, frag=frag, postfix=postfix)
if 'The Wolf Lord\'s Lady' in item['tags']:
return buildReleaseMessageWithType(item, 'The Wolf Lord\'s Lady', vol, chp, frag=frag, postfix=postfix)
tagmap = [
('Starship Officer Becomes Adventurer', 'The Starship Officer Becomes An Adventurer', 'translated'),
('Sono Mono Nochi ni', 'That Person. Later on…', 'translated'),
('PRC', 'PRC', 'translated'),
('Loiterous', 'Loiterous', 'oel'),
]
for tagname, name, tl_type in tagmap:
if tagname in item['tags']:
return buildReleaseMessageWithType(item, name, vol, chp, frag=frag, postfix=postfix, tl_type=tl_type)
return False
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
package plugin
import (
"crypto/tls"
"fmt"
"math"
"net"
"time"
"github.com/hashicorp/go-plugin/internal/plugin"
"golang.org/x/net/context"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
"google.golang.org/grpc/health/grpc_health_v1"
)
func dialGRPCConn(tls *tls.Config, dialer func(string, time.Duration) (net.Conn, error)) (*grpc.ClientConn, error) {
// Build dialing options.
opts := make([]grpc.DialOption, 0, 5)
// We use a custom dialer so that we can connect over unix domain sockets.
opts = append(opts, grpc.WithDialer(dialer))
// Fail right away
opts = append(opts, grpc.FailOnNonTempDialError(true))
// If we have no TLS configuration set, we need to explicitly tell grpc
// that we're connecting with an insecure connection.
if tls == nil {
opts = append(opts, grpc.WithTransportCredentials(insecure.NewCredentials()))
} else {
opts = append(opts, grpc.WithTransportCredentials(
credentials.NewTLS(tls)))
}. Note the first parameter is unused because we use a custom
// dialer that has the state to see the address.
conn, err := grpc.Dial("unused", opts...)
if err != nil {
return nil, err
}
return conn, nil
}
// newGRPCClient creates a new GRPCClieconn, err := grpc.DialContext(context.Background(), "unused", opts...)
if err != nil {
return nil, err
}
return conn, nil.t) (*GRPCClient, error) {
conn, err := dialGRPCConn(c.config.TLSConfig, c.dialer)
if err != nil {
return nil, err
}
// Start the broker.
brokerGRPCClient := newGRPCBrokerClient(conn)
broker := newGRPCBroker(brokerGRPCClient, c.config.TLSConfig)
go broker.Run()
go brokerGRPCClient.StartStream()
cl := &GRPCClient{
Conn: conn,
Plugins: c.config.Plugins,
doneCtx: doneCtx,
broker: broker,
controller: plugin.NewGRPCControllerClient(conn),
}
return cl, nil
}
// GRPCClient connects to a GRPCServer over gRPC to dispense plugin types.
type GRPCClient struct {
Conn *grpc.ClientConn
Plugins map[string]Plugin
doneCtx context.Context
broker *GRPCBroker
controller plugin.GRPCControllerClient
}
// ClientProtocol impl.
func (c *GRPCClient) Close() error {
c.broker.Close()
c.controller.Shutdown(c.doneCtx, &plugin.Empty{})
return c.Conn.Close()
}
// ClientProtocol impl.
func (c *GRPCClient) Dispense(name string) (interface{}, error) {
raw, ok := c.Plugins[name]
if !ok {
return nil, fmt.Errorf("unknown plugin type: %s", name)
}
p, ok := raw.(GRPCPlugin)
if !ok {
return nil, fmt.Errorf("plugin %q doesn't support gRPC", name)
}
return p.GRPCClient(c.doneCtx, c.broker, c.Conn)
}
// ClientProtocol impl.
func (c *GRPCClient) Ping() error {
client := grpc_health_v1.NewHealthClient(c.Conn)
_, err := client.Check(context.Background(), &grpc_health_v1.HealthCheckRequest{
Service: GRPCServiceName,
})
return err
}
| null | 2
|
{
"advantage_score_max": 3.6462740898132324,
"advantage_score_mean": 2.1428003311157227,
"advantage_score_min": 1.1438846588134766,
"advantage_score_std": 1.0821036100387573,
"advantage_scores": [
3.6462740898132324,
1.6382423639297485,
1.1438846588134766
],
"baseline_doc_loss": 0.9359451532363892,
"baseline_truncated": false,
"doc_advantage_score": 1.455945611000061,
"length_change_ratio": 0.6701680672268907,
"net_length_change_chars": -157,
"original_sentences_length_chars": 476,
"replacement_paraphrases_length_chars": 319,
"sentences_perturbed": 2,
"target_doc_loss": 0.64284348487854,
"target_truncated": false,
"threshold_passing_sentences": 3,
"total_doc_length_chars": 2991,
"total_sentences": 14,
"truncated": false
}
|
## Developer Onboarding
Being a new developer on an established team can be overwhelming. There are many parts of the process, culture and technical aspects the new dev will need to learn. Effective teams have good onboarding documents available so the process is clear. Ideally, onboarding should happen in stages. The suggested steps are described below, but each team must adapt according to context. It's not a manager's responsibility to onboard every new dev. Thus, all team members must be prepared. This is also important so that different people can iterate over the onboarding process and evaluate how it can improve.
### Step 1 - Processes
The goal of this step is to provide an overall understanding of both the client and the team. Who they are and how they operate.
- [ ] Ask the dev to introduce themselves. What's their past experience? What languages, databases, servers have they worked with?
- [ ] Present the client. Who is the customer? What is the business model? What are the goals Vinta helps the client achieve?
- [ ] Present the team. Detail each persons' roles, if there's a support manager, a deploy manager. Mention how the project started, and how the team grew.
- [ ] Explain the team's processes and workflows:
- [ ] Explain [sprints](https://github.com/vintasoftware/playbook/blob/master/project_management.md#sprints).
- [ ] Make sure the developer understands their responsibilities and features ownership.
- [ ] Explain the [development workflow](https://github.com/vintasoftware/playbook/blob/master/checklists/feature_development_workflow.md).
- [ ] Explain the project's repository. Differences between feature PRs, and deploy PRs. What branches represent Staging and Production?
- [ ] Explain Staging and Production environments. More details [here](https://12factor.net/dev-prod-parity).
- [ ] Ask the new developer to read the [development guideline](https://github.com/vintasoftware/playbook/blob/master/development.md#development) and the [frontend guideline](https://github.com/vintasoftware/playbook/blob/master/guidelines/guideline_frontend.md).
- [ ] Explain the Roadmap, and how the long-term planning is assessed.
- [ ] Explain how and when [sprints meetings](https://github.com/vintasoftware/playbook/blob/master/checklists/sprint_meeting.md) with the client occur. How meeting notes are organized, where they are stored.
- [ ] Show them the project's assets. They should be available on the project's Drive folder.
- [ ] Ask the developer to set up the project using the README. If any issues are encountered, they should modify the document. This benefits new future hires.
- [ ] Assert the developer has access to:
- [ ] LastPass
- [ ] The project's Drive folder
- [ ] The project's Google group
- [ ] The project's Google Calendar events
- [ ] The project's Github repository
- [ ] The project's Asana
- [ ] Both Production and Staging environments
- [ ] The client's Slack
### Step 2 - Product and Project
The new dev should already be familiarized with the processes. Now, it's time they learn details of the project.
- [ ] Start explaining main use cases and where they're implemented on the code.
- [ ] Show how they can manually test the system on Staging.
- [ ] Complete the main flows on Staging with them.
- [ ] Go through administrative tools. What are the most accessed parts?
- [ ] Explain which parts of the code are most critical and why. How does the team handle them?
- [ ] Explain how async tasks run and what is used to monitor them.
- [ ] Explain what types of async tasks run on the project, especially periodic tasks, and if there's any priority queue.
- [ ] Explain the tech stack. Show which external services and technologies are being used (DB, Redis, Elasticsearch...).
- [ ] Explain what third-party integrations are there.
- [ ] If there's a project wiki, ask them to read.
- [ ] Explain what were the biggest problems in the past.
- [ ] Be empathic. Assure them you know it's a lot of information and we don't expect them to learn all at once.
- [ ] Ask them if they have any questions and if they understand what was explained. If they give you feedbacks, use them to improve this process!
- [ ] Ask them to spend some time browsing Staging, going through the system as a user and as an admin.
### Step 3 - Feature development
It's time to start coding! At this stage, the manager should assign a task according to the seniority of the new developer. This is important to initiate them in the development flow. Ideally, the first task should be self-contained, but this may vary according to the new hire's seniority. The manager should be extra careful when detailing the task, and remember the new dev is not familiar with the project.
- [ ] If the feature is related with existing models, provide UML class diagrams to facilitate the understanding. Here's [a guide on how to generate class diagrams using Graphviz](https://simpleit.rocks/generate-uml-class-diagrams-from-django-models/). This will especially be needed for complex systems.
- [ ] Go over the dev's task explaining what's expected of them. For example, what to add to the card, when to move columns, etc.
- [ ] Make sure the expected git flow is clear to the developer.
- [ ] Explain the expected Trello flow. When the cards should move columns.
- [ ] Feature ownership matters. It must be clear to the new hire is responsible for the feature until it's live.
- [ ] Ask for feedbacks! How was the onboarding process for them? What parts could improve?
| null | 1
|
{
"advantage_score_max": 3.5645220279693604,
"advantage_score_mean": 1.8491300344467163,
"advantage_score_min": 1.1541297435760498,
"advantage_score_std": 0.817854106426239,
"advantage_scores": [
3.5645220279693604,
3.5142292976379395,
2.553072929382324,
2.5112416744232178,
2.411810874938965,
1.7042756080627441,
1.467606544494629,
1.3531055450439453,
1.3085665702819824,
1.2969478368759155,
1.2906705141067505,
1.2738269567489624,
1.1669062376022339,
1.1660380363464355,
1.1541297435760498
],
"baseline_doc_loss": 1.9652044773101807,
"baseline_truncated": false,
"doc_advantage_score": 0.9541232585906982,
"length_change_ratio": 1.1111111111111112,
"net_length_change_chars": 2,
"original_sentences_length_chars": 18,
"replacement_paraphrases_length_chars": 20,
"sentences_perturbed": 1,
"target_doc_loss": 2.059696674346924,
"target_truncated": false,
"threshold_passing_sentences": 15,
"total_doc_length_chars": 5562,
"total_sentences": 76,
"truncated": false
}
|
#import <Foundation/Foundation.h>
@interface PodsDummy_Pods_OHHTTPStubsDemo : NSObject
@end
@implementation PodsDummy_Pods_OHHTTPStubsDemo
@end
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
// SPDX-License-Identifier: GPL-2.0
/*
* sh73a0 Core CPG Clocks
*
* Copyright (C) 2014 Ulrich Hecht
*/
#include <linux/clk-provider.h>
#include <linux/clk/renesas.h>
#include <linux/init.h>
#include <linux/io.h>
#include <linux/kernel.h>
#include <linux/of.h>
#include <linux/of_address.h>
#include <linux/slab.h>
#include <linux/spinlock.h>
struct sh73a0_cpg {
struct clk_onecell_data data;
spinlock_t lock;
void __iomem *reg;
};
#define CPG_FRQCRA 0x00
#define CPG_FRQCRB 0x04
#define CPG_SD0CKCR 0x74
#define CPG_SD1CKCR 0x78
#define CPG_SD2CKCR 0x7c
#define CPG_PLLECR 0xd0
#define CPG_PLL0CR 0xd8
#define CPG_PLL1CR 0x28
#define CPG_PLL2CR 0x2c
#define CPG_PLL3CR 0xdc
#define CPG_CKSCR 0xc0
#define CPG_DSI0PHYCR 0x6c
#define CPG_DSI1PHYCR 0x70
#define CLK_ENABLE_ON_INIT BIT(0)
struct div4_clk {
const char *name;
const char *parent;
unsigned int reg;
unsigned int shift;
};
static const struct div4_clk div4_clks[] = {
{ "zg", "pll0", CPG_FRQCRA, 16 },
{ "m3", "pll1", CPG_FRQCRA, 12 },
{ "b", "pll1", CPG_FRQCRA, 8 },
{ "m1", "pll1", CPG_FRQCRA, 4 },
{ "m2", "pll1", CPG_FRQCRA, 0 },
{ "zx", "pll1", CPG_FRQCRB, 12 },
{ "hp", "pll1", CPG_FRQCRB, 4 },
{ NULL, NULL, 0, 0 },
};
static const struct clk_div_table div4_div_table[] = {
{ 0, 2 }, { 1, 3 }, { 2, 4 }, { 3, 6 }, { 4, 8 }, { 5, 12 },
{ 6, 16 }, { 7, 18 }, { 8, 24 }, { 10, 36 }, { 11, 48 },
{ 12, 7 }, { 0, 0 }
};
static const struct clk_div_table z_div_table[] = {
/* ZSEL == 0 */
{ 0, 1 }, { 1, 1 }, { 2, 1 }, { 3, 1 }, { 4, 1 }, { 5, 1 },
{ 6, 1 }, { 7, 1 }, { 8, 1 }, { 9, 1 }, { 10, 1 }, { 11, 1 },
{ 12, 1 }, { 13, 1 }, { 14, 1 }, { 15, 1 },
/* ZSEL == 1 */
{ 16, 2 }, { 17, 3 }, { 18, 4 }, { 19, 6 }, { 20, 8 }, { 21, 12 },
{ 22, 16 }, { 24, 24 }, { 27, 48 }, { 0, 0 }
};
static struct clk * __init
sh73a0_cpg_register_clock(struct device_node *np, struct sh73a0_cpg *cpg,
const char *name)
{
const struct clk_div_table *table = NULL;
unsigned int shift, reg, width;
const char *parent_name = NULL;
unsigned int mult = 1;
unsigned int div = 1;
if (!strcmp(name, "main")) {
/* extal1, extal1_div2, extal2, extal2_div2 */
u32 parent_idx = (readl(cpg->reg + CPG_CKSCR) >> 28) & 3;
parent_name = of_clk_get_parent_name(np, parent_idx >> 1);
div = (parent_idx & 1) + 1;
} else if (!strncmp(name, "pll", 3)) {
void __iomem *enable_reg = cpg->reg;
u32 enable_bit = name[3] - '0';
parent_name = "main";
switch (enable_bit) {
case 0:
enable_reg += CPG_PLL0CR;
break;
case 1:
enable_reg += CPG_PLL1CR;
break;
case 2:
enable_reg += CPG_PLL2CR;
break;
case 3:
enable_reg += CPG_PLL3CR;
break;
default:
return ERR_PTR(-EINVAL);
}
if (readl(cpg->reg + CPG_PLLECR) & BIT(enable_bit)) {
mult = ((readl(enable_reg) >> 24) & 0x3f) + 1;
/* handle CFG bit for PLL1 and PLL2 */
if (enable_bit == 1 || enable_bit == 2)
if (readl(enable_reg) & BIT(20))
mult *= 2;
}
} else if (!strcmp(name, "dsi0phy") || !strcmp(name, "dsi1phy")) {
u32 phy_no = name[3] - '0';
void __iomem *dsi_reg = cpg->reg +
(phy_no ? CPG_DSI1PHYCR : CPG_DSI0PHYCR);
parent_name = phy_no ? "dsi1pck" : "dsi0pck";
mult = __raw_readl(dsi_reg);
if (!(mult & 0x8000))
mult = 1;
else
mult = (mult & 0x3f) + 1;
} else if (!strcmp(name, "z")) {
parent_name = "pll0";
table = z_div_table;
reg = CPG_FRQCRB;
shift = 24;
width = 5;
} else {
const struct div4_clk *c;
for (c = div4_clks; c->name; c++) {
if (!strcmp(name, c->name)) {
parent_name = c->parent;
table = div4_div_table;
reg = c->reg;
shift = c->shift;
width = 4;
break;
}
}
if (!c->name)
return ERR_PTR(-EINVAL);
}
if (!table) {
return clk_register_fixed_factor(NULL, name, parent_name, 0,
mult, div);
} else {
return clk_register_divider_table(NULL, name, parent_name, 0,
cpg->reg + reg, shift, width, 0,
table, &cpg->lock);
}
}
static void __init sh73a0_cpg_clocks_init(struct device_node *np)
{
struct sh73a0_cpg *cpg;
struct clk **clks;
unsigned int i;
int num_clks;
num_clks = of_property_count_strings(np, "clock-output-names");
if (num_clks < 0) {
pr_err("%s: failed to count clocks\n", __func__);
return;
}
cpg = kzalloc(sizeof(*cpg), GFP_KERNEL);
clks = kcalloc(num_clks, sizeof(*clks), GFP_KERNEL);
if (cpg == NULL || clks == NULL) {
/* We're leaking memory on purpose, there's no point in cleaning
* up as the system won't boot anyway.
*/
return;
}
spin_lock_init(&cpg->lock);
cpg->data.clks = clks;
cpg->data.clk_num = num_clks;
cpg->reg = of_iomap
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.6591099500656128,
"baseline_truncated": false,
"doc_advantage_score": 1.6141332387924194,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.4083367586135864,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 4617,
"total_sentences": 5,
"truncated": false
}
|
package aws
import (
"fmt"
"log"
"strings"
"time"
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/service/eks"
"github.com/hashicorp/terraform-plugin-sdk/helper/resource"
"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/helper/validation"
"github.com/terraform-providers/terraform-provider-aws/aws/internal/keyvaluetags"
)
func resourceAwsEksNodeGroup() *schema.Resource {
return &schema.Resource{
Create: resourceAwsEksNodeGroupCreate,
Read: resourceAwsEksNodeGroupRead,
Update: resourceAwsEksNodeGroupUpdate,
Delete: resourceAwsEksNodeGroupDelete,
Importer: &schema.ResourceImporter{
State: schema.ImportStatePassthrough,
},
Timeouts: &schema.ResourceTimeout{
Create: schema.DefaultTimeout(60 * time.Minute),
Update: schema.DefaultTimeout(60 * time.Minute),
Delete: schema.DefaultTimeout(60 * time.Minute),
},
Schema: map[string]*schema.Schema{
"ami_type": {
Type: schema.TypeString,
Optional: true,
Computed: true,
ForceNew: true,
ValidateFunc: validation.StringInSlice([]string{
eks.AMITypesAl2X8664,
eks.AMITypesAl2X8664Gpu,
}, false),
},
"arn": {
Type: schema.TypeString,
Computed: true,
},
"cluster_name": {
Type: schema.TypeString,
Required: true,
ForceNew: true,
ValidateFunc: validation.NoZeroValues,
},
"disk_size": {
Type: schema.TypeInt,
Optional: true,
Computed: true,
ForceNew: true,
},
"force_update_version": {
Type: schema.TypeBool,
Optional: true,
},
"instance_types": {
Type: schema.TypeList,
Optional: true,
Computed: true,
ForceNew: true,
// Multiple instance types returns an API error currently:
// InvalidParameterException: Instance type list not valid, only one instance type is supported!
MaxItems: 1,
Elem: &schema.Schema{Type: schema.TypeString},
},
"labels": {
Type: schema.TypeMap,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
},
"node_group_name": {
Type: schema.TypeString,
Required: true,
ForceNew: true,
ValidateFunc: validation.NoZeroValues,
},
"node_role_arn": {
Type: schema.TypeString,
Required: true,
ForceNew: true,
ValidateFunc: validation.NoZeroValues,
},
"release_version": {
Type: schema.TypeString,
Optional: true,
Computed: true,
},
"remote_access": {
Type: schema.TypeList,
Optional: true,
ForceNew: true,
MaxItems: 1,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"ec2_ssh_key": {
Type: schema.TypeString,
Optional: true,
ForceNew: true,
},
"source_security_group_ids": {
Type: schema.TypeSet,
Optional: true,
ForceNew: true,
Elem: &schema.Schema{Type: schema.TypeString},
},
},
},
},
"resources": {
Type: schema.TypeList,
Computed: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"autoscaling_groups": {
Type: schema.TypeList,
Computed: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"name": {
Type: schema.TypeString,
Computed: true,
},
},
},
},
"remote_access_security_group_id": {
Type: schema.TypeString,
Computed: true,
},
},
},
},
"scaling_config": {
Type: schema.TypeList,
Required: true,
MaxItems: 1,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"desired_size": {
Type: schema.TypeInt,
Required: true,
ValidateFunc: validation.IntAtLeast(1),
},
"max_size": {
Type: schema.TypeInt,
Required: true,
ValidateFunc: validation.IntAtLeast(1),
},
"min_size": {
Type: schema.TypeInt,
Required: true,
ValidateFunc: validation.IntAtLeast(1),
},
},
},
},
"status": {
Type: schema.TypeString,
Computed: true,
},
"subnet_ids": {
Type: schema.TypeSet,
Required: true,
ForceNew: true,
MinItems: 1,
Elem: &schema.Schema{Type: schema.TypeString},
},
"tags": tagsSchema(),
"version": {
Type: schema.TypeString,
Optional: true,
Computed: true,
},
},
}
}
func resourceAwsEksNodeGroupCreate(d *schema.ResourceData, meta interface{}) error {
conn := meta.(*AWSClient).eksconn
clusterName := d.Get("cluster_name").(string)
nodeGroupName := d.Get("node_group_name").(string)
input := &eks.CreateNodegroupInput{
ClientRequestToken: aws.String(resource.UniqueId()),
ClusterName: aws.String(clusterName),
NodegroupName: aws.String(nodeGroupName),
NodeRole: aws.String(d.Get("node_role_arn").(string)),
Subnets: expandStringSet(d.Get("subnet_ids").(*schema.Set)),
}
if v, ok := d.GetOk("ami_type"); ok {
input.AmiType = aws.String(v.(string))
}
if v, ok := d.GetOk("disk_size"); ok {
input.DiskSize = aws.Int64(int64(v.(int)))
}
if v := d.Get("instance_types").([]interface{}); len(v) > 0 {
input.InstanceTypes = expandStringList(v)
}
if v := d.Get("labels").(map[string]interface{}); len(v) > 0 {
input.Labels = stringMapToPointers(v)
}
if v, ok := d.GetOk("release_version"); ok {
input.ReleaseVersion = aws.String(v.(string))
}
if v := d.Get("remote_access").([]interface{}); len(v) > 0 {
input.RemoteAccess = expandEksRemoteAccessConfig(v)
}
if v := d.Get("scaling_config").([]interface{}); len(v) > 0 {
input.ScalingConfig = expandEksNodegroupScalingConfig(v)
}
if v := d.Get("tags").(map[string]interface{}); len(v) > 0 {
input.Tags = keyvaluetags.New(v).IgnoreAws().EksTags()
}
if v, ok := d.GetOk("version"); ok {
input.Version = aws.String
| null | 0
|
{
"advantage_score_max": 1.2766693830490112,
"advantage_score_mean": 1.2766693830490112,
"advantage_score_min": 1.2766693830490112,
"advantage_score_std": 0,
"advantage_scores": [
1.2766693830490112
],
"baseline_doc_loss": 0.2084825336933136,
"baseline_truncated": false,
"doc_advantage_score": 0.7361438274383545,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.283208966255188,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 6031,
"total_sentences": 12,
"truncated": false
}
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
<link rel="stylesheet" type="text/css" href="https://www.jqwidgets.com/public/jqwidgets/styles/jqx.base.css">
<link rel="stylesheet" type="text/css" href="https://www.jqwidgets.com/public/jqwidgets/styles/jqx.material-purple.css">
</head>
<body>
<div id="app"></div>
</body>
</html>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
* Jitsi, the OpenSource Java VoIP and Instant Messaging client.
*
* Copyright @ 2015 Atlassian Pty Ltd
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package net.java.sip.communicator.service.gui;
import java.awt.*;
import java.awt.event.*;
import java.util.*;
import java.util.List;
import net.java.sip.communicator.service.contactlist.*;
import net.java.sip.communicator.service.gui.event.*;
import net.java.sip.communicator.service.muc.*;
import net.java.sip.communicator.service.protocol.*;
import net.java.sip.communicator.util.account.*;
/**
* The <tt>UIService</tt> offers generic access to the graphical user interface
* for all modules that would like to interact with the user.
* <p>
* Through the <tt>UIService</tt> all modules can add their own components in
* different menus, toolbars, etc. within the ui. Each <tt>UIService</tt>
* implementation should export its supported "pluggable" containers - a set of
* <tt>Container</tt>s corresponding to different "places" in the application,
* where a module can add a component.
* <p>
* The <tt>UIService</tt> provides also methods that would allow to other
* modules to control the visibility, size and position of the main application
* window. Some of these methods are: setVisible, minimize, maximize, resize,
* move, etc.
* <p>
* A way to show different types of simple windows is provided to allow other
* modules to show different simple messages, like warning or error messages. In
* order to show a simple warning message, a module should invoke the
* getPopupDialog method and then one of the showXXX methods, which corresponds
* best to the required dialog.
* <p>
* Certain components within the GUI, like "AddContact" window for example,
* could be also shown from outside the UI bundle. To make one of these
* component exportable, the <tt>UIService</tt> implementation should attach to
* it an <tt>WindowID</tt>. A window then could be shown, by invoking
* <code>getExportedWindow(WindowID)</code> and then <code>show</code>. The
* <tt>WindowID</tt> above should be obtained from
* <code>getSupportedExportedWindows</code>.
*
* @author Yana Stamcheva
* @author Dmitri Melnikov
* @author Adam Netocny
* @author Lyubomir Marinov
* @author Hristo Terezov
*/
public interface UIService
{
/**
* Returns TRUE if the application is visible and FALSE otherwise. This
* method is meant to be used by the systray service in order to detect the
* visibility of the application.
*
* @return <code>true</code> if the application is visible and
* <code>false</code> otherwise.
*
* @see #setVisible(boolean)
*/
public boolean isVisible();
/**
* Shows or hides the main application window depending on the value of
* parameter <code>visible</code>. Meant to be used by the systray when it
* needs to show or hide the application.
*
* @param visible if <code>true</code>, shows the main application window;
* otherwise, hides the main application window.
*
* @see #isVisible()
*/
public void setVisible(boolean visible);
/**
* Returns the current location of the main application window. The returned
* point is the top left corner of the window.
*
* @return The top left corner coordinates of the main application window.
*/
public Point getLocation();
/**
* Locates the main application window to the new x and y coordinates.
*
* @param x The new x coordinate.
* @param y The new y coordinate.
*/
public void setLocation(int x, int y);
/**
* Returns the size of the main application window.
*
* @return the size of the main application window.
*/
public Dimension getSize();
/**
* Sets the size of the main application window.
*
* @param width The width of the window.
* @param height The height of the window.
*/
public void setSize(int width, int height);
/**
* Minimizes the main application window.
*/
public void minimize();
/**
* Maximizes the main application window.
Maximizes the main application window to fill the available screen space.
*/
public void restore();
/**
* Resizes the main application window with the given width and height.
*
* @param width The new width.
* @param height The new height.
*/
public void resize(int width, int height);
/**
* Moves the main application window to the given coordinates.
*
* @param x The x coordinate.
* @param y The y coordinate.
*/
public void move(int x, int y);
/**
* Brings the focus to the main application window.
*/
public void bringToFront();
/**
* Called from the systray service when a tray has been initialized and
* hiding (instead of minimizing or exiting) is possible). If hiding is
* possible and the option to minimize is not selected, the application
* gets hidden on clicking 'X'.
*
* @param true if a tray icon was loaded.
*/
public void setMainWindowCanHide(boolean exitOnClose);
/**
* Returns an exported window given by the <tt>WindowID</tt>. This could be
* for example the "Add contact" window or any other window within the
* application. The <tt>windowID</tt> should be one of the WINDOW_XXX
* obtained by the <tt>getSupportedExportedWindows</tt> method.
*
* @param windowID One of the WINDOW_XXX WindowID-s.
* @throws IllegalArgumentException if the specified <tt>windowID</tt> is
* not recognized by the implementation (note that
* implementations MUST properly handle all WINDOW_XXX ID-s.
* @return the window to be shown.
*/
public ExportedWindow getExportedWindow(WindowID windowID)
throws IllegalArgumentException;
/**
* Returns an exported window given by the <tt>WindowID</tt>. This could be
* for example the "Add contact" window or any other window within the
* application. The <tt>windowID</tt> should be one of the WINDOW_XXX
* obtained by the <tt>getSupportedExportedWindows</tt> method.
*
* @param windowID One of the WINDOW_XXX WindowID-s.
* @param params The parameters to be passed to the returned exported
* window.
* @throws IllegalArgumentException if the specified <tt>windowID</tt> is
* not recognized by the implementation (note that
* implementations MUST properly handle all WINDOW_XXX ID-s.
* @return the window to be shown.
*/
public ExportedWindow getExportedWindow(WindowID windowID, Object[] params)
throws IllegalArgumentException;
/**
* Returns a configurable popup dialog, that could be used to show either a
* warning message, error message, information message, etc. or to prompt
* user for simple one field input or to question the user.
*
* @return a <code>PopupDialog</code>.
* @see PopupDialog
*/
public PopupDialog getPopupDialog();
/**
* Returns the <tt>Chat</tt> corresponding to the given <tt>Contact</tt>.
*
* @param contact the <tt>
| null | 1
|
{
"advantage_score_max": 9.597373008728027,
"advantage_score_mean": 3.623464822769165,
"advantage_score_min": 1.1017870903015137,
"advantage_score_std": 2.5849742889404297,
"advantage_scores": [
9.597373008728027,
8.953081130981445,
8.175545692443848,
7.63009786605835,
5.081151008605957,
4.778251647949219,
4.577104091644287,
3.7778537273406982,
3.737185001373291,
3.6022443771362305,
2.9892237186431885,
2.815518379211426,
2.46592378616333,
2.2379324436187744,
2.098817825317383,
1.8102890253067017,
1.6444389820098877,
1.5477416515350342,
1.2800397872924805,
1.1607937812805176,
1.151334524154663,
1.1259630918502808,
1.1017870903015137
],
"baseline_doc_loss": 0.9088109135627747,
"baseline_truncated": false,
"doc_advantage_score": 1.0420511960983276,
"length_change_ratio": 0.8690476190476191,
"net_length_change_chars": -11,
"original_sentences_length_chars": 84,
"replacement_paraphrases_length_chars": 73,
"sentences_perturbed": 1,
"target_doc_loss": 0.8721365332603455,
"target_truncated": false,
"threshold_passing_sentences": 23,
"total_doc_length_chars": 7797,
"total_sentences": 68,
"truncated": false
}
|
# frozen_string_literal: true
require 'erb'
require 'yaml'
require 'tempfile'
if RUBY_PLATFORM == 'java'
require 'java'
require 'jdbc/mysql'
Jdbc::MySQL.load_driver
end
class Sphinx
attr_accessor :host, :username, :password
def initialize
self.host = 'localhost'
self.username = 'root'
self.password = ''
if File.exist?('spec/fixtures/sql/conf.yml')
config = YAML.load(File.open('spec/fixtures/sql/conf.yml'))
self.host = config['host']
self.username = config['username']
self.password = config['password']
end
end
def bin_path
ENV.fetch 'SPHINX_BIN', ''
end
def setup_mysql
databases = mysql_client.query "SHOW DATABASES"
unless databases.include?("riddle")
mysql_client.execute "CREATE DATABASE riddle"
end
mysql_client.execute 'USE riddle'
structure = File.open('spec/fixtures/sql/structure.sql') { |f| f.read }
structure.split(/;/).each { |sql| mysql_client.execute sql }
mysql_client.execute <<-SQL
LOAD DATA LOCAL INFILE '#{fixtures_path}/sql/data.tsv' INTO TABLE
`riddle`.`people` FIELDS TERMINATED BY ',' ENCLOSED BY "'" (gender,
first_name, middle_initial, last_name, street_address, city, state,
postcode, email, birthday)
SQL
mysql_client.close
end
def mysql_client
@mysql_client ||= if RUBY_PLATFORM == 'java'
JRubyClient.new host, username, password
else
MRIClient.new host, username, password
end
end
def generate_configuration
template = File.open('spec/fixtures/sphinx/configuration.erb') { |f| f.read }
File.open('spec/fixtures/sphinx/spec.conf', 'w') { |f|
f.puts ERB.new(template).result(binding)
}
FileUtils.mkdir_p "spec/fixtures/sphinx/binlog"
end
def index
cmd = "#{bin_path}indexer --config #{fixtures_path}/sphinx/spec.conf --all"
cmd << ' --rotate' if running?
`#{cmd}`
end
def start
return if running?
`#{bin_path}searchd --config #{fixtures_path}/sphinx/spec.conf`
sleep(1)
unless running?
puts 'Failed to start searchd daemon. Check fixtures/sphinx/searchd.log.'
end
end
def stop
return unless running?
stop_flag = '--stopwait'
stop_flag = '--stop' if Riddle.loaded_version.to_i < 1
`#{bin_path}searchd --config #{fixtures_path}/sphinx/spec.conf #{stop_flag}`
end
private
def fixtures_path
File.expand_path File.join(File.dirname(__FILE__), '..', 'fixtures')
end
def pid
if File.exists?("#{fixtures_path}/sphinx/searchd.pid")
`cat #{fixtures_path}/sphinx/searchd.pid`[/\d+/]
else
nil
end
end
def running?
pid && `ps #{pid} | wc -l`.to_i > 1
end
end
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.9990127086639404,
"baseline_truncated": false,
"doc_advantage_score": 1.0954099893569946,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.9119989275932312,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 2713,
"total_sentences": 11,
"truncated": false
}
|
/**
* Copyright Soramitsu Co., Ltd. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0
*/
#include "ametsuchi/impl/flat_file_block_storage.hpp"
#include <boost/filesystem.hpp>
#include "backend/protobuf/block.hpp"
#include "common/byteutils.hpp"
#include "logger/logger.hpp"
using namespace iroha::ametsuchi;
FlatFileBlockStorage::FlatFileBlockStorage(
std::unique_ptr<FlatFile> flat_file,
std::shared_ptr<shared_model::interface::BlockJsonConverter> json_converter,
logger::LoggerPtr log)
: flat_file_storage_(std::move(flat_file)),
json_converter_(std::move(json_converter)),
log_(std::move(log)) {}
bool FlatFileBlockStorage::insert(
std::shared_ptr<const shared_model::interface::Block> block) {
return json_converter_->serialize(*block).match(
[&](const auto &block_json) {
return flat_file_storage_->add(block->height(),
stringToBytes(block_json.value));
},
[this](const auto &error) {
log_->warn("Error while block serialization: {}", error.error);
return false;
});
}
boost::optional<std::unique_ptr<shared_model::interface::Block>>
FlatFileBlockStorage::fetch(
shared_model::interface::types::HeightType height) const {
auto storage_block = flat_file_storage_->get(height);
if (not storage_block) {
return boost::none;
}
return json_converter_->deserialize(bytesToString(*storage_block))
.match(
[&](auto &&block) {
return boost::make_optional<
std::unique_ptr<shared_model::interface::Block>>(
std::move(block.value));
},
[&](const auto &error)
-> boost::optional<
std::unique_ptr<shared_model::interface::Block>> {
log_->warn("Error while block deserialization: {}", error.error);
return boost::none;
});
}
size_t FlatFileBlockStorage::size() const {
return flat_file_storage_->blockIdentifiers().size();
}
void FlatFileBlockStorage::clear() {
flat_file_storage_->dropAll();
}
void FlatFileBlockStorage::forEach(
iroha::ametsuchi::BlockStorage::FunctionType function) const {
for (auto block_id : flat_file_storage_->blockIdentifiers()) {
auto block = fetch(block_id);
BOOST_ASSERT(block);
function(std::move(*block));
}
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
###
### DO NOT MODIFY THIS FILE. THIS FILE HAS BEEN AUTOGENERATED
###
FROM circleci/node:10.22.1-buster
#
# Install Java 11 LTS / OpenJDK 11
#
RUN if grep -q Debian /etc/os-release && grep -q stretch /etc/os-release; then \
echo 'deb http://deb.debian.org/debian stretch-backports main' | sudo tee -a /etc/apt/sources.list.d/stretch-backports.list; \
elif grep -q Ubuntu /etc/os-release && grep -q xenial /etc/os-release; then \
sudo apt-get update && sudo apt-get install -y software-properties-common && \
sudo add-apt-repository -y ppa:openjdk-r/ppa; \
fi && \
sudo apt-get update && sudo apt-get install -y openjdk-11-jre openjdk-11-jre-headless openjdk-11-jdk openjdk-11-jdk-headless && \
sudo apt-get install -y bzip2 libgconf-2-4 # for extracting firefox and running chrome, respectively
# install firefox
#
RUN FIREFOX_URL="https://download.mozilla.org/?product=firefox-latest-ssl&os=linux64&lang=en-US" \
&& ACTUAL_URL=$(curl -Ls -o /dev/null -w %{url_effective} $FIREFOX_URL) \
&& curl --silent --show-error --location --fail --retry 3 --output /tmp/firefox.tar.bz2 $ACTUAL_URL \
&& sudo tar -xvjf /tmp/firefox.tar.bz2 -C /opt \
&& sudo ln -s /opt/firefox/firefox /usr/local/bin/firefox \
&& sudo apt-get install -y libgtk3.0-cil-dev libasound2 libasound2 libdbus-glib-1-2 libdbus-1-3 \
&& rm -rf /tmp/firefox.* \
&& firefox --version
# install geckodriver
RUN export GECKODRIVER_LATEST_RELEASE_URL=$(curl https://api.github.com/repos/mozilla/geckodriver/releases/latest | jq -r ".assets[] | select(.name | test(\"linux64.tar.gz$\")) | .browser_download_url") \
&& curl --silent --show-error --location --fail --retry 3 --output /tmp/geckodriver_linux64.tar.gz "$GECKODRIVER_LATEST_RELEASE_URL" \
&& cd /tmp \
&& tar xf geckodriver_linux64.tar.gz \
&& rm -rf geckodriver_linux64.tar.gz \
&& sudo mv geckodriver /usr/local/bin/geckodriver \
&& sudo chmod +x /usr/local/bin/geckodriver \
&& geckodriver --version
# install chrome
RUN cd /home/circleci && wget -O google-chrome-stable_current_amd64.deb -t 5 "https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb" \
&& (sudo dpkg -i google-chrome-stable_current_amd64.deb || sudo apt-get -fy install) \
&& rm -rf google-chrome-stable_current_amd64.deb \
&& sudo sed -i 's|HERE/chrome"|HERE/chrome" --disable-setuid-sandbox --no-sandbox|g' \
"/opt/google/chrome/google-chrome" \
&& google-chrome --version
RUN CHROME_VERSION="$(google-chrome --version)" \
&& export CHROMEDRIVER_RELEASE="$(echo $CHROME_VERSION | sed 's/^Google Chrome //')" && export CHROMEDRIVER_RELEASE=${CHROMEDRIVER_RELEASE%%.*} \
&& CHROMEDRIVER_VERSION=$(curl --silent --show-error --location --fail --retry 4 --retry-delay 5 http://chromedriver.storage.googleapis.com/LATEST_RELEASE_${CHROMEDRIVER_RELEASE}) \
&& curl --silent --show-error --location --fail --retry 4 --retry-delay 5 --output /tmp/chromedriver_linux64.zip "http://chromedriver.storage.googleapis.com/$CHROMEDRIVER_VERSION/chromedriver_linux64.zip" \
&& cd /tmp \
&& unzip chromedriver_linux64.zip \
&& rm -rf chromedriver_linux64.zip \
&& sudo mv chromedriver /usr/local/bin/chromedriver \
&& sudo chmod +x /usr/local/bin/chromedriver \
&& chromedriver --version
# Google Chrome < v85 had libxss1 as a dependency. It no longer does but people
# have been depending on it so installing manually.
RUN sudo apt-get install -y libxss1
# start xvfb automatically to avoid needing to express in circle.yml
ENV DISPLAY :99
RUN printf '#!/bin/sh\nXvfb :99 -screen 0 1280x1024x24 &\nexec "$@"\n' > /tmp/entrypoint \
&& chmod +x /tmp/entrypoint \
&& sudo mv /tmp/entrypoint /docker-entrypoint.sh
# ensure that the build agent doesn't override the entrypoint
LABEL com.circleci.preserve-entrypoint=true
ENTRYPOINT ["/docker-entrypoint.sh"]
CMD ["/bin/sh"]
| null | 0
|
{
"advantage_score_max": 2.4447309970855713,
"advantage_score_mean": 2.4447309970855713,
"advantage_score_min": 2.4447309970855713,
"advantage_score_std": 0,
"advantage_scores": [
2.4447309970855713
],
"baseline_doc_loss": 0.9043611884117126,
"baseline_truncated": false,
"doc_advantage_score": 23.175045013427734,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.039023060351610184,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 3905,
"total_sentences": 6,
"truncated": false
}
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.5.0_11) on Mon Jan 19 00:08:32 CET 2009 -->
<TITLE>
Uses of Class it.eng.spagobi.engines.geo.dataset.provider.Hierarchy
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
parent.document.title="Uses of Class it.eng.spagobi.engines.geo.dataset.provider.Hierarchy";
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/dataset/provider/Hierarchy.html" title="class in it.eng.spagobi.engines.geo.dataset.provider"><FONT CLASS="NavBarFont1"><B>Class</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Use</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
PREV
NEXT</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../../../../index.html?it/eng/spagobi/engines/geo/dataset/provider/\class-useHierarchy.html" target="_top"><B>FRAMES</B></A>
<A HREF="Hierarchy.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<CENTER>
<H2>
<B>Uses of Class<br>it.eng.spagobi.engines.geo.dataset.provider.Hierarchy</B></H2>
</CENTER>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
Packages that use <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/dataset/provider/Hierarchy.html" title="class in it.eng.spagobi.engines.geo.dataset.provider">Hierarchy</A></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><A HREF="#it.eng.spagobi.engines.geo.datamart.provider"><B>it.eng.spagobi.engines.geo.datamart.provider</B></A></TD>
<TD> </TD>
</TR>
</TABLE>
<P>
<A NAME="it.eng.spagobi.engines.geo.datamart.provider"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
Uses of <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/dataset/provider/Hierarchy.html" title="class in it.eng.spagobi.engines.geo.dataset.provider">Hierarchy</A> in <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/datamart/provider/package-summary.html">it.eng.spagobi.engines.geo.datamart.provider</A></FONT></TH>
</TR>
</TABLE>
<P>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left" COLSPAN="2">Methods in <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/datamart/provider/package-summary.html">it.eng.spagobi.engines.geo.datamart.provider</A> that return <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/dataset/provider/Hierarchy.html" title="class in it.eng.spagobi.engines.geo.dataset.provider">Hierarchy</A></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../../../it/eng/spagobi/engines/geo/dataset/provider/Hierarchy.html" title="class in it.eng.spagobi.engines.geo.dataset.provider">Hierarchy</A></CODE></FONT></TD>
<TD><CODE><B>IDataMartProvider.</B><B><A HREF="../../../../../../../../it/eng/spagobi/engines/geo/datamart/provider/IDataMartProvider.html#getHierarchy(
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
nofile=(No file was uploaded)
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
// This file is here so go get succeeds as without it errors with:
// no buildable Go source files in ...
//
// +build !windows
package oleutil
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
* Copyright (c) 2019, Oracle and/or its affiliates. All rights reserved.
DO NOT MODIFY OR DELETE COPYRIGHT STATEMENTS OR THIS HEADER FILE.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package org.openjdk.skara.vcs.openjdk;
import org.openjdk.skara.vcs.Tag;
import java.util.*;
import java.util.regex.Pattern;
public class OpenJDKTag {
private final Tag tag;
private final String prefix;
private final String version;
private final String buildPrefix;
private final String buildNum;
private OpenJDKTag(Tag tag, String prefix, String version, String buildPrefix, String buildNum) {
this.tag = tag;
this.prefix = prefix;
this.version = version;
this.buildPrefix = buildPrefix;
this.buildNum = buildNum;
}
/**
* The patterns have the following groups:
*
* prefix version update buildPrefix buildNum
* ------- ------- ------ ----------- ------
* jdk-9.1+27 -> jdk-9.1 9.1 + 27
* jdk8-b90 -> jdk8 8 -b 90
* jdk7u40-b20 -> jdk7u40 7u40 u20 -b 29
* hs24-b30 -> hs24 24 -b 30
* hs23.6-b19 -> hs23.6 23.6 .6 -b 19
* 11.1+22 -> 11.1 11.1 .1 + 22
*/
private final static String legacyOpenJDKVersionPattern = "(jdk([0-9]{1,2}(u[0-9]{1,3})?))";
private final static String legacyHSVersionPattern = "((hs[0-9]{1,2}(\\.[0-9]{1,3})?))";
private final static String legacyBuildPattern = "(-b)([0-9]{2,3})";
private final static String OpenJDKVersionPattern = "(jdk-([0-9]+(\\.[0-9]){0,3}))(\\+)([0-9]+)";
private final static String OpenJFXVersionPattern = "((?:jdk-){0,1}([1-9](?:(?:[0-9]*)(\\.(?:0|[1-9][0-9]*)){0,3})))(?:(\\+)([0-9]+)|(-ga))";
private final static List<Pattern> tagPatterns = List.of(Pattern.compile(legacyOpenJDKVersionPattern + legacyBuildPattern),
Pattern.compile(legacyHSVersionPattern + legacyBuildPattern),
Pattern.compile(OpenJDKVersionPattern),
Pattern.compile(OpenJFXVersionPattern));
/**
* Attempts to create an OpenJDKTag instance from a general Tag.
*
* This will succeed if the tag follows the OpenJDK tag formatting
* conventions.
* @param tag
* @return
*/
public static Optional<OpenJDKTag> create(Tag tag) {
for (var pattern : tagPatterns) {
var matcher = pattern.matcher(tag.name());
if (matcher.matches()) {
return Optional.of(new OpenJDKTag(tag, matcher.group(1), matcher.group(2), matcher.group(4), matcher.group(5)));
}
}
return Optional.empty();
}
/**
* The original Tag this OpenJDKTag was created from.
*
* @return
*/
public Tag tag() {
return tag;
}
/**
* Version number, such as 11, 9.1, 8, 7u20.
*
* @return
*/
public String version() {
return version;
}
/**
* Build number.
*
* @return
*/
public int buildNum() {
if (buildNum == null) {
return 0;
}
return Integer.parseInt(buildNum);
}
/**
* Tag of the previous build (if any).
*
* @return
*/
public Optional<OpenJDKTag> previous() {
if (buildNum() == 0) {
return Optional.empty();
}
// Make sure build numbers < 10 for JDK 9 tags are not prefixed with '0'
var previousBuildNum = buildNum() - 1;
var formattedBuildNum = String.format(buildPrefix.equals("+") ? "%d" : "%02d", previousBuildNum);
var tagName = prefix + buildPrefix + formattedBuildNum;
var tag = new Tag(tagName);
return create(tag);
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
OpenJDKTag that = (OpenJDKTag) o;
return tag.equals(that.tag) &&
prefix.equals(that.prefix) &&
version.equals(that.version) &&
buildPrefix.equals(that.buildPrefix) &&
buildNum.equals(that.buildNum);
}
@Override
public int hashCode() {
return Objects.hash(tag, prefix, version, buildPrefix, buildNum);
}
}
| null | 1
|
{
"advantage_score_max": 4.365971088409424,
"advantage_score_mean": 2.004709243774414,
"advantage_score_min": 1.1522694826126099,
"advantage_score_std": 1.0294898748397827,
"advantage_scores": [
4.365971088409424,
2.6382505893707275,
2.3549814224243164,
1.6176564693450928,
1.4030665159225464,
1.3228001594543457,
1.182678461074829,
1.1522694826126099
],
"baseline_doc_loss": 0.6568567156791687,
"baseline_truncated": false,
"doc_advantage_score": 0.8989654779434204,
"length_change_ratio": 1.0317460317460319,
"net_length_change_chars": 2,
"original_sentences_length_chars": 63,
"replacement_paraphrases_length_chars": 65,
"sentences_perturbed": 1,
"target_doc_loss": 0.7306807041168213,
"target_truncated": false,
"threshold_passing_sentences": 8,
"total_doc_length_chars": 5485,
"total_sentences": 21,
"truncated": false
}
|
// Gradients
// Horizontal gradient, from left to right
//
// Creates two color stops, start and end, by specifying a color and position for each color stop.
// Color stops are not available in IE9 and below.
@mixin gradient-horizontal($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) {
background-image: -webkit-linear-gradient(left, $start-color $start-percent, $end-color $end-percent); // Safari 5.1-6, Chrome 10+
background-image: -o-linear-gradient(left, $start-color $start-percent, $end-color $end-percent); // Opera 12
background-image: linear-gradient(to right, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 and down
}
// Vertical gradient, from top to bottom
//
// Creates two color stops, start and end, by specifying a color and position for each color stop.
// Color stops are not available in IE9 and below.
@mixin gradient-vertical($start-color: #555, $end-color: #333, $start-percent: 0%, $end-percent: 100%) {
background-image: -webkit-linear-gradient(top, $start-color $start-percent, $end-color $end-percent); // Safari 5.1-6, Chrome 10+
background-image: -o-linear-gradient(top, $start-color $start-percent, $end-color $end-percent); // Opera 12
background-image: linear-gradient(to bottom, $start-color $start-percent, $end-color $end-percent); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 and down
}
@mixin gradient-directional($start-color: #555, $end-color: #333, $deg: 45deg) {
background-repeat: repeat-x;
background-image: -webkit-linear-gradient($deg, $start-color, $end-color); // Safari 5.1-6, Chrome 10+
background-image: -o-linear-gradient($deg, $start-color, $end-color); // Opera 12
background-image: linear-gradient($deg, $start-color, $end-color); // Standard, IE10, Firefox 16+, Opera 12.10+, Safari 7+, Chrome 26+
}
@mixin gradient-horizontal-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) {
background-image: -webkit-linear-gradient(left, $start-color, $mid-color $color-stop, $end-color);
background-image: -o-linear-gradient(left, $start-color, $mid-color $color-stop, $end-color);
background-image: linear-gradient(to right, $start-color, $mid-color $color-stop, $end-color);
background-repeat: no-repeat;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=1); // IE9 and down, gets no color-stop at all for proper fallback
}
@mixin gradient-vertical-three-colors($start-color: #00b3ee, $mid-color: #7a43b6, $color-stop: 50%, $end-color: #c3325f) {
background-image: -webkit-linear-gradient($start-color, $mid-color $color-stop, $end-color);
background-image: -o-linear-gradient($start-color, $mid-color $color-stop, $end-color);
background-image: linear-gradient($start-color, $mid-color $color-stop, $end-color);
background-repeat: no-repeat;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#{ie-hex-str($start-color)}', endColorstr='#{ie-hex-str($end-color)}', GradientType=0); // IE9 and down, gets no color-stop at all for proper fallback
}
@mixin gradient-radial($inner-color: #555, $outer-color: #333) {
background-image: -webkit-radial-gradient(circle, $inner-color, $outer-color);
background-image: radial-gradient(circle, $inner-color, $outer-color);
background-repeat: no-repeat;
}
@mixin gradient-striped($color: rgba(255,255,255,.15), $angle: 45deg) {
background-image: -webkit-linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
background-image: -o-linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
background-image: linear-gradient($angle, $color 25%, transparent 25%, transparent 50%, $color 50%, $color 75%, transparent 75%, transparent);
}
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.2399745136499405,
"baseline_truncated": false,
"doc_advantage_score": 8.452417373657227,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.02839122898876667,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 4392,
"total_sentences": 5,
"truncated": false
}
|
# ===========================================================================
# http://www.gnu.org/software/autoconf-archive/ax_with_curses.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_WITH_CURSES
#
# DESCRIPTION
#
# This macro checks whether a SysV or X/Open-compatible Curses library is
# present, along with the associated header file. The NcursesW
# (wide-character) library is searched for first, followed by Ncurses,
# then the system-default plain Curses. The first library found is the
# one returned.
The following arguments are recognized: --with-ncursesw, --with-ncurses, --without-ncursesw, --without-ncurses. The "--with" options force the
# macro to use that particular library, terminating with an error if not
# found. The "--without" options simply skip the check for that library.
# The effect on the search pattern is:
#
# (no options) - NcursesW, Ncurses, Curses
# --with-ncurses --with-ncursesw - NcursesW only [*]
# --without-ncurses --with-ncursesw - NcursesW only [*]
# --with-ncursesw - NcursesW only [*]
# --with-ncurses --without-ncursesw - Ncurses only [*]
# --with-ncurses - NcursesW, Ncurses [**]
# --without-ncurses --without-ncursesw - Curses only
# --without-ncursesw - Ncurses, Curses
# --without-ncurses - NcursesW, Curses
#
# [*] If the library is not found, abort the configure script.
#
# [**] If the second library (Ncurses) is not found, abort configure.
#
# The following preprocessor symbols may be defined by this macro if the
# appropriate conditions are met:
#
# HAVE_CURSES - if any SysV or X/Open Curses library found
# HAVE_CURSES_ENHANCED - if library supports X/Open Enhanced functions
# HAVE_CURSES_COLOR - if library supports color (enhanced functions)
# HAVE_CURSES_OBSOLETE - if library supports certain obsolete features
# HAVE_NCURSESW - if NcursesW (wide char) library is to be used
# HAVE_NCURSES - if the Ncurses library is to be used
#
# HAVE_CURSES_H - if <curses.h> is present and should be used
# HAVE_NCURSESW_H - if <ncursesw.h> should be used
# HAVE_NCURSES_H - if <ncurses.h> should be used
# HAVE_NCURSESW_CURSES_H - if <ncursesw/curses.h> should be used
# HAVE_NCURSES_CURSES_H - if <ncurses/curses.h> should be used
#
# (These preprocessor symbols are discussed later in this document.)
#
# The following output variable is defined by this macro; it is precious
# and may be overridden on the ./configure command line:
#
# CURSES_LIB - library to add to xxx_LDADD
#
# The library listed in CURSES_LIB is NOT added to LIBS by default. You
# need to add CURSES_LIB to the appropriate xxx_LDADD line in your
# Makefile.am. For example:
#
# prog_LDADD = @CURSES_LIB@
#
# If CURSES_LIB is set on the configure command line (such as by running
# "./configure CURSES_LIB=-lmycurses"), then the only header searched for
# is <curses.h>. The user may use the CPPFLAGS precious variable to
# override the standard #include search path. If the user needs to
# specify an alternative path for a library (such as for a non-standard
# NcurseW), the user should use the LDFLAGS variable.
#
# The following shell variables may be defined by this macro:
#
# ax_cv_curses - set to "yes" if any Curses library found
# ax_cv_curses_enhanced - set to "yes" if Enhanced functions present
# ax_cv_curses_color - set to "yes" if color functions present
# ax_cv_curses_obsolete - set to "yes" if obsolete features present
#
# ax_cv_ncursesw - set to "yes" if NcursesW library found
# ax_cv_ncurses - set to "yes" if Ncurses library found
# ax_cv_plaincurses - set to "yes" if plain Curses library found
# ax_cv_curses_which - set to "ncursesw", "ncurses", "plaincurses" or "no"
#
# These variables can be used in your configure.ac to determine the level
# of support you need from the Curses library. For example, if you must
# have either Ncurses or NcursesW, you could include:
#
# AX_WITH_CURSES
# if test "x$ax_cv_ncursesw" != xyes && test "x$ax_cv_ncurses" != xyes; then
# AX_MSG_ERROR([requires either NcursesW or Ncurses library])
# fi
#
# If any Curses library will do (but one must be present and must support
# color), you could use:
#
# AX_WITH_CURSES
# if test "x$ax_cv_curses" != xyes || test "x$ax_cv_curses_color" != xyes; then
# AC_MSG_ERROR([requires an X/Open-compatible Curses library with color])
# fi
#
# Certain preprocessor symbols and shell variables defined by this macro
# can be used to determine various features of the Curses library. In
# particular, HAVE_CURSES and ax_cv_curses are defined if the Curses
# library found conforms to the traditional SysV and/or X/Open Base Curses
# definition. Any working Curses library conforms to this level.
#
# HAHAVE_CURSES_ENHANCED and ax_cv_curses_enhanced are defined if the library provides X/Open Enhanced Curses features.ticular,
# the wide-character types attr_t, cchar_t and wint_t, the functions
# wattr_set() and wget_wch() and the macros WA_NORMAL and _XOPEN_CURSES
# are checked. The Ncurses library does NOT conform to this definition,
# although NcursesW does.
#
# HAVE_CURSES_COLOR and ax_cv_curses_color are defined if the library
# supports color functions and macros such as COLOR_PAIR, A_COLOR,
# COLOR_WHITE, COLOR_RED and init_pair(). These are NOT part of the
# X/Open Base Curses definition, but are part of the Enhanced set of
# functions. The Ncurses library DOES support these functions, as does
# NcursesW.
#
# HAVE_CURSES_OBSOLETE and ax_cv_curses_obsolete are defined if the
# library supports certain features present in SysV and BSD Curses but not
# defined in the X/Open definition. In particular, the functions
# getattrs(), getcurx() and getmaxx() are checked.
#
# To use the HAVE_xxx_H preprocessor symbols, insert the following into
# your system.h (or equivalent) header file:
#
# #if defined HAVE_NCURSESW_CURSES_H
# # include <ncursesw/curses.h>
# #elif defined HAVE_NCURSESW_H
# # include <ncursesw
| null | 2
|
{
"advantage_score_max": 2.4519858360290527,
"advantage_score_mean": 1.524377703666687,
"advantage_score_min": 1.1775805950164795,
"advantage_score_std": 0.4024479389190674,
"advantage_scores": [
2.4519858360290527,
1.814141035079956,
1.5449618101119995,
1.41098952293396,
1.364230990409851,
1.2417397499084473,
1.1893924474716187,
1.1775805950164795
],
"baseline_doc_loss": 1.0084468126296997,
"baseline_truncated": false,
"doc_advantage_score": 1.0728002786636353,
"length_change_ratio": 0.904,
"net_length_change_chars": -24,
"original_sentences_length_chars": 250,
"replacement_paraphrases_length_chars": 226,
"sentences_perturbed": 2,
"target_doc_loss": 0.940013587474823,
"target_truncated": false,
"threshold_passing_sentences": 8,
"total_doc_length_chars": 6479,
"total_sentences": 27,
"truncated": false
}
|
var path = require('path');
var fs = require('fs');
// Make sure any symlinks in the project folder are resolved:
// https://github.com/facebookincubator/create-react-app/issues/637
var appDirectory = fs.realpathSync(process.cwd());
function resolveApp(relativePath) {
return path.resolve(appDirectory, relativePath);
}
// We support resolving modules according to `NODE_PATH`.
This allows you to import modules using absolute paths in large monorepos, simplifying imports and avoiding complex relative paths.
// It works similar to `NODE_PATH` in Node itself:
// https://nodejs.org/api/modules.html#modules_loading_from_the_global_folders
// We will export `nodePaths` as an array of absolute paths.
// It will then be used by Webpack configs.
// Jest doesn’t need this because it already handles `NODE_PATH` out of the box.
// Note that unlike in Node, only *relative* paths from `NODE_PATH` are honored.
// Otherwise, we risk importing Node.js core modules into an app instead of Webpack shims.
// https// See: https://github.com/facebook/create-react-app/issues/1023#issuecomment-265344421 for more details on this behavior?:')
.filter(Boolean)
.filter(folder => !path.isAbsolute(folder))
.map(resolveApp);
// config after eject: we're in ./config/
module.exports = {
// Changed from build to build_webpack so smart contract compilations are not overwritten.
appBuild: resolveApp('build_webpack'),
appPublic: resolveApp('public'),
appHtml: resolveApp('public/index.html'),
appIndexJs: resolveApp('src/index.js'),
appPackageJson: resolveApp('package.json'),
appSrc: resolveApp('src'),
yarnLockFile: resolveApp('yarn.lock'),
testsSetup: resolveApp('src/setupTests.js'),
appNodeModules: resolveApp('node_modules'),
ownNodeModules: resolveApp('node_modules'),
nodePaths: nodePaths
};
| null | 2
|
{
"advantage_score_max": 7.923591613769531,
"advantage_score_mean": 5.005159378051758,
"advantage_score_min": 3.192272186279297,
"advantage_score_std": 1.776742935180664,
"advantage_scores": [
7.923591613769531,
4.778222560882568,
4.12654972076416,
3.192272186279297
],
"baseline_doc_loss": 0.738298237323761,
"baseline_truncated": false,
"doc_advantage_score": 1.7203859090805054,
"length_change_ratio": 0.7981072555205048,
"net_length_change_chars": -64,
"original_sentences_length_chars": 317,
"replacement_paraphrases_length_chars": 253,
"sentences_perturbed": 2,
"target_doc_loss": 0.4291468858718872,
"target_truncated": false,
"threshold_passing_sentences": 4,
"total_doc_length_chars": 1886,
"total_sentences": 10,
"truncated": false
}
|
#ifndef GIM_ARRAY_H_INCLUDED
#define GIM_ARRAY_H_INCLUDED
/*! \file gim_array.h
\author Francisco Leon Najera
*/
/*
-----------------------------------------------------------------------------
This source file is part of GIMPACT Library.
For the latest info, see http://gimpact.sourceforge.net/
Copyright (c) 2006 Francisco Leon Najera. C.C. 80087371.
email: projectileman@yahoo.com
This library is free software; you can redistribute it and/or
modify it under the terms of EITHER:
(1) The GNU Lesser General Public License as published by the Free
Software Foundation; either version 2.1 of the License, or (at
your option) any later version. The text of the GNU Lesser
General Public License is included with this library in the
file GIMPACT-LICENSE-LGPL.TXT.
(2) The BSD-style license that is included with this library in
the file GIMPACT-LICENSE-BSD.TXT.
(3) The zlib/libpng license that is included with this library in
the file GIMPACT-LICENSE-ZLIB.TXT.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the files
GIMPACT-LICENSE-LGPL.TXT, GIMPACT-LICENSE-ZLIB.TXT and GIMPACT-LICENSE-BSD.TXT for more details.
-----------------------------------------------------------------------------
See the accompanying license files for details regarding usage and distribution! Very simple array container with fast access and simd memory
template<typename T>
class gim_array
{
public:
//! properties
//!@{
T *m_data;
GUINT m_size;
GUINT m_allocated_size;
//!@}
//! protected operations
//!@{
inline void destroyData()
{
m_allocated_size = 0;
if(m_data==NULL) return;
gim_free(m_data);
m_data = NULL;
}
inline bool resizeData(GUINT newsize)
{
if(newsize==0)
{
destroyData();
return true;
}
if(m_size>0)
{
m_data = (T*)gim_realloc(m_data,m_size*sizeof(T),newsize*sizeof(T));
}
else
{
m_data = (T*)gim_alloc(newsize*sizeof(T));
}
m_allocated_size = newsize;
return true;
}
inline bool growingCheck()
{
if(m_allocated_size<=m_size)
{
GUINT requestsize = m_size;
m_size = m_allocated_size;
if(resizeData((requestsize+GIM_ARRAY_GROW_INCREMENT)*GIM_ARRAY_GROW_FACTOR)==false) return false;
}
return true;
}
//!@}
//! public operations
//!@{
inline bool reserve(GUINT size)
{
if(m_allocated_size>=size) return false;
return resizeData(size);
}
inline void clear_range(GUINT start_range)
{
while(m_size>start_range)
{
m_data[--m_size].~T();
}
}
inline void clear()
{
if(m_size==0)return;
clear_range(0);
}
inline void clear_memory()
{
clear();
destroyData();
}
gim_array()
{
m_data = 0;
m_size = 0;
m_allocated_size = 0;
}
gim_array(GUINT reservesize)
{
m_data = 0;
m_size = 0;
m_allocated_size = 0;
reserve(reservesize);
}
~gim_array()
{
clear_memory();
}
inline GUINT size() const
{
return m_size;
}
inline GUINT max_size() const
{
return m_allocated_size;
}
inline T & operator[](size_t i)
{
return m_data[i];
}
inline const T & operator[](size_t i) const
{
return m_data[i];
}
inline T * pointer(){ return m_data;}
inline const T * pointer() const
{ return m_data;}
inline T * get_pointer_at(GUINT i)
{
return m_data + i;
}
inline const T * get_pointer_at(GUINT i) const
{
return m_data + i;
}
inline T & at(GUINT i)
{
return m_data[i];
}
inline const T & at(GUINT i) const
{
return m_data[i];
}
inline T & front()
{
return *m_data;
}
inline const T & front() const
{
return *m_data;
}
inline T & back()
{
return m_data[m_size-1];
}
inline const T & back() const
{
return m_data[m_size-1];
}
inline void swap(GUINT i, GUINT j)
{
gim_swap_elements(m_data,i,j);
}
inline void push_back(const T & obj)
{
this->growingCheck();
m_data[m_size] = obj;
m_size++;
}
//!Simply increase the m_size, doesn't call the new element constructor
inline void push_back_mem()
{
this->growingCheck();
m_size++;
}
inline void push_back_memcpy(const T & obj)
{
this->growingCheck();
irr_simd_memcpy(&m_data[m_size],&obj,sizeof(T));
m_size++;
}
inline void pop_back()
{
m_size--;
m_data[m_size].~T();
}
//!Simply decrease the m_size, doesn't call the deleted element destructor
inline void pop_back_mem()
{
m_size--;
}
//! fast erase
inline void erase(GUINT index)
{
if(index<m_size-1)
{
swap(index,m_size-1);
}
pop_back();
}
inline void erase_sorted_mem(GUINT index)
{
m_size--;
for(GUINT i = index;i<m_size;i++)
{
gim_simd_memcpy(m_data+i,m_data+i+1,sizeof(T));
}
}
inline void erase_sorted(GUINT index)
{
m_data[index].~T();
erase_sorted_mem(index);
}
inline void insert_mem(GUINT index)
{
this->growingCheck();
for(GUINT i = m_size;i>index;i--)
{
gim_simd_memcpy(m_data+i,m_data+i-1,sizeof(T));
}
m_size++;
}
inline void insert(const T & obj,GUINT index)
{
insert_mem(index);
m_data[index] = obj;
}
inline void resize(GUINT size, bool call_constructor = true, const T& fillData=T())
{
if(size>m_size)
{
reserve(size);
if(call_constructor)
{
while(m_size<size)
{
m_data[
| null | 1
|
{
"advantage_score_max": 1.5256400108337402,
"advantage_score_mean": 1.379350185394287,
"advantage_score_min": 1.233060359954834,
"advantage_score_std": 0.14628982543945312,
"advantage_scores": [
1.5256400108337402,
1.233060359954834
],
"baseline_doc_loss": 0.8292808532714844,
"baseline_truncated": false,
"doc_advantage_score": 2.0167086124420166,
"length_change_ratio": 0.88268156424581,
"net_length_change_chars": -21,
"original_sentences_length_chars": 179,
"replacement_paraphrases_length_chars": 158,
"sentences_perturbed": 1,
"target_doc_loss": 0.41120508313179016,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 5761,
"total_sentences": 21,
"truncated": false
}
|
/**
******************************************************************************
* @file Project/STM32F4xx_StdPeriph_Templates/stm32f4xx_it.c
* @author MCD Application Team
* @version V1.3.0
* @date 13-November-2013
* @brief Main Interrupt Service Routines.
This file provides a template for all exception handlers and peripheral interrupt service routines.
******************************************************************************
* @attention
*
* <h2><center>© COPYRIGHT 2013 STMicroelectronics</center></h2>
*
* Licensed under MCD-ST Liberty SW License Agreement V2, (the "License");
* You may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.st.com/software_license_agreement_liberty_v2
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
******************************************************************************
*/
/* Includes ------------------------------------------------------------------*/
#include "stm32f4xx_it.h"
#include "main.h"
/** @addtogroup Template_Project
* @{
*/
/* Private typedef -----------------------------------------------------------*/
/* Private define ------------------------------------------------------------*/
/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
/* Private function prototypes -----------------------------------------------*/
/* Private functions ---------------------------------------------------------*/
/******************************************************************************/
/* Cortex-M4 Processor Exceptions Handlers */
/******************************************************************************/
/**
* @brief This function handles NMI exception.
* @param None
* @retval None
*/
void NMI_Handler(void)
{
}
/**
* @brief This function handles Hard Fault exception.
* @param None
* @retval None
*/
void HardFault_Handler(void)
{
/* Go to infinite loop when Hard Fault exception occurs */
while (1)
{
}
}
/**
* @brief This function handles Memory Manage exception.
* @param None
* @retval None
*/
void MemManage_Handler(void)
{
/* Go to infinite loop when Memory Manage exception occurs */
while (1)
{
}
}
/**
* @brief This function handles Bus Fault exception.
* @param None
* @retval None
*/
void BusFault_Handler(void)
{
/* Go to infinite loop when Bus Fault exception occurs */
while (1)
{
}
}
/**
* @brief This function handles Usage Fault exception.
* @param None
* @retval None
*/
void UsageFault_Handler(void)
{
/* Go to infinite loop when Usage Fault exception occurs */
while (1)
{
}
}
/**
* @brief This function handles SVCall exception.
* @param None
* @retval None
*/
void SVC_Handler(void)
{
}
/**
* @brief This function handles Debug Monitor exception.
* @param None
* @ret* @brief This function handles Debug Monitor interrupt.
* @param None
* @retval None.retval None
*/
void PendSV_Handler(void)
{
}
/**
* @brief This function decrement timing variable
* @with __weak parameter to prevent errors
* @param None
* @retval None
*/
__weak void TimingDelay_Decrement(void) {
}
/**
* @brief This function handles SysTick Handler.
* @param None
* @retval None
*/
void SysTick_Handler(void)
{
TimingDelay_Decrement();
}
/******************************************************************************/
/* STM32F4xx Peripherals Interrupt Handlers */
/* Add here the Interrupt Handler for the used peripheral(s) (PPP), for the */
/* available peripheral interrupt handler's name please refer to the startup */
/* file (startup_stm32f4xx.s). */
/******************************************************************************/
/**
* @brief This function handles PPP interrupt request.
* @param None
* @retval None
*/
/*void PPP_IRQHandler(void)
{
}*/
/**
* @}
*/
/************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
| null | 2
|
{
"advantage_score_max": 8.549264907836914,
"advantage_score_mean": 5.696865081787109,
"advantage_score_min": 1.3685855865478516,
"advantage_score_std": 3.111720085144043,
"advantage_scores": [
8.549264907836914,
7.172744274139404,
1.3685855865478516
],
"baseline_doc_loss": 0.3803562521934509,
"baseline_truncated": false,
"doc_advantage_score": 4.147830009460449,
"length_change_ratio": 0.7661290322580645,
"net_length_change_chars": -58,
"original_sentences_length_chars": 248,
"replacement_paraphrases_length_chars": 190,
"sentences_perturbed": 2,
"target_doc_loss": 0.09170006215572357,
"target_truncated": false,
"threshold_passing_sentences": 3,
"total_doc_length_chars": 4596,
"total_sentences": 17,
"truncated": false
}
|
/***************************************************************************
Copyright 2015 Ufora Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
****************************************************************************/
#ifndef JudgmentParser_hppml_
#define JudgmentParser_hppml_
#include "../../core/SimpleParse/SimpleParse.hppml"
#include <string>
class JudgmentOnResult;
class JudgmentOnValue;
class JudgmentOnValueTuple;
class JudgmentOnType;
class JudgmentOnTypeTuple;
class Symbol;
@type JudgmentParseError = std::string error, SimpleParseRange range {
public:
JudgmentParseError( std::string inError,
const SimpleParseNode& node)
{
error() = inError + ": " + node.toString();
range() = node.extent();
}
JudgmentParseError( std::string inError,
const ImmutableTreeVector<SimpleParseNode>& nodes)
{
lassert(nodes.size());
error() = inError;
range() = SimpleParseRange(nodes[0].extent().start(),
nodes.back().extent().stop());
}
JudgmentParseError( std::string inError,
const SimpleParseNode& nodeStart,
const SimpleParseNode& nodeEnd
)
{
error() = inError;
range() = SimpleParseRange( nodeStart.extent().start(),
nodeEnd.extent().stop());
}
JudgmentParseError( std::string inError,
const SimpleParsePosition& extent
)
{
error() = inError;
range() = SimpleParseRange(extent,extent);
}
};
class JudgmentParser {
public:
//parse a SimpleParseNode to a given type or throw a JudgmentParseError
static JudgmentOnValue parseJOV(const SimpleParseNode& inNode);
static JudgmentOnValue parseJOVFromConcat(
const ImmutableTreeVector<SimpleParseNode>& inNode
);
static JudgmentOnResult parseJOR(const SimpleParseNode& node);
static JudgmentOnValueTuple parseJOVT(const SimpleParseNode& inNode);
//parse a term in a JOVT. may be named. if it has ..., then it's the
//"extras" field
static pair<JudgmentOnValue, Nullable<Symbol> > parseJOVTTerm(
const SimpleParseNode& inNode,
bool& outIsExtras
);
};
#endif
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 1.1715940237045288,
"baseline_truncated": false,
"doc_advantage_score": 1.1365954875946045,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 1.030792474746704,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 2594,
"total_sentences": 7,
"truncated": false
}
|
# CS_ARCH_ARM, CS_MODE_ARM, None
0x0f,0x10,0xa2,0xe2 = adc r1, r2, #15
0xf0,0x10,0xa2,0xe2 = adc r1, r2, #240
0x0f,0x1c,0xa2,0xe2 = adc r1, r2, #3840
0x0f,0x1a,0xa2,0xe2 = adc r1, r2, #61440
0x0f,0x18,0xa2,0xe2 = adc r1, r2, #983040
0x0f,0x16,0xa2,0xe2 = adc r1, r2, #15728640
0x0f,0x14,0xa2,0xe2 = adc r1, r2, #251658240
0x0f,0x12,0xa2,0xe2 = adc r1, r2, #4026531840
0xff,0x12,0xa2,0xe2 = adc r1, r2, #4026531855
0x0f,0x1c,0xb2,0xe2 = adcs r1, r2, #3840
0x0f,0x1c,0xb2,0x02 = adcseq r1, r2, #3840
0x0f,0x1c,0xa2,0x02 = adceq r1, r2, #3840
0x06,0x40,0xa5,0xe0 = adc r4, r5, r6
0x86,0x40,0xa5,0xe0 = adc r4, r5, r6, lsl #1
0x86,0x4f,0xa5,0xe0 = adc r4, r5, r6, lsl #31
0xa6,0x40,0xa5,0xe0 = adc r4, r5, r6, lsr #1
0xa6,0x4f,0xa5,0xe0 = adc r4, r5, r6, lsr #31
0x26,0x40,0xa5,0xe0 = adc r4, r5, r6, lsr #32
0xc6,0x40,0xa5,0xe0 = adc r4, r5, r6, asr #1
0xc6,0x4f,0xa5,0xe0 = adc r4, r5, r6, asr #31
0x46,0x40,0xa5,0xe0 = adc r4, r5, r6, asr #32
0xe6,0x40,0xa5,0xe0 = adc r4, r5, r6, ror #1
0xe6,0x4f,0xa5,0xe0 = adc r4, r5, r6, ror #31
0x18,0x69,0xa7,0xe0 = adc r6, r7, r8, lsl r9
0x38,0x69,0xa7,0xe0 = adc r6, r7, r8, lsr r9
0x58,0x69,0xa7,0xe0 = adc r6, r7, r8, asr r9
0x78,0x69,0xa7,0xe0 = adc r6, r7, r8, ror r9
0x66,0x40,0xa5,0xe0 = adc r4, r5, r6, rrx
0x06,0x50,0xa5,0xe0 = adc r5, r5, r6
0x85,0x40,0xa4,0xe0 = adc r4, r4, r5, lsl #1
0x85,0x4f,0xa4,0xe0 = adc r4, r4, r5, lsl #31
0xa5,0x40,0xa4,0xe0 = adc r4, r4, r5, lsr #1
0xa5,0x4f,0xa4,0xe0 = adc r4, r4, r5, lsr #31
0x25,0x40,0xa4,0xe0 = adc r4, r4, r5, lsr #32
0xc5,0x40,0xa4,0xe0 = adc r4, r4, r5, asr #1
0xc5,0x4f,0xa4,0xe0 = adc r4, r4, r5, asr #31
0x45,0x40,0xa4,0xe0 = adc r4, r4, r5, asr #32
0xe5,0x40,0xa4,0xe0 = adc r4, r4, r5, ror #1
0xe5,0x4f,0xa4,0xe0 = adc r4, r4, r5, ror #31
0x65,0x40,0xa4,0xe0 = adc r4, r4, r5, rrx
0x17,0x69,0xa6,0xe0 = adc r6, r6, r7, lsl r9
0x37,0x69,0xa6,0xe0 = adc r6, r6, r7, lsr r9
0x57,0x69,0xa6,0xe0 = adc r6, r6, r7, asr r9
0x77,0x69,0xa6,0xe0 = adc r6, r6, r7, ror r9
0x65,0x40,0xa4,0xe0 = adc r4, r4, r5, rrx
0x0f,0x4a,0x85,0xe2 = add r4, r5, #61440
0x06,0x40,0x85,0xe0 = add r4, r5, r6
0x86,0x42,0x85,0xe0 = add r4, r5, r6, lsl #5
0xa6,0x42,0x85,0xe0 = add r4, r5, r6, lsr #5
0xa6,0x42,0x85,0xe0 = add r4, r5, r6, lsr #5
0xc6,0x42,0x85,0xe0 = add r4, r5, r6, asr #5
0xe6,0x42,0x85,0xe0 = add r4, r5, r6, ror #5
0x18,0x69,0x87,0xe0 = add r6, r7, r8, lsl r9
0x13,0x49,0x84,0xe0 = add r4, r4, r3, lsl r9
0x38,0x69,0x87,0xe0 = add r6, r7, r8, lsr r9
0x58,0x69,0x87,0xe0 = add r6, r7, r8, asr r9
0x78,0x69,0x87,0xe0 = add r6, r7, r8, ror r9
0x66,0x40,0x85,0xe0 = add r4, r5, r6, rrx
0x0f,0x5a,0x85,0xe2 = add r5, r5, #61440
0x05,0x40,0x84,0xe0 = add r4, r4, r5
0x85,0x42,0x84,0xe0 = add r4, r4, r5, lsl #5
0xa5,0x42,0x84,0xe0 = add r4, r4, r5, lsr #5
0xa5,0x42,0x84,0xe0 = add r4, r4, r5, lsr #5
0xc5,0x42,0x84,0xe0 = add r4, r4, r5, asr #5
0xe5,0x42,0x84,0xe0 = add r4, r4, r5, ror #5
0x17,0x69,0x86,0xe0 = add r6, r6
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $NoKeywords: $
//
//=============================================================================//
#ifndef IREPLAYSERVER_H
#define IREPLAYSERVER_H
#ifdef _WIN32
#pragma once
#endif
//-----------------------------------------------------------------------------
#include "interface.h"
//-----------------------------------------------------------------------------
class IServer;
class IReplayDirector;
class IGameEvent;
struct netadr_s;
class CServerReplay;
//-----------------------------------------------------------------------------
// Interface the Replay module exposes to the engine
//-----------------------------------------------------------------------------
#define INTERFACEVERSION_REPLAYSERVER "ReplayServer001"
class IReplayServer : public IBaseInterface
{
public:
virtual ~IReplayServer() {}
virtual IServer *GetBaseServer() = 0; // get Replay base server interface
virtual IReplayDirector *GetDirector() = 0; // get director interface
virtual int GetReplaySlot() = 0; // return entity index-1 of Replay in game
virtual float GetOnlineTime() = 0; // seconds since broadcast started
virtual void BroadcastEvent(IGameEvent *event) = 0; // send a director command to all specs
virtual bool IsRecording() = 0;
virtual void StartRecording() = 0;
virtual void StopRecording() = 0;
};
#endif
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
# /* **************************************************************************
# * *
# * (C) Copyright Paul Mensonides 2002.
# * Licensed under the Boost Software License, Version 1.0. (See
# * accompanying file LICENSE_1_0.txt or copy at
# * http://www.boost.org/LICENSE_1_0.txt)
# * *
# ************************************************************************** */
#
# /* See http://www.boost.org for most recent version. */
#
# include <boost/preprocessor/slot/detail/shared.hpp>
#
# undef BOOST_PP_ITERATION_FINISH_4
#
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_1
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_2
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_3
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_4
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_5
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_6
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_7
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_8
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_9
# undef BOOST_PP_ITERATION_FINISH_4_DIGIT_10
#
# if BOOST_PP_SLOT_TEMP_3 == 0
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 0
# elif BOOST_PP_SLOT_TEMP_3 == 1
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 1
# elif BOOST_PP_SLOT_TEMP_3 == 2
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 2
# elif BOOST_PP_SLOT_TEMP_3 == 3
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 3
# elif BOOST_PP_SLOT_TEMP_3 == 4
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 4
# elif BOOST_PP_SLOT_TEMP_3 == 5
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 5
# elif BOOST_PP_SLOT_TEMP_3 == 6
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 6
# elif BOOST_PP_SLOT_TEMP_3 == 7
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 7
# elif BOOST_PP_SLOT_TEMP_3 == 8
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 8
# elif BOOST_PP_SLOT_TEMP_3 == 9
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_3 9
# endif
#
# if BOOST_PP_SLOT_TEMP_2 == 0
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 0
# elif BOOST_PP_SLOT_TEMP_2 == 1
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 1
# elif BOOST_PP_SLOT_TEMP_2 == 2
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 2
# elif BOOST_PP_SLOT_TEMP_2 == 3
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 3
# elif BOOST_PP_SLOT_TEMP_2 == 4
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 4
# elif BOOST_PP_SLOT_TEMP_2 == 5
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 5
# elif BOOST_PP_SLOT_TEMP_2 == 6
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 6
# elif BOOST_PP_SLOT_TEMP_2 == 7
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 7
# elif BOOST_PP_SLOT_TEMP_2 == 8
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 8
# elif BOOST_PP_SLOT_TEMP_2 == 9
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_2 9
# endif
#
# if BOOST_PP_SLOT_TEMP_1 == 0
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 0
# elif BOOST_PP_SLOT_TEMP_1 == 1
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 1
# elif BOOST_PP_SLOT_TEMP_1 == 2
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 2
# elif BOOST_PP_SLOT_TEMP_1 == 3
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 3
# elif BOOST_PP_SLOT_TEMP_1 == 4
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 4
# elif BOOST_PP_SLOT_TEMP_1 == 5
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 5
# elif BOOST_PP_SLOT_TEMP_1 == 6
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 6
# elif BOOST_PP_SLOT_TEMP_1 == 7
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 7
# elif BOOST_PP_SLOT_TEMP_1 == 8
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 8
# elif BOOST_PP_SLOT_TEMP_1 == 9
# define BOOST_PP_ITERATION_FINISH_4_DIGIT_1 9
# endif
#
# if BOOST_PP_ITERATION_FINISH_4_DIGIT_3
# define BOOST_PP_ITERATION_FINISH_4 BOOST_PP_SLOT_CC_3(BOOST_PP_ITERATION_FINISH_4_DIGIT_3, BOOST_PP_ITERATION_FINISH_4_DIGIT_2, BOOST_PP_ITERATION_FINISH_4_DIGIT_1)
# elif BOOST_PP_ITERATION_FINISH_4_DIGIT_2
# define BOOST_PP_ITERATION_FINISH_4 BOOST_PP_SLOT_CC_2(BOOST_PP_ITERATION_FINISH_4_DIGIT_2, BOOST_PP_ITERATION_FINISH_4_DIGIT_1)
# else
# define BOOST_PP_ITERATION_FINISH_4 BOOST_PP_ITERATION_FINISH_4_DIGIT_1
# endif
| null | 1
|
{
"advantage_score_max": 4.546376705169678,
"advantage_score_mean": 4.546376705169678,
"advantage_score_min": 4.546376705169678,
"advantage_score_std": 0,
"advantage_scores": [
4.546376705169678
],
"baseline_doc_loss": 0.23213323950767517,
"baseline_truncated": false,
"doc_advantage_score": 17.09291648864746,
"length_change_ratio": 0.9552238805970149,
"net_length_change_chars": -3,
"original_sentences_length_chars": 67,
"replacement_paraphrases_length_chars": 64,
"sentences_perturbed": 1,
"target_doc_loss": 0.013580669648945332,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 4131,
"total_sentences": 4,
"truncated": false
}
|
// flow-typed signature: 5ae61140984b5030b763a0f1d10ce2bf
// flow-typed version: <<STUB>>/@types/react-router-dom_v^4.2.3/flow_v0.64.0
/**
* This is an autogenerated libdef stub for:
*
* '@types/react-router-dom'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module '@types/react-router-dom' {
declare module.exports: any;
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
$(function () {
$('[data-toggle="popover"]').popover({trigger: 'manual'});
});
Pressure.set('.device-circle', {
change: function(force){
console.log(force);
this.style.width = Pressure.map(force, 0, 1, 10, $(this).data('size')) + 'em';
this.style.height = Pressure.map(force, 0, 1, 10, $(this).data('size')) + 'em';
this.style.marginTop = '-' + Pressure.map(force, 0, 1, 10, $(this).data('size'))/2 + 'em';
this.style.marginLeft = '-' + Pressure.map(force, 0, 1, 10, $(this).data('size'))/2 + 'em';
},
startDeepPress: function(){
this.style.backgroundColor = '#5bc0de';
},
endDeepPress: function(){
this.style.backgroundColor = '#d9534f';
},
end: function(){
this.style.width = '10em';
this.style.height = '10em';
this.style.marginTop = '-5em';
this.style.marginLeft = '-5em';
}
}, {polyfillSpeedDown: 250});
Pressure.set('.device-circle', {
change: function(){
$('.pressure-failed').hide();
},
unsupported: function(){
$('.pressure-failed').show();
}
}, {polyfill: false});
var block = {
change: function(force, event){
this.style.width = ((200 * force) + 200) + 'px';
this.innerHTML = force;
this.style.backgroundColor = "rgb(" + parseInt(Pressure.map(force, 0, 1, 255, 0)) + ",100," + parseInt(Pressure.map(force, 0, 1, 0, 255)) +")";
this.style.color = force > 0.3 ? 'white' : 'black';
},
end: function(){
this.style.width = '200px';
this.innerHTML = 0;
this.style.backgroundColor = 'rgb(255,100,0)';
this.style.color = 'black';
},
unsupported: function(){
this.innerHTML = 'Sorry! Check the devices and browsers that Pressure works on above ^^^^';
}
}
Pressure.set('#el1', block);
Pressure.set('#el2', block, {only: 'mouse'});
Pressure.set('#el3', block, {only: 'touch'});
Pressure.set('#el4', block, {only: 'pointer'});
Pressure.set('#pressure-test', {
start: function(){
this.innerHTML = 'Pressure is Supported!Pressure works with your device or browser above!';
}
});
Pressure.set('#peanuts', {
change: function(force, event){
this.style.webkitFilter = 'blur(' + Pressure.map(force, 0, 0.7, 20, 0) + 'px)';
},
end: function(){
this.style.webkitFilter = 'blur(20px)';
},
unsupported: function(){
this.innerHTML = 'Your device / browser does not support this :(';
}
});
var saveForce = 0;
Pressure.set('#text-sizer', {
change: function(force){
if(force > saveForce){
this.style.fontSize = Pressure.map(force, 0, 1, 16, 30);
saveForce = force;
}
},
end: function(){
saveForce = 0;
}
});
Pressure.set('#cube-btn', {
change: function(force){
document.getElementById('spinning-cube').style.webkitTransform = 'rotateZ(' + Pressure.map(force, 0, 1, 0, 360) + 'deg)';
},
end: function(){
document.getElementById('spinning-cube').style.webkitTransform = 'rotateZ(0deg)';
}
});
Pressure.set('#popover', {
startDeepPress: function(force){
$(this).popover('show');
},
endDeepPress: function(){
$(this).popover('hide');
}
});
// docs
Pressure.set('#output-element', {
change: function(force, event){
this.innerHTML = force;
}
}, {polyfill: false});
Pressure.set('#element-touch', {
change: function(force, event){
this.innerHTML = force + 'on an iphone';
}
}, {only: 'touch', polyfill: false});
Pressure.set('#element-mouse', {
change: function(force, event){
this.innerHTML = force + 'on a Mac';
}
}, {only: 'mouse', polyfill: false});
Pressure.set('#element-pointer', {
change: function(force, event){
this.innerHTML = force + 'on a pointer device';
}
}, {only: 'pointer', polyfill: false});
Pressure.set('#element-touch-prevent', {}, {only: 'touch', preventDefault: false});
Pressure.set('#element-mouse-prevent', {}, {only: 'mouse', preventDefault: false});
Pressure.set('#polyfill-example', {
change: function(force, event){
this.innerHTML = force;
},
end: function(){
this.innerHTML = 0;
},
unsupported: function(){
alert("Oh no, this device does not support pressure.")
}
});
Pressure.set('#polyfill-speed-up', {
change: function(force, event){
this.innerHTML = force;
},
end: function(){
this.innerHTML = 0;
}
}, {polyfillSpeedUp: 5000});
Pressure.set('#polyfill-speed-down', {
change: function(force, event){
this.innerHTML = force;
},
end: function(){
this.innerHTML = 0;
}
}, {polyfillSpeedDown: 2000});
// Twitter BTN
window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));
// Google Analytics
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-72492481-1', 'auto');
ga('send', 'pageview');
| null | 1
|
{
"advantage_score_max": 1.6360408067703247,
"advantage_score_mean": 1.4963409900665283,
"advantage_score_min": 1.3566410541534424,
"advantage_score_std": 0.13969987630844116,
"advantage_scores": [
1.6360408067703247,
1.3566410541534424
],
"baseline_doc_loss": 0.7383860349655151,
"baseline_truncated": false,
"doc_advantage_score": 1.112654685974121,
"length_change_ratio": 0.5903614457831325,
"net_length_change_chars": -34,
"original_sentences_length_chars": 83,
"replacement_paraphrases_length_chars": 49,
"sentences_perturbed": 1,
"target_doc_loss": 0.6636255383491516,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 5291,
"total_sentences": 6,
"truncated": false
}
|
module Main where
main
= do x1 <- readFile "test2.sorted"
let x2 = lines x1
x3 = zip [1 ..] x2
x4 = concat (map qq x3)
--putStr x4
writeFile "test2.orig" x4
qq :: (Int, String) -> String
qq (n, s0)
= let ws = words s0
bytes = head ws
rest = unwords (tail ws)
bytes2 = foo bytes
in
unlines [
"",
rest,
". " ++ show n ++ " 0x12345678 " ++ show (1 + (length bytes `div` 2)),
". " ++ bytes2 ++ "C3"
]
foo [] = []
foo (x:y:rest) = x:y:' ':foo rest
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 1.8641737699508667,
"baseline_truncated": false,
"doc_advantage_score": 0.9804665446281433,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 1.9013129472732544,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 609,
"total_sentences": 3,
"truncated": false
}
|
# Disallow Use of caller/callee (no-caller)
The use of `arguments.caller` and `arguments.callee` make several code optimizations impossible. They have been deprecated in future versions of JavaScript and their use is forbidden in ECMAScript 5 while in strict mode.
```js
function foo() {
var callee = arguments.callee;
}
```
## Rule Details
This rule is aimed at discouraging the use of deprecated and sub-optimal code by disallowing the use of `arguments.caller` and `arguments.callee`. As such, it will warn when `arguments.caller` and `arguments.callee` are used.
Examples of **incorrect** code for this rule:
```js
/*eslint no-caller: "error"*/
function foo(n) {
if (n <= 0) {
return;
}
arguments.callee(n - 1);
}
[1,2,3,4,5].map(function(n) {
return !(n > 1) ? 1 : arguments.callee(n - 1) * n;
});
```
Examples of **correct** code for this rule:
```js
/*eslint no-caller: "error"*/
function foo(n) {
if (n <= 0) {
return;
}
foo(n - 1);
}
[1,2,3,4,5].map(function factorial(n) {
return !(n > 1) ? 1 : factorial(n - 1) * n;
});
```
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.810439944267273,
"baseline_truncated": false,
"doc_advantage_score": 0.827383279800415,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.9795218110084534,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 1101,
"total_sentences": 9,
"truncated": false
}
|
from argschema import ArgSchema, ArgSchemaParser
from argschema.schemas import DefaultSchema
from argschema.fields import Nested, InputDir, String, Float, Dict, Int
known_conditions = {
"0": {
"duration": 1.0,
"name": "fast_pulses",
"condition": "2.5 ms pulses at 10 Hz"
},
"1": {
"duration": 0.005,
"name": "pulse",
"condition": "a single square pulse"
},
"2": {
"duration": 0.01,
"name": "pulse",
"condition": "a single square pulse"
},
"3": {
"duration": 1.0,
"name": "raised_cosine",
"condition": "half-period of a cosine wave"
}
}
class Condition(DefaultSchema):
duration = Float(required=True)
name = String(required=True)
condition = String(required=True)
class InputParameters(ArgSchema):
opto_pickle_path = String(required=True, help='path to file containing optotagging information')
sync_h5_path = String(required=True, help='path to h5 file containing syncronization information')
output_opto_table_path = String(required=True, help='the optotagging stimulation table will be written here')
conditions = Dict(String, Nested(Condition), default=known_conditions)
class OutputSchema(DefaultSchema):
input_parameters = Nested(InputParameters, description=('Input parameters the module was run with'), required=True)
class OutputParameters(OutputSchema):
output_opto_table_path = String(required=True, help='path to optotagging stimulation table')
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<!--
Copyright 2020 The OpenTracing Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>io.opentracing.contrib.specialagent.test</groupId>
<artifactId>test</artifactId>
<version>1.7.5-SNAPSHOT</version>
</parent>
<groupId>io.opentracing.contrib.specialagent.test.twilio</groupId>
<artifactId>twilio</artifactId>
<packaging>pom</packaging>
<name>SpecialAgent Tests for Twilio</name>
<modules>
<module>twilio-0.0.1</module>
<module>twilio-7.47.2</module>
</modules>
</project>
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.4413512647151947,
"baseline_truncated": false,
"doc_advantage_score": 1.9551215171813965,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.22574108839035034,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 1281,
"total_sentences": 4,
"truncated": false
}
|
<system>
<name>KOI-0845</name>
<rightascension>19 14 02</rightascension>
<declination>+41 18 06</declination>
<distance>1389.28</distance>
<star>
<magJ errorminus="0.03" errorplus="0.03">14.26</magJ>
<magH errorminus="0.04" errorplus="0.04">13.87</magH>
<magK errorminus="0.05" errorplus="0.05">13.80</magK>
<name>KOI-0845</name>
<temperature errorminus="114.00" errorplus="114.00">5846.00</temperature>
<radius errorminus="0.4000" errorplus="0.4000">0.9800</radius>
<mass errorminus="0.0850" errorplus="0.0850">0.9570</mass>
<age errorminus="3.1000" errorplus="3.1000">5.4000</age>
<planet>
<name>KOI-0845 b</name>
<name>KOI-0845 01</name>
<radius errorminus="0.12758" errorplus="0.12758">0.31896</radius>
<period errorminus="1.1000000e-04" errorplus="1.1000000e-04">16.329860000000</period>
<transittime errorminus="0.0024000" errorplus="0.0024000">2455010.2907000</transittime>
<semimajoraxis>0.1240000</semimajoraxis>
<temperature>725.0</temperature>
<list>Kepler Objects of Interest</list>
<description>This is a Kepler Object of Interest from the Q1-Q12 dataset. It has been flagged as a possible transit event but has not been confirmed to be a planet yet.</description>
<istransiting>1</istransiting>
</planet>
</star>
</system>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
{
"parent": "botania:block/chiseled_livingrock_bricks"
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
2
4
5
8
10
12
15
18
20
24
28
28
35
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
-480.507214 -2683.730823 1268.836186 -306480.177291
-499.578500 1159.506706 2664.941803 -1214196.736115
-0.992413 -0.088895 0.084939 598.230009
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<?vsp
http_header ('Content-Type: application/xrds+xml; charset=UTF-8\r\n');
OPENID..yadis ({?'uname'}, {?'type'});
?>
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 4.560586929321289,
"baseline_truncated": false,
"doc_advantage_score": 1.4031850099563599,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 3.2501678466796875,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 119,
"total_sentences": 3,
"truncated": false
}
|
tensortrade.feed.api.string package
===================================
.. automodule:: tensortrade.feed.api.string
:members:
:undoc-members:
:show-inheritance:
Submodules
----------
.. toctree::
:maxdepth: 6
tensortrade.feed.api.string.operations
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
{
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/e2e",
"baseUrl": "./",
"module": "commonjs",
"target": "es5",
"types": [
"jasmine",
"jasminewd2",
"node"
]
}
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
#if ENGLISH
#if REVISION >= 1
static const u8 sFont3Widths[] = {
3, 6, 6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 4, 8,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 8,
8, 8, 8, 8, 8, 8, 3, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
7, 6, 4, 8, 8, 8, 7, 8, 8, 4, 6, 6, 4, 4, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 6, 7, 8, 7, 7, 8, 8, 4,
7, 8, 8, 8, 8, 8, 7, 8, 7, 7, 7, 7, 7, 7, 8, 7,
7, 7, 7, 7, 5, 6, 6, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 3, 6, 3, 5, 3,
6, 6, 6, 3, 3, 6, 6, 6, 3, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 4, 5, 6,
3, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7,
3, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 1, 1,
};
#else
static const u8 sFont3Widths[] = {
3, 6, 6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 4, 8,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
7, 6, 4, 8, 8, 8, 7, 8, 8, 4, 6, 6, 4, 4, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 6, 7, 8, 7, 7, 8, 8, 4,
7, 8, 8, 8, 8, 8, 7, 8, 7, 7, 7, 7, 7, 7, 8, 7,
7, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
7, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 3, 6, 3, 5, 3,
6, 6, 6, 3, 3, 6, 6, 6, 3, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 4, 5, 6,
3, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7,
3, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 1, 1,
};
#endif
#elif GERMAN
static const u8 sFont3Widths[] = {
3, 6, 6, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6,
8, 6, 6, 6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 4, 8,
6, 6, 6, 6, 6, 8, 6, 6, 6, 6, 6, 6, 8, 6, 6, 8,
8, 8, 8, 8, 8, 8, 3, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
7, 6, 4, 8, 8, 8, 7, 8, 8, 4, 6, 6, 4, 4, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 6, 7, 8, 7, 7, 8, 8, 4,
7, 8, 8, 8, 8, 8, 7, 8, 7, 7, 7, 7, 7, 7, 8, 7,
7, 7, 7, 7, 5, 6, 6, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 3, 6, 3, 5, 3,
6, 6, 6, 3, 3, 6, 6, 6, 3, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 4, 5, 6,
3, 6, 6, 6, 6, 6, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7,
3, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 1, 1,
};
#endif
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/**
* Author: Íõ¿¡³¬
* Date: 2015-06-23
* Time: 07:17
* Declaration: All Rights Reserved !!!
*/
public class ListNode {
int val;
ListNode next;
ListNode(int x) {
val = x;
}
}
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*************************************************************
*
* MathJax/jax/output/HTML-CSS/fonts/STIX-Web/SansSerif/BoldItalic/Main.js
*
* Copyright (c) 2013-2015 The MathJax Consortium
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
MathJax.OutputJax['HTML-CSS'].FONTDATA.FONTS['STIXMathJax_SansSerif-bold-italic'] = {
directory: 'SansSerif/BoldItalic',
family: 'STIXMathJax_SansSerif',
weight: 'bold',
style: 'italic',
testString: '\u00A0\uE1F6\uE1F7\uE1F8\uE1F9\uE1FA\uE1FB\uE1FC\uE1FD\uE1FE\uE1FF\uD835\uDE3C\uD835\uDE3D\uD835\uDE3E\uD835\uDE3F',
0x20: [0,0,250,0,0],
0xA0: [0,0,250,0,0],
0xE1F6: [688,13,500,89,578],
0xE1F7: [688,0,500,204,505],
0xE1F8: [688,0,500,20,581],
0xE1F9: [688,13,500,32,586],
0xE1FA: [688,0,500,55,583],
0xE1FB: [676,13,500,27,651],
0xE1FC: [688,13,500,80,638],
0xE1FD: [676,0,500,120,639],
0xE1FE: [688,13,500,63,594],
0xE1FF: [688,13,500,28,588],
0x1D63C: [690,0,690,25,665],
0x1D63D: [676,0,636,80,691],
0x1D63E: [691,19,723,119,797],
0x1D63F: [676,0,709,80,772],
0x1D640: [676,0,635,80,728],
0x1D641: [676,0,582,80,725],
0x1D642: [691,19,746,107,785],
0x1D643: [676,0,715,80,803],
0x1D644: [676,0,440,79,534],
0x1D645: [676,96,481,15,574],
0x1D646: [676,0,712,80,816],
0x1D647: [676,0,603,80,612],
0x1D648: [676,0,913,80,1001],
0x1D649: [676,18,724,80,812],
0x1D64A: [692,18,778,106,840],
0x1D64B: [676,0,581,80,695],
0x1D64C: [691,176,779,105,839],
0x1D64D: [676,0,670,80,698],
0x1D64E: [691,19,554,66,637],
0x1D64F: [676,0,641,157,785],
0x1D650: [676,19,699,123,792],
0x1D651: [676,18,690,193,833],
0x1D652: [676,15,997,198,1135],
0x1D653: [676,0,740,40,853],
0x1D654: [676,0,694,188,842],
0x1D655: [676,0,653,25,769],
0x1D656: [473,14,489,48,507],
0x1D657: [676,13,512,51,558],
0x1D658: [473,14,462,71,524],
0x1D659: [676,14,518,69,625],
0x1D65A: [473,13,452,71,492],
0x1D65B: [692,0,340,72,533],
0x1D65C: [473,206,504,2,599],
0x1D65D: [676,0,510,55,542],
0x1D65E: [688,0,245,59,366],
0x1D65F: [688,202,324,-90,440],
0x1D660: [676,0,519,55,599],
0x1D661: [676,0,235,55,348],
0x1D662: [473,0,776,55,809],
0x1D663: [473,0,510,55,542],
0x1D664: [473,14,501,72,542],
0x1D665: [473,205,512,3,559],
0x1D666: [473,205,512,69,574],
0x1D667: [473,0,411,55,519],
0x1D668: [473,13,385,37,442],
0x1D669: [631,12,386,98,447],
0x1D66A: [462,15,518,81,569],
0x1D66B: [462,14,462,129,561],
0x1D66C: [462,14,701,131,798],
0x1D66D: [462,0,506,20,582],
0x1D66E: [462,204,472,-27,569],
0x1D66F: [462,0,441,21,530],
0x1D790: [690,0,690,25,665],
0x1D791: [676,0,706,60,671],
0x1D792: [676,0,602,60,705],
0x1D793: [690,0,720,40,680],
0x1D794: [676,0,683,60,708],
0x1D795: [676,0,707,25,769],
0x1D796: [676,0,748,60,783],
0x1D797: [691,19,847,90,822],
0x1D798: [676,0,435,50,505],
0x1D799: [676,0,712,60,796],
0x1D79A: [690,0,686,20,646],
0x1D79B: [676,0,933,60,981],
0x1D79C: [676,18,744,60,792],
0x1D79D: [676,0,690,47,737],
0x1D79E: [692,18,849,90,824],
0x1D79F: [676,0,745,60,783],
0x1D7A0: [676,0,581,60,675],
0x1D7A1: [691,19,847,90,822],
0x1D7A2: [676,0,696,21,748],
0x1D7A3: [676,0,641,87,715],
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.9735538959503174,
"baseline_truncated": false,
"doc_advantage_score": 4.199413299560547,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.23183093965053558,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 3730,
"total_sentences": 4,
"truncated": false
}
|
/* ScummVM - Graphic Adventure Engine
*
* ScummVM is the legal property of its developers, whose names
* are too numerous to list here. Please refer to the COPYRIGHT
* file distributed with this source distribution.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
*/
#include "common/endian.h"
#include "gob/gob.h"
#include "gob/goblin.h"
#include "gob/global.h"
#include "gob/util.h"
#include "gob/game.h"
#include "gob/map.h"
#include "gob/mult.h"
#include "gob/scenery.h"
#include "gob/inter.h"
namespace Gob {
Goblin_v2::Goblin_v2(GobEngine *vm) : Goblin_v1(vm) {
_gobsCount = -1;
_rotStates[0][0] = 0; _rotStates[0][1] = 18; _rotStates[0][2] = 19; _rotStates[0][3] = 20;
_rotStates[1][0] = 13; _rotStates[1][1] = 2; _rotStates[1][2] = 12; _rotStates[1][3] = 14;
_rotStates[2][0] = 16; _rotStates[2][1] = 15; _rotStates[2][2] = 4; _rotStates[2][3] = 17;
_rotStates[3][0] = 23; _rotStates[3][1] = 21; _rotStates[3][2] = 22; _rotStates[3][3] = 6;
}
void Goblin_v2::freeObjects() {
_vm->_map->_mapUnknownBool = false;
if (_gobsCount < 0)
return;
for (int i = 0; i < _gobsCount; i++) {
delete[] _vm->_mult->_objects[i].goblinStates[0];
delete[] _vm->_mult->_objects[i].goblinStates;
}
for (int i = 0; i < _soundSlotsCount; i++)
if ((_soundSlots[i] & 0x8000) == 0)
_vm->_game->freeSoundSlot(_soundSlots[i]);
_gobsCount = -1;
}
void Goblin_v2::placeObject(Gob_Object *objDesc, char animated,
int16 index, int16 x, int16 y, int16 state) {
Mult::Mult_Object *obj;
Mult::Mult_AnimData *objAnim;
int16 layer;
int16 animation;
obj = &_vm->_mult->_objects[index];
objAnim = obj->pAnimData;
obj->goblinX = x;
obj->goblinY = y;
objAnim->order = y;
if (state == -1) {
objAnim->frame = 0;
objAnim->isPaused = 0;
objAnim->isStatic = 0;
objAnim->newCycle = 0;
_vm->_scenery->updateAnim(objAnim->layer, 0, objAnim->animation, 0,
*obj->pPosX, *obj->pPosY, 0);
if (!_vm->_map->hasBigTiles())
*obj->pPosY = (y + 1) * _vm->_map->getTilesHeight()
- (_vm->_scenery->_animBottom - _vm->_scenery->_animTop);
else
*obj->pPosY = ((y + 1) * _vm->_map->getTilesHeight()) -
(_vm->_scenery->_animBottom - _vm->_scenery->_animTop) - (y + 1) / 2;
*obj->pPosX = x * _vm->_map->getTilesWidth();
} else {
if ((obj->goblinStates != 0) && (obj->goblinStates[state] != 0)) {
layer = obj->goblinStates[state][0].layer;
animation = obj->goblinStates[state][0].animation;
objAnim->state = state;
objAnim->layer = layer;
objAnim->animation = animation;
objAnim->frame = 0;
objAnim->isPaused = 0;
objAnim->isStatic = 0;
objAnim->newCycle = _vm->_scenery->getAnimLayer(animation, layer)->framesCount;
_vm->_scenery->updateAnim(layer, 0, animation, 0, *obj->pPosX, *obj->pPosY, 0);
if (!_vm->_map->hasBigTiles())
*obj->pPosY = (y + 1) * _vm->_map->getTilesHeight()
- (_vm->_scenery->_animBottom - _vm->_scenery->_animTop);
else
*obj->pPosY = ((y + 1) * _vm->_map->getTilesHeight()) -
(_vm->_scenery->_animBottom - _vm->_scenery->_animTop) - (y + 1) / 2;
*obj->pPosX = x * _vm->_map->getTilesWidth();
initiateMove(obj);
} else
initiateMove(obj);
}
}
void Goblin_v2::initiateMove(Mult::Mult_Object *obj) {
obj->destX = obj->gobDestX;
obj->destY = obj->gobDestY;
_vm->_map->findNearestToDest(obj);
_vm->_map->findNearestToGob(obj);
_vm->_map->optimizePoints(obj, obj->goblinX, obj->goblinY);
obj->pAnimData->pathExistence = _vm->_map->checkDirectPath(obj,
obj->goblinX, obj->goblinY, obj->gobDestX, obj->gobDestY);
if (obj->pAnimData->pathExistence == 3) {
const WayPoint &wayPoint = _vm->_map->getWayPoint(obj->nearestWayPoint);
obj->destX = wayPoint.x;
obj->destY = wayPoint.y;
}
}
void Goblin_v2::movePathFind(Mult::Mult_Object *obj, Gob_Object *gobDesc, int16 nextAct) {
Mult::Mult_AnimData *animData = obj->pAnimData;
animData->newCycle = _vm->_scenery->getAnimLayer(animData->animation, animData->layer)->framesCount;
int16 gobX = obj->goblinX;
int16 gobY = obj->goblinY;
int16 destX = obj->destX;
int16 destY = obj->destY;
int16 gobDestX = obj->gobDestX;
int16 gobDestY = obj->gobDestY;
animData->destX = gobDestX;
animData->destY = gobDestY;
animData->order = gobY;
Direction dir = kDirNone;
if (animData->pathExistence == 1) {
dir = _vm->_map->getDirection(gobX, gobY, destX, destY);
if (dir == kDirNone)
animData->pathExistence = 0;
if ((gobX == gobDestX) && (gobY == gobDestY))
animData->pathExistence = 4;
} else if (animData->pathExistence == 3) {
if ((gobX != gobDestX) || (gobY != gobDestY)) {
if (_
| null | 1
|
{
"advantage_score_max": 7.940878391265869,
"advantage_score_mean": 7.940878391265869,
"advantage_score_min": 7.940878391265869,
"advantage_score_std": 0,
"advantage_scores": [
7.940878391265869
],
"baseline_doc_loss": 0.7796655297279358,
"baseline_truncated": false,
"doc_advantage_score": 1.1167877912521362,
"length_change_ratio": 0.9446640316205533,
"net_length_change_chars": -14,
"original_sentences_length_chars": 253,
"replacement_paraphrases_length_chars": 239,
"sentences_perturbed": 1,
"target_doc_loss": 0.6981322169303894,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 5274,
"total_sentences": 7,
"truncated": false
}
|
GLSL optimizer
==============
> :warning: As of mid-2016, the project is unlikely to have any significant developments. At Unity we are moving to a different
shader compilation pipeline, with glsl-optimizer is not used. So from my side there won't be significant work done on it. :warning:
A C++ library that takes GLSL shaders, does some GPU-independent optimizations on them
and outputs GLSL or Metal source back. Optimizations are function inlining, dead code removal, copy propagation,
constant folding, constant propagation, arithmetic optimizations and so on.
Apparently quite a few mobile platforms are pretty bad at optimizing shaders; and
unfortunately they *also* lack offline shader compilers. So using a GLSL optimizer offline
before can make the shader run much faster on a platform like that. See performance numbers
in [this blog post](http://aras-p.info/blog/2010/09/29/glsl-optimizer/).
Even for drivers that have decent shader optimization, GLSL optimizer could be useful to just strip away
dead code, make shaders smaller and do uniform/input reflection offline.
Almost all actual code is [Mesa 3D's GLSL](http://cgit.freedesktop.org/mesa/mesa/log/)
compiler; all this library does is spits out optimized GLSL or Metal back, and adds GLES type precision
handling to the optimizer.
This GLSL optimizer is made for [Unity's](http://unity3d.com/) purposes and is built-in
starting with Unity 3.0.
GLSL Optimizer is licensed according to the terms of the MIT license.
See [change log here](Changelog.md).
Usage
-----
Visual Studio 2010 (Windows, x86/x64) and Xcode 5+ (Mac, i386) project files for a static
library are provided in `projects/vs2010/glsl_optimizer.sln` and `projects/xcode5/glsl_optimizer_lib`
respectively.
> Note: only the VS and Xcode project files are maintained and should work at any time.
> There's also a cmake and gyp build system for Linux et al., and some stuff in contrib folder -
> all that may or might not work.
For Linux you can use cmake. Just type "cmake . && make" in the root directory.
This will build the optimizer library and some executable binaries.
Interface for the library is `src/glsl/glsl_optimizer.h`. General usage is:
ctx = glslopt_initialize(targetVersion);
for (lots of shaders) {
shader = glslopt_optimize (ctx, shaderType, shaderSource, options);
if (glslopt_get_status (shader)) {
newSource = glslopt_get_output (shader);
} else {
errorLog = glslopt_get_log (shader);
}
glslopt_shader_delete (shader);
}
glslopt_cleanup (ctx);
Tests
-----
There's a testing suite for catching regressions, see `tests` folder. In VS, build and run the `glsl_optimizer_tests` solution; in Xcode use the `projects/xcode5/glsl_optimizer_tests` target. The test executable requires path to the `tests` folder as an argument.
Each test comes as three text files; input, expected IR dump and expected optimized
GLSL dump. GLES3 tests are also converted into Metal.
If you're making changes to the project and want pull requests accepted easier, I'd
appreciate if there would be no test suite regressions. If you are implementing a
feature, it would be cool to add tests to cover it as well!
Notes
-----
* GLSL versions 1.10 and 1.20 are supported. 1.10 is the default, use #version 120 to specify
1.20. Higher GLSL versions might work, but aren't tested now.
* GLSL ES versions 1.00 and 3.00 are supported.
Dev Notes
---------
Pulling Mesa upstream:
git fetch upstream
git merge upstream/master
sh removeDeletedByUs.sh
# inspect files, git rm unneeded ones, fix conflicts etc.
# git commit
Rebuilding flex/bison parsers:
* When .y/.l files are changed, the parsers are *not* rebuilt automatically,
* Run ./generateParsers.sh to do that. You'll need bison & flex (on Mac, do "Install Command Line Tools" from Xcode)
* I use bison 2.3 and flex 2.5.35 (in OS X 10.8/10.9)
| null | 1
|
{
"advantage_score_max": 1.9458736181259155,
"advantage_score_mean": 1.549496054649353,
"advantage_score_min": 1.164109468460083,
"advantage_score_std": 0.28453096747398376,
"advantage_scores": [
1.9458736181259155,
1.9180766344070435,
1.89634370803833,
1.7303706407546997,
1.6573010683059692,
1.5093034505844116,
1.4743032455444336,
1.2939931154251099,
1.2740294933319092,
1.1807507276535034,
1.164109468460083
],
"baseline_doc_loss": 2.184753894805908,
"baseline_truncated": false,
"doc_advantage_score": 0.9606661200523376,
"length_change_ratio": 1.0707964601769913,
"net_length_change_chars": 8,
"original_sentences_length_chars": 113,
"replacement_paraphrases_length_chars": 121,
"sentences_perturbed": 1,
"target_doc_loss": 2.274207353591919,
"target_truncated": false,
"threshold_passing_sentences": 11,
"total_doc_length_chars": 3882,
"total_sentences": 35,
"truncated": false
}
|
client
dev tun
proto udp
remote vn-hcm.prod.surfshark.com 1194
resolv-retry infinite
remote-random
nobind
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
persist-key
persist-tun
reneg-sec 0
remote-cert-tls server
auth-user-pass /config/openvpn-credentials.txt
#comp-lzo
verb 3
pull
fast-io
cipher AES-256-CBC
auth SHA512
<ca>
-----BEGIN CERTIFICATE-----
MIIFTTCCAzWgAwIBAgIJAMs9S3fqwv+mMA0GCSqGSIb3DQEBCwUAMD0xCzAJBgNV
BAYTAlZHMRIwEAYDVQQKDAlTdXJmc2hhcmsxGjAYBgNVBAMMEVN1cmZzaGFyayBS
b290IENBMB4XDTE4MDMxNDA4NTkyM1oXDTI4MDMxMTA4NTkyM1owPTELMAkGA1UE
BhMCVkcxEjAQBgNVBAoMCVN1cmZzaGFyazEaMBgGA1UEAwwRU3VyZnNoYXJrIFJv
b3QgQ0EwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDEGMNj0aisM63o
SkmVJyZPaYX7aPsZtzsxo6m6p5Wta3MGASoryRsBuRaH6VVa0fwbI1nw5ubyxkua
Na4v3zHVwuSq6F1p8S811+1YP1av+jqDcMyojH0ujZSHIcb/i5LtaHNXBQ3qN48C
c7sqBnTIIFpmb5HthQ/4pW+a82b1guM5dZHsh7q+LKQDIGmvtMtO1+NEnmj81BAp
FayiaD1ggvwDI4x7o/Y3ksfWSCHnqXGyqzSFLh8QuQrTmWUm84YHGFxoI1/8AKdI
yVoB6BjcaMKtKs/pbctk6vkzmYf0XmGovDKPQF6MwUekchLjB5gSBNnptSQ9kNgn
TLqi0OpSwI6ixX52Ksva6UM8P01ZIhWZ6ua/T/tArgODy5JZMW+pQ1A6L0b7egIe
ghpwKnPRG+5CzgO0J5UE6gv000mqbmC3CbiS8xi2xuNgruAyY2hUOoV9/BuBev8t
tE5ZCsJH3YlG6NtbZ9hPc61GiBSx8NJnX5QHyCnfic/X87eST/amZsZCAOJ5v4EP
SaKrItt+HrEFWZQIq4fJmHJNNbYvWzCE08AL+5/6Z+lxb/Bm3dapx2zdit3x2e+m
iGHekuiE8lQWD0rXD4+T+nDRi3X+kyt8Ex/8qRiUfrisrSHFzVMRungIMGdO9O/z
CINFrb7wahm4PqU2f12Z9TRCOTXciQIDAQABo1AwTjAdBgNVHQ4EFgQUYRpbQwyD
ahLMN3F2ony3+UqOYOgwHwYDVR0jBBgwFoAUYRpbQwyDahLMN3F2ony3+UqOYOgw
DAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAgEAn9zV7F/XVnFNZhHFrt0Z
S1Yqz+qM9CojLmiyblMFh0p7t+Hh+VKVgMwrz0LwDH4UsOosXA28eJPmech6/bjf
ymkoXISy/NUSTFpUChGO9RabGGxJsT4dugOw9MPaIVZffny4qYOc/rXDXDSfF2b+
303lLPI43y9qoe0oyZ1vtk/UKG75FkWfFUogGNbpOkuz+et5Y0aIEiyg0yh6/l5Q
5h8+yom0HZnREHhqieGbkaGKLkyu7zQ4D4tRK/mBhd8nv+09GtPEG+D5LPbabFVx
KjBMP4Vp24WuSUOqcGSsURHevawPVBfgmsxf1UCjelaIwngdh6WfNCRXa5QQPQTK
ubQvkvXONCDdhmdXQccnRX1nJWhPYi0onffvjsWUfztRypsKzX4dvM9k7xnIcGSG
EnCC4RCgt1UiZIj7frcCMssbA6vJ9naM0s7JF7N3VKeHJtqe1OCRHMYnWUZt9vrq
X6IoIHlZCoLlv39wFW9QNxelcAOCVbD+19MZ0ZXt7LitjIqe7yF5WxDQN4xru087
FzQ4Hfj7eH1SNLLyKZkA1eecjmRoi/OoqAt7afSnwtQLtMUc2bQDg6rHt5C0e4dC
LqP/9PGZTSJiwmtRHJ/N5qYWIh9ju83APvLm/AGBTR2pXmj9G3KdVOkpIC7L35dI
623cSEC3Q3UZutsEm/UplsM=
-----END CERTIFICATE-----
</ca>
key-direction 1
<tls-auth>
#
# 2048 bit OpenVPN static key
#
-----BEGIN OpenVPN Static key V1-----
b02cb1d7c6fee5d4f89b8de72b51a8d0
c7b282631d6fc19be1df6ebae9e2779e
6d9f097058a31c97f57f0c35526a44ae
09a01d1284b50b954d9246725a1ead1f
f224a102ed9ab3da0152a15525643b2e
ee226c37041dc55539d475183b889a10
e18bb94f079a4a49888da566b9978346
0ece01daaf93548beea6c827d9674897
e7279ff1a19cb092659e8c1860fbad0d
b4ad0ad5732f1af4655dbd66214e552f
04ed8fd0104e1d4bf99c249ac229ce16
9d9ba22068c6c0ab742424760911d463
6aafb4b85f0c952a9ce4275bc821391a
a65fcd0d2394f006e3fba0fd34c4bc4a
b260f4b45dec3285875589c97d3087c9
134d3a3aa2f904512e85aa2dc2202498
-----END OpenVPN Static key V1-----
</tls-auth>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
// Copyright 2018 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// +build darwin,go1.12
package unix
import "unsafe"
// Implemented in the runtime package (runtime/sys_darwin.go)
func syscall_syscall(fn, a1, a2, a3 uintptr) (r1, r2 uintptr, err Errno)
func syscall_syscall6(fn, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err Errno)
func syscall_syscall6X(fn, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err Errno)
func syscall_syscall9(fn, a1, a2, a3, a4, a5, a6, a7, a8, a9 uintptr) (r1, r2 uintptr, err Errno) // 32-bit only
func syscall_rawSyscall(fn, a1, a2, a3 uintptr) (r1, r2 uintptr, err Errno)
func syscall_rawSyscall6(fn, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err Errno)
func syscall_syscallPtr(fn, a1, a2, a3 uintptr) (r1, r2 uintptr, err Errno)
//go:linkname syscall_syscall syscall.syscall
//go:linkname syscall_syscall6 syscall.syscall6
//go:linkname syscall_syscall6X syscall.syscall6X
//go:linkname syscall_syscall9 syscall.syscall9
//go:linkname syscall_rawSyscall syscall.rawSyscall
//go:linkname syscall_rawSyscall6 syscall.rawSyscall6
//go:linkname syscall_syscallPtr syscall.syscallPtr
// Find the entry point for f. See comments in runtime/proc.go for the
// function of the same name.
//go:nosplit
func funcPC(f func()) uintptr {
return **(**uintptr)(unsafe.Pointer(&f))
}
| null | 1
|
{
"advantage_score_max": 3.9075913429260254,
"advantage_score_mean": 3.9075913429260254,
"advantage_score_min": 3.9075913429260254,
"advantage_score_std": 0,
"advantage_scores": [
3.9075913429260254
],
"baseline_doc_loss": 0.5959834456443787,
"baseline_truncated": false,
"doc_advantage_score": 14.968793869018555,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 20,
"replacement_paraphrases_length_chars": 20,
"sentences_perturbed": 1,
"target_doc_loss": 0.039815060794353485,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 1420,
"total_sentences": 5,
"truncated": false
}
|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// TransformChainTest.cs - Test Cases for TransformChain
//
// Author:
// Sebastien Pouliot (spouliot@motus.com)
//
// (C) 2002, 2003 Motus Technologies Inc. (http://www.motus.com)
using Xunit;
namespace System.Security.Cryptography.Xml.Tests
{
public class TransformChainTest
{
[Fact]
public void EmptyChain()
{
TransformChain chain = new TransformChain();
Assert.Equal(0, chain.Count);
Assert.NotNull(chain.GetEnumerator());
Assert.Equal("System.Security.Cryptography.Xml.TransformChain", chain.ToString());
}
[Fact]
public void FullChain()
{
TransformChain chain = new TransformChain();
XmlDsigBase64Transform base64 = new XmlDsigBase64Transform();
chain.Add(base64);
Assert.Equal(base64, chain[0]);
Assert.Equal(1, chain.Count);
XmlDsigC14NTransform c14n = new XmlDsigC14NTransform();
chain.Add(c14n);
Assert.Equal(c14n, chain[1]);
Assert.Equal(2, chain.Count);
XmlDsigC14NWithCommentsTransform c14nc = new XmlDsigC14NWithCommentsTransform();
chain.Add(c14nc);
Assert.Equal(c14nc, chain[2]);
Assert.Equal(3, chain.Count);
XmlDsigEnvelopedSignatureTransform esign = new XmlDsigEnvelopedSignatureTransform();
chain.Add(esign);
Assert.Equal(esign, chain[3]);
Assert.Equal(4, chain.Count);
XmlDsigXPathTransform xpath = new XmlDsigXPathTransform();
chain.Add(xpath);
Assert.Equal(xpath, chain[4]);
Assert.Equal(5, chain.Count);
XmlDsigXsltTransform xslt = new XmlDsigXsltTransform();
chain.Add(xslt);
Assert.Equal(xslt, chain[5]);
Assert.Equal(6, chain.Count);
}
}
}
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.5072590112686157,
"baseline_truncated": false,
"doc_advantage_score": 1.288906216621399,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.39355772733688354,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 2041,
"total_sentences": 3,
"truncated": false
}
|
/**
* \file sha512.h
* \brief This file contains SHA-384 and SHA-512 definitions and functions.
*
* The Secure Hash Algorithms 384 and 512 (SHA-384 and SHA-512) cryptographic
* hash functions are defined in <em>FIPS 180-4: Secure Hash Standard (SHS)</em>.
*/
/*
* Copyright (C) 2006-2018, Arm Limited (or its affiliates), All Rights Reserved
* SPDX-License-Identifier: Apache-2.0
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may
* not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
* This file is part of Mbed TLS (https://tls.mbed.org)
*/
#ifndef MBEDTLS_SHA512_H
#define MBEDTLS_SHA512_H
#if !defined(MBEDTLS_CONFIG_FILE)
#include "config.h"
#else
#include MBEDTLS_CONFIG_FILE
#endif
#include <stddef.h>
#include <stdint.h>
#define MBEDTLS_ERR_SHA512_HW_ACCEL_FAILED -0x0039 /**< SHA-512 hardware accelerator failed */
#ifdef __cplusplus
extern "C" {
#endif
#if !defined(MBEDTLS_SHA512_ALT)
// Regular implementation
//
/**
* \brief The SHA-512 context structure.
*
* The structure is used both for SHA-384 and for SHA-512
* checksum calculations. The choice between these two is
* made in the call to mbedtls_sha512_starts_ret().
*/
typedef struct
{
uint64_t total[2]; /*!< The number of Bytes processed. */
uint64_t state[8]; /*!< The intermediate digest state. */
unsigned char buffer[128]; /*!< The data block being processed. */
int is384; /*!< Determines which function to use:
0: Use SHA-512, or 1: Use SHA-384. */
}
mbedtls_sha512_context;
#else /* MBEDTLS_SHA512_ALT */
#include "sha512_alt.h"
#endif /* MBEDTLS_SHA512_ALT */
/**
* \brief This function initializes a SHA-512 context.
*
* \param ctx The SHA-512 context to initialize.
*/
void mbedtls_sha512_init( mbedtls_sha512_context *ctx );
/**
* \brief This function clears a SHA-512 context.
*
* \param ctx The SHA-512 context to clear.
*/
void mbedtls_sha512_free( mbedtls_sha512_context *ctx );
/**
* \brief This function clones the state of a SHA-512 context.
*
* \param dst The destination context.
* \param src The context to clone.
*/
void mbedtls_sha512_clone( mbedtls_sha512_context *dst,
const mbedtls_sha512_context *src );
/**
* \brief This function starts a SHA-384 or SHA-512 checksum
* calculation.
*
* \param ctx The SHA-512 context to initialize.
* \param is384 Determines which function to use:
* 0: Use SHA-512, or 1: Use SHA-384.
*
* \return \c 0 on success.
*/
int mbedtls_sha512_starts_ret( mbedtls_sha512_context *ctx, int is384 );
/**
* \brief This function feeds an input buffer into an ongoing
* SHA-512 checksum calculation.
*
* \param ctx The SHA-512 context.
* \param input The buffer holding the input data.
* \param ilen The length of the input data.
*
* \return \c 0 on success.
*/
int mbedtls_sha512_update_ret( mbedtls_sha512_context *ctx,
const unsigned char *input,
size_t ilen );
/**
* \brief This function finishes the SHA-512 operation, and writes
* the result to the output buffer. This function is for
* internal use only.
*
* \param ctx The SHA-512 context.
* \param output The SHA-384 or SHA-512 checksum result.
*
* \return \c 0 on success.
*/
int mbedtls_sha512_finish_ret( mbedtls_sha512_context *ctx,
unsigned char output[64] );
/**
* \brief This function processes a single data block within
* the ongoing SHA-512 computation.
*
* \param ctx The SHA-512 context.
* \param data The buffer holding one block of data.
*
* \return \c 0 on success.
*/
int mbedtls_internal_sha512_process( mbedtls_sha512_context *ctx,
const unsigned char data[128] );
#if !defined(MBEDTLS_DEPRECATED_REMOVED)
#if defined(MBEDTLS_DEPRECATED_WARNING)
#define MBEDTLS_DEPRECATED __attribute__((deprecated))
#else
#define MBEDTLS_DEPRECATED
#endif
/**
* \brief This function starts a SHA-384 or SHA-512 checksum
* calculation.
*
* \deprecated Superseded by mbedtls_sha512_starts_ret() in 2.7.0
*
* \param ctx The SHA-512 context to initialize.
* \param is384 Determines which function to use:
* 0: Use SHA-512, or 1: Use SHA-384.
*/
MBEDTLS_DEPRECATED void mbedtls_sha512_starts( mbedtls_sha512_context *ctx,
int is384 );
/**
* \brief This function feeds an input buffer into an ongoing
* SHA-512 checksum calculation.
*
* \deprecated Superseded by mbedtls_sha512_update_ret() in 2.7.0.
*
* \param ctx The SHA-512 context.
* \param input The buffer holding the data.
* \param ilen The length of the input data.
*/
MBEDTLS_DEPRECATED void mbedtls_sha512_update( mbedtls_sha512_context *ctx,
const unsigned char *input,
size_t ilen );
/**
* \brief This function finishes the SHA-512 operation, and writes
* the result to the output buffer.
*
* \deprecated Superseded by mbedtls_sha512_finish_ret() in 2.7.0.
*
* \param ctx The SHA-512 context.
* \param output The SHA-384 or SHA-512 checksum result.
*/
MBEDTLS_DEPRECATED void mbedtls_sha512_finish( mbedtls_sha512_context *ctx,
unsigned char output[64] );
/**
* \brief This function processes a single data block within
* the ongoing SHA-512 computation. This function is for
* internal use only.
*
* \deprecated Superseded by mbedtls_internal_sha512_process() in 2.7.0.
*
* \param ctx The SHA-512 context.
* \param data The buffer holding one block of data.
*/
MBEDTLS_DEPRECATED void mbedtls_sha512_process(
mbedtls_sha512_context *ctx,
const unsigned char data[128] );
#undef MBEDTLS_DEPRECATED
#endif /* !MBEDTLS_DEPRECATED_REMOVED */
/**
* \brief This function calculates the SHA-512 or SHA-384
* checksum of a buffer.
*
* The function allocates the context, performs the
* calculation, and frees the context.
*
* The SHA-
| null | 0
|
{
"advantage_score_max": 7.03279447555542,
"advantage_score_mean": 2.686298370361328,
"advantage_score_min": 1.1558873653411865,
"advantage_score_std": 1.6089537143707275,
"advantage_scores": [
7.03279447555542,
5.322033882141113,
5.321577072143555,
4.475250720977783,
4.459537506103516,
3.911952495574951,
2.996703863143921,
2.865086317062378,
2.824888229370117,
2.7300848960876465,
2.119489908218384,
1.979221224784851,
1.877008080482483,
1.7365156412124634,
1.7055597305297852,
1.5033215284347534,
1.4302600622177124,
1.3926938772201538,
1.3494298458099365,
1.2104828357696533,
1.1927570104599,
1.192328691482544,
1.1558873653411865
],
"baseline_doc_loss": 0.45677486062049866,
"baseline_truncated": false,
"doc_advantage_score": 2.3936545848846436,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.1908273845911026,
"target_truncated": false,
"threshold_passing_sentences": 23,
"total_doc_length_chars": 7138,
"total_sentences": 57,
"truncated": false
}
|
function ShoutAssistant(a,u,ps,text) {
this.auth=a;
this.urllen=0;
this.prevScene=ps;
this.uploading=false;
this.text=(text!=undefined)? text: '';
}
ShoutAssistant.prototype.aboutToActivate = function(callback) {
callback.defer(); //makes the setup behave like it should.
};
ShoutAssistant.prototype.setup = function() {
NavMenu.setup(this,{buttons:'navOnly'});
this.imageHosts=[
{label: "Flickr", value: "flickr", urlLen:23},
{label: "Plixi (TweetPhoto)", value: "tweetphoto", urlLen: 18},
{label: "Pikchur", value: "pikchur", urlLen: 16},
{label: "FSPic", value: "fspic", urlLen: 20}
];
this.videoHosts=[
{label: "Pikchur", value: "pikchur", urlLen: 16}
];
this.urlLengths={
"flickr":24,
"tweetphoto": 19,
"pikchur":17,
"fspic": 21
};
logthis("1");
this.controller.setupWidget("okButtonShout",
this.attributes = {type : Mojo.Widget.activityButton},
this.OKButtonModel = {
buttonLabel: "Shout!",
disabled: false
}
);
this.okTappedShoutBound=this.okTappedShout.bindAsEventListener(this);
this.attachImageBound=this.attachImage.bindAsEventListener(this);
this.removeImageBound=this.removeImage.bindAsEventListener(this);
this.attachDownBound=function(){this.controller.get("attachicon").addClassName("pressed");}.bindAsEventListener(this);
this.attachUpBound=function(){this.controller.get("attachicon").removeClassName("pressed");}.bindAsEventListener(this);
this.shoutKeyPressBound=this.shoutKeyPress.bindAsEventListener(this);
this.stageActivateBound=this.stageActivate.bind(this);
Mojo.Event.listen(this.controller.stageController.document,Mojo.Event.activate, this.stageActivateBound);
logthis("2");
this.cookieData=new Mojo.Model.Cookie("credentials");
var credentials=this.cookieData.get();
var pings=(credentials.ping=="on")? '0': '1';
this.stt=(credentials.savetotwitter==true)? (credentials.savetofacebook)? '1' : '0';? '1': '0';
logthis("3");
_globals.ammodel.items[0].disabled=true;
this.controller.setupWidget(Mojo.Menu.appMenu,
_globals.amattributes,
_globals.ammodel);
this.lhc=new Mojo.Model.Cookie("photohost");
var lh=this.lhc.get();
_globals.lasthost=(lh)? lh.photohost: "pikchur";
this.controller.setupWidget("photohostList",
this.phAttributes = {},
this.phModel = {
choices: this.imageHosts,
value: _globals.lasthost,
disabled: false
}
);
logthis("4");
this.controller.setupWidget('shout', this.tipAttributes = {hintText:'Add a shout',multiline:true,focus:true}, this.tipModel = {value:this.text, disabled:false});
this.controller.get("photohostList").hide();
logthis("5");
if(Mojo.Environment.DeviceInfo.touchableRows < 8)
{
this.controller.get("docheckingroup").style.minHeight="275px;"; //247
}
else{
this.controller.get("docheckingroup").style.minHeight="327px"; //372
}
if(this.stf=="1"){
this.controller.get('share-facebook').addClassName("pressed");
}
this.handleFacebookBound=function(){
logthis("stf: %i, stt: %i",this.stf,this.stt);
if(this.stf=="1"){
this.stf="0";
this.controller.get('share-facebook').removeClassName("pressed");
}else{
this.stf="1";
this.controller.get('share-facebook').addClassName("pressed");
}
}.bindAsEventListener(this);
logthis("6");
if(this.stt=="1"){
this.controller.get('share-twitter').addClassName("pressed");
}
this.handleTwitterBound=function(){
logthis("stf: %i, stt: %i",this.stf,this.stt);
if(this.stt=="1"){
this.stt="0";
this.controller.get('share-twitter').removeClassName("pressed");
}else{
this.stt="1";
this.controller.get('share-twitter').addClassName("pressed");
}
}.bindAsEventListener(this);
logthis("7");
this.handlePhotohostBound=this.handlePhotohost.bind(this);
Mojo.Event.listen(this.controller.get("photohostList"), Mojo.Event.propertyChange, this.handlePhotohostBound);
Mojo.Event.listen(this.controller.get('share-twitter'), Mojo.Event.tap, this.handleTwitterBound);
Mojo.Event.listen(this.controller.get('share-facebook'), Mojo.Event.tap, this.handleFacebookBound);
Mojo.Event.listen(this.controller.get('okButtonShout'), Mojo.Event.tap, this.okTappedShoutBound);
Mojo.Event.listen(this.controller.get('attach'), Mojo.Event.tap, this.attachImageBound);
Mojo.Event.listen(this.controller.get('img-preview'), Mojo.Event.tap, this.removeImageBound);
Mojo.Event.listen(this.controller.get('attach'), "mousedown", this.attachDownBound);
Mojo.Event.listen(this.controller.get('attach'), "mouseup", this.attachUpBound);
Mojo.Event.listen(this.controller.document, "keyup", this.shoutKeyPressBound);
logthis("8");
}
ShoutAssistant.prototype.stageActivate = function(event) {
NavMenu.setup(this,{buttons: 'navOnly'});
};
ShoutAssistant.prototype.activate = function(event) {
/*NavMenu.setThat(this);*/
this.controller.get('shout').mojo.focus();
}
ShoutAssistant.prototype.shoutKeyPress = function(event) {
logthis("keypress");
if(this.hasPhoto){
}
try{
var charsLeft=140-this.urllen-this.controller.get("shout").mojo.getValue().length;
this.controller.get("charCount").innerHTML=charsLeft;
if(charsLeft<0){
if(!this.controller.get("charCount").hasClassName("negative")){
this.controller.get("charCount").addClassName("negative");
}
}else{
if(this.controller.get("charCount").hasClassName("negative")){
this.controller.get("charCount").removeClassName("negative");
}
}
}catch(e){
}
};
ShoutAssistant.prototype.handleCommand = function(event) {
if(event.type===Mojo.Event.back){
if( this.uploading==true){
event.preventDefault();
event.stop();
this.controller.showAlertDialog({
onChoose: function(value) {
if(value=="yes"){
this.controller.stageController.
| null | 1
|
{
"advantage_score_max": 2.2295022010803223,
"advantage_score_mean": 1.535727858543396,
"advantage_score_min": 1.1870636940002441,
"advantage_score_std": 0.4905746877193451,
"advantage_scores": [
2.2295022010803223,
1.1906176805496216,
1.1870636940002441
],
"baseline_doc_loss": 1.3183889389038086,
"baseline_truncated": false,
"doc_advantage_score": 1.1062273979187012,
"length_change_ratio": 0.44086021505376344,
"net_length_change_chars": -52,
"original_sentences_length_chars": 93,
"replacement_paraphrases_length_chars": 41,
"sentences_perturbed": 1,
"target_doc_loss": 1.1917883157730103,
"target_truncated": false,
"threshold_passing_sentences": 3,
"total_doc_length_chars": 5971,
"total_sentences": 8,
"truncated": false
}
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta content="Apache Forrest" name="Generator">
<meta name="Forrest-version" content="0.10-dev">
<meta name="Forrest-skin-name" content="pelt">
<title>Apache™ FOP Development: RTFLib (jfor)</title>
<link type="text/css" href="../skin/basic.css" rel="stylesheet">
<link media="screen" type="text/css" href="../skin/screen.css" rel="stylesheet">
<link media="print" type="text/css" href="../skin/print.css" rel="stylesheet">
<link type="text/css" href="../skin/profile.css" rel="stylesheet">
<script src="../skin/getBlank.js" language="javascript" type="text/javascript"></script><script src="../skin/getMenu.js" language="javascript" type="text/javascript"></script><script src="../skin/fontsize.js" language="javascript" type="text/javascript"></script>
<link rel="shortcut icon" href="../favicon.ico">
</head>
<body onload="init()">
<script type="text/javascript">ndeSetTextSize();</script>
<div id="top">
<!--+
|header
+-->
<div class="header">
<!--+
|start group logo
+-->
<div class="grouplogo">
<a href="http://xmlgraphics.apache.org/"><img class="logoImage" alt="Apache XML Graphics" src="../images/group-logo.gif" title="Apache XML Graphics is responsible for the creation and maintenance of software for managing the conversion of XML formats to graphical output, and the creation and maintenance of related software components, based on software licensed to the Foundation"></a>
</div>
<!--+
|end group logo
+-->
<!--+
|start Project Logo
+-->
<div class="projectlogo">
<a href="http://xmlgraphics.apache.org/fop/"><img class="logoImage" alt="Apache FOP" src="../images/logo.jpg" title="Apache FOP (Formatting Objects Processor) is the world's first output independent formatter. Output formats currently available are PDF, PCL, PostScript, SVG, XML (area tree), direct printing, AWT, MIF, and text. The primary output target is PDF."></a>
</div>
<!--+
|end Project Logo
+-->
<!--+
|start Search
+-->
<div class="searchbox">
<form action="http://www.google.com/search" method="get" class="roundtopsmall">
<input value="xmlgraphics.apache.org" name="sitesearch" type="hidden"><input onFocus="getBlank (this, 'Search the site with google');" size="25" name="q" id="query" type="text" value="Search the site with google">
<input name="Search" value="Search" type="submit">
</form>
</div>
<!--+
|end search
+-->
<!--+
|start Tabs
+-->
<ul id="tabs">
<li>
<a class="unselected" href="../index.html">Home</a>
</li>
<li>
<a class="unselected" href="../1.0/index.html">Version 1.0</a>
</li>
<li>
<a class="unselected" href="../1.1/index.html">Version 1.1</a>
</li>
<li>
<a class="unselected" href="../trunk/index.html">FOP Trunk</a>
</li>
<li class="current">
<a class="selected" href="../dev/index.html">Development</a>
</li>
</ul>
<!--+
|end Tabs
+-->
</div>
</div>
<div id="main">
<div id="publishedStrip">
<!--+
|start Subtabs
+-->
<div id="level2tabs"></div>
<!--+
|end Endtabs
+-->
<script type="text/javascript"><!--
document.write("Last Published: " + document.lastModified);
// --></script>
</div>
<!--+
|breadtrail
+-->
<div class="breadtrail">
<a href="http://www.apache.org/">The Apache Software Foundation</a> > <a href="http://xmlgraphics.apache.org/">Apache XML Graphics Project</a><script src="../skin/breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
</div>
<!--+
|start Menu, mainarea
+-->
<!--+
|start Menu
+-->
<div id="menu">
<div onclick="SwitchMenu('menu_1.1', '../skin/')" id="menu_1.1Title" class="menutitle">About</div>
<div id="menu_1.1" class="menuitemgroup">
<div class="menuitem">
<a href="../dev/index.html">Basics</a>
</div>
</div>
<div onclick="SwitchMenu('menu_1.2', '../skin/')" id="menu_1.2Title" class="menutitle">Design</div>
<div id="menu_1.2" class="menuitemgroup">
<div onclick="SwitchMenu('menu_1.2.1', '../skin/')" id="menu_1.2.1Title" class="menutitle">About</div>
<div id="menu_1.2.1" class="menuitemgroup">
<div class="menuitem">
<a href="../dev/design/index.html">Introduction</a>
</div>
</div>
<div onclick="SwitchMenu('menu_1.2.2', '../skin/')" id="menu_1.2.2Title" class="menutitle">Core Process</div>
<div id="menu_1.2.2" class="menuitemgroup">
<div class="menuitem">
<a href="../dev/design/startup.html">Startup</a>
</div>
<div class="menuitem">
<a href="../dev/design/parsing.html">XML Parsing</a>
</div>
<div class="menuitem">
<a href="../dev/design/fotree.html">FO Tree</a>
</div>
<div class="menuitem">
<a href="../dev/design/properties.html">Properties</a>
</div>
<div class="menuitem">
<a href="../dev/design/layout.html">Layout</a>
</div>
<div class="menuitem">
<a href="../dev/design/breakpos.html">Break Possibility</a>
</div>
<div class="menuitem">
<a href="../dev/design/areas.html">Area Tree</a>
</div>
<div class="menuitem">
<a href="../dev/design/renderers.html">Renderers</a>
</div>
</div>
<div onclick="SwitchMenu('menu_1.2.3', '../skin/')" id="menu_1.2.3Title" class="menutitle">Miscellaneous</div>
<div id="menu_1.2.3" class="menuitemgroup">
<div class="menuitem">
<a href="../dev/design/images.html">Images</a>
</div>
<div class="menuitem">
<a href="../dev/design/pdf-library.html">PDF Library</a>
</div>
<div class="menuitem">
<a href="../dev/design/svg.html">SVG</a>
</div>
<div class="menuitem">
<a href="../dev/design/embedding.html">Embedding</a>
</div>
<div class="menuitem">
<a href="../dev/design/extending.html">Extending</a>
</div>
<div class="menuitem">
<a href="../dev/design/optimise.html">Optimisations</a>
</div>
<div class="menuitem">
<a href="../dev/design/useragent.html">
| null | 1
|
{
"advantage_score_max": 3.489625930786133,
"advantage_score_mean": 3.3032305240631104,
"advantage_score_min": 3.116835117340088,
"advantage_score_std": 0.18639540672302246,
"advantage_scores": [
3.489625930786133,
3.116835117340088
],
"baseline_doc_loss": 0.8250566124916077,
"baseline_truncated": false,
"doc_advantage_score": 6.571218490600586,
"length_change_ratio": 1.0084745762711864,
"net_length_change_chars": 1,
"original_sentences_length_chars": 118,
"replacement_paraphrases_length_chars": 119,
"sentences_perturbed": 1,
"target_doc_loss": 0.1255561113357544,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 5817,
"total_sentences": 4,
"truncated": false
}
|
<launch>
<arg name="visualization" default="false" doc="turns on and off visualization with rviz"/>
<!-- send Panda urdf to parameter server -->
<param name="robot_description" command="$(find xacro)/xacro --inorder '$(find franka_description)/robots/panda_arm_hand.urdf.xacro'" />
<include file="$(find moveit_resources)/panda_moveit_config/launch/planning_context.launch"/>
<node name="compare_collision_checking_speed" pkg="moveit_ros_planning" type="moveit_compare_collision_checking_speed_fcl_bullet" respawn="false" output="screen">
<rosparam command="load" file="$(find moveit_resources)/panda_moveit_config/config/kinematics.yaml"/>
<param name="visualization" value="$(arg visualization)" type="bool"/>
</node>
<include if="$(arg visualization)" file="$(find moveit_resources)/panda_moveit_config/launch/demo.launch"/>
</launch>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
* Created on Jul 6, 2007
*
* Copyright (c) 2007, The JUNG Authors
*
* All rights reserved.
*
* This software is open-source under the BSD license; see either
* "license.txt" or
* https://github.com/jrtom/jung/blob/master/LICENSE for a description.
*/
package edu.uci.ics.jung.algorithms.scoring;
import java.util.Map;
/**
* An interface for algorithms that assign scores to edges.
*
* @param <E> the edge type
* @param <S> the score type
*/
public interface EdgeScorer<E, S> {
/**
* @param e the edge whose score is requested
* @return the algorithm's score for this edge
*/
public S getEdgeScore(E e);
public Map<E, S> edgeScores();
}
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 1.1790199279785156,
"baseline_truncated": false,
"doc_advantage_score": 1.9338041543960571,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.6096894145011902,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 672,
"total_sentences": 4,
"truncated": false
}
|
/* -*- c -*- */
#ifndef _PROBES_H
#define _PROBES_H
#define DTRACE_PROBES_DISABLED 1
#define RUBY_DTRACE_METHOD_ENTRY_ENABLED() 0
#define RUBY_DTRACE_METHOD_ENTRY(classname, methodname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_METHOD_RETURN_ENABLED() 0
#define RUBY_DTRACE_METHOD_RETURN(classname, methodname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_CMETHOD_ENTRY_ENABLED() 0
#define RUBY_DTRACE_CMETHOD_ENTRY(classname, methodname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_CMETHOD_RETURN_ENABLED() 0
#define RUBY_DTRACE_CMETHOD_RETURN(classname, methodname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_REQUIRE_ENTRY_ENABLED() 0
#define RUBY_DTRACE_REQUIRE_ENTRY(rquiredfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_REQUIRE_RETURN_ENABLED() 0
#define RUBY_DTRACE_REQUIRE_RETURN(requiredfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_FIND_REQUIRE_ENTRY_ENABLED() 0
#define RUBY_DTRACE_FIND_REQUIRE_ENTRY(requiredfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_FIND_REQUIRE_RETURN_ENABLED() 0
#define RUBY_DTRACE_FIND_REQUIRE_RETURN(requiredfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_LOAD_ENTRY_ENABLED() 0
#define RUBY_DTRACE_LOAD_ENTRY(loadedfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_LOAD_RETURN_ENABLED() 0
#define RUBY_DTRACE_LOAD_RETURN(loadedfile, filename, lineno) do {} while (0)
#define RUBY_DTRACE_RAISE_ENABLED() 0
#define RUBY_DTRACE_RAISE(classname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_OBJECT_CREATE_ENABLED() 0
#define RUBY_DTRACE_OBJECT_CREATE(classname, filename, lineno) do {} while (0)
#define RUBY_DTRACE_ARRAY_CREATE_ENABLED() 0
#define RUBY_DTRACE_ARRAY_CREATE(length, filename, lineno) do {} while (0)
#define RUBY_DTRACE_HASH_CREATE_ENABLED() 0
#define RUBY_DTRACE_HASH_CREATE(length, filename, lineno) do {} while (0)
#define RUBY_DTRACE_STRING_CREATE_ENABLED() 0
#define RUBY_DTRACE_STRING_CREATE(length, filename, lineno) do {} while (0)
#define RUBY_DTRACE_SYMBOL_CREATE_ENABLED() 0
#define RUBY_DTRACE_SYMBOL_CREATE(str, filename, lineno) do {} while (0)
#define RUBY_DTRACE_PARSE_BEGIN_ENABLED() 0
#define RUBY_DTRACE_PARSE_BEGIN(sourcefile, lineno) do {} while (0)
#define RUBY_DTRACE_PARSE_END_ENABLED() 0
#define RUBY_DTRACE_PARSE_END(sourcefile, lineno) do {} while (0)
#define RUBY_DTRACE_INSN_ENABLED() 0
#define RUBY_DTRACE_INSN(insns_name) do {} while (0)
#define RUBY_DTRACE_INSN_OPERAND_ENABLED() 0
#define RUBY_DTRACE_INSN_OPERAND(val, insns_name) do {} while (0)
#define RUBY_DTRACE_GC_MARK_BEGIN_ENABLED() 0
#define RUBY_DTRACE_GC_MARK_BEGIN() do {} while (0)
#define RUBY_DTRACE_GC_MARK_END_ENABLED() 0
#define RUBY_DTRACE_GC_MARK_END() do {} while (0)
#define RUBY_DTRACE_GC_SWEEP_BEGIN_ENABLED() 0
#define RUBY_DTRACE_GC_SWEEP_BEGIN() do {} while (0)
#define RUBY_DTRACE_GC_SWEEP_END_ENABLED() 0
#define RUBY_DTRACE_GC_SWEEP_END() do {} while (0)
#define RUBY_DTRACE_METHOD_CACHE_CLEAR_ENABLED() 0
#define RUBY_DTRACE_METHOD_CACHE_CLEAR(class, filename, lineno) do {} while (0)
#endif /* _PROBES_H */
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<Panel ux:Class="Outracks.Simulator.DeveloperMenu" Color="#000C" Clicked="Close" >
<ClientPanel>
<Button Alignment="TopLeft" Margin="20" Text="Go back" Clicked="GoBack" />
<StackPanel Alignment="Center">
<Text Alignment="Center" Color="White">Fuse Preview Menu</Text>
<Text Alignment="Center" Color="#ddd">Tap to dismiss</Text>
</StackPanel>
</ClientPanel>
<AddingAnimation>
<Change this.Opacity="0" Easing="CubicIn" Duration="0.3" />
<Scale Factor="1.2" Duration="0.3" Easing="BackIn" />
</AddingAnimation>
<RemovingAnimation>
<Change this.Opacity="0" Easing="CubicOut" Duration="0.3" />
<Scale Factor="0.8" Duration="0.3" Easing="CubicOut" />
</RemovingAnimation>
</Panel>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<?xml version="1.0" encoding="utf-8"?>
<shape
xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="@color/qs_background_dark" />
<corners android:radius="8dp" />
</shape>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
// <copyright file="GameInfo.cs" company="Google Inc.">
// Copyright (C) 2015 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// </copyright>
namespace GooglePlayGames {
///
/// This file is automatically generated DO NOT EDIT!
///
/// These are the constants defined in the Play Games Console for Game Services
/// Resources.
File containing details about the game and its configuration settings. This is automatically updated by running the
/// platform-appropriate setup commands in the Unity editor (which does a simple search / replace
/// on the IDs in the form "__ID__"). We can check whether any particular field has been updated
/// by checking whether it still retains its initial value - we prevent the constants from being
/// replaced in the aforementioned search/replace by stripping off the leading and trailing "__".
/// </summary>
public static class GameInfo {
private const string UnescapedApplicationId = "APP_ID";
private const string UnescapedIosClientId = "IOS_CLIENTID";
private const string UnescapedWebClientId = "WEB_CLIENTID";
private const string UnescapedNearbyServiceId = "NEARBY_SERVICE_ID";
public const string ApplicationId = "__APP_ID__"; // Filled in automatically
public const string IosClientId = "__IOS_CLIENTID__"; // Filled in automatically
public const string WebClientId = "__WEB_CLIENTID__"; // Filled in automatically
public const string NearbyConnectionServiceId = "__NEARBY_SERVICE_ID__";
public static bool ApplicationIdInitialized() {
return !string.IsNullOrEmpty(ApplicationId) && !ApplicationId.Equals(ToEscapedToken(UnescapedApplicationId));
}
public static bool IosClientIdInitialized() {
return !string.IsNullOrEmpty(IosClientId) && !IosClientId.Equals(ToEscapedToken(UnescapedIosClientId));
}
public static bool WebClientIdInitialized() {
return !string.IsNullOrEmpty(WebClientId) && !WebClientId.Equals(ToEscapedToken(UnescapedWebClientId));
}
public static bool NearbyConnectionsInitialized() {
return !string.IsNullOrEmpty(NearbyConnectionServiceId) &&
!NearbyConnectionServiceId.Equals(ToEscapedToken(UnescapedNearbyServiceId));
}
/// <summary>
/// Returns an escaped token (i.e. one flanked with "__") for the passed token
/// </summary>
/// <returns>The escaped token.</returns>
/// <param name="token">The Token</param>
private static string ToEscapedToken(string token) {
return string.Format("__{0}__", token);
}
}
}
| null | 1
|
{
"advantage_score_max": 1.7171653509140015,
"advantage_score_mean": 1.4166333675384521,
"advantage_score_min": 1.1161013841629028,
"advantage_score_std": 0.3005319833755493,
"advantage_scores": [
1.7171653509140015,
1.1161013841629028
],
"baseline_doc_loss": 1.0278691053390503,
"baseline_truncated": false,
"doc_advantage_score": 1.2173776626586914,
"length_change_ratio": 0.958904109589041,
"net_length_change_chars": -3,
"original_sentences_length_chars": 73,
"replacement_paraphrases_length_chars": 70,
"sentences_perturbed": 1,
"target_doc_loss": 0.8443304896354675,
"target_truncated": false,
"threshold_passing_sentences": 2,
"total_doc_length_chars": 3252,
"total_sentences": 11,
"truncated": false
}
|
package compute
// Copyright (c) Microsoft and contributors. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//
// See the License for the specific language governing permissions and
// limitations under the License.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
import (
"context"
"github.com/Azure/go-autorest/autorest"
"github.com/Azure/go-autorest/autorest/azure"
"github.com/Azure/go-autorest/tracing"
"net/http"
)
// AvailabilitySetsClient is the compute Client
type AvailabilitySetsClient struct {
BaseClient
}
// NewAvailabilitySetsClient creates an instance of the AvailabilitySetsClient client.
func NewAvailabilitySetsClient(subscriptionID string) AvailabilitySetsClient {
return NewAvailabilitySetsClientWithBaseURI(DefaultBaseURI, subscriptionID)
}
// NewAvailabilitySetsClientWithBaseURI creates an instance of the AvailabilitySetsClient client.
func NewAvailabilitySetsClientWithBaseURI(baseURI string, subscriptionID string) AvailabilitySetsClient {
return AvailabilitySetsClient{NewWithBaseURI(baseURI, subscriptionID)}
}
// CreateOrUpdate create or update an availability set.
// Parameters:
// resourceGroupName - specifies the resource group name.
// availabilitySetName - the name of the availability set.
// parameters - parameters supplied to the Create Availability Set operation.
func (client AvailabilitySetsClient) CreateOrUpdate(ctx context.Context, resourceGroupName string, availabilitySetName string, parameters AvailabilitySet) (result AvailabilitySet, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AvailabilitySetsClient.CreateOrUpdate")
defer func() {
sc := -1
if result.Response.Response != nil {
sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
req, err := client.CreateOrUpdatePreparer(ctx, resourceGroupName, availabilitySetName, parameters)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "CreateOrUpdate", nil, "Failure preparing request")
return
}
resp, err := client.CreateOrUpdateSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "CreateOrUpdate", resp, "Failure sending request")
return
}
result, err = client.CreateOrUpdateResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "CreateOrUpdate", resp, "Failure responding to request")
}
return
}
// CreateOrUpdatePreparer prepares the CreateOrUpdate request.
func (client AvailabilitySetsClient) CreateOrUpdatePreparer(ctx context.Context, resourceGroupName string, availabilitySetName string, parameters AvailabilitySet) (*http.Request, error) {
pathParameters := map[string]interface{}{
"availabilitySetName": autorest.Encode("path", availabilitySetName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2017-12-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
preparer := autorest.CreatePreparer(
autorest.AsContentType("application/json; charset=utf-8"),
autorest.AsPut(),
autorest.WithBaseURL(client.BaseURI),
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", pathParameters),
autorest.WithJSON(parameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
// CreateOrUpdateSender sends the CreateOrUpdate request. The method will close the
// http.Response Body if it receives an error.
func (client AvailabilitySetsClient) CreateOrUpdateSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure.DoRetryWithRegistration(client.Client))
return autorest.SendWithSender(client, req, sd...)
}
// CreateOrUpdateResponder handles the response to the CreateOrUpdate request. The method always
// closes the http.Response Body.
func (client AvailabilitySetsClient) CreateOrUpdateResponder(resp *http.Response) (result AvailabilitySet, err error) {
err = autorest.Respond(
resp,
client.ByInspecting(),
azure.WithErrorUnlessStatusCode(http.StatusOK),
autorest.ByUnmarshallingJSON(&result),
autorest.ByClosing())
result.Response = autorest.Response{Response: resp}
return
}
// Delete delete an availability set.
// Parameters:
// resourceGroupName - the name of the resource group.
// availabilitySetName - the name of the availability set.
func (client AvailabilitySetsClient) Delete(ctx context.Context, resourceGroupName string, availabilitySetName string) (result OperationStatusResponse, err error) {
if tracing.IsEnabled() {
ctx = tracing.StartSpan(ctx, fqdn+"/AvailabilitySetsClient.Delete")
defer func() {
sc := -1
if result.Response.Response != nil {
sc = result.Response.Response.StatusCode
}
tracing.EndSpan(ctx, sc, err)
}()
}
req, err := client.DeletePreparer(ctx, resourceGroupName, availabilitySetName)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Delete", nil, "Failure preparing request")
return
}
resp, err := client.DeleteSender(req)
if err != nil {
result.Response = autorest.Response{Response: resp}
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Delete", resp, "Failure sending request")
return
}
result, err = client.DeleteResponder(resp)
if err != nil {
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Delete", resp, "Failure responding to request")
}
return
}
// DeletePreparer prepares the Delete request.
func (client AvailabilitySetsClient) DeletePreparer(ctx context.Context, resourceGroupName string, availabilitySetName string) (*http.Request, error) {
pathParameters := map[string]interface{}{
"availabilitySetName": autorest.Encode("path", availabilitySetName),
"resourceGroupName": autorest.Encode("path", resourceGroupName),
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
}
const APIVersion = "2017-12-01"
queryParameters := map[string]interface{}{
"api-version": APIVersion,
}
preparer := autorest.CreatePreparer(
autorest.AsDelete(),
autorest.WithBaseURL(client.BaseURI),
autorest.WithPathParameters("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Compute/availabilitySets/{availabilitySetName}", pathParameters),
autorest.WithQueryParameters(queryParameters))
return preparer.Prepare((&http.Request{}).WithContext(ctx))
}
// DeleteSender sends the Delete request. The method will close the
// http.Response Body if it receives an error.
func (client AvailabilitySetsClient) DeleteSender(req *http.Request) (*http.Response, error) {
sd := autorest.GetSendDecorators(req.Context(), azure
| null | 1
|
{
"advantage_score_max": 4.90650749206543,
"advantage_score_mean": 3.1731033325195312,
"advantage_score_min": 1.8204283714294434,
"advantage_score_std": 1.253558874130249,
"advantage_scores": [
4.90650749206543,
3.8130223751068115,
2.1524546146392822,
1.8204283714294434
],
"baseline_doc_loss": 0.1918731927871704,
"baseline_truncated": false,
"doc_advantage_score": 6.97908878326416,
"length_change_ratio": 1.0434782608695652,
"net_length_change_chars": 3,
"original_sentences_length_chars": 69,
"replacement_paraphrases_length_chars": 72,
"sentences_perturbed": 1,
"target_doc_loss": 0.0274925846606493,
"target_truncated": false,
"threshold_passing_sentences": 4,
"total_doc_length_chars": 7492,
"total_sentences": 25,
"truncated": false
}
|
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Stroke Bounds</title>
<link rel="stylesheet" href="../css/style.css">
<script type="text/javascript" src="../../dist/paper-full.js"></script>
<script type="text/paperscript" canvas="canvas">
project.importSVG(document.getElementById('svg'));
</script>
</head>
<body>
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="500" height="500" id="svg">
<g>
<line x1="4" y1="20" x2="200" y2="200" style="stroke:red;stroke-width:10;stroke-dasharray: 10, 4;stroke-linecap: butt" id="line" />
<rect x="200" y="20" rx="20" ry="10" width="150" height="150" style="fill:green" id="round" />
<circle cx="40" cy="100" r="20" style="fill:orange;" id="circle" />
</g>
<g>
<rect x="250" y="180" width="150" height="150" fill="blue" style="stroke-dasharray: 10, 4; stroke-width:0;" id="rect" />
<ellipse cx="120" cy="250" rx="100" ry="50" style="fill:yellow;stroke-width:-1" id="ellipse" />
</g>
<path d="m 100 350 q 100 -300 100 0 t 100 0 t 50 0" stroke="black" stroke-width="4" fill="none" id="path" />
<path d="m 100 350 q 100 -300 100 0" stroke="black" stroke-width="4" fill="none" id="path"/>
<path d="m 100 350 c 66.666666 -200 100 -200 100 0" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 q 100 -300 100 0 t 100 0 T 350 350" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 q 100 -300 100 0 T 300 350 t 50 0" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 q 100 -300 100 0 T 300 350 T 350 350" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 Q 200 50 200 350 t 100 0 t 50 0" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 Q 200 50 200 350 t 100 0 T 350 350" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 Q 200 50 200 350 T 300 350 t 50 0" stroke="black" stroke-width="4" fill="none" />
<path d="m 100 350 Q 200 50 200 350 T 300 350 T 350 350" stroke="black" stroke-width="4" fill="none" />
<path d="M 50 75 c 25 -50 25 -50 100 0 s 100 100 100 0 s 25 -50 100 0" stroke="blue" stroke-width="4" fill="none"/>
<text x="20" y="15" stroke="green" fill="green" style="font:15px arial;" id="text">I love SVG</text>
</svg>
<canvas id="canvas" width="500" height="500"></canvas>
</body>
</html>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
This code is derived from jgit (http://eclipse.org/jgit).
Copyright owners are documented in jgit's IP log.
This program and the accompanying materials are made available
under the terms of the Eclipse Distribution License v1.0 which
accompanies this distribution, is reproduced below, and is
available at http://www.eclipse.org/org/documents/edl-v10.php
All rights reserved.
Redistribution and use in source and binary forms, with or
without modification, are permitted provided that the following
conditions are met:
- Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
- No part of the name of the Eclipse Foundation, Inc. nor the names of its contributors may be used to endorse or promote products derived from this software without prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using NGit;
using NGit.Dircache;
using NGit.Errors;
using NGit.Junit;
using NGit.Revwalk;
using NGit.Storage.File;
using NGit.Storage.Pack;
using NGit.Treewalk;
using NGit.Treewalk.Filter;
using NGit.Util;
using NGit.Util.IO;
using Sharpen;
namespace NGit.Junit
{
/// <summary>Wrapper to make creating test data easier.</summary>
/// <remarks>Wrapper to make creating test data easier.</remarks>
/// <?></?>
public interface TestRepository
{
DirCacheEntry File(string path, RevBlob blob);
RevTree Tree(params DirCacheEntry[] entries);
RevTag Tag(string name, RevObject dst);
RevCommit Commit(RevTree tree, params RevCommit[] parents);
RevCommit Commit(params RevCommit[] parents);
RevWalk GetRevWalk();
CommitBuilder Commit();
ObjectInserter inserter { get; set; }
void SetAuthorAndCommitter(NGit.CommitBuilder c);
void Tick(int secDelta);
T ParseBody<T>(T @object) where T:RevObject;
RevWalk pool { get; set; }
Repository db { get; set; }
T Update<T>(string @ref, T obj) where T:AnyObjectId;
void WriteFile(FilePath p, byte[] bin);
RevBlob Blob(string content);
RevBlob Blob(byte[] content);
}
public class TestRepository<R> : TestRepository where R : Repository
{
private static readonly PersonIdent author;
private static readonly PersonIdent committer;
static TestRepository()
{
MockSystemReader m = new MockSystemReader();
long now = m.GetCurrentTime();
int tz = m.GetTimezone(now);
string an = "J. Author";
string ae = "jauthor@example.com";
author = new PersonIdent(an, ae, now, tz);
string cn = "J. Committer";
string ce = "jcommitter@example.com";
committer = new PersonIdent(cn, ce, now, tz);
}
private Repository storage;
Repository TestRepository.db {
get { return storage; }
set { storage = value; }
}
private Repository db {
get { return (R) (object) storage; }
set { storage = (Repository)(object) value; }
}
public RevWalk pool { get; set; }
public ObjectInserter inserter { get; set; }
private long now;
/// <summary>Wrap a repository with test building tools.</summary>
/// <remarks>Wrap a repository with test building tools.</remarks>
/// <param name="db">the test repository to write into.</param>
/// <exception cref="System.IO.IOException">System.IO.IOException</exception>
public TestRepository(R db) : this(db, new RevWalk(db))
{
}
/// <summary>Wrap a repository with test building tools.</summary>
/// <remarks>Wrap a repository with test building tools.</remarks>
/// <param name="db">the test repository to write into.</param>
/// <param name="rw">the RevObject pool to use for object lookup.</param>
/// <exception cref="System.IO.IOException">System.IO.IOException</exception>
public TestRepository(R db, RevWalk rw)
{
this.db = db;
this.pool = rw;
this.inserter = db.NewObjectInserter();
this.now = 1236977987000L;
}
/// <returns>the repository this helper class operates against.</returns>
public virtual Repository GetRepository()
{
return db;
}
/// <returns>get the RevWalk pool all objects are allocated through.</returns>
public virtual RevWalk GetRevWalk()
{
return pool;
}
/// <returns>
/// current time adjusted by
/// <see cref="TestRepository{R}.Tick(int)">TestRepository<R>.Tick(int)</see>
/// .
/// </returns>
public virtual DateTime GetClock()
{
return Sharpen.Extensions.CreateDate(now);
}
/// <summary>Adjust the current time that will used by the next commit.</summary>
/// <remarks>Adjust the current time that will used by the next commit.</remarks>
/// <param name="secDelta">number of seconds to add to the current time.</param>
public virtual void Tick(int secDelta)
{
now += secDelta * 1000L;
}
/// <summary>
/// Set the author and committer using
/// <see cref="TestRepository{R}.GetClock()">TestRepository<R>.GetClock()</see>
/// .
/// </summary>
/// <param name="c">the commit builder to store.</param>
public virtual void SetAuthorAndCommitter(NGit.CommitBuilder c)
{
c.Author = new PersonIdent(author, Sharpen.Extensions.CreateDate(now));
c.Committer = new PersonIdent(committer, Sharpen.Extensions.CreateDate(now));
}
/// <summary>Create a new blob object in the repository.</summary>
/// <remarks>Create a new blob object in the repository.</remarks>
/// <param name="content">file content, will be UTF-8 encoded.</param>
/// <returns>reference to the blob.</returns>
/// <exception cref="System.Exception">System.Exception</exception>
public virtual RevBlob Blob(string content)
{
return Blob(Sharpen.Runtime.GetBytesForString(content, "UTF-8"));
}
/// <summary>Create a new blob object in the repository.</summary>
/// <remarks>Create a new blob object in the repository.</remarks>
/// <param name="content">binary file content.</param>
/// <returns>reference to the blob.</returns>
/// <exception cref="System.Exception">System.Exception</exception>
public virtual RevBlob Blob(byte[] content)
{
ObjectId id;
try
{
id = inserter.Insert(Constants.OBJ_BLOB, content);
inserter.Flush();
}
finally
{
inserter.Release();
}
return pool.LookupBlob(id
| null | 1
|
{
"advantage_score_max": 4.384706974029541,
"advantage_score_mean": 4.384706974029541,
"advantage_score_min": 4.384706974029541,
"advantage_score_std": 0,
"advantage_scores": [
4.384706974029541
],
"baseline_doc_loss": 0.7552263736724854,
"baseline_truncated": false,
"doc_advantage_score": 1.0200378894805908,
"length_change_ratio": 0.9408866995073891,
"net_length_change_chars": -12,
"original_sentences_length_chars": 203,
"replacement_paraphrases_length_chars": 191,
"sentences_perturbed": 1,
"target_doc_loss": 0.7403904795646667,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 7155,
"total_sentences": 12,
"truncated": false
}
|
cmake_minimum_required(VERSION 2.8.3)
project(libmavconn)
## Find catkin macros and libraries
## if COMPONENTS list like find_package(catkin REQUIRED COMPONENTS xyz)
## is used, also find other catkin packages
find_package(catkin REQUIRED)
## System dependencies are found with CMake's conventions
find_package(console_bridge REQUIRED)
find_package(Boost REQUIRED COMPONENTS system)
# add package modules path, not needed in dependend packages
list(INSERT CMAKE_MODULE_PATH 0 "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules")
include(EnableCXX11)
include(MavrosMavlink)
# Fixed in mavlink 2016.7.7
#-> enum values out of int range
#list(APPEND IGNORE_DIALECTS "autoquad")
###################################
## catkin specific configuration ##
###################################
catkin_package(
INCLUDE_DIRS include
LIBRARIES mavconn
DEPENDS Boost console_bridge mavlink
CFG_EXTRAS libmavconn-extras.cmake
)
###########
## Build ##
###########
include_directories(
include
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/include
${Boost_INCLUDE_DIRS}
${mavlink_INCLUDE_DIRS}
${console_bridge_INCLUDE_DIRS}
)
## Declare a cpp library
add_library(mavconn
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/src/mavlink_helpers.cpp
src/interface.cpp
src/serial.cpp
src/tcp.cpp
src/udp.cpp
)
target_link_libraries(mavconn
${Boost_LIBRARIES}
${console_bridge_LIBRARIES}
)
# Use catkin-supplied em_expand macros to generate source files
em_expand(${CMAKE_CURRENT_SOURCE_DIR}/mavlink.context.py.in
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/mavlink.context.py
${CMAKE_CURRENT_SOURCE_DIR}/include/mavconn/mavlink_dialect.h.em
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/include/mavconn/mavlink_dialect.h)
em_expand(${CMAKE_CURRENT_SOURCE_DIR}/mavlink.context.py.in
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/mavlink.context.py
${CMAKE_CURRENT_SOURCE_DIR}/src/mavlink_helpers.cpp.em
${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/src/mavlink_helpers.cpp)
message(STATUS "Copy mavlink_dialect.h to source tree")
file(
COPY ${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/include/mavconn/mavlink_dialect.h
DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/include/mavconn/
)
#############
## Install ##
#############
# all install targets should use catkin DESTINATION variables
# See http://ros.org/doc/api/catkin/html/adv_user_guide/variables.html
## Mark executables and/or libraries for installation
install(TARGETS mavconn
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
## Mark cpp header files for installation
install(DIRECTORY include/mavconn/
DESTINATION ${CATKIN_GLOBAL_INCLUDE_DESTINATION}/mavconn
FILES_MATCHING PATTERN "*.h"
)
install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/catkin_generated/include/mavconn/
DESTINATION ${CATKIN_GLOBAL_INCLUDE_DESTINATION}/mavconn
FILES_MATCHING PATTERN "*.h"
)
## Install cmake files (thanks to cmake_modules package)
install(DIRECTORY cmake/Modules
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}/cmake
)
#############
## Testing ##
#############
if(CATKIN_ENABLE_TESTING)
catkin_add_gtest(mavconn-test test/test_mavconn.cpp)
target_link_libraries(mavconn-test mavconn pthread)
endif()
# vim: ts=2 sw=2 et:
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:drawable="@drawable/radio_off"
android:state_checked="true"
android:state_pressed="true" />
<item
android:drawable="@drawable/radio_black"
android:state_checked="false"
android:state_pressed="true" />
<item
android:drawable="@drawable/radio_checked_hover"
android:state_checked="true"
android:state_hovered="true" />
<item
android:drawable="@drawable/radio_unchecked_hover"
android:state_checked="false"
android:state_hovered="true" />
<item
android:drawable="@drawable/radio_on"
android:state_checked="true" />
<item
android:drawable="@drawable/radio_off" />
</selector>
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
/*
* QEMU PowerPC 440 embedded processors emulation
*
* Copyright (c) 2012 François Revol
* Copyright (c) 2016-2019 BALATON Zoltan
*
* This work is licensed under the GNU GPL license version 2 or later.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. U-Boot, ppc4xx-isram.h */
enum {
DCR_ISRAM0_BASE = 0x20,
DCR_ISRAM0_SB0CR = DCR_ISRAM0_BASE,
DCR_ISRAM0_SB1CR,
DCR_ISRAM0_SB2CR,
DCR_ISRAM0_SB3CR,
DCR_ISRAM0_BEAR,
DCR_ISRAM0_BESR0,
DCR_ISRAM0_BESR1,
DCR_ISRAM0_PMEG,
DCR_ISRAM0_CID,
DCR_ISRAM0_REVID,
DCR_ISRAM0_DPC,
DCR_ISRAM0_END = DCR_ISRAM0_DPC
};
enum {
DCR_ISRAM1_BASE = 0xb0,
DCR_ISRAM1_SB0CR = DCR_ISRAM1_BASE,
/* single bank */
DCR_ISRAM1_BEAR = DCR_ISRAM1_BASE + 0x04,
DCR_ISRAM1_BESR0,
DCR_ISRAM1_BESR1,
DCR_ISRAM1_PMEG,
DCR_ISRAM1_CID,
DCR_ISRAM1_REVID,
DCR_ISRAM1_DPC,
DCR_ISRAM1_END = DCR_ISRAM1_DPC
};
typedef struct ppc4xx_l2sram_t {
MemoryRegion bank[4];
uint32_t l2cache[8];
uint32_t isram0[11];
} ppc4xx_l2sram_t;
#ifdef MAP_L2SRAM
static void l2sram_update_mappings(ppc4xx_l2sram_t *l2sram,
uint32_t isarc, uint32_t isacntl,
uint32_t dsarc, uint32_t dsacntl)
{
if (l2sram->isarc != isarc ||
(l2sram->isacntl & 0x80000000) != (isacntl & 0x80000000)) {
if (l2sram->isacntl & 0x80000000) {
/* Unmap previously assigned memory region */
memory_region_del_subregion(get_system_memory(),
&l2sram->isarc_ram);
}
if (isacntl & 0x80000000) {
/* Map new instruction memory region */
memory_region_add_subregion(get_system_memory(), isarc,
&l2sram->isarc_ram);
}
}
if (l2sram->dsarc != dsarc ||
(l2sram->dsacntl & 0x80000000) != (dsacntl & 0x80000000)) {
if (l2sram->dsacntl & 0x80000000) {
/* Beware not to unmap the region we just mapped */
if (!(isacntl & 0x80000000) || l2sram->dsarc != isarc) {
/* Unmap previously assigned memory region */
memory_region_del_subregion(get_system_memory(),
&l2sram->dsarc_ram);
}
}
if (dsacntl & 0x80000000) {
/* Beware not to remap the region we just mapped */
if (!(isacntl & 0x80000000) || dsarc != isarc) {
/* Map new data memory region */
memory_region_add_subregion(get_system_memory(), dsarc,
&l2sram->dsarc_ram);
}
}
}
}
#endif
static uint32_t dcr_read_l2sram(void *opaque, int dcrn)
{
ppc4xx_l2sram_t *l2sram = opaque;
uint32_t ret = 0;
switch (dcrn) {
case DCR_L2CACHE_CFG:
case DCR_L2CACHE_CMD:
case DCR_L2CACHE_ADDR:
case DCR_L2CACHE_DATA:
case DCR_L2CACHE_STAT:
case DCR_L2CACHE_CVER:
case DCR_L2CACHE_SNP0:
case DCR_L2CACHE_SNP1:
ret = l2sram->l2cache[dcrn - DCR_L2CACHE_BASE];
break;
case DCR_ISRAM0_SB0CR:
case DCR_ISRAM0_SB1CR:
case DCR_ISRAM0_SB2CR:
case DCR_ISRAM0_SB3CR:
case DCR_ISRAM0_BEAR:
case DCR_ISRAM0_BESR0:
case DCR_ISRAM0_BESR1:
case DCR_ISRAM0_PMEG:
case DCR_ISRAM0_CID:
case DCR_ISRAM0_REVID:
case DCR_ISRAM0_DPC:
ret = l2sram->isram0[dcrn - DCR_ISRAM0_BASE];
break;
default:
break;
}
return ret;
}
static void dcr_write_l2sram(void *opaque, int dcrn, uint32_t val)
{
/*ppc4xx_l2sram_t *l2sram = opaque;*/
/* FIXME: Actually handle L2 cache mapping */
switch (dcrn) {
case DCR_L2CACHE_CFG:
case DCR_L2CACHE_CMD:
case DCR_L2CACHE_ADDR:
case DCR_L2CACHE_DATA:
case DCR_L2CACHE_STAT:
case DCR_L2CACHE_CVER:
case DCR_L2CACHE_SNP0:
case DCR_L2CACHE_SNP1:
/*l2sram->l2cache[dcrn - DCR_L2CACHE_BASE] = val;*/
break;
case DCR_ISRAM0_SB0CR:
case DCR_ISRAM0_SB1CR:
case DCR_ISRAM0_SB2CR:
case DCR_ISRAM0_SB3CR:
case DCR_ISRAM0_BEAR:
case DCR
| null | 1
|
{
"advantage_score_max": 1.186349630355835,
"advantage_score_mean": 1.186349630355835,
"advantage_score_min": 1.186349630355835,
"advantage_score_std": 0,
"advantage_scores": [
1.186349630355835
],
"baseline_doc_loss": 0.6358914375305176,
"baseline_truncated": false,
"doc_advantage_score": 1.1981621980667114,
"length_change_ratio": 0.5997458703939009,
"net_length_change_chars": -315,
"original_sentences_length_chars": 787,
"replacement_paraphrases_length_chars": 472,
"sentences_perturbed": 1,
"target_doc_loss": 0.5307223200798035,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 4933,
"total_sentences": 5,
"truncated": false
}
|
/******************************************/
/* */
/* Copyright (c) 2018 monitor1394 */
/* https://github.com/monitor1394 */
/* */
/******************************************/
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Events;
namespace XCharts
{
internal class ObjectPool<T> where T : new()
{
private readonly Stack<T> m_Stack = new Stack<T>();
private readonly UnityAction<T> m_ActionOnGet;
private readonly UnityAction<T> m_ActionOnRelease;
public int countAll { get; private set; }
public int countActive { get { return countAll - countInactive; } }
public int countInactive { get { return m_Stack.Count; } }
public ObjectPool(UnityAction<T> actionOnGet, UnityAction<T> actionOnRelease)
{
m_ActionOnGet = actionOnGet;
m_ActionOnRelease = actionOnRelease;
}
public T Get()
{
T element;
if (m_Stack.Count == 0)
{
element = new T();
countAll++;
}
else
{
element = m_Stack.Pop();
}
if (m_ActionOnGet != null)
m_ActionOnGet(element);
return element;
}
public void Release(T element)
{
if (m_Stack.Count > 0 && ReferenceEquals(m_Stack.Peek(), element))
Debug.LogError("Internal error. Trying to destroy object that is already released to pool.");
if (m_ActionOnRelease != null)
m_ActionOnRelease(element);
m_Stack.Push(element);
}
public void ClearAll()
{
m_Stack.Clear();
}
}
}
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 0.500760018825531,
"baseline_truncated": false,
"doc_advantage_score": 0.8356742262840271,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 0.5992287397384644,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 1838,
"total_sentences": 3,
"truncated": false
}
|
#!/bin/ksh -p
#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# or http://www.opensolaris.org/os/licensing.
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
#
# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
#
# Copyright (c) 2013, 2016 by Delphix. All rights reserved.
#
. $STF_SUITE/include/libtest.shlib
. $STF_SUITE/tests/functional/redundancy/redundancy.kshlib
#
# DESCRIPTION:
# Striped pool have no data redundancy. Any device errors will
# cause data corruption.
#
# STRATEGY:
# 1. Create N virtual disk file.
# 2. Create stripe pool based on the virtual disk files.
# 3. Fill the filesystem with directories and files.
# 4. Record all the files and directories checksum information.
# 5. Corrupt one of the virtual disk files.
# 6. Verify the data is error.
#
verify_runnable "global"
log_assert "Verify striped pool have no data redundancy."
log_onexit cleanup
typeset -i cnt=$(random_int_between 2 5)
setup_test_env $TESTPOOL "" $cnt
damage_devs $TESTPOOL 1 "keep_label"
log_must zpool scrub -w $TESTPOOL
log_mustnot is_healthy $TESTPOOL
log_pass "Striped pool has no data redundancy as expected."
| null | 1
|
{
"advantage_score_max": 3.93865966796875,
"advantage_score_mean": 2.59208607673645,
"advantage_score_min": 1.1126458644866943,
"advantage_score_std": 0.9524248838424683,
"advantage_scores": [
3.93865966796875,
2.93985652923584,
2.9259536266326904,
2.0433144569396973,
1.1126458644866943
],
"baseline_doc_loss": 0.9779649972915649,
"baseline_truncated": false,
"doc_advantage_score": 1.3344119787216187,
"length_change_ratio": 1.0555555555555556,
"net_length_change_chars": 2,
"original_sentences_length_chars": 36,
"replacement_paraphrases_length_chars": 38,
"sentences_perturbed": 1,
"target_doc_loss": 0.7328808307647705,
"target_truncated": false,
"threshold_passing_sentences": 5,
"total_doc_length_chars": 1823,
"total_sentences": 27,
"truncated": false
}
|
Title: brocade_fcport: Fixed wrong speed information
Level: 1
Component: checks
Class: fix
Compatible: compat
Edition: cre
State: unknown
Version: 1.5.0i1
Date: 1500909872
Brocade specific SNMP table
.1.3.6.1.4.1.1588.2.1.1.1.6.2.1
does not provide speed information for the interfaces.
Thus this check plugins had to fetch another SNMP table
.1.3.6.1.2.1.31.1.1.1.15
from IF-MIB.
Unfortunately these tables are not directly connected by index
and the assumed speed information could be wrong for some
devices.
http://community.brocade.com/t5/Fibre-Channel-SAN/SNMP-FC-port-speed/td-p/64980
says that "1073741824" from if-table correlates with index 1 from
brocade-if-table.
| null | 0
|
{
"advantage_score_max": 0,
"advantage_score_mean": 0,
"advantage_score_min": 0,
"advantage_score_std": 0,
"advantage_scores": [],
"baseline_doc_loss": 2.5851638317108154,
"baseline_truncated": false,
"doc_advantage_score": 1.2044122219085693,
"length_change_ratio": 1,
"net_length_change_chars": 0,
"original_sentences_length_chars": 0,
"replacement_paraphrases_length_chars": 0,
"sentences_perturbed": 0,
"target_doc_loss": 2.146411180496216,
"target_truncated": false,
"threshold_passing_sentences": 0,
"total_doc_length_chars": 677,
"total_sentences": 4,
"truncated": false
}
|
/*
* Hibernate OGM, Domain model persistence for NoSQL datastores
*
* License: GNU Lesser General Public License (LGPL), version 2.1 or later
* See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
This library is licensed under the GNU Lesser General Public License (LGPL), version 2.1 or later. For details, refer to the lgpl.txt file in the root directory or visit <http://www.gnu.org/licenses/lgpl-2.1.html>.
* It extends {@link NamedParametersStoredProcedureCallTest} to support backendtck test cases.
* <p>This test based on 3 deployables (simple-value-procedure.jar, result-set-procedure.jar, exceptional-procedure.jar).
* <p>They're representatives of following classes accordingly {@link SimpleValueProcedure}, {@link ResultSetProcedure} and {@link ExceptionalProcedure}.
*
* @author The Viet Nguyen &ntviet18@gmail.com&
*/
@TestForIssue(jiraKey = { "OGM-1431" })
@RunWith(InfinispanRemoteJpaServerRunner.class)
public class ServerTaskInfinispanNamedParametersStoredProcedureCallTest extends NamedParametersStoredProcedureCallTest {
@BeforeClass
public static void setUpAll() throws Exception {
StoredProceduresDeployer.deployJars();
}
@Override
public void testExceptionWhenUsingNotRegisteredParameter() {
// this dialect delegate validation to users
}
}
| null | 1
|
{
"advantage_score_max": 1.5282480716705322,
"advantage_score_mean": 1.5282480716705322,
"advantage_score_min": 1.5282480716705322,
"advantage_score_std": 0,
"advantage_scores": [
1.5282480716705322
],
"baseline_doc_loss": 1.5673718452453613,
"baseline_truncated": false,
"doc_advantage_score": 1.2409528493881226,
"length_change_ratio": 0.40074906367041196,
"net_length_change_chars": -320,
"original_sentences_length_chars": 534,
"replacement_paraphrases_length_chars": 214,
"sentences_perturbed": 1,
"target_doc_loss": 1.263038992881775,
"target_truncated": false,
"threshold_passing_sentences": 1,
"total_doc_length_chars": 1654,
"total_sentences": 6,
"truncated": false
}
|
import { handleActions } from 'redux-actions'
import { fromJS } from 'immutable'
export default handleActions(
{
PROJECT_LOAD: (state, { payload }) => {
try {
const proj = fromJS(payload)
return state.unshift(proj)
} catch (err) {
return state
}
},
PROJECTS_LOAD: (state, { payload }) => {
try {
return fromJS(payload)
} catch (err) {
return state
}
},
PROJECT_UPDATE_PREVIEW: (state, { payload }) => {
if (!state) {
return state
}
const { path, html } = payload
const index = state.findIndex(pr => pr.get('path') === path)
if (index === -1) {
return state
}
return state.update(index, p => p.set('html', html))
},
PROJECT_REMOVE: (state, { payload: path }) => {
return state.filter(p => p.get('path') !== path)
},
PROJECT_RENAME: (state, { payload: { oldPath, newPath } }) => {
return state.map(p => {
if (p.get('path') !== oldPath) {
return p
}
return p.set('path', newPath)
})
},
},
null,
)
| null | 0
|
{
"advantage_score_max": null,
"advantage_score_mean": null,
"advantage_score_min": null,
"advantage_score_std": null,
"advantage_scores": null,
"baseline_doc_loss": null,
"baseline_truncated": null,
"doc_advantage_score": null,
"length_change_ratio": null,
"net_length_change_chars": null,
"original_sentences_length_chars": null,
"replacement_paraphrases_length_chars": null,
"sentences_perturbed": null,
"target_doc_loss": null,
"target_truncated": null,
"threshold_passing_sentences": null,
"total_doc_length_chars": null,
"total_sentences": null,
"truncated": null
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.