seed
stringlengths
1
14k
source
stringclasses
2 values
Rect rect = GUILayoutUtility.GetRect(content, style); // Right click if (DetectClickInRect(rect, 1)) { optionsPressed = true;
ise-uiuc/Magicoder-OSS-Instruct-75K
main: './src/main/index.ts' }, output: { path: path.resolve(__dirname, 'dist'), filename: '[name].js' }, module: { rules: [ { test: /\.worker\.ts$/,
ise-uiuc/Magicoder-OSS-Instruct-75K
input_vertex_id += 1 elif identifier == "f": data = [int(val) for val in data]
ise-uiuc/Magicoder-OSS-Instruct-75K
git commit -m "[build] $VERSION" npm version $VERSION --message "[release] $VERSION" git push origin master #publish
ise-uiuc/Magicoder-OSS-Instruct-75K
import Cocoa class ViewController: NSViewController { static func freshController() -> ViewController { let storyboard = NSStoryboard(name: "Main", bundle: nil) let identifier: NSStoryboard.SceneIdentifier = "ViewController"
ise-uiuc/Magicoder-OSS-Instruct-75K
typedef long long ll;
ise-uiuc/Magicoder-OSS-Instruct-75K
""" :return: A list of CSHMember instances """ if self.ldap: return self.ldap.get_group(group).get_members() else: return list(filter(lambda member: group in member.groups, self.mock_members))
ise-uiuc/Magicoder-OSS-Instruct-75K
# console.log("function name") is added to all functions # # running counts are added to mithril.js methods m.redraw() and m.render() sjs --readable-names -m ./mithril_pxp_macros.sjs -o ./mithril_pxp.js node_modules/mithril/mithril.js
ise-uiuc/Magicoder-OSS-Instruct-75K
# buttonm = QPushButton('-', self) # buttonm.setToolTip('Subtraction Operator') # buttonm.move(100,100) # buttonm.clicked.connect(self.on_click) self.show() def createGridLayout(self): self.horizontalGroupBox = QGroupBox("Grid") layout = QGrid...
ise-uiuc/Magicoder-OSS-Instruct-75K
cd ~/ git clone --depth 1 --branch blead git://perl5.git.perl.org/perl.git cd perl
ise-uiuc/Magicoder-OSS-Instruct-75K
Each dataset has bug report ids and the ids of duplicate bug reports. """ class BugDataset(object): def __init__(self, file): f = open(file, 'r') self.info = f.readline().strip()
ise-uiuc/Magicoder-OSS-Instruct-75K
cx.graphics.wait_fences(&mut [fence], true); cx.graphics.reset_fences(&mut [fence]); } let camera = viewport.camera();
ise-uiuc/Magicoder-OSS-Instruct-75K
sale_way_choice = ( (0, '一口价'), (1, '拍卖'), ) is_new_choice = ( (0, '非全新'),
ise-uiuc/Magicoder-OSS-Instruct-75K
load_from_paths, load_original_text_from_directory, load_transcription_text_from_directory, )
ise-uiuc/Magicoder-OSS-Instruct-75K
fn main() { let (M, D): (i64, i64) = { let mut line: String = String::new(); std::io::stdin().read_line(&mut line).unwrap(); let mut iter = line.split_whitespace(); ( iter.next().unwrap().parse().unwrap(), iter.next().unwrap().parse().unwrap()
ise-uiuc/Magicoder-OSS-Instruct-75K
import java.util.ArrayList; import java.util.List; /** * Created by ITON Solutions on 8/21/16. */ public class EMContact extends EntityModel <ETContact, Integer>{ public EMContact(EntityManagerFactory emf) {
ise-uiuc/Magicoder-OSS-Instruct-75K
freqs = number.CategoryFreqs()
ise-uiuc/Magicoder-OSS-Instruct-75K
// Created by Daniel Saidi on 2021-09-02. // Copyright © 2020 Daniel Saidi. All rights reserved. // import Combine import SwiftUI public extension View { /** This modifier can be applied to a view, to make it call
ise-uiuc/Magicoder-OSS-Instruct-75K
def HasResistance(seq): retval = [] if HasCmR(seq): retval.append( 'CmR' ) if HasKanR(seq): retval.append('KanR') if HasAmpR(seq):
ise-uiuc/Magicoder-OSS-Instruct-75K
from pyvisdk.thirdparty import Enum FileSystemInterfaceVersion = Enum( 'NFSV3_0', )
ise-uiuc/Magicoder-OSS-Instruct-75K
void Fuzz::next(SkRegion* region) { // See FuzzCommon.h FuzzNiceRegion(this, region, 10); } void Fuzz::nextRange(float* f, float min, float max) {
ise-uiuc/Magicoder-OSS-Instruct-75K
repeat_eos_u4 = Struct( 'numbers' / GreedyRange(Int32ul), )
ise-uiuc/Magicoder-OSS-Instruct-75K
# you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0
ise-uiuc/Magicoder-OSS-Instruct-75K
def command(prefix, cmd): print ('{:}{:}'.format(prefix, cmd)) os.system(cmd) def main(source, destination, xtype): assert source.exists(), '{:} does not exist'.format(source) assert (source/'train').exists(), '{:}/train does not exist'.format(source)
ise-uiuc/Magicoder-OSS-Instruct-75K
"previous": None,
ise-uiuc/Magicoder-OSS-Instruct-75K
public int getCode() { return code; } public void setCode(int code)
ise-uiuc/Magicoder-OSS-Instruct-75K
from rest_framework import serializers from .models import AccountsUser
ise-uiuc/Magicoder-OSS-Instruct-75K
public void positiveFlow_setBids_adTargetingIntegralIsViewability_viewabilityDtoNotNull() throws Exception { TargetingIntegral tiMock = PowerMockito.mock(TargetingIntegral.class); Mockito.when(tiMock.isViewability()).thenReturn(true); PowerMockito.doReturn(new IntegralVa...
ise-uiuc/Magicoder-OSS-Instruct-75K
Given a data source (either a string or a DataSource object) and a string model name this function will generate a GeoDjango model. Usage: >>> from django.contrib.gis.utils import ogrinspect
ise-uiuc/Magicoder-OSS-Instruct-75K
def loadTexture(data, ix, iy): glPixelStorei(GL_UNPACK_ALIGNMENT,1) glTexImage2D(GL_TEXTURE_2D, 0, GL_RGB, ix, iy, 0, GL_RGB, GL_UNSIGNED_BYTE, data) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP) glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP)
ise-uiuc/Magicoder-OSS-Instruct-75K
import javax.servlet.http.HttpServletResponse; import java.io.IOException;
ise-uiuc/Magicoder-OSS-Instruct-75K
raise NotImplementedError def docs(self, f): with lzma.open(f) as infile: docs = [json.loads(l.decode('utf-8')) for l in infile] docs = [self.extract_text(r) for r in docs] docs = self.langdetect.pipe(docs, batch_size=1000, n_threads=5) docs = [doc.text for doc i...
ise-uiuc/Magicoder-OSS-Instruct-75K
# 1 se afla in lista 1 si 4, 2 se afla in lista 1 si 2, 3 in 1 si 2. """ lists = [list(x) for x in args[0:-1]] x = args[-1] all_elements = [] distinct_elements = [] for lst in lists: all_elements = list_all_elements(all_elements, lst) distinct_elements = list_reunion(distinc...
ise-uiuc/Magicoder-OSS-Instruct-75K
const governance = GovernanceCanister.create({ certifiedServiceOverride: service, serviceOverride: service, }); const rawProposal = { id: [{ id: 1n }], ballots: [], proposal: [], proposer: [], latest_tally: [],
ise-uiuc/Magicoder-OSS-Instruct-75K
for i in usage.instances: # this is just a way to phrase uptime in a way that is compatible # with the 'timesince' filter. Use of local time intentional i['uptime_at'] = now - datetime.timedelta(seconds=i['uptime']) if i['ended_at']: terminated_in...
ise-uiuc/Magicoder-OSS-Instruct-75K
# This should only happen when no libraries are shared logger.warning(f"Skipped User with No Libraries Shared: {user.username}") continue
ise-uiuc/Magicoder-OSS-Instruct-75K
import { AxiosRequestConfig } from "./types"; import {processHeaders} from './helpers/headers'
ise-uiuc/Magicoder-OSS-Instruct-75K
} void ConnectionsHandler::handleGETRequest( Poco::Net::HTTPServerRequest &request,
ise-uiuc/Magicoder-OSS-Instruct-75K
default: return this.wrapWithSparkLineButton(valueModel, BasicComponentFactory.createIntegerField(valueModel, new ZeroNumberFormat(NumberFormat.getIntegerInstance()))); } }
ise-uiuc/Magicoder-OSS-Instruct-75K
""" from aeroport.abc import AbstractPayload, AbstractField class Field(AbstractField): """Container of field metadata""" class Payload(AbstractPayload):
ise-uiuc/Magicoder-OSS-Instruct-75K
export { DeleteTaskService };
ise-uiuc/Magicoder-OSS-Instruct-75K
NEAREST = 0 BILINEAR = 1 BICUBIC = 2 @classmethod def get(cls, value: Union[str, int, T]) -> T: # type: ignore if type(value) == str: return cls[value.upper()] # type: ignore
ise-uiuc/Magicoder-OSS-Instruct-75K
func configure(viewModel: SelectionViewModel, output: SelectionModuleOutput?) func dismiss() }
ise-uiuc/Magicoder-OSS-Instruct-75K
size[1]="1000000"
ise-uiuc/Magicoder-OSS-Instruct-75K
fn available_native_type_constructors(&self) -> &'static [dml::native_type_constructor::NativeTypeConstructor] { NATIVE_TYPE_CONSTRUCTORS } fn default_native_type_for_scalar_type(&self, scalar_type: &dml::scalars::ScalarType) -> serde_json::Value { let native_type = default_for(scalar_type...
ise-uiuc/Magicoder-OSS-Instruct-75K
kubectl --namespace ghcn create configmap ghcn-conf --from-file=../config.yml --from-file=../override.yml
ise-uiuc/Magicoder-OSS-Instruct-75K
// furnished to do so, subject to the following conditions: // The above copyright notice and this permission notice shall be included in all
ise-uiuc/Magicoder-OSS-Instruct-75K
mkdir -p "${DATA_PATH}/conf" echo fi if [ ! -f "${DATA_PATH}/conf/options-ssl-nginx.conf" ]; then echo -e "### Downloading missing options-ssl-nginx.conf: ${DATA_PATH}/conf/options-ssl-nginx.conf ... " curl -s https://raw.githubusercontent.com/certbot/certbot/master/certbot-nginx/certbot_nginx/tls_configs/opt...
ise-uiuc/Magicoder-OSS-Instruct-75K
class B{deinit{class b<T where T:j{class a
ise-uiuc/Magicoder-OSS-Instruct-75K
<gh_stars>0 __all__ = ["search", "download","lyrics", "patches"]
ise-uiuc/Magicoder-OSS-Instruct-75K
* This will train the model on the training set: $ pyannote-audio sad train ${PWD} ${DATABASE}
ise-uiuc/Magicoder-OSS-Instruct-75K
import { RuntimeError } from './runtime-error';
ise-uiuc/Magicoder-OSS-Instruct-75K
* 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....
ise-uiuc/Magicoder-OSS-Instruct-75K
export class Project { public id: number; public code: string; public displayName: string; public releaseDate: Date; public posterUrl: string; public posterDescription: string; public category: Category; public description: string; public descriptionShort: string;
ise-uiuc/Magicoder-OSS-Instruct-75K
rm -f wave.out set restart_file=`ls -ld * | awk '/snapshot0/ {{ print $9 }}' | tail -n1` ln -s -f $restart_file wave.out rm -f running echo ' ' > queued """
ise-uiuc/Magicoder-OSS-Instruct-75K
public Any exec(Any a) throws AnyException { final AnyDocument doc = (AnyDocument)EvalExpr.evalFunc(getTransaction(), a, doc_, AnyDocument.class); final StringI layoutSt...
ise-uiuc/Magicoder-OSS-Instruct-75K
global LDAP LDAP = LDAPConnector() processor = Processor() processor.load_files(alias_files) if CONFIG["main"].getboolean("check_syntax_only"): print("Done with syntax check. Not doing anything else.") return
ise-uiuc/Magicoder-OSS-Instruct-75K
board=[[nan, nan], [9, nan]], label='won'
ise-uiuc/Magicoder-OSS-Instruct-75K
c0 = up_down.count(0) p1 = c1 / len(up_down) p0 = c0 / len(up_down) print('likehood(goes up, binom):' + str(binom.pmf(c1, len(up_down), p1))) print(binom.pmf(c0, len(up_down), p0)) p_grid, posterior = grid_approx.compute(up_down, 1) plt.plot(p_grid, posterior) plt.show()
ise-uiuc/Magicoder-OSS-Instruct-75K
and len(transfers_in) == 1 and transfers_in[0][0] == 1): return True else: return False def handle_nft_mint(exporter, txinfo): transfers_in, transfers_out, transfers_unknown = txinfo.transfers_net if len(transfers_in) == 1 and len(transfers_out) == 1: sent_amou...
ise-uiuc/Magicoder-OSS-Instruct-75K
@inlinable @inline(__always) public init(color: Model.Float32Components, opacity: Float = 1) { self._color = color self._opacity = opacity
ise-uiuc/Magicoder-OSS-Instruct-75K
order_scene 场景订单场景类型,1:常规订单,2:渠道订单,3:会员运营订单,默认为1 signurl 1:使用淘宝联盟的http链接 2:使用淘宝联盟的https链接
ise-uiuc/Magicoder-OSS-Instruct-75K
frame = wx.Frame(None, wx.ID_ANY, "Hello, World") frame.Show(True) app.MainLoop()
ise-uiuc/Magicoder-OSS-Instruct-75K
-X MKCOL -i -k #-------------------------------------------------------------------- # /davコレクション内に、スライドショー用のサブコレクション(slideshow)を作成 #-------------------------------------------------------------------- curl "https://${_server}/${_cell}/${_box}/dav/slideshow" \ -d "<?xml version=\"1.0\" encoding=\"utf-8\"?><D:mkcol xml...
ise-uiuc/Magicoder-OSS-Instruct-75K
plt.title("Slice 2") curr_data = data_sample2[marker].values curr_data = (curr_data - curr_data.mean()) / curr_data.std() plt.scatter( data_sample2["xcoord"],
ise-uiuc/Magicoder-OSS-Instruct-75K
<reponame>INaCloud/Dockstarter-DSAC #!/usr/bin/env bash set -euo pipefail IFS=$'\n\t'
ise-uiuc/Magicoder-OSS-Instruct-75K
r, addr = sock.recvfrom(Config.Buffer_Size) swapped_string = s2.split(Config.Separator)[1] + s1.split(Config.Separator)[1] returned_string = Config.decrypt(r.decode(Config.Enc_Type)) print("[**] Server replies with encrypted r=%s" % r) print("[***] Decrypted result r=%s" % return...
ise-uiuc/Magicoder-OSS-Instruct-75K
product = menu.list_promt('product', 'Which product do you need?', choices).get('product') product_key = f'{product[0]}@{product[1]}' return product_path_dict[product_key]
ise-uiuc/Magicoder-OSS-Instruct-75K
* SOFTWARE. */ package hu.nemes.projecteuler.page1; import hu.nemes.projecteuler.common.Primes; import java.util.AbstractMap; import java.util.Comparator; import java.util.Map; import java.util.concurrent.Callable; import java.util.function.LongSupplier;
ise-uiuc/Magicoder-OSS-Instruct-75K
print "FileThumbnailUrl=%s" % thumbnail_filepath.replace(thumbnail_root_dir, thumbnails_root_url)
ise-uiuc/Magicoder-OSS-Instruct-75K
<reponame>gyratory/NPTfP3 # This program demonstrates the use of the == operator using numbers print (5 == 6) # Using variables x = 5
ise-uiuc/Magicoder-OSS-Instruct-75K
DEFAULT_STRATEGIES = [ [['ror_name', 'ror_acronym', 'ror_city', 'ror_country']], [['ror_name', 'ror_city', 'ror_country']] ]
ise-uiuc/Magicoder-OSS-Instruct-75K
config = load_config(config_params) # Optimise mf_opt_val, mf_opt_pt, history = maximise_multifidelity_function(snls_mf_objective,
ise-uiuc/Magicoder-OSS-Instruct-75K
class Command(uWSGICommand): help = "Start Nautobot uWSGI server."
ise-uiuc/Magicoder-OSS-Instruct-75K
{ static $var = "hello"; return $var; } // the value we get is "hello" $byref_initial = config_byref(); // let's change the value $byref_initial = "world"; // Let's get the value again and see echo "Byref, new value: " . config_byref() . "\n"; // We still get "hello"
ise-uiuc/Magicoder-OSS-Instruct-75K
id = db.Column(db.Integer, primary_key=True) username = db.Column(db.String(150), nullable=False, unique=True) password = db.Column(db.String(150), nullable=False) balance = db.Column(db.Float(44)) class Transaction(db.Model): __tablename__ = "transaction" id = db.Column(db.Integer, primary_ke...
ise-uiuc/Magicoder-OSS-Instruct-75K
other.bare_jid == self.bare_jid and other.device == self.device ) def __hash__(self): return hash((self.bare_jid, self.device)) def __str__(self): return ( "The initial key exchange with {} on device {} failed: {}" .format(self.__bare_jid...
ise-uiuc/Magicoder-OSS-Instruct-75K
print("VAR is '{}'".format(os.environ["VAR"]))
ise-uiuc/Magicoder-OSS-Instruct-75K
prepend = lambda x: "+- " + x if x != "" else x stats[name + "_std_formatted"] = fmt_std.apply(prepend)
ise-uiuc/Magicoder-OSS-Instruct-75K
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Copyright (c) 2017 <NAME>
ise-uiuc/Magicoder-OSS-Instruct-75K
*/ private $required; /** * @var mixed The default value can be of any type */ private $defaultValue; public function __construct(string $name, bool $required, $defaultValue = null)
ise-uiuc/Magicoder-OSS-Instruct-75K
DQMStore = cms.untracked.bool(True), disableROOToutput = cms.untracked.bool(True), filterTriggerType = cms.int32(1) )
ise-uiuc/Magicoder-OSS-Instruct-75K
from . import edgetpu, openvino, onnx
ise-uiuc/Magicoder-OSS-Instruct-75K
'firewall_mode': {'required': True}, 'rule_set_type': {'required': True}, 'rule_set_version': {'required': True}, 'max_request_body_size': {'maximum': 128, 'minimum': 8}, 'max_request_body_size_in_kb': {'maximum': 128, 'minimum': 8}, 'file_upload_limit_in_mb': {'maximum':...
ise-uiuc/Magicoder-OSS-Instruct-75K
public static void Main(string[] args) { BuildWebHost(args) .MigrateDbContext<APIDbContext>((db, services) => db.Seed(services)) .Run(); } public static IWebHost BuildWebHost(string[] args) {
ise-uiuc/Magicoder-OSS-Instruct-75K
variables_lib2.local_variable(value1) variables = variables_lib.local_variables() self.assertEquals(2, len(variables)) self.assertRaises(errors_impl.OpError, sess.run, variables) variables_lib.variables_initializer(variables).run() self.assertAllEqual(set([value0, value1]), set(...
ise-uiuc/Magicoder-OSS-Instruct-75K
self.pooler = nn.Sequential( nn.Linear(model_config.hidden_size * 2, 200), nn.Linear(200, 2) ) self.loss_func = nn.CrossEntropyLoss(ignore_index=-100) def forward( self, input_ids=None, attention_mask=None, token_type_ids=None, position_ids=...
ise-uiuc/Magicoder-OSS-Instruct-75K
self.model = None
ise-uiuc/Magicoder-OSS-Instruct-75K
return solution; }
ise-uiuc/Magicoder-OSS-Instruct-75K
<gh_stars>1-10 #!/bin/bash -eu yarn lerna run clean --scope=fixture-injection yarn lerna run clean --scope=jest-fixture-injection
ise-uiuc/Magicoder-OSS-Instruct-75K
if [ "$#" -ne 1 ]; then echo "usage: $0 amount (IOTX)" exit
ise-uiuc/Magicoder-OSS-Instruct-75K
public DateTimeOffset DateAdded { get; set; } public string Image { get; set; } public decimal Weight { get; set; } public decimal Price { get; set; }
ise-uiuc/Magicoder-OSS-Instruct-75K
<div id="category-rabbits" class="pet-category"> <a class="round-button" href="<?php echo base_url()?>index.php/CustomPet_ctr" alt="Rabbit">Rabbits</a> </div>
ise-uiuc/Magicoder-OSS-Instruct-75K
"Upgrade-Insecure-Requests": "1", } seeds = ["https://www.sjtu.edu.cn/", "http://www.jwc.sjtu.edu.cn/", "http://www.seiee.sjtu.edu.cn/", ] domains = [ "news.sjtu.edu.cn", "www.sjtu.edu.cn", "jwc.sjtu.edu.cn", "seiee.sjtu.edu.cn", ]
ise-uiuc/Magicoder-OSS-Instruct-75K
or (expectSuccess != True and expectSuccess != False)): print('whenISubmitAPaymentRequest: invalid parameters') assert(False) try: hash = node.createpaymentrequest(hash, amount, description)["hash"] except JSONRPCException as e:
ise-uiuc/Magicoder-OSS-Instruct-75K
} /// Creates a dynamic `MoveX` event with the timestamps and the X positions of the element /// /// Uses a `Linear` easing /// /// Example: /// ``` /// use osb::Sprite;
ise-uiuc/Magicoder-OSS-Instruct-75K
// This method does not account for codepoint boundaries. If encoding a string, consider using EncodeString int EncodeBytes(byte[] buffer, int offset, int count); int EncodeString(string value, Encoding encoding);
ise-uiuc/Magicoder-OSS-Instruct-75K
# TODO: think of clever caching trickery: cache_file = None if cache_file and os.path.exists(cache_file): logger.info('Using cached object from %s', cache_file) with shelve.open(cache_file) as s: obj = s['obj'] ppci_module = s['ppci_module'] else: # TODO: ...
ise-uiuc/Magicoder-OSS-Instruct-75K
using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; namespace _03.ShowFromOneTextBoxInAnother { public partial class Index : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { }
ise-uiuc/Magicoder-OSS-Instruct-75K
polygonInspector.currentEdgeIndex = edge.previousEdge.index; edge = polygon.edges[polygonInspector.currentEdgeIndex]; ShowUpEdges(edge); } if (GUILayout.Button("Show up ("+polygonInspector.currentEdgeIndex.ToString()+")")) { ShowUpEdges(edge); } if (GUILayout.Button("+")) {
ise-uiuc/Magicoder-OSS-Instruct-75K