seed
stringlengths
1
14k
source
stringclasses
2 values
try: import embedded_jubatus embedded_available = True except ImportError: embedded_available = False try: import numpy import scipy import sklearn sklearn_available = True except ImportError: sklearn_available = False
ise-uiuc/Magicoder-OSS-Instruct-75K
export declare class BeaconV1Schema extends ObjectSchema { constructor(); }
ise-uiuc/Magicoder-OSS-Instruct-75K
<b style="color:#1a6061; font-size:16px; text-shadow:1px 1px #fff;"><i class="far fa-calendar-alt"></i> {{ $current_datetime->format('M-d-Y h:i A') }} - You are logged in!</b> <h3 style="color:#fff; text-shadow:2px 2px #1a6061;">Welcome to <img src="/images/amadeus-icon2.png" style="width:30px;...
ise-uiuc/Magicoder-OSS-Instruct-75K
import os def start(args, logfile, errfile): setup_util.replace_text("openresty/nginx.conf", "CWD", os.getcwd()) setup_util.replace_text("openresty/app.lua", "DBHOSTNAME", args.database_host) subprocess.Popen('sudo /usr/local/openresty/nginx/sbin/nginx -c `pwd`/nginx.conf -g "worker_processes ' + str((args.max_t...
ise-uiuc/Magicoder-OSS-Instruct-75K
print(find_amicable_pair())
ise-uiuc/Magicoder-OSS-Instruct-75K
# redistribute it and/or modify it under the terms of the GNU General Public
ise-uiuc/Magicoder-OSS-Instruct-75K
assert task1.state.node_status == NodeStatus.complete assert task1.find_generated_parameter("YMD").value == 20220607
ise-uiuc/Magicoder-OSS-Instruct-75K
var factory = new ConnectionFactory() { HostName = "localhost" }; using (var connection = factory.CreateConnection()) using (var channel = connection.CreateModel()) { channel.QueueDeclare(queue: "PedidosClientes", durab...
ise-uiuc/Magicoder-OSS-Instruct-75K
tOplkError OplkSyncEventHandler::ProcessSyncEvent() { tOplkError oplkRet = kErrorGeneralError; oplkRet = oplk_waitSyncEvent(0); if (oplkRet != kErrorOk) { qDebug("Error wait sync event. Err=0x%x", oplkRet);
ise-uiuc/Magicoder-OSS-Instruct-75K
if __name__ == '__main__': data_loader = SpatialDataLoader(batch_size=64, use_multiprocessing=True, # data_root_path="data", ucf_split='01', testing_samples_per_video=19, width=224, height=224, num_workers=2) train_loader, test_loader, t...
ise-uiuc/Magicoder-OSS-Instruct-75K
for epoch in range(10): train_loss, train_acc = model.train_model(model, train_iter, epoch) val_loss, val_acc = model.eval_model(model, valid_iter) print(f'Epoch: {epoch+1:02}, Train Loss: {train_loss:.3f}, Train Acc: {train_acc:.2f}%, Val. Loss: {val_loss:3f}, Val. Acc: {val_acc:.2f}%') test_loss...
ise-uiuc/Magicoder-OSS-Instruct-75K
/// <summary> /// Define a unique RDBMS column constraint /// </summary> [AttributeUsage(AttributeTargets.Property)] public class UniqueAttribute : AttributeBase {} }
ise-uiuc/Magicoder-OSS-Instruct-75K
return "ID: {id}".format(id=self.identifier) def __str__(self): return '`{id}`'.format(id=self.identifier)
ise-uiuc/Magicoder-OSS-Instruct-75K
try: from unittest import mock except ImportError: import mock ERROR_MSG_MAP = { AuthenticationError: 'User authentication Failed', PermissionDenied: 'permission', NotFoundError: 'Not Found', ServiceUnavailable: 'Service Unavailable', ServerError: 'Server Error' }
ise-uiuc/Magicoder-OSS-Instruct-75K
return fighters def new_beggar():
ise-uiuc/Magicoder-OSS-Instruct-75K
parentNode:parentNode ){ selectedNode = null; this.blackboard = blackboard;
ise-uiuc/Magicoder-OSS-Instruct-75K
let fixture: ComponentFixture<DataSourceConfigurationV2Component>; let providerRegistryService: ProviderRegistryService; let logger: LoggerService; beforeEach(waitForAsync(() => { logger = new LoggerService(); providerRegistryService = new ProviderRegistryService(logger);
ise-uiuc/Magicoder-OSS-Instruct-75K
} else if let Some(shellwords::MismatchedQuotes) = why.downcast_ref::<shellwords::MismatchedQuotes>() { error!( "channel:{} timestamp:{} command:{} mismatched quotes", context.message.channel_id, context.message.timestamp.iso_8601(),
ise-uiuc/Magicoder-OSS-Instruct-75K
model = get_model()
ise-uiuc/Magicoder-OSS-Instruct-75K
from service.models.dataset import Dataset
ise-uiuc/Magicoder-OSS-Instruct-75K
// mamba_ios_cocoapod_testTests // // Created by David Coufal on 12/20/17. // Copyright © 2017 David Coufal. // Released under an MIT license: https://opensource.org/licenses/MIT // import XCTest @testable import mamba_ios_cocoapod_test class mamba_ios_cocoapod_testTests: XCTestCase {
ise-uiuc/Magicoder-OSS-Instruct-75K
input_env_1 = torch.randn((50,)) * 0.2 validation[i] = {'label': 1, 'input': input_env_1}
ise-uiuc/Magicoder-OSS-Instruct-75K
def pip(libraries): def decorator(function): @wraps(function) def wrapper(*args, **kwargs): import subprocess import sys for library, version in libraries.items(): print('Pip Install:', library, version)
ise-uiuc/Magicoder-OSS-Instruct-75K
import re import sys res = ''
ise-uiuc/Magicoder-OSS-Instruct-75K
{ Assert.AreEqual(1, vssdCollection.Count);
ise-uiuc/Magicoder-OSS-Instruct-75K
break result.append(column_name) result.append(space_filling) cur_len += len(column_name) + len(space_filling) if len(result): result[-1] = '' return result def get_user_color_scheme_path(): return os.path.join(subLime.packages_path(), 'User', 'RainbowCSV.sublim...
ise-uiuc/Magicoder-OSS-Instruct-75K
<filename>Seminar 3/src/ro/ase/acs/nosql/DropTable.java package ro.ase.acs.nosql; import ro.ase.acs.contracts.nosqlable.NoSqlMethods; public class DropTable implements NoSqlMethods { @Override public Object nosqlMethod() { return null; }
ise-uiuc/Magicoder-OSS-Instruct-75K
|| idx == self.get_index(center_row+1, center_col-1) || idx == self.get_index(center_row+1, center_col); self.cells.set(idx, enabled); } } } } impl Universe { pub fn get_cells(&self) -> &FixedBitSet { &self.cells }
ise-uiuc/Magicoder-OSS-Instruct-75K
with BytesIO() as output: image.save(output, format='JPEG', quality=quality, optimize=True) return output.getvalue()
ise-uiuc/Magicoder-OSS-Instruct-75K
res = Database.sendMessage("usb_device", "UPDATE_INTERFACES_NUMBER", args) nCDCInstances = Database.getSymbolValue("usb_device_cdc", "CONFIG_USB_DEVICE_CDC_INSTANCES") if nCDCInstances != None: nCDCInstances = nCDCInstances - 1 args = {"cdcInstanceCount": nCDCInstances} res = Database.sendMessage("u...
ise-uiuc/Magicoder-OSS-Instruct-75K
std::process::exit(1); } } fn error(err: String) -> io::Error { io::Error::new(io::ErrorKind::Other, err) } fn run_client() -> io::Result<()> { // First parameter is target URL (mandatory). let url = match env::args().nth(1) { Some(ref url) => Uri::from_str(url).map_err(|e| error(forma...
ise-uiuc/Magicoder-OSS-Instruct-75K
"""Return the unit this state is expressed in.""" return self._unit_of_measurement class SonarrCommandsSensor(SonarrSensor): """Defines a Sonarr Commands sensor.""" def __init__(self, sonarr: Sonarr, entry_id: str) -> None: """Initialize Sonarr Commands sensor."""
ise-uiuc/Magicoder-OSS-Instruct-75K
upperCaseTownNamesCommand.ExecuteNonQuery(); } var townNames = new List<string>(); var getTownsNames = $"SELECT Name FROM Towns WHERE Id IN ({string.Join(", ", townsIds)})"; using (var getTownsNamesCommand = new Sql...
ise-uiuc/Magicoder-OSS-Instruct-75K
MLCMST_Improver::MLCMST_Improver() : MLCMST_Improver(std::make_unique<Star>()) { } MLCMST_Improver::MLCMST_Improver(std::unique_ptr<MLCMST_Solver> init_solver) : init_solver_(std::move(init_solver)) { } network::MLCST MLCMST_Improver::run(const network::MLCCNetwork &mlcc_network) {
ise-uiuc/Magicoder-OSS-Instruct-75K
_mat[10] = p[10]; _mat[11] = p[11]; _mat[12] = p[12]; _mat[13] = p[13]; _mat[14] = p[14]; _mat[15] = p[15]; return *this; } TMatrix44 TMatrix44::operator*=(TMatrix44 &m){ auto tmp = new float[16]; for(int i = 0; i < 4; i++){ for(int j = 0; j < 4; j++){ ...
ise-uiuc/Magicoder-OSS-Instruct-75K
void LavaFloor::Draw(sf::RenderWindow &window) { window.draw(projectile); } bool LavaFloor::CanIgnite() { return true; } int LavaFloor::GetTypeIgnition() { return type_ignition; } float LavaFloor::GetIgnitionDuration() { return duration_ignition; }
ise-uiuc/Magicoder-OSS-Instruct-75K
extern crate bson; extern crate chrono; extern crate clap; #[macro_use] extern crate error_chain; #[macro_use] extern crate log; extern crate serde; #[macro_use] extern crate serde_derive; #[macro_use] extern crate serde_json; extern crate uuid;
ise-uiuc/Magicoder-OSS-Instruct-75K
/// </summary> /// <typeparam name="TItem">The cache type.</typeparam>
ise-uiuc/Magicoder-OSS-Instruct-75K
# 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...
ise-uiuc/Magicoder-OSS-Instruct-75K
lblMusic.setText("-"); lblCostumes.setText("-"); lblSummary.setText("-"); btnSubmit.setDisable(true); tablePlays.getItems().clear();
ise-uiuc/Magicoder-OSS-Instruct-75K
#! /bin/bash killall polybar polybar right &
ise-uiuc/Magicoder-OSS-Instruct-75K
public class p02_Parse_URL { public static void main(String[] args) {
ise-uiuc/Magicoder-OSS-Instruct-75K
# Built-in libraries
ise-uiuc/Magicoder-OSS-Instruct-75K
tally.connect(src.id, dest.id, event.conn_built) start_times = [] snapshots = {port: [] for port in SERVICES}
ise-uiuc/Magicoder-OSS-Instruct-75K
./configure --prefix=/usr
ise-uiuc/Magicoder-OSS-Instruct-75K
# Copy the entire desired "define" row from your language/localized.chat.php, like in the sample below and change the second expression to what you wish to say. # The change will be reflected to all the available languages!!! # Never modify the original language/localized.chat.php, if you want to still be able to app...
ise-uiuc/Magicoder-OSS-Instruct-75K
/** * Adds an {@link ILootModifier} to the current entity that fires only if the entity was killed by a player with the * given weapon, optionally considering its damage and NBT data. * * <p>Additional parameters that further specify the weapon, such as count, are ignored.</p> * *...
ise-uiuc/Magicoder-OSS-Instruct-75K
@Component({ selector: 'cm-studenti-container', templateUrl: './studenti-container.component.html', styleUrls: ['./studenti-container.component.scss'] }) export class StudentiContainerComponent implements OnInit {
ise-uiuc/Magicoder-OSS-Instruct-75K
self.measure() { // Put the code you want to measure the time of here. } }
ise-uiuc/Magicoder-OSS-Instruct-75K
from .core import listen_for_events
ise-uiuc/Magicoder-OSS-Instruct-75K
class MmConfig(AppConfig): name = 'MM'
ise-uiuc/Magicoder-OSS-Instruct-75K
model_name='exposure',
ise-uiuc/Magicoder-OSS-Instruct-75K
err_data += err_chunk, if chan.exit_status_ready(): exit_status = chan.recv_exit_status() if 0 != exit_status or len(err_data) > 0: raise exceptions.SSHExecCommandFailed( command=self.cmd, exit_status=exit_status, ...
ise-uiuc/Magicoder-OSS-Instruct-75K
print('Advertisement registered') def register_ad_error_cb(error): print('Failed to register advertisement: ' + str(error)) mainloop.quit() def main(): global mainloop
ise-uiuc/Magicoder-OSS-Instruct-75K
group_id = **group_id**
ise-uiuc/Magicoder-OSS-Instruct-75K
expect(mockGet).toBeCalledWith( expect.objectContaining({ TableName: process.env.DYNAMO_TABLE, Key: { guid: 'test-guid' } }), expect.anything() ); expect(JSON.parse(response.body)).toMatchObject({ testRecord: true });
ise-uiuc/Magicoder-OSS-Instruct-75K
System.out.println(b.isFemale()); divide("Testing Static Functions"); // testing static functions System.out.println(Person.getOlder(a, b)); Person[] persons = { new Person(1989, "Ken"), new Person(1990, "Charlie"), new Person(1991, "Mike...
ise-uiuc/Magicoder-OSS-Instruct-75K
ANY, CLASS, PROPERTY }
ise-uiuc/Magicoder-OSS-Instruct-75K
'@modern-js-reduck/react', '@modern-js-reduck/store', '@modern-js-block/runtime', '@modern-js-model/runtime', // 星夜区块单独发布的 reduck 版本 '@modern-js-model/reduck-core', '@modern-js/runtime', '@modern-js/runtime-core', '@modern-js/plugin-router', '@modern-js/plugin-state',
ise-uiuc/Magicoder-OSS-Instruct-75K
# DO NOT EDIT: File is generated by code generator. from pokepay_partner_python_sdk.pokepay.request.request import PokepayRequest from pokepay_partner_python_sdk.pokepay.response.shop_with_accounts import ShopWithAccounts class GetShop(PokepayRequest): def __init__(self, shop_id): self.path = "/shops" + ...
ise-uiuc/Magicoder-OSS-Instruct-75K
BtagPerformanceESProducer_TTBARWPBTAGCSVT = cms.ESProducer("BtagPerformanceESProducer", # this is what it makes available ComponentName = cms.string('TTBARWPBTAGCSVT'), # this is where it gets the payload from PayloadName = cms.string('BTagTTBARWPBTAGCSVTtable_v8_...
ise-uiuc/Magicoder-OSS-Instruct-75K
// validate and add row to db public function add(Request $request) { //validate incoming request $this->validate($request, [ 'inventory_id'=> 'required', // 'pharmacy_item_id'=> 'required', 'transaction_type'=> 'required', 'quantity'=> 'requi...
ise-uiuc/Magicoder-OSS-Instruct-75K
var nthDigit = FindNthDigit(number, index);
ise-uiuc/Magicoder-OSS-Instruct-75K
def count_words(s, n): s = s.split(' ') counted_words = [(w, s.count((w))) for w in set(s)] counted_words.sort(key = lambda x: (-x[1], x[0])) top_n = counted_words[:n] return top_n
ise-uiuc/Magicoder-OSS-Instruct-75K
classNames = { 0: 'background', 1: 'person', 2: 'bicycle', 3: 'car', 4: 'motorcycle', 5: 'airplane', 6: 'bus', 7: 'train', 8: 'truck', 9: 'boat', 10: 'traffic light', 11: 'fire hydrant', 13: 'stop sign', 14: 'parking meter', 15: 'bench', 16: 'bird', 17: 'cat', 18: 'dog', 19: 'horse', 20: 'sheep', 21: '...
ise-uiuc/Magicoder-OSS-Instruct-75K
return "If a suspected non-conformity resulted from the non-disclosure of material " + "information by the developer about additional types of costs or fees associated with " + "the Health IT Module, how did the ONC-ACB evaluate the suspected non-conformity?"; } }
ise-uiuc/Magicoder-OSS-Instruct-75K
for a in apps: test_auth_app_db.session.delete(a) test_auth_app_db.session.commit()
ise-uiuc/Magicoder-OSS-Instruct-75K
*/ public $digest;
ise-uiuc/Magicoder-OSS-Instruct-75K
{ self.stack.iter().any(|bs| bs.vars.contains(id)) } pub fn get_failure(&self, name: &Lstr) -> Option<&IfCase> { for b in self.stack.iter().rev() {
ise-uiuc/Magicoder-OSS-Instruct-75K
/** * 跟新categoryname的 * @param session * @param categoryId * @param categoryName * @return */ @RequestMapping(value = "setCategoryName.do",method = RequestMethod.GET)
ise-uiuc/Magicoder-OSS-Instruct-75K
saver_var.restore(sess, restore_file)
ise-uiuc/Magicoder-OSS-Instruct-75K
dataSourceId: string;
ise-uiuc/Magicoder-OSS-Instruct-75K
let users = AsyncUsers::default(); let usersocks = AsyncUserSocks::default(); let socks = AsyncSocks::default(); let cache = AsyncCache::default(); let wsusers = users.clone(); let wspgpool = pgpool.clone();
ise-uiuc/Magicoder-OSS-Instruct-75K
def segmenter_pekkanen(ecg, sampling_rate, window_size=5.0, lfreq=5.0, hfreq=15.0,): """ ECG R peak detection based on `Kathirvel et al. (2001) <http://link.springer.com/article/10.1007/s13239-011-0065-3/fulltext.html>`_ with some tweaks (mainly robust estimation of the rectified signal cutoff threshold). ...
ise-uiuc/Magicoder-OSS-Instruct-75K
override func viewWillAppear(_ animated: Bool) { navigationController?.isToolbarHidden = false if AppDefaults.shared.articleFullscreenEnabled {
ise-uiuc/Magicoder-OSS-Instruct-75K
guard let enumFacade = getMigrationResult( migration: noChange, target: readResource(Resources .ErrorEnumFacadeAddedCase .rawValue) ) as? WrappedEnum else { fatalError("Migration ...
ise-uiuc/Magicoder-OSS-Instruct-75K
input_set.extend(list(ret)) input_set_size = len(input_set) input2idx = dict(zip(input_set, range(input_set_size))) print('Vacabulary size:', input_set_size, '\n') return input2idx, input_set_size def save_vocab(path, input2idx): print('Saving bocabulary...') f = open(path,'wb') pickle.dump(input2idx, f)
ise-uiuc/Magicoder-OSS-Instruct-75K
messaging_text = 'no text' # Echo response = messaging_text bot.send_text_message(sender_id, response)
ise-uiuc/Magicoder-OSS-Instruct-75K
'Corp_id' => '集团id',
ise-uiuc/Magicoder-OSS-Instruct-75K
->withInput(); } } public function logout() { auth()->guard('admin')->logout(); return redirect('/admin/login'); } public function resetarSenhaAdmin(){ return view('auth.passwords.email-admin'); } public function AllresetarSenhaAdmin(){ ...
ise-uiuc/Magicoder-OSS-Instruct-75K
{ return $this->belongsToMany('App\Internshiptool'); } public function statuses () { return $this->belongsTo('App\Status'); }
ise-uiuc/Magicoder-OSS-Instruct-75K
if num > max_num: max_num = num print(max_num)
ise-uiuc/Magicoder-OSS-Instruct-75K
<?php $this->load->view('_partial/footer'); ?>
ise-uiuc/Magicoder-OSS-Instruct-75K
def update(self, episode_num): pass
ise-uiuc/Magicoder-OSS-Instruct-75K
from opticks.ana.base import opticks_main from opticks.analytic.csg import CSG args = opticks_main(csgpath="$TMP/$FUNCNAME", testobject="$(tlens-testobject)", container="$(tlens-container)" ) container = CSG("box", param=[-1,1,0,700], boundary=args.container, poly="MC", nx="20" ) CSG.boundary = args.testobject
ise-uiuc/Magicoder-OSS-Instruct-75K
showDate: false, showTime: !showTime, }) } onPressDate={() =>
ise-uiuc/Magicoder-OSS-Instruct-75K
_virtualUser = null; _requestResults = new RequestResult[logLength]; } #endregion } }
ise-uiuc/Magicoder-OSS-Instruct-75K
def get_percent_change(polo, ticker): '''Computes the 24 hour percentage change.''' polo_data = polo.returnTicker()[ticker] percentageChange = polo_data['percentChange'] print("The 24 hour percentage change is {}".format(percentageChange)) def get_high_low(polo, ticker):
ise-uiuc/Magicoder-OSS-Instruct-75K
xhr.responseType = "arraybuffer"; xhr.send( config !== void 0 && config !== null && config.data !== void 0 && config.data !== null ? config.data : void 0 ); } catch (e) { L...
ise-uiuc/Magicoder-OSS-Instruct-75K
instance.nola = attrs.get('nola', None) instance.is_excluded_from_dfp = attrs.get( 'is_excluded_from_dfp', False ) # see the bottom of the file for notes instance.can_embed_player = attrs.get('can_embed_player', False) instance.language = attrs.get('language', None) instance.funder_mess...
ise-uiuc/Magicoder-OSS-Instruct-75K
'user': 'test-user', 'pass': '<PASSWORD>' } scraper._create_rdbms_connection(connection_args) expected_connection_info = { 'host': 'test-host', 'port': 5433, 'user': 'test-user', 'password': '<PASSWORD>', 'conn...
ise-uiuc/Magicoder-OSS-Instruct-75K
v1_api.register(SentMessageResource()) v1_api.register(TrashMessageResource()) v1_api.register(ProvinceResource()) urlpatterns = patterns('', url(r'^', include(v1_api.urls)), )
ise-uiuc/Magicoder-OSS-Instruct-75K
} return EmptyView() as! Content } static public func buildEither<TrueView:ViewRoot, FalseView:ViewRoot>(trueView:TrueView) -> EirtherView<TrueView,FalseView> {
ise-uiuc/Magicoder-OSS-Instruct-75K
def __repr__(self) -> str: return "From: {}\nSubject: {}".format(self.sender_address, self.subject)
ise-uiuc/Magicoder-OSS-Instruct-75K
argparser.add_argument("--cnn", action='store_true', help="whether to use cnn") argparser.add_argument("--lstm", action='store_true', help="whether to use lstm") argparser.add_argument("--dataset", type=str, default="mr", help="which dataset") argparser.add_argument("--embedding", type=str, required=Tru...
ise-uiuc/Magicoder-OSS-Instruct-75K
showBalance?: boolean; }) => JSX.Element; //# sourceMappingURL=index.d.ts.map
ise-uiuc/Magicoder-OSS-Instruct-75K
<p>Northern Territory: Open to everywhere but Victoria and Sydney, which must do hotel quarantine</p> <p>South Australia: Closed to Victoria, NSW arrivals must self-isolate, rest are open</p> <p>Tasmania: Closed to Victoria, everywhere else must do hotel quarantine</p> <p>Western Australia: Closed to everywhere with...
ise-uiuc/Magicoder-OSS-Instruct-75K
from ..tag2label import prepare_df_from_dirs def prepare_dataset(): shutil.rmtree('datasets', ignore_errors=True) # dummy datasets e.g. root1 and root2 root1 = Path('datasets/root1') root1.mkdir(parents=True, exist_ok=True) root2 = Path('datasets/root2') root2.mkdir(parents=True, exist_ok=Tru...
ise-uiuc/Magicoder-OSS-Instruct-75K
default_next_question_key=self._ANY_DEFAULT_NEXT_QUESTION_KEY, ) def test_creating_questions(self): q = Question(text=self._ANY_TEXT, key=self._ANY_KEY) self.assertEqual(q.text, self._ANY_TEXT) self.assertEqual(q.key, self._ANY_KEY) self.assertEqual(q.default_ans...
ise-uiuc/Magicoder-OSS-Instruct-75K
public IEnumerable<Domain.Models.Epic> GetEpicsSubscribedTo(int subscriberID) { var subscriptions = _context.Subscriptions.Include(w => w.Writer).ThenInclude(r => r.RoleNavigation).Include(s => s.Subscriber).Where(s => s.SubscriberId == subscriberID); var m_subscriptions = subsc...
ise-uiuc/Magicoder-OSS-Instruct-75K