ngram
listlengths
0
67.8k
[ "TypeError('callback must be a callable, got %s' % type(callback).__name__) if errback is not", "be a callable, got %s' % type(errback).__name__) self.callback = callback self.errback = errback", "escape_ajax from scrapy.http.common import obsolete_setter from scrapy.utils.curl import curl_to_request_kwargs cla...
[ "= 2 class Game(object): class Rules(): def __init__(self, shoe_size=4, min_bet=1, max_bet=10): self.shoe_size =", "0 while (bet!=self.bet and self.bet!=0) or not (rules.min_bet <= bet <= rules.max_bet) :", "= shoe self.shoe.shuffle() self.state = [self.PlayerState(Dealer())] + [self.PlayerState(p) for p in pla...
[ "0 y el 100. # Summing all the multiples of 7 from 0", "7 == 0: total = total+i print(\"Sumatoria de los múltiplos de 7:\", total)", "all the multiples of 7 from 0 to 100. total = 0 for", "de 7 encontrados entre el 0 y el 100. # Summing all the", "to 100. total = 0 for i in range(101): if i % 7", "= 0 for...
[ "# HomeAssistant Status Output # Publishes the provided sensor key and value pair", "key and value pair to a HomeAssistant instance import logging import time from", "serverIP = None serverPort = 8123 useHttps = False timeout = 2 backgroundTasksLock", "False except self.requests.exceptions.ReadTimeout as e: l...
[ "Add config for database # app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///db.sqlite3' # # stop tracking modifications", "= 'sqlite:///db.sqlite3' # # stop tracking modifications on sqlalchemy config # app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] =", "? app.config[\"TWITTER_API_CLIENT\"] = twitter # # Have t...
[ "inst.project_lang_to_gloss(tagmap = './data/tagset_mappings/ctn.txt') # fix_ctn_gloss_line(inst, tag_method=MANUAL_POS) # inst.tag_trans_pos(tagger) # inst.heur_align() # Align trans/gloss", "fix_ctn_gloss_line(to_tag, tag_method=INTENT_POS_CLASS) # Now, retrieve eval/gold. eval_tags = [v.value() for v in to_tag...
[ "import cv2 picturecounter = 1 # 防止过多记录的标识 class Video(Resource): #如果方法为get 调用该方法 def get(self):", "pointer picpath = r'/root/video/realtime/%s/%s.jpg' % (rpiname, picturecounter) image = cv2.imread(picpath) bs = cv2.imencode(\".jpg\",", "username=\\'\" + username + \"\\'\" # 可能存在类型问题 # cursor.execute(sql) # ro...
[ "for sqnorm. afixedf = np.copy(afixed) for k in range(0,len(order)): afixedf[:,k] = afixed[:,order[k]] return", "ambiguity vector search via search-and-shrink zfixedff, sqnormff = ssearch( zhat, L, D, ncands", "Qahat, Z ) Qzhat = np.matmul( Z.transpose(), Qzhat ) zhat = np.matmul(Z.transpose(),ahat) iZt", "# ...
[]
[ "the final value return hexadecimal def decrypt(msg, key): # Defining hex to uni", "temp = ord(msg[i]) ^ ord(key[iteration]) # zfill will pad a single letter hex", "are used, repeat the key iteration = 0 # Returning the final value", "2): # Decoding each individual bytes from hex hex_to_uni += bytes.fromhex(m...
[ "import os import random def rename_files(path): file_list = os.listdir(path) print(file_list) for file_name in", "numbers to beginning of filename. new_file_name = str(random.randint(1, 99)) + file_name print(\"Renaming \"", "\" + file_name + \" to \" + new_file_name) os.rename(os.path.join(path, file_name), o...
[ "bn.rankdata ranked = func(data, axis=axis) if pct: count = np.sum(~np.isnan(data), axis=axis, keepdims=True) ranked", "dimensions are squeezed. Returns ------- squeezed : same type as caller This object,", "return apply_ufunc( duck_array_ops.isnull, self, dask=\"allowed\", keep_attrs=keep_attrs, ) def notnull(...
[ "number_of_notebooks = map(int, input().split()) if number_of_pens >= number_of_participants and number_of_notebooks >= number_of_participants: print('Yes')", "number_of_participants, number_of_pens, number_of_notebooks = map(int, input().split()) if number_of_pens >= number_of_participants and number_of_notebook...
[]
[ "util.BufferedByteStream('this is a test') self.assertEqual(len(sp), 14) self.assertEqual(sp.read(1), b't') self.assertEqual(sp.getvalue(), b'this is a test')", "meta = { 'exclude': ['foo'], 'readonly': ['bar'], 'dynamic': False, 'alias': 'spam.eggs', 'proxy_attrs': None,", "x.write_char(0) x.write_char(-128) x...
[ "print (Fore.GREEN + '[+] Result: DMARC Policy is set as quarantine! Domain emails", "pip install -r requirements.txt (colorama) os = platform.platform() if os.find('Windows')!= (-1): init(convert=True) print(\"\"\"", "init(convert=True) print(\"\"\" ███████╗░░░░░░██╗░░░██╗░█████╗░██╗░░░░░██╗░░░██╗░█████╗░█████...
[ "from logger import getLogger LOGGER = getLogger('API_MODULE') define(\"port\", default=8000, help=\"run on the given", "'data': answers, 'contextOut': [answers], 'source': 'how-about-natume' } self.finish( dumps( respose, ensure_ascii=False, indent=4, sort_keys=True,", "[answers], 'source': 'how-about-natume' ...
[ "0: self.state = chunkParserStates.COMPLETE else: self.state = chunkParserStates.WAITING_FOR_SIZE self.chunk = b'' self.size =", "on Network monitoring, controls & Application development, testing, debugging. :copyright: (c) 2013-present by", "b'' # Extract following chunk data size line, raw = find_http_line(r...
[ "ty.List[Pool], request: 'objects.InstancePCIRequest', numa_cells: ty.Optional[ty.List['objects.InstanceNUMACell']] = None, ) -> bool: \"\"\"Apply an individual", "Unless required by applicable law or agreed to in writing, software # distributed", "fulfil LEGACY but not SOCKET. If we have SOCKET, # process it h...
[ "renames all the files of the folder Desktop to 'new_name' and count starts", "the files will be renamed like : 1. new_name33.exe 2. new_name34.exe and so", "and count starts from 33 to further (we can also provide 1 to", "further (we can also provide 1 to start it from 1) and extension", "given '.exe' henc...
[ "def readlinkabs(l): \"\"\" Return an absolute path for the destination of a symlink", "path for the destination of a symlink \"\"\" if not (os.path.islink(l)): return None", "\"\"\" if not (os.path.islink(l)): return None p = os.readlink(l) if os.path.isabs(p): return p", "readlinkabs(l): \"\"\" Return an ab...
[ "= Picamera2() video_config = picam2.video_configuration(main={\"size\": (1280, 720), \"format\": \"RGB888\"}, lores={\"size\": lsize, \"format\": \"YUV420\"})", "= (320, 240) picam2 = Picamera2() video_config = picam2.video_configuration(main={\"size\": (1280, 720), \"format\": \"RGB888\"},", "= int(time.time(...
[ "pattern_info # create the list representation self._pattern_list = [] for pattern_name in self._pattern_dict.keys():", "top N patterns. \"\"\" self._pattern_dict = pattern_info # create the list representation self._pattern_list", "in the repository. \"\"\" all_patterns = self.get_all() num_to_return = int(len...
[]
[ "range(self.ui.servoCountSpin.value())]) @asyncio.coroutine def handle_connect_clicked(self): val = self.ui.typeCombo.currentText().lower() try: self.controller = yield From( selector.select_servo(", "= QtGui.QDoubleSpinBox() doublespin.setRange(-180, 180) doublespin.setDecimals(1) save = QtGui.QPushButton() save...
[ "in the JUICE protocol. \"\"\" def __init__(self, __body='', **kw): self.update(kw) if __body: assert", "aCallable, result)) # return result def checkKnownErrors(error): key = error.trap(*command.allErrors) code = command.allErrors[key]", "proto).addErrback( checkKnownErrors) return doit def _wrap(self, aCallab...
[ "def _http_request( self, payload: Union[SimulatorInterface, SimulatorEventRequest], config: ServiceConfig, ) -> SimulatorEvent: res =", "retryable response error code.\" \" Retrying request.\".format(res.status_code) ) self._retry_attempts += 1 return self._http_request(payload,", "bail on error if res.status_...
[ "x_shift = random.randint(-enlarge_img_shrink[0]//16, enlarge_img_shrink[0]//16) y_shift = random.randint(-enlarge_img_shrink[1]//16, enlarge_img_shrink[1]//16) x_min += x_shift x_max +=", "= 3 im_lr -= im_lr % (fiducial_points-1) - (2*edge_padding) # im_lr % (fiducial_points-1)", "* perspective_shreshold, y_mi...
[ "analysis.deserialize_tweets(sys.stdin) # run analysis analysis.analyze_tweets(tweet_generator, results) # run baseline analysis, if requests if", "= args.do_audience_analysis) # manage input sources, file opening, and deserialization if args.input_file_name is", "analysis') args = parser.parse_args() # get the...
[ "(incoming_msg[:7] == 'TPC - e ' and len(incoming_msg)>8): utils.portalLogin(os.environ.get('TPC_EMAIL'),os.environ.get('TPC_PWD')) companyName = incoming_msg.split(' ')[2]", "Please enter one of the following option 👇 \\n *TPC*. TPC portal willingness", "\\n 📞 : 9537701631 \\n ✉ : <EMAIL> \\n\\n Please enter...
[]
[ "y_pred = None ####################################################################### # TODO: Implement this function; it should be VERY", "of training samples. - grads: Dictionary mapping parameter names to gradients of those", "<= c < C. \"\"\" y_pred = None ##################################################...
[ "Getting a setting object. \"\"\" name = 'TEST_SETTING' data = 'Setting data' setting", "\"\"\" name = 'TEST_SETTING' data = 'Setting data' setting = self._create_setting(name, data=data) try:", "data=data) try: setting2 = Setting.objects.get(pk=setting.pk) except Setting.DoesNotExist: self.fail('Setting with I...
[ "from homeassistant.const import CONF_LATITUDE, CONF_LONGITUDE, CONF_NAME, TEMP_CELSIUS from homeassistant.core import HomeAssistant from homeassistant.helpers", "from .sensor import ( ATTRIBUTION, CONF_STATION_ID, ZamgData, closest_station, zamg_stations, ) _LOGGER = logging.getLogger(__name__)", "@property de...
[ "a core model. nlu: Check sections for finetuning an nlu model. Returns: `True`", "target_path) fingerprint_comparison.core = core_merge_failed if not fingerprint_comparison.should_retrain_nlg() and core_merge_failed: # If moving the", "FINGERPRINT_NLU_LABELS_KEY: nlu_data.label_fingerprint(), FINGERPRINT_STORI...
[ "from backtesting import Backtest, Strategy from backtesting.lib import crossover, cross from backtesting.test import", "Moving Average def init(self): # compute momentum \"\"\" Simple Moving Average Calc\"\"\" self.sma", "Created on Fri Jul 16 11:20:01 2021 @author: q GOAL : develop a", "from backtesting.lib...
[ "de números com Generator gen = getsizeof(x * 10 for x in range(1000))", "print(res) # [True, True, True, True, True, False] # Generator - mais efeciente", "# Quanto maior a string mais espaço ocupa. print(getsizeof('Paulo')) print(getsizeof('Quanto maior a string", "x in range(1000)]) # Gerando uma lista de ...
[ "número: \")) numero3 = int(input(\"Digite o terceiro número: \")) if (numero1 < numero2", "numero3 = int(input(\"Digite o terceiro número: \")) if (numero1 < numero2 and numero2", "número: \")) numero2 = int(input(\"Digite o segundo número: \")) numero3 = int(input(\"Digite o", "o terceiro número: \")) if (n...
[ "for i in range(2): tina.forward(lengte) tina.right(60) tina.forward(lengte) tina.right(120) def sneeuwvlok(lengte, num): for i", "turtle.Turtle() tina.shape(\"turtle\") tina.speed(10) def parallellogram(lengte): for i in range(2): tina.forward(lengte) tina.right(60) tina.forward(lengte) tina.right(120)", "tina...
[ "IMPLIED, INCLUDING BUT NOT LIMITED TO THE # WARRANTIES OF MERCHANTABILITY, FITNESS FOR", "including without limitation # the rights to use, copy, modify, merge, publish, #", "title, } self.site.render_template('listing.tmpl', out_name, context) flag = True template_deps = self.site.template_system.template_dep...
[ "None, index_document: Optional[pulumi.Input[str]] = None, resource_group_name: Optional[pulumi.Input[str]] = None, __props__=None): \"\"\" Enables the", "# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK", "__props__.__dict__[\"error404_document\"] = error404_document __props__.__dict__[\...
[ "WITHOUT WARRANTIES OR CONDITIONS # OF ANY KIND, either express or implied. See", "for the AWS doc team's sample catalog. Do not remove.] # snippet-sourcedescription:[s3-python-example-get-bucket-policy.py demonstrates", "permissions and limitations under the License. import boto3 # Create an S3 client", "= b...
[ "writing, software # distributed under the License is distributed on an \"AS IS\"", "15234324, \"stringField\": \"hey\", \"boolField\": True, \"floatField\": 1234.0, \"doubleField\": -1234.0, \"bytesField\": b\"12312adf\", \"nullField\": None,", "1234.0, \"doubleField\": -1234.0, \"bytesField\": b\"12312adf\", ...
[ "erode_value_blobs(array, steps=1, values_to_ignore=tuple(), new_value=0): unique_values = list(np.unique(array)) all_entries_to_keep = np.zeros(shape=array.shape, dtype=np.bool) for unique_value", "unique_value if unique_value in values_to_ignore: all_entries_to_keep = np.logical_or(entries_of_this_value, all_en...
[ "test_unit_decomposition(self): lu = u.mag(u.Jy) assert lu.decompose() == u.mag(u.Jy.decompose()) assert lu.decompose().physical_unit.bases == [u.kg, u.s]", "assert q1.value == 2.5 assert q1.unit == unit pv = 100. * unit.physical_unit", "some power is only possible when the physical unit is dimensionless, and t...
[ "get_raw(url, json.dumps(data), \"application/json\", headers, status=status) def time_api_get_work_types_call(return_value): method_name = 'djconnectwise.api.TimeAPIClient.get_work_types' return create_mock_call(method_name, return_value)", "side_effect=raised) def _project_api_tickets_call(page=1, page_size=25,...
[ "1, ) cv2.putText( trajectory, \"Green\", (270, 120), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 0), 1,", "path using either five point estimation or eight point estimation :param image_path: Path", "400, true_z + 100), 1, list((0, 0, 255)), 4) trajectory = cv2.circle(trajectory, (draw_x", "\"Actual Position:\",...
[ "train_images = np.load(os.path.join(train_dir, 'train_images.npy')) train_labels = np.load(os.path.join(train_dir, 'train_labels.npy')) print('train_images', train_images.shape, 'train_labels', train_labels.shape) dataset_train", "test_images = np.load(os.path.join(val_dir, 'validation_images.npy')) test_labels ...
[ "= X_test[test_idx, :] y_test = Y_test[test_idx] distances = dataset.find_distances(x_test, X_train) flipped_idx = Y_train", "= (np.copy(Y_test) + 1) / 2 Y_pred = model.sess.run(model.preds, feed_dict=model.all_test_feed_dict) Y_pred_correct = np.zeros([len(Y_test)])", "= 0.001 initial_learning_rate = 0.001 kee...
[ "in count: cmd4g[i]=count[i]+cmd4g[i] del count cmd4gx={} for i in cmd4g: if cmd4g[i]>0: cmd4gx[i]=cmd4g[i]", "in traing data # ../../data/train is the path of original train data ##########################################################", "specify # the order of samples in traing data # ../../data/train is th...
[]
[ "from pygments.token import String, Number, Name, Keyword, Operator, Text, Comment __all__ = ['RtsLexer']", "(r\"'(\\\\\\\\|\\\\[^\\\\]|[^'\\\\])*'\", String), (r'\"', String, 'escapable-string'), (r'(0x[0-9a-fA-F]+|\\d+)', Number), (r'\\d+\\.\\d+', Number.Float), (r'\\$[a-zA-Z](\\w|_)*', Name.Variable), (r'(if|e...
[ "is not index assert idx_copy.equals(index) new_copy = index.copy(deep=True, name=\"banana\") assert new_copy.name == \"banana\"", "assert new_copy.name == \"banana\" def test_unique(self, index): # don't test a MultiIndex here", "level in 0, index.name, None: result = index.unique(level=level) tm.assert_index_...
[ "-39.04876174, 45.31837288, 55.65557816, 50.47052688, 0.36025589, 58.92377491, 29.70094194, -15.13534937, ], ) else: np.testing.assert_almost_equal( x_out[:,", "TestUtils.bioptim_folder() + \"/examples/getting_started/models/2segments_4dof_2contacts.bioMod\" ) nlp.ns = 5 nlp.cx = cx nlp.x_bounds = np.zeros((nlp.m...
[ "return [event_type for event_type, event in self.items if event.get_event_action() in event_actions.WRITE_ACTIONS] def user_view_events(self):", "ManagerInterface from event_manager import event_actions class EventManager(ManagerInterface): def _get_state_data(self, event): # pylint:disable=arguments-differ retu...
[ "helpers import * def test_f_login_andy(): url = \"http://central.orbits.local/rpc.AuthService/Login\" raw_payload = {\"name\": \"andy\",\"password\": \"<PASSWORD>\"}", "body contents, e.g. status code. assert response.status_code == 200 # print full request", "raw_payload = {\"name\": \"andy\",\"password\": \"...
[ "= u_r - c_r s[1,:] = np.max(s_index,axis=0) # Compute middle state q_hat =", "for m in xrange(num_eqn): for mw in xrange(num_waves): amdq[m,:] += (s[mw,:] < 0.0)", "= a1 wave[1,0,:] = a1 * (ubar - cbar) s[0,:] = ubar -", "shallow_exact_1D(q_l,q_r,aux_l,aux_r,problem_data): r\"\"\" Exact shallow water Riemann...
[ "in constant: if not isHashable(value): return False return True elif constant is Ellipsis:", "return None elif constant_type is slice: return None else: assert False, constant_type def", "and # integrates with CPython, but also works on its own. # #", "in ( str, unicode, complex, int, long, bool, float, None...
[ "support is taken from the environment. return get_environ_proxies(url) def _get_verify_value(self, verify): # This", "import URLLib3Session from botocore.utils import is_valid_endpoint_url, get_environ_proxies from botocore.hooks import first_non_none_response from botocore.history", "DEFAULT_TIMEOUT = 60 MAX_...
[ "''' import scipy.stats as stats import numpy as np import pandas as pd", "as a child and those who know did not. This function should return", "versus those who were vaccinated but did not contract chicken pox. Return results", "variables. If we wanted to know if vaccines work, we might look at", "a dictio...
[ "next 13 bars: \" + str(min_forecast) + \"-\" + str(max_forecast) ) print(\"sell\") plt.savefig(sell_dir", "print('buy') # plt.savefig(buy_dir + str(uuid.uuid4())+'.jpg', bbox_inches='tight') # plt.show() open.clear() close.clear() volume.clear() high.clear() low.clear()", "c_start = start + 12 for x in range(f...
[ "= TornadoDic.NOMINAL_ATTRIBUTE attribute_value_range = attribute_value_range.strip('{}').replace(\"'\", \"\") attribute_value_range = attribute_value_range.split(',') attributes_min_max.append([None, None]) attribute.set_type(attribute_type) attribute.set_possible_values(attribute_value_range)", "line[2] attribu...
[ "from keras import backend as K from evolution import Evolution from genome_handler import", "#mlflow.tensorflow.autolog() #mlflow.keras.autolog() print(\"Num GPUs Available: \", len(tf.config.list_physical_devices('GPU'))) K.set_image_data_format(\"channels_last\") #(x_train, y_train), (x_test, y_test) =", "to...
[ "== 2: next_dir = (self.pos[0] - agent.pos[0], self.pos[1] - agent.pos[1]) if next_dir[0] *", "obtener la dirección hacia donde debe moverse el automóvil, regresa la dirección #", "guarda en el automóvil y se cambia su dirección. if self.is_valid(next_cell): self.next_cell =", "col < width - 2: agent.directio...
[ "# Originally I implemented this using regular open() and read(), so it #", "== '.js': display(Javascript(contents)) elif ext == '.css': display(HTML('<style>' + contents + '</style>')) else:", "file to a jupyter notebook.\"\"\" import os from pkg_resources import resource_string from IPython.display", "if th...
[ "ProgramWidget(QWidget): def __init__(self, hub_client : HubClient, hub_monitor : HubMonitor, *args, **kwargs): super().__init__(*args, **kwargs)", "print((\"Storage free %s%s of total %s%s\" % (storage['free'], storage['unit'], storage['total'], storage['unit']))) class ConsoleWidget(QTextEdit):", "**kwargs) s...
[ "import Task # Create your views here. class CustomLoginView(LoginView): template_name='base/login.html' fiels='__all__' redirect_auhenticated_user =", "TaskUpdate(UpdateView): model = Task fields = '__all__' success_url = reverse_lazy('tasks') class TaskDelete(DeleteView): model", "from django.views.generic.de...
[ "assert isinstance(result_, tuple) assert len(result_) == 2 result, none = result_ assert none", "assert np.all(result <= (y + TOL)) def test_Dropout_x_is_op(): x = np.array([3, 4]).astype(np.float32) input_op", "* from dnnv.nn.operations import * TOL = 1e-6 def test_Dropout_consts(): x = np.array([3,", "len(...
[ "# sets a unique port per agent 2. worker.py will begin listening on", "SMARTS calls `act()` rpc with observation as input and receives the actions as", "mod in modules: try: importlib.import_module(mod) except ImportError: if mod == \"ray\": print( \"You", "TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR...
[ "> 0: # Was stated that payments needed to happen in increments of", "Generate: ------------------- Lowest Payment: 310 Test Case 2: balance = 4773 annualInterestRate =", "4773 annualInterestRate = 0.2 Result Your Code Should Generate: ------------------- Lowest Payment: 440", "(Monthly interest rate x Monthl...
[ "def frequencySort(self, s): \"\"\" :type s: str :rtype: str \"\"\" return ''.join(c *", "c, v in count: res += c * v return res ### Test", "\"\"\" :type s: str :rtype: str \"\"\" freq = collections.defaultdict(int) for c in", "freq = collections.defaultdict(int) for c in s: freq[c] += 1 counts = [\"\"]", "...
[ "0; } #collapseTrigger{ color:#fff; display: block; text-decoration: none; } * { margin: 0;", "class=\"%s\" name=\"%s-target-tie\" data-col=\"1\" value=\"1\"/> </label> </td> </tr>\"\"\" % (example.key, example.key) html += \"\"\"", "generate_2choice_instructions(): return \"\"\" <p>Consider the following excha...
[ "works everywhere in the documentation. .. exref:: :title: an example of use Just", "is the documentation for this class. **example with a sphinx directives** It works", "(myexampleb). \"\"\" class myclass: \"\"\" This is the documentation for this class. **example", "in the documentation. .. exref:: :title: ...
[ "# preample import numpy as np from utilites import Pauli_operators, simulate, CheckNoise ################################################", "drift Hamiltonian dynamic_operators = [0.5*Pauli_operators[1]] # control Hamiltonian noise_operators = [0.5*Pauli_operators[3]] # noise", "as np from utilites import Paul...
[]
[ "\"\"\" from flask import Blueprint from flask_restful import Api from .resources.user import UserAuth,", "module. \"\"\" from flask import Blueprint from flask_restful import Api from .resources.user import", "flask_restful import Api from .resources.user import UserAuth, UserItem, UserList, UserFollow # Creat...
[ "print(next(cycle1)) print(next(cycle1)) print(next(cycle1)) # use count to create a simple counter count1 =", "print(next(cycle1)) # use count to create a simple counter count1 = itertools.count(100, 3)", "as long as the # condition of the function is true and then", "40, 30] # accumulate creates an iterator...
[ "str(telefone) def imprimeNome(self): print(f\"Você pode chamar essa pessoa de {self.nome}.\") def __imprimeTelefone(self): print(f\"Você", "= str(endereco) self.__telefone = str(telefone) def imprimeNome(self): print(f\"Você pode chamar essa pessoa de", "chamar essa pessoa de {self.nome}.\") def __imprimeTelef...
[]
[ "parse different inputs includeing system specifications, flag arguments, execution parameters, user parameters and", "to define the break error level. maxerrors : int or bool, optional The", "`table`. directory : str, optional The argument is used to set logging file", "html=html, table=table, status=status,...
[ "its affiliates. All rights reserved. # This software is dual-licensed to you under", "the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License", "(UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at", "# coding: utf-8 ...
[ "start_urls = [ 'https://millardayo.com', ] def parse(self, response, **kwargs): # extracting data -", "{ 'image_url': post.find('img').get('src'), 'link': post.find('a').get('href'), 'title': post.find('a').get('title'), 'excerpt': post.find('p').get_text(), 'source': 'millardayo', } except", "'image_url': pos...
[ "from apache_beam.runners.portability import expansion_service from apache_beam.transforms import ptransform from apache_beam.transforms.external import ImplicitSchemaPayloadBuilder from", "KIND, either express or implied. # See the License for the specific language", "apache_beam.runners.portability import exp...
[ "from sqlalchemy.orm import sessionmaker from settings import DB_URI Session = sessionmaker(autocommit=False, autoflush=False, bind=create_engine(DB_URI))", "sessionmaker from settings import DB_URI Session = sessionmaker(autocommit=False, autoflush=False, bind=create_engine(DB_URI)) session = scoped_session(Sess...
[ "capability of a GPU (e.g. \"6.1\") \"\"\" major, _ = parse_compute_version(compute_version) if major", "was specified or GPU detected.\" \"Try specifying it by adding '-arch=sm_xx' to your", "distributed on an # \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY", "proc.returncode != 0: msg = code msg ...
[ "specific calculation from history\"\"\" return Calculations.history[num] @staticmethod def add_calculation(calculation): \"\"\" get a generic", "\"\"\"create a subtraction object to history using factory method create\"\"\" Calculations.add_calculation(Subtraction.create(values)) return True", "history of calc...
[ "valor 5 foi digitado e está na {valores.index(5)} posição.') else: print('Valor 5 não", "valores.reverse() print(f'O valor 5 foi digitado e está na {valores.index(5)} posição.') else: print('Valor", "ou -1 para Finalizar: ')) if valor < 0: print('\\nFinalizando...') break else: valores.append(valor)", "orden...
[ "model_name='transaction', old_name='authorityStart', new_name='authority_start', ), migrations.RenameField( model_name='transaction', old_name='authorityVerify', new_name='authority_verify', ), migrations.RenameField( model_name='transaction', old_name='failureReason', new_name='failure_reason',", "model_name='t...
[ "InPlaceABNSyncWrapper from .misc import GlobalAvgPool2d from .residual import IdentityResidualBlock from .dense import DenseModule", "from .bn import ABN, InPlaceABN, InPlaceABNWrapper, InPlaceABNSync, InPlaceABNSyncWrapper from .misc import GlobalAvgPool2d from", ".bn import ABN, InPlaceABN, InPlaceABNWrapper...
[ "distributed on an # \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY", "2], [3, 4, None]]) expected = pa.chunked_array([[True, True, True, True, None]]) for result", "table.filter(mask) assert result.equals(expected_drop) result = table.filter(mask, null_selection_behavior=\"emit_null\") assert result....
[ "python 3 compatibility library import six from client.api_client import ApiClient class LogApi(object): \"\"\"NOTE:", "api_client=None): if api_client is None: api_client = ApiClient() self.api_client = api_client def logs_get(self,", "is set if ('name' not in params or params['name'] is None): raise ValueErro...
[ "system = self._system self._solver_info.append_subsolver() system._transfer('nonlinear', 'fwd') with Recording('NonlinearBlockJac', 0, self) as rec: #", "for subsys in system._subsystems_myproc: subsys._solve_nonlinear() else: for subsys in system._subsystems_myproc: subsys._solve_nonlinear() system._check_child...
[ "as multiple arguments. else: b = predicate(r) if not sess.run(b): filtered = True", "KIND, either express or implied. # See the License for the specific language", "not sess.run(b): filtered = True break if not filtered: result = sess.run(get_next) self.assertAllEqual(r,", "Unless required by applicable law ...
[ "= data[i] c = chr(b) if c == \"\\n\": count_lines += 1 elif", "emulator including the header. This is intended for saved .egv files which include", "intended for saved .egv files which include a default header. \"\"\" if self.header_skipped:", "\"\" self.number_consumer = self.speedcode_b2_consumer def speed...
[ ":type Offset: int :param Limit: 分页单位,最大支持50。 :type Limit: int :param ProfileName: 根据邮件配置名称查询,定期发送的邮件配置名称遵循:\"scheduler_\"+{instanceId}的规则。 :type", "def __init__(self): r\"\"\" :param SecAuditGroupId: 安全审计组Id。 :type SecAuditGroupId: str :param AsyncRequestId: 异步任务Id。 :type", "def __init__(self): r\"\"\" :param ...
[ "a response object from the given parameters. :param body: Buffer/string containing the response", "resource access. Certain methods MUST be overridden in a subclass, thus this class", "# Catch missing parameters in request return self._make_json_error_response(\"invalid_request\") except StandardError as exc: ...
[ "extractor model resorted_img_folder='resorted_data',#the folder for clustered images cluster_algo='kmeans',#cluster algorithm base_img_folder='data', maxK=150,#the max k", "resize_shape=(224,224) # (w,h) a tuple for resizing the input images to the same", "the resorted_img function to label the images under di...
[ "# # Licensed under the Apache License, Version 2.0 (the \"License\"); # you", "writing, software # distributed under the License is distributed on an \"AS IS\"", "permissions and # limitations under the License. import torch from gradsflow.models import Model", "KIND, either express or implied. # See the Lic...
[ "parity=\"N\", stopbits=1, bytesize=8, timeout=1): ExecutorBase.__init__(self, checkok=False) self.device = device self.baudrate = baudrate self.type", "baudrate self.type = type self.parity = parity self.stopbits = stopbits self.bytesize = bytesize", "method to communicate with any serial device. Please note t...
[ "in some unique scenarios in which child objects share their parent's ID. Because", "to 64 bits in size (e.g. a uint64), they are always returned as", "as strings in the HTTP API to prevent integer overflows in some languages.", "languages. See Gateway ETF/JSON for more information regarding Gateway encoding....