code stringlengths 4 4.48k | docstring stringlengths 1 6.45k | _id stringlengths 24 24 |
|---|---|---|
@pulumi.output_type <NEW_LINE> class GetVpcLinkResult: <NEW_LINE> <INDENT> def __init__(__self__, description=None, id=None, name=None, status=None, status_message=None, tags=None, target_arns=None): <NEW_LINE> <INDENT> if description and not isinstance(description, str): <NEW_LINE> <INDENT> raise TypeError("Expected a... | A collection of values returned by getVpcLink. | 62598ee099cbb53fe682f481 |
class MatchExtraStats(Item): <NEW_LINE> <INDENT> match_id = Field() <NEW_LINE> team_id = Field() <NEW_LINE> pens_attempt = Field() <NEW_LINE> pens_conceded = Field() <NEW_LINE> drops_attempt = Field() <NEW_LINE> kicks = Field() <NEW_LINE> passes = Field() <NEW_LINE> runs = Field() <NEW_LINE> meters = Field() <NEW_LINE>... | Data structure to store extended match stats | 62598ee0462c4b4f79db9fc9 |
class RunExportMacros(RunMacrosAbstract): <NEW_LINE> <INDENT> def run(self, year, output_file=None): <NEW_LINE> <INDENT> output_file = redirect_sftp_url_to_local_tempdir(output_file) <NEW_LINE> RunMacrosAbstract.run(self, 'export_macros', year, output_file) | Class to run specified Emme2 macros. run_export_macros should run before
opus_emme2.models.get_emme2_data_into_cache. Then in the configuration, if there is some
desired matrix generated by a macro, the matrix_variable_map config entry will store it.
The macro specification should also have a specification of the bank... | 62598ee04428ac0f6e656b21 |
class NumberConverter(BaseConverter): <NEW_LINE> <INDENT> weight = 50 <NEW_LINE> def __init__(self, router, fixed_digits=0, min=None, max=None): <NEW_LINE> <INDENT> BaseConverter.__init__(self, router) <NEW_LINE> self.fixed_digits = fixed_digits <NEW_LINE> self.min = min <NEW_LINE> self.max = max <NEW_LINE> <DEDENT> de... | Baseclass for `IntegerConverter` and `FloatConverter`.
:internal: | 62598ee063d6d428bbee0da1 |
class JuMEG_Template_Experiments(JuMEG_Template): <NEW_LINE> <INDENT> def __init__ (self,**kwargs): <NEW_LINE> <INDENT> super().__init__() <NEW_LINE> self.template_path = os.getenv('JUMEG_PATH_TEMPLATE_EXPERIMENTS',self.template_path_default + '/jumeg_experiments') <NEW_LINE> self.template_name = 'default' <NEW_L... | class to work with <jumeg experiment templates>
overwrite _init(**kwargs) for you settings
Example
-------
from jumeg.template.jumeg_template import JuMEG_Template_Experiments
class JuMEG_ExpTemplate(JuMEG_Template_Experiments):
def __init__(self,**kwargs):
super().__init__()
def update_from_kwargs... | 62598ee021a7993f00c6453b |
class Normalize(object): <NEW_LINE> <INDENT> def __init__(self, mean, std): <NEW_LINE> <INDENT> self.mean = mean <NEW_LINE> self.std = std <NEW_LINE> <DEDENT> def __call__(self, sample): <NEW_LINE> <INDENT> tensor = sample['image'] <NEW_LINE> return {'image': F.normalize(tensor, self.mean, self.std), 'label': sample['l... | normalize the color range to [0,1].
https://pytorch.org/docs/stable/torchvision/models.html
The images have to be loaded in to a range of [0, 1] and then normalized using mean = [0.485, 0.456, 0.406] and std = [0.229, 0.224, 0.225]. | 62598ee0a05bb46b38488e4d |
class JaffePotential(TwoPowerIntegerSphericalPotential): <NEW_LINE> <INDENT> def __init__(self,amp=1.,a=1.,normalize=False): <NEW_LINE> <INDENT> Potential.__init__(self,amp=amp) <NEW_LINE> self.a= a <NEW_LINE> self.alpha= 2 <NEW_LINE> self.beta= 4 <NEW_LINE> if normalize: <NEW_LINE> <INDENT> self.normalize(normalize) <... | Class that implements the Jaffe potential | 62598ee01f037a2d8b9e26d5 |
class Tox(TestCommand): <NEW_LINE> <INDENT> description = 'run tests' <NEW_LINE> user_options = [] <NEW_LINE> def finalize_options(self): <NEW_LINE> <INDENT> TestCommand.finalize_options(self) <NEW_LINE> self.test_args = [] <NEW_LINE> self.test_suite = True <NEW_LINE> <DEDENT> def run_tests(self): <NEW_LINE> <INDENT> i... | Run all tests. | 62598ee06aa9bd52df0d347d |
class method(osv.osv): <NEW_LINE> <INDENT> _name = 'method' <NEW_LINE> _columns = { 'name': fields.char('Nombre', size=256, required=True, help="Nombre del Metodo"), 'especification': fields.char('Especificacion', size=256, required=True, help="Especificacion"), 'references': fields.char('Referencias', size=256, requir... | Metodo | 62598ee0a219f33f346c4e08 |
class BuildExt(build_ext): <NEW_LINE> <INDENT> c_opts = { 'msvc': ['/EHsc'], 'unix': [], } <NEW_LINE> l_opts = { 'msvc': [], 'unix': [], } <NEW_LINE> if sys.platform == 'darwin': <NEW_LINE> <INDENT> raise NotImplementedError('MacOS/Darwin not supported!') <NEW_LINE> <DEDENT> def build_extensions(self): <NEW_LINE> <INDE... | A custom build extension for adding compiler-specific options. | 62598ee05f7d997b871f86bd |
class GlslBlockGroup(GlslBlock): <NEW_LINE> <INDENT> def __init__(self, block): <NEW_LINE> <INDENT> GlslBlock.__init__(self) <NEW_LINE> if block.getParent(): <NEW_LINE> <INDENT> block.removeFromParent() <NEW_LINE> <DEDENT> self.addChildren(block) <NEW_LINE> <DEDENT> def format(self, force): <NEW_LINE> <INDENT> return "... | Group of other blocks. Not parsed, but combined. | 62598ee023849d37ff84f68a |
class parse_opmap_t(object): <NEW_LINE> <INDENT> opmap_pattern = re.compile(r'(?P<grp>[A-Za-z0-9_]+)[(](?P<indx>[A-Za-z0-9_]+)[)]') <NEW_LINE> def __init__(self, field_to_bits): <NEW_LINE> <INDENT> self.groups = {} <NEW_LINE> self.field_to_bits = field_to_bits <NEW_LINE> <DEDENT> def read_line(self,line): <NEW_LINE> <I... | Read a list of lines and generate a a dictionary containing
opmap_t's indexed by group name. To operate, this object needs a
dictionary mapping field names to widths | 62598ee0eab8aa0e5d30a347 |
class MyBaseException(Exception): <NEW_LINE> <INDENT> errno=0 <NEW_LINE> httperror = 500 <NEW_LINE> msg="Generic Model Exception" <NEW_LINE> def __init__(self, **kwargs): <NEW_LINE> <INDENT> self.msgargs=kwargs <NEW_LINE> <DEDENT> def __str__(self): <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> return self.msg.format(**... | Base class for Exceptions
Create subclasses with parameters in their msg e.g. {message} or {name}
and call as in: raise NewException(name="Foo");
msgargs Arguments that slot into msg
__str__ Returns msg expanded with msgparms | 62598ee0596a89723612622f |
class Linear(ParameterLayer): <NEW_LINE> <INDENT> def __init__(self, nout, init, name="LinearLayer"): <NEW_LINE> <INDENT> super(Linear, self).__init__(init, name) <NEW_LINE> self.nout = nout <NEW_LINE> self.inputs = None <NEW_LINE> <DEDENT> def __str__(self): <NEW_LINE> <INDENT> return "Linear Layer '%s': %d inputs, %d... | A fully connected layer implemented as the dot product of inputs and
weights.
Arguments:
nout (int, tuple): Desired size or shape of layer output
init (Initializer, optional): Initializer object to use for
initializing layer weights
name (str, optional): Layer name. Defaults to "LinearLayer" | 62598ee04428ac0f6e656b22 |
class TeamStatsStats(object): <NEW_LINE> <INDENT> openapi_types = { 'type': 'TeamStatsType', 'splits': 'list[object]' } <NEW_LINE> attribute_map = { 'type': 'type', 'splits': 'splits' } <NEW_LINE> def __init__(self, type=None, splits=None): <NEW_LINE> <INDENT> self._type = None <NEW_LINE> self._splits = None <NEW_LINE>... | NOTE: This class is auto generated by OpenAPI Generator.
Ref: https://openapi-generator.tech
Do not edit the class manually. | 62598ee0b7558d5895461c1c |
class CheckoutQueryset(models.QuerySet): <NEW_LINE> <INDENT> def for_display(self): <NEW_LINE> <INDENT> return self.prefetch_related( "lines__variant__product__images" ) | A specialized queryset for dealing with checkouts. | 62598ee02c8b7c6e89bd1d8f |
class CharacterSet(_Constants): <NEW_LINE> <INDENT> desc = MYSQL_CHARACTER_SETS <NEW_LINE> slash_charsets = (1, 13, 28, 84, 87, 88) <NEW_LINE> @classmethod <NEW_LINE> def get_info(cls, setid): <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> return cls.desc[setid][0:2] <NEW_LINE> <DEDENT> except IndexError: <NEW_LINE> <IND... | MySQL supported character sets and collations
List of character sets with their collations supported by MySQL. This
maps to the character set we get from the server within the handshake
packet.
The list is hardcode so we avoid a database query when getting the
name of the used character set or collation. | 62598ee0498bea3a75a56107 |
class ErrorList(list): <NEW_LINE> <INDENT> def add(self, opts, errorMessage): <NEW_LINE> <INDENT> self.append(checks.Error(errorMessage, hint=None, obj=field)) | A dummy list class that emulates API used by the older
validateField() method. When validateField() is fully
deprecated, this dummy can be removed too. | 62598ee07d847024c075a99f |
class EmployeeRepository: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self._employees = [] <NEW_LINE> <DEDENT> def __iadd__(self, employee): <NEW_LINE> <INDENT> self._employees.append(employee) <NEW_LINE> return self <NEW_LINE> <DEDENT> def __isub__(self, employee): <NEW_LINE> <INDENT> self._employees.r... | EmployeeRepository provides a collection-like interface for accessing domain objects. | 62598ee032920d7e50bc45fe |
class TestNoteTypeItem(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 testNoteTypeItem(self): <NEW_LINE> <INDENT> pass | NoteTypeItem unit test stubs | 62598ee0baa26c4b54d4d8a1 |
class GLstartGame_args: <NEW_LINE> <INDENT> thrift_spec = ( None, (1, TType.I32, 'gameID', None, None, ), ) <NEW_LINE> def __init__(self, gameID=None,): <NEW_LINE> <INDENT> self.gameID = gameID <NEW_LINE> <DEDENT> def read(self, iprot): <NEW_LINE> <INDENT> if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerate... | Attributes:
- gameID | 62598ee091f36d47f223018c |
class Xmldomdict(Xmldom): <NEW_LINE> <INDENT> def parse(self, string, onlycontent=False): <NEW_LINE> <INDENT> elem = super(Xmldomdict, self).parse(string, onlycontent) <NEW_LINE> return self.xmlToDict(elem) <NEW_LINE> <DEDENT> def xmlToDict(self, node): <NEW_LINE> <INDENT> results = {} <NEW_LINE> attr_map = node.attrib... | response xml format parser
converst dom to a simple dict | 62598ee0d7e4931a7ef3a66c |
class PersonListView(ListCreateAPIView): <NEW_LINE> <INDENT> queryset = Person.objects.all() <NEW_LINE> serializer_class = PersonSerializer | List of People in JSON format. | 62598ee03617ad0b5ee046ff |
class TestFTPModule(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.ftp = FTP('localhost') <NEW_LINE> <DEDENT> def test_anonymous_ftp(self): <NEW_LINE> <INDENT> self.assertRaises(error_perm, self.ftp.login) <NEW_LINE> log = get_last_log() <NEW_LINE> self.assertEqual(log['dst_port'], 21... | Tests the cases for the FTP module.
The FTP server should not allow logins and should log each attempt. | 62598ee08a43f66fc4bf0743 |
class ArithmeticStrengthenRelation: <NEW_LINE> <INDENT> def filter(self, node): <NEW_LINE> <INDENT> return is_arithmetic_relation(node) and node.get_ident() in [ '<', '>', '<=', '>=', 'distinct' ] <NEW_LINE> <DEDENT> def mutations(self, node): <NEW_LINE> <INDENT> strengthen = { '<': ['='], '>': ['='], '<=': ['<', '='],... | Replace a relation by a stronger relation.
For example, ``>=`` is replaced by ``>``. | 62598ee07d43ff24874266e4 |
class GceDisk(disk.BaseDisk): <NEW_LINE> <INDENT> def __init__(self, disk_spec, name, zone, project, image=None, image_project=None): <NEW_LINE> <INDENT> super(GceDisk, self).__init__(disk_spec) <NEW_LINE> self.attached_vm_name = None <NEW_LINE> self.image = image <NEW_LINE> self.image_project = image_project <NEW_LINE... | Object representing an GCE Disk. | 62598ee010dbd63aa1c6f142 |
class Encoder(nn.Layer): <NEW_LINE> <INDENT> def __init__(self, block_expansion, in_features, num_blocks=3, max_features=256): <NEW_LINE> <INDENT> super(Encoder, self).__init__() <NEW_LINE> down_blocks = [] <NEW_LINE> for i in range(num_blocks): <NEW_LINE> <INDENT> down_blocks.append( DownBlock2d(in_features if i == 0 ... | Hourglass Encoder | 62598ee04e4d5625663709ea |
class Gene(models.Model): <NEW_LINE> <INDENT> organism = models.ForeignKey(Organism, on_delete=models.CASCADE) <NEW_LINE> title = models.CharField(max_length=50) <NEW_LINE> name = models.CharField(max_length=255) <NEW_LINE> existence = models.CharField(db_column='Protein Existence', max_length=255) <NEW_LINE> lrrce_seq... | Model to define the genes table
Primary key - ID field autocreated
Foreign key - organism (links to organism table)
Title - Short title of gene (i.e. KERA_HUMAN)
Name - List of names (as seen on site)
Existence - State of protein existence (i.e. Evidence at transcript level)
LRRCE seq - ONLY sequence of LRRCE motif
Un... | 62598ee0442bda511e95aa38 |
class BaseKey: <NEW_LINE> <INDENT> def __init__(self, wif=None): <NEW_LINE> <INDENT> if wif: <NEW_LINE> <INDENT> if isinstance(wif, str): <NEW_LINE> <INDENT> private_key_bytes, compressed, prefix = wif_to_bytes(wif) <NEW_LINE> self._pk = ECPrivateKey(private_key_bytes) <NEW_LINE> <DEDENT> elif isinstance(wif, ECPrivate... | This class represents a point on the elliptic curve secp256k1 and
provides all necessary cryptographic functionality. You shouldn't use
this class directly.
:param wif: A private key serialized to the Wallet Import Format. If the
argument is not supplied, a new private key will be created.
The ... | 62598ee00c0af96317c5496e |
class DirtyTracking(with_meta_class(TrackingBase)): <NEW_LINE> <INDENT> pass | Tracked class base
| 62598ee0bd1bec0571e143b4 |
class SatlanticPARDataParticle(DataParticle): <NEW_LINE> <INDENT> _data_particle_type = DataParticleType.PARSED <NEW_LINE> def _build_parsed_values(self): <NEW_LINE> <INDENT> match = SAMPLE_REGEX.match(self.raw_data) <NEW_LINE> if not match: <NEW_LINE> <INDENT> raise SampleException("No regex match of parsed sample dat... | Routines for parsing raw data into a data particle structure for the
Satlantic PAR sensor. Overrides the building of values, and the rest comes
along for free. | 62598ee08da39b475be0177b |
class Node: <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> self.item = -1 <NEW_LINE> self.parent = None <NEW_LINE> self.child = [] <NEW_LINE> self.nodeLink = None <NEW_LINE> self.tidList = set() <NEW_LINE> <DEDENT> def getChild(self, item): <NEW_LINE> <INDENT> for child in self.child: <NEW_LINE> <INDENT> i... | A class used to represent the node of localPeriodicPatternTree
...
Attributes:
----------
item : int
storing item of a node
parent : node
To maintain the parent of every node
child : list
To maintain the children of node
nodeLink : node
To maintain the next node of node
... | 62598ee091af0d3eaad383e9 |
@attr('a11y') <NEW_LINE> class LearnerProfileA11yTest(LearnerProfileTestMixin, WebAppTest): <NEW_LINE> <INDENT> def test_editable_learner_profile_a11y(self): <NEW_LINE> <INDENT> username, _ = self.log_in_as_unique_user() <NEW_LINE> profile_page = self.visit_profile_page(username) <NEW_LINE> profile_page.a11y_audit.conf... | Class to test learner profile accessibility. | 62598ee03539df3088eca884 |
class TestDownloadExceptionInit: <NEW_LINE> <INDENT> def test_init(self): <NEW_LINE> <INDENT> exception = DownloadException("This error is a tech heresy!") <NEW_LINE> with pytest.raises(Exception): <NEW_LINE> <INDENT> raise exception <NEW_LINE> <DEDENT> assert exception.message == "This error is a tech heresy!" | Test class for `hotness.exceptions.DownloadException.__init__` method. | 62598ee0596a897236126231 |
class MockTimesketchOutputModule(timesketch_out.TimesketchOutputModule): <NEW_LINE> <INDENT> def __init__(self, output_mediator): <NEW_LINE> <INDENT> return | Mock Timesketch output module for testing. | 62598ee023849d37ff84f68c |
class Ledning(object): <NEW_LINE> <INDENT> a1 = 0.0 <NEW_LINE> a2 = 0.0 <NEW_LINE> a_mid = 0.0 <NEW_LINE> sporhoyde_e = 0.0 <NEW_LINE> G_sno_tung = 0.0 <NEW_LINE> G_sno_lett = 0.0 <NEW_LINE> rho_sno_tung = 0.0 <NEW_LINE> rho_sno_lett = 0.0 <NEW_LINE> ec3 = True <NEW_LINE> def __init__(self, navn="", type="", G_0=0.0, d... | Klasse med felles attributter for alle ledninger.
``sporhoyde_e`` trekkes fra x-koordinat ``e[0]`` for å konvertere
ledningens høydekoordinat med nullpunkt i skinneoverkant
til mastenes lokale aksesystem med origo i mastefot. | 62598ee05f7d997b871f86be |
class SupplementaryDocumentTextExtractionTaskResponse(TaskResponse): <NEW_LINE> <INDENT> @property <NEW_LINE> def generated_text_data_checks(self): <NEW_LINE> <INDENT> return [ check for check in self.generated_checks if isinstance(check, GeneratedSupplementaryDocumentTextDataCheckResponse) ] | Represents a Supplementary Document Text Extraction task response | 62598ee0f548e778e5969b67 |
class SetComponentTypeCommand(BaseSequenceComponentNodeUndoCommand): <NEW_LINE> <INDENT> undo_id = gen_undo_id() <NEW_LINE> def __init__(self, seq_component_node_controller, node, new_component_type, parent=None): <NEW_LINE> <INDENT> super().__init__(seq_component_node_controller, parent) <NEW_LINE> self._node = node <... | QUndoCommand class for changing the component type of a sequence component tree node. | 62598ee030dc7b766599de59 |
class Room(db.Model): <NEW_LINE> <INDENT> user1 = db.StringProperty() <NEW_LINE> user2 = db.StringProperty() <NEW_LINE> def __str__(self): <NEW_LINE> <INDENT> str = "[" <NEW_LINE> if self.user1: <NEW_LINE> <INDENT> str += self.user1 <NEW_LINE> <DEDENT> if self.user2: <NEW_LINE> <INDENT> str += ", " + self.user2 <NEW_LI... | All the data we store for a room | 62598ee0379a373c97d975cc |
class InstanceServlet(object): <NEW_LINE> <INDENT> class Delegate(object): <NEW_LINE> <INDENT> def CreateBranchUtility(self, object_store_creator): <NEW_LINE> <INDENT> return BranchUtility.Create(object_store_creator) <NEW_LINE> <DEDENT> def CreateHostFileSystemProvider(self, object_store_creator, **optargs): <NEW_LINE... | Servlet for running on normal AppEngine instances.
Create this via GetConstructor() so that cache state can be shared amongst
them via the memoizing Delegate. | 62598ee066673b3332c2e979 |
class playwithjson: <NEW_LINE> <INDENT> def __init__(self, jsonfile): <NEW_LINE> <INDENT> self.jsonfile = jsonfile <NEW_LINE> <DEDENT> def access_json(self): <NEW_LINE> <INDENT> if str(self.jsonfile).endswith('.json'): <NEW_LINE> <INDENT> try: <NEW_LINE> <INDENT> fp = open(self.jsonfile, "r+") <NEW_LINE> <DEDENT> excep... | A simple class which opens and reads json files. | 62598ee07b25080760ed5a6d |
class LSHForMatrix: <NEW_LINE> <INDENT> def __init__(self, num_of_functions, seed = 1): <NEW_LINE> <INDENT> self.num_of_functions = num_of_functions <NEW_LINE> self.seed = seed <NEW_LINE> <DEDENT> def fit(self, shape): <NEW_LINE> <INDENT> np.random.seed(self.seed) <NEW_LINE> self.parameters = np.zeros((self.num_of_func... | 该类主要用于处理矩阵数据的LSH函数
通常情况下,只有一个hash function | 62598ee08e71fb1e983ba042 |
class set_license_key_result(object): <NEW_LINE> <INDENT> def __init__(self, success=None, e=None,): <NEW_LINE> <INDENT> self.success = success <NEW_LINE> self.e = e <NEW_LINE> <DEDENT> def read(self, iprot): <NEW_LINE> <INDENT> if iprot._fast_decode is not None and isinstance(iprot.trans, TTransport.CReadableTransport... | Attributes:
- success
- e | 62598ee099cbb53fe682f484 |
class PasteEmptyException(Exception): <NEW_LINE> <INDENT> pass | Exception class indicating a paste is empty | 62598ee0d7e4931a7ef3a66e |
class Stem: <NEW_LINE> <INDENT> def __init__(self, diameter, length): <NEW_LINE> <INDENT> self.__diameter = diameter <NEW_LINE> self.__length = length <NEW_LINE> <DEDENT> def getDiameter(self): <NEW_LINE> <INDENT> return self.__diameter <NEW_LINE> <DEDENT> def getLength(self): <NEW_LINE> <INDENT> return self.__length | The Stem constructor expects the stem diameter (float) and stem length (float). | 62598ee08e71fb1e983ba043 |
class Salsa20Cipher: <NEW_LINE> <INDENT> def __init__(self, key, nonce): <NEW_LINE> <INDENT> expect_byte_string(key) <NEW_LINE> expect_byte_string(nonce) <NEW_LINE> self._state = VoidPointer() <NEW_LINE> result = _raw_salsa20_lib.Salsa20_stream_init( key, c_size_t(len(key)), nonce, c_size_t(len(nonce)), self._state.add... | Salsa20 cipher object | 62598ee099fddb7c1ca620ef |
class eq_ka(Equation): <NEW_LINE> <INDENT> class p_ka1(Variable): <NEW_LINE> <INDENT> name = 'p_ka1' <NEW_LINE> unit = joule / (kelvin ** 2 * meter * second) <NEW_LINE> domain = 'real' <NEW_LINE> latex_name = 'p_1' <NEW_LINE> default = 6.84e-05 <NEW_LINE> <DEDENT> class p_ka2(Variable): <NEW_LINE> <INDENT> name = 'p_ka... | k_a as a function of air temperature.
(Table A.3 in :cite:`monteith_principles_2007`) | 62598ee0e5267d203ee69ed6 |
class Lexer(ABC): <NEW_LINE> <INDENT> @abstractmethod <NEW_LINE> def lex(self, lexer_state: LexerState, parser_state: Any) -> Iterator[Token]: <NEW_LINE> <INDENT> return NotImplemented <NEW_LINE> <DEDENT> def make_lexer_state(self, text): <NEW_LINE> <INDENT> line_ctr = LineCounter(b'\n' if isinstance(text, bytes) else ... | Lexer interface
Method Signatures:
lex(self, lexer_state, parser_state) -> Iterator[Token] | 62598ee01b99ca400228e7f6 |
class Address(BaseModel): <NEW_LINE> <INDENT> street: str = AddressFields.street <NEW_LINE> city: str = AddressFields.city <NEW_LINE> state: str = AddressFields.state <NEW_LINE> zip_code: str = AddressFields.zip_code | The address information of a person | 62598ee0460517430c430a5c |
class FlowMode(Enum): <NEW_LINE> <INDENT> Constants = 1 <NEW_LINE> PowerFunction = 2 <NEW_LINE> Slope = 3 | TRDI restricts the constant
method to use of the top depth cell only and the power-law
estimate to using all of the available depth cells, but provides
an additional 3-point slope method to fit situations where wind
significantly affects the velocity at the water surface. | 62598ee056b00c62f0fb0ea3 |
class CompactJSONDeserialiser: <NEW_LINE> <INDENT> def __init__(self, registry: Registry = None) -> None: <NEW_LINE> <INDENT> self.registry = registry or Registry() <NEW_LINE> <DEDENT> def deserialise_meta(self, meta) -> Metadata: <NEW_LINE> <INDENT> metadata = Metadata() <NEW_LINE> for key in META_KEYS: <NEW_LINE> <IN... | JSON Refract Deserialiser | 62598ee010dbd63aa1c6f143 |
class Edge: <NEW_LINE> <INDENT> def __init__(self, transport, s_entity, e_entity): <NEW_LINE> <INDENT> self.transport = transport <NEW_LINE> self.start = s_entity <NEW_LINE> self.end = e_entity <NEW_LINE> <DEDENT> def cost(self): <NEW_LINE> <INDENT> return self.transport.cost() | An edge is a directed arrow from one entity to another | 62598ee057b8e32f525073ef |
@urls.register <NEW_LINE> class HealthMonitors(generic.View): <NEW_LINE> <INDENT> url_regex = r'nlbaas/healthmonitors/$' <NEW_LINE> @rest_utils.ajax() <NEW_LINE> def post(self, request): <NEW_LINE> <INDENT> kwargs = {'loadbalancer_id': request.DATA.get('loadbalancer_id'), 'pool_id': request.DATA.get('parentResourceId')... | API for load balancer pool health monitors.
| 62598ee038b623060ffa7668 |
class ArticleListView(generic.ListView): <NEW_LINE> <INDENT> template_name = 'blog/article_list.html' <NEW_LINE> context_object_name = 'article_list' <NEW_LINE> model = Article <NEW_LINE> paginate_by = 12 <NEW_LINE> def get_queryset(self): <NEW_LINE> <INDENT> if self.queryset is not None: <NEW_LINE> <INDENT> queryset =... | Muestra lista de artículos. | 62598ee0a8ecb0332586f7bb |
class _EstimateFeeBaseClass: <NEW_LINE> <INDENT> def __init__(self, refresh_rate, timeout): <NEW_LINE> <INDENT> self.refresh_rate = refresh_rate <NEW_LINE> self.timeout = timeout <NEW_LINE> <DEDENT> def limit_requests(func): <NEW_LINE> <INDENT> @functools.wraps(func) <NEW_LINE> def wrapper(self, *args, **kwargs): <NEW_... | api interfaces should return a tuple of low, medium and high priority fees, in sat/byte.
they should also update cached api data every self._refresh_rate seconds.
sub-classes should raise BlockchainConnectionError if it cannot connect to the specified source.
sub-classes need to implement all_priorities property, tha... | 62598ee0e64d504609df86a9 |
class ImagePushRetry(Exception): <NEW_LINE> <INDENT> pass | An exception to handle retries for pushing container images | 62598ee030bbd7224646820b |
class VerificarPositivo(VerificarMinimo): <NEW_LINE> <INDENT> def __init__(self, msg="Por favor, digite um valor positivo"): <NEW_LINE> <INDENT> super().__init__(0, msg) | Verifica se o campo é um valor positivo, isto é maior ou igual a zero. | 62598ee0f7d966606f7465c3 |
class ParamTestLayered(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.rng = np.random.RandomState(0) <NEW_LINE> tf.reset_default_graph() <NEW_LINE> self.m = hb.model.Model() <NEW_LINE> self.m.p = hb.param.Variable([3], n_layers = [2,3]) <NEW_LINE> self.m.q = hb.param.Variable([3], ... | test Layered LocalVariable | 62598ee0bd1bec0571e143b5 |
class MiniJinja(object): <NEW_LINE> <INDENT> def __init__(self, templates='.'): <NEW_LINE> <INDENT> import re <NEW_LINE> import sys <NEW_LINE> self.PY3K = sys.version_info[0] == 3 <NEW_LINE> self.path = templates + '/' <NEW_LINE> self.tag = re.compile('{{ *(?P<tag>\w+) *}}') <NEW_LINE> <DEDENT> def render(self, tplfil... | Template engine that knows how to render {{ tag }} | 62598ee0fbf16365ca792677 |
class SpiderDispatcher(object): <NEW_LINE> <INDENT> def __init__(self, num_threads, resource_queue): <NEW_LINE> <INDENT> self.num_threads = num_threads <NEW_LINE> self.queue = resource_queue <NEW_LINE> self.handler = None <NEW_LINE> <DEDENT> def __do_work(self, task_obj): <NEW_LINE> <INDENT> self.handler(task_obj) <NEW... | Spider dispatcher class.
This class controls the threading and concurrency
Attributes:
num_threads: concurrency
resource_queue: object queue on which task is performed
handler: task performer object | 62598ee03317a56b869bd851 |
class SpindleStatus(IntEnum): <NEW_LINE> <INDENT> CW = 0 <NEW_LINE> CCW = 1 <NEW_LINE> OFF = 2 | Enumeration for Spindle status. | 62598ee0435de62698e9a3aa |
class Solution: <NEW_LINE> <INDENT> def findMode(self, root): <NEW_LINE> <INDENT> if not root: <NEW_LINE> <INDENT> return [] <NEW_LINE> <DEDENT> self.m = {} <NEW_LINE> self.dfs(root) <NEW_LINE> max_val = -sys.maxint-1 <NEW_LINE> ret = [] <NEW_LINE> for k in self.m: <NEW_LINE> <INDENT> if self.m[k] > max_val: <NEW_LINE>... | @param root: a root of integer
@return: return a integer list | 62598ee023849d37ff84f68d |
class Random(object): <NEW_LINE> <INDENT> @staticmethod <NEW_LINE> def nextChassisAxis(): <NEW_LINE> <INDENT> return random.uniform(CHASSIS_MIN_AXIS, CHASSIS_MAX_AXIS) <NEW_LINE> <DEDENT> @staticmethod <NEW_LINE> def nextChassisDensity(): <NEW_LINE> <INDENT> return random.uniform(CHASSIS_MIN_DENSITY, CHASSIS_MAX_DENSIT... | All methods are static
| 62598ee08e7ae83300ee7662 |
class CommandResponse(Exception): <NEW_LINE> <INDENT> def __init__(self, status, message, iterable=True, task_id=None): <NEW_LINE> <INDENT> self.status = status <NEW_LINE> self.message = message <NEW_LINE> self.iterable = iterable <NEW_LINE> self.task_id = task_id <NEW_LINE> <DEDENT> @property <NEW_LINE> def report_mes... | The result of command execution | 62598ee06e29344779afec01 |
class File(str): <NEW_LINE> <INDENT> def __new__(cls, name, package): <NEW_LINE> <INDENT> return str.__new__(cls, name) <NEW_LINE> <DEDENT> def __init__(self, name, package): <NEW_LINE> <INDENT> self.package = package <NEW_LINE> <DEDENT> @property <NEW_LINE> def path(self): <NEW_LINE> <INDENT> return os.path.join(self.... | The name of a package file (source or data)
with reference to the package and its absolute path. | 62598ee02ae34c7f260a96bb |
class ExportTags(Choreography): <NEW_LINE> <INDENT> def __init__(self, temboo_session): <NEW_LINE> <INDENT> Choreography.__init__(self, temboo_session, '/Library/Box/ExportTags') <NEW_LINE> <DEDENT> def new_input_set(self): <NEW_LINE> <INDENT> return ExportTagsInputSet() <NEW_LINE> <DEDENT> def _make_result_set(self, r... | Create a new instance of the ExportTags Choreography. A TembooSession object, containing a valid
set of Temboo credentials, must be supplied. | 62598ee0627d3e7fe0e0545b |
class Course: <NEW_LINE> <INDENT> def __init__(self, json: dict): <NEW_LINE> <INDENT> self.id = json['id'] <NEW_LINE> self.code = json['code'] <NEW_LINE> self.name = json['name'] <NEW_LINE> self.term = json['term'] <NEW_LINE> self.events = [] <NEW_LINE> for event in json['meeting_sections']: <NEW_LINE> <INDENT> for sub... | A UTM Course | 62598ee001c39578d7f1137c |
class BasicShape(Element): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> super.__init__() | classdocs | 62598ee0097d151d1a2bf5f2 |
class User(db.Model, UserMixin): <NEW_LINE> <INDENT> id = db.Column(db.Integer, primary_key=True) <NEW_LINE> login = db.Column(db.String(30), unique=True, nullable=False) <NEW_LINE> pwdhash = db.Column(db.String(), nullable=False) <NEW_LINE> created_at = db.Column(db.DateTime(), default=datetime.utcnow()) <NEW_LINE> la... | Represent a user. | 62598ee08e7ae83300ee7663 |
class ModuleProxyWrapper(nn.Module): <NEW_LINE> <INDENT> def __init__(self, module: nn.Module): <NEW_LINE> <INDENT> super().__init__() <NEW_LINE> assert hasattr(module, "module"), "ModuleProxyWrapper expects input to wrap another module" <NEW_LINE> self.module = module <NEW_LINE> <DEDENT> def __getattr__(sel... | Wrap a DistributedDataParallel module and forward requests for missing
attributes to the module wrapped by DDP (the twice-wrapped module).
Also forward calls to :func:`state_dict` and :func:`load_state_dict`.
Usage::
module.xyz = "hello world"
wrapped_module = DistributedDataParallel(module, **ddp_args)
w... | 62598ee097e22403b38394c3 |
class EvaluationRoundLimit(ModelNormal): <NEW_LINE> <INDENT> allowed_values = { } <NEW_LINE> validations = { } <NEW_LINE> additional_properties_type = None <NEW_LINE> _nullable = False <NEW_LINE> @cached_property <NEW_LINE> def openapi_types(): <NEW_LINE> <INDENT> lazy_import() <NEW_LINE> return { 'limit_type': (Evalua... | NOTE: This class is auto generated by OpenAPI Generator.
Ref: https://openapi-generator.tech
Do not edit the class manually.
Attributes:
allowed_values (dict): The key is the tuple path to the attribute
and the for var_name this is (var_name,). The value is a dict
with a capitalized key describing the a... | 62598ee0cb5e8a47e493b463 |
class SampleOTU(SchemaMixin, Base): <NEW_LINE> <INDENT> __tablename__ = 'sample_otu' <NEW_LINE> sample_id = Column(Integer, ForeignKey(SCHEMA + '.sample_context.id'), primary_key=True) <NEW_LINE> otu_id = Column(Integer, ForeignKey(SCHEMA + '.otu.id'), primary_key=True) <NEW_LINE> count = Column(Float, nullable=False) ... | Combined table + site abundance values. | 62598ee024f1403a92684b8e |
class oaiharvest_repository_with_approval(oaiharvest_harvest_repositories): <NEW_LINE> <INDENT> record_workflow = "oaiharvest_record_approval" <NEW_LINE> @staticmethod <NEW_LINE> def get_description(bwo): <NEW_LINE> <INDENT> from flask import render_template <NEW_LINE> identifiers = None <NEW_LINE> extra_data = bwo.get... | A workflow for use with OAI harvesting in BibSched with approval. | 62598ee0656771135c487c65 |
class SelectSmartSimilar(bpy.types.Operator): <NEW_LINE> <INDENT> bl_idname = "view3d.selectsmartsimilar" <NEW_LINE> bl_label = "Select Smart Similar" <NEW_LINE> bl_options = {'REGISTER', 'UNDO'} <NEW_LINE> def invoke(self, context, event): <NEW_LINE> <INDENT> if bpy.context.mode=='OBJECT': <NEW_LINE> <INDENT> bpy.ops.... | SelectSmartVert | 62598ee067a9b606de5445a2 |
class BasePageElement(): <NEW_LINE> <INDENT> def __set__(self, obj, value): <NEW_LINE> <INDENT> driver = obj.driver <NEW_LINE> WebDriverWait(driver, 100).until( lambda driver: driver.find_element_by_name(self.locator)) <NEW_LINE> driver.find_element_by_name(self.locator).send_keys(value) <NEW_LINE> <DEDENT> def __get__... | Base page class that is initialized on every page object class. | 62598ee06fb2d068a769310c |
class PasswdMap(maps.Map): <NEW_LINE> <INDENT> def Add(self, entry): <NEW_LINE> <INDENT> if not isinstance(entry, PasswdMapEntry): <NEW_LINE> <INDENT> raise TypeError <NEW_LINE> <DEDENT> return super(PasswdMap, self).Add(entry) | This class represents an NSS passwd map.
Map data is stored as a list of MapEntry objects, see the abstract
class Map. | 62598ee0d6c5a102081e0705 |
class Liboldx(AutotoolsPackage, XorgPackage): <NEW_LINE> <INDENT> homepage = "https://cgit.freedesktop.org/xorg/lib/liboldX/" <NEW_LINE> xorg_mirror_path = "lib/liboldX-1.0.1.tar.gz" <NEW_LINE> version('1.0.1', sha256='74322dbf04df69787485eb24b16e12783dfc3454befaf18482ead51bd7b55dc8') <NEW_LINE> depends_on('libx11') <N... | X version 10 backwards compatibility. | 62598ee067a9b606de5445a3 |
class ModelMetaclass(type): <NEW_LINE> <INDENT> def __new__(cls, name, bases, attrs): <NEW_LINE> <INDENT> if name == 'Model': <NEW_LINE> <INDENT> return type.__new__(cls, name, bases, attrs) <NEW_LINE> <DEDENT> tableName = attrs.get('__table__', None) or name <NEW_LINE> logging.info('found model: %s(table: %s)' % (name... | Model类的元类
--------------------------------
所有元类都继承自type | 62598ee045492302aabfaa87 |
class CalendarEvent(models.Model): <NEW_LINE> <INDENT> CSS_CLASS_CHOICES = ( ('', _('Normal')), ('event-warning', _('Warning')), ('event-info', _('Info')), ('event-success', _('Success')), ('event-inverse', _('Inverse')), ('event-special', _('Special')), ('event-important', _('Important')), ) <NEW_LINE> title = models.... | Calendar Events | 62598ee0e5267d203ee69ed8 |
class Dateframeable(models.Model): <NEW_LINE> <INDENT> partial_date_validator = RegexValidator(regex="^[0-9]{4}(-[0-9]{2}){0,2}$", message="Date has wrong format") <NEW_LINE> start_date = models.CharField( _("start date"), max_length=10, blank=True, null=True, validators=[partial_date_validator, validate_partial_date],... | An abstract base class model that provides a start and an end dates to the class.
Uncomplete dates can be used. The validation pattern is: "^[0-9]{4}(-[0-9]{2}){0,2}$" | 62598ee05fdd1c0f98e5c583 |
class ModelClassProxy(object): <NEW_LINE> <INDENT> @classmethod <NEW_LINE> def _create_class_proxy(cls, proxy_cls): <NEW_LINE> <INDENT> def make_method(name): <NEW_LINE> <INDENT> def method(self, *args, **kwargs): <NEW_LINE> <INDENT> attr = getattr(object.__getattribute__(self, "_model_cls"), name) <NEW_LINE> return at... | Model class proxy for clients.
Wraps client-dependant methods as partial methods with the client assigned. | 62598ee0462c4b4f79db9fce |
class TestCJKTokenizer(InvenioTestCase): <NEW_LINE> <INDENT> @classmethod <NEW_LINE> def setUp(self): <NEW_LINE> <INDENT> _TOKENIZERS = load_tokenizers() <NEW_LINE> self.tokenizer = _TOKENIZERS["BibIndexCJKTokenizer"]() <NEW_LINE> <DEDENT> def test_tokenize_for_words_phrase_galaxy(self): <NEW_LINE> <INDENT> phrase = "g... | Tests for CJK Tokenizer which splits CJK words into characters and treats
every single character as a word | 62598ee00a50d4780f70397e |
class NevaCoin(Bitcoin): <NEW_LINE> <INDENT> name = 'nevacoin' <NEW_LINE> symbols = ('NEVA', ) <NEW_LINE> seeds = ('n1.nevacoin.net', 'n2.nevacoin.net', 'n3.nevacoin.net', 'n4.nevacoin.net', 'seed.crypto.si') <NEW_LINE> port = 7391 <NEW_LINE> message_start = b'\xe4\x83\xe6\x32' <NEW_LINE> base58_prefixes = { 'PUBKEY_AD... | Class with all the necessary NEVA network information based on
http://www.github.com/Nevacoin/nevacoin/blob/master/src/chainparams.cpp
(date of access: 02/11/2018) | 62598ee0460517430c430a5e |
class Downloadables(AutoUnload, set): <NEW_LINE> <INDENT> def __init__(self): <NEW_LINE> <INDENT> _downloadables_list.append(self) <NEW_LINE> <DEDENT> def add(self, item): <NEW_LINE> <INDENT> if item in self: <NEW_LINE> <INDENT> return <NEW_LINE> <DEDENT> _downloadables_list._add_to_download_table(item) <NEW_LINE> supe... | Class used to store downloadables for a script. | 62598ee08c0ade5d55dc296e |
class TransactionOutput: <NEW_LINE> <INDENT> def __init__(self, recipient_address, value): <NEW_LINE> <INDENT> self.recipient = recipient_address <NEW_LINE> self.value = value <NEW_LINE> <DEDENT> def to_dict(self): <NEW_LINE> <INDENT> d = { 'recipient_address': self.recipient, 'value': self.value } <NEW_LINE> return d | トランザクションの中で Output (送金相手と送る金額)を管理する | 62598ee038b623060ffa766a |
@decorators.class_logging <NEW_LINE> class Resampler(object): <NEW_LINE> <INDENT> def __init__(self, source_samplerate, destination_samplerate=16000, dtype=np.int16, channels=1): <NEW_LINE> <INDENT> super(Resampler, self).__init__() <NEW_LINE> self.ratio = destination_samplerate / float(source_samplerate) <NEW_LINE> se... | docstring for Resapler | 62598ee057b8e32f525073f0 |
class StorageServiceProperties(msrest.serialization.Model): <NEW_LINE> <INDENT> _attribute_map = { 'hour_metrics': {'key': 'HourMetrics', 'type': 'Metrics'}, 'minute_metrics': {'key': 'MinuteMetrics', 'type': 'Metrics'}, 'cors': {'key': 'Cors', 'type': '[CorsRule]', 'xml': {'wrapped': True}}, 'protocol': {'key': 'Proto... | Storage service properties.
:ivar hour_metrics: A summary of request statistics grouped by API in hourly aggregates for
files.
:vartype hour_metrics: ~azure.storage.fileshare.models.Metrics
:ivar minute_metrics: A summary of request statistics grouped by API in minute aggregates for
files.
:vartype minute_metrics: ~... | 62598ee021a7993f00c64541 |
class PoolAdder(object): <NEW_LINE> <INDENT> def __init__(self, threshold): <NEW_LINE> <INDENT> self._threshold = threshold <NEW_LINE> self._conn = RedisClient() <NEW_LINE> self._tester = ValidityTester() <NEW_LINE> self._crawler = FreeProxyGetter() <NEW_LINE> <DEDENT> def is_over_threshold(self): <NEW_LINE> <INDENT> i... | add proxy to pool | 62598ee00c0af96317c54972 |
class LocalizedObjectAnnotation(proto.Message): <NEW_LINE> <INDENT> mid = proto.Field(proto.STRING, number=1,) <NEW_LINE> language_code = proto.Field(proto.STRING, number=2,) <NEW_LINE> name = proto.Field(proto.STRING, number=3,) <NEW_LINE> score = proto.Field(proto.FLOAT, number=4,) <NEW_LINE> bounding_poly = proto.Fi... | Set of detected objects with bounding boxes.
Attributes:
mid (str):
Object ID that should align with
EntityAnnotation mid.
language_code (str):
The BCP-47 language code, such as "en-US" or "sr-Latn". For
more information, see
http://www.unicode.org/reports/tr35/#Unicode_... | 62598ee0009cb60464cffb23 |
class TestDefaultApi(unittest.TestCase): <NEW_LINE> <INDENT> def setUp(self): <NEW_LINE> <INDENT> self.api = samsara.api.default_api.DefaultApi() <NEW_LINE> <DEDENT> def tearDown(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def test_create_address(self): <NEW_LINE> <INDENT> pass <NEW_LINE> <DEDENT> def test_crea... | DefaultApi unit test stubs | 62598ee08da39b475be0177f |
class TestRedisIntervalIADD(object): <NEW_LINE> <INDENT> @classmethod <NEW_LINE> def setup_class(cls): <NEW_LINE> <INDENT> cls.redis = RedisInterval(host="localhost") <NEW_LINE> <DEDENT> def test_add_simple_text(self): <NEW_LINE> <INDENT> value = self.redis.iadd("test", 0, 10, "simple text") <NEW_LINE> assert value == ... | Tests the IADD command | 62598ee0bd1bec0571e143b6 |
class TestXDisplacement: <NEW_LINE> <INDENT> x = 0.452 <NEW_LINE> def test_identity(self): <NEW_LINE> <INDENT> _, r = xdisplacement(0) <NEW_LINE> assert r == 0 <NEW_LINE> <DEDENT> def test_hermitian(self, hbar): <NEW_LINE> <INDENT> H, _ = xdisplacement(self.x) <NEW_LINE> assert is_hermitian(H) <NEW_LINE> assert is_herm... | Tests for x displacement function | 62598ee03539df3088eca887 |
class Database: <NEW_LINE> <INDENT> def __init__(self, name, **options): <NEW_LINE> <INDENT> self.name = name <NEW_LINE> self.object_hook = options.pop('object_hook', None) <NEW_LINE> self.encoder = options.pop('encoder', None) <NEW_LINE> self.loop = options.pop('loop', asyncio.get_event_loop()) <NEW_LINE> if options.p... | The "database" object. Internally based on ``json``. | 62598ee023849d37ff84f68f |
class Webhook(LitecordObject): <NEW_LINE> <INDENT> def __init__(self, user, channel, raw): <NEW_LINE> <INDENT> self.id = int(raw['webhook_id']) <NEW_LINE> self._update(user, channel, raw) <NEW_LINE> <DEDENT> def _update(self, user, channel, raw): <NEW_LINE> <INDENT> self._raw = raw <NEW_LINE> self.channel = channel <NE... | A webhook object
Attributes
----------
_raw: dict
Raw webhook data.
id: int
ID of the webhook.
channel_id: int
ID of the channel the webhook refers to.
creator_id: int
ID of the user who created the webhook.
channel: :class:`Channel`
Channel the webhook refers to.
creator_id: :class:`User`
User... | 62598ee060cbc95b06362911 |
class ProfileView(RetrieveView): <NEW_LINE> <INDENT> serializer_class = ProfileSerializer <NEW_LINE> lookup_field = 'user__username' <NEW_LINE> queryset = Profile.objects.get_queryset() | View for detail profile User
params: username | 62598ee03c8af77a43b6721d |
class ModifyInfoForm(forms.Form): <NEW_LINE> <INDENT> nick_name = forms.CharField(max_length=20) <NEW_LINE> mobile = forms.CharField(max_length=11) <NEW_LINE> email = forms.EmailField() | 补充昵称和号码及修改邮箱 | 62598ee092d797404e387e66 |
class WordFilter(BaseFilter): <NEW_LINE> <INDENT> filterArgs = [ ('--word', {'action':'store', 'nargs':'*', 'help':'only output lines matching any of WORD'}), ] <NEW_LINE> def __init__(self, commandLineArgs): <NEW_LINE> <INDENT> BaseFilter.__init__(self, commandLineArgs) <NEW_LINE> if 'word' in self.commandLineArgs and... | accepts only if line contains any of the words specified by --word
| 62598ee001c39578d7f1137e |
class Identifier(str): <NEW_LINE> <INDENT> english_dictionary = enchant.Dict('en_US') <NEW_LINE> word_spec = re.compile(r'[A-Z]?[a-z]+|[A-Z]+(?=[A-Z][a-z]|[0-9]|$)') <NEW_LINE> @classmethod <NEW_LINE> def _readable(cls, word): <NEW_LINE> <INDENT> return len(word) > 1 and cls.english_dictionary.check(word) <NEW_LINE> <D... | handling an identifier in source code. | 62598ee056ac1b37e63007c2 |
class geom_rect(geom): <NEW_LINE> <INDENT> DEFAULT_AES = {'alpha': None, 'color': None, 'fill': '#333333', 'linetype': 'solid', 'size': 1.0} <NEW_LINE> REQUIRED_AES = {'xmin', 'xmax', 'ymin', 'ymax'} <NEW_LINE> DEFAULT_PARAMS = {} <NEW_LINE> _aes_renames = {'linetype': 'linestyle', 'size': 'linewidth', 'fill': 'facecol... | 2-dimensional rectangle
Parameters
----------
xmin:
min value for x
xmax:
max value for x
ymin:
min value for y
ymax:
max value for y
color:
color of outer line
alpha:
transparency of fill
size:
size of outer line
linetype:
type of the line ('solid', 'dashed', 'dashdot', 'dotted')
fill:... | 62598ee02c8b7c6e89bd1d95 |
class FindRefsWorker(DownloadWorker): <NEW_LINE> <INDENT> def do_task(self, filepath, url, directory, retry, timeout, unit, katana): <NEW_LINE> <INDENT> response = self.session.get( "%s/%s" % (url, filepath), allow_redirects=False, timeout=timeout ) <NEW_LINE> if response.status_code != 200: <NEW_LINE> <INDENT> return ... | Part of the Git Dumper procedure.
Find refs/ | 62598ee0cad5886f8bdc38d6 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.