seed
stringlengths
1
14k
source
stringclasses
2 values
def save_coordinates(self, path: str) -> None:
ise-uiuc/Magicoder-OSS-Instruct-75K
public boolean canPassThrough() { return true; } @Override
ise-uiuc/Magicoder-OSS-Instruct-75K
key } // 保存内容 localStorage.setItem(key, JSON.stringify(articleData)) } if (typeof callback === 'function') { // 执行回调函数:把新的值传给callBack callback(err) } })
ise-uiuc/Magicoder-OSS-Instruct-75K
name = "Ensure EKS Cluster has Secrets Encryption Enabled" id = "CKV_AWS_58" supported_resources = ['aws_eks_cluster'] categories = [CheckCategories.KUBERNETES] super().__init__(name=name, id=id, categories=categories, supported_resources=supported_resources) def scan_resource_conf(self, conf): if "encryption_config" in conf.keys() and "resources" in conf["encryption_config"][0] and \ "secrets" in conf["encryption_config"][0]["resources"][0]: return CheckResult.PASSED else: return CheckResult.FAILED
ise-uiuc/Magicoder-OSS-Instruct-75K
#include <boost/vmd/is_number.hpp>
ise-uiuc/Magicoder-OSS-Instruct-75K
@staticmethod def read_xyztype(bytes, offset, count): sig = IccProfile.read_string(bytes, offset, 4) assert(IccProfile.read_int(bytes, offset+4) == 0) # todo: repeat xyz for remainder of xyztype bytes xyz = IccProfile.read_xyznumber(bytes, offset+8)
ise-uiuc/Magicoder-OSS-Instruct-75K
return render(request, "hello/greet.html", { "name": name.capitalize() })
ise-uiuc/Magicoder-OSS-Instruct-75K
RUN apk add --update build-base postgresql-dev sqlite-dev mariadb-dev nodejs tzdata 1>/dev/null
ise-uiuc/Magicoder-OSS-Instruct-75K
writer.Close() with debug_events_reader.DebugDataReader(self.dump_root) as reader: reader.update() traces = reader.graph_execution_traces(begin=begin, end=end) self.assertLen(traces, expected_end - expected_begin) self.assertEqual(traces[0].op_name, "Op_%d" % expected_begin) self.assertEqual(traces[-1].op_name, "Op_%d" % (expected_end - 1))
ise-uiuc/Magicoder-OSS-Instruct-75K
from dataset.hcp.dwi.dwi import HcpDwiProcessor from fwk.config import Config class DwiProcessorScript:
ise-uiuc/Magicoder-OSS-Instruct-75K
/// Left-Right-Center-Surround. LeftRightCenterSurround = 0x0107, } impl Into<WrappedBitFlags<Version1LogicalAudioChannelSpatialLocation>> for DolbyProLogicMode { #[inline(always)] fn into(self) -> WrappedBitFlags<Version1LogicalAudioChannelSpatialLocation> {
ise-uiuc/Magicoder-OSS-Instruct-75K
('area', '0003_alter_profile_profile_pic'), ] operations = [ migrations.AlterField( model_name='area', name='admin', field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='admin', to='area.profile'), ), migrations.AlterField( model_name='area', name='hoodimage',
ise-uiuc/Magicoder-OSS-Instruct-75K
import multiprocessing import numpy as np a = time.time() cores = multiprocessing.cpu_count() pool = multiprocessing.Pool(processes=cores) cnt = 0 pi = [None] * t
ise-uiuc/Magicoder-OSS-Instruct-75K
{ return Textures[name]; } void ResourceManager::Clear() { // (Properly) delete all shaders for (auto iter : Shaders) glDeleteProgram(iter.second.ID); // (Properly) delete all textures for (auto iter : Textures) glDeleteTextures(1, &iter.second.ID); } Shader ResourceManager::loadShaderFromFile(const GLchar *vShaderFile, const GLchar *fShaderFile, const GLchar *gShaderFile)
ise-uiuc/Magicoder-OSS-Instruct-75K
# config self.rknn.config(batch_size=1, mean_values=[self.mean], std_values=[self.std], reorder_channel='0 1 2', target_platform=self.device, quantized_dtype=quantized_dtype ) # parse model if model_type == "darknet":
ise-uiuc/Magicoder-OSS-Instruct-75K
/// - Parameters: /// - merge: indicator if `memory` content, once sent to CAI, shall be added to the current state of the memory or if the content shall replace the current memory
ise-uiuc/Magicoder-OSS-Instruct-75K
radiusSqr = _radius * _radius;
ise-uiuc/Magicoder-OSS-Instruct-75K
# # Professor: <NAME> # Autores: # - MatheusRV (3929)
ise-uiuc/Magicoder-OSS-Instruct-75K
($( $l:expr ),*) => { concat!("\x1B[", $( $l ),*) }; }
ise-uiuc/Magicoder-OSS-Instruct-75K
+ str(len(dict_to_print)) + " --> " + str(sum(dict_to_print.values())) + " elements ", "green", ) ) def print_debug(message):
ise-uiuc/Magicoder-OSS-Instruct-75K
{ /// <summary> /// Manages visibility of the gameobject. /// </summary> [RequireComponent(typeof(CanvasGroup))] public class Menu : MonoBehaviour, IMenu { #region Fields /// <summary> /// Reference to <see cref="UnityEngine.CanvasGroup"/> used to show or hide the gameobject. /// </summary> private CanvasGroup _canvasGroup; [SerializeField] private LeanButton backButton;
ise-uiuc/Magicoder-OSS-Instruct-75K
<form action="results.php" method="get"> <span class="title">D V D &nbsp; T I T L E :</span> <br><br> <input type="text" name="dvd_title">
ise-uiuc/Magicoder-OSS-Instruct-75K
from forte.data.multi_pack import * from forte.data.container import *
ise-uiuc/Magicoder-OSS-Instruct-75K
def get_data(self): # load the data # the text reviews have already been converted to numerical features (x_train, y_train), (x_test, y_test) = tf.keras.datasets.imdb.load_data() # pad all sequences to the same length pad_length = 1000 x_train = pad_sequences(x_train, pad_length) x_test = pad_sequences(x_test, pad_length) return (x_train, y_train), (x_test, y_test)
ise-uiuc/Magicoder-OSS-Instruct-75K
} #[test] fn test() { #[cfg(feature = "a")] assert!(!func(1)); #[cfg(feature = "b")] assert!(func(-1)); }
ise-uiuc/Magicoder-OSS-Instruct-75K
conv1 = create_conv2d_layer(input, 'conv1', parameters['w1'], parameters['b1']) conv2 = create_conv2d_layer(conv1, 'conv2', parameters['w2'], parameters['b2']) pool1 = tf.nn.max_pool(conv2, ksize=[1, 3, 3, 1], strides=[1, 2, 2, 1], padding='SAME', name='pool1') conv3 = create_conv2d_layer(pool1, 'conv3', parameters['w3'], parameters['b3'])
ise-uiuc/Magicoder-OSS-Instruct-75K
def is_prime(n): return not re.match(r'^.?$|^(..+?)\1+$', '1'*n)
ise-uiuc/Magicoder-OSS-Instruct-75K
namespace spec\loophp\phptree\Exporter; use Graphp\GraphViz\GraphViz; use loophp\phptree\Exporter\Graph; use loophp\phptree\Importer\Text; use loophp\phptree\Node\AttributeNode; use loophp\phptree\Node\ValueNode;
ise-uiuc/Magicoder-OSS-Instruct-75K
('BEING_BODY', 49, 'телосложение', tt_beings_relations.BODY, True), ('BEING_SIZE', 50, 'размер', tt_beings_relations.SIZE, True), ('BEING_ORIENTATION', 51, 'положение тела', tt_beings_relations.ORIENTATION, True), ('UPBRINGING', 52, 'воспитание', tt_beings_relations.UPBRINGING, True), ('FIRST_DEATH', 53, 'первая смерть', tt_beings_relations.FIRST_DEATH, True), ('AGE', 54, 'возраст в котором умер', tt_beings_relations.AGE, False), ('CLAN_MEMBERSHIP', 55, 'членство в гильдии', heroes_relations.CLAN_MEMBERSHIP, True)) def get(value): restriction_groups = GROUP.index_static_relation[value._relation]
ise-uiuc/Magicoder-OSS-Instruct-75K
options["manual"] = {'flag':'manual', 'msg':"Manual control of attack rate increments"} print "Pick either of the following options: " for K in options: if K not in ['continue', 'decrease', 'manual']: print "- [", K, "] ", options[K]['msg'] while True:
ise-uiuc/Magicoder-OSS-Instruct-75K
l2=open(f2).readlines() r=[lin1.strip()+" "+lin2.strip()+" "+lin3 for lin1,lin2,lin3 in zip(l1,l2[:400],l2[400:])] with open(w,"w") as fout:
ise-uiuc/Magicoder-OSS-Instruct-75K
def get_args(): ap = argparse.ArgumentParser(description='Query a CloudFormation stack for build and template parameters', add_help=False) ap.add_argument('stack_name',
ise-uiuc/Magicoder-OSS-Instruct-75K
/** * A factory method that creates a new instance of this class from an object * containing the properties of this ROS resource, which will be assigned to ROS resource. */
ise-uiuc/Magicoder-OSS-Instruct-75K
func applicationWillTerminate(application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. }
ise-uiuc/Magicoder-OSS-Instruct-75K
result += sq_sum[n % 1000] n //= 1000 return result sq_sum = [sum(int(c)**2 for c in str(i)) for i in range(1000)] if __name__ == "__main__": print(calculate())
ise-uiuc/Magicoder-OSS-Instruct-75K
<div class="entry-header"> <h1>Opps! Nu exista produse dupa criteriile selectate.</h1> </div> <div class="image-404"><img alt="" src="<?= asset('assets/img404.png') ?>"></div> <div class="form404-wrapper"> <div class="container"> <a title="Back to homepage" href="<?= route('home') ?>">Back to homepage</a> </div> </div> </div> <?php
ise-uiuc/Magicoder-OSS-Instruct-75K
rm -rf ./e2e/downloads/ rm -rf ./e2e-output/screenshots/ export URL_HOST_ADF=$HOST export USERNAME_ADF=$USERNAME export PASSWORD_ADF=$PASSWORD export EMAIL_ADF=$EMAIL export BROWSER_RUN=$BROWSER_RUN export PROXY_HOST_ADF=$PROXY export SAVE_SCREENSHOT=$SAVE_SCREENSHOT export TIMEOUT=$TIMEOUT export FOLDER=$FOLDER'/' export SELENIUM_SERVER=$SELENIUM_SERVER
ise-uiuc/Magicoder-OSS-Instruct-75K
/// <param name="deviceId">Device identifier.</param> /// <param name="messageId">Message identifier.</param> public DeviceMessageLockLostException(string deviceId, Guid messageId) : base("Message {0} lock was lost for Device {1}".FormatInvariant(messageId, deviceId)) { } #if !WINDOWS_UWP && !PCL /// <summary> /// Initializes a new instance of the <see cref="DeviceMessageLockLostException"/> class with the specified serialization and context information.
ise-uiuc/Magicoder-OSS-Instruct-75K
collectionCommands $1 $2 ;; "arrikitaun" ) echo "Have a nice day!" ;; * ) usage ;; esac # Unload al security variables unset PASSPHRASE
ise-uiuc/Magicoder-OSS-Instruct-75K
id_type acquireId(); void freeId(id_parameter id); std::size_t usedIdCount() const; private: std::mutex protect_; std::set <id_type> freeIds_; id_type increment_; }; }
ise-uiuc/Magicoder-OSS-Instruct-75K
public interface SipChannelInterceptor { }
ise-uiuc/Magicoder-OSS-Instruct-75K
// Otherwise request access and callback with the new status. requestAuthorization { newStatus in result(.success(newStatus == .authorized)) } } }
ise-uiuc/Magicoder-OSS-Instruct-75K
if __name__ == "__main__": '''Program entrance.''' global_config.config_logging('../log/app.log') __execute(sys.argv[1:])
ise-uiuc/Magicoder-OSS-Instruct-75K
audio_file = models.FileField(default='') song_visibility = models.CharField(max_length=100, default="private") is_favorite = models.BooleanField(default=False) def __str__(self): return self.song_title
ise-uiuc/Magicoder-OSS-Instruct-75K
people[name] = bid if continue_b == "yes": other_biders = True clear() elif continue_b == "no": other_biders = False max_bid = [] person_won = [] for person in people: for i in range(0, len(people)): for personss in people:
ise-uiuc/Magicoder-OSS-Instruct-75K
Olá, ".$dados['nome'].", para alterar sua senha basta clicar no link abaixo: <br><br> <a href=".base_url('trocar-senha?c='.$dados['cod_usuario_encode'])."> ".base_url('trocar-senha?c='.$dados['cod_usuario_encode'])." </a> "; $mail->isHTML(true); $mail->Body = $mensagem;
ise-uiuc/Magicoder-OSS-Instruct-75K
byte otherBitIdx = rotADef[0]& 0x7; byte *rotBDef = (byte[])&(listenerFP[otherBitIdx]); signed char delta = (rotBDef[0]>>5) - (rotADef[0]>>5); if(delta!=0) { rotADef[0]&=B00011111; rotBDef[0]&=B00011111; DEBUG_PRINT(F("Process RotaryEncoder: fpA: ")); DEBUG_PRINT((unsigned int)listenerFP[bitIdx], HEX); DEBUG_PRINT(F(", fpB: ")); DEBUG_PRINT((unsigned int)listenerFP[otherBitIdx], HEX); DEBUG_PRINT(F(", BbitIdx: "));
ise-uiuc/Magicoder-OSS-Instruct-75K
* * 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.fengniao.myblibli.widget.media; import android.app.Service; import android.content.Context; import android.content.Intent;
ise-uiuc/Magicoder-OSS-Instruct-75K
extension String{ /**
ise-uiuc/Magicoder-OSS-Instruct-75K
def compare_circuit(c1: Circuit, c2: Circuit) -> bool: return repr(c1) == repr(c2) def test_parametrized1(): assert compare_circuit( ParametrizedCircuit().ry('a')[0].rz('b')[0].subs([1.2, 3.4]),
ise-uiuc/Magicoder-OSS-Instruct-75K
def cphiADD(circuit, q, ctl, a, n, inv): angle=getAngles(a,n) for i in range(0,n): if inv==0: circuit.cu1(angle[i],ctl,q[i]) else: circuit.cu1(-angle[i],ctl,q[i]) """Doubly controlled version of the phiADD circuit""" def ccphiADD(circuit,q,ctl1,ctl2,a,n,inv): angle=getAngles(a,n) for i in range(0,n): if inv==0:
ise-uiuc/Magicoder-OSS-Instruct-75K
InnerException = ex; } public Result() : this(true, null, null) { } public Result(bool success, string message) : this(success, message, null) { }
ise-uiuc/Magicoder-OSS-Instruct-75K
@abstractmethod def get_path(self, arg: dict[str, Any] | str, dist_name: str, version: str | float | int,
ise-uiuc/Magicoder-OSS-Instruct-75K
<reponame>ttkltll/fisher DEBUG = True SECRET_KEY = "<KEY>" SQLALCHEMY_DATABASE_URI = "mysql+pymysql://root:999999@127.0.0.1:3306/fisher"
ise-uiuc/Magicoder-OSS-Instruct-75K
def test_static_method_call(node): value = node.static_meth("foo") assert value == "static:foo"
ise-uiuc/Magicoder-OSS-Instruct-75K
} } cout<<"max="<<max<<",row="<<row<<",colum="<<colum<<endl; } int max_value(int x,int max) //定义函数 { if(x>max)return x; else return max; }
ise-uiuc/Magicoder-OSS-Instruct-75K
for ($i = 1; $i <= $m; $i++) $res[] = $i*$n; return $res; }
ise-uiuc/Magicoder-OSS-Instruct-75K
export interface NodeLike { name?: string; mesh?: Mesh; translation?: Vector3; rotation?: Quaternion; scale?: Vector3; matrix?: Matrix; children?: Node[]; } export declare class Node extends Serializable implements NodeLike {
ise-uiuc/Magicoder-OSS-Instruct-75K
cors = CORS(app) app.config['CORS_HEADERS'] = 'Content-Type' api = Api(app) api.add_resource(ExtractAnswer, '/extract-answer') if __name__ == '__main__': app.run(host='127.0.0.1', port=5001)
ise-uiuc/Magicoder-OSS-Instruct-75K
Assert.assertTrue(stackTrace.indexOf("com.alibaba.druid.bvt.pool.DruidDataSourceTest.setUp") != -1); } public void test_restart() throws Exception { Assert.assertEquals(true, dataSource.isInited()); dataSource.restart(); Assert.assertEquals(false, dataSource.isInited());
ise-uiuc/Magicoder-OSS-Instruct-75K
//! which is represented as steps of computation making up the full program. pub mod flags; pub mod helper; pub mod memory; pub mod runner; pub mod word;
ise-uiuc/Magicoder-OSS-Instruct-75K
url='https://gz.17zwd.com/api/shop/get-list/73' resp=requests.get(url) f=open('17wang.txt','w+',encoding='utf-8') f.write(resp.text) print(resp.text)
ise-uiuc/Magicoder-OSS-Instruct-75K
# # Code by <NAME> # ###########################
ise-uiuc/Magicoder-OSS-Instruct-75K
# This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. # This file exists just to make opam happy, it should not do anything useful besides that.
ise-uiuc/Magicoder-OSS-Instruct-75K
namespace numpy { types::str base_repr(long number, long base = 2, long padding = 0); DECLARE_FUNCTOR(pythonic::numpy, base_repr); }
ise-uiuc/Magicoder-OSS-Instruct-75K
def api_root(): return APIRoot(parent=None, ref='')
ise-uiuc/Magicoder-OSS-Instruct-75K
<filename>profile_generator/model/faded.py import math from profile_generator.unit import Curve def curve(offset: float, slope: float) -> Curve: fade_end = 3 * offset / (2 - 2 * slope) a = (1 - offset / fade_end - slope) / math.pow(fade_end, 2) b = 0 c = slope d = offset
ise-uiuc/Magicoder-OSS-Instruct-75K
class PyfaiAzimuthalIntegratorTools(PluginTools): """1D azimuthal integrator by pyFAI
ise-uiuc/Magicoder-OSS-Instruct-75K
<filename>src/stores/selection/constant.ts enum Selection { CATEGORY = "UPDATE_CATEGORY_SELECTION", SUB_CATEGORY = "UPDATE_SUB_CATEGORY_SELECTION", PROVINCE = "UPDATE_PROVINCE_SELECTION", PRICE = "UPDATE_PRICE_RANGE_SELECTION", SEARCH = "UPDATE_SEARCH_SELECTION", FILTER = "UPDATE_IS_FILTER_OPEN_SELECTION" } export default Selection
ise-uiuc/Magicoder-OSS-Instruct-75K
import * as types from './types'; export { types };
ise-uiuc/Magicoder-OSS-Instruct-75K
raw_data: list of (label, time) event_mapping_data: a list of event index, where each row index indicates a corresponding log Returns: -------- event_count_matrix: event count matrix, where each row is an instance (log sequence vector) labels: a list of labels, 1 represents anomaly
ise-uiuc/Magicoder-OSS-Instruct-75K
================================ test session starts ================================= platform linux2 -- Python 2.7.13, pytest-3.6.3, py-1.5.4, pluggy-0.6.0 rootdir: /home/markn/devel/py-src/DailyCodingChallenge, inifile: collected 1 item codechallenge_025.py . [100%]
ise-uiuc/Magicoder-OSS-Instruct-75K
# compatible sources: ncode.syosetu.com import re def input_url_source_check(input_url): sources_regex = {'syosetu': '((http:\/\/|https:\/\/)?(ncode.syosetu.com\/n))(\d{4}[a-z]{2}\/?)$'} for key in sources_regex: regex = re.compile(sources_regex[key]) if re.match(regex, input_url): return key else: return False
ise-uiuc/Magicoder-OSS-Instruct-75K
// MARK - helpers func description() -> String { if firstName != nil && lastName != nil && favoriteSong != nil { return "\(firstName!) \(lastName!), likes \(favoriteSong!)" } else { return "\(firstName) \(lastName), \(favoriteSong)" } } }
ise-uiuc/Magicoder-OSS-Instruct-75K
/// let bodhi = BodhiServiceBuilder::default().build().unwrap(); /// /// # #[cfg(feature = "online-tests")] /// let builds = bodhi /// .query(
ise-uiuc/Magicoder-OSS-Instruct-75K
case let .webPage(webPage, media): return .webPage(webPage: webPage, media: media) case let .stickerPack(stickerPack, media): return .stickerPack(stickerPack: stickerPack, media: media) case let .savedGif(media):
ise-uiuc/Magicoder-OSS-Instruct-75K
from __future__ import print_function from builtins import input import cv2 as cv import numpy as np import argparse # Read image given by user
ise-uiuc/Magicoder-OSS-Instruct-75K
func applicationWillTerminate(application: UIApplication) { // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. } }
ise-uiuc/Magicoder-OSS-Instruct-75K
* * Copyright (c) 2014-2016 The Khronos Group Inc. * * Licensed under the Apache License, Version 2.0 (the "License");
ise-uiuc/Magicoder-OSS-Instruct-75K
supplier_framework, signed_agreement_returned_at=datetime.utcnow() ) with freeze_time('2016-12-12'): res = self.sign_agreement(agreement_id) assert res.status_code == 200 data = json.loads(res.get_data(as_text=True)) assert data['agreement'] == { 'id': agreement_id, 'supplierId': supplier_framework['supplierId'], 'frameworkSlug': supplier_framework['frameworkSlug'], 'status': 'signed', 'signedAgreementReturnedAt': '2016-12-12T00:00:00.000000Z'
ise-uiuc/Magicoder-OSS-Instruct-75K
chmod -R 777 dc cd dc
ise-uiuc/Magicoder-OSS-Instruct-75K
<gh_stars>0 def is_xpath_selector(selector): return selector.startswith('/')
ise-uiuc/Magicoder-OSS-Instruct-75K
def buscar_por_id(self,id): return self.dao.buscar_por_id(id)
ise-uiuc/Magicoder-OSS-Instruct-75K
import com.morgan.shared.nav.ClientApplication; /** * Abstract base class for all {@link ApplicationPlace} types that are in the authentication app. * * @author <EMAIL> (<NAME>) */ public abstract class AuthenticationApplicationPlace extends ApplicationPlace { protected AuthenticationApplicationPlace(Map<String, String> parameters) { super(ClientApplication.AUTHENTICATION, parameters); }
ise-uiuc/Magicoder-OSS-Instruct-75K
def test_timestamps(self): ts = moz_to_unix_timestamp(1000000) assert ts == 1 ts = moz_to_unix_timestamp(None) assert ts == 0 dt = moz_datetime(1000000) assert dt == datetime.fromtimestamp(1) def test_tabulate(self, stdout):
ise-uiuc/Magicoder-OSS-Instruct-75K
class TestMochaParser(TestCase):
ise-uiuc/Magicoder-OSS-Instruct-75K
def main(): spotify_client = SpotifyClient(os.getenv("SPOTIFY_AUTHORIZATION_TOKEN"),
ise-uiuc/Magicoder-OSS-Instruct-75K
@Override public VideoController getController() { return mVideoController; } @Override public String getUrl() { return url; }
ise-uiuc/Magicoder-OSS-Instruct-75K
'doNewBug', ] _fullSummary = None def prepareNewBug(fields): global _fullSummary # If the summary is too large, put it in a note if fields.has_key('Summary') and len(fields['Summary']) > 2000: fullsum = fields['Summary'].replace('\r\n', '\n')
ise-uiuc/Magicoder-OSS-Instruct-75K
novo = valor - (valor * 5 / 100) print("O produto que custavo R${:.2f}, na promoção de 5% vai custar R${:.2f}".format(valor, novo))
ise-uiuc/Magicoder-OSS-Instruct-75K
echo "${SELF}:BUILDDIR: '${BUILDDIR}'" >&2; exit 1;
ise-uiuc/Magicoder-OSS-Instruct-75K
let dic = attributtedString.attributes(at: range.location + range.length - 1, effectiveRange: nil) let mAttri = attributtedString.attributedSubstring(from: NSRange(location: range.location, length: range.length)).mutableCopy() as! NSMutableAttributedString let attriToken = NSAttributedString(string: "\u{2026}", attributes: dic)
ise-uiuc/Magicoder-OSS-Instruct-75K
c+=1
ise-uiuc/Magicoder-OSS-Instruct-75K
print(key) for value in alien.values(): print(value)
ise-uiuc/Magicoder-OSS-Instruct-75K
# 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
ise-uiuc/Magicoder-OSS-Instruct-75K
# Flat not getting correct results due to missing boolean operators. print(len(e.childClipPath)) # 7 print(len(e1.childClipPath)) # 7 print(e.childClipPath.points) print(e1.childClipPath.points) #[(50.0, 0.0), (500.0, 0.0), (500.0, 500.0), (0.0, 500.0), (0.0, 80.0), (50.0, 80.0), (50.0, 0.0)] e = Element(w=500, h=500, context=context) e1 = Element(parent=e, w=100, h=100, conditions=[Left2Left(), Top2Top()])
ise-uiuc/Magicoder-OSS-Instruct-75K
namespace App\Models;
ise-uiuc/Magicoder-OSS-Instruct-75K
BINARY_PATH = None if args.bin is None else os.path.join(os.getcwd(), args.bin) OUTPUT_PATH = Path(args.outdir) if not OUTPUT_PATH.exists(): print('Error: output path does not exist') exit(1) class TarFileInfoIterator: def __init__(self, tfile: tarfile.TarFile): self._tfile = tfile def __iter__(self) -> 'TarFileInfoIterator':
ise-uiuc/Magicoder-OSS-Instruct-75K
outputs=base_model.get_layer('block4_pool').output) img_path = 'cat.jpg'
ise-uiuc/Magicoder-OSS-Instruct-75K
def bucket(arg, buckets, closed='left', close_extreme=True, include_under=False, include_over=False): """ Compute a discrete binning of a numeric array Parameters ---------- arg : numeric array expression buckets : list closed : {'left', 'right'}, default 'left' Which side of each interval is closed. For example buckets = [0, 100, 200] closed = 'left': 100 falls in 2nd bucket
ise-uiuc/Magicoder-OSS-Instruct-75K