seed
stringlengths
1
14k
source
stringclasses
2 values
[MethodImpl(Inline), Op, Closures(Closure)] public static ref ushort u16<T>(in T src, int offset) => ref add(@as<T,ushort>(src), offset); [MethodImpl(Inline), Op] public static ushort u16(ReadOnlySpan<byte> src) => first16u(src); [MethodImpl(Inline), Op]
ise-uiuc/Magicoder-OSS-Instruct-75K
from . import views urlpatterns = [ path('', views.home, name='home'), path('blog_upload', views.blog_upload, name='uploading_blogs'), path('blogs/<slug:the_slug>', views.blog_details, name='blog_details'), path('blog-delete/<slug:the_slug>', views.blog_delete, name='blog_delete'), path('like/<slug:the_slug>', views.blog_like, name='like_blog'),
ise-uiuc/Magicoder-OSS-Instruct-75K
} void SceneAsteroids::SetupModels() { ModelJoey* rock = new ModelJoey("Models/rock.obj", "Textures"); ModelJoey* planet = new ModelJoey("Models/planet.obj", "Textures"); models.insert(std::make_pair("rock", rock)); models.insert(std::make_pair("planet", planet)); } void SceneAsteroids::Update(float timestep, Window* mainWindow)
ise-uiuc/Magicoder-OSS-Instruct-75K
role: number; expireIn: string | number; }; export type UserSessionToken = { id: string; role: number; expireIn?: string | number; };
ise-uiuc/Magicoder-OSS-Instruct-75K
migrations.CreateModel( name='interview', fields=[ ('interview_id', models.AutoField(primary_key=True, serialize=False)), ('date', models.DateTimeField(default=django.utils.timezone.now)), ('feedback', models.CharField(default='?', max_length=500)), ('status', models.IntegerField(default=0)), ('apply_id', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='backend.apply')), ], ), migrations.CreateModel(
ise-uiuc/Magicoder-OSS-Instruct-75K
pub const NBRE_MAX_CANAUX: usize = 8; /// Chemin vers le fichier des profils pub const PROFILS_SOURCE: &'static str = "./profils.csv";
ise-uiuc/Magicoder-OSS-Instruct-75K
get { return this.deliverables_Line_ReferenceField; } set { this.deliverables_Line_ReferenceField = value; this.RaisePropertyChanged("Deliverables_Line_Reference"); } }
ise-uiuc/Magicoder-OSS-Instruct-75K
POINT p;
ise-uiuc/Magicoder-OSS-Instruct-75K
use super::super::super::server::message as server_msg; use super::super::Player; #[derive(Message)] #[rtype(result = "()")] pub struct ListLobbies; impl Handler<ListLobbies> for Player { type Result = (); fn handle(&mut self, _msg: ListLobbies, _ctx: &mut Self::Context) -> Self::Result { self.server.do_send(server_msg::ListLobbies { player_id: self.session_id, }); }
ise-uiuc/Magicoder-OSS-Instruct-75K
class CryptoConfigParser(ConfigParser): def __init__(self, *args, **kwargs): key = kwargs.pop('crypt_key', None) if key != None: self.crypt_key = key else: self.crypt_key = None ConfigParser.__init__(self, *args, **kwargs) def get(self, section, option, *args, **kwargs): raw_val = ConfigParser.get(self, section, option, *args, **kwargs)
ise-uiuc/Magicoder-OSS-Instruct-75K
</div> <div class="clear"></div> </div> </div> </div>
ise-uiuc/Magicoder-OSS-Instruct-75K
export default class AuthToken { /** * * @function * This function generates a jwt token * @param user {User}. * @return {String} */ public static createToken(createTokenData: DataToStoredInToken): TokenData { const expiresIn = 60 * 60; // an hour
ise-uiuc/Magicoder-OSS-Instruct-75K
env = gym.envs.make("MountainCar-v0") env.reset()
ise-uiuc/Magicoder-OSS-Instruct-75K
'price', 'currency_id', 'quantity', ]; /** * Return the user's orders * * @return \Illuminate\Database\Eloquent\Relations\BelongsTo */ public function order(): BelongsTo { return $this->belongsTo(Order::class, 'order_id');
ise-uiuc/Magicoder-OSS-Instruct-75K
<td><input type="hidden" name="nip" value="<?=$row->NIP?>"> <?=$row->NIP?> </td> <td><?=$row->nama?></td> <td><input type="text" name="quiz" value="<?=$row->quiz?>" size="15"></td> <td><select name="divisi"> <?php foreach($listdiv as $rrrow){ ?> <option value="<?=$rrrow->iddiv?>" <?php if($row->divisi==$rrrow->iddiv){echo 'selected';}?> ><?=$rrrow->divisi ?></option> <?php }?> </select></td> <td id="btn"><input type="submit" value="Simpan" class="btnsave"></td>
ise-uiuc/Magicoder-OSS-Instruct-75K
<!-- jquery -->
ise-uiuc/Magicoder-OSS-Instruct-75K
RelationId } from 'typeorm'; import { PublicComment } from '../public-comment/public-comment.entity'; import { Submission } from './submission.entity'; @Entity('cut_block', { schema: 'app_fom' }) export class CutBlock extends ApiBaseEntity<CutBlock> { constructor(cutBlock?: Partial<CutBlock>) { super(cutBlock); } @PrimaryGeneratedColumn('increment', { name: 'cut_block_id' })
ise-uiuc/Magicoder-OSS-Instruct-75K
print(f'vc digitou {num}') print(f'o valor 9 apareceu {num.count(9)} vezes') if 3 in num: print(f'o valor 3 apareceu na {num.index(3)+1} posição') else: print('o valor 3 não foi digitado em nenhuma posição')
ise-uiuc/Magicoder-OSS-Instruct-75K
def get_namespaced_type(identifier: Text): """Create a `NamespacedType` object from the full name of an interface.""" return _get_namespaced_type(identifier) def get_message_namespaced_type(identifier: Text): """Create a `NamespacedType` object from the full name of a message."""
ise-uiuc/Magicoder-OSS-Instruct-75K
public String getLowerCase() { return lowerCase; } }
ise-uiuc/Magicoder-OSS-Instruct-75K
asset_manager.register_asset_type(asset_type)?; let asset_type = MeshBasicAssetType::create(asset_manager, asset_resource)?; asset_manager.register_asset_type(asset_type)?; let asset_type = ModelBasicAssetType::create(asset_manager, asset_resource)?; asset_manager.register_asset_type(asset_type)?; let asset_type = PrefabBasicAssetType::create(asset_manager, asset_resource)?; asset_manager.register_asset_type(asset_type)?; Ok(())
ise-uiuc/Magicoder-OSS-Instruct-75K
# data cleaning df1 = pipeline.data_cleaning(test_raw) # feature engineering df2 = pipeline.feature_engineering(df1) # data preparation df3 = pipeline.data_preparation(df2) # prediction df_response = pipeline.get_prediction(model, test_raw, df3) return df_response
ise-uiuc/Magicoder-OSS-Instruct-75K
db = SQLAlchemy() migrate = Migrate() csrf = CsrfProtect()
ise-uiuc/Magicoder-OSS-Instruct-75K
double_delta=False, keep_all_features=True) elif feature_server_type == '8k': feature_server = FeaturesServer(features_extractor=feature_extractor, feature_filename_structure=feature_filename_structure, dataset_list=('cep'), #delta=True, keep_all_features=True) elif feature_server_type == '8ksns': feature_server = FeaturesServer(features_extractor=feature_extractor, feature_filename_structure=feature_filename_structure, dataset_list=('cep'), delta=True,
ise-uiuc/Magicoder-OSS-Instruct-75K
use std::pin::Pin; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::Arc; use std::task::{self, Poll}; use bytes::Bytes; use futures::prelude::*;
ise-uiuc/Magicoder-OSS-Instruct-75K
/opt/google/bin/genewdatabase -o Tutorial/Databases/SFinset_5 --imagery Tutorial/Projects/Imagery/SFinset_5 /opt/google/bin/gebuild Tutorial/Databases/SFinset_1 /opt/google/bin/gebuild Tutorial/Databases/SFinset_2 /opt/google/bin/gebuild Tutorial/Databases/SFinset_3 /opt/google/bin/gebuild Tutorial/Databases/SFinset_4 /opt/google/bin/gebuild Tutorial/Databases/SFinset_5
ise-uiuc/Magicoder-OSS-Instruct-75K
import numpy as np import pandas as pd import plotly from flask import Flask, jsonify, render_template, request from plotly.graph_objs import Bar from sqlalchemy import create_engine from disaster.models.train_classifier import tokenize app = Flask(__name__, static_url_path='/static') # load data engine = create_engine('sqlite:///disaster/data/disaster.db') df = pd.read_sql_table('mytable', engine) plotting_helper = pd.read_csv('disaster/data/plotting_df.csv')
ise-uiuc/Magicoder-OSS-Instruct-75K
Arguments: Context - Pointer to the context to query GetExpirationTime - If TRUE return the expiration time.
ise-uiuc/Magicoder-OSS-Instruct-75K
def numberOfDigitOne(self, n): """ function to count number of digit ones in a number n. mod by 10 to test if 1st digit is 1; then divide by 10 to get next digit; next test if next digit is 1. """ result = 0 while n: if n % 10 == 1: result += 1
ise-uiuc/Magicoder-OSS-Instruct-75K
import reporter from reporter import Reporter
ise-uiuc/Magicoder-OSS-Instruct-75K
</a> </div> <div class="card-body"> <table class="table table-bordered table-striped"> <thead> <tr> <th>#</th>
ise-uiuc/Magicoder-OSS-Instruct-75K
DB<KEY> # COMMAND ---------- YCG<KEY> <KEY> <KEY> # COMMAND ---------- ZRVAOZRAYN NMEGHRENACAKMPTMCCNTUBFMQZODD
ise-uiuc/Magicoder-OSS-Instruct-75K
black_args.append("--quiet") black_args.append(fp.name) try:
ise-uiuc/Magicoder-OSS-Instruct-75K
} private class FrameCompletionHandler implements CompletionCheck, CompletionHandler<Long, Void> { private final FrameType expected; protected final ByteBuffer[] buffers; private boolean parsedFrameHeader = false;
ise-uiuc/Magicoder-OSS-Instruct-75K
for webcam in configuration: print(webcam['URL'], webcam['directory'])
ise-uiuc/Magicoder-OSS-Instruct-75K
term = CommitteePostTerm() term.post = self term.start_date = start_date term.end_date = end_date return term def to_dict(self): terms = [] for term in self.current_terms(): terms.append({ "id": term.id, "startDate": term.start_date, "endDate": term.end_date, "user": term.user.to_dict_without_terms()
ise-uiuc/Magicoder-OSS-Instruct-75K
{ _rep->socket = socket(AF_UNIX, SOCK_STREAM, 0); } else { _rep->socket = socket(PF_INET, SOCK_STREAM, IPPROTO_TCP); } if (_rep->socket < 0) { delete _rep; _rep = 0; //l10n
ise-uiuc/Magicoder-OSS-Instruct-75K
"""InstrumentType - The type of an Instrument CURRENCY Currency CFD Contract For Difference METAL Metal """ CURRENCY = 1 CFD = 2 METAL = 3
ise-uiuc/Magicoder-OSS-Instruct-75K
BackgroundTabLoadingPolicy::PageNodeToLoadData::~PageNodeToLoadData() = default; struct BackgroundTabLoadingPolicy::ScoredTabComparator {
ise-uiuc/Magicoder-OSS-Instruct-75K
from .fsa import * from .fsa_util import str_to_fsa
ise-uiuc/Magicoder-OSS-Instruct-75K
tag.append("{0!s}={1!s}".format(arg, entry[arg])) return ','.join(tag) @staticmethod def format_time(entry): return int(float(entry['time']))
ise-uiuc/Magicoder-OSS-Instruct-75K
// Last Modified On : 08-27-2018 // *********************************************************************** // <copyright file="PingDockerHostNoAuthenticationCommand.cs" company="Docker.Benchmarking.Orchestrator.Core"> // Copyright (c) . All rights reserved. // </copyright> // <summary></summary> // *********************************************************************** using MediatR;
ise-uiuc/Magicoder-OSS-Instruct-75K
* * 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. * * Neither the name of Intel Corporation nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific 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
ise-uiuc/Magicoder-OSS-Instruct-75K
pytestmark = pytest.mark.django_db def test_create_new_fake_visitor_instance_using_factory(visitor): pass
ise-uiuc/Magicoder-OSS-Instruct-75K
dp.descriptor['resources'] = [ { 'name': 'donor-declarations-categorised-2016', 'path': filepath, 'schema': schema } ] with open('datapackage.json', 'w') as f: f.write(dp.to_json())
ise-uiuc/Magicoder-OSS-Instruct-75K
### GROUPSIZE = 100 ###
ise-uiuc/Magicoder-OSS-Instruct-75K
for child in self.children: if child.name == name: return self parent = child.get_parent(name) if parent is not None:
ise-uiuc/Magicoder-OSS-Instruct-75K
"""proj URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/3.1/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-based views 1. Add an import: from other_app.views import Home 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home')
ise-uiuc/Magicoder-OSS-Instruct-75K
import netmiko import paramiko def send_cmd_with_prompt(device, command, *, wait_for, confirmation): if type(wait_for) == str: wait_for = [wait_for] if type(confirmation) == str: confirmation = [confirmation] with netmiko.Netmiko(**device) as ssh:
ise-uiuc/Magicoder-OSS-Instruct-75K
verbose_name = "Category" verbose_name_plural = "Categories" def __str__(self):
ise-uiuc/Magicoder-OSS-Instruct-75K
if (state !== 'SUCCEEDED') { const { SLACK_ERROR_CHANNEL } = process.env; SLACK_ERROR_CHANNEL && (slackMessage.channel = SLACK_ERROR_CHANNEL); } await postSlackMessage(slackMessage); }
ise-uiuc/Magicoder-OSS-Instruct-75K
f = os.path.join(self.path, "resources.txt") if not os.path.exists(f): print("SKIP: %s NOT EXISTS" % f) resources = list(filter(None, open(f).read().splitlines())) files = getfiles.getfiles(self.path) matches = ["demo.details", "fiddle.manifest"] for f in filter(lambda f: os.path.basename(f) in matches, files): if os.path.exists(f): data = yaml.load(open(f, 'r')) if data.get("resources", []) != resources: data["resources"] = resources yaml.dump(data, open(f, 'w'), default_flow_style=False)
ise-uiuc/Magicoder-OSS-Instruct-75K
cpu_y = y.asarray().astype(np.double)
ise-uiuc/Magicoder-OSS-Instruct-75K
""" Copyright (C) Ghost Robotics - All Rights Reserved Written by <NAME> <<EMAIL>> """ import os import rospy class BaseSerializer: def __init__(self, topic_name='', skip_frame=1, directory_name='./', bag_file=''): self.dir_name = directory_name self.counter = 0 self.skip_frame = skip_frame
ise-uiuc/Magicoder-OSS-Instruct-75K
* PartnerRelay constructor. * @param BookingConnection|null $allBookings * @param TicketConnection|null $allTickets */ public function __construct( ?BookingConnection $allBookings = null, ?TicketConnection $allTickets = null ) { $this->allBookings = $allBookings; $this->allTickets = $allTickets; } /** * @return BookingConnection|null */
ise-uiuc/Magicoder-OSS-Instruct-75K
Task<Wheel> GetById(string id); Task Create(Wheel newLocation); Task Update(Wheel updatedLocation); Task Delete(Wheel toDelete); } }
ise-uiuc/Magicoder-OSS-Instruct-75K
foreach (var type in args[0]) { AppendItem(node, unit, type.GetEnumeratorTypes(node, unit)); } }
ise-uiuc/Magicoder-OSS-Instruct-75K
XM_ASSERT_EQ(v2.pos.x, v1.pos.x); XM_ASSERT_EQ(v2.pos.y, v1.pos.y); XM_ASSERT_EQ(v2.pos.z, v1.pos.z); XM_ASSERT_EQ(v2.uv0.x, v1.uv0.x); XM_ASSERT_EQ(v2.uv0.y, v1.uv0.y); XM_ASSERT_EQ(v2.color0.x, testColor.x); XM_ASSERT_EQ(v2.color0.y, testColor.y); XM_ASSERT_EQ(v2.color0.z, testColor.z);
ise-uiuc/Magicoder-OSS-Instruct-75K
export FLASK_ENV=development export FLASK_DEBUG=1 #flask run --port=8800 cd .. gunicorn app:app
ise-uiuc/Magicoder-OSS-Instruct-75K
return getState().label; } @Override protected PeriodicItemState getState() { return (PeriodicItemState) super.getState(); } public DataType[] getDataSet() {
ise-uiuc/Magicoder-OSS-Instruct-75K
root=/dev/vda mem=768M vmalloc=768M" ;; ""|--help) usage ;; *) echo "Unsupported architecture: $1"
ise-uiuc/Magicoder-OSS-Instruct-75K
"""A ba.Material with a very low friction/stiffness/etc that can be applied to invisible 'railings' useful for gently keeping characters from falling off of cliffs. """ if self._railing_material is None: mat = self._railing_material = ba.Material() mat.add_actions(('modify_part_collision', 'collide', False)) mat.add_actions(('modify_part_collision', 'stiffness', 0.003))
ise-uiuc/Magicoder-OSS-Instruct-75K
if repository in yes: subprocess.call(['git', 'clone', repo['url']], cwd=target_dir) writeToPomXML(repo) writeToPlan(repo) else: for repo in config['repos']: if repo['auto_install'] == "yes": print("Geppetto repository cloned by default", repo['url']) if repo['name'] == 'geppetto-application': # subprocess.call(['rm', '-rf', 'webapp'], cwd=os.path.join(target_dir, 'org.geppetto.frontend/src/main')) subprocess.call(['git', 'clone', repo['url'], 'webapp'], cwd=os.path.join(target_dir, 'org.geppetto.frontend/src/main')) else: subprocess.call(['git', 'clone', repo['url']], cwd = target_dir) #Once the repos are cloned, write to pom.xml
ise-uiuc/Magicoder-OSS-Instruct-75K
function textblock { echo "<text xp=\"$2\" yp=\"$3\" sp=\"$4\" font=\"$5\" wp=\"$6\" color=\"$7\" opacity=\"$8\" type=\"block\">$1</text>" } function textcode { echo "<text xp=\"$2\" yp=\"$3\" sp=\"$4\" font=\"$5\" wp=\"$6\" color=\"$7\" opacity=\"$8\" type=\"code\">$1</text>" } function list { echo "<list xp=\"$1\" yp=\"$2\" sp=\"$3\" color=\"$4\" opacity=\"$5\">" } function blist {
ise-uiuc/Magicoder-OSS-Instruct-75K
return InlineKeyboardMarkup([ [InlineKeyboardButton(name, callback_data=data) for (name, data) in row] for row in layout if row ]) # pylint: disable=invalid-name def s(amount: int, plural_ending: str = 's', singular_ending: str = '') -> str: '''Return the plural or singular ending depending on the amount.'''
ise-uiuc/Magicoder-OSS-Instruct-75K
rules = [ Rule(LinkExtractor(allow=['/[a-zA-Z0-9-]+-\d+\.html']), 'parse_item'), Rule(LinkExtractor(allow=['/[a-zA-Z0-9-]+-1+\.html']), 'parse'), #Rule(LinkExtractor(), 'parse_item_and_links'), ]
ise-uiuc/Magicoder-OSS-Instruct-75K
- etc """
ise-uiuc/Magicoder-OSS-Instruct-75K
print("\nMemory location of str1 =", hex(id(str1))) print("Memory location of str2 =", hex(id(str2))) print()
ise-uiuc/Magicoder-OSS-Instruct-75K
##################################### from RCNN ############################################# pretrain_opts['padding'] = 1.2 pretrain_opts['padding_ratio'] = 5. pretrain_opts['padded_img_size'] = pretrain_opts['img_size'] * int(pretrain_opts['padding_ratio']) pretrain_opts['frame_interval'] = 2
ise-uiuc/Magicoder-OSS-Instruct-75K
:param user: A django user, created after receiving OAuth details :param details: A dictionary of OAuth user info :return: None """ pass def check_user_details(self, details): """ Stub method to allow checking OAuth user details and raising PermissionDenied if not valid :param details: A dictionary of OAuth user info """ pass def verify_user_belongs_to_group(self, duke_unique_id, group_name):
ise-uiuc/Magicoder-OSS-Instruct-75K
printf("release - recv.\n"); release(device_data_ptr); pthread_exit(NULL); }
ise-uiuc/Magicoder-OSS-Instruct-75K
return BossHTTPError("Datatype does not match channel", ErrorCodes.DATATYPE_DOES_NOT_MATCH) # Make sure cutout request is under 1GB UNCOMPRESSED total_bytes = req.get_x_span() * req.get_y_span() * req.get_z_span() * len(req.get_time()) * (self.bit_depth/8) if total_bytes > settings.CUTOUT_MAX_SIZE: return BossHTTPError("Cutout request is over 1GB when uncompressed. Reduce cutout dimensions.", ErrorCodes.REQUEST_TOO_LARGE)
ise-uiuc/Magicoder-OSS-Instruct-75K
import ComponentRequest from './ComponentRequest' interface CascaderProp extends CascaderProps, CompleteProps { } const filter: string[] = ['item', 'handleLoadData'] export default function (props: CascaderProp) { const getProps = GetSystemParam(props, filter) const Component = ComponentEvent(props.item, props, <Cascader/>) return ComponentRequest(true, props.item, getProps, Component) }
ise-uiuc/Magicoder-OSS-Instruct-75K
def __init__(self, groups=None, policies=None): self.update(groups, policies) def update(self, groups=None, policies=None): """Update the stored configuration with the provided values. :param groups: The groups. :type groups: dict or None :param policies: The policies. :type policies: dict or None """ if groups: if self.groups:
ise-uiuc/Magicoder-OSS-Instruct-75K
X_res, y_res = translate._feature_df_to_nn_input(df) tools.eq_(X_res.shape, (n - (lookback + lookforward), lookback + lookforward + 1, len(features))) def test_time_gaps(): n = 50 for gap in range(1, 3): df = pd.DataFrame({"time": pd.to_datetime(list(range(0, n * gap, gap)), unit="s"),
ise-uiuc/Magicoder-OSS-Instruct-75K
license='', packages=find_packages(exclude=['ez_setup', 'examples', 'tests']), include_package_data=True, zip_safe=False, install_requires=[ # -*- Extra requirements: -*- ], entry_points=""" # -*- Entry points: -*-
ise-uiuc/Magicoder-OSS-Instruct-75K
self.coordinates = [] libdir = path.abspath(path.dirname(__file__)) self.image = Image.open(libdir + "/assets/dota2map.png") self.draw = ImageDraw.Draw(self.image) self.map_w, self.map_h = self.image.size # init information tables and respective columns tower_info_table = received_tables.by_dt['DT_DOTA_BaseNPC_Tower'] position_x_index = tower_info_table.by_name['m_cellX'] position_y_index = tower_info_table.by_name['m_cellY'] position_vector_index = tower_info_table.by_name['m_vecOrigin'] name_index = tower_info_table.by_name['m_iName'] tower_list = deepcopy(TOWERS)
ise-uiuc/Magicoder-OSS-Instruct-75K
_Titles = List[str] _Text = Tuple[_Titles, _Alineas] _LabelizedText = Tuple[_Text, Set[TopicName]] def _build_labelized_text(raw_text: Tuple[int, List[str], List[Dict]], labels: Set[TopicName]) -> _LabelizedText: text = raw_text[1], [EnrichedString.from_dict(dict_) for dict_ in raw_text[2]] return text, labels def _load_dataset( texts: List[Tuple[int, List[str], List[Dict]]], labels: Dict[int, Set[TopicName]] ) -> List[_LabelizedText]: return [_build_labelized_text(text, labels[index]) for index, text in enumerate(texts)]
ise-uiuc/Magicoder-OSS-Instruct-75K
for row in range(self.ui.tableWidget.rowCount()): for col in range(self.ui.tableWidget.columnCount()): self.ui.tableWidget.setItem(row, col, QtWidgets.QTableWidgetItem(None))
ise-uiuc/Magicoder-OSS-Instruct-75K
env.roledefs = { 'all': [host1, host2, host3, host4, host5], 'cfgm': [host1], 'webui': [host1], 'control': [host2, host3], 'compute': [host4, host5], 'collector': [host2, host3], 'database': [host1], 'build': [host_build], } env.hostnames = {
ise-uiuc/Magicoder-OSS-Instruct-75K
def onPress(self, b): self.onExit(self.key, self.content, b.tag, self.tag)
ise-uiuc/Magicoder-OSS-Instruct-75K
} if let returned = returned { returns.append(returned)
ise-uiuc/Magicoder-OSS-Instruct-75K
logging.info("Unzipping %s...", zip_file) # make sure we have an input file if not zip_file or not os.path.isfile(zip_file): logging.error("%s - unzip - Jahia zip file %s not found", site_name, zip_file) raise ValueError("Jahia zip file not found") # create zipFile to manipulate / extract zip content export_zip = zipfile.ZipFile(zip_file, 'r')
ise-uiuc/Magicoder-OSS-Instruct-75K
) for i in range(n): if i % 2 == 0: grid = (
ise-uiuc/Magicoder-OSS-Instruct-75K
# Use json.load to get the data from the config file try: config_info = json.load(config_file) api_key = config_info['api_key'][0] config_info = config_info["conversions"] except json.decoder.JSONDecodeError as err: print("ERROR: Could not parse 'hotfolders_config.json' - invalid JSON found:") print(err) sys.exit(0) """
ise-uiuc/Magicoder-OSS-Instruct-75K
Text("Alert") .font(.headline) TabView(selection: $selectedTabIndex) { Group { VStack(spacing: 10) { FieldView(title: "Title", description: "NotificationView.Hints.Alert.Title",
ise-uiuc/Magicoder-OSS-Instruct-75K
def main(args=None, **kwargs): """Run (start) the device server.""" run([TestDevice], verbose=True, msg_stream=sys.stdout, post_init_callback=init_callback, raises=False, args=args, **kwargs) if __name__ == '__main__': PARSER = argparse.ArgumentParser(description='Device registration time.')
ise-uiuc/Magicoder-OSS-Instruct-75K
tempDecomp = set() h = FPolynom(F, basis[i], True) if h == FPolynom(F, [1]): i = i + 1 continue for d in decomp:
ise-uiuc/Magicoder-OSS-Instruct-75K
iptables -I PRE_DOCKER -o docker0 -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT iptables -I PRE_DOCKER -i docker0 ! -o docker0 -j ACCEPT iptables -I PRE_DOCKER -m state --state RELATED -j ACCEPT iptables -I PRE_DOCKER -i docker0 -o docker0 -j ACCEPT # Insert this chain before Docker one in FORWARD table iptables -I FORWARD -o docker0 -j PRE_DOCKER
ise-uiuc/Magicoder-OSS-Instruct-75K
&options, shared_options.redis, storage_id, size_threshold, cleanup_target, ) .await?; let status_job = StatusServer::new(&scheduler, shared_options.status_server); let metrics_job = context.metrics.clone(); let server_job = ServerJob::new(options.port, options.storage_directory.clone()); let cleanup_job = CleanupJob::new(size_threshold); let metadata_job = MetadataJob::new(); let advertise_job = ServiceAdvertisorJob::new(ServiceDescriptor::Storage(storage_id), endpoint);
ise-uiuc/Magicoder-OSS-Instruct-75K
('label', models.CharField(db_index=True, max_length=64, verbose_name='Label')), ('content', markdownx.models.MarkdownxField(verbose_name='Content')), ('created_by', models.ForeignKey(blank=True, editable=False, null=True, on_delete=models.SET( components.models.get_sentinel_user), related_name='+', to=settings.AUTH_USER_MODEL)), ], options={ 'abstract': False, }, ), migrations.CreateModel( name='Message',
ise-uiuc/Magicoder-OSS-Instruct-75K
self.base_link_to_workplan = self.get_base_link_to_workplan(url)
ise-uiuc/Magicoder-OSS-Instruct-75K
let acceptor = acceptor.clone(); tokio::spawn(async move { if let Ok(stream) = acceptor.accept(stream).await { let fut = Http::new() .serve_connection(stream, service_fn(serve));
ise-uiuc/Magicoder-OSS-Instruct-75K
/* OP_COUNT can be increased/decrease as per the requirement. * If required to be set as higher value such as 1000000 * one needs to set the VM heap size accordingly. * (For example:Default setting in build.xml is <jvmarg value="-Xmx256M"/> * */ OP_COUNT = 1000;
ise-uiuc/Magicoder-OSS-Instruct-75K
if b.score > self.score { ctx.stroke( kurbo::Rect::new(
ise-uiuc/Magicoder-OSS-Instruct-75K
try: file.write("#F %s\n"%self.FILE_NAME) file.write("\n#S 1 xoppy CrossSec results\n") file.write("#N 5\n")
ise-uiuc/Magicoder-OSS-Instruct-75K
path('productdetail/<int:id>', views.productdetails, name='productdetail'), path('newProduct/', views.newProduct, name='newproduct'), path('newReview/', views.newReview, name='newreview'), path('loginmessage/', views.loginmessage, name='loginmessage'), path('logoutmessage/', views.logoutmessage, name='logoutmessage'), ]
ise-uiuc/Magicoder-OSS-Instruct-75K
# Does this topic include others? if topic in rs._includes: # Try each of these. for includes in sorted(rs._includes[topic]): topics.extend(get_topic_tree(rs, includes, depth + 1)) # Does this topic inherit others? if topic in rs._lineage: # Try each of these. for inherits in sorted(rs._lineage[topic]): topics.extend(get_topic_tree(rs, inherits, depth + 1))
ise-uiuc/Magicoder-OSS-Instruct-75K
upright = np.c_[inds[1:, :-1].ravel(), inds[:-1, 1:].ravel()] downright = np.c_[inds[:-1, :-1].ravel(), inds[1:, 1:].ravel()] edges.extend([upright, downright]) if return_lists: return edges return np.vstack(edges) def edge_list_to_features(edge_list): edges = np.vstack(edge_list) edge_features = np.zeros((edges.shape[0], 2)) edge_features[:len(edge_list[0]), 0] = 1 edge_features[len(edge_list[0]):, 1] = 1 return edge_features
ise-uiuc/Magicoder-OSS-Instruct-75K
fi fi fi }
ise-uiuc/Magicoder-OSS-Instruct-75K