code stringlengths 4 4.48k | docstring stringlengths 1 6.45k | _id stringlengths 24 24 |
|---|---|---|
class VerisureEthernetStatus(BinarySensorEntity): <NEW_LINE> <INDENT> @property <NEW_LINE> def name(self): <NEW_LINE> <INDENT> return "Verisure Ethernet status" <NEW_LINE> <DEDENT> @property <NEW_LINE> def is_on(self): <NEW_LINE> <INDENT> return hub.get_first("$.ethernetConnectedNow") <NEW_LINE> <DEDENT> @property <NEW... | Representation of a Verisure VBOX internet status. | 62598f6566673b3332c2fa88 |
class Halcyon(Bitcoin): <NEW_LINE> <INDENT> name = 'halcyon' <NEW_LINE> symbols = ('HAL', ) <NEW_LINE> seeds = ('seed0.phoenixcoin.org', 'seed1.phoenixcoin.org', ) <NEW_LINE> port = 21108 <NEW_LINE> message_start = b'\xa1\xa0\xa2\xa3' <NEW_LINE> base58_prefixes = { 'PUBKEY_ADDR': 40, 'SCRIPT_ADDR': 28, 'SECRET_KEY': 16... | Class with all the necessary Halcyon network information based on
https://github.com/ghostlander/halcyon/blob/master/src/net.cpp
(date of access: 02/12/2018) | 62598f65d164cc6175820646 |
class ConstructabilityState(Enum): <NEW_LINE> <INDENT> UNVERIFIED = "unverified" <NEW_LINE> REQUIRES_MEASURES = "requires_measures" <NEW_LINE> ENQUIRY_SENT = "enquiry_sent" <NEW_LINE> COMPLETE = "complete" <NEW_LINE> class Labels: <NEW_LINE> <INDENT> UNVERIFIED = pgettext_lazy("Constructability state", "Unverified") <N... | In Finnish: Selvitysaste | 62598f6521bff66bcd722328 |
@pytest.mark.skipif(django.VERSION < (1, 8) or compat.postgres_fields is None, reason='RangeField is only available for django1.8+' ' and with psycopg2.') <NEW_LINE> class TestIntegerRangeField(FieldValues): <NEW_LINE> <INDENT> if compat.NumericRange is not None: <NEW_LINE> <INDENT> valid_inputs = [ ({'lower': '1', 'up... | Values for `ListField` with CharField as child. | 62598f656e29344779affd27 |
class InstanceSpec(AbstractModel): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.Cpu = None <NEW_LINE> self.Memory = None <NEW_LINE> self.MaxStorageSize = None <NEW_LINE> self.MinStorageSize = None <NEW_LINE> <DEDENT> def _deserialize(self, params): <NEW_LINE> <INDENT> self.Cpu = params.get("Cpu") <N... | 实例可售卖规格详细信息,创建实例时Cpu/Memory确定实例规格,存储可选大小为[MinStorageSize,MaxStorageSize]
| 62598f65c432627299fa26a0 |
class StaticVBar(Actor): <NEW_LINE> <INDENT> @manage(['params', 'dimension', 'max_req_in_progress', 'labels', 'values']) <NEW_LINE> def init(self, chart_param={}, dimension=10, max_req_in_progress=5): <NEW_LINE> <INDENT> self.params = chart_param <NEW_LINE> self.dimension = dimension <NEW_LINE> self.max_req_in_progress... | An actor for creating vertical bar charts.
chart_param: Initial settings for the chart specific parameters
dimension: The number of accumulated values to show simultaneously
max_req_in_progress: Max nbr of async threads for requesting chart images
Inputs:
values: list of values
labels: list of l... | 62598f6515baa72349461653 |
class MsgReset(SBP): <NEW_LINE> <INDENT> def __init__(self, sbp=None, **kwargs): <NEW_LINE> <INDENT> if sbp: <NEW_LINE> <INDENT> self.__dict__.update(sbp.__dict__) <NEW_LINE> self.payload = sbp.payload <NEW_LINE> <DEDENT> <DEDENT> def __repr__(self): <NEW_LINE> <INDENT> return fmt_repr(self) | SBP class for message MSG_RESET (0x00B2).
You can have MSG_RESET inherent its fields directly
from an inherited SBP object, or construct it inline using a dict
of its fields.
This message from the host resets the Piksi back into the
bootloader. It ensures that all outstanding memory accesses
including buff... | 62598f655166f23b2e242aa7 |
class UnaddableError(ContainerError): <NEW_LINE> <INDENT> def __init__(self, container, obj, message=""): <NEW_LINE> <INDENT> self.container = container <NEW_LINE> self.obj = obj <NEW_LINE> self.message = message and ": %s" % message <NEW_LINE> <DEDENT> def __str__(self): <NEW_LINE> <INDENT> return ("%(obj)s cannot be ... | An object cannot be added to a container. | 62598f65925a0f43d25e7706 |
class Orf: <NEW_LINE> <INDENT> def __init__(self, contig, start, end, strand): <NEW_LINE> <INDENT> self.contig = contig <NEW_LINE> self.start = int(start) <NEW_LINE> self.end = int(end) <NEW_LINE> self.strand = +1 if strand == '+' else -1 <NEW_LINE> self.sequence = str() | Used to represent an ORF and is associated with a BlastResult instance | 62598f65bf627c535bcb0b4f |
class StalkerSceneAddPrevisOperator(bpy.types.Operator): <NEW_LINE> <INDENT> bl_label = 'Add Previs Only' <NEW_LINE> bl_idname = 'stalker.scene_add_previs_op' <NEW_LINE> stalker_entity_id = bpy.props.IntProperty(name='stalker_entity_id') <NEW_LINE> stalker_entity_name = bpy.props.StringProperty(name='stalker_entity_nam... | Adds the previs output of this scene | 62598f6563f4b57ef00858d6 |
class DependentHostedNumberOrderList(ListResource): <NEW_LINE> <INDENT> def __init__(self, version, signing_document_sid): <NEW_LINE> <INDENT> super(DependentHostedNumberOrderList, self).__init__(version) <NEW_LINE> self._solution = {'signing_document_sid': signing_document_sid, } <NEW_LINE> self._uri = '/Authorization... | PLEASE NOTE that this class contains preview products that are subject
to change. Use them with caution. If you currently do not have developer
preview access, please contact help@twilio.com. | 62598f650a366e3fb87dc08f |
class AlgoLookup(object): <NEW_LINE> <INDENT> pub_algorithms = { 1: "RSA Encrypt or Sign", 2: "RSA Encrypt-Only", 3: "RSA Sign-Only", 16: "ElGamal Encrypt-Only", 17: "DSA Digital Signature Algorithm", 18: "Elliptic Curve", 19: "ECDSA", 20: "Formerly ElGamal Encrypt or Sign", 21: "Diffie-Hellman", } <NEW_LINE> @class... | Mixin class containing algorithm lookup methods. | 62598f6591af0d3eaad394d7 |
@interface <NEW_LINE> class HttpPlugin (object): <NEW_LINE> <INDENT> def handle(self, context): <NEW_LINE> <INDENT> for name, method in self.__class__.__dict__.iteritems(): <NEW_LINE> <INDENT> if hasattr(method, '_url_pattern'): <NEW_LINE> <INDENT> method = getattr(self, name) <NEW_LINE> match = method._url_pattern.mat... | A base plugin class for HTTP request handling::
@plugin
class TerminalHttp (BasePlugin, HttpPlugin):
@url('/terminal/(?P<id>\d+)')
def get_page(self, context, id):
if context.session.identity is None:
context.respond_redirect('/')
context.add_header('Cont... | 62598f6566673b3332c2fa8a |
class DataGridFieldObjectSubForm(ObjectSubForm): <NEW_LINE> <INDENT> def updateWidgets(self): <NEW_LINE> <INDENT> rv = super(DataGridFieldObjectSubForm, self).updateWidgets() <NEW_LINE> if hasattr(self.parentForm, 'datagridUpdateWidgets'): <NEW_LINE> <INDENT> self.parentForm.datagridUpdateWidgets( self, self.widgets, s... | Local class of subform - this is intended to all configuration
information to be passed all the way down to the subform.
All the parent and form nesting can be confusing, especially so
when you throw fieldsets (groups) into the mix. So some notes.
When the datagrid object is part of a standard form without a
fieldse... | 62598f6530c21e258be97ecc |
class Substation(EquipmentContainer): <NEW_LINE> <INDENT> def __init__(self, Substation_SubstationFeeder: List['Feeder'] = None, EquipmentContainer_Equipments: List['Equipment'] = None, IdentifiedObject_mRID: str = None, IdentifiedObject_name: str = None): <NEW_LINE> <INDENT> super().__init__(EquipmentContainer_Equipme... | A collection of equipment for purposes other than generation or utilization, through which electric energy in bulk is passed for the purposes of switching or modifying its characteristics. | 62598f65a8ecb033258708d3 |
class precomputed_kernel(object): <NEW_LINE> <INDENT> def __init__(self, kmatrix, copy=False): <NEW_LINE> <INDENT> kmatrix = np.ascontiguousarray(kmatrix, np.double, copy=copy) <NEW_LINE> self.kernel_nr_ = 1 <NEW_LINE> self.kernel_arg_ = 0. <NEW_LINE> <DEDENT> def __call__(self, x0, x1): <NEW_LINE> <INDENT> return kmat... | kernel = precomputed_kernel(kmatrix)
A "fake" kernel which is precomputed. | 62598f651f037a2d8b9e37bf |
class Optimal_Readout_Power(ORC): <NEW_LINE> <INDENT> def __init__(self, qubit_info, powers, plen=None, amp=1.0, **kwargs): <NEW_LINE> <INDENT> self.qubit_info = qubit_info <NEW_LINE> self.plen = plen <NEW_LINE> self.amp = amp <NEW_LINE> super(Optimal_Readout_Power, self).__init__(infos=qubit_info, powers=powers, swept... | This is the simplest possible use of ORC. We compare a pi pulse
to no pi pulse and sweep readout power.
We're not actually sweeping a sequence parameter, so the generated
sequence is only two elements. Swept params is a dummy list of one
element. | 62598f651d351010ab8f3212 |
class Memory(object): <NEW_LINE> <INDENT> read_only = False <NEW_LINE> load_listeners = None <NEW_LINE> store_listeners = None <NEW_LINE> def __init__(self): <NEW_LINE> <INDENT> self.load_listeners = list() <NEW_LINE> self.store_listeners = list() <NEW_LINE> <DEDENT> def __getitem__(self, index): <NEW_LINE> <INDENT> if... | The :class:`Memory` class is the base class for :class:`Block` and
:class:`Bank`. It provides get and set item support with slices, memory
listeners, and read-only toggle support.
.. data:: m[address]
Gets or sets memory values at the specified *address*.
Slice syntax can be used but varies from the usual rules ... | 62598f65925a0f43d25e7708 |
class CifsShareGetIterKeyTd(NetAppObject): <NEW_LINE> <INDENT> _key_1 = None <NEW_LINE> @property <NEW_LINE> def key_1(self): <NEW_LINE> <INDENT> return self._key_1 <NEW_LINE> <DEDENT> @key_1.setter <NEW_LINE> def key_1(self, val): <NEW_LINE> <INDENT> if val != None: <NEW_LINE> <INDENT> self.validate('key_1', val) <NEW... | Key typedef for table cifs_share_byname | 62598f65287bf620b627128b |
class EntityMention(): <NEW_LINE> <INDENT> def __init__(self, text: str, intent: str, location: List[int]) -> None: <NEW_LINE> <INDENT> self.text = text <NEW_LINE> self.intent = intent <NEW_LINE> self.location = location <NEW_LINE> <DEDENT> @classmethod <NEW_LINE> def from_dict(cls, _dict: Dict) -> 'EntityMention': <NE... | An object describing a contextual entity mention.
:attr str text: The text of the user input example.
:attr str intent: The name of the intent.
:attr List[int] location: An array of zero-based character offsets that indicate
where the entity mentions begin and end in the input text. | 62598f658c3a8732951f5c20 |
class FileLock: <NEW_LINE> <INDENT> def __init__(self, name='/tmp/credshed.lock'): <NEW_LINE> <INDENT> self.file = Path(name).resolve() <NEW_LINE> self.interval = .1 <NEW_LINE> <DEDENT> def __enter__(self): <NEW_LINE> <INDENT> while 1: <NEW_LINE> <INDENT> if not self.file.is_file(): <NEW_LINE> <INDENT> with open(self.f... | Implements a simple sempahore using the filesystem | 62598f6573bcbd0ca4bc9923 |
class SpeakerForms(messages.Message): <NEW_LINE> <INDENT> items = messages.MessageField(SpeakerForm, 1, repeated=True) | Multiple Speaker outbound form message | 62598f6526238365f5fac246 |
class Test_iter_cards(unittest.TestCase): <NEW_LINE> <INDENT> def test_next(self): <NEW_LINE> <INDENT> x = Deck.iter_cards() <NEW_LINE> result = next(x) <NEW_LINE> self.assertIsNotNone(result) <NEW_LINE> <DEDENT> def test_count(self): <NEW_LINE> <INDENT> x = Deck.iter_cards() <NEW_LINE> count = 0 <NEW_LINE> for unused ... | Unit tests for Deck.iter_cards() | 62598f6530c21e258be97ece |
class AvatarUploadForm(forms.Form): <NEW_LINE> <INDENT> avatar = forms.FileField( label = "", help_text = "", widget = forms.FileInput(attrs={'title':_('Change')}) ) | Upload user avatar | 62598f65a8ecb033258708d5 |
class TestNtpServerExtended(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 testNtpServerExtended(self): <NEW_LINE> <INDENT> pass | NtpServerExtended unit test stubs | 62598f65a4f1c619b294dcc5 |
class Movie(): <NEW_LINE> <INDENT> def __init__(self, movie_title, movie_storyline, poster_image, trailer_youtube): <NEW_LINE> <INDENT> self.title = movie_title <NEW_LINE> self.storyline = movie_storyline <NEW_LINE> self.poster_image_url = poster_image <NEW_LINE> self.trailer_youtube_url = trailer_youtube <NEW_LINE> <D... | Generates a movie object storing the movie's title,
storyline and links to its poster art and youtube trailer | 62598f65796e427e5384de66 |
class MacroNode(Node): <NEW_LINE> <INDENT> node_type = "macro" <NEW_LINE> def __init__(self, name, args=None, kwargs=None): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> self.args = args or [] <NEW_LINE> self.kwargs = kwargs or {} <NEW_LINE> try: <NEW_LINE> <INDENT> self.value = self.args[0] <NEW_LINE> <DEDENT> excep... | Base node for macros.
This node contains a macro, with a name and arguments.
Attributes:
value: the name of the macro
arguments: the string of arguments | 62598f65d164cc617582064b |
class action_createproc(action): <NEW_LINE> <INDENT> def __init__(self, rid, cwds, env, cmd, pipes, rlimits): <NEW_LINE> <INDENT> self.rid = rid <NEW_LINE> self.cwds = cwds <NEW_LINE> self.env = env <NEW_LINE> self.cmd = cmd <NEW_LINE> self.pipes = pipes <NEW_LINE> self.rlimits = rlimits | receiving this action, the daemon should create
a process with a specified command line (cmd),
working dir (cwd), environment (env), relative id
(rid), and open file descriptors (pipes).
relative id is an id given to the process unique
in the task the process belongs to.
for "pipes", see gxpc.py's add_down_pipe meth... | 62598f656e29344779affd2b |
class BlackAndWhite(gym.ObservationWrapper): <NEW_LINE> <INDENT> def __init__(self, env): <NEW_LINE> <INDENT> super(BlackAndWhite, self).__init__(env) <NEW_LINE> old_shape = self.observation_space.shape <NEW_LINE> self.observation_space = gym.spaces.Box(low=0.0, high=1.0, shape=(old_shape[0], old_shape[1], 1), dtype=np... | Converts to black and white | 62598f6656b00c62f0fb1f86 |
class ModelFlasktests(Modeltests): <NEW_LINE> <INDENT> def setup_db(self): <NEW_LINE> <INDENT> from tests.test_vote import Votetests <NEW_LINE> votes = Votetests("test_init_vote") <NEW_LINE> votes.session = self.session <NEW_LINE> votes.test_init_vote() <NEW_LINE> <DEDENT> def setUp(self): <NEW_LINE> <INDENT> super(Mod... | Model flask application tests. | 62598f660a366e3fb87dc093 |
class InsertionDeletionCost(SimilarityScorer): <NEW_LINE> <INDENT> def __init__(self, feature_weight = 1.0): <NEW_LINE> <INDENT> self.feature_weight = feature_weight <NEW_LINE> self.kDeletionCost = 1.0 <NEW_LINE> self.kInsertionCost = 1.0 <NEW_LINE> <DEDENT> def GetSimilarity(self, tree_pattern1, tree_pattern2): <NEW_L... | Implements the abstract methods from Similarity class. It counts the leaves
in the source tree and multiplies them by a deletion cost. Then, it counts
the leaves in the target tree and multiplies them by an insertion cost.
Finally, it adds up the insertion and deletion costs. | 62598f6676d4e153a661c2e7 |
class SchemaError(Exception): <NEW_LINE> <INDENT> pass | Classe base de exceções de schema(contrato) | 62598f668c3a8732951f5c23 |
class LocalCopyCreateEvent(Event): <NEW_LINE> <INDENT> def __str__(self): <NEW_LINE> <INDENT> id_ = self.args[0] <NEW_LINE> return "%s: local copy created at %s" % (str(id_), id_.to_local_copy()) | An event raised after the creation of a local copy of a suite.
event.args[0] is the SuiteId of the suite. | 62598f66d18da76e235b6c9f |
class Rpc(object): <NEW_LINE> <INDENT> def __init__(self, name='', params=(), rt=None, event=None, rt_array=False): <NEW_LINE> <INDENT> def tp(x): <NEW_LINE> <INDENT> return x.split('.')[-1] if x is not None else x <NEW_LINE> <DEDENT> def pkg(x): <NEW_LINE> <INDENT> return '.'.join(x.split('.')[:-1]) if x is not None e... | Class to represent a remote procedure call | 62598f6630c21e258be97ed0 |
class Applet(QObject): <NEW_LINE> <INDENT> def __init__(self, parent=None): <NEW_LINE> <INDENT> QObject.__init__(self, parent) <NEW_LINE> self.applet = None <NEW_LINE> self.applet_script = None <NEW_LINE> self._forward_to_applet = True <NEW_LINE> <DEDENT> def __getattr__(self, key): <NEW_LINE> <INDENT> if self._forward... | Subclass Applet in your module and return an instance of it in a global function named
applet(). Implement the following functions to breathe life into your applet:
* paint - Draw the applet given a QPainter and some options
It provides the same API as Plasma.Applet; it just has slightly less irritating event names... | 62598f660383005118f6cddd |
class Sink(object): <NEW_LINE> <INDENT> def __init__(self, size=10): <NEW_LINE> <INDENT> self._msg_ids = [None for i in range(size)] <NEW_LINE> self._store = {} <NEW_LINE> self._subs = set() <NEW_LINE> <DEDENT> def subscribe(self, d): <NEW_LINE> <INDENT> self._subs.add(d) <NEW_LINE> <DEDENT> def unsub(self, d):... | specialized ring-buffer for message storage | 62598f668a349b6b43685913 |
class Feedback(models.Model): <NEW_LINE> <INDENT> scholar = models.ForeignKey(McUser) <NEW_LINE> applicant = models.ForeignKey(Applicant) <NEW_LINE> RATING_CHOICES = ( (5, 'Strong Yes'), (4, 'Yes - little or no reservations'), (3, 'Yes - some reservations'), (2, 'No - significant reservations'), (1, 'Strong No'), (0, '... | Model for feedback from one scholar on an applicant. | 62598f6630c21e258be97ed1 |
class Command(NoArgsCommand): <NEW_LINE> <INDENT> help = 'Charges Credit Cards for due balance' <NEW_LINE> def handle_noargs(self, **options): <NEW_LINE> <INDENT> end_period = datetime.datetime.now() <NEW_LINE> create_charges_for_balance(end_period) | Charges for due balance | 62598f66d53ae8145f917b68 |
class RandomChar(): <NEW_LINE> <INDENT> @staticmethod <NEW_LINE> def unicode(): <NEW_LINE> <INDENT> val = random.randint(0x4e00,0x9fbf) <NEW_LINE> return unichr(val) <NEW_LINE> <DEDENT> @staticmethod <NEW_LINE> def gb2312(): <NEW_LINE> <INDENT> head = random.randint(0xb0,0xcf) <NEW_LINE> body = random.randint(0xa,0xf) ... | 随机生成汉字 | 62598f660a366e3fb87dc095 |
class CFGStringExporter(Exporter, patterns.DynamicVisitor): <NEW_LINE> <INDENT> __BLOCK_SEP = "\n\n================================\n\n" <NEW_LINE> def __init__(self, cfg: cfg.ControlFlowGraph, ordered: bool = True): <NEW_LINE> <INDENT> super().__init__(cfg) <NEW_LINE> self.ordered = ordered <NEW_LINE> self.blocks = []... | Prints a textual representation of the given CFG to stdout.
Args:
cfg: source CFG to be printed.
ordered: if True (default), print BasicBlocks in order of entry. | 62598f6663f4b57ef00858d9 |
class POWER_SEQUENCER_OT_duplicate_move(bpy.types.Operator): <NEW_LINE> <INDENT> doc = { "name": doc_name(__qualname__), "demo": "", "description": doc_description(__doc__), "shortcuts": [ ({"type": "D", "value": "PRESS"}, {}, "Duplicate Move"), ({"type": "D", "value": "PRESS", "shift": True}, {}, "Duplicate Move"), ],... | Auto selects the strip under the mouse if nothing is selected, and calls Blender's
Duplicate Move function | 62598f6621a7993f00c6564c |
class FoundANone(VarLibMergeError): <NEW_LINE> <INDENT> @property <NEW_LINE> def offender(self): <NEW_LINE> <INDENT> cause = self.argv[0] <NEW_LINE> index = [x is None for x in cause["got"]].index(True) <NEW_LINE> return index, self._master_name(index) <NEW_LINE> <DEDENT> @property <NEW_LINE> def details(self): <NEW_LI... | one of the values in a list was empty when it shouldn't have been | 62598f66d18da76e235b6ca0 |
class Row: <NEW_LINE> <INDENT> def __init__(self,guess,result): <NEW_LINE> <INDENT> self.__guess = guess <NEW_LINE> self.__result = result <NEW_LINE> <DEDENT> def setGuess(self,guess): <NEW_LINE> <INDENT> self.__guess = guess <NEW_LINE> <DEDENT> def setResult(self,result): <NEW_LINE> <INDENT> self.__result = result <NE... | Class containing a guess code and answer code | 62598f664d74a7450cd58a42 |
class ContainsEverything: <NEW_LINE> <INDENT> def __contains__(self, item): <NEW_LINE> <INDENT> return True | An object whose instances will claim to contain anything. | 62598f6626238365f5fac24a |
class RestoreDisk(models.Model): <NEW_LINE> <INDENT> mountpoint = models.CharField(blank=True, max_length=1024, help_text="E.g. /badc/restore_1", unique=True) <NEW_LINE> allocated_bytes = FileSizeField(default=0, help_text="Maximum size on the disk that can be allocated to the restore area") <NEW_LINE> used_bytes = Fil... | Allocated area(s) of disk(s) to hold restored files. Restore will find a space on one
of these RestoreDisks to write the files to.
:var models.CharField mountpoint: the path to the restore area
:var FileSizeField allocated_bytes: the allocated size of the restore area (in bytes)
:var FileSizeField used_bytes: the amo... | 62598f66a8ecb033258708d9 |
class DatasetParameterSet(object): <NEW_LINE> <INDENT> def __init__(self, dataset_paramset_json): <NEW_LINE> <INDENT> self.json = dataset_paramset_json <NEW_LINE> self.id = dataset_paramset_json['id'] <NEW_LINE> self.dataset = dataset_paramset_json['dataset'] <NEW_LINE> self.schema = Schema(dataset_paramset_json['schem... | Model class for MyTardis API v1's DatasetParameterSetResource.
See: https://github.com/mytardis/mytardis/blob/3.7/tardis/tardis_portal/api.py | 62598f6630c21e258be97ed3 |
class _CommandFemMeshRegion(FemCommands): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> super(_CommandFemMeshRegion, self).__init__() <NEW_LINE> self.resources = {'Pixmap': 'fem-femmesh-region', 'MenuText': QtCore.QT_TRANSLATE_NOOP("FEM_MeshRegion", "FEM mesh region"), 'Accel': "M, R", 'ToolTip': QtCore.Q... | The FEM_MeshRegion command definition | 62598f661d351010ab8f3218 |
class Needle: <NEW_LINE> <INDENT> index = "" <NEW_LINE> cls = "" <NEW_LINE> inp = "" <NEW_LINE> parameters = None <NEW_LINE> def __init__(self, index, cls, inp, parameters): <NEW_LINE> <INDENT> self.index = index <NEW_LINE> self.cls = cls <NEW_LINE> self.inp = inp <NEW_LINE> self.parameters = dict((p[0], SimulationDefi... | A percutaneous needle.
More generally, one of a set of possible
implements used in a procedure, possibly with repetition) [see CDM] | 62598f661f5feb6acb16230f |
class SoftmaxWithLoss(object): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.loss = None <NEW_LINE> self.y = None <NEW_LINE> self.t = None <NEW_LINE> <DEDENT> def forward(self, x, t): <NEW_LINE> <INDENT> self.t = t <NEW_LINE> self.y = softmax(x) <NEW_LINE> self.loss = cross_entropy_error(self.y, self... | classdocs | 62598f6621a7993f00c6564e |
class TestPopularityItem(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 testPopularityItem(self): <NEW_LINE> <INDENT> pass | PopularityItem unit test stubs | 62598f66bf627c535bcb0b57 |
class TestRecipeSignupAndLogin(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.acc = Account() <NEW_LINE> self.rec = Lists() <NEW_LINE> self.pro = Procedures() <NEW_LINE> <DEDENT> def test_signup_success(self): <NEW_LINE> <INDENT> result = self.acc.adduser("name", "username@domain.com"... | test for successful and unsuccessful signup and login | 62598f668c3a8732951f5c26 |
class ConstantsRemover(BaseEstimator, TransformerMixin): <NEW_LINE> <INDENT> def __init__(self, eps = 10e-10): <NEW_LINE> <INDENT> self.eps = eps <NEW_LINE> <DEDENT> def fit(self, X, y=None): <NEW_LINE> <INDENT> stds = X[0].values.std() <NEW_LINE> cols = X[0].values.columns.values <NEW_LINE> self.const_dims_ = [c for c... | For now it just looks at the first track | 62598f6691af0d3eaad394df |
class NewsLinkModelTests(TestCase): <NEW_LINE> <INDENT> def test_concrete_fields(self): <NEW_LINE> <INDENT> field_names = get_concrete_field_names(NewsLink) <NEW_LINE> expected_field_names = [ "id", "title", "slug", "pub_date", "link", ] <NEW_LINE> self.assertEqual(field_names, expected_field_names) <NEW_LINE> <DEDENT>... | Tests for the NewsLink model | 62598f66d18da76e235b6ca1 |
class MoNN4L(models.BaseModel): <NEW_LINE> <INDENT> def create_model(self, model_input, vocab_size, num_mixtures=None, l2_penalty=1e-6, **unused_params): <NEW_LINE> <INDENT> num_mixtures = num_mixtures or FLAGS.MoNN_num_experts <NEW_LINE> gate_activations = slim.fully_connected( model_input, vocab_size * (num_mixtures ... | A softmax over a mixture of logistic models (with L2 regularization). | 62598f668a349b6b43685917 |
class Shape(ABC): <NEW_LINE> <INDENT> def __init__(self, color:str, filled=True): <NEW_LINE> <INDENT> self._color = color <NEW_LINE> self._filled = filled <NEW_LINE> <DEDENT> @property <NEW_LINE> def color(self): <NEW_LINE> <INDENT> return self._color <NEW_LINE> <DEDENT> @color.setter <NEW_LINE> def color(self, color):... | This is super class for shapes
...
Attributes:
color: str
filled: bool
Methods:
color`s setter and getter
is_filled`s setter and getter | 62598f66a8ecb033258708db |
class StateTester(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.list_val = [1, 2, 'a', 1.2] <NEW_LINE> self.dict_val = {'a': 1, 1: 2.3} <NEW_LINE> self.int_val = 123 <NEW_LINE> <DEDENT> def tearDown(self): <NEW_LINE> <INDENT> state.reset_instance() <NEW_LINE> <DEDENT> def _setup_basi... | ABC for state's test fixtures
| 62598f66711fe17d825dfdc2 |
class PadController(object): <NEW_LINE> <INDENT> def __init__(self, robo): <NEW_LINE> <INDENT> self.robo = robo <NEW_LINE> self.initialize_pad() <NEW_LINE> self.curdir = 0 <NEW_LINE> <DEDENT> def initialize_pad(self): <NEW_LINE> <INDENT> pygame.init() <NEW_LINE> pygame.joystick.init() <NEW_LINE> pad_count = pygame.joys... | module to controll nxt-robot using gamepad running in pygame loop | 62598f66796e427e5384de6c |
class BaseTests(unittest.TestCase): <NEW_LINE> <INDENT> def test_visualizer_returns_self(self): <NEW_LINE> <INDENT> visualizer = Visualizer() <NEW_LINE> self.assertIs(visualizer.fit([]), visualizer) <NEW_LINE> <DEDENT> def test_base_poof(self): <NEW_LINE> <INDENT> with self.assertRaises(NotImplementedError): <NEW_LINE>... | Test the high level API for yellowbrick | 62598f66ff9c53063f519d2b |
class Family(family.Family): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> family.Family.__init__(self) <NEW_LINE> self.name = 'omegawiki' <NEW_LINE> self.langs['omegawiki'] = 'www.omegawiki.org' <NEW_LINE> self.namespaces[4] = { '_default': [u'Meta'], } <NEW_LINE> self.namespaces[5] = { '_default': [u'Me... | Family class for Omega Wiki. | 62598f665166f23b2e242ab2 |
class wire(): <NEW_LINE> <INDENT> def __init__(self, ends, pointlist): <NEW_LINE> <INDENT> self.ends = ends <NEW_LINE> self.pointlist = pointlist <NEW_LINE> self.connections = [] <NEW_LINE> self.shifts = [] <NEW_LINE> <DEDENT> def calculateAngle(self, end, centre): <NEW_LINE> <INDENT> return np.array(centre) - np.array... | The class of wires.
A shape classified as a wire. Wire objects will be then used in connection.
Attributes:
ends (list): A list of two end points' positions.
pointlist (list): The list of polygon vertex points.
connection (list): The connection information of the wire.
Args:
ends (list): A list of tw... | 62598f6663f4b57ef00858db |
class Error(RuntimeError): <NEW_LINE> <INDENT> def __init__(self, message, result): <NEW_LINE> <INDENT> super().__init__() <NEW_LINE> self.message = message <NEW_LINE> self.result = result | PythonAEM error, contains a message and PythonAEM Result object
useful for debugging the result and response when an error occurs | 62598f6621a7993f00c65650 |
class GoodsCategory(models.Model): <NEW_LINE> <INDENT> CATEGORY_TYPE = ( (1, "first class"), (2, "second class"), (3, "third class"), ) <NEW_LINE> name = models.CharField(default="", max_length=30, help_text="category_name") <NEW_LINE> code = models.CharField(default="", max_length=30, help_text="category_code") <NEW_L... | multi-category of goods | 62598f6676d4e153a661c2ed |
class DispatchingJinjaLoader(BaseLoader): <NEW_LINE> <INDENT> def __init__(self, app): <NEW_LINE> <INDENT> self.app = app <NEW_LINE> <DEDENT> def get_source(self, environment, template): <NEW_LINE> <INDENT> if self.app.config['EXPLAIN_TEMPLATE_LOADING']: <NEW_LINE> <INDENT> return self._get_source_explained(environment... | A loader that looks for views in the application and all
the blueprint folders. | 62598f66bf627c535bcb0b59 |
class BuildFiler(object): <NEW_LINE> <INDENT> def download_to_stream(self, filename): <NEW_LINE> <INDENT> raise NotImplementedError <NEW_LINE> <DEDENT> def upload_from_stream(self, filename, data, properties = {}): <NEW_LINE> <INDENT> raise NotImplementedError <NEW_LINE> <DEDENT> def download_to_file(self, remote_filen... | Abstraction for interacting with storage (S3, local, etc.)
Base class for the BuildFiler. You probably don't want to use
this implementation, as it's pretty much an abstract base class.
Use the S3BuildFiler. | 62598f6615baa7234946165f |
class Singleton(type): <NEW_LINE> <INDENT> _instances = {} <NEW_LINE> def __call__(cls, *args, **kwargs): <NEW_LINE> <INDENT> if cls not in cls._instances: <NEW_LINE> <INDENT> cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs) <NEW_LINE> <DEDENT> return cls._instances[cls] | Base metaclass for Singleton pattern
@see http://stackoverflow.com/a/6798042/1977778 | 62598f666e29344779affd33 |
class Graph(MDIWindow): <NEW_LINE> <INDENT> def __init__(self, toproxy): <NEW_LINE> <INDENT> MDIWindow.__init__(self,toproxy) <NEW_LINE> <DEDENT> def activeLayer(self): <NEW_LINE> <INDENT> return new_proxy(Layer, self._getHeldObject().activeLayer) <NEW_LINE> <DEDENT> def setActiveLayer(self, layer): <NEW_LINE> <INDENT>... | Proxy for the _qti.Graph object.
| 62598f660a366e3fb87dc09c |
class Glog(CMakePackage): <NEW_LINE> <INDENT> homepage = "https://github.com/google/glog" <NEW_LINE> url = "https://github.com/google/glog/archive/v0.3.4.tar.gz" <NEW_LINE> version('0.3.4', 'df92e05c9d02504fb96674bc776a41cb') <NEW_LINE> version('0.3.3', 'c1f86af27bd9c73186730aa957607ed0') <NEW_LINE> depends_on('gf... | C++ implementation of the Google logging module. | 62598f66925a0f43d25e7712 |
class VideoPanel(wx.Panel): <NEW_LINE> <INDENT> def __init__(self, parent): <NEW_LINE> <INDENT> wx.Panel.__init__(self, parent) <NEW_LINE> self.video_format_combo = wx.ComboBox(self, choices=VIDEO_FORMATS, size=(200, 30)) <NEW_LINE> self.second_video_format_combo = wx.ComboBox(self, choices=SECOND_VIDEO_FORMATS, size=(... | Options frame video tab panel.
Params
parent: wx.Panel parent. | 62598f6666673b3332c2fa96 |
class ReduceLROnPlateau(Callback): <NEW_LINE> <INDENT> def __init__(self, monitor='val_loss', factor=0.1, patience=10, epsilon=0, cooldown=0, min_lr=0, verbose=0): <NEW_LINE> <INDENT> self.monitor = monitor <NEW_LINE> if factor >= 1.0: <NEW_LINE> <INDENT> raise ValueError('ReduceLROnPlateau does not support a factor >=... | Reduce the learning rate if the train or validation loss plateaus | 62598f66d164cc6175820654 |
class DynamicPatcher(MetaPathFinder, Loader): <NEW_LINE> <INDENT> def __init__(self, patcher: Patcher) -> None: <NEW_LINE> <INDENT> self._patcher = patcher <NEW_LINE> self.sysmodules = {} <NEW_LINE> self.modules = self._patcher.fake_modules <NEW_LINE> self._loaded_module_names: Set[str] = set() <NEW_LINE> for name in s... | A file loader that replaces file system related modules by their
fake implementation if they are loaded after calling `setUpPyfakefs()`.
Implements the protocol needed for import hooks. | 62598f6621bff66bcd722337 |
class DefaultErrorResponseError(msrest.serialization.Model): <NEW_LINE> <INDENT> _validation = { 'code': {'readonly': True}, 'message': {'readonly': True}, 'target': {'readonly': True}, 'innererror': {'readonly': True}, } <NEW_LINE> _attribute_map = { 'code': {'key': 'code', 'type': 'str'}, 'message': {'key': 'message'... | Error model.
Variables are only populated by the server, and will be ignored when sending a request.
:ivar code: Standardized string to programmatically identify the error.
:vartype code: str
:ivar message: Detailed error description and debugging information.
:vartype message: str
:ivar target: Detailed error descri... | 62598f661d351010ab8f321e |
class AvailableSkusOperations(object): <NEW_LINE> <INDENT> models = _models <NEW_LINE> def __init__(self, client, config, serializer, deserializer): <NEW_LINE> <INDENT> self._client = client <NEW_LINE> self._serialize = serializer <NEW_LINE> self._deserialize = deserializer <NEW_LINE> self._config = config <NEW_LINE> <... | AvailableSkusOperations operations.
You should not instantiate this class directly. Instead, you should create a Client instance that
instantiates it for you and attaches it as an attribute.
:ivar models: Alias to model classes used in this operation group.
:type models: ~azure.mgmt.databoxedge.v2020_12_01.models
:pa... | 62598f661f5feb6acb162315 |
class Writer(object): <NEW_LINE> <INDENT> def __init__(self, session, url): <NEW_LINE> <INDENT> self.session = session <NEW_LINE> self.url = url <NEW_LINE> self.r = None <NEW_LINE> <DEDENT> def write(self, data): <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> self.r = self.session.post(self.url, data=data, stream=True) <... | Alluxio file writer.
A string or a file-like object can be written as a stream to an Alluxio file.
:meth:`alluxio.Writer.close` must be called after the writing is done.
This class is used by :meth:`.Client.open`, it is not intended to be created
by users directly.
All operations on the reader will raise :class:`all... | 62598f66925a0f43d25e7714 |
class FlagsFile(FlagsSource): <NEW_LINE> <INDENT> _FILE_NAME = ".clang_complete" <NEW_LINE> def __init__(self, include_prefixes): <NEW_LINE> <INDENT> super().__init__(include_prefixes) <NEW_LINE> self._cache = FlagsFileCache() <NEW_LINE> <DEDENT> def get_flags(self, file_path=None, search_scope=None): <NEW_LINE> <INDEN... | Manages flags parsing from .clang_complete file.
Attributes:
cache (dict): Cache of all parsed files to date. Stored by full file
path. Needed to avoid reparsing the file multiple times.
path_for_file (dict): A path to a database for every source file path. | 62598f6676d4e153a661c2f1 |
class EditHasRemoteForm(forms.Form): <NEW_LINE> <INDENT> mysql_instance_id = forms.IntegerField(required = True, min_value = 0, error_messages = {'required': '找不到MySQL实例', 'invalid': '不合法MySQL实例'}) <NEW_LINE> mysql_backup_instance_id = forms.IntegerField(required = True, min_value = 0, error_messages = {'required': '找不... | 编辑包含远程备份表单 | 62598f661d351010ab8f321f |
class aiohttpClient(AsyncClient): <NEW_LINE> <INDENT> def __init__(self, session, endpoint): <NEW_LINE> <INDENT> super(aiohttpClient, self).__init__(endpoint) <NEW_LINE> self.session = session <NEW_LINE> <DEDENT> async def _send_message(self, request): <NEW_LINE> <INDENT> with async_timeout.timeout(10): <NEW_LINE> <IND... | TODO: rename aiohttpClient to AiohttpClient (breaking change) | 62598f6638b623060ffa8777 |
class ModelInterface(object): <NEW_LINE> <INDENT> def get_probability_correct(self, num_pretest, trajectory, parameters): <NEW_LINE> <INDENT> raise NotImplementedError('Data module must implement this') | This is the interface for the student model that models
the student mastery of the material. It is a stateless module,
so it stores no information about the student or the course.
It gets the trajectory of correctness (0 or 1),
and a set of parameters as a dictionary, and computes
the probabilty of getting the next que... | 62598f6630c21e258be97eda |
class CollectDefaultVotesMixin(models.Model): <NEW_LINE> <INDENT> votesvalid = MinMaxIntegerField(null=True, blank=True, min_value=-2, verbose_name=ugettext_lazy('Valid votes')) <NEW_LINE> votesinvalid = MinMaxIntegerField(null=True, blank=True, min_value=-2, verbose_name=ugettext_lazy('Invalid votes')) <NEW_LINE> vote... | Mixin for a poll to collect the default vote values for valid votes,
invalid votes and votes cast. | 62598f668a349b6b4368591d |
class User: <NEW_LINE> <INDENT> def __init__(self, *args: List[Any], **kwargs: Dict[Any, Any]) -> None: <NEW_LINE> <INDENT> for key, value in kwargs.items(): <NEW_LINE> <INDENT> setattr(self, key, value) <NEW_LINE> <DEDENT> <DEDENT> def __getattr__(self, item) -> Any: <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> return... | User model
| 62598f667c178a314d78cb7d |
class RubberbandBase(ToolBase): <NEW_LINE> <INDENT> def trigger(self, sender, event, data): <NEW_LINE> <INDENT> if not self.figure.canvas.widgetlock.available(sender): <NEW_LINE> <INDENT> return <NEW_LINE> <DEDENT> if data is not None: <NEW_LINE> <INDENT> self.draw_rubberband(*data) <NEW_LINE> <DEDENT> else: <NEW_LINE>... | Draw and remove rubberband | 62598f66d164cc6175820657 |
class Request(SimpleStringifiable): <NEW_LINE> <INDENT> def __init__(self, instance, instance_type, zone, ami, count, bid=0, ondemand=False, odp=0, price=0, DrAFTS=0, AvgPrice=0, OraclePrice=0): <NEW_LINE> <INDENT> self.instance = instance <NEW_LINE> self.instance_type = instance_type <NEW_LINE> self.zone = zone <NEW_L... | Store the details of what is being requested. | 62598f66d53ae8145f917b72 |
class EducationSerializer(serializers.HyperlinkedModelSerializer): <NEW_LINE> <INDENT> class Meta: <NEW_LINE> <INDENT> model = Education <NEW_LINE> fields = ('id', 'url', 'title', 'institute', 'description', 'year') <NEW_LINE> extra_kwargs = { 'url': {'view_name': 'resume:education-detail'} } | Serializer for the `Education` model. | 62598f666e29344779affd37 |
class PrivateUserApiTests(TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.user = create_user( email='test@mytest.com', password='testpass', name='Test name' ) <NEW_LINE> self.client = APIClient() <NEW_LINE> self.client.force_authenticate(user=self.user) <NEW_LINE> <DEDENT> def test_retrieve_pro... | Test API requests that require authentication | 62598f6621a7993f00c65656 |
class Stemmer: <NEW_LINE> <INDENT> max_cache_size = 10000 <NEW_LINE> def __init__ (self, algorithm, cache_size=None): <NEW_LINE> <INDENT> if algorithm not in ['english', 'eng', 'en']: <NEW_LINE> <INDENT> raise KeyError("Stemming algorithm '%s' not found" % algorithm) <NEW_LINE> <DEDENT> if cache_size: <NEW_LINE> <INDEN... | An instance of a stemming algorithm.
When creating a Stemmer object, there is one required argument:
the name of the algorithm to use in the new stemmer. A list of the
valid algorithm names may be obtained by calling the algorithms()
function in this module. In addition, the appropriate stemming algorithm
for a given ... | 62598f66bf627c535bcb0b5f |
class cached_class_property(default_class_property, _func_deco_with_attr): <NEW_LINE> <INDENT> def __get__(self, obj, objtype=None): <NEW_LINE> <INDENT> if objtype is None: <NEW_LINE> <INDENT> objtype = type(obj) <NEW_LINE> <DEDENT> ret = super(cached_class_property, self).__get__(obj, objtype) <NEW_LINE> setattr(objty... | Non-data descriptor.
Delegates to func only the first time a property is accessed.
Usage example:
>>> class C(object):
... @cached_class_property
... def cached(cls):
... print("Accessing {cls.__name__}.cached"
... .format(**locals()))
... return 17
...
>>> x = C()
>>> x.cached
... | 62598f664d74a7450cd58a47 |
class TestGeoFeedAPI(unittest2.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.service = apiclient.discovery.build("geofeed", "v1.0", discoveryServiceUrl=("http://localhost:8080/_ah/api/discovery/v1/" "apis/{api}/{apiVersion}/rest")) <NEW_LINE> self.geofeed = self.service <NEW_LINE> <DEDENT> de... | GeoFeed API test cases. | 62598f66507cdc57c63a447a |
class AFrameBody(Frame): <NEW_LINE> <INDENT> def __init__(self, frmclass, dc_fldvals={}): <NEW_LINE> <INDENT> self.frmtype = 'FrameBody' <NEW_LINE> self.bitbyte = frmclass.bitbyte <NEW_LINE> self.frame_len = frmclass.frame_len <NEW_LINE> self.mask_len = frmclass.mask_len <NEW_LINE> self.ls_fields = copy.copy(frmclass.l... | A class to build a frame body field.
@ivar frmtype: a conventional name for the type of frame.
@ivar bitbyte: 'bits' or 'bytes', indicates how this frame will be parsed.
@ivar frame_len: the actual length of this frame.
@ivar masklen: length of bitmask.
@ivar dc_fields: a dictionary of {field: FieldTemplate} for field... | 62598f66d10714528d69d5ab |
class POParser: <NEW_LINE> <INDENT> def __init__(self, file): <NEW_LINE> <INDENT> self._file = file <NEW_LINE> self._in_paren = re.compile(r'"(.*)"') <NEW_LINE> self.msgdict = OrderedDict() <NEW_LINE> self.line = '' <NEW_LINE> self.sameMessageEntry = True <NEW_LINE> self.msgid = '' <NEW_LINE> self.msgstr = '' <NEW_LINE... | Parses an existing po- file and builds a dictionary according to
MessageCatalog. POParser is the deserializer, POWriter the serializer. | 62598f66ac7a0e7691f71bf1 |
class Role: <NEW_LINE> <INDENT> id: int <NEW_LINE> name: str <NEW_LINE> color: int <NEW_LINE> position: int <NEW_LINE> hoist: int <NEW_LINE> mentionable: int <NEW_LINE> permissions: int <NEW_LINE> def __init__(self, **kwargs): <NEW_LINE> <INDENT> self.id: int = kwargs.get("role_id", 0) <NEW_LINE> self.name: str = kwarg... | `Standard Object`
represent the component that used in permission control and user identify | 62598f6656b00c62f0fb1f94 |
class ChangeDirective(EnvDirective, Directive): <NEW_LINE> <INDENT> has_content = True <NEW_LINE> def run(self): <NEW_LINE> <INDENT> if "ChangeLogDirective" not in self.env.temp_data: <NEW_LINE> <INDENT> return [] <NEW_LINE> <DEDENT> content = _parse_content(self.content) <NEW_LINE> sorted_tags = _comma_list(content.ge... | Implement the ``.. change::`` directive.
| 62598f660a366e3fb87dc0a1 |
class ListServiceIdsEnums: <NEW_LINE> <INDENT> class Order(str, Enum): <NEW_LINE> <INDENT> ASC = 'asc' <NEW_LINE> DESC = 'desc' | Enums for list_service_ids parameters. | 62598f66925a0f43d25e7718 |
class ListaDidaticosDetailForm(ModelForm): <NEW_LINE> <INDENT> _model_class = ListaDidaticos <NEW_LINE> _include = [ListaDidaticos.creation, ListaDidaticos.autor, ListaDidaticos.preco, ListaDidaticos.titulo, ListaDidaticos.edicao, ListaDidaticos.descricao, ListaDidaticos.editora] | Form used to show entity details on app's admin page | 62598f669b70327d1c57e488 |
@dataclass <NEW_LINE> class Program(ProgramType): <NEW_LINE> <INDENT> class Meta: <NEW_LINE> <INDENT> name = "program" <NEW_LINE> namespace = "urn:vpro:media:2009" | This is the most used entity in POMS.
It represents e.g. one broadcast program or one web-only clip. It represent a standalone entity which a
consumer can view or listen to. | 62598f6630c21e258be97ede |
class NewsConfig(AppConfig): <NEW_LINE> <INDENT> name = 'apps.news' <NEW_LINE> verbose_name = _('News') | Configuration for ``News`` app. | 62598f66ac7a0e7691f71bf3 |
class TestSOCKSWithTLS(IPV4SocketDummyServerTestCase): <NEW_LINE> <INDENT> def test_basic_request(self): <NEW_LINE> <INDENT> if not HAS_SSL: <NEW_LINE> <INDENT> raise SkipTest("No TLS available") <NEW_LINE> <DEDENT> def request_handler(listener): <NEW_LINE> <INDENT> sock = listener.accept()[0] <NEW_LINE> handler = hand... | Test that TLS behaves properly for SOCKS proxies. | 62598f666aa9bd52df0d45b0 |
class Tool(NotRunnable, PipelineElement): <NEW_LINE> <INDENT> def __init__(self, name=None): <NEW_LINE> <INDENT> super(Tool, self).__init__() <NEW_LINE> self.name = name <NEW_LINE> <DEDENT> @property <NEW_LINE> def arguments(self): <NEW_LINE> <INDENT> raise NotImplementedError("Tools must implement this") <NEW_LINE> <D... | This represents a Tool of the pipeline.
A Tool modifies the JVM on which it runs, so that data about that run is
gathered. Hprof, for example, is a Tool. | 62598f663eb6a72ae0389d23 |
class CourseDetailView(View): <NEW_LINE> <INDENT> def get(self, request, course_id): <NEW_LINE> <INDENT> course = Course.objects.get(id=int(course_id)) <NEW_LINE> course.click_nums += 1 <NEW_LINE> course.save() <NEW_LINE> has_fav_course = False <NEW_LINE> has_fav_org = False <NEW_LINE> if request.user.is_authenticated:... | 课程详情 | 62598f66711fe17d825dfdcc |
class Scheduler(BaseScheduler): <NEW_LINE> <INDENT> @staticmethod <NEW_LINE> def get_store(app): <NEW_LINE> <INDENT> store_classes = getattr(app.conf, 'beatx_store_classes', { 'dummy': 'beatx.store.dummy.Store', 'redis': 'beatx.store.redis.Store', 'memcached': 'beatx.store.memcached.MemcachedStore', 'pylibmc': 'beatx.s... | Celery scheduler which use store class to load/save schedule.
Only single instance of running beat instances will be active.
Another instances will run in "sleep-mode" and will waiting
when master instance will dead[or not :-)]. | 62598f661d351010ab8f3224 |
class SimulatedASRModule(abstract.AbstractModule): <NEW_LINE> <INDENT> @staticmethod <NEW_LINE> def name(): <NEW_LINE> <INDENT> return "Simulated ASR Module" <NEW_LINE> <DEDENT> @staticmethod <NEW_LINE> def description(): <NEW_LINE> <INDENT> return "An Module that mimics a real incremental ASR module." <NEW_LINE> <DEDE... | A simulated ASR module that tries to mimic a real ASR module by reading
meta data.
This module tries to output the text of the incoming audio only in part.
For this it uses the "completion" meta-data to approximate the current
position in the utterance. | 62598f66925a0f43d25e771a |
class BiosVfProcessorEnergyConfiguration(ManagedObject): <NEW_LINE> <INDENT> consts = BiosVfProcessorEnergyConfigurationConsts() <NEW_LINE> naming_props = set([]) <NEW_LINE> mo_meta = MoMeta("BiosVfProcessorEnergyConfiguration", "biosVfProcessorEnergyConfiguration", "Processor-Energy-Configuration", VersionMeta.Version... | This is BiosVfProcessorEnergyConfiguration class. | 62598f66d99f1b3c44d04d96 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.