seed
stringlengths
1
14k
source
stringclasses
2 values
'germany:G65_JagdTiger_SdKfz_185': [ 8, 9 ], 'usa:A45_M6A2E1': [ 8, 9 ], 'usa:A80_T26_E4_SuperPershing': [ 8, 9 ], 'ussr:R54_KV-5': [ 8, 9 ], 'ussr:R61_Object252': [ 8, 9 ], 'ussr:R61_Object252_BF': [ 8, 9 ], } def _getTiers(level, cls, key): if key in _special: return _special[key] # HT: (=T4 max+1) if level == 4 and cls == 'heavyTank': return (4, 5)
ise-uiuc/Magicoder-OSS-Instruct-75K
'attention_mask': attention_mask, 'start_position': start_position, 'end_position': end_position, 'token_type_id': self.token_type_id } def get_rex_example(self, num_ctx): ''' Sampling training data for combined retrieval-extraction training. ''' ctx_list, label = self.context_sampler.sample(num_ctx) examples = [self.get_ext_example(ctx_obj=x) for x in ctx_list]
ise-uiuc/Magicoder-OSS-Instruct-75K
/// Default initializer /// /// - Parameters:
ise-uiuc/Magicoder-OSS-Instruct-75K
mod tests;
ise-uiuc/Magicoder-OSS-Instruct-75K
student_names: List[str], individual_seconds: int, max_individual_seconds: int ) -> Tuple[List[str], int]: """Removes the last student from the queue. Parameters ---------- student_names : List[str] The list of students in the queue. individual_seconds : int The number of seconds remaining for the individual meeting.
ise-uiuc/Magicoder-OSS-Instruct-75K
depends_on = None def upgrade(): op.alter_column('event', 'user',
ise-uiuc/Magicoder-OSS-Instruct-75K
if (col.gameObject.name == "SplitMetalBall") { Destroy(col.gameObject); } } }
ise-uiuc/Magicoder-OSS-Instruct-75K
checkForWavelengthMismatch=false; //how to use wavelength sensitive refractive indices: refractiveIndexMedium.put(0.673, 1d); refractiveIndexMedium.put(0.818, 1d); refractiveIndexMedium.put(0.844, 1d); refractiveIndexMedium.put(1.313, 1d); refractiveIndexMedium.put(1.324, 1d);
ise-uiuc/Magicoder-OSS-Instruct-75K
x = 'curso de python no cursoemvideo' print(19 // 2)
ise-uiuc/Magicoder-OSS-Instruct-75K
export const countries: { [key: string]: [string, string]; };
ise-uiuc/Magicoder-OSS-Instruct-75K
# modelo de red neuronal con 4 capas ocultas ann = MLPRegressor(solver='lbfgs', alpha=1e-5, tol=1e-100, hidden_layer_sizes=(28, 21, 14, 7), max_iter=10**4, random_state=1) # entrenar red ann.fit(x_train, y_train) # guardar red en archivo with open('trainedmodel_boston.sav', 'wb') as file:
ise-uiuc/Magicoder-OSS-Instruct-75K
@Blog : @Motto : All our science, measured against reality, is primitive and childlike - and yet it is the most precious thing we have. """ __auth__ = 'diklios' from wtforms import StringField, BooleanField, SubmitField, IntegerField from wtforms.validators import DataRequired, Email, EqualTo, Length, ValidationError, Regexp
ise-uiuc/Magicoder-OSS-Instruct-75K
class Test1 { public: Test1() { cout << "Test1()\n"; } Test1(const Test1&) { cout << "Test1(const Test1&)\n"; } ~Test1() { cout << "~Test1()\n"; } void operator()(int a) { cout << "[" << this_thread::get_id().get_native_id() << "] func1(" << a << ")\n"; } }; class Test2 {
ise-uiuc/Magicoder-OSS-Instruct-75K
// Unless explicitly stated otherwise all files in this repository are licensed under the Apache License Version 2.0. // This product includes software developed at Datadog (https://www.datadoghq.com/). Copyright 2021-Present Datadog, Inc. pub mod container_id;
ise-uiuc/Magicoder-OSS-Instruct-75K
"""add role Revision ID: 221ccee39de7 Revises: <KEY> Create Date: 2021-05-13 23:51:53.241485
ise-uiuc/Magicoder-OSS-Instruct-75K
class IGeoFileLayer(IDefaultPloneLayer): """Marker interface that defines a Zope 3 browser layer. """ class IGisFile(Interface): """ Marker interface for files containing GIS data. Should just be used in the browser page definition!!! """
ise-uiuc/Magicoder-OSS-Instruct-75K
# ,entity1 = entity1,entity2 = entity2) # with driver.session() as session: # for sent in doc.sents: # temp = nlp(str(sent)).ents # if(len(temp) > 2): # for i,entity1 in enumerate(temp[:-1]): # for entity2 in temp[i+1:]: # session.write_transaction(addEntity,str(entity1),str(entity2)) # elif(len(temp) == 2): # session.write_transaction(addEntity,str(temp[0]),str(temp[1]))
ise-uiuc/Magicoder-OSS-Instruct-75K
else: User.objects.get(email=invitee) except User.DoesNotExist: raise forms.ValidationError('User '+invitee+' not found.') return invited class ReviewCreateStep2(forms.Form): query = forms.CharField(widget=QueryWidget)
ise-uiuc/Magicoder-OSS-Instruct-75K
from rest_framework import serializers from mongoengine.fields import ObjectId import sys if sys.version_info[0] >= 3:
ise-uiuc/Magicoder-OSS-Instruct-75K
<filename>matcher/dirstruct/semantic_type_classifier/evaluate.sh<gh_stars>1-10 #!/bin/bash java -Xmx2000m -Djava.library.path=deps/centos7_x86_64 -cp "../prototype.jar:../lib/*" com.nicta.dataint.matcher.runner.RunRfKnnSemanticTypeClassifierEvaluation $1 $2 $3 $4 $5 $6 $7 $8 $9 ${10} ${11}
ise-uiuc/Magicoder-OSS-Instruct-75K
class c { class case ,
ise-uiuc/Magicoder-OSS-Instruct-75K
return data def analyze_entropy(self, files, offset=0, length=0, block=0, plot=True, legend=True, save=False, algorithm=None, load_plugins=True, whitelist=[], blacklist=[], compcheck=False): ''' Performs an entropy analysis on the specified file(s).
ise-uiuc/Magicoder-OSS-Instruct-75K
<reponame>Dharaneeshwar/Leetcode class Solution: def maxSubArray(self, nums: List[int]) -> int: current_max=nums[0] global_max=nums[0] for i in range(1,len(nums)): current_max=max(nums[i],current_max+nums[i]) global_max=max(current_max,global_max)
ise-uiuc/Magicoder-OSS-Instruct-75K
uniform_builder: &mut Self::UniformBuilderRepr, name: &str, ) -> Result<Uniform<T>, UniformWarning> where T: Uniformable<Self>;
ise-uiuc/Magicoder-OSS-Instruct-75K
from typing import Optional, Union, List, Type from rest_framework import serializers from django_basket.models import get_basket_model, BaseBasket from django_basket.models.item import DynamicBasketItem from ..settings import basket_settings from ..utils import load_module def get_basket_item_serializer_class() -> Optional[Type[serializers.Serializer]]: serializer_class = load_module(basket_settings.items_serializer) if serializer_class: return serializer_class
ise-uiuc/Magicoder-OSS-Instruct-75K
look_modification_entity.has_component(AtomComponentProperties.postfx_layer()))
ise-uiuc/Magicoder-OSS-Instruct-75K
} } } /* *** ODSAendTag: IneffbtInc *** */
ise-uiuc/Magicoder-OSS-Instruct-75K
with open("results.txt", 'w') as log_file: for algo_name in algos.keys(): measure_algo(algo_name, args.annotations_path, args.loader, log_file)
ise-uiuc/Magicoder-OSS-Instruct-75K
import { currentlyPlayingMock } from './mocks/player/currently-playing.mock'; import { recentlyPlayedTracksMock } from './mocks/player/recently-played-tracks.mock'; import {
ise-uiuc/Magicoder-OSS-Instruct-75K
if stopsModel.noDataTitle != "" {
ise-uiuc/Magicoder-OSS-Instruct-75K
* AEM Permission Management * %% * Copyright (C) 2013 Cognifide Limited * %% * Licensed under the Apache License, Version 2.0 (the "License");
ise-uiuc/Magicoder-OSS-Instruct-75K
printlnC "$SH_LINE_PREFIX $COLOR_SUCCESS" "Installing chef-manage-2.4.4-1.el7.x86_64.rpm ..... DONE." else printlnC "$SH_LINE_PREFIX $COLOR_WARN" "Installing chef-manage-2.4.4-1.el7.x86_64.rpm ..... DONE with Errors." fi
ise-uiuc/Magicoder-OSS-Instruct-75K
if matrix[row][k_row_i+1]
ise-uiuc/Magicoder-OSS-Instruct-75K
import de.fraunhofer.iosb.svs.analysishub.data.entity.ProcessingModule;
ise-uiuc/Magicoder-OSS-Instruct-75K
'name': 'vlaskola', 'engine': 'peewee.PostgresqlDatabase', 'user': 'postgres' } SECRET_KEY = os.environ.get("SECRET_KEY") SECURITY_REGISTERABLE = True SECURITY_SEND_REGISTER_EMAIL = False SECURITY_PASSWORD_SALT = os.environ.get( "SECURITY_PASSWORD_SALT") SECURITY_FLASH_MESSAGES = False SECURITY_URL_PREFIX = '/api/accounts' SECURITY_REDIRECT_BEHAVIOR = "spa" SECURITY_CSRF_PROTECT_MECHANISMS = ["session", "basic"]
ise-uiuc/Magicoder-OSS-Instruct-75K
_expireCall = None def __init__(self, site, uid, reactor=None): """ Initialize a session with a unique ID for that session. @param reactor: L{IReactorTime} used to schedule expiration of the session. If C{None}, the reactor associated with I{site} is used.
ise-uiuc/Magicoder-OSS-Instruct-75K
mechanism.calculate() mechanism.tables(acceleration=True, velocity=True, position=True) fig1, ax1 = mechanism.plot(cushion=2, show_joints=True) fig2, ax2 = mechanism.plot(cushion=2, velocity=True, acceleration=True) ax2.set_title('Showing Velocity and Acceleration')
ise-uiuc/Magicoder-OSS-Instruct-75K
.. note:: :class: toggle
ise-uiuc/Magicoder-OSS-Instruct-75K
impl From<bool> for Number { fn from(b: bool) -> Number { Number::Bool(b.into()) } } impl From<u64> for Number { fn from(u: u64) -> Number { Number::UInt(u.into()) } } impl From<Boolean> for Number { fn from(b: Boolean) -> Number {
ise-uiuc/Magicoder-OSS-Instruct-75K
self.totalhosts: list = response[0] async def get_hostnames(self) -> Type[list]: return self.totalhosts async def process(self, proxy=False): self.proxy = proxy await self.do_search()
ise-uiuc/Magicoder-OSS-Instruct-75K
model_name='recipe', name='photo', field=models.ImageField(default='recipe_default.jpg', upload_to='profile_pics'), ), ]
ise-uiuc/Magicoder-OSS-Instruct-75K
self.assertEqual(user.username, 'testuser') self.assertEqual(user.email, '<EMAIL>') self.assertTrue(user.is_active) self.assertFalse(user.is_staff)
ise-uiuc/Magicoder-OSS-Instruct-75K
} fn migration_file_extension(&self) -> &'static str { "mongo" } fn migration_len(&self, migration: &Migration) -> usize { migration.downcast_ref::<MongoDbMigration>().steps.len() } fn migration_summary(&self, migration: &Migration) -> String { migration.downcast_ref::<MongoDbMigration>().summary() }
ise-uiuc/Magicoder-OSS-Instruct-75K
std::cout << std::to_string(*buffer) << '\n'; } template<KeyOrValue... Entries> class Map { public: void print() const { (Entries.print(), ...); } };
ise-uiuc/Magicoder-OSS-Instruct-75K
# When dealing with grid, it's important to remember that the coordinate system is flipped # -- grid is made up of rows(y) of columns(x) # Loop through the coordinates and count the number of times each cell in the grid is touched for line in data: if line[x1] == line[x2]: for y in range(min(line[y1], line[y2]), max(line[y1], line[y2]) + 1): grid[y][line[x1]] += 1
ise-uiuc/Magicoder-OSS-Instruct-75K
import java.util.Objects; /** * sofa service register. */
ise-uiuc/Magicoder-OSS-Instruct-75K
guard lineItems.count <= 1024 else {
ise-uiuc/Magicoder-OSS-Instruct-75K
hw_i2c_0 = I2C(0, sda=Pin(21), scl=Pin(22)) axp = AXP192(hw_i2c_0) axp.setup()
ise-uiuc/Magicoder-OSS-Instruct-75K
docker-compose -f docker-compose-dev.yml -p dev --env-file docker/dev.env "${@:}" ;; "--utils"|"-u") echo "starting utils containers" docker-compose -f docker-compose_utils.yml -p utils up -d ;; "--prod"|"-p") echo "starting prod containers" docker-compose -f docker-compose.yml -p prod up -d ;; "--preprod"|"-t") echo "starting preprod containers" docker-compose -f docker-compose-preprod.yml up -d
ise-uiuc/Magicoder-OSS-Instruct-75K
using System.Collections.Generic; namespace Plato.Messaging.RMQ.Interfaces { public interface IRMQConfigurationManager { /// <summary>
ise-uiuc/Magicoder-OSS-Instruct-75K
"fields": [ {"type": "DATE", "name": "submission_date", "mode": "NULLABLE"}, {"type": "DATETIME", "name": "generated_time", "mode": "NULLABLE"}, {"type": "INTEGER", "name": "mau", "mode": "NULLABLE"}, {"type": "INTEGER", "name": "wau", "mode": "NULLABLE"}, {"type": "STRING", "name": "country", "mode": "NULLABLE"}, ] }, }
ise-uiuc/Magicoder-OSS-Instruct-75K
// but drag events happen after mouse out events. clearRootEditableElementForSelectionOnMouseDown(); m_wasShiftKeyDownOnMouseDown = false; } } } HTMLElement::defaultEventHandler(event); } void HTMLAnchorElement::setActive(bool down, bool pause) { if (hasEditableStyle()) {
ise-uiuc/Magicoder-OSS-Instruct-75K
@Override protected void parseArray(JsonNode node) { // NOP } @Override protected void login() {} @Override protected boolean handledAsLogin(JsonNode node) { return false;
ise-uiuc/Magicoder-OSS-Instruct-75K
keep='first', inplace=False) #Upper extreme measurement ratios for all above 0.9, all above 0.8, SH and LH above 0.9 and SH and LH above 0.8 upperbestsitesall = df_results[(df_results['largerthan2stdevLH'] >= 0.9) &
ise-uiuc/Magicoder-OSS-Instruct-75K
pass # Instance Methods
ise-uiuc/Magicoder-OSS-Instruct-75K
} @Override public void destroy() { eventPublisher.unregister(this); executorService.shutdownNow(); } @EventListener public void onIssueEvent(IssueEvent issueEvent) { List<String> scripts = listenerDataManager.getScripts(EventType.ISSUE, issueEvent.getProject().getId()); for (final String script : scripts) { final Map<String, Object> parameters = new HashMap<>(); parameters.put("changeLog", issueEvent.getChangeLog()); parameters.put("eventComment", issueEvent.getComment());
ise-uiuc/Magicoder-OSS-Instruct-75K
super().__init__(message)
ise-uiuc/Magicoder-OSS-Instruct-75K
use super::sdl2::pixels::Color; use super::sdl2::render::Renderer; use super::sdl2::rect::Point; const SCREEN_WIDTH: usize = 64; const SCREEN_HEIGHT: usize = 32; const SCREEN_SIZE: usize = SCREEN_WIDTH * SCREEN_HEIGHT; const SCREEN_SCALE: usize = 10; pub struct Graphics {
ise-uiuc/Magicoder-OSS-Instruct-75K
use InvalidArgumentException;
ise-uiuc/Magicoder-OSS-Instruct-75K
int climbStairs(int n) { int prev = 0; int cur = 1; for(int i = 1; i <= n; i++) { int tmp = prev;
ise-uiuc/Magicoder-OSS-Instruct-75K
// In UI tests it is usually best to stop immediately when a failure occurs. continueAfterFailure = false // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. XCUIApplication().launch() // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. } override func tearDown() { // Put teardown code here. This method is called after the invocation of each test method in the class. super.tearDown() }
ise-uiuc/Magicoder-OSS-Instruct-75K
for c in range(len(matrix)): s+= str(matrix[c][r]) + ' ' s += '\n' print (s) #turn the paramter matrix into an identity matrix #you may assume matrix is square def ident(matrix): for r in range(len(matrix[0])):
ise-uiuc/Magicoder-OSS-Instruct-75K
import numpy as np import nltk from nltk.tokenize import sent_tokenize, word_tokenize import gensim from .core import Transform from tqdm import tqdm class Word2Vec(Transform):
ise-uiuc/Magicoder-OSS-Instruct-75K
model.benchmark(batch_size=16)
ise-uiuc/Magicoder-OSS-Instruct-75K
import os, zipfile # Zip files. def zipfiles(directory):
ise-uiuc/Magicoder-OSS-Instruct-75K
{ MessageBox.Show(ex.ToString()); } } private void button2_Click(object sender, EventArgs e) { try { this.ClosePlayer(); }
ise-uiuc/Magicoder-OSS-Instruct-75K
* Returns a substring based on the arg. * <pre>
ise-uiuc/Magicoder-OSS-Instruct-75K
""" Store everything that comes in """ # for ever while True: # get the item item = yield # store it self.cache.append(item) # all done return
ise-uiuc/Magicoder-OSS-Instruct-75K
fn spawn_deleter( me: Data<Mutex<Self>>, pool: Data<DbConnectionPool>, every: Duration, ) { actix_web::rt::spawn(async move { let mut task = interval_at( Instant::now(), every.to_std().expect("can't spawn on a negative interval")); while task.next().await.is_some() { me.lock().unwrap().delete(pool.clone()) .await .map_err(|err| error!("error deleting, {:?}", err))
ise-uiuc/Magicoder-OSS-Instruct-75K
self.year_slice[year].ix[0,'max'] = self.year_slice[year].ix[0,asset] self.year_slice[year]['max_time'] = self.year_slice[year]['time'] for i in range(1, len(self.year_slice[year][asset])):
ise-uiuc/Magicoder-OSS-Instruct-75K
e.printStackTrace(); logger.error("SQLException:{}!", e.getMessage()); } } /**
ise-uiuc/Magicoder-OSS-Instruct-75K
if isinstance(data, dict): data = dict(data)
ise-uiuc/Magicoder-OSS-Instruct-75K
} override func didReceiveMemoryWarning() { super.didReceiveMemoryWarning() // Dispose of any resources that can be recreated. } }
ise-uiuc/Magicoder-OSS-Instruct-75K
// Created by Gungor Basa on 4/1/20. // import Foundation extension CharacterSet { static let urlQueryValueAllowed: CharacterSet = { let generalDelimitersToEncode = ":#[]@" // does not include "?" or "/" due to RFC 3986 - Section 3.4 let subDelimitersToEncode = "!$&'()*+,;=" var allowed = CharacterSet.urlQueryAllowed allowed.remove(charactersIn: "\(generalDelimitersToEncode)\(subDelimitersToEncode)")
ise-uiuc/Magicoder-OSS-Instruct-75K
def animation( self ): if self.state == 'normal': self.image = self.sheet[ 0 ].subsurface( (int( self.frame%4 )*16, 0), (16, 16) ) self.frame += (.1*self.dt) elif self.state == 'activated': self.t += (.1*self.dt) self.image = self.sheet[ 0 ].subsurface( (4*16, 0), (16, 16) ) if int(self.t**2) + self.y_init != self.y_init: self.rect.y = 10*sin(self.t) + self.y_init
ise-uiuc/Magicoder-OSS-Instruct-75K
export * from './account-instance.controller'; export * from './account.controller'; export * from './plan.controller';
ise-uiuc/Magicoder-OSS-Instruct-75K
self.assertNotIn(session_label, self.calendar.all_sessions)
ise-uiuc/Magicoder-OSS-Instruct-75K
dotnet build dotnet ef database update dotnet publish -c 'Release' -o '/var/netpips/server' sudo service netpips-server start sudo service netpips-server status
ise-uiuc/Magicoder-OSS-Instruct-75K
return data_to_interp_from.interp(year=self.year) def get_remind_electricity_efficiencies(self, drop_hydrogen=True): """ This method retrieves efficiency values for electricity-producing technology, for a specified year, for each region provided by REMIND. Electricity production from hydrogen can be removed from the mix (unless specified, it is removed). :param drop_hydrogen: removes hydrogen from the region-specific electricity mix if `True`. :type drop_hydrogen: bool :return: an multi-dimensional array with electricity technologies market share for a given year, for all regions. :rtype: xarray.core.dataarray.DataArray
ise-uiuc/Magicoder-OSS-Instruct-75K
private var model: CZFeedModel? // Adaptive to `UIView`/`UIViewController` private var cellComponent: CZFeedCellViewSizeCalculatable? open func config(with model: CZFeedModel, onAction: OnAction?, parentViewController: UIViewController? = nil) { defer { self.model = model
ise-uiuc/Magicoder-OSS-Instruct-75K
numeratorSum = np.sum(particleDerivsInRing * momentaMagInRing * np.exp(1.j * harmonic * thetaInRing)) denominatorSum = np.sum(momentaMagInRing) self._fourierHarmonics[harmonic][i] = numeratorSum / denominatorSum if verbose > 0: print('finished!') return self._fourierHarmonics[harmonic]
ise-uiuc/Magicoder-OSS-Instruct-75K
{ public class ViewNotFoundException : CouchbaseException { } }
ise-uiuc/Magicoder-OSS-Instruct-75K
{ @Test public void testGetMessageType_DSNMessage() throws Exception { MimeMessage msg = TestUtils.readMimeMessageFromFile("DSNMessage.txt"); assertEquals(TxMessageType.DSN, TxUtil.getMessageType(msg)); } @Test public void testGetMessageType_MDNMessage() throws Exception { MimeMessage msg = TestUtils.readMimeMessageFromFile("MDNMessage.txt");
ise-uiuc/Magicoder-OSS-Instruct-75K
*/ export interface SolidProvider { name: string; image: string; loginUrl: string; desc: string; }
ise-uiuc/Magicoder-OSS-Instruct-75K
if not (val == True or val == False): valid = False val = data["hivaids"] if not (val == True or val == False): valid = False val = data["anemia"]
ise-uiuc/Magicoder-OSS-Instruct-75K
set -e COVER_PROFILE=profile.cov report_coverage() { go get github.com/mattn/goveralls CIRCLE_BUILD_NUM=${BUILD_ID} CIRCLE_PR_NUMBER=${PULL_NUMBER} $(go env GOBIN)/goveralls \
ise-uiuc/Magicoder-OSS-Instruct-75K
coverageBed -a "$1" -b "$3" > "$4"
ise-uiuc/Magicoder-OSS-Instruct-75K
_nameBox.centerYAnchor.constraint(equalTo: margins.centerYAnchor, constant: 0).isActive = true _nameBox.trailingAnchor.constraint(equalTo: margins.trailingAnchor, constant: -84).isActive = true _nameLabel.trailingAnchor.constraint(equalTo: _nameBox.leadingAnchor, constant: -8).isActive = true _nameLabel.leadingAnchor.constraint(equalTo: margins.leadingAnchor, constant: 84).isActive = true _nameLabel.topAnchor.constraint(equalTo: _messageLabel.bottomAnchor, constant: 8).isActive = true _button.centerXAnchor.constraint(equalTo: margins.centerXAnchor, constant: 0).isActive = true _button.topAnchor.constraint(equalTo: _nameBox.bottomAnchor, constant: 8).isActive = true
ise-uiuc/Magicoder-OSS-Instruct-75K
def sources(self) -> Set[Source]: return set([cast(Source, t) for t in self.datasets if t.TYPE == Source.TYPE]) def to_dict(self) -> Dict[str, Any]: data = super().to_dict() data["sources"] = [s.name for s in self.sources] return data
ise-uiuc/Magicoder-OSS-Instruct-75K
from .auth import auth as auth_blueprint app.register_blueprint(auth_blueprint, url_prefix='/auth') return app
ise-uiuc/Magicoder-OSS-Instruct-75K
public StateRow[] rows { get; set; } }
ise-uiuc/Magicoder-OSS-Instruct-75K
using System.Linq; using System.Linq.Expressions; using System.Text;
ise-uiuc/Magicoder-OSS-Instruct-75K
nl = u"\n" # TODO: errors and status on stderr with CLI? class BaseTextFormatter(Formatter): """
ise-uiuc/Magicoder-OSS-Instruct-75K
"Author": a['Author'], "LinkUrl": a['LinkUrl'], "PubTime": a['PubTime'], "Title": a['Title'], "allPics": a['allPics'], } specials.append(special) return specials def get_article_detail(article_url): """获取新华网article_url中的文章内容 :param article_url: 文章url
ise-uiuc/Magicoder-OSS-Instruct-75K
let task = URLSession.shared.dataTask(with: request){ data, response, error in if error != nil { callback(nil, .apiError(error: "\(String(describing: error?.localizedDescription))")) return } var responseJson = [String:Any]() try? responseJson = (JSONSerialization.jsonObject(with: data!, options: .mutableContainers) as? [String: Any])! callback(responseJson, nil) }
ise-uiuc/Magicoder-OSS-Instruct-75K
"LoadStoreUnit" + str(i+1), arg2) for i in range(arg1)] elif fp_type == FPType.BranchUnit: self.branch_unit = [BranchUnit( "BranchUnit" + str(i+1), arg2) for i in range(arg1)]
ise-uiuc/Magicoder-OSS-Instruct-75K
<filename>python/coursera_python/WESLEYAN/week1/1.py<gh_stars>10-100 def problem1_1(): print("Problem Set 1") pass # replace this pass (a do-nothing) statement with your code
ise-uiuc/Magicoder-OSS-Instruct-75K
it('Await exec', async () => { const list = []; const fn = (arg) => { list.push(arg); return arg; }; webAssemblyQueue.exec(fn, this, 1);
ise-uiuc/Magicoder-OSS-Instruct-75K
import AppKit import SwiftSweet class ViewController: NSViewController { override func loadView() { self.view = NSView(frame: Rect(x: 100, y: 100, width: 800, height: 500)) } override func viewDidLoad() { super.viewDidLoad() textWrap()
ise-uiuc/Magicoder-OSS-Instruct-75K
---------- close : bool, optional If true, a ``plt.close('all')`` call is automatically issued after sending all the SVG figures. """ for figure_manager in Gcf.get_all_fig_managers(): send_svg_canvas(figure_manager.canvas) if close: matplotlib.pyplot.close('all') # This flag will be reset by draw_if_interactive when called
ise-uiuc/Magicoder-OSS-Instruct-75K