code
stringlengths
4
4.48k
docstring
stringlengths
1
6.45k
_id
stringlengths
24
24
class Pressure(WeatherChannel): <NEW_LINE> <INDENT> def __init__(self, ctime_range=None, source_dir=None): <NEW_LINE> <INDENT> WeatherChannel.__init__(self, 'pressure', ctime_range=ctime_range, source_dir=source_dir)
Load APEX 'pressure', in mBar.
62598ef29c8ee8231303f56c
class MongoDBCollectionsDBDiscoveryMetric(DiscoveryMetric): <NEW_LINE> <INDENT> DEFAULT_KEY = "mongodb.server.discovery.databaseCollections" <NEW_LINE> DEFAULT_VALUE = json.dumps(dict(data = [])) <NEW_LINE> def __init__(self, mongoClient = None, mongodHost = None, mongodPort = None): <NEW_LINE> <INDENT> if mongoClient:...
Discover a list of all collections within all DBs @note: Only provides DB names and collection names - Lowest overhead, least information provided
62598ef23d592f4c4edb9710
class AliveLoggingReceivingCallbackWebsocketClientProtocol(WebSocketClientProtocol): <NEW_LINE> <INDENT> alive = False <NEW_LINE> callback = None <NEW_LINE> alive_message = 'Secure importer alive.' <NEW_LINE> def onMessage(self, payload, isBinary): <NEW_LINE> <INDENT> if not isBinary: <NEW_LINE> <INDENT> success = self...
Receive only websocket client that - logs an alive message while connected - periodically calls a health check function
62598ef27d847024c075abf2
class MultiplyModN(BasicMathGate): <NEW_LINE> <INDENT> def __init__(self, a): <NEW_LINE> <INDENT> def mod(exponent,modulus,val): <NEW_LINE> <INDENT> if modulus == 0 or val >= modulus: <NEW_LINE> <INDENT> return (exponent,modulus,val) <NEW_LINE> <DEDENT> else: <NEW_LINE> <INDENT> base = a <NEW_LINE> exp = exponent <NEW_...
Takes three quantum registers as input, 'exponent, 'modulus' and 'val'. The gate returns the exponent and modulus registers unchanged, and multiplies the val register by base^exponent mod(modulus) The numbers in quantum registers are stored from low- to high-bit, i.e., qunum[0] is the LSB.
62598ef27047854f4633dbf2
class HubVirtualNetworkConnection(SubResource): <NEW_LINE> <INDENT> _validation = { 'etag': {'readonly': True}, 'provisioning_state': {'readonly': True}, } <NEW_LINE> _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'name': {'key': 'name', 'type': 'str'}, 'etag': {'key': 'etag', 'type': 'str'}, 'remote_virtual_ne...
HubVirtualNetworkConnection Resource. Variables are only populated by the server, and will be ignored when sending a request. :param id: Resource ID. :type id: str :param name: The name of the resource that is unique within a resource group. This name can be used to access the resource. :type name: str :ivar etag: A...
62598ef27d847024c075abf3
class Role(models.Model): <NEW_LINE> <INDENT> name = models.CharField(max_length=32, unique=True, verbose_name="角色名称") <NEW_LINE> permissions = models.ManyToManyField("Permission", blank=True, verbose_name="URL授权") <NEW_LINE> desc = models.CharField(max_length=128, blank=True, null=True, verbose_name="描述") <NEW_LINE> c...
角色
62598ef263b5f9789fe83982
class QuotaController(wsgi.Controller): <NEW_LINE> <INDENT> @admin_context <NEW_LINE> def show(self, req, tenant_id, id): <NEW_LINE> <INDENT> LOG.info(_("req : '%s'\n\n") % req) <NEW_LINE> LOG.info(_("Indexing quota info for tenant '%s'") % id) <NEW_LINE> quotas = quota_engine.get_all_quotas_by_tenant(id) <NEW_LINE> re...
Controller for quota functionality
62598ef2283ffb24f3cf20d6
class Slide(Orderable, TextContent): <NEW_LINE> <INDENT> homepage = models.ForeignKey(HomePage, related_name="slides") <NEW_LINE> link = models.CharField(max_length=2000, blank=True, help_text="If present the title will link here") <NEW_LINE> image = FileField(verbose_name=_("Image"), upload_to=upload_to("vital_theme.S...
A slide in a slider connected to a HomePage
62598ef22c8b7c6e89bd1fe7
class FlickrPhotoset(models.Model): <NEW_LINE> <INDENT> flickr_id = models.CharField(primary_key=True, max_length=50) <NEW_LINE> primary = models.ForeignKey(FlickrPhoto, null=True, default=None, related_name='primary_photo_set') <NEW_LINE> owner = models.ForeignKey('FlickrUser') <NEW_LINE> title = models.CharField(max_...
One photoset and its list of ``FlickrPhotos``.
62598ef210dbd63aa1c6f39c
class BookingSerializer(serializers.ModelSerializer): <NEW_LINE> <INDENT> room_number = serializers.PrimaryKeyRelatedField( queryset=RoomViewSet.queryset ) <NEW_LINE> user = serializers.SlugRelatedField( queryset=UserViewSet.queryset, allow_null=True, slug_field='username', default=serializers.CurrentUserDefault() ) <N...
Serializer for Booking model, used to represent the model to the API and vice versa
62598ef2b7558d5895461e6b
class MetadataChangeEventTest(unittest.TestCase): <NEW_LINE> <INDENT> def test_metadata_change_event(self): <NEW_LINE> <INDENT> metadata_change_event_obj = MetadataChangeEvent() <NEW_LINE> self.assertNotEqual(metadata_change_event_obj, None)
NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually.
62598ef22ae34c7f260a9905
class AdalineGD(object): <NEW_LINE> <INDENT> def __init__(self, eta=0.01, n_iter=50): <NEW_LINE> <INDENT> self.eta = eta <NEW_LINE> self.n_iter = n_iter <NEW_LINE> <DEDENT> def fit(self, X, y): <NEW_LINE> <INDENT> self.w_ = np.zeros(1 + X.shape[1]) <NEW_LINE> self.cost_ = [] <NEW_LINE> for i in range(self.n_iter): <NEW...
ADAptive LInear NEuron classifer. Parameters ----------- eta : float Learning rate (between 0.0 and 1.0) n_iter : int Passes over the training dataset. Attributes ----------- w_ : 1d-array Weights after fitting. errors_ : list Number of misclassifications in every epoch.
62598ef25166f23b2e241bfd
class BinaryTree(object): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.root = None <NEW_LINE> self.size = 0 <NEW_LINE> <DEDENT> def insert(self, val): <NEW_LINE> <INDENT> if not self.root: <NEW_LINE> <INDENT> self.root = Tnode(val) <NEW_LINE> self.size += 1 <NEW_LINE> <DEDENT> else: <NEW_LINE> <INDE...
Binary Tree implementation
62598ef2d58c6744b42db6c8
class AppInfoExternal(validation.Validated): <NEW_LINE> <INDENT> ATTRIBUTES = { APPLICATION: APPLICATION_RE_STRING, VERSION: VERSION_RE_STRING, RUNTIME: RUNTIME_RE_STRING, API_VERSION: API_VERSION_RE_STRING, HANDLERS: validation.Optional(validation.Repeated(URLMap)), SERVICES: validation.Optional(validation.Repeated( v...
Class representing users application info. This class is passed to a yaml_object builder to provide the validation for the application information file format parser. Attributes: application: Unique identifier for application. version: Application's major version number. runtime: Runtime used by application. ...
62598ef25fdd1c0f98e5c7c7
class BaseGeometry: <NEW_LINE> <INDENT> def area(self): <NEW_LINE> <INDENT> raise Exception("area() is not implemented") <NEW_LINE> <DEDENT> def integer_validator(self, name, value): <NEW_LINE> <INDENT> if type(value) is not int: <NEW_LINE> <INDENT> raise TypeError("{:s} must be an integer".format(name)) <NEW_LINE> <DE...
class with public instances area and integer_validator
62598ef2091ae3566870343e
class TestScriptConfigConflict(object): <NEW_LINE> <INDENT> def test_try_resolve_twice(self, config_conflict): <NEW_LINE> <INDENT> assert not config_conflict.is_resolved <NEW_LINE> assert isinstance(config_conflict.try_resolve(evc.adapters.ScriptConfigChange.BREAK), config_conflict.ScriptConfigResolution) <NEW_LINE> as...
Tests methods related to code conflicts
62598ef24f88993c371ef8fc
class GVE(object): <NEW_LINE> <INDENT> def __init__(self, mu=1.0): <NEW_LINE> <INDENT> self.mu = mu <NEW_LINE> <DEDENT> def __call__(self, T, X): <NEW_LINE> <INDENT> dims = (T.shape[0], 1, 1) <NEW_LINE> a = X[:, 0:1].reshape(dims) <NEW_LINE> e = X[:, 1:2].reshape(dims) <NEW_LINE> i = X[:, 2:3].reshape(dims) <NEW_LINE> ...
Gauss's Variational Equations for classical orbital elements. Attributes: mu: float, optional Standard Gravitational Parameter. Defaults to 1.0, the standard value in canonical units.
62598ef2236d856c2adc8829
class _PlaybackControls(): <NEW_LINE> <INDENT> UPDATE_DELAY = 200 <NEW_LINE> MAX_FRAMERATE = 25 <NEW_LINE> def __init__(self, display): <NEW_LINE> <INDENT> self.display = display <NEW_LINE> self.playing = False <NEW_LINE> self.current_frame = 0 <NEW_LINE> self.maxframe = 0 <NEW_LINE> self.loop = False <NEW_LINE> self.u...
Handles all of the control variables and UI elements for running through the loaded timeline
62598ef2a8370b77170eec09
class ShortCounter(object): <NEW_LINE> <INDENT> def __init__(self, length=0, log=False, name=None): <NEW_LINE> <INDENT> self.count = 0 <NEW_LINE> self.log = log <NEW_LINE> self.minlen = length <NEW_LINE> self.name = name <NEW_LINE> <DEDENT> def test(self, s, id): <NEW_LINE> <INDENT> if len(s) < self.minlen: <NEW_LINE> ...
count sequences too short
62598ef2be383301e0252000
class SignError(ValueError): <NEW_LINE> <INDENT> pass
this is an exception to be raised if a parameter is passed to a method with the wrong sign (e.g. Ecriterion in DontLeaveBasin must be positive)
62598ef2a219f33f346c5058
class BookFactory(factory.Factory): <NEW_LINE> <INDENT> class Meta: <NEW_LINE> <INDENT> model = Book <NEW_LINE> <DEDENT> name = "Alice in Wonderland" <NEW_LINE> price = factory.LazyAttribute(lambda f: 3.99) <NEW_LINE> author = factory.SubFactory(AuthorFactory) <NEW_LINE> book_edition = factory.RelatedFactory("tests.tes...
Test factory with all the features.
62598ef2a8370b77170eec0a
class Application(Frame): <NEW_LINE> <INDENT> def __init__(self, parent): <NEW_LINE> <INDENT> Frame.__init__(self, parent) <NEW_LINE> self.parent = parent <NEW_LINE> self.strategy = StringVar() <NEW_LINE> self.minimal_size_var = StringVar() <NEW_LINE> self.size_unit_var = StringVar() <NEW_LINE> self.init_strategy_panel...
class responsible for glue logic with presenter
62598ef2be7bc26dc9251275
class Mutation(): <NEW_LINE> <INDENT> def __init__(self, mutation_id, ref_counts, var_counts): <NEW_LINE> <INDENT> self.id = mutation_id <NEW_LINE> self.ref_counts = ref_counts <NEW_LINE> self.var_counts = var_counts <NEW_LINE> self.states = [] <NEW_LINE> <DEDENT> def setStates(self, states): <NEW_LINE> <INDENT> self.s...
Mutation Helper class that keeps track of each mutation and it's states
62598ef201c39578d7f115c9
class AmazonPayErrorResponse(object): <NEW_LINE> <INDENT> deserialized_types = { 'error_code': 'str', 'error_message': 'str' } <NEW_LINE> attribute_map = { 'error_code': 'errorCode', 'error_message': 'errorMessage' } <NEW_LINE> supports_multiple_types = False <NEW_LINE> def __init__(self, error_code=None, error_message...
Error response for SetupAmazonPay and ChargeAmazonPay calls. :param error_code: Error code indicating the succinct cause of error :type error_code: (optional) str :param error_message: Description of the error. :type error_message: (optional) str
62598ef267a9b606de5447f4
class Collision(object): <NEW_LINE> <INDENT> def __init__(self, line_count): <NEW_LINE> <INDENT> self.line_count = line_count <NEW_LINE> self.leaves = self._leaves() <NEW_LINE> <DEDENT> def _leaves(self): <NEW_LINE> <INDENT> return [0] * self.line_count <NEW_LINE> <DEDENT> def detect(self, display): <NEW_LINE> <INDENT>...
碰撞处理
62598ef23d592f4c4edb9712
class NetdiffException(Exception): <NEW_LINE> <INDENT> pass
root netdiff exception
62598ef2442bda511e95ac88
class SystemGatewayPublicDirectoryTestCase(BaseTestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> super(SystemGatewayPublicDirectoryTestCase, self).setUp() <NEW_LINE> self.gw = SystemGateway() <NEW_LINE> self.user1 = make_storage_user(username='sharer') <NEW_LINE> self.vgw = ReadWriteVolumeGateway(self...
Test public directory operations.
62598ef21f5feb6acb161479
class TestPublishFormPackaged(mkt.site.tests.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.app = app_factory(status=mkt.STATUS_PUBLIC, is_packaged=True) <NEW_LINE> self.ver1 = self.app.current_version <NEW_LINE> self.ver1.update(created=self.days_ago(1)) <NEW_LINE> self.ver2 = version_factory...
Test that changing the app visibility doesn't affect the version statuses in weird ways.
62598ef2f9cc0f698b1c46e2
class ImageTestCase(TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.user = UserFactory.create() <NEW_LINE> self.user.set_password('secret') <NEW_LINE> self.user.save() <NEW_LINE> self.album1 = Album.all_albums.create(title='album1', owner=self.user) <NEW_LINE> self.album1.save() <NEW_LINE> self...
Define a class with a series of image tests.
62598ef2e5267d203ee6a12f
class ToughLayoutCasesPageSet(page_set_module.PageSet): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> super(ToughLayoutCasesPageSet, self).__init__( user_agent_type='desktop', archive_data_file='data/tough_layout_cases.json', bucket=page_set_module.PARTNER_BUCKET) <NEW_LINE> urls_list = [ 'http://oilevent...
The slowest layouts observed in the alexa top 1 million sites in July 2013.
62598ef2379a373c97d9781d
class Exercise(models.Model): <NEW_LINE> <INDENT> exercise_name = models.CharField(max_length=100) <NEW_LINE> calories = models.IntegerField(default=0) <NEW_LINE> duration = models.IntegerField(default=0) <NEW_LINE> met = models.IntegerField(default=0) <NEW_LINE> date = models.DateTimeField('date exercise add', null=Tr...
Class for exercise models.
62598ef2851cf427c66b6aea
class FeatureEngineer(BaseEstimator, TransformerMixin): <NEW_LINE> <INDENT> def __init__(self, func, level='low', drop_correlated_features=False): <NEW_LINE> <INDENT> self.func = func <NEW_LINE> self.level = level <NEW_LINE> self.drop_correlated_features = drop_correlated_features <NEW_LINE> <DEDENT> def fit(self, X, y...
Custom sklearn transformer for using a feature engineering function, with args accessible via model tuning
62598ef2fff4ab517ebcbffe
@dataclass <NEW_LINE> class DataCollatorForSOP(DataCollatorForLanguageModeling): <NEW_LINE> <INDENT> def __init__(self, *args, **kwargs): <NEW_LINE> <INDENT> warnings.warn( "DataCollatorForSOP is deprecated and will be removed in a future version, you can now use " "DataCollatorForLanguageModeling instead.", FutureWarn...
Data collator used for sentence order prediction task. - collates batches of tensors, honoring their tokenizer's pad_token - preprocesses batches for both masked language modeling and sentence order prediction
62598ef2ff9c53063f518e86
class FileLock(object): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self._files = set() <NEW_LINE> <DEDENT> def acquire(self, files): <NEW_LINE> <INDENT> if not self._files.isdisjoint(files): <NEW_LINE> <INDENT> return False <NEW_LINE> <DEDENT> self._files.update(files) <NEW_LINE> return True <NEW_LINE>...
A file lock, excludes accessing the same files from different ports.
62598ef25fc7496912d47685
class DataTransformationOperatorManager(OperatorManager): <NEW_LINE> <INDENT> MANAGER_NAME = 'data-transformation' <NEW_LINE> def __new__(cls, *args, **kwargs): <NEW_LINE> <INDENT> if not hasattr(cls, '_instance'): <NEW_LINE> <INDENT> cls._instance = super().__new__(cls) <NEW_LINE> <DEDENT> return cls._instance <NEW_LI...
A data transformation operator manager
62598ef2377c676e912f6175
class JobsSPU(BaseModel): <NEW_LINE> <INDENT> name = models.CharField(max_length=20, verbose_name='岗位SPU名称') <NEW_LINE> detail = HTMLField(blank=True, verbose_name='岗位详情') <NEW_LINE> class Meta: <NEW_LINE> <INDENT> db_table = 'df_jobs_spu' <NEW_LINE> verbose_name = '岗位SPU' <NEW_LINE> verbose_name_plural = verbose_name ...
岗位SPU模型类
62598ef299cbb53fe682f6d5
class TimeoutError(Exception): <NEW_LINE> <INDENT> pass
Custom error for Timeout class.
62598ef2b7558d5895461e6d
class ExpiredTokenError(InvalidTokenError): <NEW_LINE> <INDENT> pass
Raised when an authentication token expired.
62598ef2bf627c535bcafc97
class TestClientSecret(ClientEndpoint): <NEW_LINE> <INDENT> @cached_property <NEW_LINE> def route(self) -> str: <NEW_LINE> <INDENT> user_id = self.get_client(self.user).user_id <NEW_LINE> return f'/client/secret/{user_id}' <NEW_LINE> <DEDENT> def test_permission_denied(self) -> None: <NEW_LINE> <INDENT> client = self.g...
Integration tests for /client/secret/<user_id> endpoints.
62598ef216aa5153ce3fed28
class SimpleRedisQueue(object): <NEW_LINE> <INDENT> def __init__(self, name, namespace='queue', **redis_kwargs): <NEW_LINE> <INDENT> self.__db= redis.Redis(**redis_kwargs) <NEW_LINE> self.key = '%s:%s' %(namespace, name) <NEW_LINE> logging.info("Redis key : %s param : %s"%(self.key,str(redis_kwargs))) <NEW_LINE> loggi...
Simple Queue with Redis list
62598ef256ac1b37e6300a14
class TestV1ServicePort(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def tearDown(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def testV1ServicePort(self): <NEW_LINE> <INDENT> pass
V1ServicePort unit test stubs
62598ef267a9b606de5447f5
class QLearningAgent(ReinforcementAgent): <NEW_LINE> <INDENT> def __init__(self, **args): <NEW_LINE> <INDENT> ReinforcementAgent.__init__(self, **args) <NEW_LINE> self.q_value = util.Counter() <NEW_LINE> "*** YOUR CODE HERE ***" <NEW_LINE> <DEDENT> def getQValue(self, state, action): <NEW_LINE> <INDENT> return self.q_v...
Q-Learning Agent Functions you should fill in: - computeValueFromQValues - computeActionFromQValues - getQValue - getAction - update Instance variables you have access to - self.epsilon (exploration prob) - self.alpha (learning rate) - self.discount (discount rate) Functions you should use - self.g...
62598ef2a8370b77170eec0c
class DuckDNSUpdater(BaseHTTPUpdater): <NEW_LINE> <INDENT> _api_url = 'https://www.duckdns.org/update' <NEW_LINE> _domains = None <NEW_LINE> _token = None <NEW_LINE> info_code = { "OK": "Success.", "KO": "Fail.", } <NEW_LINE> def __init__(self, domains, token, *args, **kwargs): <NEW_LINE> <INDENT> for k, v in {'domains...
https://{DOMAIN}/update?domains={DOMAINLIST}&token={TOKEN}&ip={IP} DOMAIN the service domain DOMAINLIST is either a single domain or a comma separated list of domains TOKEN is the API token for authentication/authorization IP is either the IP or blank for auto-detection
62598ef255399d3f05624d4d
@inside_glslc_testsuite('OptionsCapM') <NEW_LINE> class TestDashCapMMImpliesDashCapE(DependencyInfoStdoutMatch, expect.NoOutputOnStderr): <NEW_LINE> <INDENT> environment = Directory('.', [File('shader.glsl', MINIMAL_SHADER)]) <NEW_LINE> glslc_args = ['-MM', 'shader.glsl'] <NEW_LINE> dependency_rules_expected = [{'targe...
Tests that -M implies -E, a .glsl file without an explict stage should not generate an error. e.g. glslc -MM shader.glsl => shader.spv: shader.glsl <no error message should be generated>
62598ef24527f215b58e8726
class LabelInput(tk.Frame): <NEW_LINE> <INDENT> def __init__(self,parent,label="", input_class=ttk.Entry, input_var=None, input_args=None,label_args=None, **kwargs): <NEW_LINE> <INDENT> super().__init__(parent,**kwargs) <NEW_LINE> input_args = input_args or {} <NEW_LINE> label_args = label_args or {} <NEW_LINE> self.va...
a widget containting a label and input together. will make building form easier
62598ef28e7ae83300ee78b8
class UsernameMobileAuthBackend(ModelBackend): <NEW_LINE> <INDENT> def authenticate(self, request, username=None, password=None, **kwargs): <NEW_LINE> <INDENT> user = get_user_by_account(username) <NEW_LINE> if user and user.check_password(password): <NEW_LINE> <INDENT> return user
自定义用户认证后端
62598ef2d486a94d0ba2a7ef
@format_docstring(get_user_info_request, response_example=post_SocialSignUpOrIn_response) <NEW_LINE> class UserInfo(generics.ListAPIView): <NEW_LINE> <INDENT> serializer_class = UserSerializer <NEW_LINE> permission_classes = (IsAuthenticated,) <NEW_LINE> def get_queryset(self): <NEW_LINE> <INDENT> return User.objects.f...
User 정보 가능 메소드 : [ GET ] Request: {} Response: {response_example}
62598ef2460517430c430caf
class ToolIcon(BaseInteractiveItem): <NEW_LINE> <INDENT> def __init__(self, parent=None): <NEW_LINE> <INDENT> super(ToolIcon, self).__init__(parent) <NEW_LINE> self.size = QSize(64, 64) <NEW_LINE> <DEDENT> def paint(self, painter, option, widget): <NEW_LINE> <INDENT> pen = Qt.NoPen <NEW_LINE> painter.setPen(pen) <NEW_L...
A tool item constructed as an item group containing an icon and with additional visual elements. Treated as a single entity by Scene
62598ef223849d37ff84f8e3
class RelatedImpressionSerializer(serializers.ModelSerializer): <NEW_LINE> <INDENT> id = serializers.IntegerField() <NEW_LINE> name = serializers.ReadOnlyField() <NEW_LINE> class Meta: <NEW_LINE> <INDENT> fields = ( 'id', 'name', ) <NEW_LINE> model = Impression
Minimal Impression serializer that only serializes id and name.
62598ef260cbc95b06362b5e
class AuthorsSocialsListView(APIView): <NEW_LINE> <INDENT> def post(self, request, id=None): <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> body = json.loads(request.body) <NEW_LINE> <DEDENT> except: <NEW_LINE> <INDENT> return Response(status=400) <NEW_LINE> <DEDENT> if ( "date_start" not in body or "date_end" not in bod...
Task 6
62598ef2aad79263cf42d035
class NsRecordTestCase(TestCase): <NEW_LINE> <INDENT> def test_long_name_server(self): <NEW_LINE> <INDENT> expected_errors = { "name_server": [ "Cannot exceed 255 characters." ] } <NEW_LINE> name = "test." * 51 + "local" <NEW_LINE> with self.assertRaisesMessage(ValidationError, str(expected_errors)): <NEW_LINE> <INDENT...
Test case for NS records.
62598ef299fddb7c1ca62218
class Digital3DSystem(object): <NEW_LINE> <INDENT> def __init__(self, system): <NEW_LINE> <INDENT> self.active = get_boolean(system.IsActive) <NEW_LINE> self.configuration = get_string(system.Digital3DConfiguration) <NEW_LINE> self.install_date = get_datetime(system.InstallDate) <NEW_LINE> self.screen_color = get_strin...
Represents a digital 3D system installed in an auditorium. Mandatory fields: :ivar boolean active: Whether the 3D system is active or not. Optional fields: :ivar string configuration: A string describing the 3D configuration, eg. *"RealD"* or *"Dolby 3D"*. :ivar datetime install_date: The install date of the 3D sys...
62598ef244b2445a339b5d80
class FakeBranch: <NEW_LINE> <INDENT> def __init__(self, id): <NEW_LINE> <INDENT> self.id = id <NEW_LINE> <DEDENT> @property <NEW_LINE> def unique_name(self): <NEW_LINE> <INDENT> return branch_id_to_path(self.id)
Just enough of a Branch to pass `test_switch_branches`.
62598ef2baa26c4b54d4daf5
class USEquities(MarketSession): <NEW_LINE> <INDENT> timezone = pytz.timezone("US/Eastern")
US Equities market session.
62598ef2bd1bec0571e144df
class RepoId(_messages.Message): <NEW_LINE> <INDENT> projectRepoId = _messages.MessageField('ProjectRepoId', 1) <NEW_LINE> uid = _messages.StringField(2)
A unique identifier for a Cloud Repo. Fields: projectRepoId: A combination of a project ID and a repo name. uid: A server-assigned, globally unique identifier.
62598ef28da39b475be019d6
class Database(sqlite.Database): <NEW_LINE> <INDENT> def __init__(self, dbname, dbuser='', dbpass='', dbhost='localhost', dbport=3306, dbmode='a'): <NEW_LINE> <INDENT> self.__name__ = 'mysql' <NEW_LINE> self.dbname = dbname <NEW_LINE> self.__Trace__ = Trace <NEW_LINE> self.trace_names = [] <NEW_LINE> self._traces = {} ...
MySQL database.
62598ef2a8370b77170eec0d
class IntroduceArchivalFileConversionBlacklist(UpgradeStep): <NEW_LINE> <INDENT> def __call__(self): <NEW_LINE> <INDENT> self.install_upgrade_profile()
Introduce archival file conversion blacklist.
62598ef23346ee7daa336a7c
class Doc(Command): <NEW_LINE> <INDENT> def __init__(self, callback, uid, script, html): <NEW_LINE> <INDENT> self.script = script <NEW_LINE> self.html = html <NEW_LINE> super(Doc, self).__init__(callback, uid) <NEW_LINE> <DEDENT> def run(self): <NEW_LINE> <INDENT> processed = [] <NEW_LINE> try: <NEW_LINE> <INDENT> defi...
Get back a python definition where to go
62598ef201c39578d7f115cd
class MessageAddedHandler(BaseHandler): <NEW_LINE> <INDENT> def __init__( self, callback: Callable[["histories.History"], Any], labels: Union[list, str] = None, filters: Iterable[Callable[["histories.History"], bool]] = None, ) -> None: <NEW_LINE> <INDENT> super().__init__(callback, labels, filters, ["messageAdded"])
A handler class with the messageAdded history type filter. Parameters: callback (``callable``): A callback function to execute when there's a new update. The function should take one agrument which will be the :obj:`~google_workspace.gmail.histories.History`. labels (``list`` | ``str``, *optio...
62598ef226068e7796d4b186
class Host(models.Model): <NEW_LINE> <INDENT> HOST_STATUS = ( (0, '在线'), (1, '测试'), (2, '空闲'), (3, '其他'), ) <NEW_LINE> HOST_TYPE = ( (0, '虚拟机'), (1, '宿主机'), (2, '物理机'), ) <NEW_LINE> HOST_MODEL = ( (0, 'DELL 630'), (1, 'DELL 730XD'), (2, 'other'), ) <NEW_LINE> HOST_IMAGE = ( (0, 'centos_6.6_x86_64'), (1, 'redhat_6.6_x86...
主机管理
62598ef28e7ae83300ee78b9
class UniqueNoteQuarterLengths(featuresModule.FeatureExtractor): <NEW_LINE> <INDENT> id = 'QL1' <NEW_LINE> def __init__(self, dataOrStream=None, *arguments, **keywords): <NEW_LINE> <INDENT> featuresModule.FeatureExtractor.__init__(self, dataOrStream=dataOrStream, *arguments, **keywords) <NEW_LINE> self.name = 'Unique ...
>>> from music21 import * >>> s = corpus.parse('hwv56/movement3-05.md') >>> fe = features.native.UniqueNoteQuarterLengths(s) >>> fe.extract().vector [7]
62598ef24f6381625f1988d0
class RemoteScheduler(object): <NEW_LINE> <INDENT> def __init__(self, url='http://localhost:8082/', connect_timeout=None): <NEW_LINE> <INDENT> assert not url.startswith('http+unix://') or HAS_UNIX_SOCKET, ( 'You need to install requests-unixsocket for Unix socket support.' ) <NEW_LINE> self._url = url.rstrip('/') <NEW_...
Scheduler proxy object. Talks to a RemoteSchedulerResponder.
62598ef27d43ff2487426810
class FooterFilter(HeaderFilter): <NEW_LINE> <INDENT> aliases = ['ft'] <NEW_LINE> _settings = { 'key-name' : 'footer', 'footer' : ("Document key of file to use as footer.", None) } <NEW_LINE> def process_text(self, input_text): <NEW_LINE> <INDENT> footer_data = self.find_input_in_parent_dir("_footer") <NEW_LINE> return...
Apply another file to bottom of file.
62598ef27047854f4633dbf8
class SGDRScheduler(Callback): <NEW_LINE> <INDENT> def __init__(self, min_lr, max_lr, steps_per_epoch, lr_decay=1, cycle_length=10, mult_factor=2, initial_epoch=0): <NEW_LINE> <INDENT> self.min_lr = min_lr <NEW_LINE> self.max_lr = max_lr <NEW_LINE> self.lr_decay = lr_decay <NEW_LINE> self.batch_since_restart = 0 <NEW_L...
Cosine annealing learning rate scheduler with periodic restarts. # Usage ```python schedule = SGDRScheduler(min_lr=1e-5, max_lr=1e-2, steps_per_epoch=np.ceil(epoch_size/batch_size), lr_decay=0.9, ...
62598ef2851cf427c66b6aee
@attr.s(eq=False) <NEW_LINE> class Tag(Pretty, BaseEntity, Updateable): <NEW_LINE> <INDENT> pretty_attrs = ['name', 'display_name'] <NEW_LINE> display_name = attr.ib() <NEW_LINE> name = attr.ib(default=None) <NEW_LINE> def __eq__(self, other): <NEW_LINE> <INDENT> return ( self.display_name == getattr(other, 'display_na...
Class represents a category in CFME UI Args: name: Name of the tag display_name: Tag display name category: Tags Category
62598ef2d268445f26638fa4
class BidirectionalBreadthFirstSearch: <NEW_LINE> <INDENT> def __init__(self, start, goal): <NEW_LINE> <INDENT> self.fwd_bfs = BreadthFirstSearch(start, goal) <NEW_LINE> self.bwd_bfs = BreadthFirstSearch(goal, start) <NEW_LINE> self.reached = False <NEW_LINE> <DEDENT> def search(self) -> list[tuple[int]]: <NEW_LINE> <I...
>>> bd_bfs = BidirectionalBreadthFirstSearch((0, 0), (len(grid) - 1, ... len(grid[0]) - 1)) >>> bd_bfs.fwd_bfs.start.pos == bd_bfs.bwd_bfs.target.pos True >>> bd_bfs.retrace_bidirectional_path(bd_bfs.fwd_bfs.start, ... bd_bfs.bwd_bfs....
62598ef2379a373c97d97821
class SchedulerHook(base.ProcessingHook): <NEW_LINE> <INDENT> KEYS = ('cpus', 'cpu_arch', 'memory_mb', 'local_gb') <NEW_LINE> def before_update(self, introspection_data, node_info, **kwargs): <NEW_LINE> <INDENT> inventory = utils.get_inventory(introspection_data, node_info=node_info) <NEW_LINE> errors = [] <NEW_LINE> r...
Nova scheduler required properties.
62598ef25fdd1c0f98e5c7cc
class TimeseriesAggregator(Aggregator): <NEW_LINE> <INDENT> def __init__(self, *args, **kwargs): <NEW_LINE> <INDENT> self.step = settings.STEP_SIZE <NEW_LINE> self.max_distance = self.step * 5.0 <NEW_LINE> Aggregator.__init__(self, *args, **kwargs) <NEW_LINE> <DEDENT> def aggregate(self, results): <NEW_LINE> <INDENT> m...
Time series aggregator. Runs the jobs (which are all assumed to output a series of timed entries) and combines the times onto a single timeline, aligning values to the same time steps (interpolating values as necessary). Assumes each job outputs a list of pairs (time, value) where the times and values are floating poin...
62598ef22ae34c7f260a990b
class Guitar: <NEW_LINE> <INDENT> def __init__(self, name="", year=0, cost=0): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> self.year = year <NEW_LINE> self.cost = cost <NEW_LINE> <DEDENT> def get_age(self): <NEW_LINE> <INDENT> return 2020 - int(self.year) <NEW_LINE> <DEDENT> def is_vintage(self): <NEW_LINE> <INDENT...
Represent a Guitar Object
62598ef25fdd1c0f98e5c7cd
class Spinner: <NEW_LINE> <INDENT> busy = False <NEW_LINE> delay = 0.1 <NEW_LINE> @staticmethod <NEW_LINE> def spinning_cursor(): <NEW_LINE> <INDENT> while 1: <NEW_LINE> <INDENT> for cursor in '|/-\\': <NEW_LINE> <INDENT> yield cursor <NEW_LINE> <DEDENT> <DEDENT> <DEDENT> def __init__(self, delay=None): <NEW_LINE> <IND...
Spinner running in a separate thread
62598ef25fcc89381b26553e
class LiverConfig(Config): <NEW_LINE> <INDENT> NAME = "liver" <NEW_LINE> IMAGES_PER_GPU = 2 <NEW_LINE> NUM_CLASSES = 1 + 1 <NEW_LINE> STEPS_PER_EPOCH = 100 <NEW_LINE> DETECTION_MIN_CONFIDENCE = 0.9 <NEW_LINE> LEARNING_RATE = 1e-3 <NEW_LINE> MAX_GT_INSTANCES = 100 <NEW_LINE> IMAGE_RESIZE_MODE = "square" <NEW_LINE> IMAGE...
Configuration for training on the toy dataset. Derives from the base Config class and overrides some values.
62598ef24428ac0f6e656d78
class API(wsgi.Router): <NEW_LINE> <INDENT> def __init__(self, mapper): <NEW_LINE> <INDENT> mapper = mapper or wsgi.APIMapper() <NEW_LINE> init(mapper) <NEW_LINE> super(API, self).__init__(mapper)
WSGI entry point for satisfy grenade.
62598ef27b180e01f3e4845b
class NegativeIdentity(SemanticPointer): <NEW_LINE> <INDENT> def __init__( self, n_dimensions, vocab=None, algebra=None, *, sidedness=ElementSidedness.TWO_SIDED, ): <NEW_LINE> <INDENT> data = self._get_algebra(vocab, algebra).negative_identity_element( n_dimensions, sidedness=sidedness ) <NEW_LINE> super(NegativeIdenti...
Negative identity element. Parameters ---------- n_dimensions : int Dimensionality of the negative identity vector. vocab : Vocabulary, optional Vocabulary that the Semantic Pointer is considered to be part of. Mutually exclusive with the *algebra* argument. algebra : AbstractAlgebra, optional Algebra ...
62598ef2f548e778e5969db7
class Hardware(object): <NEW_LINE> <INDENT> def __init__(self, name=None): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> <DEDENT> def __str__(self): <NEW_LINE> <INDENT> if self.name is None: <NEW_LINE> <INDENT> return "Hardware chain does not exist" <NEW_LINE> <DEDENT> else: <NEW_LINE> <INDENT> return self.name <NEW_...
All functionality relating to jtag hardware (i.e., a usb-blaster)
62598ef2fff4ab517ebcc003
class Configuration: <NEW_LINE> <INDENT> def __init__(self, filename=None): <NEW_LINE> <INDENT> self.filename = filename <NEW_LINE> <DEDENT> def load(self): <NEW_LINE> <INDENT> success = False <NEW_LINE> if self.filename is not None and os.path.isfile(self.filename): <NEW_LINE> <INDENT> with open(self.filename, 'r') as...
Loads and stores a configuration file or buffer
62598ef2d7e4931a7ef3a8c6
class Primes: <NEW_LINE> <INDENT> def __init__(self, n): <NEW_LINE> <INDENT> self.n = n <NEW_LINE> <DEDENT> def __iter__(self): <NEW_LINE> <INDENT> if self.n <= 2: <NEW_LINE> <INDENT> return <NEW_LINE> <DEDENT> p = 2 <NEW_LINE> yield p <NEW_LINE> numbers_left = set(xrange(3, self.n, 2)) <NEW_LINE> while p**2 <= self.n:...
Iterator for all prime numbers smaller than a specified value. Generates primes with Sieve of Eratosthenes. >>> list(Primes(60)) [2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59]
62598ef267a9b606de5447f9
class Mappings(InfoCmd): <NEW_LINE> <INDENT> options = [Bcfg2.Options.PositionalArgument("type", nargs='?'), Bcfg2.Options.PositionalArgument("name", nargs='?')] <NEW_LINE> def run(self, setup): <NEW_LINE> <INDENT> data = [('Plugin', 'Type', 'Name')] <NEW_LINE> for generator in self.core.plugins_by_type( Bcfg2.Server.P...
Print generator mappings for optional type and name
62598ef24527f215b58e872a
class remoteProc(): <NEW_LINE> <INDENT> t1=None <NEW_LINE> x =1 <NEW_LINE> y =1 <NEW_LINE> infoData="This is data" <NEW_LINE> keepLooping=True <NEW_LINE> num=None <NEW_LINE> arr=None <NEW_LINE> def __init__(self, num=Value('d', 0.0), arr= Array('f', range(10)), keepLooping=Value('i', 1)): <NEW_LINE> <INDENT> self.num=n...
The remoteProc class contains the shared Python variables as well as its own parameters and the "complicated" function requiring running in the background as its own process. The main process can access the multiprocessing variables of num, arr and keepLooping. Users can control the loop running in a thread by sett...
62598ef2e5267d203ee6a134
class TestCodecs(TestCaseBase): <NEW_LINE> <INDENT> def test_vp8(self): <NEW_LINE> <INDENT> cmd = self.cmd + ["--input-dir", TEST_BAT_VP8_DIR] <NEW_LINE> result = self.run_cmd(cmd) <NEW_LINE> self.assertEqual(result.status(), True) <NEW_LINE> self.assert_codec_name(self.output_dir, "hevc") <NEW_LINE> <DEDENT> def test_...
Codecs TestCase
62598ef2442bda511e95ac8e
class SearchEngine(object): <NEW_LINE> <INDENT> def __init__(self, directory): <NEW_LINE> <INDENT> self.directory = directory <NEW_LINE> <DEDENT> def _findAllFilesInDirectory(self, namePattern): <NEW_LINE> <INDENT> matches = [] <NEW_LINE> for root, dirnames, filenames in os.walk(self.directory): <NEW_LINE> <INDENT> for...
Reimplementation of grep in Python, with context
62598ef21f5feb6acb16147f
class PipelineUpdater(Updater): <NEW_LINE> <INDENT> def __init__(self, *args, application_name='', **kwargs): <NEW_LINE> <INDENT> self.application_name = application_name <NEW_LINE> super().__init__(*args, **kwargs) <NEW_LINE> <DEDENT> @property <NEW_LINE> def name(self): <NEW_LINE> <INDENT> return self.pipeline['name'...
Update Spinnaker Pipeline.
62598ef27047854f4633dbfa
class CertifiersOf(WOT): <NEW_LINE> <INDENT> def __init__(self, connection_handler, search, module='wot'): <NEW_LINE> <INDENT> super(WOT, self).__init__(connection_handler, module) <NEW_LINE> self.search = search <NEW_LINE> <DEDENT> def __get__(self, **kwargs): <NEW_LINE> <INDENT> assert self.search is not None <NEW_LI...
GET Certification data over a member.
62598ef2a17c0f6771d5aa80
@api.route("", endpoint="loaded_samples") <NEW_LINE> @api.doc(security="apikey") <NEW_LINE> class LoadedSample(Resource): <NEW_LINE> <INDENT> @authentication_required <NEW_LINE> @authorization_required <NEW_LINE> def get(self): <NEW_LINE> <INDENT> return loaded_sample.get_loaded_samples(request) <NEW_LINE> <DEDENT> @au...
Loaded sample resource
62598ef2460517430c430cb3
class RedisBuffer(redis.client.Pipeline): <NEW_LINE> <INDENT> def __init__(self, connection_pool, response_callbacks, transaction, buffer_size, shard_hint=None): <NEW_LINE> <INDENT> self._buffer_size = buffer_size <NEW_LINE> super(RedisBuffer, self).__init__( connection_pool, response_callbacks, transaction, shard_hint...
A bufferized version of `redis.pipeline.Pipeline`. The only difference from the conventional pipeline object is the ``_buffer_size``. Once the buffer is longer than the buffer size, the pipeline is automatically executed, and the buffer cleared.
62598ef2aad79263cf42d039
class Q: <NEW_LINE> <INDENT> array = None <NEW_LINE> def __init__(self, array): <NEW_LINE> <INDENT> self.array = array <NEW_LINE> <DEDENT> def __and__(self, other): <NEW_LINE> <INDENT> return np.logical_and(self.array, other.array) <NEW_LINE> <DEDENT> def __or__(self, other): <NEW_LINE> <INDENT> return np.logical_or(se...
advanced query manager for Table
62598ef291f36d47f22302ba
class InputBatchesRolloverCorrectlyTestCase(BaseDataBatcherTestCase): <NEW_LINE> <INDENT> def runTest(self): <NEW_LINE> <INDENT> x, _, _ = self.db.next_batch(5) <NEW_LINE> self.assertEqual(x[0, 0], 0) <NEW_LINE> x, _, _ = self.db.next_batch(5) <NEW_LINE> self.assertEqual(x[0, 0], 5) <NEW_LINE> x, _, _ = self.db.next_ba...
Provides a test for returning the correct input batch after rolling over an epoch. Inherits from the BaseDataBatcherTestCase.
62598ef2a219f33f346c505f
class Container(Sequence): <NEW_LINE> <INDENT> def __init__( self, separator, sequence=[], esc="\\", separators="\r|~^&", factory=None ): <NEW_LINE> <INDENT> assert separator in separators <NEW_LINE> super(Container, self).__init__(sequence) <NEW_LINE> self.separator = separator <NEW_LINE> self.esc = esc <NEW_LINE> sel...
Abstract root class for the parts of the HL7 message.
62598ef299fddb7c1ca6221a
@pytest.mark.components <NEW_LINE> @pytest.allure.story('Groups') <NEW_LINE> @pytest.allure.feature('POST') <NEW_LINE> class Test_PFE_Components(object): <NEW_LINE> <INDENT> @pytest.allure.link('https://jira.qumu.com/browse/TC-45517') <NEW_LINE> @pytest.mark.Groups <NEW_LINE> @pytest.mark.POST <NEW_LINE> def test_TC_45...
PFE Groups test cases.
62598ef2fff4ab517ebcc004
class CarBase: <NEW_LINE> <INDENT> def __init__(self, car_type, brand, photo_file_name, carrying): <NEW_LINE> <INDENT> self.car_type = car_type <NEW_LINE> self.brand = brand <NEW_LINE> self.photo_file_name = photo_file_name <NEW_LINE> self.carrying = carrying <NEW_LINE> <DEDENT> def get_photo_file_ext(self): <NEW_LINE>...
Base class with attributes and methods
62598ef299cbb53fe682f6db
class Picture(Object): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> super().__init__() <NEW_LINE> self.content = None <NEW_LINE> <DEDENT> @staticmethod <NEW_LINE> def create_from_bytes(content: bin) -> 'Picture': <NEW_LINE> <INDENT> if binascii.hexlify(content[:2]) == b'424d': <NEW_LINE> <INDENT> pic = B...
A Picture object. Note that picture objects are not associated with a CLSID and cannot be automatically read from a stream!
62598ef24c34283577618b13
class NameClashError(Error): <NEW_LINE> <INDENT> def __init__(self, old_name, new_name, klass): <NEW_LINE> <INDENT> Error.__init__(self, old_name, new_name, klass) <NEW_LINE> self.old_name = old_name <NEW_LINE> self.new_name = new_name <NEW_LINE> self.klass = klass
A name clash occurred while trying to alias old method names.
62598ef2097d151d1a2bf84d
class PacketCaptureListResult(msrest.serialization.Model): <NEW_LINE> <INDENT> _attribute_map = { 'value': {'key': 'value', 'type': '[PacketCaptureResult]'}, } <NEW_LINE> def __init__( self, **kwargs ): <NEW_LINE> <INDENT> super(PacketCaptureListResult, self).__init__(**kwargs) <NEW_LINE> self.value = kwargs.get('value...
List of packet capture sessions. :param value: Information about packet capture sessions. :type value: list[~azure.mgmt.network.v2020_06_01.models.PacketCaptureResult]
62598ef221bff66bcd721482
class Square: <NEW_LINE> <INDENT> def __init__(self, size): <NEW_LINE> <INDENT> self.__size = size
class square that has attributes: size
62598ef25fdd1c0f98e5c7cf
class PIC(Module): <NEW_LINE> <INDENT> images = [ "local/donut:1.0.0", ] <NEW_LINE> @classmethod <NEW_LINE> def add_arguments(cls, parser): <NEW_LINE> <INDENT> parser.add_argument("-m", "--method", type=str, help="Method to invoke") <NEW_LINE> parser.add_argument("-p", "--parameter", type=str, action="append", help="Pa...
Wrap the supplied Windows x86 DLL as position-independent code (PIC).
62598ef2d58c6744b42db6cc
class FlashNewsView(APIView): <NEW_LINE> <INDENT> permission_classes = [AllowAny, ] <NEW_LINE> def get(self, request): <NEW_LINE> <INDENT> items = Item.objects.filter(category_id = 2, is_deleted=False).order_by('-created_time')[:20] <NEW_LINE> serializer = GetItemSerializer(items, many=True) <NEW_LINE> res = { 'error':...
Get all Categories
62598ef271ff763f4b5e5f8c
class RoomStateRestServlet(RestServlet): <NEW_LINE> <INDENT> PATTERNS = admin_patterns("/rooms/(?P<room_id>[^/]*)/state$") <NEW_LINE> def __init__(self, hs: "HomeServer"): <NEW_LINE> <INDENT> self.auth = hs.get_auth() <NEW_LINE> self.store = hs.get_datastore() <NEW_LINE> self.clock = hs.get_clock() <NEW_LINE> self._eve...
Get full state within a room.
62598ef232920d7e50bc4859
class RecipeDetailSerializer(RecipeSerializer): <NEW_LINE> <INDENT> ingredients = IngredientSerializer(many=True, read_only=True) <NEW_LINE> tags = TagSerializer(many=True, read_only=True)
serializer for recipe detail object
62598ef2a219f33f346c5060
class ShowIpOspfMaxMetricSchema(MetaParser): <NEW_LINE> <INDENT> schema = { 'vrf': {Any(): {'address_family': {Any(): {'instance': {Any(): {'router_id': str, 'base_topology_mtid': {Any(): {'start_time': str, 'time_elapsed': str, 'router_lsa_max_metric': {Any(): {Optional('condition'): str, Optional('state'): str, Optio...
Schema for: * 'show ip ospf max-metric'
62598ef24f6381625f1988d2
@util.export <NEW_LINE> class Plugin(plugin.PluginBase, packager.PackagerBase): <NEW_LINE> <INDENT> def install(self, packages, ignoreErrors=False): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def update(self, packages, ignoreErrors=False): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def queryPackages(self, patterns=...
Offline packager.
62598ef28e7ae83300ee78be
class HashTable_tb2: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.testcase_max_value = 500000 <NEW_LINE> self.testcase_max_length = 200000 <NEW_LINE> <DEDENT> def gen_test_case(self): <NEW_LINE> <INDENT> keys = set([random.randint(0, self.testcase_max_value) for i in range(1, self.testcase_max_lengt...
testbench
62598ef2d486a94d0ba2a7f5