file_path
stringlengths
20
202
content
stringlengths
9
3.85M
size
int64
9
3.85M
lang
stringclasses
9 values
avg_line_length
float64
3.33
100
max_line_length
int64
8
993
alphanum_fraction
float64
0.26
0.93
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/tnt.py
""" pygments.lexers.tnt ~~~~~~~~~~~~~~~~~~~ Lexer for Typographic Number Theory. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import Lexer from pygments.token import Text, Comment, Operator, Keyword, Name, Number, \ Punctuation, Error __all__ = ['TNTLexer'] class TNTLexer(Lexer): """ Lexer for Typographic Number Theory, as described in the book Gödel, Escher, Bach, by Douglas R. Hofstadter .. versionadded:: 2.7 """ name = 'Typographic Number Theory' url = 'https://github.com/Kenny2github/language-tnt' aliases = ['tnt'] filenames = ['*.tnt'] cur = [] LOGIC = set('⊃→]&∧^|∨Vv') OPERATORS = set('+.⋅*') VARIABLES = set('abcde') PRIMES = set("'′") NEGATORS = set('~!') QUANTIFIERS = set('AE∀∃') NUMBERS = set('0123456789') WHITESPACE = set('\t \v\n') RULES = re.compile('''(?xi) joining | separation | double-tilde | fantasy\\ rule | carry[- ]over(?:\\ of)?(?:\\ line)?\\ ([0-9]+) | detachment | contrapositive | De\\ Morgan | switcheroo | specification | generalization | interchange | existence | symmetry | transitivity | add\\ S | drop\\ S | induction | axiom\\ ([1-5]) | premise | push | pop ''') LINENOS = re.compile(r'(?:[0-9]+)(?:(?:, ?|,? and )(?:[0-9]+))*') COMMENT = re.compile(r'\[[^\n\]]+\]') def __init__(self, *args, **kwargs): Lexer.__init__(self, *args, **kwargs) self.cur = [] def whitespace(self, start, text, required=False): """Tokenize whitespace.""" end = start try: while text[end] in self.WHITESPACE: end += 1 except IndexError: end = len(text) if required and end == start: raise AssertionError if end != start: self.cur.append((start, Text, text[start:end])) return end def variable(self, start, text): """Tokenize a variable.""" if text[start] not in self.VARIABLES: raise AssertionError end = start+1 while text[end] in self.PRIMES: end += 1 self.cur.append((start, Name.Variable, text[start:end])) return end def term(self, start, text): """Tokenize a term.""" if text[start] == 'S': # S...S(...) or S...0 end = start+1 while text[end] == 'S': end += 1 self.cur.append((start, Number.Integer, text[start:end])) return self.term(end, text) if text[start] == '0': # the singleton 0 self.cur.append((start, Number.Integer, text[start])) return start+1 if text[start] in self.VARIABLES: # a''... return self.variable(start, text) if text[start] == '(': # (...+...) self.cur.append((start, Punctuation, text[start])) start = self.term(start+1, text) if text[start] not in self.OPERATORS: raise AssertionError self.cur.append((start, Operator, text[start])) start = self.term(start+1, text) if text[start] != ')': raise AssertionError self.cur.append((start, Punctuation, text[start])) return start+1 raise AssertionError # no matches def formula(self, start, text): """Tokenize a formula.""" if text[start] in self.NEGATORS: # ~<...> end = start+1 while text[end] in self.NEGATORS: end += 1 self.cur.append((start, Operator, text[start:end])) return self.formula(end, text) if text[start] in self.QUANTIFIERS: # Aa:<...> self.cur.append((start, Keyword.Declaration, text[start])) start = self.variable(start+1, text) if text[start] != ':': raise AssertionError self.cur.append((start, Punctuation, text[start])) return self.formula(start+1, text) if text[start] == '<': # <...&...> self.cur.append((start, Punctuation, text[start])) start = self.formula(start+1, text) if text[start] not in self.LOGIC: raise AssertionError self.cur.append((start, Operator, text[start])) start = self.formula(start+1, text) if text[start] != '>': raise AssertionError self.cur.append((start, Punctuation, text[start])) return start+1 # ...=... start = self.term(start, text) if text[start] != '=': raise AssertionError self.cur.append((start, Operator, text[start])) start = self.term(start+1, text) return start def rule(self, start, text): """Tokenize a rule.""" match = self.RULES.match(text, start) if match is None: raise AssertionError groups = sorted(match.regs[1:]) # exclude whole match for group in groups: if group[0] >= 0: # this group matched self.cur.append((start, Keyword, text[start:group[0]])) self.cur.append((group[0], Number.Integer, text[group[0]:group[1]])) if group[1] != match.end(): self.cur.append((group[1], Keyword, text[group[1]:match.end()])) break else: self.cur.append((start, Keyword, text[start:match.end()])) return match.end() def lineno(self, start, text): """Tokenize a line referral.""" end = start while text[end] not in self.NUMBERS: end += 1 self.cur.append((start, Punctuation, text[start])) self.cur.append((start+1, Text, text[start+1:end])) start = end match = self.LINENOS.match(text, start) if match is None: raise AssertionError if text[match.end()] != ')': raise AssertionError self.cur.append((match.start(), Number.Integer, match.group(0))) self.cur.append((match.end(), Punctuation, text[match.end()])) return match.end() + 1 def error_till_line_end(self, start, text): """Mark everything from ``start`` to the end of the line as Error.""" end = start try: while text[end] != '\n': # there's whitespace in rules end += 1 except IndexError: end = len(text) if end != start: self.cur.append((start, Error, text[start:end])) end = self.whitespace(end, text) return end def get_tokens_unprocessed(self, text): """Returns a list of TNT tokens.""" self.cur = [] start = end = self.whitespace(0, text) while start <= end < len(text): try: # try line number while text[end] in self.NUMBERS: end += 1 if end != start: # actual number present self.cur.append((start, Number.Integer, text[start:end])) # whitespace is required after a line number orig = len(self.cur) try: start = end = self.whitespace(end, text, True) except AssertionError: del self.cur[orig:] start = end = self.error_till_line_end(end, text) continue # at this point it could be a comment match = self.COMMENT.match(text, start) if match is not None: self.cur.append((start, Comment, text[start:match.end()])) start = end = match.end() # anything after the closing bracket is invalid start = end = self.error_till_line_end(start, text) # do not attempt to process the rest continue del match if text[start] in '[]': # fantasy push or pop self.cur.append((start, Keyword, text[start])) start += 1 end += 1 else: # one formula, possibly containing subformulae orig = len(self.cur) try: start = end = self.formula(start, text) except (AssertionError, RecursionError): # not well-formed del self.cur[orig:] while text[end] not in self.WHITESPACE: end += 1 self.cur.append((start, Error, text[start:end])) start = end # skip whitespace after formula orig = len(self.cur) try: start = end = self.whitespace(end, text, True) except AssertionError: del self.cur[orig:] start = end = self.error_till_line_end(start, text) continue # rule proving this formula a theorem orig = len(self.cur) try: start = end = self.rule(start, text) except AssertionError: del self.cur[orig:] start = end = self.error_till_line_end(start, text) continue # skip whitespace after rule start = end = self.whitespace(end, text) # line marker if text[start] == '(': orig = len(self.cur) try: start = end = self.lineno(start, text) except AssertionError: del self.cur[orig:] start = end = self.error_till_line_end(start, text) continue start = end = self.whitespace(start, text) except IndexError: try: del self.cur[orig:] except NameError: pass # if orig was never defined, fine self.error_till_line_end(start, text) return self.cur
10,440
Python
37.386029
79
0.494444
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/business.py
""" pygments.lexers.business ~~~~~~~~~~~~~~~~~~~~~~~~ Lexers for "business-oriented" languages. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, include, words, bygroups from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Error, Whitespace from pygments.lexers._openedge_builtins import OPENEDGEKEYWORDS __all__ = ['CobolLexer', 'CobolFreeformatLexer', 'ABAPLexer', 'OpenEdgeLexer', 'GoodDataCLLexer', 'MaqlLexer'] class CobolLexer(RegexLexer): """ Lexer for OpenCOBOL code. .. versionadded:: 1.6 """ name = 'COBOL' aliases = ['cobol'] filenames = ['*.cob', '*.COB', '*.cpy', '*.CPY'] mimetypes = ['text/x-cobol'] flags = re.IGNORECASE | re.MULTILINE # Data Types: by PICTURE and USAGE # Operators: **, *, +, -, /, <, >, <=, >=, =, <> # Logical (?): NOT, AND, OR # Reserved words: # http://opencobol.add1tocobol.com/#reserved-words # Intrinsics: # http://opencobol.add1tocobol.com/#does-opencobol-implement-any-intrinsic-functions tokens = { 'root': [ include('comment'), include('strings'), include('core'), include('nums'), (r'[a-z0-9]([\w\-]*[a-z0-9]+)?', Name.Variable), # (r'[\s]+', Text), (r'[ \t]+', Whitespace), ], 'comment': [ (r'(^.{6}[*/].*\n|^.{6}|\*>.*\n)', Comment), ], 'core': [ # Figurative constants (r'(^|(?<=[^\w\-]))(ALL\s+)?' r'((ZEROES)|(HIGH-VALUE|LOW-VALUE|QUOTE|SPACE|ZERO)(S)?)' r'\s*($|(?=[^\w\-]))', Name.Constant), # Reserved words STATEMENTS and other bolds (words(( 'ACCEPT', 'ADD', 'ALLOCATE', 'CALL', 'CANCEL', 'CLOSE', 'COMPUTE', 'CONFIGURATION', 'CONTINUE', 'DATA', 'DELETE', 'DISPLAY', 'DIVIDE', 'DIVISION', 'ELSE', 'END', 'END-ACCEPT', 'END-ADD', 'END-CALL', 'END-COMPUTE', 'END-DELETE', 'END-DISPLAY', 'END-DIVIDE', 'END-EVALUATE', 'END-IF', 'END-MULTIPLY', 'END-OF-PAGE', 'END-PERFORM', 'END-READ', 'END-RETURN', 'END-REWRITE', 'END-SEARCH', 'END-START', 'END-STRING', 'END-SUBTRACT', 'END-UNSTRING', 'END-WRITE', 'ENVIRONMENT', 'EVALUATE', 'EXIT', 'FD', 'FILE', 'FILE-CONTROL', 'FOREVER', 'FREE', 'GENERATE', 'GO', 'GOBACK', 'IDENTIFICATION', 'IF', 'INITIALIZE', 'INITIATE', 'INPUT-OUTPUT', 'INSPECT', 'INVOKE', 'I-O-CONTROL', 'LINKAGE', 'LOCAL-STORAGE', 'MERGE', 'MOVE', 'MULTIPLY', 'OPEN', 'PERFORM', 'PROCEDURE', 'PROGRAM-ID', 'RAISE', 'READ', 'RELEASE', 'RESUME', 'RETURN', 'REWRITE', 'SCREEN', 'SD', 'SEARCH', 'SECTION', 'SET', 'SORT', 'START', 'STOP', 'STRING', 'SUBTRACT', 'SUPPRESS', 'TERMINATE', 'THEN', 'UNLOCK', 'UNSTRING', 'USE', 'VALIDATE', 'WORKING-STORAGE', 'WRITE'), prefix=r'(^|(?<=[^\w\-]))', suffix=r'\s*($|(?=[^\w\-]))'), Keyword.Reserved), # Reserved words (words(( 'ACCESS', 'ADDRESS', 'ADVANCING', 'AFTER', 'ALL', 'ALPHABET', 'ALPHABETIC', 'ALPHABETIC-LOWER', 'ALPHABETIC-UPPER', 'ALPHANUMERIC', 'ALPHANUMERIC-EDITED', 'ALSO', 'ALTER', 'ALTERNATE' 'ANY', 'ARE', 'AREA', 'AREAS', 'ARGUMENT-NUMBER', 'ARGUMENT-VALUE', 'AS', 'ASCENDING', 'ASSIGN', 'AT', 'AUTO', 'AUTO-SKIP', 'AUTOMATIC', 'AUTOTERMINATE', 'BACKGROUND-COLOR', 'BASED', 'BEEP', 'BEFORE', 'BELL', 'BLANK', 'BLINK', 'BLOCK', 'BOTTOM', 'BY', 'BYTE-LENGTH', 'CHAINING', 'CHARACTER', 'CHARACTERS', 'CLASS', 'CODE', 'CODE-SET', 'COL', 'COLLATING', 'COLS', 'COLUMN', 'COLUMNS', 'COMMA', 'COMMAND-LINE', 'COMMIT', 'COMMON', 'CONSTANT', 'CONTAINS', 'CONTENT', 'CONTROL', 'CONTROLS', 'CONVERTING', 'COPY', 'CORR', 'CORRESPONDING', 'COUNT', 'CRT', 'CURRENCY', 'CURSOR', 'CYCLE', 'DATE', 'DAY', 'DAY-OF-WEEK', 'DE', 'DEBUGGING', 'DECIMAL-POINT', 'DECLARATIVES', 'DEFAULT', 'DELIMITED', 'DELIMITER', 'DEPENDING', 'DESCENDING', 'DETAIL', 'DISK', 'DOWN', 'DUPLICATES', 'DYNAMIC', 'EBCDIC', 'ENTRY', 'ENVIRONMENT-NAME', 'ENVIRONMENT-VALUE', 'EOL', 'EOP', 'EOS', 'ERASE', 'ERROR', 'ESCAPE', 'EXCEPTION', 'EXCLUSIVE', 'EXTEND', 'EXTERNAL', 'FILE-ID', 'FILLER', 'FINAL', 'FIRST', 'FIXED', 'FLOAT-LONG', 'FLOAT-SHORT', 'FOOTING', 'FOR', 'FOREGROUND-COLOR', 'FORMAT', 'FROM', 'FULL', 'FUNCTION', 'FUNCTION-ID', 'GIVING', 'GLOBAL', 'GROUP', 'HEADING', 'HIGHLIGHT', 'I-O', 'ID', 'IGNORE', 'IGNORING', 'IN', 'INDEX', 'INDEXED', 'INDICATE', 'INITIAL', 'INITIALIZED', 'INPUT', 'INTO', 'INTRINSIC', 'INVALID', 'IS', 'JUST', 'JUSTIFIED', 'KEY', 'LABEL', 'LAST', 'LEADING', 'LEFT', 'LENGTH', 'LIMIT', 'LIMITS', 'LINAGE', 'LINAGE-COUNTER', 'LINE', 'LINES', 'LOCALE', 'LOCK', 'LOWLIGHT', 'MANUAL', 'MEMORY', 'MINUS', 'MODE', 'MULTIPLE', 'NATIONAL', 'NATIONAL-EDITED', 'NATIVE', 'NEGATIVE', 'NEXT', 'NO', 'NULL', 'NULLS', 'NUMBER', 'NUMBERS', 'NUMERIC', 'NUMERIC-EDITED', 'OBJECT-COMPUTER', 'OCCURS', 'OF', 'OFF', 'OMITTED', 'ON', 'ONLY', 'OPTIONAL', 'ORDER', 'ORGANIZATION', 'OTHER', 'OUTPUT', 'OVERFLOW', 'OVERLINE', 'PACKED-DECIMAL', 'PADDING', 'PAGE', 'PARAGRAPH', 'PLUS', 'POINTER', 'POSITION', 'POSITIVE', 'PRESENT', 'PREVIOUS', 'PRINTER', 'PRINTING', 'PROCEDURE-POINTER', 'PROCEDURES', 'PROCEED', 'PROGRAM', 'PROGRAM-POINTER', 'PROMPT', 'QUOTE', 'QUOTES', 'RANDOM', 'RD', 'RECORD', 'RECORDING', 'RECORDS', 'RECURSIVE', 'REDEFINES', 'REEL', 'REFERENCE', 'RELATIVE', 'REMAINDER', 'REMOVAL', 'RENAMES', 'REPLACING', 'REPORT', 'REPORTING', 'REPORTS', 'REPOSITORY', 'REQUIRED', 'RESERVE', 'RETURNING', 'REVERSE-VIDEO', 'REWIND', 'RIGHT', 'ROLLBACK', 'ROUNDED', 'RUN', 'SAME', 'SCROLL', 'SECURE', 'SEGMENT-LIMIT', 'SELECT', 'SENTENCE', 'SEPARATE', 'SEQUENCE', 'SEQUENTIAL', 'SHARING', 'SIGN', 'SIGNED', 'SIGNED-INT', 'SIGNED-LONG', 'SIGNED-SHORT', 'SIZE', 'SORT-MERGE', 'SOURCE', 'SOURCE-COMPUTER', 'SPECIAL-NAMES', 'STANDARD', 'STANDARD-1', 'STANDARD-2', 'STATUS', 'SUBKEY', 'SUM', 'SYMBOLIC', 'SYNC', 'SYNCHRONIZED', 'TALLYING', 'TAPE', 'TEST', 'THROUGH', 'THRU', 'TIME', 'TIMES', 'TO', 'TOP', 'TRAILING', 'TRANSFORM', 'TYPE', 'UNDERLINE', 'UNIT', 'UNSIGNED', 'UNSIGNED-INT', 'UNSIGNED-LONG', 'UNSIGNED-SHORT', 'UNTIL', 'UP', 'UPDATE', 'UPON', 'USAGE', 'USING', 'VALUE', 'VALUES', 'VARYING', 'WAIT', 'WHEN', 'WITH', 'WORDS', 'YYYYDDD', 'YYYYMMDD'), prefix=r'(^|(?<=[^\w\-]))', suffix=r'\s*($|(?=[^\w\-]))'), Keyword.Pseudo), # inactive reserved words (words(( 'ACTIVE-CLASS', 'ALIGNED', 'ANYCASE', 'ARITHMETIC', 'ATTRIBUTE', 'B-AND', 'B-NOT', 'B-OR', 'B-XOR', 'BIT', 'BOOLEAN', 'CD', 'CENTER', 'CF', 'CH', 'CHAIN', 'CLASS-ID', 'CLASSIFICATION', 'COMMUNICATION', 'CONDITION', 'DATA-POINTER', 'DESTINATION', 'DISABLE', 'EC', 'EGI', 'EMI', 'ENABLE', 'END-RECEIVE', 'ENTRY-CONVENTION', 'EO', 'ESI', 'EXCEPTION-OBJECT', 'EXPANDS', 'FACTORY', 'FLOAT-BINARY-16', 'FLOAT-BINARY-34', 'FLOAT-BINARY-7', 'FLOAT-DECIMAL-16', 'FLOAT-DECIMAL-34', 'FLOAT-EXTENDED', 'FORMAT', 'FUNCTION-POINTER', 'GET', 'GROUP-USAGE', 'IMPLEMENTS', 'INFINITY', 'INHERITS', 'INTERFACE', 'INTERFACE-ID', 'INVOKE', 'LC_ALL', 'LC_COLLATE', 'LC_CTYPE', 'LC_MESSAGES', 'LC_MONETARY', 'LC_NUMERIC', 'LC_TIME', 'LINE-COUNTER', 'MESSAGE', 'METHOD', 'METHOD-ID', 'NESTED', 'NONE', 'NORMAL', 'OBJECT', 'OBJECT-REFERENCE', 'OPTIONS', 'OVERRIDE', 'PAGE-COUNTER', 'PF', 'PH', 'PROPERTY', 'PROTOTYPE', 'PURGE', 'QUEUE', 'RAISE', 'RAISING', 'RECEIVE', 'RELATION', 'REPLACE', 'REPRESENTS-NOT-A-NUMBER', 'RESET', 'RESUME', 'RETRY', 'RF', 'RH', 'SECONDS', 'SEGMENT', 'SELF', 'SEND', 'SOURCES', 'STATEMENT', 'STEP', 'STRONG', 'SUB-QUEUE-1', 'SUB-QUEUE-2', 'SUB-QUEUE-3', 'SUPER', 'SYMBOL', 'SYSTEM-DEFAULT', 'TABLE', 'TERMINAL', 'TEXT', 'TYPEDEF', 'UCS-4', 'UNIVERSAL', 'USER-DEFAULT', 'UTF-16', 'UTF-8', 'VAL-STATUS', 'VALID', 'VALIDATE', 'VALIDATE-STATUS'), prefix=r'(^|(?<=[^\w\-]))', suffix=r'\s*($|(?=[^\w\-]))'), Error), # Data Types (r'(^|(?<=[^\w\-]))' r'(PIC\s+.+?(?=(\s|\.\s))|PICTURE\s+.+?(?=(\s|\.\s))|' r'(COMPUTATIONAL)(-[1-5X])?|(COMP)(-[1-5X])?|' r'BINARY-C-LONG|' r'BINARY-CHAR|BINARY-DOUBLE|BINARY-LONG|BINARY-SHORT|' r'BINARY)\s*($|(?=[^\w\-]))', Keyword.Type), # Operators (r'(\*\*|\*|\+|-|/|<=|>=|<|>|==|/=|=)', Operator), # (r'(::)', Keyword.Declaration), (r'([(),;:&%.])', Punctuation), # Intrinsics (r'(^|(?<=[^\w\-]))(ABS|ACOS|ANNUITY|ASIN|ATAN|BYTE-LENGTH|' r'CHAR|COMBINED-DATETIME|CONCATENATE|COS|CURRENT-DATE|' r'DATE-OF-INTEGER|DATE-TO-YYYYMMDD|DAY-OF-INTEGER|DAY-TO-YYYYDDD|' r'EXCEPTION-(?:FILE|LOCATION|STATEMENT|STATUS)|EXP10|EXP|E|' r'FACTORIAL|FRACTION-PART|INTEGER-OF-(?:DATE|DAY|PART)|INTEGER|' r'LENGTH|LOCALE-(?:DATE|TIME(?:-FROM-SECONDS)?)|LOG(?:10)?|' r'LOWER-CASE|MAX|MEAN|MEDIAN|MIDRANGE|MIN|MOD|NUMVAL(?:-C)?|' r'ORD(?:-MAX|-MIN)?|PI|PRESENT-VALUE|RANDOM|RANGE|REM|REVERSE|' r'SECONDS-FROM-FORMATTED-TIME|SECONDS-PAST-MIDNIGHT|SIGN|SIN|SQRT|' r'STANDARD-DEVIATION|STORED-CHAR-LENGTH|SUBSTITUTE(?:-CASE)?|' r'SUM|TAN|TEST-DATE-YYYYMMDD|TEST-DAY-YYYYDDD|TRIM|' r'UPPER-CASE|VARIANCE|WHEN-COMPILED|YEAR-TO-YYYY)\s*' r'($|(?=[^\w\-]))', Name.Function), # Booleans (r'(^|(?<=[^\w\-]))(true|false)\s*($|(?=[^\w\-]))', Name.Builtin), # Comparing Operators (r'(^|(?<=[^\w\-]))(equal|equals|ne|lt|le|gt|ge|' r'greater|less|than|not|and|or)\s*($|(?=[^\w\-]))', Operator.Word), ], # \"[^\"\n]*\"|\'[^\'\n]*\' 'strings': [ # apparently strings can be delimited by EOL if they are continued # in the next line (r'"[^"\n]*("|\n)', String.Double), (r"'[^'\n]*('|\n)", String.Single), ], 'nums': [ (r'\d+(\s*|\.$|$)', Number.Integer), (r'[+-]?\d*\.\d+(E[-+]?\d+)?', Number.Float), (r'[+-]?\d+\.\d*(E[-+]?\d+)?', Number.Float), ], } class CobolFreeformatLexer(CobolLexer): """ Lexer for Free format OpenCOBOL code. .. versionadded:: 1.6 """ name = 'COBOLFree' aliases = ['cobolfree'] filenames = ['*.cbl', '*.CBL'] mimetypes = [] flags = re.IGNORECASE | re.MULTILINE tokens = { 'comment': [ (r'(\*>.*\n|^\w*\*.*$)', Comment), ], } class ABAPLexer(RegexLexer): """ Lexer for ABAP, SAP's integrated language. .. versionadded:: 1.1 """ name = 'ABAP' aliases = ['abap'] filenames = ['*.abap', '*.ABAP'] mimetypes = ['text/x-abap'] flags = re.IGNORECASE | re.MULTILINE tokens = { 'common': [ (r'\s+', Whitespace), (r'^\*.*$', Comment.Single), (r'\".*?\n', Comment.Single), (r'##\w+', Comment.Special), ], 'variable-names': [ (r'<\S+>', Name.Variable), (r'\w[\w~]*(?:(\[\])|->\*)?', Name.Variable), ], 'root': [ include('common'), # function calls (r'CALL\s+(?:BADI|CUSTOMER-FUNCTION|FUNCTION)', Keyword), (r'(CALL\s+(?:DIALOG|SCREEN|SUBSCREEN|SELECTION-SCREEN|' r'TRANSACTION|TRANSFORMATION))\b', Keyword), (r'(FORM|PERFORM)(\s+)(\w+)', bygroups(Keyword, Whitespace, Name.Function)), (r'(PERFORM)(\s+)(\()(\w+)(\))', bygroups(Keyword, Whitespace, Punctuation, Name.Variable, Punctuation)), (r'(MODULE)(\s+)(\S+)(\s+)(INPUT|OUTPUT)', bygroups(Keyword, Whitespace, Name.Function, Whitespace, Keyword)), # method implementation (r'(METHOD)(\s+)([\w~]+)', bygroups(Keyword, Whitespace, Name.Function)), # method calls (r'(\s+)([\w\-]+)([=\-]>)([\w\-~]+)', bygroups(Whitespace, Name.Variable, Operator, Name.Function)), # call methodnames returning style (r'(?<=(=|-)>)([\w\-~]+)(?=\()', Name.Function), # text elements (r'(TEXT)(-)(\d{3})', bygroups(Keyword, Punctuation, Number.Integer)), (r'(TEXT)(-)(\w{3})', bygroups(Keyword, Punctuation, Name.Variable)), # keywords with dashes in them. # these need to be first, because for instance the -ID part # of MESSAGE-ID wouldn't get highlighted if MESSAGE was # first in the list of keywords. (r'(ADD-CORRESPONDING|AUTHORITY-CHECK|' r'CLASS-DATA|CLASS-EVENTS|CLASS-METHODS|CLASS-POOL|' r'DELETE-ADJACENT|DIVIDE-CORRESPONDING|' r'EDITOR-CALL|ENHANCEMENT-POINT|ENHANCEMENT-SECTION|EXIT-COMMAND|' r'FIELD-GROUPS|FIELD-SYMBOLS|FIELD-SYMBOL|FUNCTION-POOL|' r'INTERFACE-POOL|INVERTED-DATE|' r'LOAD-OF-PROGRAM|LOG-POINT|' r'MESSAGE-ID|MOVE-CORRESPONDING|MULTIPLY-CORRESPONDING|' r'NEW-LINE|NEW-PAGE|NEW-SECTION|NO-EXTENSION|' r'OUTPUT-LENGTH|PRINT-CONTROL|' r'SELECT-OPTIONS|START-OF-SELECTION|SUBTRACT-CORRESPONDING|' r'SYNTAX-CHECK|SYSTEM-EXCEPTIONS|' r'TYPE-POOL|TYPE-POOLS|NO-DISPLAY' r')\b', Keyword), # keyword kombinations (r'(?<![-\>])(CREATE\s+(PUBLIC|PRIVATE|DATA|OBJECT)|' r'(PUBLIC|PRIVATE|PROTECTED)\s+SECTION|' r'(TYPE|LIKE)\s+((LINE\s+OF|REF\s+TO|' r'(SORTED|STANDARD|HASHED)\s+TABLE\s+OF))?|' r'FROM\s+(DATABASE|MEMORY)|CALL\s+METHOD|' r'(GROUP|ORDER) BY|HAVING|SEPARATED BY|' r'GET\s+(BADI|BIT|CURSOR|DATASET|LOCALE|PARAMETER|' r'PF-STATUS|(PROPERTY|REFERENCE)\s+OF|' r'RUN\s+TIME|TIME\s+(STAMP)?)?|' r'SET\s+(BIT|BLANK\s+LINES|COUNTRY|CURSOR|DATASET|EXTENDED\s+CHECK|' r'HANDLER|HOLD\s+DATA|LANGUAGE|LEFT\s+SCROLL-BOUNDARY|' r'LOCALE|MARGIN|PARAMETER|PF-STATUS|PROPERTY\s+OF|' r'RUN\s+TIME\s+(ANALYZER|CLOCK\s+RESOLUTION)|SCREEN|' r'TITLEBAR|UPADTE\s+TASK\s+LOCAL|USER-COMMAND)|' r'CONVERT\s+((INVERTED-)?DATE|TIME|TIME\s+STAMP|TEXT)|' r'(CLOSE|OPEN)\s+(DATASET|CURSOR)|' r'(TO|FROM)\s+(DATA BUFFER|INTERNAL TABLE|MEMORY ID|' r'DATABASE|SHARED\s+(MEMORY|BUFFER))|' r'DESCRIBE\s+(DISTANCE\s+BETWEEN|FIELD|LIST|TABLE)|' r'FREE\s(MEMORY|OBJECT)?|' r'PROCESS\s+(BEFORE\s+OUTPUT|AFTER\s+INPUT|' r'ON\s+(VALUE-REQUEST|HELP-REQUEST))|' r'AT\s+(LINE-SELECTION|USER-COMMAND|END\s+OF|NEW)|' r'AT\s+SELECTION-SCREEN(\s+(ON(\s+(BLOCK|(HELP|VALUE)-REQUEST\s+FOR|' r'END\s+OF|RADIOBUTTON\s+GROUP))?|OUTPUT))?|' r'SELECTION-SCREEN:?\s+((BEGIN|END)\s+OF\s+((TABBED\s+)?BLOCK|LINE|' r'SCREEN)|COMMENT|FUNCTION\s+KEY|' r'INCLUDE\s+BLOCKS|POSITION|PUSHBUTTON|' r'SKIP|ULINE)|' r'LEAVE\s+(LIST-PROCESSING|PROGRAM|SCREEN|' r'TO LIST-PROCESSING|TO TRANSACTION)' r'(ENDING|STARTING)\s+AT|' r'FORMAT\s+(COLOR|INTENSIFIED|INVERSE|HOTSPOT|INPUT|FRAMES|RESET)|' r'AS\s+(CHECKBOX|SUBSCREEN|WINDOW)|' r'WITH\s+(((NON-)?UNIQUE)?\s+KEY|FRAME)|' r'(BEGIN|END)\s+OF|' r'DELETE(\s+ADJACENT\s+DUPLICATES\sFROM)?|' r'COMPARING(\s+ALL\s+FIELDS)?|' r'(INSERT|APPEND)(\s+INITIAL\s+LINE\s+(IN)?TO|\s+LINES\s+OF)?|' r'IN\s+((BYTE|CHARACTER)\s+MODE|PROGRAM)|' r'END-OF-(DEFINITION|PAGE|SELECTION)|' r'WITH\s+FRAME(\s+TITLE)|' r'(REPLACE|FIND)\s+((FIRST|ALL)\s+OCCURRENCES?\s+OF\s+)?(SUBSTRING|REGEX)?|' r'MATCH\s+(LENGTH|COUNT|LINE|OFFSET)|' r'(RESPECTING|IGNORING)\s+CASE|' r'IN\s+UPDATE\s+TASK|' r'(SOURCE|RESULT)\s+(XML)?|' r'REFERENCE\s+INTO|' # simple kombinations r'AND\s+(MARK|RETURN)|CLIENT\s+SPECIFIED|CORRESPONDING\s+FIELDS\s+OF|' r'IF\s+FOUND|FOR\s+EVENT|INHERITING\s+FROM|LEAVE\s+TO\s+SCREEN|' r'LOOP\s+AT\s+(SCREEN)?|LOWER\s+CASE|MATCHCODE\s+OBJECT|MODIF\s+ID|' r'MODIFY\s+SCREEN|NESTING\s+LEVEL|NO\s+INTERVALS|OF\s+STRUCTURE|' r'RADIOBUTTON\s+GROUP|RANGE\s+OF|REF\s+TO|SUPPRESS DIALOG|' r'TABLE\s+OF|UPPER\s+CASE|TRANSPORTING\s+NO\s+FIELDS|' r'VALUE\s+CHECK|VISIBLE\s+LENGTH|HEADER\s+LINE|COMMON\s+PART)\b', Keyword), # single word keywords. (r'(^|(?<=(\s|\.)))(ABBREVIATED|ABSTRACT|ADD|ALIASES|ALIGN|ALPHA|' r'ASSERT|AS|ASSIGN(ING)?|AT(\s+FIRST)?|' r'BACK|BLOCK|BREAK-POINT|' r'CASE|CAST|CATCH|CHANGING|CHECK|CLASS|CLEAR|COLLECT|COLOR|COMMIT|COND|CONV|' r'CREATE|COMMUNICATION|COMPONENTS?|COMPUTE|CONCATENATE|CONDENSE|' r'CONSTANTS|CONTEXTS|CONTINUE|CONTROLS|COUNTRY|CURRENCY|' r'DATA|DATE|DECIMALS|DEFAULT|DEFINE|DEFINITION|DEFERRED|DEMAND|' r'DETAIL|DIRECTORY|DIVIDE|DO|DUMMY|' r'ELSE(IF)?|ENDAT|ENDCASE|ENDCATCH|ENDCLASS|ENDDO|ENDFORM|ENDFUNCTION|' r'ENDIF|ENDINTERFACE|ENDLOOP|ENDMETHOD|ENDMODULE|ENDSELECT|ENDTRY|ENDWHILE|' r'ENHANCEMENT|EVENTS|EXACT|EXCEPTIONS?|EXIT|EXPONENT|EXPORT|EXPORTING|EXTRACT|' r'FETCH|FIELDS?|FOR|FORM|FORMAT|FREE|FROM|FUNCTION|' r'HIDE|' r'ID|IF|IMPORT|IMPLEMENTATION|IMPORTING|IN|INCLUDE|INCLUDING|' r'INDEX|INFOTYPES|INITIALIZATION|INTERFACE|INTERFACES|INTO|' r'LANGUAGE|LEAVE|LENGTH|LINES|LOAD|LOCAL|' r'JOIN|' r'KEY|' r'NEW|NEXT|' r'MAXIMUM|MESSAGE|METHOD[S]?|MINIMUM|MODULE|MODIFIER|MODIFY|MOVE|MULTIPLY|' r'NODES|NUMBER|' r'OBLIGATORY|OBJECT|OF|OFF|ON|OTHERS|OVERLAY|' r'PACK|PAD|PARAMETERS|PERCENTAGE|POSITION|PROGRAM|PROVIDE|PUBLIC|PUT|PF\d\d|' r'RAISE|RAISING|RANGES?|READ|RECEIVE|REDEFINITION|REFRESH|REJECT|REPORT|RESERVE|' r'REF|RESUME|RETRY|RETURN|RETURNING|RIGHT|ROLLBACK|REPLACE|' r'SCROLL|SEARCH|SELECT|SHIFT|SIGN|SINGLE|SIZE|SKIP|SORT|SPLIT|STATICS|STOP|' r'STYLE|SUBMATCHES|SUBMIT|SUBTRACT|SUM(?!\()|SUMMARY|SUMMING|SUPPLY|SWITCH|' r'TABLE|TABLES|TIMESTAMP|TIMES?|TIMEZONE|TITLE|\??TO|' r'TOP-OF-PAGE|TRANSFER|TRANSLATE|TRY|TYPES|' r'ULINE|UNDER|UNPACK|UPDATE|USING|' r'VALUE|VALUES|VIA|VARYING|VARY|' r'WAIT|WHEN|WHERE|WIDTH|WHILE|WITH|WINDOW|WRITE|XSD|ZERO)\b', Keyword), # builtins (r'(abs|acos|asin|atan|' r'boolc|boolx|bit_set|' r'char_off|charlen|ceil|cmax|cmin|condense|contains|' r'contains_any_of|contains_any_not_of|concat_lines_of|cos|cosh|' r'count|count_any_of|count_any_not_of|' r'dbmaxlen|distance|' r'escape|exp|' r'find|find_end|find_any_of|find_any_not_of|floor|frac|from_mixed|' r'insert|' r'lines|log|log10|' r'match|matches|' r'nmax|nmin|numofchar|' r'repeat|replace|rescale|reverse|round|' r'segment|shift_left|shift_right|sign|sin|sinh|sqrt|strlen|' r'substring|substring_after|substring_from|substring_before|substring_to|' r'tan|tanh|to_upper|to_lower|to_mixed|translate|trunc|' r'xstrlen)(\()\b', bygroups(Name.Builtin, Punctuation)), (r'&[0-9]', Name), (r'[0-9]+', Number.Integer), # operators which look like variable names before # parsing variable names. (r'(?<=(\s|.))(AND|OR|EQ|NE|GT|LT|GE|LE|CO|CN|CA|NA|CS|NOT|NS|CP|NP|' r'BYTE-CO|BYTE-CN|BYTE-CA|BYTE-NA|BYTE-CS|BYTE-NS|' r'IS\s+(NOT\s+)?(INITIAL|ASSIGNED|REQUESTED|BOUND))\b', Operator.Word), include('variable-names'), # standard operators after variable names, # because < and > are part of field symbols. (r'[?*<>=\-+&]', Operator), (r"'(''|[^'])*'", String.Single), (r"`([^`])*`", String.Single), (r"([|}])([^{}|]*?)([|{])", bygroups(Punctuation, String.Single, Punctuation)), (r'[/;:()\[\],.]', Punctuation), (r'(!)(\w+)', bygroups(Operator, Name)), ], } class OpenEdgeLexer(RegexLexer): """ Lexer for `OpenEdge ABL (formerly Progress) <http://web.progress.com/en/openedge/abl.html>`_ source code. .. versionadded:: 1.5 """ name = 'OpenEdge ABL' aliases = ['openedge', 'abl', 'progress'] filenames = ['*.p', '*.cls'] mimetypes = ['text/x-openedge', 'application/x-openedge'] types = (r'(?i)(^|(?<=[^\w\-]))(CHARACTER|CHAR|CHARA|CHARAC|CHARACT|CHARACTE|' r'COM-HANDLE|DATE|DATETIME|DATETIME-TZ|' r'DECIMAL|DEC|DECI|DECIM|DECIMA|HANDLE|' r'INT64|INTEGER|INT|INTE|INTEG|INTEGE|' r'LOGICAL|LONGCHAR|MEMPTR|RAW|RECID|ROWID)\s*($|(?=[^\w\-]))') keywords = words(OPENEDGEKEYWORDS, prefix=r'(?i)(^|(?<=[^\w\-]))', suffix=r'\s*($|(?=[^\w\-]))') tokens = { 'root': [ (r'/\*', Comment.Multiline, 'comment'), (r'\{', Comment.Preproc, 'preprocessor'), (r'\s*&.*', Comment.Preproc), (r'0[xX][0-9a-fA-F]+[LlUu]*', Number.Hex), (r'(?i)(DEFINE|DEF|DEFI|DEFIN)\b', Keyword.Declaration), (types, Keyword.Type), (keywords, Name.Builtin), (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'[0-9][0-9]*\.[0-9]+([eE][0-9]+)?[fd]?', Number.Float), (r'[0-9]+', Number.Integer), (r'\s+', Whitespace), (r'[+*/=-]', Operator), (r'[.:()]', Punctuation), (r'.', Name.Variable), # Lazy catch-all ], 'comment': [ (r'[^*/]', Comment.Multiline), (r'/\*', Comment.Multiline, '#push'), (r'\*/', Comment.Multiline, '#pop'), (r'[*/]', Comment.Multiline) ], 'preprocessor': [ (r'[^{}]', Comment.Preproc), (r'\{', Comment.Preproc, '#push'), (r'\}', Comment.Preproc, '#pop'), ], } def analyse_text(text): """Try to identify OpenEdge ABL based on a few common constructs.""" result = 0 if 'END.' in text: result += 0.05 if 'END PROCEDURE.' in text: result += 0.05 if 'ELSE DO:' in text: result += 0.05 return result class GoodDataCLLexer(RegexLexer): """ Lexer for `GoodData-CL <https://github.com/gooddata/GoodData-CL/raw/master/cli/src/main/resources/\ com/gooddata/processor/COMMANDS.txt>`_ script files. .. versionadded:: 1.4 """ name = 'GoodData-CL' aliases = ['gooddata-cl'] filenames = ['*.gdc'] mimetypes = ['text/x-gooddata-cl'] flags = re.IGNORECASE tokens = { 'root': [ # Comments (r'#.*', Comment.Single), # Function call (r'[a-z]\w*', Name.Function), # Argument list (r'\(', Punctuation, 'args-list'), # Punctuation (r';', Punctuation), # Space is not significant (r'\s+', Text) ], 'args-list': [ (r'\)', Punctuation, '#pop'), (r',', Punctuation), (r'[a-z]\w*', Name.Variable), (r'=', Operator), (r'"', String, 'string-literal'), (r'[0-9]+(?:\.[0-9]+)?(?:e[+-]?[0-9]{1,3})?', Number), # Space is not significant (r'\s', Whitespace) ], 'string-literal': [ (r'\\[tnrfbae"\\]', String.Escape), (r'"', String, '#pop'), (r'[^\\"]+', String) ] } class MaqlLexer(RegexLexer): """ Lexer for `GoodData MAQL <https://secure.gooddata.com/docs/html/advanced.metric.tutorial.html>`_ scripts. .. versionadded:: 1.4 """ name = 'MAQL' aliases = ['maql'] filenames = ['*.maql'] mimetypes = ['text/x-gooddata-maql', 'application/x-gooddata-maql'] flags = re.IGNORECASE tokens = { 'root': [ # IDENTITY (r'IDENTIFIER\b', Name.Builtin), # IDENTIFIER (r'\{[^}]+\}', Name.Variable), # NUMBER (r'[0-9]+(?:\.[0-9]+)?(?:e[+-]?[0-9]{1,3})?', Number), # STRING (r'"', String, 'string-literal'), # RELATION (r'\<\>|\!\=', Operator), (r'\=|\>\=|\>|\<\=|\<', Operator), # := (r'\:\=', Operator), # OBJECT (r'\[[^]]+\]', Name.Variable.Class), # keywords (words(( 'DIMENSION', 'DIMENSIONS', 'BOTTOM', 'METRIC', 'COUNT', 'OTHER', 'FACT', 'WITH', 'TOP', 'OR', 'ATTRIBUTE', 'CREATE', 'PARENT', 'FALSE', 'ROW', 'ROWS', 'FROM', 'ALL', 'AS', 'PF', 'COLUMN', 'COLUMNS', 'DEFINE', 'REPORT', 'LIMIT', 'TABLE', 'LIKE', 'AND', 'BY', 'BETWEEN', 'EXCEPT', 'SELECT', 'MATCH', 'WHERE', 'TRUE', 'FOR', 'IN', 'WITHOUT', 'FILTER', 'ALIAS', 'WHEN', 'NOT', 'ON', 'KEYS', 'KEY', 'FULLSET', 'PRIMARY', 'LABELS', 'LABEL', 'VISUAL', 'TITLE', 'DESCRIPTION', 'FOLDER', 'ALTER', 'DROP', 'ADD', 'DATASET', 'DATATYPE', 'INT', 'BIGINT', 'DOUBLE', 'DATE', 'VARCHAR', 'DECIMAL', 'SYNCHRONIZE', 'TYPE', 'DEFAULT', 'ORDER', 'ASC', 'DESC', 'HYPERLINK', 'INCLUDE', 'TEMPLATE', 'MODIFY'), suffix=r'\b'), Keyword), # FUNCNAME (r'[a-z]\w*\b', Name.Function), # Comments (r'#.*', Comment.Single), # Punctuation (r'[,;()]', Punctuation), # Space is not significant (r'\s+', Whitespace) ], 'string-literal': [ (r'\\[tnrfbae"\\]', String.Escape), (r'"', String, '#pop'), (r'[^\\"]+', String) ], }
28,112
Python
43.837321
94
0.498755
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/ncl.py
""" pygments.lexers.ncl ~~~~~~~~~~~~~~~~~~~ Lexers for NCAR Command Language. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, include, words from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation __all__ = ['NCLLexer'] class NCLLexer(RegexLexer): """ Lexer for NCL code. .. versionadded:: 2.2 """ name = 'NCL' aliases = ['ncl'] filenames = ['*.ncl'] mimetypes = ['text/ncl'] flags = re.MULTILINE tokens = { 'root': [ (r';.*\n', Comment), include('strings'), include('core'), (r'[a-zA-Z_]\w*', Name), include('nums'), (r'[\s]+', Text), ], 'core': [ # Statements (words(( 'begin', 'break', 'continue', 'create', 'defaultapp', 'do', 'else', 'end', 'external', 'exit', 'True', 'False', 'file', 'function', 'getvalues', 'graphic', 'group', 'if', 'list', 'load', 'local', 'new', '_Missing', 'Missing', 'noparent', 'procedure', 'quit', 'QUIT', 'Quit', 'record', 'return', 'setvalues', 'stop', 'then', 'while'), prefix=r'\b', suffix=r'\s*\b'), Keyword), # Data Types (words(( 'ubyte', 'uint', 'uint64', 'ulong', 'string', 'byte', 'character', 'double', 'float', 'integer', 'int64', 'logical', 'long', 'short', 'ushort', 'enumeric', 'numeric', 'snumeric'), prefix=r'\b', suffix=r'\s*\b'), Keyword.Type), # Operators (r'[\%^*+\-/<>]', Operator), # punctuation: (r'[\[\]():@$!&|.,\\{}]', Punctuation), (r'[=:]', Punctuation), # Intrinsics (words(( 'abs', 'acos', 'addfile', 'addfiles', 'all', 'angmom_atm', 'any', 'area_conserve_remap', 'area_hi2lores', 'area_poly_sphere', 'asciiread', 'asciiwrite', 'asin', 'atan', 'atan2', 'attsetvalues', 'avg', 'betainc', 'bin_avg', 'bin_sum', 'bw_bandpass_filter', 'cancor', 'cbinread', 'cbinwrite', 'cd_calendar', 'cd_inv_calendar', 'cdfbin_p', 'cdfbin_pr', 'cdfbin_s', 'cdfbin_xn', 'cdfchi_p', 'cdfchi_x', 'cdfgam_p', 'cdfgam_x', 'cdfnor_p', 'cdfnor_x', 'cdft_p', 'cdft_t', 'ceil', 'center_finite_diff', 'center_finite_diff_n', 'cfftb', 'cfftf', 'cfftf_frq_reorder', 'charactertodouble', 'charactertofloat', 'charactertointeger', 'charactertolong', 'charactertoshort', 'charactertostring', 'chartodouble', 'chartofloat', 'chartoint', 'chartointeger', 'chartolong', 'chartoshort', 'chartostring', 'chiinv', 'clear', 'color_index_to_rgba', 'conform', 'conform_dims', 'cos', 'cosh', 'count_unique_values', 'covcorm', 'covcorm_xy', 'craybinnumrec', 'craybinrecread', 'create_graphic', 'csa1', 'csa1d', 'csa1s', 'csa1x', 'csa1xd', 'csa1xs', 'csa2', 'csa2d', 'csa2l', 'csa2ld', 'csa2ls', 'csa2lx', 'csa2lxd', 'csa2lxs', 'csa2s', 'csa2x', 'csa2xd', 'csa2xs', 'csa3', 'csa3d', 'csa3l', 'csa3ld', 'csa3ls', 'csa3lx', 'csa3lxd', 'csa3lxs', 'csa3s', 'csa3x', 'csa3xd', 'csa3xs', 'csc2s', 'csgetp', 'css2c', 'cssetp', 'cssgrid', 'csstri', 'csvoro', 'cumsum', 'cz2ccm', 'datatondc', 'day_of_week', 'day_of_year', 'days_in_month', 'default_fillvalue', 'delete', 'depth_to_pres', 'destroy', 'determinant', 'dewtemp_trh', 'dgeevx_lapack', 'dim_acumrun_n', 'dim_avg', 'dim_avg_n', 'dim_avg_wgt', 'dim_avg_wgt_n', 'dim_cumsum', 'dim_cumsum_n', 'dim_gamfit_n', 'dim_gbits', 'dim_max', 'dim_max_n', 'dim_median', 'dim_median_n', 'dim_min', 'dim_min_n', 'dim_num', 'dim_num_n', 'dim_numrun_n', 'dim_pqsort', 'dim_pqsort_n', 'dim_product', 'dim_product_n', 'dim_rmsd', 'dim_rmsd_n', 'dim_rmvmean', 'dim_rmvmean_n', 'dim_rmvmed', 'dim_rmvmed_n', 'dim_spi_n', 'dim_standardize', 'dim_standardize_n', 'dim_stat4', 'dim_stat4_n', 'dim_stddev', 'dim_stddev_n', 'dim_sum', 'dim_sum_n', 'dim_sum_wgt', 'dim_sum_wgt_n', 'dim_variance', 'dim_variance_n', 'dimsizes', 'doubletobyte', 'doubletochar', 'doubletocharacter', 'doubletofloat', 'doubletoint', 'doubletointeger', 'doubletolong', 'doubletoshort', 'dpres_hybrid_ccm', 'dpres_plevel', 'draw', 'draw_color_palette', 'dsgetp', 'dsgrid2', 'dsgrid2d', 'dsgrid2s', 'dsgrid3', 'dsgrid3d', 'dsgrid3s', 'dspnt2', 'dspnt2d', 'dspnt2s', 'dspnt3', 'dspnt3d', 'dspnt3s', 'dssetp', 'dtrend', 'dtrend_msg', 'dtrend_msg_n', 'dtrend_n', 'dtrend_quadratic', 'dtrend_quadratic_msg_n', 'dv2uvf', 'dv2uvg', 'dz_height', 'echo_off', 'echo_on', 'eof2data', 'eof_varimax', 'eofcor', 'eofcor_pcmsg', 'eofcor_ts', 'eofcov', 'eofcov_pcmsg', 'eofcov_ts', 'eofunc', 'eofunc_ts', 'eofunc_varimax', 'equiv_sample_size', 'erf', 'erfc', 'esacr', 'esacv', 'esccr', 'esccv', 'escorc', 'escorc_n', 'escovc', 'exit', 'exp', 'exp_tapersh', 'exp_tapersh_wgts', 'exp_tapershC', 'ezfftb', 'ezfftb_n', 'ezfftf', 'ezfftf_n', 'f2fosh', 'f2foshv', 'f2fsh', 'f2fshv', 'f2gsh', 'f2gshv', 'fabs', 'fbindirread', 'fbindirwrite', 'fbinnumrec', 'fbinread', 'fbinrecread', 'fbinrecwrite', 'fbinwrite', 'fft2db', 'fft2df', 'fftshift', 'fileattdef', 'filechunkdimdef', 'filedimdef', 'fileexists', 'filegrpdef', 'filevarattdef', 'filevarchunkdef', 'filevarcompressleveldef', 'filevardef', 'filevardimsizes', 'filwgts_lancos', 'filwgts_lanczos', 'filwgts_normal', 'floattobyte', 'floattochar', 'floattocharacter', 'floattoint', 'floattointeger', 'floattolong', 'floattoshort', 'floor', 'fluxEddy', 'fo2fsh', 'fo2fshv', 'fourier_info', 'frame', 'fspan', 'ftcurv', 'ftcurvd', 'ftcurvi', 'ftcurvp', 'ftcurvpi', 'ftcurvps', 'ftcurvs', 'ftest', 'ftgetp', 'ftkurv', 'ftkurvd', 'ftkurvp', 'ftkurvpd', 'ftsetp', 'ftsurf', 'g2fsh', 'g2fshv', 'g2gsh', 'g2gshv', 'gamma', 'gammainc', 'gaus', 'gaus_lobat', 'gaus_lobat_wgt', 'gc_aangle', 'gc_clkwise', 'gc_dangle', 'gc_inout', 'gc_latlon', 'gc_onarc', 'gc_pnt2gc', 'gc_qarea', 'gc_tarea', 'generate_2d_array', 'get_color_index', 'get_color_rgba', 'get_cpu_time', 'get_isolines', 'get_ncl_version', 'get_script_name', 'get_script_prefix_name', 'get_sphere_radius', 'get_unique_values', 'getbitsone', 'getenv', 'getfiledimsizes', 'getfilegrpnames', 'getfilepath', 'getfilevaratts', 'getfilevarchunkdimsizes', 'getfilevardims', 'getfilevardimsizes', 'getfilevarnames', 'getfilevartypes', 'getvaratts', 'getvardims', 'gradsf', 'gradsg', 'greg2jul', 'grid2triple', 'hlsrgb', 'hsvrgb', 'hydro', 'hyi2hyo', 'idsfft', 'igradsf', 'igradsg', 'ilapsf', 'ilapsg', 'ilapvf', 'ilapvg', 'ind', 'ind_resolve', 'int2p', 'int2p_n', 'integertobyte', 'integertochar', 'integertocharacter', 'integertoshort', 'inttobyte', 'inttochar', 'inttoshort', 'inverse_matrix', 'isatt', 'isbigendian', 'isbyte', 'ischar', 'iscoord', 'isdefined', 'isdim', 'isdimnamed', 'isdouble', 'isenumeric', 'isfile', 'isfilepresent', 'isfilevar', 'isfilevaratt', 'isfilevarcoord', 'isfilevardim', 'isfloat', 'isfunc', 'isgraphic', 'isint', 'isint64', 'isinteger', 'isleapyear', 'islogical', 'islong', 'ismissing', 'isnan_ieee', 'isnumeric', 'ispan', 'isproc', 'isshort', 'issnumeric', 'isstring', 'isubyte', 'isuint', 'isuint64', 'isulong', 'isunlimited', 'isunsigned', 'isushort', 'isvar', 'jul2greg', 'kmeans_as136', 'kolsm2_n', 'kron_product', 'lapsf', 'lapsg', 'lapvf', 'lapvg', 'latlon2utm', 'lclvl', 'lderuvf', 'lderuvg', 'linint1', 'linint1_n', 'linint2', 'linint2_points', 'linmsg', 'linmsg_n', 'linrood_latwgt', 'linrood_wgt', 'list_files', 'list_filevars', 'list_hlus', 'list_procfuncs', 'list_vars', 'ListAppend', 'ListCount', 'ListGetType', 'ListIndex', 'ListIndexFromName', 'ListPop', 'ListPush', 'ListSetType', 'loadscript', 'local_max', 'local_min', 'log', 'log10', 'longtobyte', 'longtochar', 'longtocharacter', 'longtoint', 'longtointeger', 'longtoshort', 'lspoly', 'lspoly_n', 'mask', 'max', 'maxind', 'min', 'minind', 'mixed_layer_depth', 'mixhum_ptd', 'mixhum_ptrh', 'mjo_cross_coh2pha', 'mjo_cross_segment', 'moc_globe_atl', 'monthday', 'natgrid', 'natgridd', 'natgrids', 'ncargpath', 'ncargversion', 'ndctodata', 'ndtooned', 'new', 'NewList', 'ngezlogo', 'nggcog', 'nggetp', 'nglogo', 'ngsetp', 'NhlAddAnnotation', 'NhlAddData', 'NhlAddOverlay', 'NhlAddPrimitive', 'NhlAppGetDefaultParentId', 'NhlChangeWorkstation', 'NhlClassName', 'NhlClearWorkstation', 'NhlDataPolygon', 'NhlDataPolyline', 'NhlDataPolymarker', 'NhlDataToNDC', 'NhlDestroy', 'NhlDraw', 'NhlFrame', 'NhlFreeColor', 'NhlGetBB', 'NhlGetClassResources', 'NhlGetErrorObjectId', 'NhlGetNamedColorIndex', 'NhlGetParentId', 'NhlGetParentWorkstation', 'NhlGetWorkspaceObjectId', 'NhlIsAllocatedColor', 'NhlIsApp', 'NhlIsDataComm', 'NhlIsDataItem', 'NhlIsDataSpec', 'NhlIsTransform', 'NhlIsView', 'NhlIsWorkstation', 'NhlName', 'NhlNDCPolygon', 'NhlNDCPolyline', 'NhlNDCPolymarker', 'NhlNDCToData', 'NhlNewColor', 'NhlNewDashPattern', 'NhlNewMarker', 'NhlPalGetDefined', 'NhlRemoveAnnotation', 'NhlRemoveData', 'NhlRemoveOverlay', 'NhlRemovePrimitive', 'NhlSetColor', 'NhlSetDashPattern', 'NhlSetMarker', 'NhlUpdateData', 'NhlUpdateWorkstation', 'nice_mnmxintvl', 'nngetaspectd', 'nngetaspects', 'nngetp', 'nngetsloped', 'nngetslopes', 'nngetwts', 'nngetwtsd', 'nnpnt', 'nnpntd', 'nnpntend', 'nnpntendd', 'nnpntinit', 'nnpntinitd', 'nnpntinits', 'nnpnts', 'nnsetp', 'num', 'obj_anal_ic', 'omega_ccm', 'onedtond', 'overlay', 'paleo_outline', 'pdfxy_bin', 'poisson_grid_fill', 'pop_remap', 'potmp_insitu_ocn', 'prcwater_dp', 'pres2hybrid', 'pres_hybrid_ccm', 'pres_sigma', 'print', 'print_table', 'printFileVarSummary', 'printVarSummary', 'product', 'pslec', 'pslhor', 'pslhyp', 'qsort', 'rand', 'random_chi', 'random_gamma', 'random_normal', 'random_setallseed', 'random_uniform', 'rcm2points', 'rcm2rgrid', 'rdsstoi', 'read_colormap_file', 'reg_multlin', 'regcoef', 'regCoef_n', 'regline', 'relhum', 'replace_ieeenan', 'reshape', 'reshape_ind', 'rgba_to_color_index', 'rgbhls', 'rgbhsv', 'rgbyiq', 'rgrid2rcm', 'rhomb_trunc', 'rip_cape_2d', 'rip_cape_3d', 'round', 'rtest', 'runave', 'runave_n', 'set_default_fillvalue', 'set_sphere_radius', 'setfileoption', 'sfvp2uvf', 'sfvp2uvg', 'shaec', 'shagc', 'shgetnp', 'shgetp', 'shgrid', 'shorttobyte', 'shorttochar', 'shorttocharacter', 'show_ascii', 'shsec', 'shsetp', 'shsgc', 'shsgc_R42', 'sigma2hybrid', 'simpeq', 'simpne', 'sin', 'sindex_yrmo', 'sinh', 'sizeof', 'sleep', 'smth9', 'snindex_yrmo', 'solve_linsys', 'span_color_indexes', 'span_color_rgba', 'sparse_matrix_mult', 'spcorr', 'spcorr_n', 'specx_anal', 'specxy_anal', 'spei', 'sprintf', 'sprinti', 'sqrt', 'sqsort', 'srand', 'stat2', 'stat4', 'stat_medrng', 'stat_trim', 'status_exit', 'stdatmus_p2tdz', 'stdatmus_z2tdp', 'stddev', 'str_capital', 'str_concat', 'str_fields_count', 'str_get_cols', 'str_get_dq', 'str_get_field', 'str_get_nl', 'str_get_sq', 'str_get_tab', 'str_index_of_substr', 'str_insert', 'str_is_blank', 'str_join', 'str_left_strip', 'str_lower', 'str_match', 'str_match_ic', 'str_match_ic_regex', 'str_match_ind', 'str_match_ind_ic', 'str_match_ind_ic_regex', 'str_match_ind_regex', 'str_match_regex', 'str_right_strip', 'str_split', 'str_split_by_length', 'str_split_csv', 'str_squeeze', 'str_strip', 'str_sub_str', 'str_switch', 'str_upper', 'stringtochar', 'stringtocharacter', 'stringtodouble', 'stringtofloat', 'stringtoint', 'stringtointeger', 'stringtolong', 'stringtoshort', 'strlen', 'student_t', 'sum', 'svd_lapack', 'svdcov', 'svdcov_sv', 'svdstd', 'svdstd_sv', 'system', 'systemfunc', 'tan', 'tanh', 'taper', 'taper_n', 'tdclrs', 'tdctri', 'tdcudp', 'tdcurv', 'tddtri', 'tdez2d', 'tdez3d', 'tdgetp', 'tdgrds', 'tdgrid', 'tdgtrs', 'tdinit', 'tditri', 'tdlbla', 'tdlblp', 'tdlbls', 'tdline', 'tdlndp', 'tdlnpa', 'tdlpdp', 'tdmtri', 'tdotri', 'tdpara', 'tdplch', 'tdprpa', 'tdprpi', 'tdprpt', 'tdsetp', 'tdsort', 'tdstri', 'tdstrs', 'tdttri', 'thornthwaite', 'tobyte', 'tochar', 'todouble', 'tofloat', 'toint', 'toint64', 'tointeger', 'tolong', 'toshort', 'tosigned', 'tostring', 'tostring_with_format', 'totype', 'toubyte', 'touint', 'touint64', 'toulong', 'tounsigned', 'toushort', 'trend_manken', 'tri_trunc', 'triple2grid', 'triple2grid2d', 'trop_wmo', 'ttest', 'typeof', 'undef', 'unique_string', 'update', 'ushorttoint', 'ut_calendar', 'ut_inv_calendar', 'utm2latlon', 'uv2dv_cfd', 'uv2dvf', 'uv2dvg', 'uv2sfvpf', 'uv2sfvpg', 'uv2vr_cfd', 'uv2vrdvf', 'uv2vrdvg', 'uv2vrf', 'uv2vrg', 'v5d_close', 'v5d_create', 'v5d_setLowLev', 'v5d_setUnits', 'v5d_write', 'v5d_write_var', 'variance', 'vhaec', 'vhagc', 'vhsec', 'vhsgc', 'vibeta', 'vinth2p', 'vinth2p_ecmwf', 'vinth2p_ecmwf_nodes', 'vinth2p_nodes', 'vintp2p_ecmwf', 'vr2uvf', 'vr2uvg', 'vrdv2uvf', 'vrdv2uvg', 'wavelet', 'wavelet_default', 'weibull', 'wgt_area_smooth', 'wgt_areaave', 'wgt_areaave2', 'wgt_arearmse', 'wgt_arearmse2', 'wgt_areasum2', 'wgt_runave', 'wgt_runave_n', 'wgt_vert_avg_beta', 'wgt_volave', 'wgt_volave_ccm', 'wgt_volrmse', 'wgt_volrmse_ccm', 'where', 'wk_smooth121', 'wmbarb', 'wmbarbmap', 'wmdrft', 'wmgetp', 'wmlabs', 'wmsetp', 'wmstnm', 'wmvect', 'wmvectmap', 'wmvlbl', 'wrf_avo', 'wrf_cape_2d', 'wrf_cape_3d', 'wrf_dbz', 'wrf_eth', 'wrf_helicity', 'wrf_ij_to_ll', 'wrf_interp_1d', 'wrf_interp_2d_xy', 'wrf_interp_3d_z', 'wrf_latlon_to_ij', 'wrf_ll_to_ij', 'wrf_omega', 'wrf_pvo', 'wrf_rh', 'wrf_slp', 'wrf_smooth_2d', 'wrf_td', 'wrf_tk', 'wrf_updraft_helicity', 'wrf_uvmet', 'wrf_virtual_temp', 'wrf_wetbulb', 'wrf_wps_close_int', 'wrf_wps_open_int', 'wrf_wps_rddata_int', 'wrf_wps_rdhead_int', 'wrf_wps_read_int', 'wrf_wps_write_int', 'write_matrix', 'write_table', 'yiqrgb', 'z2geouv', 'zonal_mpsi', 'addfiles_GetVar', 'advect_variable', 'area_conserve_remap_Wrap', 'area_hi2lores_Wrap', 'array_append_record', 'assignFillValue', 'byte2flt', 'byte2flt_hdf', 'calcDayAnomTLL', 'calcMonAnomLLLT', 'calcMonAnomLLT', 'calcMonAnomTLL', 'calcMonAnomTLLL', 'calculate_monthly_values', 'cd_convert', 'changeCase', 'changeCaseChar', 'clmDayTLL', 'clmDayTLLL', 'clmMon2clmDay', 'clmMonLLLT', 'clmMonLLT', 'clmMonTLL', 'clmMonTLLL', 'closest_val', 'copy_VarAtts', 'copy_VarCoords', 'copy_VarCoords_1', 'copy_VarCoords_2', 'copy_VarMeta', 'copyatt', 'crossp3', 'cshstringtolist', 'cssgrid_Wrap', 'dble2flt', 'decimalPlaces', 'delete_VarAtts', 'dim_avg_n_Wrap', 'dim_avg_wgt_n_Wrap', 'dim_avg_wgt_Wrap', 'dim_avg_Wrap', 'dim_cumsum_n_Wrap', 'dim_cumsum_Wrap', 'dim_max_n_Wrap', 'dim_min_n_Wrap', 'dim_rmsd_n_Wrap', 'dim_rmsd_Wrap', 'dim_rmvmean_n_Wrap', 'dim_rmvmean_Wrap', 'dim_rmvmed_n_Wrap', 'dim_rmvmed_Wrap', 'dim_standardize_n_Wrap', 'dim_standardize_Wrap', 'dim_stddev_n_Wrap', 'dim_stddev_Wrap', 'dim_sum_n_Wrap', 'dim_sum_wgt_n_Wrap', 'dim_sum_wgt_Wrap', 'dim_sum_Wrap', 'dim_variance_n_Wrap', 'dim_variance_Wrap', 'dpres_plevel_Wrap', 'dtrend_leftdim', 'dv2uvF_Wrap', 'dv2uvG_Wrap', 'eof_north', 'eofcor_Wrap', 'eofcov_Wrap', 'eofunc_north', 'eofunc_ts_Wrap', 'eofunc_varimax_reorder', 'eofunc_varimax_Wrap', 'eofunc_Wrap', 'epsZero', 'f2fosh_Wrap', 'f2foshv_Wrap', 'f2fsh_Wrap', 'f2fshv_Wrap', 'f2gsh_Wrap', 'f2gshv_Wrap', 'fbindirSwap', 'fbinseqSwap1', 'fbinseqSwap2', 'flt2dble', 'flt2string', 'fo2fsh_Wrap', 'fo2fshv_Wrap', 'g2fsh_Wrap', 'g2fshv_Wrap', 'g2gsh_Wrap', 'g2gshv_Wrap', 'generate_resample_indices', 'generate_sample_indices', 'generate_unique_indices', 'genNormalDist', 'get1Dindex', 'get1Dindex_Collapse', 'get1Dindex_Exclude', 'get_file_suffix', 'GetFillColor', 'GetFillColorIndex', 'getFillValue', 'getind_latlon2d', 'getVarDimNames', 'getVarFillValue', 'grib_stime2itime', 'hyi2hyo_Wrap', 'ilapsF_Wrap', 'ilapsG_Wrap', 'ind_nearest_coord', 'indStrSubset', 'int2dble', 'int2flt', 'int2p_n_Wrap', 'int2p_Wrap', 'isMonotonic', 'isStrSubset', 'latGau', 'latGauWgt', 'latGlobeF', 'latGlobeFo', 'latRegWgt', 'linint1_n_Wrap', 'linint1_Wrap', 'linint2_points_Wrap', 'linint2_Wrap', 'local_max_1d', 'local_min_1d', 'lonFlip', 'lonGlobeF', 'lonGlobeFo', 'lonPivot', 'merge_levels_sfc', 'mod', 'month_to_annual', 'month_to_annual_weighted', 'month_to_season', 'month_to_season12', 'month_to_seasonN', 'monthly_total_to_daily_mean', 'nameDim', 'natgrid_Wrap', 'NewCosWeight', 'niceLatLon2D', 'NormCosWgtGlobe', 'numAsciiCol', 'numAsciiRow', 'numeric2int', 'obj_anal_ic_deprecated', 'obj_anal_ic_Wrap', 'omega_ccm_driver', 'omega_to_w', 'oneDtostring', 'pack_values', 'pattern_cor', 'pdfx', 'pdfxy', 'pdfxy_conform', 'pot_temp', 'pot_vort_hybrid', 'pot_vort_isobaric', 'pres2hybrid_Wrap', 'print_clock', 'printMinMax', 'quadroots', 'rcm2points_Wrap', 'rcm2rgrid_Wrap', 'readAsciiHead', 'readAsciiTable', 'reg_multlin_stats', 'region_ind', 'regline_stats', 'relhum_ttd', 'replaceSingleChar', 'RGBtoCmap', 'rgrid2rcm_Wrap', 'rho_mwjf', 'rm_single_dims', 'rmAnnCycle1D', 'rmInsufData', 'rmMonAnnCycLLLT', 'rmMonAnnCycLLT', 'rmMonAnnCycTLL', 'runave_n_Wrap', 'runave_Wrap', 'short2flt', 'short2flt_hdf', 'shsgc_R42_Wrap', 'sign_f90', 'sign_matlab', 'smth9_Wrap', 'smthClmDayTLL', 'smthClmDayTLLL', 'SqrtCosWeight', 'stat_dispersion', 'static_stability', 'stdMonLLLT', 'stdMonLLT', 'stdMonTLL', 'stdMonTLLL', 'symMinMaxPlt', 'table_attach_columns', 'table_attach_rows', 'time_to_newtime', 'transpose', 'triple2grid_Wrap', 'ut_convert', 'uv2dvF_Wrap', 'uv2dvG_Wrap', 'uv2vrF_Wrap', 'uv2vrG_Wrap', 'vr2uvF_Wrap', 'vr2uvG_Wrap', 'w_to_omega', 'wallClockElapseTime', 'wave_number_spc', 'wgt_areaave_Wrap', 'wgt_runave_leftdim', 'wgt_runave_n_Wrap', 'wgt_runave_Wrap', 'wgt_vertical_n', 'wind_component', 'wind_direction', 'yyyyddd_to_yyyymmdd', 'yyyymm_time', 'yyyymm_to_yyyyfrac', 'yyyymmdd_time', 'yyyymmdd_to_yyyyddd', 'yyyymmdd_to_yyyyfrac', 'yyyymmddhh_time', 'yyyymmddhh_to_yyyyfrac', 'zonal_mpsi_Wrap', 'zonalAve', 'calendar_decode2', 'cd_string', 'kf_filter', 'run_cor', 'time_axis_labels', 'ut_string', 'wrf_contour', 'wrf_map', 'wrf_map_overlay', 'wrf_map_overlays', 'wrf_map_resources', 'wrf_map_zoom', 'wrf_overlay', 'wrf_overlays', 'wrf_user_getvar', 'wrf_user_ij_to_ll', 'wrf_user_intrp2d', 'wrf_user_intrp3d', 'wrf_user_latlon_to_ij', 'wrf_user_list_times', 'wrf_user_ll_to_ij', 'wrf_user_unstagger', 'wrf_user_vert_interp', 'wrf_vector', 'gsn_add_annotation', 'gsn_add_polygon', 'gsn_add_polyline', 'gsn_add_polymarker', 'gsn_add_shapefile_polygons', 'gsn_add_shapefile_polylines', 'gsn_add_shapefile_polymarkers', 'gsn_add_text', 'gsn_attach_plots', 'gsn_blank_plot', 'gsn_contour', 'gsn_contour_map', 'gsn_contour_shade', 'gsn_coordinates', 'gsn_create_labelbar', 'gsn_create_legend', 'gsn_create_text', 'gsn_csm_attach_zonal_means', 'gsn_csm_blank_plot', 'gsn_csm_contour', 'gsn_csm_contour_map', 'gsn_csm_contour_map_ce', 'gsn_csm_contour_map_overlay', 'gsn_csm_contour_map_polar', 'gsn_csm_hov', 'gsn_csm_lat_time', 'gsn_csm_map', 'gsn_csm_map_ce', 'gsn_csm_map_polar', 'gsn_csm_pres_hgt', 'gsn_csm_pres_hgt_streamline', 'gsn_csm_pres_hgt_vector', 'gsn_csm_streamline', 'gsn_csm_streamline_contour_map', 'gsn_csm_streamline_contour_map_ce', 'gsn_csm_streamline_contour_map_polar', 'gsn_csm_streamline_map', 'gsn_csm_streamline_map_ce', 'gsn_csm_streamline_map_polar', 'gsn_csm_streamline_scalar', 'gsn_csm_streamline_scalar_map', 'gsn_csm_streamline_scalar_map_ce', 'gsn_csm_streamline_scalar_map_polar', 'gsn_csm_time_lat', 'gsn_csm_vector', 'gsn_csm_vector_map', 'gsn_csm_vector_map_ce', 'gsn_csm_vector_map_polar', 'gsn_csm_vector_scalar', 'gsn_csm_vector_scalar_map', 'gsn_csm_vector_scalar_map_ce', 'gsn_csm_vector_scalar_map_polar', 'gsn_csm_x2y', 'gsn_csm_x2y2', 'gsn_csm_xy', 'gsn_csm_xy2', 'gsn_csm_xy3', 'gsn_csm_y', 'gsn_define_colormap', 'gsn_draw_colormap', 'gsn_draw_named_colors', 'gsn_histogram', 'gsn_labelbar_ndc', 'gsn_legend_ndc', 'gsn_map', 'gsn_merge_colormaps', 'gsn_open_wks', 'gsn_panel', 'gsn_polygon', 'gsn_polygon_ndc', 'gsn_polyline', 'gsn_polyline_ndc', 'gsn_polymarker', 'gsn_polymarker_ndc', 'gsn_retrieve_colormap', 'gsn_reverse_colormap', 'gsn_streamline', 'gsn_streamline_map', 'gsn_streamline_scalar', 'gsn_streamline_scalar_map', 'gsn_table', 'gsn_text', 'gsn_text_ndc', 'gsn_vector', 'gsn_vector_map', 'gsn_vector_scalar', 'gsn_vector_scalar_map', 'gsn_xy', 'gsn_y', 'hsv2rgb', 'maximize_output', 'namedcolor2rgb', 'namedcolor2rgba', 'reset_device_coordinates', 'span_named_colors'), prefix=r'\b'), Name.Builtin), # Resources (words(( 'amDataXF', 'amDataYF', 'amJust', 'amOn', 'amOrthogonalPosF', 'amParallelPosF', 'amResizeNotify', 'amSide', 'amTrackData', 'amViewId', 'amZone', 'appDefaultParent', 'appFileSuffix', 'appResources', 'appSysDir', 'appUsrDir', 'caCopyArrays', 'caXArray', 'caXCast', 'caXMaxV', 'caXMinV', 'caXMissingV', 'caYArray', 'caYCast', 'caYMaxV', 'caYMinV', 'caYMissingV', 'cnCellFillEdgeColor', 'cnCellFillMissingValEdgeColor', 'cnConpackParams', 'cnConstFEnableFill', 'cnConstFLabelAngleF', 'cnConstFLabelBackgroundColor', 'cnConstFLabelConstantSpacingF', 'cnConstFLabelFont', 'cnConstFLabelFontAspectF', 'cnConstFLabelFontColor', 'cnConstFLabelFontHeightF', 'cnConstFLabelFontQuality', 'cnConstFLabelFontThicknessF', 'cnConstFLabelFormat', 'cnConstFLabelFuncCode', 'cnConstFLabelJust', 'cnConstFLabelOn', 'cnConstFLabelOrthogonalPosF', 'cnConstFLabelParallelPosF', 'cnConstFLabelPerimColor', 'cnConstFLabelPerimOn', 'cnConstFLabelPerimSpaceF', 'cnConstFLabelPerimThicknessF', 'cnConstFLabelSide', 'cnConstFLabelString', 'cnConstFLabelTextDirection', 'cnConstFLabelZone', 'cnConstFUseInfoLabelRes', 'cnExplicitLabelBarLabelsOn', 'cnExplicitLegendLabelsOn', 'cnExplicitLineLabelsOn', 'cnFillBackgroundColor', 'cnFillColor', 'cnFillColors', 'cnFillDotSizeF', 'cnFillDrawOrder', 'cnFillMode', 'cnFillOn', 'cnFillOpacityF', 'cnFillPalette', 'cnFillPattern', 'cnFillPatterns', 'cnFillScaleF', 'cnFillScales', 'cnFixFillBleed', 'cnGridBoundFillColor', 'cnGridBoundFillPattern', 'cnGridBoundFillScaleF', 'cnGridBoundPerimColor', 'cnGridBoundPerimDashPattern', 'cnGridBoundPerimOn', 'cnGridBoundPerimThicknessF', 'cnHighLabelAngleF', 'cnHighLabelBackgroundColor', 'cnHighLabelConstantSpacingF', 'cnHighLabelCount', 'cnHighLabelFont', 'cnHighLabelFontAspectF', 'cnHighLabelFontColor', 'cnHighLabelFontHeightF', 'cnHighLabelFontQuality', 'cnHighLabelFontThicknessF', 'cnHighLabelFormat', 'cnHighLabelFuncCode', 'cnHighLabelPerimColor', 'cnHighLabelPerimOn', 'cnHighLabelPerimSpaceF', 'cnHighLabelPerimThicknessF', 'cnHighLabelString', 'cnHighLabelsOn', 'cnHighLowLabelOverlapMode', 'cnHighUseLineLabelRes', 'cnInfoLabelAngleF', 'cnInfoLabelBackgroundColor', 'cnInfoLabelConstantSpacingF', 'cnInfoLabelFont', 'cnInfoLabelFontAspectF', 'cnInfoLabelFontColor', 'cnInfoLabelFontHeightF', 'cnInfoLabelFontQuality', 'cnInfoLabelFontThicknessF', 'cnInfoLabelFormat', 'cnInfoLabelFuncCode', 'cnInfoLabelJust', 'cnInfoLabelOn', 'cnInfoLabelOrthogonalPosF', 'cnInfoLabelParallelPosF', 'cnInfoLabelPerimColor', 'cnInfoLabelPerimOn', 'cnInfoLabelPerimSpaceF', 'cnInfoLabelPerimThicknessF', 'cnInfoLabelSide', 'cnInfoLabelString', 'cnInfoLabelTextDirection', 'cnInfoLabelZone', 'cnLabelBarEndLabelsOn', 'cnLabelBarEndStyle', 'cnLabelDrawOrder', 'cnLabelMasking', 'cnLabelScaleFactorF', 'cnLabelScaleValueF', 'cnLabelScalingMode', 'cnLegendLevelFlags', 'cnLevelCount', 'cnLevelFlag', 'cnLevelFlags', 'cnLevelSelectionMode', 'cnLevelSpacingF', 'cnLevels', 'cnLineColor', 'cnLineColors', 'cnLineDashPattern', 'cnLineDashPatterns', 'cnLineDashSegLenF', 'cnLineDrawOrder', 'cnLineLabelAngleF', 'cnLineLabelBackgroundColor', 'cnLineLabelConstantSpacingF', 'cnLineLabelCount', 'cnLineLabelDensityF', 'cnLineLabelFont', 'cnLineLabelFontAspectF', 'cnLineLabelFontColor', 'cnLineLabelFontColors', 'cnLineLabelFontHeightF', 'cnLineLabelFontQuality', 'cnLineLabelFontThicknessF', 'cnLineLabelFormat', 'cnLineLabelFuncCode', 'cnLineLabelInterval', 'cnLineLabelPerimColor', 'cnLineLabelPerimOn', 'cnLineLabelPerimSpaceF', 'cnLineLabelPerimThicknessF', 'cnLineLabelPlacementMode', 'cnLineLabelStrings', 'cnLineLabelsOn', 'cnLinePalette', 'cnLineThicknessF', 'cnLineThicknesses', 'cnLinesOn', 'cnLowLabelAngleF', 'cnLowLabelBackgroundColor', 'cnLowLabelConstantSpacingF', 'cnLowLabelCount', 'cnLowLabelFont', 'cnLowLabelFontAspectF', 'cnLowLabelFontColor', 'cnLowLabelFontHeightF', 'cnLowLabelFontQuality', 'cnLowLabelFontThicknessF', 'cnLowLabelFormat', 'cnLowLabelFuncCode', 'cnLowLabelPerimColor', 'cnLowLabelPerimOn', 'cnLowLabelPerimSpaceF', 'cnLowLabelPerimThicknessF', 'cnLowLabelString', 'cnLowLabelsOn', 'cnLowUseHighLabelRes', 'cnMaxDataValueFormat', 'cnMaxLevelCount', 'cnMaxLevelValF', 'cnMaxPointDistanceF', 'cnMinLevelValF', 'cnMissingValFillColor', 'cnMissingValFillPattern', 'cnMissingValFillScaleF', 'cnMissingValPerimColor', 'cnMissingValPerimDashPattern', 'cnMissingValPerimGridBoundOn', 'cnMissingValPerimOn', 'cnMissingValPerimThicknessF', 'cnMonoFillColor', 'cnMonoFillPattern', 'cnMonoFillScale', 'cnMonoLevelFlag', 'cnMonoLineColor', 'cnMonoLineDashPattern', 'cnMonoLineLabelFontColor', 'cnMonoLineThickness', 'cnNoDataLabelOn', 'cnNoDataLabelString', 'cnOutOfRangeFillColor', 'cnOutOfRangeFillPattern', 'cnOutOfRangeFillScaleF', 'cnOutOfRangePerimColor', 'cnOutOfRangePerimDashPattern', 'cnOutOfRangePerimOn', 'cnOutOfRangePerimThicknessF', 'cnRasterCellSizeF', 'cnRasterMinCellSizeF', 'cnRasterModeOn', 'cnRasterSampleFactorF', 'cnRasterSmoothingOn', 'cnScalarFieldData', 'cnSmoothingDistanceF', 'cnSmoothingOn', 'cnSmoothingTensionF', 'cnSpanFillPalette', 'cnSpanLinePalette', 'ctCopyTables', 'ctXElementSize', 'ctXMaxV', 'ctXMinV', 'ctXMissingV', 'ctXTable', 'ctXTableLengths', 'ctXTableType', 'ctYElementSize', 'ctYMaxV', 'ctYMinV', 'ctYMissingV', 'ctYTable', 'ctYTableLengths', 'ctYTableType', 'dcDelayCompute', 'errBuffer', 'errFileName', 'errFilePtr', 'errLevel', 'errPrint', 'errUnitNumber', 'gsClipOn', 'gsColors', 'gsEdgeColor', 'gsEdgeDashPattern', 'gsEdgeDashSegLenF', 'gsEdgeThicknessF', 'gsEdgesOn', 'gsFillBackgroundColor', 'gsFillColor', 'gsFillDotSizeF', 'gsFillIndex', 'gsFillLineThicknessF', 'gsFillOpacityF', 'gsFillScaleF', 'gsFont', 'gsFontAspectF', 'gsFontColor', 'gsFontHeightF', 'gsFontOpacityF', 'gsFontQuality', 'gsFontThicknessF', 'gsLineColor', 'gsLineDashPattern', 'gsLineDashSegLenF', 'gsLineLabelConstantSpacingF', 'gsLineLabelFont', 'gsLineLabelFontAspectF', 'gsLineLabelFontColor', 'gsLineLabelFontHeightF', 'gsLineLabelFontQuality', 'gsLineLabelFontThicknessF', 'gsLineLabelFuncCode', 'gsLineLabelString', 'gsLineOpacityF', 'gsLineThicknessF', 'gsMarkerColor', 'gsMarkerIndex', 'gsMarkerOpacityF', 'gsMarkerSizeF', 'gsMarkerThicknessF', 'gsSegments', 'gsTextAngleF', 'gsTextConstantSpacingF', 'gsTextDirection', 'gsTextFuncCode', 'gsTextJustification', 'gsnAboveYRefLineBarColors', 'gsnAboveYRefLineBarFillScales', 'gsnAboveYRefLineBarPatterns', 'gsnAboveYRefLineColor', 'gsnAddCyclic', 'gsnAttachBorderOn', 'gsnAttachPlotsXAxis', 'gsnBelowYRefLineBarColors', 'gsnBelowYRefLineBarFillScales', 'gsnBelowYRefLineBarPatterns', 'gsnBelowYRefLineColor', 'gsnBoxMargin', 'gsnCenterString', 'gsnCenterStringFontColor', 'gsnCenterStringFontHeightF', 'gsnCenterStringFuncCode', 'gsnCenterStringOrthogonalPosF', 'gsnCenterStringParallelPosF', 'gsnContourLineThicknessesScale', 'gsnContourNegLineDashPattern', 'gsnContourPosLineDashPattern', 'gsnContourZeroLineThicknessF', 'gsnDebugWriteFileName', 'gsnDraw', 'gsnFrame', 'gsnHistogramBarWidthPercent', 'gsnHistogramBinIntervals', 'gsnHistogramBinMissing', 'gsnHistogramBinWidth', 'gsnHistogramClassIntervals', 'gsnHistogramCompare', 'gsnHistogramComputePercentages', 'gsnHistogramComputePercentagesNoMissing', 'gsnHistogramDiscreteBinValues', 'gsnHistogramDiscreteClassValues', 'gsnHistogramHorizontal', 'gsnHistogramMinMaxBinsOn', 'gsnHistogramNumberOfBins', 'gsnHistogramPercentSign', 'gsnHistogramSelectNiceIntervals', 'gsnLeftString', 'gsnLeftStringFontColor', 'gsnLeftStringFontHeightF', 'gsnLeftStringFuncCode', 'gsnLeftStringOrthogonalPosF', 'gsnLeftStringParallelPosF', 'gsnMajorLatSpacing', 'gsnMajorLonSpacing', 'gsnMaskLambertConformal', 'gsnMaskLambertConformalOutlineOn', 'gsnMaximize', 'gsnMinorLatSpacing', 'gsnMinorLonSpacing', 'gsnPanelBottom', 'gsnPanelCenter', 'gsnPanelDebug', 'gsnPanelFigureStrings', 'gsnPanelFigureStringsBackgroundFillColor', 'gsnPanelFigureStringsFontHeightF', 'gsnPanelFigureStringsJust', 'gsnPanelFigureStringsPerimOn', 'gsnPanelLabelBar', 'gsnPanelLeft', 'gsnPanelMainFont', 'gsnPanelMainFontColor', 'gsnPanelMainFontHeightF', 'gsnPanelMainString', 'gsnPanelRight', 'gsnPanelRowSpec', 'gsnPanelScalePlotIndex', 'gsnPanelTop', 'gsnPanelXF', 'gsnPanelXWhiteSpacePercent', 'gsnPanelYF', 'gsnPanelYWhiteSpacePercent', 'gsnPaperHeight', 'gsnPaperMargin', 'gsnPaperOrientation', 'gsnPaperWidth', 'gsnPolar', 'gsnPolarLabelDistance', 'gsnPolarLabelFont', 'gsnPolarLabelFontHeightF', 'gsnPolarLabelSpacing', 'gsnPolarTime', 'gsnPolarUT', 'gsnRightString', 'gsnRightStringFontColor', 'gsnRightStringFontHeightF', 'gsnRightStringFuncCode', 'gsnRightStringOrthogonalPosF', 'gsnRightStringParallelPosF', 'gsnScalarContour', 'gsnScale', 'gsnShape', 'gsnSpreadColorEnd', 'gsnSpreadColorStart', 'gsnSpreadColors', 'gsnStringFont', 'gsnStringFontColor', 'gsnStringFontHeightF', 'gsnStringFuncCode', 'gsnTickMarksOn', 'gsnXAxisIrregular2Linear', 'gsnXAxisIrregular2Log', 'gsnXRefLine', 'gsnXRefLineColor', 'gsnXRefLineDashPattern', 'gsnXRefLineThicknessF', 'gsnXYAboveFillColors', 'gsnXYBarChart', 'gsnXYBarChartBarWidth', 'gsnXYBarChartColors', 'gsnXYBarChartColors2', 'gsnXYBarChartFillDotSizeF', 'gsnXYBarChartFillLineThicknessF', 'gsnXYBarChartFillOpacityF', 'gsnXYBarChartFillScaleF', 'gsnXYBarChartOutlineOnly', 'gsnXYBarChartOutlineThicknessF', 'gsnXYBarChartPatterns', 'gsnXYBarChartPatterns2', 'gsnXYBelowFillColors', 'gsnXYFillColors', 'gsnXYFillOpacities', 'gsnXYLeftFillColors', 'gsnXYRightFillColors', 'gsnYAxisIrregular2Linear', 'gsnYAxisIrregular2Log', 'gsnYRefLine', 'gsnYRefLineColor', 'gsnYRefLineColors', 'gsnYRefLineDashPattern', 'gsnYRefLineDashPatterns', 'gsnYRefLineThicknessF', 'gsnYRefLineThicknesses', 'gsnZonalMean', 'gsnZonalMeanXMaxF', 'gsnZonalMeanXMinF', 'gsnZonalMeanYRefLine', 'lbAutoManage', 'lbBottomMarginF', 'lbBoxCount', 'lbBoxEndCapStyle', 'lbBoxFractions', 'lbBoxLineColor', 'lbBoxLineDashPattern', 'lbBoxLineDashSegLenF', 'lbBoxLineThicknessF', 'lbBoxLinesOn', 'lbBoxMajorExtentF', 'lbBoxMinorExtentF', 'lbBoxSeparatorLinesOn', 'lbBoxSizing', 'lbFillBackground', 'lbFillColor', 'lbFillColors', 'lbFillDotSizeF', 'lbFillLineThicknessF', 'lbFillPattern', 'lbFillPatterns', 'lbFillScaleF', 'lbFillScales', 'lbJustification', 'lbLabelAlignment', 'lbLabelAngleF', 'lbLabelAutoStride', 'lbLabelBarOn', 'lbLabelConstantSpacingF', 'lbLabelDirection', 'lbLabelFont', 'lbLabelFontAspectF', 'lbLabelFontColor', 'lbLabelFontHeightF', 'lbLabelFontQuality', 'lbLabelFontThicknessF', 'lbLabelFuncCode', 'lbLabelJust', 'lbLabelOffsetF', 'lbLabelPosition', 'lbLabelStride', 'lbLabelStrings', 'lbLabelsOn', 'lbLeftMarginF', 'lbMaxLabelLenF', 'lbMinLabelSpacingF', 'lbMonoFillColor', 'lbMonoFillPattern', 'lbMonoFillScale', 'lbOrientation', 'lbPerimColor', 'lbPerimDashPattern', 'lbPerimDashSegLenF', 'lbPerimFill', 'lbPerimFillColor', 'lbPerimOn', 'lbPerimThicknessF', 'lbRasterFillOn', 'lbRightMarginF', 'lbTitleAngleF', 'lbTitleConstantSpacingF', 'lbTitleDirection', 'lbTitleExtentF', 'lbTitleFont', 'lbTitleFontAspectF', 'lbTitleFontColor', 'lbTitleFontHeightF', 'lbTitleFontQuality', 'lbTitleFontThicknessF', 'lbTitleFuncCode', 'lbTitleJust', 'lbTitleOffsetF', 'lbTitleOn', 'lbTitlePosition', 'lbTitleString', 'lbTopMarginF', 'lgAutoManage', 'lgBottomMarginF', 'lgBoxBackground', 'lgBoxLineColor', 'lgBoxLineDashPattern', 'lgBoxLineDashSegLenF', 'lgBoxLineThicknessF', 'lgBoxLinesOn', 'lgBoxMajorExtentF', 'lgBoxMinorExtentF', 'lgDashIndex', 'lgDashIndexes', 'lgItemCount', 'lgItemOrder', 'lgItemPlacement', 'lgItemPositions', 'lgItemType', 'lgItemTypes', 'lgJustification', 'lgLabelAlignment', 'lgLabelAngleF', 'lgLabelAutoStride', 'lgLabelConstantSpacingF', 'lgLabelDirection', 'lgLabelFont', 'lgLabelFontAspectF', 'lgLabelFontColor', 'lgLabelFontHeightF', 'lgLabelFontQuality', 'lgLabelFontThicknessF', 'lgLabelFuncCode', 'lgLabelJust', 'lgLabelOffsetF', 'lgLabelPosition', 'lgLabelStride', 'lgLabelStrings', 'lgLabelsOn', 'lgLeftMarginF', 'lgLegendOn', 'lgLineColor', 'lgLineColors', 'lgLineDashSegLenF', 'lgLineDashSegLens', 'lgLineLabelConstantSpacingF', 'lgLineLabelFont', 'lgLineLabelFontAspectF', 'lgLineLabelFontColor', 'lgLineLabelFontColors', 'lgLineLabelFontHeightF', 'lgLineLabelFontHeights', 'lgLineLabelFontQuality', 'lgLineLabelFontThicknessF', 'lgLineLabelFuncCode', 'lgLineLabelStrings', 'lgLineLabelsOn', 'lgLineThicknessF', 'lgLineThicknesses', 'lgMarkerColor', 'lgMarkerColors', 'lgMarkerIndex', 'lgMarkerIndexes', 'lgMarkerSizeF', 'lgMarkerSizes', 'lgMarkerThicknessF', 'lgMarkerThicknesses', 'lgMonoDashIndex', 'lgMonoItemType', 'lgMonoLineColor', 'lgMonoLineDashSegLen', 'lgMonoLineLabelFontColor', 'lgMonoLineLabelFontHeight', 'lgMonoLineThickness', 'lgMonoMarkerColor', 'lgMonoMarkerIndex', 'lgMonoMarkerSize', 'lgMonoMarkerThickness', 'lgOrientation', 'lgPerimColor', 'lgPerimDashPattern', 'lgPerimDashSegLenF', 'lgPerimFill', 'lgPerimFillColor', 'lgPerimOn', 'lgPerimThicknessF', 'lgRightMarginF', 'lgTitleAngleF', 'lgTitleConstantSpacingF', 'lgTitleDirection', 'lgTitleExtentF', 'lgTitleFont', 'lgTitleFontAspectF', 'lgTitleFontColor', 'lgTitleFontHeightF', 'lgTitleFontQuality', 'lgTitleFontThicknessF', 'lgTitleFuncCode', 'lgTitleJust', 'lgTitleOffsetF', 'lgTitleOn', 'lgTitlePosition', 'lgTitleString', 'lgTopMarginF', 'mpAreaGroupCount', 'mpAreaMaskingOn', 'mpAreaNames', 'mpAreaTypes', 'mpBottomAngleF', 'mpBottomMapPosF', 'mpBottomNDCF', 'mpBottomNPCF', 'mpBottomPointLatF', 'mpBottomPointLonF', 'mpBottomWindowF', 'mpCenterLatF', 'mpCenterLonF', 'mpCenterRotF', 'mpCountyLineColor', 'mpCountyLineDashPattern', 'mpCountyLineDashSegLenF', 'mpCountyLineThicknessF', 'mpDataBaseVersion', 'mpDataResolution', 'mpDataSetName', 'mpDefaultFillColor', 'mpDefaultFillPattern', 'mpDefaultFillScaleF', 'mpDynamicAreaGroups', 'mpEllipticalBoundary', 'mpFillAreaSpecifiers', 'mpFillBoundarySets', 'mpFillColor', 'mpFillColors', 'mpFillColors-default', 'mpFillDotSizeF', 'mpFillDrawOrder', 'mpFillOn', 'mpFillPatternBackground', 'mpFillPattern', 'mpFillPatterns', 'mpFillPatterns-default', 'mpFillScaleF', 'mpFillScales', 'mpFillScales-default', 'mpFixedAreaGroups', 'mpGeophysicalLineColor', 'mpGeophysicalLineDashPattern', 'mpGeophysicalLineDashSegLenF', 'mpGeophysicalLineThicknessF', 'mpGreatCircleLinesOn', 'mpGridAndLimbDrawOrder', 'mpGridAndLimbOn', 'mpGridLatSpacingF', 'mpGridLineColor', 'mpGridLineDashPattern', 'mpGridLineDashSegLenF', 'mpGridLineThicknessF', 'mpGridLonSpacingF', 'mpGridMaskMode', 'mpGridMaxLatF', 'mpGridPolarLonSpacingF', 'mpGridSpacingF', 'mpInlandWaterFillColor', 'mpInlandWaterFillPattern', 'mpInlandWaterFillScaleF', 'mpLabelDrawOrder', 'mpLabelFontColor', 'mpLabelFontHeightF', 'mpLabelsOn', 'mpLambertMeridianF', 'mpLambertParallel1F', 'mpLambertParallel2F', 'mpLandFillColor', 'mpLandFillPattern', 'mpLandFillScaleF', 'mpLeftAngleF', 'mpLeftCornerLatF', 'mpLeftCornerLonF', 'mpLeftMapPosF', 'mpLeftNDCF', 'mpLeftNPCF', 'mpLeftPointLatF', 'mpLeftPointLonF', 'mpLeftWindowF', 'mpLimbLineColor', 'mpLimbLineDashPattern', 'mpLimbLineDashSegLenF', 'mpLimbLineThicknessF', 'mpLimitMode', 'mpMaskAreaSpecifiers', 'mpMaskOutlineSpecifiers', 'mpMaxLatF', 'mpMaxLonF', 'mpMinLatF', 'mpMinLonF', 'mpMonoFillColor', 'mpMonoFillPattern', 'mpMonoFillScale', 'mpNationalLineColor', 'mpNationalLineDashPattern', 'mpNationalLineThicknessF', 'mpOceanFillColor', 'mpOceanFillPattern', 'mpOceanFillScaleF', 'mpOutlineBoundarySets', 'mpOutlineDrawOrder', 'mpOutlineMaskingOn', 'mpOutlineOn', 'mpOutlineSpecifiers', 'mpPerimDrawOrder', 'mpPerimLineColor', 'mpPerimLineDashPattern', 'mpPerimLineDashSegLenF', 'mpPerimLineThicknessF', 'mpPerimOn', 'mpPolyMode', 'mpProjection', 'mpProvincialLineColor', 'mpProvincialLineDashPattern', 'mpProvincialLineDashSegLenF', 'mpProvincialLineThicknessF', 'mpRelativeCenterLat', 'mpRelativeCenterLon', 'mpRightAngleF', 'mpRightCornerLatF', 'mpRightCornerLonF', 'mpRightMapPosF', 'mpRightNDCF', 'mpRightNPCF', 'mpRightPointLatF', 'mpRightPointLonF', 'mpRightWindowF', 'mpSatelliteAngle1F', 'mpSatelliteAngle2F', 'mpSatelliteDistF', 'mpShapeMode', 'mpSpecifiedFillColors', 'mpSpecifiedFillDirectIndexing', 'mpSpecifiedFillPatterns', 'mpSpecifiedFillPriority', 'mpSpecifiedFillScales', 'mpTopAngleF', 'mpTopMapPosF', 'mpTopNDCF', 'mpTopNPCF', 'mpTopPointLatF', 'mpTopPointLonF', 'mpTopWindowF', 'mpUSStateLineColor', 'mpUSStateLineDashPattern', 'mpUSStateLineDashSegLenF', 'mpUSStateLineThicknessF', 'pmAnnoManagers', 'pmAnnoViews', 'pmLabelBarDisplayMode', 'pmLabelBarHeightF', 'pmLabelBarKeepAspect', 'pmLabelBarOrthogonalPosF', 'pmLabelBarParallelPosF', 'pmLabelBarSide', 'pmLabelBarWidthF', 'pmLabelBarZone', 'pmLegendDisplayMode', 'pmLegendHeightF', 'pmLegendKeepAspect', 'pmLegendOrthogonalPosF', 'pmLegendParallelPosF', 'pmLegendSide', 'pmLegendWidthF', 'pmLegendZone', 'pmOverlaySequenceIds', 'pmTickMarkDisplayMode', 'pmTickMarkZone', 'pmTitleDisplayMode', 'pmTitleZone', 'prGraphicStyle', 'prPolyType', 'prXArray', 'prYArray', 'sfCopyData', 'sfDataArray', 'sfDataMaxV', 'sfDataMinV', 'sfElementNodes', 'sfExchangeDimensions', 'sfFirstNodeIndex', 'sfMissingValueV', 'sfXArray', 'sfXCActualEndF', 'sfXCActualStartF', 'sfXCEndIndex', 'sfXCEndSubsetV', 'sfXCEndV', 'sfXCStartIndex', 'sfXCStartSubsetV', 'sfXCStartV', 'sfXCStride', 'sfXCellBounds', 'sfYArray', 'sfYCActualEndF', 'sfYCActualStartF', 'sfYCEndIndex', 'sfYCEndSubsetV', 'sfYCEndV', 'sfYCStartIndex', 'sfYCStartSubsetV', 'sfYCStartV', 'sfYCStride', 'sfYCellBounds', 'stArrowLengthF', 'stArrowStride', 'stCrossoverCheckCount', 'stExplicitLabelBarLabelsOn', 'stLabelBarEndLabelsOn', 'stLabelFormat', 'stLengthCheckCount', 'stLevelColors', 'stLevelCount', 'stLevelPalette', 'stLevelSelectionMode', 'stLevelSpacingF', 'stLevels', 'stLineColor', 'stLineOpacityF', 'stLineStartStride', 'stLineThicknessF', 'stMapDirection', 'stMaxLevelCount', 'stMaxLevelValF', 'stMinArrowSpacingF', 'stMinDistanceF', 'stMinLevelValF', 'stMinLineSpacingF', 'stMinStepFactorF', 'stMonoLineColor', 'stNoDataLabelOn', 'stNoDataLabelString', 'stScalarFieldData', 'stScalarMissingValColor', 'stSpanLevelPalette', 'stStepSizeF', 'stStreamlineDrawOrder', 'stUseScalarArray', 'stVectorFieldData', 'stZeroFLabelAngleF', 'stZeroFLabelBackgroundColor', 'stZeroFLabelConstantSpacingF', 'stZeroFLabelFont', 'stZeroFLabelFontAspectF', 'stZeroFLabelFontColor', 'stZeroFLabelFontHeightF', 'stZeroFLabelFontQuality', 'stZeroFLabelFontThicknessF', 'stZeroFLabelFuncCode', 'stZeroFLabelJust', 'stZeroFLabelOn', 'stZeroFLabelOrthogonalPosF', 'stZeroFLabelParallelPosF', 'stZeroFLabelPerimColor', 'stZeroFLabelPerimOn', 'stZeroFLabelPerimSpaceF', 'stZeroFLabelPerimThicknessF', 'stZeroFLabelSide', 'stZeroFLabelString', 'stZeroFLabelTextDirection', 'stZeroFLabelZone', 'tfDoNDCOverlay', 'tfPlotManagerOn', 'tfPolyDrawList', 'tfPolyDrawOrder', 'tiDeltaF', 'tiMainAngleF', 'tiMainConstantSpacingF', 'tiMainDirection', 'tiMainFont', 'tiMainFontAspectF', 'tiMainFontColor', 'tiMainFontHeightF', 'tiMainFontQuality', 'tiMainFontThicknessF', 'tiMainFuncCode', 'tiMainJust', 'tiMainOffsetXF', 'tiMainOffsetYF', 'tiMainOn', 'tiMainPosition', 'tiMainSide', 'tiMainString', 'tiUseMainAttributes', 'tiXAxisAngleF', 'tiXAxisConstantSpacingF', 'tiXAxisDirection', 'tiXAxisFont', 'tiXAxisFontAspectF', 'tiXAxisFontColor', 'tiXAxisFontHeightF', 'tiXAxisFontQuality', 'tiXAxisFontThicknessF', 'tiXAxisFuncCode', 'tiXAxisJust', 'tiXAxisOffsetXF', 'tiXAxisOffsetYF', 'tiXAxisOn', 'tiXAxisPosition', 'tiXAxisSide', 'tiXAxisString', 'tiYAxisAngleF', 'tiYAxisConstantSpacingF', 'tiYAxisDirection', 'tiYAxisFont', 'tiYAxisFontAspectF', 'tiYAxisFontColor', 'tiYAxisFontHeightF', 'tiYAxisFontQuality', 'tiYAxisFontThicknessF', 'tiYAxisFuncCode', 'tiYAxisJust', 'tiYAxisOffsetXF', 'tiYAxisOffsetYF', 'tiYAxisOn', 'tiYAxisPosition', 'tiYAxisSide', 'tiYAxisString', 'tmBorderLineColor', 'tmBorderThicknessF', 'tmEqualizeXYSizes', 'tmLabelAutoStride', 'tmSciNoteCutoff', 'tmXBAutoPrecision', 'tmXBBorderOn', 'tmXBDataLeftF', 'tmXBDataRightF', 'tmXBFormat', 'tmXBIrrTensionF', 'tmXBIrregularPoints', 'tmXBLabelAngleF', 'tmXBLabelConstantSpacingF', 'tmXBLabelDeltaF', 'tmXBLabelDirection', 'tmXBLabelFont', 'tmXBLabelFontAspectF', 'tmXBLabelFontColor', 'tmXBLabelFontHeightF', 'tmXBLabelFontQuality', 'tmXBLabelFontThicknessF', 'tmXBLabelFuncCode', 'tmXBLabelJust', 'tmXBLabelStride', 'tmXBLabels', 'tmXBLabelsOn', 'tmXBMajorLengthF', 'tmXBMajorLineColor', 'tmXBMajorOutwardLengthF', 'tmXBMajorThicknessF', 'tmXBMaxLabelLenF', 'tmXBMaxTicks', 'tmXBMinLabelSpacingF', 'tmXBMinorLengthF', 'tmXBMinorLineColor', 'tmXBMinorOn', 'tmXBMinorOutwardLengthF', 'tmXBMinorPerMajor', 'tmXBMinorThicknessF', 'tmXBMinorValues', 'tmXBMode', 'tmXBOn', 'tmXBPrecision', 'tmXBStyle', 'tmXBTickEndF', 'tmXBTickSpacingF', 'tmXBTickStartF', 'tmXBValues', 'tmXMajorGrid', 'tmXMajorGridLineColor', 'tmXMajorGridLineDashPattern', 'tmXMajorGridThicknessF', 'tmXMinorGrid', 'tmXMinorGridLineColor', 'tmXMinorGridLineDashPattern', 'tmXMinorGridThicknessF', 'tmXTAutoPrecision', 'tmXTBorderOn', 'tmXTDataLeftF', 'tmXTDataRightF', 'tmXTFormat', 'tmXTIrrTensionF', 'tmXTIrregularPoints', 'tmXTLabelAngleF', 'tmXTLabelConstantSpacingF', 'tmXTLabelDeltaF', 'tmXTLabelDirection', 'tmXTLabelFont', 'tmXTLabelFontAspectF', 'tmXTLabelFontColor', 'tmXTLabelFontHeightF', 'tmXTLabelFontQuality', 'tmXTLabelFontThicknessF', 'tmXTLabelFuncCode', 'tmXTLabelJust', 'tmXTLabelStride', 'tmXTLabels', 'tmXTLabelsOn', 'tmXTMajorLengthF', 'tmXTMajorLineColor', 'tmXTMajorOutwardLengthF', 'tmXTMajorThicknessF', 'tmXTMaxLabelLenF', 'tmXTMaxTicks', 'tmXTMinLabelSpacingF', 'tmXTMinorLengthF', 'tmXTMinorLineColor', 'tmXTMinorOn', 'tmXTMinorOutwardLengthF', 'tmXTMinorPerMajor', 'tmXTMinorThicknessF', 'tmXTMinorValues', 'tmXTMode', 'tmXTOn', 'tmXTPrecision', 'tmXTStyle', 'tmXTTickEndF', 'tmXTTickSpacingF', 'tmXTTickStartF', 'tmXTValues', 'tmXUseBottom', 'tmYLAutoPrecision', 'tmYLBorderOn', 'tmYLDataBottomF', 'tmYLDataTopF', 'tmYLFormat', 'tmYLIrrTensionF', 'tmYLIrregularPoints', 'tmYLLabelAngleF', 'tmYLLabelConstantSpacingF', 'tmYLLabelDeltaF', 'tmYLLabelDirection', 'tmYLLabelFont', 'tmYLLabelFontAspectF', 'tmYLLabelFontColor', 'tmYLLabelFontHeightF', 'tmYLLabelFontQuality', 'tmYLLabelFontThicknessF', 'tmYLLabelFuncCode', 'tmYLLabelJust', 'tmYLLabelStride', 'tmYLLabels', 'tmYLLabelsOn', 'tmYLMajorLengthF', 'tmYLMajorLineColor', 'tmYLMajorOutwardLengthF', 'tmYLMajorThicknessF', 'tmYLMaxLabelLenF', 'tmYLMaxTicks', 'tmYLMinLabelSpacingF', 'tmYLMinorLengthF', 'tmYLMinorLineColor', 'tmYLMinorOn', 'tmYLMinorOutwardLengthF', 'tmYLMinorPerMajor', 'tmYLMinorThicknessF', 'tmYLMinorValues', 'tmYLMode', 'tmYLOn', 'tmYLPrecision', 'tmYLStyle', 'tmYLTickEndF', 'tmYLTickSpacingF', 'tmYLTickStartF', 'tmYLValues', 'tmYMajorGrid', 'tmYMajorGridLineColor', 'tmYMajorGridLineDashPattern', 'tmYMajorGridThicknessF', 'tmYMinorGrid', 'tmYMinorGridLineColor', 'tmYMinorGridLineDashPattern', 'tmYMinorGridThicknessF', 'tmYRAutoPrecision', 'tmYRBorderOn', 'tmYRDataBottomF', 'tmYRDataTopF', 'tmYRFormat', 'tmYRIrrTensionF', 'tmYRIrregularPoints', 'tmYRLabelAngleF', 'tmYRLabelConstantSpacingF', 'tmYRLabelDeltaF', 'tmYRLabelDirection', 'tmYRLabelFont', 'tmYRLabelFontAspectF', 'tmYRLabelFontColor', 'tmYRLabelFontHeightF', 'tmYRLabelFontQuality', 'tmYRLabelFontThicknessF', 'tmYRLabelFuncCode', 'tmYRLabelJust', 'tmYRLabelStride', 'tmYRLabels', 'tmYRLabelsOn', 'tmYRMajorLengthF', 'tmYRMajorLineColor', 'tmYRMajorOutwardLengthF', 'tmYRMajorThicknessF', 'tmYRMaxLabelLenF', 'tmYRMaxTicks', 'tmYRMinLabelSpacingF', 'tmYRMinorLengthF', 'tmYRMinorLineColor', 'tmYRMinorOn', 'tmYRMinorOutwardLengthF', 'tmYRMinorPerMajor', 'tmYRMinorThicknessF', 'tmYRMinorValues', 'tmYRMode', 'tmYROn', 'tmYRPrecision', 'tmYRStyle', 'tmYRTickEndF', 'tmYRTickSpacingF', 'tmYRTickStartF', 'tmYRValues', 'tmYUseLeft', 'trGridType', 'trLineInterpolationOn', 'trXAxisType', 'trXCoordPoints', 'trXInterPoints', 'trXLog', 'trXMaxF', 'trXMinF', 'trXReverse', 'trXSamples', 'trXTensionF', 'trYAxisType', 'trYCoordPoints', 'trYInterPoints', 'trYLog', 'trYMaxF', 'trYMinF', 'trYReverse', 'trYSamples', 'trYTensionF', 'txAngleF', 'txBackgroundFillColor', 'txConstantSpacingF', 'txDirection', 'txFont', 'HLU-Fonts', 'txFontAspectF', 'txFontColor', 'txFontHeightF', 'txFontOpacityF', 'txFontQuality', 'txFontThicknessF', 'txFuncCode', 'txJust', 'txPerimColor', 'txPerimDashLengthF', 'txPerimDashPattern', 'txPerimOn', 'txPerimSpaceF', 'txPerimThicknessF', 'txPosXF', 'txPosYF', 'txString', 'vcExplicitLabelBarLabelsOn', 'vcFillArrowEdgeColor', 'vcFillArrowEdgeThicknessF', 'vcFillArrowFillColor', 'vcFillArrowHeadInteriorXF', 'vcFillArrowHeadMinFracXF', 'vcFillArrowHeadMinFracYF', 'vcFillArrowHeadXF', 'vcFillArrowHeadYF', 'vcFillArrowMinFracWidthF', 'vcFillArrowWidthF', 'vcFillArrowsOn', 'vcFillOverEdge', 'vcGlyphOpacityF', 'vcGlyphStyle', 'vcLabelBarEndLabelsOn', 'vcLabelFontColor', 'vcLabelFontHeightF', 'vcLabelsOn', 'vcLabelsUseVectorColor', 'vcLevelColors', 'vcLevelCount', 'vcLevelPalette', 'vcLevelSelectionMode', 'vcLevelSpacingF', 'vcLevels', 'vcLineArrowColor', 'vcLineArrowHeadMaxSizeF', 'vcLineArrowHeadMinSizeF', 'vcLineArrowThicknessF', 'vcMagnitudeFormat', 'vcMagnitudeScaleFactorF', 'vcMagnitudeScaleValueF', 'vcMagnitudeScalingMode', 'vcMapDirection', 'vcMaxLevelCount', 'vcMaxLevelValF', 'vcMaxMagnitudeF', 'vcMinAnnoAngleF', 'vcMinAnnoArrowAngleF', 'vcMinAnnoArrowEdgeColor', 'vcMinAnnoArrowFillColor', 'vcMinAnnoArrowLineColor', 'vcMinAnnoArrowMinOffsetF', 'vcMinAnnoArrowSpaceF', 'vcMinAnnoArrowUseVecColor', 'vcMinAnnoBackgroundColor', 'vcMinAnnoConstantSpacingF', 'vcMinAnnoExplicitMagnitudeF', 'vcMinAnnoFont', 'vcMinAnnoFontAspectF', 'vcMinAnnoFontColor', 'vcMinAnnoFontHeightF', 'vcMinAnnoFontQuality', 'vcMinAnnoFontThicknessF', 'vcMinAnnoFuncCode', 'vcMinAnnoJust', 'vcMinAnnoOn', 'vcMinAnnoOrientation', 'vcMinAnnoOrthogonalPosF', 'vcMinAnnoParallelPosF', 'vcMinAnnoPerimColor', 'vcMinAnnoPerimOn', 'vcMinAnnoPerimSpaceF', 'vcMinAnnoPerimThicknessF', 'vcMinAnnoSide', 'vcMinAnnoString1', 'vcMinAnnoString1On', 'vcMinAnnoString2', 'vcMinAnnoString2On', 'vcMinAnnoTextDirection', 'vcMinAnnoZone', 'vcMinDistanceF', 'vcMinFracLengthF', 'vcMinLevelValF', 'vcMinMagnitudeF', 'vcMonoFillArrowEdgeColor', 'vcMonoFillArrowFillColor', 'vcMonoLineArrowColor', 'vcMonoWindBarbColor', 'vcNoDataLabelOn', 'vcNoDataLabelString', 'vcPositionMode', 'vcRefAnnoAngleF', 'vcRefAnnoArrowAngleF', 'vcRefAnnoArrowEdgeColor', 'vcRefAnnoArrowFillColor', 'vcRefAnnoArrowLineColor', 'vcRefAnnoArrowMinOffsetF', 'vcRefAnnoArrowSpaceF', 'vcRefAnnoArrowUseVecColor', 'vcRefAnnoBackgroundColor', 'vcRefAnnoConstantSpacingF', 'vcRefAnnoExplicitMagnitudeF', 'vcRefAnnoFont', 'vcRefAnnoFontAspectF', 'vcRefAnnoFontColor', 'vcRefAnnoFontHeightF', 'vcRefAnnoFontQuality', 'vcRefAnnoFontThicknessF', 'vcRefAnnoFuncCode', 'vcRefAnnoJust', 'vcRefAnnoOn', 'vcRefAnnoOrientation', 'vcRefAnnoOrthogonalPosF', 'vcRefAnnoParallelPosF', 'vcRefAnnoPerimColor', 'vcRefAnnoPerimOn', 'vcRefAnnoPerimSpaceF', 'vcRefAnnoPerimThicknessF', 'vcRefAnnoSide', 'vcRefAnnoString1', 'vcRefAnnoString1On', 'vcRefAnnoString2', 'vcRefAnnoString2On', 'vcRefAnnoTextDirection', 'vcRefAnnoZone', 'vcRefLengthF', 'vcRefMagnitudeF', 'vcScalarFieldData', 'vcScalarMissingValColor', 'vcScalarValueFormat', 'vcScalarValueScaleFactorF', 'vcScalarValueScaleValueF', 'vcScalarValueScalingMode', 'vcSpanLevelPalette', 'vcUseRefAnnoRes', 'vcUseScalarArray', 'vcVectorDrawOrder', 'vcVectorFieldData', 'vcWindBarbCalmCircleSizeF', 'vcWindBarbColor', 'vcWindBarbLineThicknessF', 'vcWindBarbScaleFactorF', 'vcWindBarbTickAngleF', 'vcWindBarbTickLengthF', 'vcWindBarbTickSpacingF', 'vcZeroFLabelAngleF', 'vcZeroFLabelBackgroundColor', 'vcZeroFLabelConstantSpacingF', 'vcZeroFLabelFont', 'vcZeroFLabelFontAspectF', 'vcZeroFLabelFontColor', 'vcZeroFLabelFontHeightF', 'vcZeroFLabelFontQuality', 'vcZeroFLabelFontThicknessF', 'vcZeroFLabelFuncCode', 'vcZeroFLabelJust', 'vcZeroFLabelOn', 'vcZeroFLabelOrthogonalPosF', 'vcZeroFLabelParallelPosF', 'vcZeroFLabelPerimColor', 'vcZeroFLabelPerimOn', 'vcZeroFLabelPerimSpaceF', 'vcZeroFLabelPerimThicknessF', 'vcZeroFLabelSide', 'vcZeroFLabelString', 'vcZeroFLabelTextDirection', 'vcZeroFLabelZone', 'vfCopyData', 'vfDataArray', 'vfExchangeDimensions', 'vfExchangeUVData', 'vfMagMaxV', 'vfMagMinV', 'vfMissingUValueV', 'vfMissingVValueV', 'vfPolarData', 'vfSingleMissingValue', 'vfUDataArray', 'vfUMaxV', 'vfUMinV', 'vfVDataArray', 'vfVMaxV', 'vfVMinV', 'vfXArray', 'vfXCActualEndF', 'vfXCActualStartF', 'vfXCEndIndex', 'vfXCEndSubsetV', 'vfXCEndV', 'vfXCStartIndex', 'vfXCStartSubsetV', 'vfXCStartV', 'vfXCStride', 'vfYArray', 'vfYCActualEndF', 'vfYCActualStartF', 'vfYCEndIndex', 'vfYCEndSubsetV', 'vfYCEndV', 'vfYCStartIndex', 'vfYCStartSubsetV', 'vfYCStartV', 'vfYCStride', 'vpAnnoManagerId', 'vpClipOn', 'vpHeightF', 'vpKeepAspect', 'vpOn', 'vpUseSegments', 'vpWidthF', 'vpXF', 'vpYF', 'wkAntiAlias', 'wkBackgroundColor', 'wkBackgroundOpacityF', 'wkColorMapLen', 'wkColorMap', 'wkColorModel', 'wkDashTableLength', 'wkDefGraphicStyleId', 'wkDeviceLowerX', 'wkDeviceLowerY', 'wkDeviceUpperX', 'wkDeviceUpperY', 'wkFileName', 'wkFillTableLength', 'wkForegroundColor', 'wkFormat', 'wkFullBackground', 'wkGksWorkId', 'wkHeight', 'wkMarkerTableLength', 'wkMetaName', 'wkOrientation', 'wkPDFFileName', 'wkPDFFormat', 'wkPDFResolution', 'wkPSFileName', 'wkPSFormat', 'wkPSResolution', 'wkPaperHeightF', 'wkPaperSize', 'wkPaperWidthF', 'wkPause', 'wkTopLevelViews', 'wkViews', 'wkVisualType', 'wkWidth', 'wkWindowId', 'wkXColorMode', 'wsCurrentSize', 'wsMaximumSize', 'wsThresholdSize', 'xyComputeXMax', 'xyComputeXMin', 'xyComputeYMax', 'xyComputeYMin', 'xyCoordData', 'xyCoordDataSpec', 'xyCurveDrawOrder', 'xyDashPattern', 'xyDashPatterns', 'xyExplicitLabels', 'xyExplicitLegendLabels', 'xyLabelMode', 'xyLineColor', 'xyLineColors', 'xyLineDashSegLenF', 'xyLineLabelConstantSpacingF', 'xyLineLabelFont', 'xyLineLabelFontAspectF', 'xyLineLabelFontColor', 'xyLineLabelFontColors', 'xyLineLabelFontHeightF', 'xyLineLabelFontQuality', 'xyLineLabelFontThicknessF', 'xyLineLabelFuncCode', 'xyLineThicknessF', 'xyLineThicknesses', 'xyMarkLineMode', 'xyMarkLineModes', 'xyMarker', 'xyMarkerColor', 'xyMarkerColors', 'xyMarkerSizeF', 'xyMarkerSizes', 'xyMarkerThicknessF', 'xyMarkerThicknesses', 'xyMarkers', 'xyMonoDashPattern', 'xyMonoLineColor', 'xyMonoLineLabelFontColor', 'xyMonoLineThickness', 'xyMonoMarkLineMode', 'xyMonoMarker', 'xyMonoMarkerColor', 'xyMonoMarkerSize', 'xyMonoMarkerThickness', 'xyXIrrTensionF', 'xyXIrregularPoints', 'xyXStyle', 'xyYIrrTensionF', 'xyYIrregularPoints', 'xyYStyle'), prefix=r'\b'), Name.Builtin), # Booleans (r'\.(True|False)\.', Name.Builtin), # Comparing Operators (r'\.(eq|ne|lt|le|gt|ge|not|and|or|xor)\.', Operator.Word), ], 'strings': [ (r'(?s)"(\\\\|\\[0-7]+|\\.|[^"\\])*"', String.Double), ], 'nums': [ (r'\d+(?![.e])(_[a-z]\w+)?', Number.Integer), (r'[+-]?\d*\.\d+(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float), (r'[+-]?\d+\.\d*(e[-+]?\d+)?(_[a-z]\w+)?', Number.Float), ], }
63,962
Python
70.54698
91
0.592868
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/mosel.py
""" pygments.lexers.mosel ~~~~~~~~~~~~~~~~~~~~~ Lexers for the mosel language. http://www.fico.com/en/products/fico-xpress-optimization :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, words from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation __all__ = ['MoselLexer'] FUNCTIONS = ( # core functions '_', 'abs', 'arctan', 'asproc', 'assert', 'bitflip', 'bitneg', 'bitset', 'bitshift', 'bittest', 'bitval', 'ceil', 'cos', 'create', 'currentdate', 'currenttime', 'cutelt', 'cutfirst', 'cuthead', 'cutlast', 'cuttail', 'datablock', 'delcell', 'exists', 'exit', 'exp', 'exportprob', 'fclose', 'fflush', 'finalize', 'findfirst', 'findlast', 'floor', 'fopen', 'fselect', 'fskipline', 'fwrite', 'fwrite_', 'fwriteln', 'fwriteln_', 'getact', 'getcoeff', 'getcoeffs', 'getdual', 'getelt', 'getfid', 'getfirst', 'getfname', 'gethead', 'getlast', 'getobjval', 'getparam', 'getrcost', 'getreadcnt', 'getreverse', 'getsize', 'getslack', 'getsol', 'gettail', 'gettype', 'getvars', 'isdynamic', 'iseof', 'isfinite', 'ishidden', 'isinf', 'isnan', 'isodd', 'ln', 'localsetparam', 'log', 'makesos1', 'makesos2', 'maxlist', 'memoryuse', 'minlist', 'newmuid', 'publish', 'random', 'read', 'readln', 'reset', 'restoreparam', 'reverse', 'round', 'setcoeff', 'sethidden', 'setioerr', 'setmatherr', 'setname', 'setparam', 'setrandseed', 'setrange', 'settype', 'sin', 'splithead', 'splittail', 'sqrt', 'strfmt', 'substr', 'timestamp', 'unpublish', 'versionnum', 'versionstr', 'write', 'write_', 'writeln', 'writeln_', # mosel exam mmxprs | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u 'addcut', 'addcuts', 'addmipsol', 'basisstability', 'calcsolinfo', 'clearmipdir', 'clearmodcut', 'command', 'copysoltoinit', 'crossoverlpsol', 'defdelayedrows', 'defsecurevecs', 'delcuts', 'dropcuts', 'estimatemarginals', 'fixglobal', 'flushmsgq', 'getbstat', 'getcnlist', 'getcplist', 'getdualray', 'getiis', 'getiissense', 'getiistype', 'getinfcause', 'getinfeas', 'getlb', 'getlct', 'getleft', 'getloadedlinctrs', 'getloadedmpvars', 'getname', 'getprimalray', 'getprobstat', 'getrange', 'getright', 'getsensrng', 'getsize', 'getsol', 'gettype', 'getub', 'getvars', 'gety', 'hasfeature', 'implies', 'indicator', 'initglobal', 'ishidden', 'isiisvalid', 'isintegral', 'loadbasis', 'loadcuts', 'loadlpsol', 'loadmipsol', 'loadprob', 'maximise', 'maximize', 'minimise', 'minimize', 'postsolve', 'readbasis', 'readdirs', 'readsol', 'refinemipsol', 'rejectintsol', 'repairinfeas', 'repairinfeas_deprec', 'resetbasis', 'resetiis', 'resetsol', 'savebasis', 'savemipsol', 'savesol', 'savestate', 'selectsol', 'setarchconsistency', 'setbstat', 'setcallback', 'setcbcutoff', 'setgndata', 'sethidden', 'setlb', 'setmipdir', 'setmodcut', 'setsol', 'setub', 'setucbdata', 'stopoptimise', 'stopoptimize', 'storecut', 'storecuts', 'unloadprob', 'uselastbarsol', 'writebasis', 'writedirs', 'writeprob', 'writesol', 'xor', 'xprs_addctr', 'xprs_addindic', # mosel exam mmsystem | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u 'addmonths', 'copytext', 'cuttext', 'deltext', 'endswith', 'erase', 'expandpath', 'fcopy', 'fdelete', 'findfiles', 'findtext', 'fmove', 'formattext', 'getasnumber', 'getchar', 'getcwd', 'getdate', 'getday', 'getdaynum', 'getdays', 'getdirsep', 'getdsoparam', 'getendparse', 'getenv', 'getfsize', 'getfstat', 'getftime', 'gethour', 'getminute', 'getmonth', 'getmsec', 'getoserrmsg', 'getoserror', 'getpathsep', 'getqtype', 'getsecond', 'getsepchar', 'getsize', 'getstart', 'getsucc', 'getsysinfo', 'getsysstat', 'gettime', 'gettmpdir', 'gettrim', 'getweekday', 'getyear', 'inserttext', 'isvalid', 'jointext', 'makedir', 'makepath', 'newtar', 'newzip', 'nextfield', 'openpipe', 'parseextn', 'parseint', 'parsereal', 'parsetext', 'pastetext', 'pathmatch', 'pathsplit', 'qsort', 'quote', 'readtextline', 'regmatch', 'regreplace', 'removedir', 'removefiles', 'setchar', 'setdate', 'setday', 'setdsoparam', 'setendparse', 'setenv', 'sethour', 'setminute', 'setmonth', 'setmsec', 'setoserror', 'setqtype', 'setsecond', 'setsepchar', 'setstart', 'setsucc', 'settime', 'settrim', 'setyear', 'sleep', 'splittext', 'startswith', 'system', 'tarlist', 'textfmt', 'tolower', 'toupper', 'trim', 'untar', 'unzip', 'ziplist', # mosel exam mmjobs | sed -n -e "s/ [pf][a-z]* \([a-zA-Z0-9_]*\).*/'\1',/p" | sort -u 'canceltimer', 'clearaliases', 'compile', 'connect', 'detach', 'disconnect', 'dropnextevent', 'findxsrvs', 'getaliases', 'getannidents', 'getannotations', 'getbanner', 'getclass', 'getdsoprop', 'getdsopropnum', 'getexitcode', 'getfromgid', 'getfromid', 'getfromuid', 'getgid', 'gethostalias', 'getid', 'getmodprop', 'getmodpropnum', 'getnextevent', 'getnode', 'getrmtid', 'getstatus', 'getsysinfo', 'gettimer', 'getuid', 'getvalue', 'isqueueempty', 'load', 'nullevent', 'peeknextevent', 'resetmodpar', 'run', 'send', 'setcontrol', 'setdefstream', 'setgid', 'sethostalias', 'setmodpar', 'settimer', 'setuid', 'setworkdir', 'stop', 'unload', 'wait', 'waitexpired', 'waitfor', 'waitforend', ) class MoselLexer(RegexLexer): """ For the Mosel optimization language. .. versionadded:: 2.6 """ name = 'Mosel' aliases = ['mosel'] filenames = ['*.mos'] tokens = { 'root': [ (r'\n', Text), (r'\s+', Text.Whitespace), (r'!.*?\n', Comment.Single), (r'\(!(.|\n)*?!\)', Comment.Multiline), (words(( 'and', 'as', 'break', 'case', 'count', 'declarations', 'do', 'dynamic', 'elif', 'else', 'end-', 'end', 'evaluation', 'false', 'forall', 'forward', 'from', 'function', 'hashmap', 'if', 'imports', 'include', 'initialisations', 'initializations', 'inter', 'max', 'min', 'model', 'namespace', 'next', 'not', 'nsgroup', 'nssearch', 'of', 'options', 'or', 'package', 'parameters', 'procedure', 'public', 'prod', 'record', 'repeat', 'requirements', 'return', 'sum', 'then', 'to', 'true', 'union', 'until', 'uses', 'version', 'while', 'with'), prefix=r'\b', suffix=r'\b'), Keyword.Builtin), (words(( 'range', 'array', 'set', 'list', 'mpvar', 'mpproblem', 'linctr', 'nlctr', 'integer', 'string', 'real', 'boolean', 'text', 'time', 'date', 'datetime', 'returned', 'Model', 'Mosel', 'counter', 'xmldoc', 'is_sos1', 'is_sos2', 'is_integer', 'is_binary', 'is_continuous', 'is_free', 'is_semcont', 'is_semint', 'is_partint'), prefix=r'\b', suffix=r'\b'), Keyword.Type), (r'(\+|\-|\*|/|=|<=|>=|\||\^|<|>|<>|\.\.|\.|:=|::|:|in|mod|div)', Operator), (r'[()\[\]{},;]+', Punctuation), (words(FUNCTIONS, prefix=r'\b', suffix=r'\b'), Name.Function), (r'(\d+\.(?!\.)\d*|\.(?!.)\d+)([eE][+-]?\d+)?', Number.Float), (r'\d+([eE][+-]?\d+)?', Number.Integer), (r'[+-]?Infinity', Number.Integer), (r'0[xX][0-9a-fA-F]+', Number), (r'"', String.Double, 'double_quote'), (r'\'', String.Single, 'single_quote'), (r'(\w+|(\.(?!\.)))', Text), ], 'single_quote': [ (r'\'', String.Single, '#pop'), (r'[^\']+', String.Single), ], 'double_quote': [ (r'(\\"|\\[0-7]{1,3}\D|\\[abfnrtv]|\\\\)', String.Escape), (r'\"', String.Double, '#pop'), (r'[^"\\]+', String.Double), ], }
9,187
Python
19.508929
91
0.484816
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/templates.py
""" pygments.lexers.templates ~~~~~~~~~~~~~~~~~~~~~~~~~ Lexers for various template engines' markup. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexers.html import HtmlLexer, XmlLexer from pygments.lexers.javascript import JavascriptLexer, LassoLexer from pygments.lexers.css import CssLexer from pygments.lexers.php import PhpLexer from pygments.lexers.python import PythonLexer from pygments.lexers.perl import PerlLexer from pygments.lexers.jvm import JavaLexer, TeaLangLexer from pygments.lexers.data import YamlLexer from pygments.lexers.sql import SqlLexer from pygments.lexer import Lexer, DelegatingLexer, RegexLexer, bygroups, \ include, using, this, default, combined from pygments.token import Error, Punctuation, Whitespace, \ Text, Comment, Operator, Keyword, Name, String, Number, Other, Token from pygments.util import html_doctype_matches, looks_like_xml __all__ = ['HtmlPhpLexer', 'XmlPhpLexer', 'CssPhpLexer', 'JavascriptPhpLexer', 'ErbLexer', 'RhtmlLexer', 'XmlErbLexer', 'CssErbLexer', 'JavascriptErbLexer', 'SmartyLexer', 'HtmlSmartyLexer', 'XmlSmartyLexer', 'CssSmartyLexer', 'JavascriptSmartyLexer', 'DjangoLexer', 'HtmlDjangoLexer', 'CssDjangoLexer', 'XmlDjangoLexer', 'JavascriptDjangoLexer', 'GenshiLexer', 'HtmlGenshiLexer', 'GenshiTextLexer', 'CssGenshiLexer', 'JavascriptGenshiLexer', 'MyghtyLexer', 'MyghtyHtmlLexer', 'MyghtyXmlLexer', 'MyghtyCssLexer', 'MyghtyJavascriptLexer', 'MasonLexer', 'MakoLexer', 'MakoHtmlLexer', 'MakoXmlLexer', 'MakoJavascriptLexer', 'MakoCssLexer', 'JspLexer', 'CheetahLexer', 'CheetahHtmlLexer', 'CheetahXmlLexer', 'CheetahJavascriptLexer', 'EvoqueLexer', 'EvoqueHtmlLexer', 'EvoqueXmlLexer', 'ColdfusionLexer', 'ColdfusionHtmlLexer', 'ColdfusionCFCLexer', 'VelocityLexer', 'VelocityHtmlLexer', 'VelocityXmlLexer', 'SspLexer', 'TeaTemplateLexer', 'LassoHtmlLexer', 'LassoXmlLexer', 'LassoCssLexer', 'LassoJavascriptLexer', 'HandlebarsLexer', 'HandlebarsHtmlLexer', 'YamlJinjaLexer', 'LiquidLexer', 'TwigLexer', 'TwigHtmlLexer', 'Angular2Lexer', 'Angular2HtmlLexer', 'SqlJinjaLexer'] class ErbLexer(Lexer): """ Generic ERB (Ruby Templating) lexer. Just highlights ruby code between the preprocessor directives, other data is left untouched by the lexer. All options are also forwarded to the `RubyLexer`. """ name = 'ERB' url = 'https://github.com/ruby/erb' aliases = ['erb'] mimetypes = ['application/x-ruby-templating'] _block_re = re.compile(r'(<%%|%%>|<%=|<%#|<%-|<%|-%>|%>|^%[^%].*?$)', re.M) def __init__(self, **options): from pygments.lexers.ruby import RubyLexer self.ruby_lexer = RubyLexer(**options) Lexer.__init__(self, **options) def get_tokens_unprocessed(self, text): """ Since ERB doesn't allow "<%" and other tags inside of ruby blocks we have to use a split approach here that fails for that too. """ tokens = self._block_re.split(text) tokens.reverse() state = idx = 0 try: while True: # text if state == 0: val = tokens.pop() yield idx, Other, val idx += len(val) state = 1 # block starts elif state == 1: tag = tokens.pop() # literals if tag in ('<%%', '%%>'): yield idx, Other, tag idx += 3 state = 0 # comment elif tag == '<%#': yield idx, Comment.Preproc, tag val = tokens.pop() yield idx + 3, Comment, val idx += 3 + len(val) state = 2 # blocks or output elif tag in ('<%', '<%=', '<%-'): yield idx, Comment.Preproc, tag idx += len(tag) data = tokens.pop() r_idx = 0 for r_idx, r_token, r_value in \ self.ruby_lexer.get_tokens_unprocessed(data): yield r_idx + idx, r_token, r_value idx += len(data) state = 2 elif tag in ('%>', '-%>'): yield idx, Error, tag idx += len(tag) state = 0 # % raw ruby statements else: yield idx, Comment.Preproc, tag[0] r_idx = 0 for r_idx, r_token, r_value in \ self.ruby_lexer.get_tokens_unprocessed(tag[1:]): yield idx + 1 + r_idx, r_token, r_value idx += len(tag) state = 0 # block ends elif state == 2: tag = tokens.pop() if tag not in ('%>', '-%>'): yield idx, Other, tag else: yield idx, Comment.Preproc, tag idx += len(tag) state = 0 except IndexError: return def analyse_text(text): if '<%' in text and '%>' in text: return 0.4 class SmartyLexer(RegexLexer): """ Generic Smarty template lexer. Just highlights smarty code between the preprocessor directives, other data is left untouched by the lexer. """ name = 'Smarty' url = 'https://www.smarty.net/' aliases = ['smarty'] filenames = ['*.tpl'] mimetypes = ['application/x-smarty'] flags = re.MULTILINE | re.DOTALL tokens = { 'root': [ (r'[^{]+', Other), (r'(\{)(\*.*?\*)(\})', bygroups(Comment.Preproc, Comment, Comment.Preproc)), (r'(\{php\})(.*?)(\{/php\})', bygroups(Comment.Preproc, using(PhpLexer, startinline=True), Comment.Preproc)), (r'(\{)(/?[a-zA-Z_]\w*)(\s*)', bygroups(Comment.Preproc, Name.Function, Text), 'smarty'), (r'\{', Comment.Preproc, 'smarty') ], 'smarty': [ (r'\s+', Text), (r'\{', Comment.Preproc, '#push'), (r'\}', Comment.Preproc, '#pop'), (r'#[a-zA-Z_]\w*#', Name.Variable), (r'\$[a-zA-Z_]\w*(\.\w+)*', Name.Variable), (r'[~!%^&*()+=|\[\]:;,.<>/?@-]', Operator), (r'(true|false|null)\b', Keyword.Constant), (r"[0-9](\.[0-9]*)?(eE[+-][0-9])?[flFLdD]?|" r"0[xX][0-9a-fA-F]+[Ll]?", Number), (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'[a-zA-Z_]\w*', Name.Attribute) ] } def analyse_text(text): rv = 0.0 if re.search(r'\{if\s+.*?\}.*?\{/if\}', text): rv += 0.15 if re.search(r'\{include\s+file=.*?\}', text): rv += 0.15 if re.search(r'\{foreach\s+.*?\}.*?\{/foreach\}', text): rv += 0.15 if re.search(r'\{\$.*?\}', text): rv += 0.01 return rv class VelocityLexer(RegexLexer): """ Generic Velocity template lexer. Just highlights velocity directives and variable references, other data is left untouched by the lexer. """ name = 'Velocity' url = 'https://velocity.apache.org/' aliases = ['velocity'] filenames = ['*.vm', '*.fhtml'] flags = re.MULTILINE | re.DOTALL identifier = r'[a-zA-Z_]\w*' tokens = { 'root': [ (r'[^{#$]+', Other), (r'(#)(\*.*?\*)(#)', bygroups(Comment.Preproc, Comment, Comment.Preproc)), (r'(##)(.*?$)', bygroups(Comment.Preproc, Comment)), (r'(#\{?)(' + identifier + r')(\}?)(\s?\()', bygroups(Comment.Preproc, Name.Function, Comment.Preproc, Punctuation), 'directiveparams'), (r'(#\{?)(' + identifier + r')(\}|\b)', bygroups(Comment.Preproc, Name.Function, Comment.Preproc)), (r'\$!?\{?', Punctuation, 'variable') ], 'variable': [ (identifier, Name.Variable), (r'\(', Punctuation, 'funcparams'), (r'(\.)(' + identifier + r')', bygroups(Punctuation, Name.Variable), '#push'), (r'\}', Punctuation, '#pop'), default('#pop') ], 'directiveparams': [ (r'(&&|\|\||==?|!=?|[-<>+*%&|^/])|\b(eq|ne|gt|lt|ge|le|not|in)\b', Operator), (r'\[', Operator, 'rangeoperator'), (r'\b' + identifier + r'\b', Name.Function), include('funcparams') ], 'rangeoperator': [ (r'\.\.', Operator), include('funcparams'), (r'\]', Operator, '#pop') ], 'funcparams': [ (r'\$!?\{?', Punctuation, 'variable'), (r'\s+', Text), (r'[,:]', Punctuation), (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r"0[xX][0-9a-fA-F]+[Ll]?", Number), (r"\b[0-9]+\b", Number), (r'(true|false|null)\b', Keyword.Constant), (r'\(', Punctuation, '#push'), (r'\)', Punctuation, '#pop'), (r'\{', Punctuation, '#push'), (r'\}', Punctuation, '#pop'), (r'\[', Punctuation, '#push'), (r'\]', Punctuation, '#pop'), ] } def analyse_text(text): rv = 0.0 if re.search(r'#\{?macro\}?\(.*?\).*?#\{?end\}?', text, re.DOTALL): rv += 0.25 if re.search(r'#\{?if\}?\(.+?\).*?#\{?end\}?', text, re.DOTALL): rv += 0.15 if re.search(r'#\{?foreach\}?\(.+?\).*?#\{?end\}?', text, re.DOTALL): rv += 0.15 if re.search(r'\$!?\{?[a-zA-Z_]\w*(\([^)]*\))?' r'(\.\w+(\([^)]*\))?)*\}?', text): rv += 0.01 return rv class VelocityHtmlLexer(DelegatingLexer): """ Subclass of the `VelocityLexer` that highlights unlexed data with the `HtmlLexer`. """ name = 'HTML+Velocity' aliases = ['html+velocity'] alias_filenames = ['*.html', '*.fhtml'] mimetypes = ['text/html+velocity'] def __init__(self, **options): super().__init__(HtmlLexer, VelocityLexer, **options) class VelocityXmlLexer(DelegatingLexer): """ Subclass of the `VelocityLexer` that highlights unlexed data with the `XmlLexer`. """ name = 'XML+Velocity' aliases = ['xml+velocity'] alias_filenames = ['*.xml', '*.vm'] mimetypes = ['application/xml+velocity'] def __init__(self, **options): super().__init__(XmlLexer, VelocityLexer, **options) def analyse_text(text): rv = VelocityLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class DjangoLexer(RegexLexer): """ Generic `django <http://www.djangoproject.com/documentation/templates/>`_ and `jinja <https://jinja.pocoo.org/jinja/>`_ template lexer. It just highlights django/jinja code between the preprocessor directives, other data is left untouched by the lexer. """ name = 'Django/Jinja' aliases = ['django', 'jinja'] mimetypes = ['application/x-django-templating', 'application/x-jinja'] flags = re.M | re.S tokens = { 'root': [ (r'[^{]+', Other), (r'\{\{', Comment.Preproc, 'var'), # jinja/django comments (r'\{#.*?#\}', Comment), # django comments (r'(\{%)(-?\s*)(comment)(\s*-?)(%\})(.*?)' r'(\{%)(-?\s*)(endcomment)(\s*-?)(%\})', bygroups(Comment.Preproc, Text, Keyword, Text, Comment.Preproc, Comment, Comment.Preproc, Text, Keyword, Text, Comment.Preproc)), # raw jinja blocks (r'(\{%)(-?\s*)(raw)(\s*-?)(%\})(.*?)' r'(\{%)(-?\s*)(endraw)(\s*-?)(%\})', bygroups(Comment.Preproc, Text, Keyword, Text, Comment.Preproc, Text, Comment.Preproc, Text, Keyword, Text, Comment.Preproc)), # filter blocks (r'(\{%)(-?\s*)(filter)(\s+)([a-zA-Z_]\w*)', bygroups(Comment.Preproc, Text, Keyword, Text, Name.Function), 'block'), (r'(\{%)(-?\s*)([a-zA-Z_]\w*)', bygroups(Comment.Preproc, Text, Keyword), 'block'), (r'\{', Other) ], 'varnames': [ (r'(\|)(\s*)([a-zA-Z_]\w*)', bygroups(Operator, Text, Name.Function)), (r'(is)(\s+)(not)?(\s+)?([a-zA-Z_]\w*)', bygroups(Keyword, Text, Keyword, Text, Name.Function)), (r'(_|true|false|none|True|False|None)\b', Keyword.Pseudo), (r'(in|as|reversed|recursive|not|and|or|is|if|else|import|' r'with(?:(?:out)?\s*context)?|scoped|ignore\s+missing)\b', Keyword), (r'(loop|block|super|forloop)\b', Name.Builtin), (r'[a-zA-Z_][\w-]*', Name.Variable), (r'\.\w+', Name.Variable), (r':?"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r":?'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'([{}()\[\]+\-*/%,:~]|[><=]=?|!=)', Operator), (r"[0-9](\.[0-9]*)?(eE[+-][0-9])?[flFLdD]?|" r"0[xX][0-9a-fA-F]+[Ll]?", Number), ], 'var': [ (r'\s+', Text), (r'(-?)(\}\})', bygroups(Text, Comment.Preproc), '#pop'), include('varnames') ], 'block': [ (r'\s+', Text), (r'(-?)(%\})', bygroups(Text, Comment.Preproc), '#pop'), include('varnames'), (r'.', Punctuation) ] } def analyse_text(text): rv = 0.0 if re.search(r'\{%\s*(block|extends)', text) is not None: rv += 0.4 if re.search(r'\{%\s*if\s*.*?%\}', text) is not None: rv += 0.1 if re.search(r'\{\{.*?\}\}', text) is not None: rv += 0.1 return rv class MyghtyLexer(RegexLexer): """ Generic myghty templates lexer. Code that isn't Myghty markup is yielded as `Token.Other`. .. versionadded:: 0.6 """ name = 'Myghty' url = 'http://www.myghty.org/' aliases = ['myghty'] filenames = ['*.myt', 'autodelegate'] mimetypes = ['application/x-myghty'] tokens = { 'root': [ (r'\s+', Text), (r'(?s)(<%(?:def|method))(\s*)(.*?)(>)(.*?)(</%\2\s*>)', bygroups(Name.Tag, Text, Name.Function, Name.Tag, using(this), Name.Tag)), (r'(?s)(<%\w+)(.*?)(>)(.*?)(</%\2\s*>)', bygroups(Name.Tag, Name.Function, Name.Tag, using(PythonLexer), Name.Tag)), (r'(<&[^|])(.*?)(,.*?)?(&>)', bygroups(Name.Tag, Name.Function, using(PythonLexer), Name.Tag)), (r'(?s)(<&\|)(.*?)(,.*?)?(&>)', bygroups(Name.Tag, Name.Function, using(PythonLexer), Name.Tag)), (r'</&>', Name.Tag), (r'(?s)(<%!?)(.*?)(%>)', bygroups(Name.Tag, using(PythonLexer), Name.Tag)), (r'(?<=^)#[^\n]*(\n|\Z)', Comment), (r'(?<=^)(%)([^\n]*)(\n|\Z)', bygroups(Name.Tag, using(PythonLexer), Other)), (r"""(?sx) (.+?) # anything, followed by: (?: (?<=\n)(?=[%#]) | # an eval or comment line (?=</?[%&]) | # a substitution or block or # call start or end # - don't consume (\\\n) | # an escaped newline \Z # end of string )""", bygroups(Other, Operator)), ] } class MyghtyHtmlLexer(DelegatingLexer): """ Subclass of the `MyghtyLexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 0.6 """ name = 'HTML+Myghty' aliases = ['html+myghty'] mimetypes = ['text/html+myghty'] def __init__(self, **options): super().__init__(HtmlLexer, MyghtyLexer, **options) class MyghtyXmlLexer(DelegatingLexer): """ Subclass of the `MyghtyLexer` that highlights unlexed data with the `XmlLexer`. .. versionadded:: 0.6 """ name = 'XML+Myghty' aliases = ['xml+myghty'] mimetypes = ['application/xml+myghty'] def __init__(self, **options): super().__init__(XmlLexer, MyghtyLexer, **options) class MyghtyJavascriptLexer(DelegatingLexer): """ Subclass of the `MyghtyLexer` that highlights unlexed data with the `JavascriptLexer`. .. versionadded:: 0.6 """ name = 'JavaScript+Myghty' aliases = ['javascript+myghty', 'js+myghty'] mimetypes = ['application/x-javascript+myghty', 'text/x-javascript+myghty', 'text/javascript+mygthy'] def __init__(self, **options): super().__init__(JavascriptLexer, MyghtyLexer, **options) class MyghtyCssLexer(DelegatingLexer): """ Subclass of the `MyghtyLexer` that highlights unlexed data with the `CssLexer`. .. versionadded:: 0.6 """ name = 'CSS+Myghty' aliases = ['css+myghty'] mimetypes = ['text/css+myghty'] def __init__(self, **options): super().__init__(CssLexer, MyghtyLexer, **options) class MasonLexer(RegexLexer): """ Generic mason templates lexer. Stolen from Myghty lexer. Code that isn't Mason markup is HTML. .. versionadded:: 1.4 """ name = 'Mason' url = 'http://www.masonhq.com/' aliases = ['mason'] filenames = ['*.m', '*.mhtml', '*.mc', '*.mi', 'autohandler', 'dhandler'] mimetypes = ['application/x-mason'] tokens = { 'root': [ (r'\s+', Whitespace), (r'(?s)(<%doc>)(.*?)(</%doc>)', bygroups(Name.Tag, Comment.Multiline, Name.Tag)), (r'(?s)(<%(?:def|method))(\s*)(.*?)(>)(.*?)(</%\2\s*>)', bygroups(Name.Tag, Whitespace, Name.Function, Name.Tag, using(this), Name.Tag)), (r'(?s)(<%(\w+)(.*?)(>))(.*?)(</%\2\s*>)', bygroups(Name.Tag, None, None, None, using(PerlLexer), Name.Tag)), (r'(?s)(<&[^|])(.*?)(,.*?)?(&>)', bygroups(Name.Tag, Name.Function, using(PerlLexer), Name.Tag)), (r'(?s)(<&\|)(.*?)(,.*?)?(&>)', bygroups(Name.Tag, Name.Function, using(PerlLexer), Name.Tag)), (r'</&>', Name.Tag), (r'(?s)(<%!?)(.*?)(%>)', bygroups(Name.Tag, using(PerlLexer), Name.Tag)), (r'(?<=^)#[^\n]*(\n|\Z)', Comment), (r'(?<=^)(%)([^\n]*)(\n|\Z)', bygroups(Name.Tag, using(PerlLexer), Other)), (r"""(?sx) (.+?) # anything, followed by: (?: (?<=\n)(?=[%#]) | # an eval or comment line (?=</?[%&]) | # a substitution or block or # call start or end # - don't consume (\\\n) | # an escaped newline \Z # end of string )""", bygroups(using(HtmlLexer), Operator)), ] } def analyse_text(text): result = 0.0 if re.search(r'</%(class|doc|init)>', text) is not None: result = 1.0 elif re.search(r'<&.+&>', text, re.DOTALL) is not None: result = 0.11 return result class MakoLexer(RegexLexer): """ Generic mako templates lexer. Code that isn't Mako markup is yielded as `Token.Other`. .. versionadded:: 0.7 """ name = 'Mako' url = 'http://www.makotemplates.org/' aliases = ['mako'] filenames = ['*.mao'] mimetypes = ['application/x-mako'] tokens = { 'root': [ (r'(\s*)(%)(\s*end(?:\w+))(\n|\Z)', bygroups(Text.Whitespace, Comment.Preproc, Keyword, Other)), (r'(\s*)(%)([^\n]*)(\n|\Z)', bygroups(Text.Whitespace, Comment.Preproc, using(PythonLexer), Other)), (r'(\s*)(##[^\n]*)(\n|\Z)', bygroups(Text.Whitespace, Comment.Single, Text.Whitespace)), (r'(?s)<%doc>.*?</%doc>', Comment.Multiline), (r'(<%)([\w.:]+)', bygroups(Comment.Preproc, Name.Builtin), 'tag'), (r'(</%)([\w.:]+)(>)', bygroups(Comment.Preproc, Name.Builtin, Comment.Preproc)), (r'<%(?=([\w.:]+))', Comment.Preproc, 'ondeftags'), (r'(?s)(<%(?:!?))(.*?)(%>)', bygroups(Comment.Preproc, using(PythonLexer), Comment.Preproc)), (r'(\$\{)(.*?)(\})', bygroups(Comment.Preproc, using(PythonLexer), Comment.Preproc)), (r'''(?sx) (.+?) # anything, followed by: (?: (?<=\n)(?=%|\#\#) | # an eval or comment line (?=\#\*) | # multiline comment (?=</?%) | # a python block # call start or end (?=\$\{) | # a substitution (?<=\n)(?=\s*%) | # - don't consume (\\\n) | # an escaped newline \Z # end of string ) ''', bygroups(Other, Operator)), (r'\s+', Text), ], 'ondeftags': [ (r'<%', Comment.Preproc), (r'(?<=<%)(include|inherit|namespace|page)', Name.Builtin), include('tag'), ], 'tag': [ (r'((?:\w+)\s*=)(\s*)(".*?")', bygroups(Name.Attribute, Text, String)), (r'/?\s*>', Comment.Preproc, '#pop'), (r'\s+', Text), ], 'attr': [ ('".*?"', String, '#pop'), ("'.*?'", String, '#pop'), (r'[^\s>]+', String, '#pop'), ], } class MakoHtmlLexer(DelegatingLexer): """ Subclass of the `MakoLexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 0.7 """ name = 'HTML+Mako' aliases = ['html+mako'] mimetypes = ['text/html+mako'] def __init__(self, **options): super().__init__(HtmlLexer, MakoLexer, **options) class MakoXmlLexer(DelegatingLexer): """ Subclass of the `MakoLexer` that highlights unlexed data with the `XmlLexer`. .. versionadded:: 0.7 """ name = 'XML+Mako' aliases = ['xml+mako'] mimetypes = ['application/xml+mako'] def __init__(self, **options): super().__init__(XmlLexer, MakoLexer, **options) class MakoJavascriptLexer(DelegatingLexer): """ Subclass of the `MakoLexer` that highlights unlexed data with the `JavascriptLexer`. .. versionadded:: 0.7 """ name = 'JavaScript+Mako' aliases = ['javascript+mako', 'js+mako'] mimetypes = ['application/x-javascript+mako', 'text/x-javascript+mako', 'text/javascript+mako'] def __init__(self, **options): super().__init__(JavascriptLexer, MakoLexer, **options) class MakoCssLexer(DelegatingLexer): """ Subclass of the `MakoLexer` that highlights unlexed data with the `CssLexer`. .. versionadded:: 0.7 """ name = 'CSS+Mako' aliases = ['css+mako'] mimetypes = ['text/css+mako'] def __init__(self, **options): super().__init__(CssLexer, MakoLexer, **options) # Genshi and Cheetah lexers courtesy of Matt Good. class CheetahPythonLexer(Lexer): """ Lexer for handling Cheetah's special $ tokens in Python syntax. """ def get_tokens_unprocessed(self, text): pylexer = PythonLexer(**self.options) for pos, type_, value in pylexer.get_tokens_unprocessed(text): if type_ == Token.Error and value == '$': type_ = Comment.Preproc yield pos, type_, value class CheetahLexer(RegexLexer): """ Generic cheetah templates lexer. Code that isn't Cheetah markup is yielded as `Token.Other`. This also works for `spitfire templates`_ which use the same syntax. .. _spitfire templates: http://code.google.com/p/spitfire/ """ name = 'Cheetah' url = 'http://www.cheetahtemplate.org/' aliases = ['cheetah', 'spitfire'] filenames = ['*.tmpl', '*.spt'] mimetypes = ['application/x-cheetah', 'application/x-spitfire'] tokens = { 'root': [ (r'(##[^\n]*)$', (bygroups(Comment))), (r'#[*](.|\n)*?[*]#', Comment), (r'#end[^#\n]*(?:#|$)', Comment.Preproc), (r'#slurp$', Comment.Preproc), (r'(#[a-zA-Z]+)([^#\n]*)(#|$)', (bygroups(Comment.Preproc, using(CheetahPythonLexer), Comment.Preproc))), # TODO support other Python syntax like $foo['bar'] (r'(\$)([a-zA-Z_][\w.]*\w)', bygroups(Comment.Preproc, using(CheetahPythonLexer))), (r'(?s)(\$\{!?)(.*?)(\})', bygroups(Comment.Preproc, using(CheetahPythonLexer), Comment.Preproc)), (r'''(?sx) (.+?) # anything, followed by: (?: (?=\#[#a-zA-Z]*) | # an eval comment (?=\$[a-zA-Z_{]) | # a substitution \Z # end of string ) ''', Other), (r'\s+', Text), ], } class CheetahHtmlLexer(DelegatingLexer): """ Subclass of the `CheetahLexer` that highlights unlexed data with the `HtmlLexer`. """ name = 'HTML+Cheetah' aliases = ['html+cheetah', 'html+spitfire', 'htmlcheetah'] mimetypes = ['text/html+cheetah', 'text/html+spitfire'] def __init__(self, **options): super().__init__(HtmlLexer, CheetahLexer, **options) class CheetahXmlLexer(DelegatingLexer): """ Subclass of the `CheetahLexer` that highlights unlexed data with the `XmlLexer`. """ name = 'XML+Cheetah' aliases = ['xml+cheetah', 'xml+spitfire'] mimetypes = ['application/xml+cheetah', 'application/xml+spitfire'] def __init__(self, **options): super().__init__(XmlLexer, CheetahLexer, **options) class CheetahJavascriptLexer(DelegatingLexer): """ Subclass of the `CheetahLexer` that highlights unlexed data with the `JavascriptLexer`. """ name = 'JavaScript+Cheetah' aliases = ['javascript+cheetah', 'js+cheetah', 'javascript+spitfire', 'js+spitfire'] mimetypes = ['application/x-javascript+cheetah', 'text/x-javascript+cheetah', 'text/javascript+cheetah', 'application/x-javascript+spitfire', 'text/x-javascript+spitfire', 'text/javascript+spitfire'] def __init__(self, **options): super().__init__(JavascriptLexer, CheetahLexer, **options) class GenshiTextLexer(RegexLexer): """ A lexer that highlights genshi text templates. """ name = 'Genshi Text' url = 'http://genshi.edgewall.org/' aliases = ['genshitext'] mimetypes = ['application/x-genshi-text', 'text/x-genshi'] tokens = { 'root': [ (r'[^#$\s]+', Other), (r'^(\s*)(##.*)$', bygroups(Text, Comment)), (r'^(\s*)(#)', bygroups(Text, Comment.Preproc), 'directive'), include('variable'), (r'[#$\s]', Other), ], 'directive': [ (r'\n', Text, '#pop'), (r'(?:def|for|if)\s+.*', using(PythonLexer), '#pop'), (r'(choose|when|with)([^\S\n]+)(.*)', bygroups(Keyword, Text, using(PythonLexer)), '#pop'), (r'(choose|otherwise)\b', Keyword, '#pop'), (r'(end\w*)([^\S\n]*)(.*)', bygroups(Keyword, Text, Comment), '#pop'), ], 'variable': [ (r'(?<!\$)(\$\{)(.+?)(\})', bygroups(Comment.Preproc, using(PythonLexer), Comment.Preproc)), (r'(?<!\$)(\$)([a-zA-Z_][\w.]*)', Name.Variable), ] } class GenshiMarkupLexer(RegexLexer): """ Base lexer for Genshi markup, used by `HtmlGenshiLexer` and `GenshiLexer`. """ flags = re.DOTALL tokens = { 'root': [ (r'[^<$]+', Other), (r'(<\?python)(.*?)(\?>)', bygroups(Comment.Preproc, using(PythonLexer), Comment.Preproc)), # yield style and script blocks as Other (r'<\s*(script|style)\s*.*?>.*?<\s*/\1\s*>', Other), (r'<\s*py:[a-zA-Z0-9]+', Name.Tag, 'pytag'), (r'<\s*[a-zA-Z0-9:.]+', Name.Tag, 'tag'), include('variable'), (r'[<$]', Other), ], 'pytag': [ (r'\s+', Text), (r'[\w:-]+\s*=', Name.Attribute, 'pyattr'), (r'/?\s*>', Name.Tag, '#pop'), ], 'pyattr': [ ('(")(.*?)(")', bygroups(String, using(PythonLexer), String), '#pop'), ("(')(.*?)(')", bygroups(String, using(PythonLexer), String), '#pop'), (r'[^\s>]+', String, '#pop'), ], 'tag': [ (r'\s+', Text), (r'py:[\w-]+\s*=', Name.Attribute, 'pyattr'), (r'[\w:-]+\s*=', Name.Attribute, 'attr'), (r'/?\s*>', Name.Tag, '#pop'), ], 'attr': [ ('"', String, 'attr-dstring'), ("'", String, 'attr-sstring'), (r'[^\s>]*', String, '#pop') ], 'attr-dstring': [ ('"', String, '#pop'), include('strings'), ("'", String) ], 'attr-sstring': [ ("'", String, '#pop'), include('strings'), ("'", String) ], 'strings': [ ('[^"\'$]+', String), include('variable') ], 'variable': [ (r'(?<!\$)(\$\{)(.+?)(\})', bygroups(Comment.Preproc, using(PythonLexer), Comment.Preproc)), (r'(?<!\$)(\$)([a-zA-Z_][\w\.]*)', Name.Variable), ] } class HtmlGenshiLexer(DelegatingLexer): """ A lexer that highlights `genshi <http://genshi.edgewall.org/>`_ and `kid <http://kid-templating.org/>`_ kid HTML templates. """ name = 'HTML+Genshi' aliases = ['html+genshi', 'html+kid'] alias_filenames = ['*.html', '*.htm', '*.xhtml'] mimetypes = ['text/html+genshi'] def __init__(self, **options): super().__init__(HtmlLexer, GenshiMarkupLexer, **options) def analyse_text(text): rv = 0.0 if re.search(r'\$\{.*?\}', text) is not None: rv += 0.2 if re.search(r'py:(.*?)=["\']', text) is not None: rv += 0.2 return rv + HtmlLexer.analyse_text(text) - 0.01 class GenshiLexer(DelegatingLexer): """ A lexer that highlights `genshi <http://genshi.edgewall.org/>`_ and `kid <http://kid-templating.org/>`_ kid XML templates. """ name = 'Genshi' aliases = ['genshi', 'kid', 'xml+genshi', 'xml+kid'] filenames = ['*.kid'] alias_filenames = ['*.xml'] mimetypes = ['application/x-genshi', 'application/x-kid'] def __init__(self, **options): super().__init__(XmlLexer, GenshiMarkupLexer, **options) def analyse_text(text): rv = 0.0 if re.search(r'\$\{.*?\}', text) is not None: rv += 0.2 if re.search(r'py:(.*?)=["\']', text) is not None: rv += 0.2 return rv + XmlLexer.analyse_text(text) - 0.01 class JavascriptGenshiLexer(DelegatingLexer): """ A lexer that highlights javascript code in genshi text templates. """ name = 'JavaScript+Genshi Text' aliases = ['js+genshitext', 'js+genshi', 'javascript+genshitext', 'javascript+genshi'] alias_filenames = ['*.js'] mimetypes = ['application/x-javascript+genshi', 'text/x-javascript+genshi', 'text/javascript+genshi'] def __init__(self, **options): super().__init__(JavascriptLexer, GenshiTextLexer, **options) def analyse_text(text): return GenshiLexer.analyse_text(text) - 0.05 class CssGenshiLexer(DelegatingLexer): """ A lexer that highlights CSS definitions in genshi text templates. """ name = 'CSS+Genshi Text' aliases = ['css+genshitext', 'css+genshi'] alias_filenames = ['*.css'] mimetypes = ['text/css+genshi'] def __init__(self, **options): super().__init__(CssLexer, GenshiTextLexer, **options) def analyse_text(text): return GenshiLexer.analyse_text(text) - 0.05 class RhtmlLexer(DelegatingLexer): """ Subclass of the ERB lexer that highlights the unlexed data with the html lexer. Nested Javascript and CSS is highlighted too. """ name = 'RHTML' aliases = ['rhtml', 'html+erb', 'html+ruby'] filenames = ['*.rhtml'] alias_filenames = ['*.html', '*.htm', '*.xhtml'] mimetypes = ['text/html+ruby'] def __init__(self, **options): super().__init__(HtmlLexer, ErbLexer, **options) def analyse_text(text): rv = ErbLexer.analyse_text(text) - 0.01 if html_doctype_matches(text): # one more than the XmlErbLexer returns rv += 0.5 return rv class XmlErbLexer(DelegatingLexer): """ Subclass of `ErbLexer` which highlights data outside preprocessor directives with the `XmlLexer`. """ name = 'XML+Ruby' aliases = ['xml+ruby', 'xml+erb'] alias_filenames = ['*.xml'] mimetypes = ['application/xml+ruby'] def __init__(self, **options): super().__init__(XmlLexer, ErbLexer, **options) def analyse_text(text): rv = ErbLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class CssErbLexer(DelegatingLexer): """ Subclass of `ErbLexer` which highlights unlexed data with the `CssLexer`. """ name = 'CSS+Ruby' aliases = ['css+ruby', 'css+erb'] alias_filenames = ['*.css'] mimetypes = ['text/css+ruby'] def __init__(self, **options): super().__init__(CssLexer, ErbLexer, **options) def analyse_text(text): return ErbLexer.analyse_text(text) - 0.05 class JavascriptErbLexer(DelegatingLexer): """ Subclass of `ErbLexer` which highlights unlexed data with the `JavascriptLexer`. """ name = 'JavaScript+Ruby' aliases = ['javascript+ruby', 'js+ruby', 'javascript+erb', 'js+erb'] alias_filenames = ['*.js'] mimetypes = ['application/x-javascript+ruby', 'text/x-javascript+ruby', 'text/javascript+ruby'] def __init__(self, **options): super().__init__(JavascriptLexer, ErbLexer, **options) def analyse_text(text): return ErbLexer.analyse_text(text) - 0.05 class HtmlPhpLexer(DelegatingLexer): """ Subclass of `PhpLexer` that highlights unhandled data with the `HtmlLexer`. Nested Javascript and CSS is highlighted too. """ name = 'HTML+PHP' aliases = ['html+php'] filenames = ['*.phtml'] alias_filenames = ['*.php', '*.html', '*.htm', '*.xhtml', '*.php[345]'] mimetypes = ['application/x-php', 'application/x-httpd-php', 'application/x-httpd-php3', 'application/x-httpd-php4', 'application/x-httpd-php5'] def __init__(self, **options): super().__init__(HtmlLexer, PhpLexer, **options) def analyse_text(text): rv = PhpLexer.analyse_text(text) - 0.01 if html_doctype_matches(text): rv += 0.5 return rv class XmlPhpLexer(DelegatingLexer): """ Subclass of `PhpLexer` that highlights unhandled data with the `XmlLexer`. """ name = 'XML+PHP' aliases = ['xml+php'] alias_filenames = ['*.xml', '*.php', '*.php[345]'] mimetypes = ['application/xml+php'] def __init__(self, **options): super().__init__(XmlLexer, PhpLexer, **options) def analyse_text(text): rv = PhpLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class CssPhpLexer(DelegatingLexer): """ Subclass of `PhpLexer` which highlights unmatched data with the `CssLexer`. """ name = 'CSS+PHP' aliases = ['css+php'] alias_filenames = ['*.css'] mimetypes = ['text/css+php'] def __init__(self, **options): super().__init__(CssLexer, PhpLexer, **options) def analyse_text(text): return PhpLexer.analyse_text(text) - 0.05 class JavascriptPhpLexer(DelegatingLexer): """ Subclass of `PhpLexer` which highlights unmatched data with the `JavascriptLexer`. """ name = 'JavaScript+PHP' aliases = ['javascript+php', 'js+php'] alias_filenames = ['*.js'] mimetypes = ['application/x-javascript+php', 'text/x-javascript+php', 'text/javascript+php'] def __init__(self, **options): super().__init__(JavascriptLexer, PhpLexer, **options) def analyse_text(text): return PhpLexer.analyse_text(text) class HtmlSmartyLexer(DelegatingLexer): """ Subclass of the `SmartyLexer` that highlights unlexed data with the `HtmlLexer`. Nested Javascript and CSS is highlighted too. """ name = 'HTML+Smarty' aliases = ['html+smarty'] alias_filenames = ['*.html', '*.htm', '*.xhtml', '*.tpl'] mimetypes = ['text/html+smarty'] def __init__(self, **options): super().__init__(HtmlLexer, SmartyLexer, **options) def analyse_text(text): rv = SmartyLexer.analyse_text(text) - 0.01 if html_doctype_matches(text): rv += 0.5 return rv class XmlSmartyLexer(DelegatingLexer): """ Subclass of the `SmartyLexer` that highlights unlexed data with the `XmlLexer`. """ name = 'XML+Smarty' aliases = ['xml+smarty'] alias_filenames = ['*.xml', '*.tpl'] mimetypes = ['application/xml+smarty'] def __init__(self, **options): super().__init__(XmlLexer, SmartyLexer, **options) def analyse_text(text): rv = SmartyLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class CssSmartyLexer(DelegatingLexer): """ Subclass of the `SmartyLexer` that highlights unlexed data with the `CssLexer`. """ name = 'CSS+Smarty' aliases = ['css+smarty'] alias_filenames = ['*.css', '*.tpl'] mimetypes = ['text/css+smarty'] def __init__(self, **options): super().__init__(CssLexer, SmartyLexer, **options) def analyse_text(text): return SmartyLexer.analyse_text(text) - 0.05 class JavascriptSmartyLexer(DelegatingLexer): """ Subclass of the `SmartyLexer` that highlights unlexed data with the `JavascriptLexer`. """ name = 'JavaScript+Smarty' aliases = ['javascript+smarty', 'js+smarty'] alias_filenames = ['*.js', '*.tpl'] mimetypes = ['application/x-javascript+smarty', 'text/x-javascript+smarty', 'text/javascript+smarty'] def __init__(self, **options): super().__init__(JavascriptLexer, SmartyLexer, **options) def analyse_text(text): return SmartyLexer.analyse_text(text) - 0.05 class HtmlDjangoLexer(DelegatingLexer): """ Subclass of the `DjangoLexer` that highlights unlexed data with the `HtmlLexer`. Nested Javascript and CSS is highlighted too. """ name = 'HTML+Django/Jinja' aliases = ['html+django', 'html+jinja', 'htmldjango'] filenames = ['*.html.j2', '*.htm.j2', '*.xhtml.j2', '*.html.jinja2', '*.htm.jinja2', '*.xhtml.jinja2'] alias_filenames = ['*.html', '*.htm', '*.xhtml'] mimetypes = ['text/html+django', 'text/html+jinja'] def __init__(self, **options): super().__init__(HtmlLexer, DjangoLexer, **options) def analyse_text(text): rv = DjangoLexer.analyse_text(text) - 0.01 if html_doctype_matches(text): rv += 0.5 return rv class XmlDjangoLexer(DelegatingLexer): """ Subclass of the `DjangoLexer` that highlights unlexed data with the `XmlLexer`. """ name = 'XML+Django/Jinja' aliases = ['xml+django', 'xml+jinja'] filenames = ['*.xml.j2', '*.xml.jinja2'] alias_filenames = ['*.xml'] mimetypes = ['application/xml+django', 'application/xml+jinja'] def __init__(self, **options): super().__init__(XmlLexer, DjangoLexer, **options) def analyse_text(text): rv = DjangoLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class CssDjangoLexer(DelegatingLexer): """ Subclass of the `DjangoLexer` that highlights unlexed data with the `CssLexer`. """ name = 'CSS+Django/Jinja' aliases = ['css+django', 'css+jinja'] filenames = ['*.css.j2', '*.css.jinja2'] alias_filenames = ['*.css'] mimetypes = ['text/css+django', 'text/css+jinja'] def __init__(self, **options): super().__init__(CssLexer, DjangoLexer, **options) def analyse_text(text): return DjangoLexer.analyse_text(text) - 0.05 class JavascriptDjangoLexer(DelegatingLexer): """ Subclass of the `DjangoLexer` that highlights unlexed data with the `JavascriptLexer`. """ name = 'JavaScript+Django/Jinja' aliases = ['javascript+django', 'js+django', 'javascript+jinja', 'js+jinja'] filenames = ['*.js.j2', '*.js.jinja2'] alias_filenames = ['*.js'] mimetypes = ['application/x-javascript+django', 'application/x-javascript+jinja', 'text/x-javascript+django', 'text/x-javascript+jinja', 'text/javascript+django', 'text/javascript+jinja'] def __init__(self, **options): super().__init__(JavascriptLexer, DjangoLexer, **options) def analyse_text(text): return DjangoLexer.analyse_text(text) - 0.05 class JspRootLexer(RegexLexer): """ Base for the `JspLexer`. Yields `Token.Other` for area outside of JSP tags. .. versionadded:: 0.7 """ tokens = { 'root': [ (r'<%\S?', Keyword, 'sec'), # FIXME: I want to make these keywords but still parse attributes. (r'</?jsp:(forward|getProperty|include|plugin|setProperty|useBean).*?>', Keyword), (r'[^<]+', Other), (r'<', Other), ], 'sec': [ (r'%>', Keyword, '#pop'), # note: '\w\W' != '.' without DOTALL. (r'[\w\W]+?(?=%>|\Z)', using(JavaLexer)), ], } class JspLexer(DelegatingLexer): """ Lexer for Java Server Pages. .. versionadded:: 0.7 """ name = 'Java Server Page' aliases = ['jsp'] filenames = ['*.jsp'] mimetypes = ['application/x-jsp'] def __init__(self, **options): super().__init__(XmlLexer, JspRootLexer, **options) def analyse_text(text): rv = JavaLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 if '<%' in text and '%>' in text: rv += 0.1 return rv class EvoqueLexer(RegexLexer): """ For files using the Evoque templating system. .. versionadded:: 1.1 """ name = 'Evoque' aliases = ['evoque'] filenames = ['*.evoque'] mimetypes = ['application/x-evoque'] flags = re.DOTALL tokens = { 'root': [ (r'[^#$]+', Other), (r'#\[', Comment.Multiline, 'comment'), (r'\$\$', Other), # svn keywords (r'\$\w+:[^$\n]*\$', Comment.Multiline), # directives: begin, end (r'(\$)(begin|end)(\{(%)?)(.*?)((?(4)%)\})', bygroups(Punctuation, Name.Builtin, Punctuation, None, String, Punctuation)), # directives: evoque, overlay # see doc for handling first name arg: /directives/evoque/ # + minor inconsistency: the "name" in e.g. $overlay{name=site_base} # should be using(PythonLexer), not passed out as String (r'(\$)(evoque|overlay)(\{(%)?)(\s*[#\w\-"\'.]+)?' r'(.*?)((?(4)%)\})', bygroups(Punctuation, Name.Builtin, Punctuation, None, String, using(PythonLexer), Punctuation)), # directives: if, for, prefer, test (r'(\$)(\w+)(\{(%)?)(.*?)((?(4)%)\})', bygroups(Punctuation, Name.Builtin, Punctuation, None, using(PythonLexer), Punctuation)), # directive clauses (no {} expression) (r'(\$)(else|rof|fi)', bygroups(Punctuation, Name.Builtin)), # expressions (r'(\$\{(%)?)(.*?)((!)(.*?))?((?(2)%)\})', bygroups(Punctuation, None, using(PythonLexer), Name.Builtin, None, None, Punctuation)), (r'#', Other), ], 'comment': [ (r'[^\]#]', Comment.Multiline), (r'#\[', Comment.Multiline, '#push'), (r'\]#', Comment.Multiline, '#pop'), (r'[\]#]', Comment.Multiline) ], } def analyse_text(text): """Evoque templates use $evoque, which is unique.""" if '$evoque' in text: return 1 class EvoqueHtmlLexer(DelegatingLexer): """ Subclass of the `EvoqueLexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 1.1 """ name = 'HTML+Evoque' aliases = ['html+evoque'] filenames = ['*.html'] mimetypes = ['text/html+evoque'] def __init__(self, **options): super().__init__(HtmlLexer, EvoqueLexer, **options) def analyse_text(text): return EvoqueLexer.analyse_text(text) class EvoqueXmlLexer(DelegatingLexer): """ Subclass of the `EvoqueLexer` that highlights unlexed data with the `XmlLexer`. .. versionadded:: 1.1 """ name = 'XML+Evoque' aliases = ['xml+evoque'] filenames = ['*.xml'] mimetypes = ['application/xml+evoque'] def __init__(self, **options): super().__init__(XmlLexer, EvoqueLexer, **options) def analyse_text(text): return EvoqueLexer.analyse_text(text) class ColdfusionLexer(RegexLexer): """ Coldfusion statements """ name = 'cfstatement' aliases = ['cfs'] filenames = [] mimetypes = [] flags = re.IGNORECASE tokens = { 'root': [ (r'//.*?\n', Comment.Single), (r'/\*(?:.|\n)*?\*/', Comment.Multiline), (r'\+\+|--', Operator), (r'[-+*/^&=!]', Operator), (r'<=|>=|<|>|==', Operator), (r'mod\b', Operator), (r'(eq|lt|gt|lte|gte|not|is|and|or)\b', Operator), (r'\|\||&&', Operator), (r'\?', Operator), (r'"', String.Double, 'string'), # There is a special rule for allowing html in single quoted # strings, evidently. (r"'.*?'", String.Single), (r'\d+', Number), (r'(if|else|len|var|xml|default|break|switch|component|property|function|do|' r'try|catch|in|continue|for|return|while|required|any|array|binary|boolean|' r'component|date|guid|numeric|query|string|struct|uuid|case)\b', Keyword), (r'(true|false|null)\b', Keyword.Constant), (r'(application|session|client|cookie|super|this|variables|arguments)\b', Name.Constant), (r'([a-z_$][\w.]*)(\s*)(\()', bygroups(Name.Function, Text, Punctuation)), (r'[a-z_$][\w.]*', Name.Variable), (r'[()\[\]{};:,.\\]', Punctuation), (r'\s+', Text), ], 'string': [ (r'""', String.Double), (r'#.+?#', String.Interp), (r'[^"#]+', String.Double), (r'#', String.Double), (r'"', String.Double, '#pop'), ], } class ColdfusionMarkupLexer(RegexLexer): """ Coldfusion markup only """ name = 'Coldfusion' aliases = ['cf'] filenames = [] mimetypes = [] tokens = { 'root': [ (r'[^<]+', Other), include('tags'), (r'<[^<>]*', Other), ], 'tags': [ (r'<!---', Comment.Multiline, 'cfcomment'), (r'(?s)<!--.*?-->', Comment), (r'<cfoutput.*?>', Name.Builtin, 'cfoutput'), (r'(?s)(<cfscript.*?>)(.+?)(</cfscript.*?>)', bygroups(Name.Builtin, using(ColdfusionLexer), Name.Builtin)), # negative lookbehind is for strings with embedded > (r'(?s)(</?cf(?:component|include|if|else|elseif|loop|return|' r'dbinfo|dump|abort|location|invoke|throw|file|savecontent|' r'mailpart|mail|header|content|zip|image|lock|argument|try|' r'catch|break|directory|http|set|function|param)\b)(.*?)((?<!\\)>)', bygroups(Name.Builtin, using(ColdfusionLexer), Name.Builtin)), ], 'cfoutput': [ (r'[^#<]+', Other), (r'(#)(.*?)(#)', bygroups(Punctuation, using(ColdfusionLexer), Punctuation)), # (r'<cfoutput.*?>', Name.Builtin, '#push'), (r'</cfoutput.*?>', Name.Builtin, '#pop'), include('tags'), (r'(?s)<[^<>]*', Other), (r'#', Other), ], 'cfcomment': [ (r'<!---', Comment.Multiline, '#push'), (r'--->', Comment.Multiline, '#pop'), (r'([^<-]|<(?!!---)|-(?!-->))+', Comment.Multiline), ], } class ColdfusionHtmlLexer(DelegatingLexer): """ Coldfusion markup in html """ name = 'Coldfusion HTML' aliases = ['cfm'] filenames = ['*.cfm', '*.cfml'] mimetypes = ['application/x-coldfusion'] def __init__(self, **options): super().__init__(HtmlLexer, ColdfusionMarkupLexer, **options) class ColdfusionCFCLexer(DelegatingLexer): """ Coldfusion markup/script components .. versionadded:: 2.0 """ name = 'Coldfusion CFC' aliases = ['cfc'] filenames = ['*.cfc'] mimetypes = [] def __init__(self, **options): super().__init__(ColdfusionHtmlLexer, ColdfusionLexer, **options) class SspLexer(DelegatingLexer): """ Lexer for Scalate Server Pages. .. versionadded:: 1.4 """ name = 'Scalate Server Page' aliases = ['ssp'] filenames = ['*.ssp'] mimetypes = ['application/x-ssp'] def __init__(self, **options): super().__init__(XmlLexer, JspRootLexer, **options) def analyse_text(text): rv = 0.0 if re.search(r'val \w+\s*:', text): rv += 0.6 if looks_like_xml(text): rv += 0.2 if '<%' in text and '%>' in text: rv += 0.1 return rv class TeaTemplateRootLexer(RegexLexer): """ Base for the `TeaTemplateLexer`. Yields `Token.Other` for area outside of code blocks. .. versionadded:: 1.5 """ tokens = { 'root': [ (r'<%\S?', Keyword, 'sec'), (r'[^<]+', Other), (r'<', Other), ], 'sec': [ (r'%>', Keyword, '#pop'), # note: '\w\W' != '.' without DOTALL. (r'[\w\W]+?(?=%>|\Z)', using(TeaLangLexer)), ], } class TeaTemplateLexer(DelegatingLexer): """ Lexer for `Tea Templates <http://teatrove.org/>`_. .. versionadded:: 1.5 """ name = 'Tea' aliases = ['tea'] filenames = ['*.tea'] mimetypes = ['text/x-tea'] def __init__(self, **options): super().__init__(XmlLexer, TeaTemplateRootLexer, **options) def analyse_text(text): rv = TeaLangLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 if '<%' in text and '%>' in text: rv += 0.1 return rv class LassoHtmlLexer(DelegatingLexer): """ Subclass of the `LassoLexer` which highlights unhandled data with the `HtmlLexer`. Nested JavaScript and CSS is also highlighted. .. versionadded:: 1.6 """ name = 'HTML+Lasso' aliases = ['html+lasso'] alias_filenames = ['*.html', '*.htm', '*.xhtml', '*.lasso', '*.lasso[89]', '*.incl', '*.inc', '*.las'] mimetypes = ['text/html+lasso', 'application/x-httpd-lasso', 'application/x-httpd-lasso[89]'] def __init__(self, **options): super().__init__(HtmlLexer, LassoLexer, **options) def analyse_text(text): rv = LassoLexer.analyse_text(text) - 0.01 if html_doctype_matches(text): # same as HTML lexer rv += 0.5 return rv class LassoXmlLexer(DelegatingLexer): """ Subclass of the `LassoLexer` which highlights unhandled data with the `XmlLexer`. .. versionadded:: 1.6 """ name = 'XML+Lasso' aliases = ['xml+lasso'] alias_filenames = ['*.xml', '*.lasso', '*.lasso[89]', '*.incl', '*.inc', '*.las'] mimetypes = ['application/xml+lasso'] def __init__(self, **options): super().__init__(XmlLexer, LassoLexer, **options) def analyse_text(text): rv = LassoLexer.analyse_text(text) - 0.01 if looks_like_xml(text): rv += 0.4 return rv class LassoCssLexer(DelegatingLexer): """ Subclass of the `LassoLexer` which highlights unhandled data with the `CssLexer`. .. versionadded:: 1.6 """ name = 'CSS+Lasso' aliases = ['css+lasso'] alias_filenames = ['*.css'] mimetypes = ['text/css+lasso'] def __init__(self, **options): options['requiredelimiters'] = True super().__init__(CssLexer, LassoLexer, **options) def analyse_text(text): rv = LassoLexer.analyse_text(text) - 0.05 if re.search(r'\w+:[^;]+;', text): rv += 0.1 if 'padding:' in text: rv += 0.1 return rv class LassoJavascriptLexer(DelegatingLexer): """ Subclass of the `LassoLexer` which highlights unhandled data with the `JavascriptLexer`. .. versionadded:: 1.6 """ name = 'JavaScript+Lasso' aliases = ['javascript+lasso', 'js+lasso'] alias_filenames = ['*.js'] mimetypes = ['application/x-javascript+lasso', 'text/x-javascript+lasso', 'text/javascript+lasso'] def __init__(self, **options): options['requiredelimiters'] = True super().__init__(JavascriptLexer, LassoLexer, **options) def analyse_text(text): rv = LassoLexer.analyse_text(text) - 0.05 return rv class HandlebarsLexer(RegexLexer): """ Generic handlebars template lexer. Highlights only the Handlebars template tags (stuff between `{{` and `}}`). Everything else is left for a delegating lexer. .. versionadded:: 2.0 """ name = "Handlebars" url = 'https://handlebarsjs.com/' aliases = ['handlebars'] tokens = { 'root': [ (r'[^{]+', Other), # Comment start {{! }} or {{!-- (r'\{\{!.*\}\}', Comment), # HTML Escaping open {{{expression (r'(\{\{\{)(\s*)', bygroups(Comment.Special, Text), 'tag'), # {{blockOpen {{#blockOpen {{/blockClose with optional tilde ~ (r'(\{\{)([#~/]+)([^\s}]*)', bygroups(Comment.Preproc, Number.Attribute, Number.Attribute), 'tag'), (r'(\{\{)(\s*)', bygroups(Comment.Preproc, Text), 'tag'), ], 'tag': [ (r'\s+', Text), # HTML Escaping close }}} (r'\}\}\}', Comment.Special, '#pop'), # blockClose}}, includes optional tilde ~ (r'(~?)(\}\})', bygroups(Number, Comment.Preproc), '#pop'), # {{opt=something}} (r'([^\s}]+)(=)', bygroups(Name.Attribute, Operator)), # Partials {{> ...}} (r'(>)(\s*)(@partial-block)', bygroups(Keyword, Text, Keyword)), (r'(#?>)(\s*)([\w-]+)', bygroups(Keyword, Text, Name.Variable)), (r'(>)(\s*)(\()', bygroups(Keyword, Text, Punctuation), 'dynamic-partial'), include('generic'), ], 'dynamic-partial': [ (r'\s+', Text), (r'\)', Punctuation, '#pop'), (r'(lookup)(\s+)(\.|this)(\s+)', bygroups(Keyword, Text, Name.Variable, Text)), (r'(lookup)(\s+)(\S+)', bygroups(Keyword, Text, using(this, state='variable'))), (r'[\w-]+', Name.Function), include('generic'), ], 'variable': [ (r'[()/@a-zA-Z][\w-]*', Name.Variable), (r'\.[\w-]+', Name.Variable), (r'(this\/|\.\/|(\.\.\/)+)[\w-]+', Name.Variable), ], 'generic': [ include('variable'), # borrowed from DjangoLexer (r':?"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r":?'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r"[0-9](\.[0-9]*)?(eE[+-][0-9])?[flFLdD]?|" r"0[xX][0-9a-fA-F]+[Ll]?", Number), ] } class HandlebarsHtmlLexer(DelegatingLexer): """ Subclass of the `HandlebarsLexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 2.0 """ name = "HTML+Handlebars" aliases = ["html+handlebars"] filenames = ['*.handlebars', '*.hbs'] mimetypes = ['text/html+handlebars', 'text/x-handlebars-template'] def __init__(self, **options): super().__init__(HtmlLexer, HandlebarsLexer, **options) class YamlJinjaLexer(DelegatingLexer): """ Subclass of the `DjangoLexer` that highlights unlexed data with the `YamlLexer`. Commonly used in Saltstack salt states. .. versionadded:: 2.0 """ name = 'YAML+Jinja' aliases = ['yaml+jinja', 'salt', 'sls'] filenames = ['*.sls', '*.yaml.j2', '*.yml.j2', '*.yaml.jinja2', '*.yml.jinja2'] mimetypes = ['text/x-yaml+jinja', 'text/x-sls'] def __init__(self, **options): super().__init__(YamlLexer, DjangoLexer, **options) class LiquidLexer(RegexLexer): """ Lexer for Liquid templates. .. versionadded:: 2.0 """ name = 'liquid' url = 'https://www.rubydoc.info/github/Shopify/liquid' aliases = ['liquid'] filenames = ['*.liquid'] tokens = { 'root': [ (r'[^{]+', Text), # tags and block tags (r'(\{%)(\s*)', bygroups(Punctuation, Whitespace), 'tag-or-block'), # output tags (r'(\{\{)(\s*)([^\s}]+)', bygroups(Punctuation, Whitespace, using(this, state = 'generic')), 'output'), (r'\{', Text) ], 'tag-or-block': [ # builtin logic blocks (r'(if|unless|elsif|case)(?=\s+)', Keyword.Reserved, 'condition'), (r'(when)(\s+)', bygroups(Keyword.Reserved, Whitespace), combined('end-of-block', 'whitespace', 'generic')), (r'(else)(\s*)(%\})', bygroups(Keyword.Reserved, Whitespace, Punctuation), '#pop'), # other builtin blocks (r'(capture)(\s+)([^\s%]+)(\s*)(%\})', bygroups(Name.Tag, Whitespace, using(this, state = 'variable'), Whitespace, Punctuation), '#pop'), (r'(comment)(\s*)(%\})', bygroups(Name.Tag, Whitespace, Punctuation), 'comment'), (r'(raw)(\s*)(%\})', bygroups(Name.Tag, Whitespace, Punctuation), 'raw'), # end of block (r'(end(case|unless|if))(\s*)(%\})', bygroups(Keyword.Reserved, None, Whitespace, Punctuation), '#pop'), (r'(end([^\s%]+))(\s*)(%\})', bygroups(Name.Tag, None, Whitespace, Punctuation), '#pop'), # builtin tags (assign and include are handled together with usual tags) (r'(cycle)(\s+)(?:([^\s:]*)(:))?(\s*)', bygroups(Name.Tag, Whitespace, using(this, state='generic'), Punctuation, Whitespace), 'variable-tag-markup'), # other tags or blocks (r'([^\s%]+)(\s*)', bygroups(Name.Tag, Whitespace), 'tag-markup') ], 'output': [ include('whitespace'), (r'\}\}', Punctuation, '#pop'), # end of output (r'\|', Punctuation, 'filters') ], 'filters': [ include('whitespace'), (r'\}\}', Punctuation, ('#pop', '#pop')), # end of filters and output (r'([^\s|:]+)(:?)(\s*)', bygroups(Name.Function, Punctuation, Whitespace), 'filter-markup') ], 'filter-markup': [ (r'\|', Punctuation, '#pop'), include('end-of-tag'), include('default-param-markup') ], 'condition': [ include('end-of-block'), include('whitespace'), (r'([^\s=!><]+)(\s*)([=!><]=?)(\s*)(\S+)(\s*)(%\})', bygroups(using(this, state = 'generic'), Whitespace, Operator, Whitespace, using(this, state = 'generic'), Whitespace, Punctuation)), (r'\b!', Operator), (r'\bnot\b', Operator.Word), (r'([\w.\'"]+)(\s+)(contains)(\s+)([\w.\'"]+)', bygroups(using(this, state = 'generic'), Whitespace, Operator.Word, Whitespace, using(this, state = 'generic'))), include('generic'), include('whitespace') ], 'generic-value': [ include('generic'), include('end-at-whitespace') ], 'operator': [ (r'(\s*)((=|!|>|<)=?)(\s*)', bygroups(Whitespace, Operator, None, Whitespace), '#pop'), (r'(\s*)(\bcontains\b)(\s*)', bygroups(Whitespace, Operator.Word, Whitespace), '#pop'), ], 'end-of-tag': [ (r'\}\}', Punctuation, '#pop') ], 'end-of-block': [ (r'%\}', Punctuation, ('#pop', '#pop')) ], 'end-at-whitespace': [ (r'\s+', Whitespace, '#pop') ], # states for unknown markup 'param-markup': [ include('whitespace'), # params with colons or equals (r'([^\s=:]+)(\s*)(=|:)', bygroups(Name.Attribute, Whitespace, Operator)), # explicit variables (r'(\{\{)(\s*)([^\s}])(\s*)(\}\})', bygroups(Punctuation, Whitespace, using(this, state = 'variable'), Whitespace, Punctuation)), include('string'), include('number'), include('keyword'), (r',', Punctuation) ], 'default-param-markup': [ include('param-markup'), (r'.', Text) # fallback for switches / variables / un-quoted strings / ... ], 'variable-param-markup': [ include('param-markup'), include('variable'), (r'.', Text) # fallback ], 'tag-markup': [ (r'%\}', Punctuation, ('#pop', '#pop')), # end of tag include('default-param-markup') ], 'variable-tag-markup': [ (r'%\}', Punctuation, ('#pop', '#pop')), # end of tag include('variable-param-markup') ], # states for different values types 'keyword': [ (r'\b(false|true)\b', Keyword.Constant) ], 'variable': [ (r'[a-zA-Z_]\w*', Name.Variable), (r'(?<=\w)\.(?=\w)', Punctuation) ], 'string': [ (r"'[^']*'", String.Single), (r'"[^"]*"', String.Double) ], 'number': [ (r'\d+\.\d+', Number.Float), (r'\d+', Number.Integer) ], 'generic': [ # decides for variable, string, keyword or number include('keyword'), include('string'), include('number'), include('variable') ], 'whitespace': [ (r'[ \t]+', Whitespace) ], # states for builtin blocks 'comment': [ (r'(\{%)(\s*)(endcomment)(\s*)(%\})', bygroups(Punctuation, Whitespace, Name.Tag, Whitespace, Punctuation), ('#pop', '#pop')), (r'.', Comment) ], 'raw': [ (r'[^{]+', Text), (r'(\{%)(\s*)(endraw)(\s*)(%\})', bygroups(Punctuation, Whitespace, Name.Tag, Whitespace, Punctuation), '#pop'), (r'\{', Text) ], } class TwigLexer(RegexLexer): """ Twig template lexer. It just highlights Twig code between the preprocessor directives, other data is left untouched by the lexer. .. versionadded:: 2.0 """ name = 'Twig' aliases = ['twig'] mimetypes = ['application/x-twig'] flags = re.M | re.S # Note that a backslash is included in the following two patterns # PHP uses a backslash as a namespace separator _ident_char = r'[\\\w-]|[^\x00-\x7f]' _ident_begin = r'(?:[\\_a-z]|[^\x00-\x7f])' _ident_end = r'(?:' + _ident_char + ')*' _ident_inner = _ident_begin + _ident_end tokens = { 'root': [ (r'[^{]+', Other), (r'\{\{', Comment.Preproc, 'var'), # twig comments (r'\{\#.*?\#\}', Comment), # raw twig blocks (r'(\{%)(-?\s*)(raw)(\s*-?)(%\})(.*?)' r'(\{%)(-?\s*)(endraw)(\s*-?)(%\})', bygroups(Comment.Preproc, Text, Keyword, Text, Comment.Preproc, Other, Comment.Preproc, Text, Keyword, Text, Comment.Preproc)), (r'(\{%)(-?\s*)(verbatim)(\s*-?)(%\})(.*?)' r'(\{%)(-?\s*)(endverbatim)(\s*-?)(%\})', bygroups(Comment.Preproc, Text, Keyword, Text, Comment.Preproc, Other, Comment.Preproc, Text, Keyword, Text, Comment.Preproc)), # filter blocks (r'(\{%%)(-?\s*)(filter)(\s+)(%s)' % _ident_inner, bygroups(Comment.Preproc, Text, Keyword, Text, Name.Function), 'tag'), (r'(\{%)(-?\s*)([a-zA-Z_]\w*)', bygroups(Comment.Preproc, Text, Keyword), 'tag'), (r'\{', Other), ], 'varnames': [ (r'(\|)(\s*)(%s)' % _ident_inner, bygroups(Operator, Text, Name.Function)), (r'(is)(\s+)(not)?(\s*)(%s)' % _ident_inner, bygroups(Keyword, Text, Keyword, Text, Name.Function)), (r'(?i)(true|false|none|null)\b', Keyword.Pseudo), (r'(in|not|and|b-and|or|b-or|b-xor|is' r'if|elseif|else|import' r'constant|defined|divisibleby|empty|even|iterable|odd|sameas' r'matches|starts\s+with|ends\s+with)\b', Keyword), (r'(loop|block|parent)\b', Name.Builtin), (_ident_inner, Name.Variable), (r'\.' + _ident_inner, Name.Variable), (r'\.[0-9]+', Number), (r':?"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r":?'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'([{}()\[\]+\-*/,:~%]|\.\.|\?|:|\*\*|\/\/|!=|[><=]=?)', Operator), (r"[0-9](\.[0-9]*)?(eE[+-][0-9])?[flFLdD]?|" r"0[xX][0-9a-fA-F]+[Ll]?", Number), ], 'var': [ (r'\s+', Text), (r'(-?)(\}\})', bygroups(Text, Comment.Preproc), '#pop'), include('varnames') ], 'tag': [ (r'\s+', Text), (r'(-?)(%\})', bygroups(Text, Comment.Preproc), '#pop'), include('varnames'), (r'.', Punctuation), ], } class TwigHtmlLexer(DelegatingLexer): """ Subclass of the `TwigLexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 2.0 """ name = "HTML+Twig" aliases = ["html+twig"] filenames = ['*.twig'] mimetypes = ['text/html+twig'] def __init__(self, **options): super().__init__(HtmlLexer, TwigLexer, **options) class Angular2Lexer(RegexLexer): """ Generic angular2 template lexer. Highlights only the Angular template tags (stuff between `{{` and `}}` and special attributes: '(event)=', '[property]=', '[(twoWayBinding)]='). Everything else is left for a delegating lexer. .. versionadded:: 2.1 """ name = "Angular2" url = 'https://angular.io/guide/template-syntax' aliases = ['ng2'] tokens = { 'root': [ (r'[^{([*#]+', Other), # {{meal.name}} (r'(\{\{)(\s*)', bygroups(Comment.Preproc, Text), 'ngExpression'), # (click)="deleteOrder()"; [value]="test"; [(twoWayTest)]="foo.bar" (r'([([]+)([\w:.-]+)([\])]+)(\s*)(=)(\s*)', bygroups(Punctuation, Name.Attribute, Punctuation, Text, Operator, Text), 'attr'), (r'([([]+)([\w:.-]+)([\])]+)(\s*)', bygroups(Punctuation, Name.Attribute, Punctuation, Text)), # *ngIf="..."; #f="ngForm" (r'([*#])([\w:.-]+)(\s*)(=)(\s*)', bygroups(Punctuation, Name.Attribute, Text, Operator, Text), 'attr'), (r'([*#])([\w:.-]+)(\s*)', bygroups(Punctuation, Name.Attribute, Text)), ], 'ngExpression': [ (r'\s+(\|\s+)?', Text), (r'\}\}', Comment.Preproc, '#pop'), # Literals (r':?(true|false)', String.Boolean), (r':?"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r":?'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r"[0-9](\.[0-9]*)?(eE[+-][0-9])?[flFLdD]?|" r"0[xX][0-9a-fA-F]+[Ll]?", Number), # Variabletext (r'[a-zA-Z][\w-]*(\(.*\))?', Name.Variable), (r'\.[\w-]+(\(.*\))?', Name.Variable), # inline If (r'(\?)(\s*)([^}\s]+)(\s*)(:)(\s*)([^}\s]+)(\s*)', bygroups(Operator, Text, String, Text, Operator, Text, String, Text)), ], 'attr': [ ('".*?"', String, '#pop'), ("'.*?'", String, '#pop'), (r'[^\s>]+', String, '#pop'), ], } class Angular2HtmlLexer(DelegatingLexer): """ Subclass of the `Angular2Lexer` that highlights unlexed data with the `HtmlLexer`. .. versionadded:: 2.0 """ name = "HTML + Angular2" aliases = ["html+ng2"] filenames = ['*.ng2'] def __init__(self, **options): super().__init__(HtmlLexer, Angular2Lexer, **options) class SqlJinjaLexer(DelegatingLexer): """ Templated SQL lexer. .. versionadded:: 2.13 """ name = 'SQL+Jinja' aliases = ['sql+jinja'] filenames = ['*.sql', '*.sql.j2', '*.sql.jinja2'] def __init__(self, **options): super().__init__(SqlLexer, DjangoLexer, **options) def analyse_text(text): rv = 0.0 # dbt's ref function if re.search(r'\{\{\s*ref\(.*\)\s*\}\}', text): rv += 0.4 # dbt's source function if re.search(r'\{\{\s*source\(.*\)\s*\}\}', text): rv += 0.25 # Jinja macro if re.search( r'\{%-?\s*macro \w+\(.*\)\s*-?%\}\s+.*\s+\{%-?\s*endmacro\s*-?%\}', text, re.S, ): rv += 0.15 return rv
72,695
Python
30.59322
106
0.487255
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/fift.py
""" pygments.lexers.fift ~~~~~~~~~~~~~~~~~~~~ Lexers for fift. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, include from pygments.token import Literal, Comment, Name, String, Number, Whitespace __all__ = ['FiftLexer'] class FiftLexer(RegexLexer): """ For Fift source code. """ name = 'Fift' aliases = ['fift', 'fif'] filenames = ['*.fif'] url = 'https://ton-blockchain.github.io/docs/fiftbase.pdf' tokens = { 'root': [ (r'\s+', Whitespace), include('comments'), (r'[\.+]?\"', String, 'string'), # numbers (r'0x[0-9a-fA-F]+', Number.Hex), (r'0b[01]+', Number.Bin), (r'-?[0-9]+("/"-?[0-9]+)?', Number.Decimal), # slices (r'b\{[01]+\}', Literal), (r'x\{[0-9a-fA-F_]+\}', Literal), # byte literal (r'B\{[0-9a-fA-F_]+\}', Literal), # treat anything as word (r'\S+', Name) ], 'string': [ (r'\\.', String.Escape), (r'\"', String, '#pop'), (r'[^\"\r\n\\]+', String) ], 'comments': [ (r'//.*', Comment.Singleline), (r'/\*', Comment.Multiline, 'comment'), ], 'comment': [ (r'[^/*]+', Comment.Multiline), (r'/\*', Comment.Multiline, '#push'), (r'\*/', Comment.Multiline, '#pop'), (r'[*/]', Comment.Multiline), ], }
1,621
Python
22.852941
77
0.436767
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/_qlik_builtins.py
""" pygments.lexers._qlik_builtins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Qlik builtins. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ # operators # see https://help.qlik.com/en-US/sense/August2021/Subsystems/Hub/Content/Sense_Hub/Scripting/Operators/operators.htm OPERATORS_LIST = { "words": [ # Bit operators "bitnot", "bitand", "bitor", "bitxor", # Logical operators "and", "or", "not", "xor", # Relational operators "precedes", "follows", # String operators "like", ], "symbols": [ # Bit operators ">>", "<<", # Logical operators # Numeric operators "+", "-", "/", "*", # Relational operators "<", "<=", ">", ">=", "=", "<>", # String operators "&", ], } # SCRIPT STATEMENTS # see https://help.qlik.com/en-US/sense/August2021/Subsystems/Hub/Content/Sense_Hub/Scripting/ STATEMENT_LIST = [ # control statements "for", "each", "in", "next", "do", "while", "until", "unless", "loop", "return", "switch", "case", "default", "if", "else", "endif", "then", "end", "exit", "script", "switch", # prefixes "Add", "Buffer", "Concatenate", "Crosstable", "First", "Generic", "Hierarchy", "HierarchyBelongsTo", "Inner", "IntervalMatch", "Join", "Keep", "Left", "Mapping", "Merge", "NoConcatenate", "Outer", "Partial reload", "Replace", "Right", "Sample", "Semantic", "Unless", "When", # regular statements "Alias", # alias ... as ... "as", "AutoNumber", "Binary", "Comment field", # comment fields ... using ... "Comment fields", # comment field ... with ... "using", "with", "Comment table", # comment table ... with ... "Comment tables", # comment tables ... using ... "Connect", "ODBC", # ODBC CONNECT TO ... "OLEBD", # OLEDB CONNECT TO ... "CUSTOM", # CUSTOM CONNECT TO ... "LIB", # LIB CONNECT TO ... "Declare", "Derive", "From", "explicit", "implicit", "Direct Query", "dimension", "measure", "Directory", "Disconnect", "Drop field", "Drop fields", "Drop table", "Drop tables", "Execute", "FlushLog", "Force", "capitalization", "case upper", "case lower", "case mixed", "Load", "distinct", "from", "inline", "resident", "from_field", "autogenerate", "extension", "where", "group by", "order by", "asc", "desc", "Let", "Loosen Table", "Map", "NullAsNull", "NullAsValue", "Qualify", "Rem", "Rename field", "Rename fields", "Rename table", "Rename tables", "Search", "include", "exclude", "Section", "access", "application", "Select", "Set", "Sleep", "SQL", "SQLColumns", "SQLTables", "SQLTypes", "Star", "Store", "Tag", "Trace", "Unmap", "Unqualify", "Untag", # Qualifiers "total", ] # Script functions # see https://help.qlik.com/en-US/sense/August2021/Subsystems/Hub/Content/Sense_Hub/Scripting/functions-in-scripts-chart-expressions.htm SCRIPT_FUNCTIONS = [ # Basic aggregation functions in the data load script "FirstSortedValue", "Max", "Min", "Mode", "Only", "Sum", # Counter aggregation functions in the data load script "Count", "MissingCount", "NullCount", "NumericCount", "TextCount", # Financial aggregation functions in the data load script "IRR", "XIRR", "NPV", "XNPV", # Statistical aggregation functions in the data load script "Avg", "Correl", "Fractile", "FractileExc", "Kurtosis", "LINEST_B" "LINEST_df", "LINEST_f", "LINEST_m", "LINEST_r2", "LINEST_seb", "LINEST_sem", "LINEST_sey", "LINEST_ssreg", "Linest_ssresid", "Median", "Skew", "Stdev", "Sterr", "STEYX", # Statistical test functions "Chi2Test_chi2", "Chi2Test_df", "Chi2Test_p", # Two independent samples t-tests "ttest_conf", "ttest_df", "ttest_dif", "ttest_lower", "ttest_sig", "ttest_sterr", "ttest_t", "ttest_upper", # Two independent weighted samples t-tests "ttestw_conf", "ttestw_df", "ttestw_dif", "ttestw_lower", "ttestw_sig", "ttestw_sterr", "ttestw_t", "ttestw_upper", # One sample t-tests "ttest1_conf", "ttest1_df", "ttest1_dif", "ttest1_lower", "ttest1_sig", "ttest1_sterr", "ttest1_t", "ttest1_upper", # One weighted sample t-tests "ttest1w_conf", "ttest1w_df", "ttest1w_dif", "ttest1w_lower", "ttest1w_sig", "ttest1w_sterr", "ttest1w_t", "ttest1w_upper", # One column format functions "ztest_conf", "ztest_dif", "ztest_sig", "ztest_sterr", "ztest_z", "ztest_lower", "ztest_upper", # Weighted two-column format functions "ztestw_conf", "ztestw_dif", "ztestw_lower", "ztestw_sig", "ztestw_sterr", "ztestw_upper", "ztestw_z", # String aggregation functions in the data load script "Concat", "FirstValue", "LastValue", "MaxString", "MinString", # Synthetic dimension functions "ValueList", "ValueLoop", # Color functions "ARGB", "HSL", "RGB", "Color", "Colormix1", "Colormix2", "SysColor", "ColorMapHue", "ColorMapJet", "black", "blue", "brown", "cyan", "darkgray", "green", "lightblue", "lightcyan", "lightgray", "lightgreen", "lightmagenta", "lightred", "magenta", "red", "white", "yellow", # Conditional functions "alt", "class", "coalesce", "if", "match", "mixmatch", "pick", "wildmatch", # Counter functions "autonumber", "autonumberhash128", "autonumberhash256", "IterNo", "RecNo", "RowNo", # Integer expressions of time "second", "minute", "hour", "day", "week", "month", "year", "weekyear", "weekday", # Timestamp functions "now", "today", "LocalTime", # Make functions "makedate", "makeweekdate", "maketime", # Other date functions "AddMonths", "AddYears", "yeartodate", # Timezone functions "timezone", "GMT", "UTC", "daylightsaving", "converttolocaltime", # Set time functions "setdateyear", "setdateyearmonth", # In... functions "inyear", "inyeartodate", "inquarter", "inquartertodate", "inmonth", "inmonthtodate", "inmonths", "inmonthstodate", "inweek", "inweektodate", "inlunarweek", "inlunarweektodate", "inday", "indaytotime", # Start ... end functions "yearstart", "yearend", "yearname", "quarterstart", "quarterend", "quartername", "monthstart", "monthend", "monthname", "monthsstart", "monthsend", "monthsname", "weekstart", "weekend", "weekname", "lunarweekstart", "lunarweekend", "lunarweekname", "daystart", "dayend", "dayname", # Day numbering functions "age", "networkdays", "firstworkdate", "lastworkdate", "daynumberofyear", "daynumberofquarter", # Exponential and logarithmic "exp", "log", "log10", "pow", "sqr", "sqrt", # Count functions "GetAlternativeCount", "GetExcludedCount", "GetNotSelectedCount", "GetPossibleCount", "GetSelectedCount", # Field and selection functions "GetCurrentSelections", "GetFieldSelections", "GetObjectDimension", "GetObjectField", "GetObjectMeasure", # File functions "Attribute", "ConnectString", "FileBaseName", "FileDir", "FileExtension", "FileName", "FilePath", "FileSize", "FileTime", "GetFolderPath", "QvdCreateTime", "QvdFieldName", "QvdNoOfFields", "QvdNoOfRecords", "QvdTableName", # Financial functions "FV", "nPer", "Pmt", "PV", "Rate", # Formatting functions "ApplyCodepage", "Date", "Dual", "Interval", "Money", "Num", "Time", "Timestamp", # General numeric functions "bitcount", "div", "fabs", "fact", "frac", "sign", # Combination and permutation functions "combin", "permut", # Modulo functions "fmod", "mod", # Parity functions "even", "odd", # Rounding functions "ceil", "floor", "round", # Geospatial functions "GeoAggrGeometry", "GeoBoundingBox", "GeoCountVertex", "GeoInvProjectGeometry", "GeoProjectGeometry", "GeoReduceGeometry", "GeoGetBoundingBox", "GeoGetPolygonCenter", "GeoMakePoint", "GeoProject", # Interpretation functions "Date#", "Interval#", "Money#", "Num#", "Text", "Time#", "Timestamp#", # Field functions "FieldIndex", "FieldValue", "FieldValueCount", # Inter-record functions in the data load script "Exists", "LookUp", "Peek", "Previous", # Logical functions "IsNum", "IsText", # Mapping functions "ApplyMap", "MapSubstring", # Mathematical functions "e", "false", "pi", "rand", "true", # NULL functions "EmptyIsNull", "IsNull", "Null", # Basic range functions "RangeMax", "RangeMaxString", "RangeMin", "RangeMinString", "RangeMode", "RangeOnly", "RangeSum", # Counter range functions "RangeCount", "RangeMissingCount", "RangeNullCount", "RangeNumericCount", "RangeTextCount", # Statistical range functions "RangeAvg", "RangeCorrel", "RangeFractile", "RangeKurtosis", "RangeSkew", "RangeStdev", # Financial range functions "RangeIRR", "RangeNPV", "RangeXIRR", "RangeXNPV", # Statistical distribution "CHIDIST", "CHIINV", "NORMDIST", "NORMINV", "TDIST", "TINV", "FDIST", "FINV", # String functions "Capitalize", "Chr", "Evaluate", "FindOneOf", "Hash128", "Hash160", "Hash256", "Index", "KeepChar", "Left", "Len", "LevenshteinDist", "Lower", "LTrim", "Mid", "Ord", "PurgeChar", "Repeat", "Replace", "Right", "RTrim", "SubField", "SubStringCount", "TextBetween", "Trim", "Upper", # System functions "Author", "ClientPlatform", "ComputerName", "DocumentName", "DocumentPath", "DocumentTitle", "EngineVersion", "GetCollationLocale", "GetObjectField", "GetRegistryString", "IsPartialReload", "OSUser", "ProductVersion", "ReloadTime", "StateName", # Table functions "FieldName", "FieldNumber", "NoOfFields", "NoOfRows", "NoOfTables", "TableName", "TableNumber", ] # System variables and constants # see https://help.qlik.com/en-US/sense/August2021/Subsystems/Hub/Content/Sense_Hub/Scripting/work-with-variables-in-data-load-editor.htm CONSTANT_LIST = [ # System Variables "floppy", "cd", "include", "must_include", "hideprefix", "hidesuffix", "qvpath", "qvroot", "QvWorkPath", "QvWorkRoot", "StripComments", "Verbatim", "OpenUrlTimeout", "WinPath", "WinRoot", "CollationLocale", "CreateSearchIndexOnReload", # value handling variables "NullDisplay", "NullInterpret", "NullValue", "OtherSymbol", # Currency formatting "MoneyDecimalSep", "MoneyFormat", "MoneyThousandSep", # Number formatting "DecimalSep", "ThousandSep", "NumericalAbbreviation", # Time formatting "DateFormat", "TimeFormat", "TimestampFormat", "MonthNames", "LongMonthNames", "DayNames", "LongDayNames", "FirstWeekDay", "BrokenWeeks", "ReferenceDay", "FirstMonthOfYear", # Error variables "errormode", "scripterror", "scripterrorcount", "scripterrorlist", # Other "null", ]
12,595
Python
17.884558
139
0.541882
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/special.py
""" pygments.lexers.special ~~~~~~~~~~~~~~~~~~~~~~~ Special lexers. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import ast from pygments.lexer import Lexer, line_re from pygments.token import Token, Error, Text, Generic from pygments.util import get_choice_opt __all__ = ['TextLexer', 'OutputLexer', 'RawTokenLexer'] class TextLexer(Lexer): """ "Null" lexer, doesn't highlight anything. """ name = 'Text only' aliases = ['text'] filenames = ['*.txt'] mimetypes = ['text/plain'] priority = 0.01 def get_tokens_unprocessed(self, text): yield 0, Text, text def analyse_text(text): return TextLexer.priority class OutputLexer(Lexer): """ Simple lexer that highlights everything as ``Token.Generic.Output``. .. versionadded:: 2.10 """ name = 'Text output' aliases = ['output'] def get_tokens_unprocessed(self, text): yield 0, Generic.Output, text _ttype_cache = {} class RawTokenLexer(Lexer): """ Recreate a token stream formatted with the `RawTokenFormatter`. Additional options accepted: `compress` If set to ``"gz"`` or ``"bz2"``, decompress the token stream with the given compression algorithm before lexing (default: ``""``). """ name = 'Raw token data' aliases = [] filenames = [] mimetypes = ['application/x-pygments-tokens'] def __init__(self, **options): self.compress = get_choice_opt(options, 'compress', ['', 'none', 'gz', 'bz2'], '') Lexer.__init__(self, **options) def get_tokens(self, text): if self.compress: if isinstance(text, str): text = text.encode('latin1') try: if self.compress == 'gz': import gzip text = gzip.decompress(text) elif self.compress == 'bz2': import bz2 text = bz2.decompress(text) except OSError: yield Error, text.decode('latin1') if isinstance(text, bytes): text = text.decode('latin1') # do not call Lexer.get_tokens() because stripping is not optional. text = text.strip('\n') + '\n' for i, t, v in self.get_tokens_unprocessed(text): yield t, v def get_tokens_unprocessed(self, text): length = 0 for match in line_re.finditer(text): try: ttypestr, val = match.group().rstrip().split('\t', 1) ttype = _ttype_cache.get(ttypestr) if not ttype: ttype = Token ttypes = ttypestr.split('.')[1:] for ttype_ in ttypes: if not ttype_ or not ttype_[0].isupper(): raise ValueError('malformed token name') ttype = getattr(ttype, ttype_) _ttype_cache[ttypestr] = ttype val = ast.literal_eval(val) if not isinstance(val, str): raise ValueError('expected str') except (SyntaxError, ValueError): val = match.group() ttype = Error yield length, ttype, val length += len(val)
3,414
Python
28.188034
75
0.53017
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/asm.py
""" pygments.lexers.asm ~~~~~~~~~~~~~~~~~~~ Lexers for assembly languages. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, include, bygroups, using, words, \ DelegatingLexer, default from pygments.lexers.c_cpp import CppLexer, CLexer from pygments.lexers.d import DLexer from pygments.token import Text, Name, Number, String, Comment, Punctuation, \ Other, Keyword, Operator, Whitespace __all__ = ['GasLexer', 'ObjdumpLexer', 'DObjdumpLexer', 'CppObjdumpLexer', 'CObjdumpLexer', 'HsailLexer', 'LlvmLexer', 'LlvmMirBodyLexer', 'LlvmMirLexer', 'NasmLexer', 'NasmObjdumpLexer', 'TasmLexer', 'Ca65Lexer', 'Dasm16Lexer'] class GasLexer(RegexLexer): """ For Gas (AT&T) assembly code. """ name = 'GAS' aliases = ['gas', 'asm'] filenames = ['*.s', '*.S'] mimetypes = ['text/x-gas'] #: optional Comment or Whitespace string = r'"(\\"|[^"])*"' char = r'[\w$.@-]' identifier = r'(?:[a-zA-Z$_]' + char + r'*|\.' + char + '+)' number = r'(?:0[xX][a-fA-F0-9]+|#?-?\d+)' register = '%' + identifier + r'\b' tokens = { 'root': [ include('whitespace'), (identifier + ':', Name.Label), (r'\.' + identifier, Name.Attribute, 'directive-args'), (r'lock|rep(n?z)?|data\d+', Name.Attribute), (identifier, Name.Function, 'instruction-args'), (r'[\r\n]+', Text) ], 'directive-args': [ (identifier, Name.Constant), (string, String), ('@' + identifier, Name.Attribute), (number, Number.Integer), (register, Name.Variable), (r'[\r\n]+', Whitespace, '#pop'), (r'([;#]|//).*?\n', Comment.Single, '#pop'), (r'/[*].*?[*]/', Comment.Multiline), (r'/[*].*?\n[\w\W]*?[*]/', Comment.Multiline, '#pop'), include('punctuation'), include('whitespace') ], 'instruction-args': [ # For objdump-disassembled code, shouldn't occur in # actual assembler input ('([a-z0-9]+)( )(<)('+identifier+')(>)', bygroups(Number.Hex, Text, Punctuation, Name.Constant, Punctuation)), ('([a-z0-9]+)( )(<)('+identifier+')([-+])('+number+')(>)', bygroups(Number.Hex, Text, Punctuation, Name.Constant, Punctuation, Number.Integer, Punctuation)), # Address constants (identifier, Name.Constant), (number, Number.Integer), # Registers (register, Name.Variable), # Numeric constants ('$'+number, Number.Integer), (r"$'(.|\\')'", String.Char), (r'[\r\n]+', Whitespace, '#pop'), (r'([;#]|//).*?\n', Comment.Single, '#pop'), (r'/[*].*?[*]/', Comment.Multiline), (r'/[*].*?\n[\w\W]*?[*]/', Comment.Multiline, '#pop'), include('punctuation'), include('whitespace') ], 'whitespace': [ (r'\n', Whitespace), (r'\s+', Whitespace), (r'([;#]|//).*?\n', Comment.Single), (r'/[*][\w\W]*?[*]/', Comment.Multiline) ], 'punctuation': [ (r'[-*,.()\[\]!:{}]+', Punctuation) ] } def analyse_text(text): if re.search(r'^\.(text|data|section)', text, re.M): return True elif re.search(r'^\.\w+', text, re.M): return 0.1 def _objdump_lexer_tokens(asm_lexer): """ Common objdump lexer tokens to wrap an ASM lexer. """ hex_re = r'[0-9A-Za-z]' return { 'root': [ # File name & format: ('(.*?)(:)( +file format )(.*?)$', bygroups(Name.Label, Punctuation, Text, String)), # Section header ('(Disassembly of section )(.*?)(:)$', bygroups(Text, Name.Label, Punctuation)), # Function labels # (With offset) ('('+hex_re+'+)( )(<)(.*?)([-+])(0[xX][A-Za-z0-9]+)(>:)$', bygroups(Number.Hex, Whitespace, Punctuation, Name.Function, Punctuation, Number.Hex, Punctuation)), # (Without offset) ('('+hex_re+'+)( )(<)(.*?)(>:)$', bygroups(Number.Hex, Whitespace, Punctuation, Name.Function, Punctuation)), # Code line with disassembled instructions ('( *)('+hex_re+r'+:)(\t)((?:'+hex_re+hex_re+' )+)( *\t)([a-zA-Z].*?)$', bygroups(Whitespace, Name.Label, Whitespace, Number.Hex, Whitespace, using(asm_lexer))), # Code line without raw instructions (objdump --no-show-raw-insn) ('( *)('+hex_re+r'+:)( *\t)([a-zA-Z].*?)$', bygroups(Whitespace, Name.Label, Whitespace, using(asm_lexer))), # Code line with ascii ('( *)('+hex_re+r'+:)(\t)((?:'+hex_re+hex_re+' )+)( *)(.*?)$', bygroups(Whitespace, Name.Label, Whitespace, Number.Hex, Whitespace, String)), # Continued code line, only raw opcodes without disassembled # instruction ('( *)('+hex_re+r'+:)(\t)((?:'+hex_re+hex_re+' )+)$', bygroups(Whitespace, Name.Label, Whitespace, Number.Hex)), # Skipped a few bytes (r'\t\.\.\.$', Text), # Relocation line # (With offset) (r'(\t\t\t)('+hex_re+r'+:)( )([^\t]+)(\t)(.*?)([-+])(0x'+hex_re+'+)$', bygroups(Whitespace, Name.Label, Whitespace, Name.Property, Whitespace, Name.Constant, Punctuation, Number.Hex)), # (Without offset) (r'(\t\t\t)('+hex_re+r'+:)( )([^\t]+)(\t)(.*?)$', bygroups(Whitespace, Name.Label, Whitespace, Name.Property, Whitespace, Name.Constant)), (r'[^\n]+\n', Other) ] } class ObjdumpLexer(RegexLexer): """ For the output of ``objdump -dr``. """ name = 'objdump' aliases = ['objdump'] filenames = ['*.objdump'] mimetypes = ['text/x-objdump'] tokens = _objdump_lexer_tokens(GasLexer) class DObjdumpLexer(DelegatingLexer): """ For the output of ``objdump -Sr`` on compiled D files. """ name = 'd-objdump' aliases = ['d-objdump'] filenames = ['*.d-objdump'] mimetypes = ['text/x-d-objdump'] def __init__(self, **options): super().__init__(DLexer, ObjdumpLexer, **options) class CppObjdumpLexer(DelegatingLexer): """ For the output of ``objdump -Sr`` on compiled C++ files. """ name = 'cpp-objdump' aliases = ['cpp-objdump', 'c++-objdumb', 'cxx-objdump'] filenames = ['*.cpp-objdump', '*.c++-objdump', '*.cxx-objdump'] mimetypes = ['text/x-cpp-objdump'] def __init__(self, **options): super().__init__(CppLexer, ObjdumpLexer, **options) class CObjdumpLexer(DelegatingLexer): """ For the output of ``objdump -Sr`` on compiled C files. """ name = 'c-objdump' aliases = ['c-objdump'] filenames = ['*.c-objdump'] mimetypes = ['text/x-c-objdump'] def __init__(self, **options): super().__init__(CLexer, ObjdumpLexer, **options) class HsailLexer(RegexLexer): """ For HSAIL assembly code. .. versionadded:: 2.2 """ name = 'HSAIL' aliases = ['hsail', 'hsa'] filenames = ['*.hsail'] mimetypes = ['text/x-hsail'] string = r'"[^"]*?"' identifier = r'[a-zA-Z_][\w.]*' # Registers register_number = r'[0-9]+' register = r'(\$(c|s|d|q)' + register_number + r')\b' # Qualifiers alignQual = r'(align\(\d+\))' widthQual = r'(width\((\d+|all)\))' allocQual = r'(alloc\(agent\))' # Instruction Modifiers roundingMod = (r'((_ftz)?(_up|_down|_zero|_near))') datatypeMod = (r'_(' # packedTypes r'u8x4|s8x4|u16x2|s16x2|u8x8|s8x8|u16x4|s16x4|u32x2|s32x2|' r'u8x16|s8x16|u16x8|s16x8|u32x4|s32x4|u64x2|s64x2|' r'f16x2|f16x4|f16x8|f32x2|f32x4|f64x2|' # baseTypes r'u8|s8|u16|s16|u32|s32|u64|s64|' r'b128|b8|b16|b32|b64|b1|' r'f16|f32|f64|' # opaqueType r'roimg|woimg|rwimg|samp|sig32|sig64)') # Numeric Constant float = r'((\d+\.)|(\d*\.\d+))[eE][+-]?\d+' hexfloat = r'0[xX](([0-9a-fA-F]+\.[0-9a-fA-F]*)|([0-9a-fA-F]*\.[0-9a-fA-F]+))[pP][+-]?\d+' ieeefloat = r'0((h|H)[0-9a-fA-F]{4}|(f|F)[0-9a-fA-F]{8}|(d|D)[0-9a-fA-F]{16})' tokens = { 'root': [ include('whitespace'), include('comments'), (string, String), (r'@' + identifier + ':?', Name.Label), (register, Name.Variable.Anonymous), include('keyword'), (r'&' + identifier, Name.Variable.Global), (r'%' + identifier, Name.Variable), (hexfloat, Number.Hex), (r'0[xX][a-fA-F0-9]+', Number.Hex), (ieeefloat, Number.Float), (float, Number.Float), (r'\d+', Number.Integer), (r'[=<>{}\[\]()*.,:;!]|x\b', Punctuation) ], 'whitespace': [ (r'(\n|\s)+', Whitespace), ], 'comments': [ (r'/\*.*?\*/', Comment.Multiline), (r'//.*?\n', Comment.Single), ], 'keyword': [ # Types (r'kernarg' + datatypeMod, Keyword.Type), # Regular keywords (r'\$(full|base|small|large|default|zero|near)', Keyword), (words(( 'module', 'extension', 'pragma', 'prog', 'indirect', 'signature', 'decl', 'kernel', 'function', 'enablebreakexceptions', 'enabledetectexceptions', 'maxdynamicgroupsize', 'maxflatgridsize', 'maxflatworkgroupsize', 'requireddim', 'requiredgridsize', 'requiredworkgroupsize', 'requirenopartialworkgroups'), suffix=r'\b'), Keyword), # instructions (roundingMod, Keyword), (datatypeMod, Keyword), (r'_(' + alignQual + '|' + widthQual + ')', Keyword), (r'_kernarg', Keyword), (r'(nop|imagefence)\b', Keyword), (words(( 'cleardetectexcept', 'clock', 'cuid', 'debugtrap', 'dim', 'getdetectexcept', 'groupbaseptr', 'kernargbaseptr', 'laneid', 'maxcuid', 'maxwaveid', 'packetid', 'setdetectexcept', 'waveid', 'workitemflatabsid', 'workitemflatid', 'nullptr', 'abs', 'bitrev', 'currentworkgroupsize', 'currentworkitemflatid', 'fract', 'ncos', 'neg', 'nexp2', 'nlog2', 'nrcp', 'nrsqrt', 'nsin', 'nsqrt', 'gridgroups', 'gridsize', 'not', 'sqrt', 'workgroupid', 'workgroupsize', 'workitemabsid', 'workitemid', 'ceil', 'floor', 'rint', 'trunc', 'add', 'bitmask', 'borrow', 'carry', 'copysign', 'div', 'rem', 'sub', 'shl', 'shr', 'and', 'or', 'xor', 'unpackhi', 'unpacklo', 'max', 'min', 'fma', 'mad', 'bitextract', 'bitselect', 'shuffle', 'cmov', 'bitalign', 'bytealign', 'lerp', 'nfma', 'mul', 'mulhi', 'mul24hi', 'mul24', 'mad24', 'mad24hi', 'bitinsert', 'combine', 'expand', 'lda', 'mov', 'pack', 'unpack', 'packcvt', 'unpackcvt', 'sad', 'sementp', 'ftos', 'stof', 'cmp', 'ld', 'st', '_eq', '_ne', '_lt', '_le', '_gt', '_ge', '_equ', '_neu', '_ltu', '_leu', '_gtu', '_geu', '_num', '_nan', '_seq', '_sne', '_slt', '_sle', '_sgt', '_sge', '_snum', '_snan', '_sequ', '_sneu', '_sltu', '_sleu', '_sgtu', '_sgeu', 'atomic', '_ld', '_st', '_cas', '_add', '_and', '_exch', '_max', '_min', '_or', '_sub', '_wrapdec', '_wrapinc', '_xor', 'ret', 'cvt', '_readonly', '_kernarg', '_global', 'br', 'cbr', 'sbr', '_scacq', '_screl', '_scar', '_rlx', '_wave', '_wg', '_agent', '_system', 'ldimage', 'stimage', '_v2', '_v3', '_v4', '_1d', '_2d', '_3d', '_1da', '_2da', '_1db', '_2ddepth', '_2dadepth', '_width', '_height', '_depth', '_array', '_channelorder', '_channeltype', 'querysampler', '_coord', '_filter', '_addressing', 'barrier', 'wavebarrier', 'initfbar', 'joinfbar', 'waitfbar', 'arrivefbar', 'leavefbar', 'releasefbar', 'ldf', 'activelaneid', 'activelanecount', 'activelanemask', 'activelanepermute', 'call', 'scall', 'icall', 'alloca', 'packetcompletionsig', 'addqueuewriteindex', 'casqueuewriteindex', 'ldqueuereadindex', 'stqueuereadindex', 'readonly', 'global', 'private', 'group', 'spill', 'arg', '_upi', '_downi', '_zeroi', '_neari', '_upi_sat', '_downi_sat', '_zeroi_sat', '_neari_sat', '_supi', '_sdowni', '_szeroi', '_sneari', '_supi_sat', '_sdowni_sat', '_szeroi_sat', '_sneari_sat', '_pp', '_ps', '_sp', '_ss', '_s', '_p', '_pp_sat', '_ps_sat', '_sp_sat', '_ss_sat', '_s_sat', '_p_sat')), Keyword), # Integer types (r'i[1-9]\d*', Keyword) ] } class LlvmLexer(RegexLexer): """ For LLVM assembly code. """ name = 'LLVM' url = 'https://llvm.org/docs/LangRef.html' aliases = ['llvm'] filenames = ['*.ll'] mimetypes = ['text/x-llvm'] #: optional Comment or Whitespace string = r'"[^"]*?"' identifier = r'([-a-zA-Z$._][\w\-$.]*|' + string + ')' block_label = r'(' + identifier + r'|(\d+))' tokens = { 'root': [ include('whitespace'), # Before keywords, because keywords are valid label names :(... (block_label + r'\s*:', Name.Label), include('keyword'), (r'%' + identifier, Name.Variable), (r'@' + identifier, Name.Variable.Global), (r'%\d+', Name.Variable.Anonymous), (r'@\d+', Name.Variable.Global), (r'#\d+', Name.Variable.Global), (r'!' + identifier, Name.Variable), (r'!\d+', Name.Variable.Anonymous), (r'c?' + string, String), (r'0[xX][a-fA-F0-9]+', Number), (r'-?\d+(?:[.]\d+)?(?:[eE][-+]?\d+(?:[.]\d+)?)?', Number), (r'[=<>{}\[\]()*.,!]|x\b', Punctuation) ], 'whitespace': [ (r'(\n|\s+)+', Whitespace), (r';.*?\n', Comment) ], 'keyword': [ # Regular keywords (words(( 'aarch64_sve_vector_pcs', 'aarch64_vector_pcs', 'acq_rel', 'acquire', 'add', 'addrspace', 'addrspacecast', 'afn', 'alias', 'aliasee', 'align', 'alignLog2', 'alignstack', 'alloca', 'allocsize', 'allOnes', 'alwaysinline', 'alwaysInline', 'amdgpu_cs', 'amdgpu_es', 'amdgpu_gfx', 'amdgpu_gs', 'amdgpu_hs', 'amdgpu_kernel', 'amdgpu_ls', 'amdgpu_ps', 'amdgpu_vs', 'and', 'any', 'anyregcc', 'appending', 'arcp', 'argmemonly', 'args', 'arm_aapcs_vfpcc', 'arm_aapcscc', 'arm_apcscc', 'ashr', 'asm', 'atomic', 'atomicrmw', 'attributes', 'available_externally', 'avr_intrcc', 'avr_signalcc', 'bit', 'bitcast', 'bitMask', 'blockaddress', 'blockcount', 'br', 'branchFunnel', 'builtin', 'byArg', 'byref', 'byte', 'byteArray', 'byval', 'c', 'call', 'callbr', 'callee', 'caller', 'calls', 'canAutoHide', 'catch', 'catchpad', 'catchret', 'catchswitch', 'cc', 'ccc', 'cfguard_checkcc', 'cleanup', 'cleanuppad', 'cleanupret', 'cmpxchg', 'cold', 'coldcc', 'comdat', 'common', 'constant', 'contract', 'convergent', 'critical', 'cxx_fast_tlscc', 'datalayout', 'declare', 'default', 'define', 'deplibs', 'dereferenceable', 'dereferenceable_or_null', 'distinct', 'dllexport', 'dllimport', 'dso_local', 'dso_local_equivalent', 'dso_preemptable', 'dsoLocal', 'eq', 'exact', 'exactmatch', 'extern_weak', 'external', 'externally_initialized', 'extractelement', 'extractvalue', 'fadd', 'false', 'fast', 'fastcc', 'fcmp', 'fdiv', 'fence', 'filter', 'flags', 'fmul', 'fneg', 'fpext', 'fptosi', 'fptoui', 'fptrunc', 'freeze', 'frem', 'from', 'fsub', 'funcFlags', 'function', 'gc', 'getelementptr', 'ghccc', 'global', 'guid', 'gv', 'hash', 'hhvm_ccc', 'hhvmcc', 'hidden', 'hot', 'hotness', 'icmp', 'ifunc', 'inaccessiblemem_or_argmemonly', 'inaccessiblememonly', 'inalloca', 'inbounds', 'indir', 'indirectbr', 'info', 'initialexec', 'inline', 'inlineBits', 'inlinehint', 'inrange', 'inreg', 'insertelement', 'insertvalue', 'insts', 'intel_ocl_bicc', 'inteldialect', 'internal', 'inttoptr', 'invoke', 'jumptable', 'kind', 'landingpad', 'largest', 'linkage', 'linkonce', 'linkonce_odr', 'live', 'load', 'local_unnamed_addr', 'localdynamic', 'localexec', 'lshr', 'max', 'metadata', 'min', 'minsize', 'module', 'monotonic', 'msp430_intrcc', 'mul', 'mustprogress', 'musttail', 'naked', 'name', 'nand', 'ne', 'nest', 'ninf', 'nnan', 'noalias', 'nobuiltin', 'nocallback', 'nocapture', 'nocf_check', 'noduplicate', 'noduplicates', 'nofree', 'noimplicitfloat', 'noinline', 'noInline', 'nomerge', 'none', 'nonlazybind', 'nonnull', 'noprofile', 'norecurse', 'noRecurse', 'noredzone', 'noreturn', 'nosync', 'notail', 'notEligibleToImport', 'noundef', 'nounwind', 'nsw', 'nsz', 'null', 'null_pointer_is_valid', 'nuw', 'oeq', 'offset', 'oge', 'ogt', 'ole', 'olt', 'one', 'opaque', 'optforfuzzing', 'optnone', 'optsize', 'or', 'ord', 'param', 'params', 'partition', 'path', 'personality', 'phi', 'poison', 'preallocated', 'prefix', 'preserve_allcc', 'preserve_mostcc', 'private', 'prologue', 'protected', 'ptrtoint', 'ptx_device', 'ptx_kernel', 'readnone', 'readNone', 'readonly', 'readOnly', 'reassoc', 'refs', 'relbf', 'release', 'resByArg', 'resume', 'ret', 'returnDoesNotAlias', 'returned', 'returns_twice', 'safestack', 'samesize', 'sanitize_address', 'sanitize_hwaddress', 'sanitize_memory', 'sanitize_memtag', 'sanitize_thread', 'sdiv', 'section', 'select', 'seq_cst', 'sext', 'sge', 'sgt', 'shadowcallstack', 'shl', 'shufflevector', 'sideeffect', 'signext', 'single', 'singleImpl', 'singleImplName', 'sitofp', 'sizeM1', 'sizeM1BitWidth', 'sle', 'slt', 'source_filename', 'speculatable', 'speculative_load_hardening', 'spir_func', 'spir_kernel', 'srem', 'sret', 'ssp', 'sspreq', 'sspstrong', 'store', 'strictfp', 'sub', 'summaries', 'summary', 'swiftcc', 'swifterror', 'swiftself', 'switch', 'syncscope', 'tail', 'tailcc', 'target', 'thread_local', 'to', 'token', 'triple', 'true', 'trunc', 'type', 'typeCheckedLoadConstVCalls', 'typeCheckedLoadVCalls', 'typeid', 'typeidCompatibleVTable', 'typeIdInfo', 'typeTestAssumeConstVCalls', 'typeTestAssumeVCalls', 'typeTestRes', 'typeTests', 'udiv', 'ueq', 'uge', 'ugt', 'uitofp', 'ule', 'ult', 'umax', 'umin', 'undef', 'une', 'uniformRetVal', 'uniqueRetVal', 'unknown', 'unnamed_addr', 'uno', 'unordered', 'unreachable', 'unsat', 'unwind', 'urem', 'uselistorder', 'uselistorder_bb', 'uwtable', 'va_arg', 'varFlags', 'variable', 'vcall_visibility', 'vFuncId', 'virtFunc', 'virtualConstProp', 'void', 'volatile', 'vscale', 'vTableFuncs', 'weak', 'weak_odr', 'webkit_jscc', 'win64cc', 'within', 'wpdRes', 'wpdResolutions', 'writeonly', 'x', 'x86_64_sysvcc', 'x86_fastcallcc', 'x86_intrcc', 'x86_mmx', 'x86_regcallcc', 'x86_stdcallcc', 'x86_thiscallcc', 'x86_vectorcallcc', 'xchg', 'xor', 'zeroext', 'zeroinitializer', 'zext', 'immarg', 'willreturn'), suffix=r'\b'), Keyword), # Types (words(('void', 'half', 'bfloat', 'float', 'double', 'fp128', 'x86_fp80', 'ppc_fp128', 'label', 'metadata', 'x86_mmx', 'x86_amx', 'token', 'ptr')), Keyword.Type), # Integer types (r'i[1-9]\d*', Keyword.Type) ] } class LlvmMirBodyLexer(RegexLexer): """ For LLVM MIR examples without the YAML wrapper. .. versionadded:: 2.6 """ name = 'LLVM-MIR Body' url = 'https://llvm.org/docs/MIRLangRef.html' aliases = ['llvm-mir-body'] filenames = [] mimetypes = [] tokens = { 'root': [ # Attributes on basic blocks (words(('liveins', 'successors'), suffix=':'), Keyword), # Basic Block Labels (r'bb\.[0-9]+(\.[a-zA-Z0-9_.-]+)?( \(address-taken\))?:', Name.Label), (r'bb\.[0-9]+ \(%[a-zA-Z0-9_.-]+\)( \(address-taken\))?:', Name.Label), (r'%bb\.[0-9]+(\.\w+)?', Name.Label), # Stack references (r'%stack\.[0-9]+(\.\w+\.addr)?', Name), # Subreg indices (r'%subreg\.\w+', Name), # Virtual registers (r'%[a-zA-Z0-9_]+ *', Name.Variable, 'vreg'), # Reference to LLVM-IR global include('global'), # Reference to Intrinsic (r'intrinsic\(\@[a-zA-Z0-9_.]+\)', Name.Variable.Global), # Comparison predicates (words(('eq', 'ne', 'sgt', 'sge', 'slt', 'sle', 'ugt', 'uge', 'ult', 'ule'), prefix=r'intpred\(', suffix=r'\)'), Name.Builtin), (words(('oeq', 'one', 'ogt', 'oge', 'olt', 'ole', 'ugt', 'uge', 'ult', 'ule'), prefix=r'floatpred\(', suffix=r'\)'), Name.Builtin), # Physical registers (r'\$\w+', String.Single), # Assignment operator (r'=', Operator), # gMIR Opcodes (r'(G_ANYEXT|G_[SZ]EXT|G_SEXT_INREG|G_TRUNC|G_IMPLICIT_DEF|G_PHI|' r'G_FRAME_INDEX|G_GLOBAL_VALUE|G_INTTOPTR|G_PTRTOINT|G_BITCAST|' r'G_CONSTANT|G_FCONSTANT|G_VASTART|G_VAARG|G_CTLZ|G_CTLZ_ZERO_UNDEF|' r'G_CTTZ|G_CTTZ_ZERO_UNDEF|G_CTPOP|G_BSWAP|G_BITREVERSE|' r'G_ADDRSPACE_CAST|G_BLOCK_ADDR|G_JUMP_TABLE|G_DYN_STACKALLOC|' r'G_ADD|G_SUB|G_MUL|G_[SU]DIV|G_[SU]REM|G_AND|G_OR|G_XOR|G_SHL|' r'G_[LA]SHR|G_[IF]CMP|G_SELECT|G_GEP|G_PTR_MASK|G_SMIN|G_SMAX|' r'G_UMIN|G_UMAX|G_[US]ADDO|G_[US]ADDE|G_[US]SUBO|G_[US]SUBE|' r'G_[US]MULO|G_[US]MULH|G_FNEG|G_FPEXT|G_FPTRUNC|G_FPTO[US]I|' r'G_[US]ITOFP|G_FABS|G_FCOPYSIGN|G_FCANONICALIZE|G_FMINNUM|' r'G_FMAXNUM|G_FMINNUM_IEEE|G_FMAXNUM_IEEE|G_FMINIMUM|G_FMAXIMUM|' r'G_FADD|G_FSUB|G_FMUL|G_FMA|G_FMAD|G_FDIV|G_FREM|G_FPOW|G_FEXP|' r'G_FEXP2|G_FLOG|G_FLOG2|G_FLOG10|G_FCEIL|G_FCOS|G_FSIN|G_FSQRT|' r'G_FFLOOR|G_FRINT|G_FNEARBYINT|G_INTRINSIC_TRUNC|' r'G_INTRINSIC_ROUND|G_LOAD|G_[ZS]EXTLOAD|G_INDEXED_LOAD|' r'G_INDEXED_[ZS]EXTLOAD|G_STORE|G_INDEXED_STORE|' r'G_ATOMIC_CMPXCHG_WITH_SUCCESS|G_ATOMIC_CMPXCHG|' r'G_ATOMICRMW_(XCHG|ADD|SUB|AND|NAND|OR|XOR|MAX|MIN|UMAX|UMIN|FADD|' r'FSUB)' r'|G_FENCE|G_EXTRACT|G_UNMERGE_VALUES|G_INSERT|G_MERGE_VALUES|' r'G_BUILD_VECTOR|G_BUILD_VECTOR_TRUNC|G_CONCAT_VECTORS|' r'G_INTRINSIC|G_INTRINSIC_W_SIDE_EFFECTS|G_BR|G_BRCOND|' r'G_BRINDIRECT|G_BRJT|G_INSERT_VECTOR_ELT|G_EXTRACT_VECTOR_ELT|' r'G_SHUFFLE_VECTOR)\b', Name.Builtin), # Target independent opcodes (r'(COPY|PHI|INSERT_SUBREG|EXTRACT_SUBREG|REG_SEQUENCE)\b', Name.Builtin), # Flags (words(('killed', 'implicit')), Keyword), # ConstantInt values (r'(i[0-9]+)( +)', bygroups(Keyword.Type, Whitespace), 'constantint'), # ConstantFloat values (r'(half|float|double) +', Keyword.Type, 'constantfloat'), # Bare immediates include('integer'), # MMO's (r'(::)( *)', bygroups(Operator, Whitespace), 'mmo'), # MIR Comments (r';.*', Comment), # If we get here, assume it's a target instruction (r'[a-zA-Z0-9_]+', Name), # Everything else that isn't highlighted (r'[(), \n]+', Text), ], # The integer constant from a ConstantInt value 'constantint': [ include('integer'), (r'(?=.)', Text, '#pop'), ], # The floating point constant from a ConstantFloat value 'constantfloat': [ include('float'), (r'(?=.)', Text, '#pop'), ], 'vreg': [ # The bank or class if there is one (r'( *)(:(?!:))', bygroups(Whitespace, Keyword), ('#pop', 'vreg_bank_or_class')), # The LLT if there is one (r'( *)(\()', bygroups(Whitespace, Text), 'vreg_type'), (r'(?=.)', Text, '#pop'), ], 'vreg_bank_or_class': [ # The unassigned bank/class (r'( *)(_)', bygroups(Whitespace, Name.Variable.Magic)), (r'( *)([a-zA-Z0-9_]+)', bygroups(Whitespace, Name.Variable)), # The LLT if there is one (r'( *)(\()', bygroups(Whitespace, Text), 'vreg_type'), (r'(?=.)', Text, '#pop'), ], 'vreg_type': [ # Scalar and pointer types (r'( *)([sp][0-9]+)', bygroups(Whitespace, Keyword.Type)), (r'( *)(<[0-9]+ *x *[sp][0-9]+>)', bygroups(Whitespace, Keyword.Type)), (r'\)', Text, '#pop'), (r'(?=.)', Text, '#pop'), ], 'mmo': [ (r'\(', Text), (r' +', Whitespace), (words(('load', 'store', 'on', 'into', 'from', 'align', 'monotonic', 'acquire', 'release', 'acq_rel', 'seq_cst')), Keyword), # IR references (r'%ir\.[a-zA-Z0-9_.-]+', Name), (r'%ir-block\.[a-zA-Z0-9_.-]+', Name), (r'[-+]', Operator), include('integer'), include('global'), (r',', Punctuation), (r'\), \(', Text), (r'\)', Text, '#pop'), ], 'integer': [(r'-?[0-9]+', Number.Integer),], 'float': [(r'-?[0-9]+\.[0-9]+(e[+-][0-9]+)?', Number.Float)], 'global': [(r'\@[a-zA-Z0-9_.]+', Name.Variable.Global)], } class LlvmMirLexer(RegexLexer): """ Lexer for the overall LLVM MIR document format. MIR is a human readable serialization format that's used to represent LLVM's machine specific intermediate representation. It allows LLVM's developers to see the state of the compilation process at various points, as well as test individual pieces of the compiler. .. versionadded:: 2.6 """ name = 'LLVM-MIR' url = 'https://llvm.org/docs/MIRLangRef.html' aliases = ['llvm-mir'] filenames = ['*.mir'] tokens = { 'root': [ # Comments are hashes at the YAML level (r'#.*', Comment), # Documents starting with | are LLVM-IR (r'--- \|$', Keyword, 'llvm_ir'), # Other documents are MIR (r'---', Keyword, 'llvm_mir'), # Consume everything else in one token for efficiency (r'[^-#]+|.', Text), ], 'llvm_ir': [ # Documents end with '...' or '---' (r'(\.\.\.|(?=---))', Keyword, '#pop'), # Delegate to the LlvmLexer (r'((?:.|\n)+?)(?=(\.\.\.|---))', bygroups(using(LlvmLexer))), ], 'llvm_mir': [ # Comments are hashes at the YAML level (r'#.*', Comment), # Documents end with '...' or '---' (r'(\.\.\.|(?=---))', Keyword, '#pop'), # Handle the simple attributes (r'name:', Keyword, 'name'), (words(('alignment', ), suffix=':'), Keyword, 'number'), (words(('legalized', 'regBankSelected', 'tracksRegLiveness', 'selected', 'exposesReturnsTwice'), suffix=':'), Keyword, 'boolean'), # Handle the attributes don't highlight inside (words(('registers', 'stack', 'fixedStack', 'liveins', 'frameInfo', 'machineFunctionInfo'), suffix=':'), Keyword), # Delegate the body block to the LlvmMirBodyLexer (r'body: *\|', Keyword, 'llvm_mir_body'), # Consume everything else (r'.+', Text), (r'\n', Whitespace), ], 'name': [ (r'[^\n]+', Name), default('#pop'), ], 'boolean': [ (r' *(true|false)', Name.Builtin), default('#pop'), ], 'number': [ (r' *[0-9]+', Number), default('#pop'), ], 'llvm_mir_body': [ # Documents end with '...' or '---'. # We have to pop llvm_mir_body and llvm_mir (r'(\.\.\.|(?=---))', Keyword, '#pop:2'), # Delegate the body block to the LlvmMirBodyLexer (r'((?:.|\n)+?)(?=\.\.\.|---)', bygroups(using(LlvmMirBodyLexer))), # The '...' is optional. If we didn't already find it then it isn't # there. There might be a '---' instead though. (r'(?!\.\.\.|---)((?:.|\n)+)', bygroups(using(LlvmMirBodyLexer))), ], } class NasmLexer(RegexLexer): """ For Nasm (Intel) assembly code. """ name = 'NASM' aliases = ['nasm'] filenames = ['*.asm', '*.ASM', '*.nasm'] mimetypes = ['text/x-nasm'] # Tasm uses the same file endings, but TASM is not as common as NASM, so # we prioritize NASM higher by default priority = 1.0 identifier = r'[a-z$._?][\w$.?#@~]*' hexn = r'(?:0x[0-9a-f]+|$0[0-9a-f]*|[0-9]+[0-9a-f]*h)' octn = r'[0-7]+q' binn = r'[01]+b' decn = r'[0-9]+' floatn = decn + r'\.e?' + decn string = r'"(\\"|[^"\n])*"|' + r"'(\\'|[^'\n])*'|" + r"`(\\`|[^`\n])*`" declkw = r'(?:res|d)[bwdqt]|times' register = (r'(r[0-9][0-5]?[bwd]?|' r'[a-d][lh]|[er]?[a-d]x|[er]?[sb]p|[er]?[sd]i|[c-gs]s|st[0-7]|' r'mm[0-7]|cr[0-4]|dr[0-367]|tr[3-7]|k[0-7]|' r'[xyz]mm(?:[12][0-9]?|3[01]?|[04-9]))\b') wordop = r'seg|wrt|strict|rel|abs' type = r'byte|[dq]?word' # Directives must be followed by whitespace, otherwise CPU will match # cpuid for instance. directives = (r'(?:BITS|USE16|USE32|SECTION|SEGMENT|ABSOLUTE|EXTERN|GLOBAL|' r'ORG|ALIGN|STRUC|ENDSTRUC|COMMON|CPU|GROUP|UPPERCASE|IMPORT|' r'EXPORT|LIBRARY|MODULE)(?=\s)') flags = re.IGNORECASE | re.MULTILINE tokens = { 'root': [ (r'^\s*%', Comment.Preproc, 'preproc'), include('whitespace'), (identifier + ':', Name.Label), (r'(%s)(\s+)(equ)' % identifier, bygroups(Name.Constant, Whitespace, Keyword.Declaration), 'instruction-args'), (directives, Keyword, 'instruction-args'), (declkw, Keyword.Declaration, 'instruction-args'), (identifier, Name.Function, 'instruction-args'), (r'[\r\n]+', Whitespace) ], 'instruction-args': [ (string, String), (hexn, Number.Hex), (octn, Number.Oct), (binn, Number.Bin), (floatn, Number.Float), (decn, Number.Integer), include('punctuation'), (register, Name.Builtin), (identifier, Name.Variable), (r'[\r\n]+', Whitespace, '#pop'), include('whitespace') ], 'preproc': [ (r'[^;\n]+', Comment.Preproc), (r';.*?\n', Comment.Single, '#pop'), (r'\n', Comment.Preproc, '#pop'), ], 'whitespace': [ (r'\n', Whitespace), (r'[ \t]+', Whitespace), (r';.*', Comment.Single), (r'#.*', Comment.Single) ], 'punctuation': [ (r'[,{}():\[\]]+', Punctuation), (r'[&|^<>+*/%~-]+', Operator), (r'[$]+', Keyword.Constant), (wordop, Operator.Word), (type, Keyword.Type) ], } def analyse_text(text): # Probably TASM if re.match(r'PROC', text, re.IGNORECASE): return False class NasmObjdumpLexer(ObjdumpLexer): """ For the output of ``objdump -d -M intel``. .. versionadded:: 2.0 """ name = 'objdump-nasm' aliases = ['objdump-nasm'] filenames = ['*.objdump-intel'] mimetypes = ['text/x-nasm-objdump'] tokens = _objdump_lexer_tokens(NasmLexer) class TasmLexer(RegexLexer): """ For Tasm (Turbo Assembler) assembly code. """ name = 'TASM' aliases = ['tasm'] filenames = ['*.asm', '*.ASM', '*.tasm'] mimetypes = ['text/x-tasm'] identifier = r'[@a-z$._?][\w$.?#@~]*' hexn = r'(?:0x[0-9a-f]+|$0[0-9a-f]*|[0-9]+[0-9a-f]*h)' octn = r'[0-7]+q' binn = r'[01]+b' decn = r'[0-9]+' floatn = decn + r'\.e?' + decn string = r'"(\\"|[^"\n])*"|' + r"'(\\'|[^'\n])*'|" + r"`(\\`|[^`\n])*`" declkw = r'(?:res|d)[bwdqt]|times' register = (r'(r[0-9][0-5]?[bwd]|' r'[a-d][lh]|[er]?[a-d]x|[er]?[sb]p|[er]?[sd]i|[c-gs]s|st[0-7]|' r'mm[0-7]|cr[0-4]|dr[0-367]|tr[3-7])\b') wordop = r'seg|wrt|strict' type = r'byte|[dq]?word' directives = (r'BITS|USE16|USE32|SECTION|SEGMENT|ABSOLUTE|EXTERN|GLOBAL|' r'ORG|ALIGN|STRUC|ENDSTRUC|ENDS|COMMON|CPU|GROUP|UPPERCASE|INCLUDE|' r'EXPORT|LIBRARY|MODULE|PROC|ENDP|USES|ARG|DATASEG|UDATASEG|END|IDEAL|' r'P386|MODEL|ASSUME|CODESEG|SIZE') # T[A-Z][a-z] is more of a convention. Lexer should filter out STRUC definitions # and then 'add' them to datatype somehow. datatype = (r'db|dd|dw|T[A-Z][a-z]+') flags = re.IGNORECASE | re.MULTILINE tokens = { 'root': [ (r'^\s*%', Comment.Preproc, 'preproc'), include('whitespace'), (identifier + ':', Name.Label), (directives, Keyword, 'instruction-args'), (r'(%s)(\s+)(%s)' % (identifier, datatype), bygroups(Name.Constant, Whitespace, Keyword.Declaration), 'instruction-args'), (declkw, Keyword.Declaration, 'instruction-args'), (identifier, Name.Function, 'instruction-args'), (r'[\r\n]+', Whitespace) ], 'instruction-args': [ (string, String), (hexn, Number.Hex), (octn, Number.Oct), (binn, Number.Bin), (floatn, Number.Float), (decn, Number.Integer), include('punctuation'), (register, Name.Builtin), (identifier, Name.Variable), # Do not match newline when it's preceded by a backslash (r'(\\)(\s*)(;.*)([\r\n])', bygroups(Text, Whitespace, Comment.Single, Whitespace)), (r'[\r\n]+', Whitespace, '#pop'), include('whitespace') ], 'preproc': [ (r'[^;\n]+', Comment.Preproc), (r';.*?\n', Comment.Single, '#pop'), (r'\n', Comment.Preproc, '#pop'), ], 'whitespace': [ (r'[\n\r]', Whitespace), (r'(\\)([\n\r])', bygroups(Text, Whitespace)), (r'[ \t]+', Whitespace), (r';.*', Comment.Single) ], 'punctuation': [ (r'[,():\[\]]+', Punctuation), (r'[&|^<>+*=/%~-]+', Operator), (r'[$]+', Keyword.Constant), (wordop, Operator.Word), (type, Keyword.Type) ], } def analyse_text(text): # See above if re.match(r'PROC', text, re.I): return True class Ca65Lexer(RegexLexer): """ For ca65 assembler sources. .. versionadded:: 1.6 """ name = 'ca65 assembler' aliases = ['ca65'] filenames = ['*.s'] flags = re.IGNORECASE tokens = { 'root': [ (r';.*', Comment.Single), (r'\s+', Whitespace), (r'[a-z_.@$][\w.@$]*:', Name.Label), (r'((ld|st)[axy]|(in|de)[cxy]|asl|lsr|ro[lr]|adc|sbc|cmp|cp[xy]' r'|cl[cvdi]|se[cdi]|jmp|jsr|bne|beq|bpl|bmi|bvc|bvs|bcc|bcs' r'|p[lh][ap]|rt[is]|brk|nop|ta[xy]|t[xy]a|txs|tsx|and|ora|eor' r'|bit)\b', Keyword), (r'\.\w+', Keyword.Pseudo), (r'[-+~*/^&|!<>=]', Operator), (r'"[^"\n]*.', String), (r"'[^'\n]*.", String.Char), (r'\$[0-9a-f]+|[0-9a-f]+h\b', Number.Hex), (r'\d+', Number.Integer), (r'%[01]+', Number.Bin), (r'[#,.:()=\[\]]', Punctuation), (r'[a-z_.@$][\w.@$]*', Name), ] } def analyse_text(self, text): # comments in GAS start with "#" if re.search(r'^\s*;', text, re.MULTILINE): return 0.9 class Dasm16Lexer(RegexLexer): """ For DCPU-16 Assembly. .. versionadded:: 2.4 """ name = 'DASM16' url = 'http://0x10c.com/doc/dcpu-16.txt' aliases = ['dasm16'] filenames = ['*.dasm16', '*.dasm'] mimetypes = ['text/x-dasm16'] INSTRUCTIONS = [ 'SET', 'ADD', 'SUB', 'MUL', 'MLI', 'DIV', 'DVI', 'MOD', 'MDI', 'AND', 'BOR', 'XOR', 'SHR', 'ASR', 'SHL', 'IFB', 'IFC', 'IFE', 'IFN', 'IFG', 'IFA', 'IFL', 'IFU', 'ADX', 'SBX', 'STI', 'STD', 'JSR', 'INT', 'IAG', 'IAS', 'RFI', 'IAQ', 'HWN', 'HWQ', 'HWI', ] REGISTERS = [ 'A', 'B', 'C', 'X', 'Y', 'Z', 'I', 'J', 'SP', 'PC', 'EX', 'POP', 'PEEK', 'PUSH' ] # Regexes yo char = r'[a-zA-Z0-9_$@.]' identifier = r'(?:[a-zA-Z$_]' + char + r'*|\.' + char + '+)' number = r'[+-]?(?:0[xX][a-zA-Z0-9]+|\d+)' binary_number = r'0b[01_]+' instruction = r'(?i)(' + '|'.join(INSTRUCTIONS) + ')' single_char = r"'\\?" + char + "'" string = r'"(\\"|[^"])*"' def guess_identifier(lexer, match): ident = match.group(0) klass = Name.Variable if ident.upper() in lexer.REGISTERS else Name.Label yield match.start(), klass, ident tokens = { 'root': [ include('whitespace'), (':' + identifier, Name.Label), (identifier + ':', Name.Label), (instruction, Name.Function, 'instruction-args'), (r'\.' + identifier, Name.Function, 'data-args'), (r'[\r\n]+', Whitespace) ], 'numeric' : [ (binary_number, Number.Integer), (number, Number.Integer), (single_char, String), ], 'arg' : [ (identifier, guess_identifier), include('numeric') ], 'deref' : [ (r'\+', Punctuation), (r'\]', Punctuation, '#pop'), include('arg'), include('whitespace') ], 'instruction-line' : [ (r'[\r\n]+', Whitespace, '#pop'), (r';.*?$', Comment, '#pop'), include('whitespace') ], 'instruction-args': [ (r',', Punctuation), (r'\[', Punctuation, 'deref'), include('arg'), include('instruction-line') ], 'data-args' : [ (r',', Punctuation), include('numeric'), (string, String), include('instruction-line') ], 'whitespace': [ (r'\n', Whitespace), (r'\s+', Whitespace), (r';.*?\n', Comment) ], }
41,243
Python
38.734104
94
0.471159
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/rdf.py
""" pygments.lexers.rdf ~~~~~~~~~~~~~~~~~~~ Lexers for semantic web and RDF query languages and markup. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, bygroups, default from pygments.token import Keyword, Punctuation, String, Number, Operator, \ Generic, Whitespace, Name, Literal, Comment, Text __all__ = ['SparqlLexer', 'TurtleLexer', 'ShExCLexer'] class SparqlLexer(RegexLexer): """ Lexer for `SPARQL <https://www.w3.org/TR/sparql11-query/>`_ query language. .. versionadded:: 2.0 """ name = 'SPARQL' aliases = ['sparql'] filenames = ['*.rq', '*.sparql'] mimetypes = ['application/sparql-query'] # character group definitions :: PN_CHARS_BASE_GRP = ('a-zA-Z' '\u00c0-\u00d6' '\u00d8-\u00f6' '\u00f8-\u02ff' '\u0370-\u037d' '\u037f-\u1fff' '\u200c-\u200d' '\u2070-\u218f' '\u2c00-\u2fef' '\u3001-\ud7ff' '\uf900-\ufdcf' '\ufdf0-\ufffd') PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_') PN_CHARS_GRP = (PN_CHARS_U_GRP + r'\-' + r'0-9' + '\u00b7' + '\u0300-\u036f' + '\u203f-\u2040') HEX_GRP = '0-9A-Fa-f' PN_LOCAL_ESC_CHARS_GRP = r' _~.\-!$&"()*+,;=/?#@%' # terminal productions :: PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']' PN_CHARS_U = '[' + PN_CHARS_U_GRP + ']' PN_CHARS = '[' + PN_CHARS_GRP + ']' HEX = '[' + HEX_GRP + ']' PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']' IRIREF = r'<(?:[^<>"{}|^`\\\x00-\x20])*>' BLANK_NODE_LABEL = '_:[0-9' + PN_CHARS_U_GRP + '](?:[' + PN_CHARS_GRP + \ '.]*' + PN_CHARS + ')?' PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?' VARNAME = '[0-9' + PN_CHARS_U_GRP + '][' + PN_CHARS_U_GRP + \ '0-9\u00b7\u0300-\u036f\u203f-\u2040]*' PERCENT = '%' + HEX + HEX PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')' PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' + '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' + PN_CHARS_GRP + ':]|' + PLX + '))?') EXPONENT = r'[eE][+-]?\d+' # Lexer token definitions :: tokens = { 'root': [ (r'\s+', Text), # keywords :: (r'(?i)(select|construct|describe|ask|where|filter|group\s+by|minus|' r'distinct|reduced|from\s+named|from|order\s+by|desc|asc|limit|' r'offset|values|bindings|load|into|clear|drop|create|add|move|copy|' r'insert\s+data|delete\s+data|delete\s+where|with|delete|insert|' r'using\s+named|using|graph|default|named|all|optional|service|' r'silent|bind|undef|union|not\s+in|in|as|having|to|prefix|base)\b', Keyword), (r'(a)\b', Keyword), # IRIs :: ('(' + IRIREF + ')', Name.Label), # blank nodes :: ('(' + BLANK_NODE_LABEL + ')', Name.Label), # # variables :: ('[?$]' + VARNAME, Name.Variable), # prefixed names :: (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + r')?', bygroups(Name.Namespace, Punctuation, Name.Tag)), # function names :: (r'(?i)(str|lang|langmatches|datatype|bound|iri|uri|bnode|rand|abs|' r'ceil|floor|round|concat|strlen|ucase|lcase|encode_for_uri|' r'contains|strstarts|strends|strbefore|strafter|year|month|day|' r'hours|minutes|seconds|timezone|tz|now|uuid|struuid|md5|sha1|sha256|sha384|' r'sha512|coalesce|if|strlang|strdt|sameterm|isiri|isuri|isblank|' r'isliteral|isnumeric|regex|substr|replace|exists|not\s+exists|' r'count|sum|min|max|avg|sample|group_concat|separator)\b', Name.Function), # boolean literals :: (r'(true|false)', Keyword.Constant), # double literals :: (r'[+\-]?(\d+\.\d*' + EXPONENT + r'|\.?\d+' + EXPONENT + ')', Number.Float), # decimal literals :: (r'[+\-]?(\d+\.\d*|\.\d+)', Number.Float), # integer literals :: (r'[+\-]?\d+', Number.Integer), # operators :: (r'(\|\||&&|=|\*|\-|\+|/|!=|<=|>=|!|<|>)', Operator), # punctuation characters :: (r'[(){}.;,:^\[\]]', Punctuation), # line comments :: (r'#[^\n]*', Comment), # strings :: (r'"""', String, 'triple-double-quoted-string'), (r'"', String, 'single-double-quoted-string'), (r"'''", String, 'triple-single-quoted-string'), (r"'", String, 'single-single-quoted-string'), ], 'triple-double-quoted-string': [ (r'"""', String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String, 'string-escape'), ], 'single-double-quoted-string': [ (r'"', String, 'end-of-string'), (r'[^"\\\n]+', String), (r'\\', String, 'string-escape'), ], 'triple-single-quoted-string': [ (r"'''", String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String.Escape, 'string-escape'), ], 'single-single-quoted-string': [ (r"'", String, 'end-of-string'), (r"[^'\\\n]+", String), (r'\\', String, 'string-escape'), ], 'string-escape': [ (r'u' + HEX + '{4}', String.Escape, '#pop'), (r'U' + HEX + '{8}', String.Escape, '#pop'), (r'.', String.Escape, '#pop'), ], 'end-of-string': [ (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)', bygroups(Operator, Name.Function), '#pop:2'), (r'\^\^', Operator, '#pop:2'), default('#pop:2'), ], } class TurtleLexer(RegexLexer): """ Lexer for `Turtle <http://www.w3.org/TR/turtle/>`_ data language. .. versionadded:: 2.1 """ name = 'Turtle' aliases = ['turtle'] filenames = ['*.ttl'] mimetypes = ['text/turtle', 'application/x-turtle'] # character group definitions :: PN_CHARS_BASE_GRP = ('a-zA-Z' '\u00c0-\u00d6' '\u00d8-\u00f6' '\u00f8-\u02ff' '\u0370-\u037d' '\u037f-\u1fff' '\u200c-\u200d' '\u2070-\u218f' '\u2c00-\u2fef' '\u3001-\ud7ff' '\uf900-\ufdcf' '\ufdf0-\ufffd') PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_') PN_CHARS_GRP = (PN_CHARS_U_GRP + r'\-' + r'0-9' + '\u00b7' + '\u0300-\u036f' + '\u203f-\u2040') PN_CHARS = '[' + PN_CHARS_GRP + ']' PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']' PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?' HEX_GRP = '0-9A-Fa-f' HEX = '[' + HEX_GRP + ']' PERCENT = '%' + HEX + HEX PN_LOCAL_ESC_CHARS_GRP = r' _~.\-!$&"()*+,;=/?#@%' PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']' PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')' PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' + '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' + PN_CHARS_GRP + ':]|' + PLX + '))?') patterns = { 'PNAME_NS': r'((?:[a-zA-Z][\w-]*)?\:)', # Simplified character range 'IRIREF': r'(<[^<>"{}|^`\\\x00-\x20]*>)' } tokens = { 'root': [ (r'\s+', Text), # Base / prefix (r'(@base|BASE)(\s+)%(IRIREF)s(\s*)(\.?)' % patterns, bygroups(Keyword, Whitespace, Name.Variable, Whitespace, Punctuation)), (r'(@prefix|PREFIX)(\s+)%(PNAME_NS)s(\s+)%(IRIREF)s(\s*)(\.?)' % patterns, bygroups(Keyword, Whitespace, Name.Namespace, Whitespace, Name.Variable, Whitespace, Punctuation)), # The shorthand predicate 'a' (r'(?<=\s)a(?=\s)', Keyword.Type), # IRIREF (r'%(IRIREF)s' % patterns, Name.Variable), # PrefixedName (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + r')?', bygroups(Name.Namespace, Punctuation, Name.Tag)), # Comment (r'#[^\n]+', Comment), (r'\b(true|false)\b', Literal), (r'[+\-]?\d*\.\d+', Number.Float), (r'[+\-]?\d*(:?\.\d+)?E[+\-]?\d+', Number.Float), (r'[+\-]?\d+', Number.Integer), (r'[\[\](){}.;,:^]', Punctuation), (r'"""', String, 'triple-double-quoted-string'), (r'"', String, 'single-double-quoted-string'), (r"'''", String, 'triple-single-quoted-string'), (r"'", String, 'single-single-quoted-string'), ], 'triple-double-quoted-string': [ (r'"""', String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String, 'string-escape'), ], 'single-double-quoted-string': [ (r'"', String, 'end-of-string'), (r'[^"\\\n]+', String), (r'\\', String, 'string-escape'), ], 'triple-single-quoted-string': [ (r"'''", String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String, 'string-escape'), ], 'single-single-quoted-string': [ (r"'", String, 'end-of-string'), (r"[^'\\\n]+", String), (r'\\', String, 'string-escape'), ], 'string-escape': [ (r'.', String, '#pop'), ], 'end-of-string': [ (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)', bygroups(Operator, Generic.Emph), '#pop:2'), (r'(\^\^)%(IRIREF)s' % patterns, bygroups(Operator, Generic.Emph), '#pop:2'), default('#pop:2'), ], } # Turtle and Tera Term macro files share the same file extension # but each has a recognizable and distinct syntax. def analyse_text(text): for t in ('@base ', 'BASE ', '@prefix ', 'PREFIX '): if re.search(r'^\s*%s' % t, text): return 0.80 class ShExCLexer(RegexLexer): """ Lexer for `ShExC <https://shex.io/shex-semantics/#shexc>`_ shape expressions language syntax. """ name = 'ShExC' aliases = ['shexc', 'shex'] filenames = ['*.shex'] mimetypes = ['text/shex'] # character group definitions :: PN_CHARS_BASE_GRP = ('a-zA-Z' '\u00c0-\u00d6' '\u00d8-\u00f6' '\u00f8-\u02ff' '\u0370-\u037d' '\u037f-\u1fff' '\u200c-\u200d' '\u2070-\u218f' '\u2c00-\u2fef' '\u3001-\ud7ff' '\uf900-\ufdcf' '\ufdf0-\ufffd') PN_CHARS_U_GRP = (PN_CHARS_BASE_GRP + '_') PN_CHARS_GRP = (PN_CHARS_U_GRP + r'\-' + r'0-9' + '\u00b7' + '\u0300-\u036f' + '\u203f-\u2040') HEX_GRP = '0-9A-Fa-f' PN_LOCAL_ESC_CHARS_GRP = r"_~.\-!$&'()*+,;=/?#@%" # terminal productions :: PN_CHARS_BASE = '[' + PN_CHARS_BASE_GRP + ']' PN_CHARS_U = '[' + PN_CHARS_U_GRP + ']' PN_CHARS = '[' + PN_CHARS_GRP + ']' HEX = '[' + HEX_GRP + ']' PN_LOCAL_ESC_CHARS = '[' + PN_LOCAL_ESC_CHARS_GRP + ']' UCHAR_NO_BACKSLASH = '(?:u' + HEX + '{4}|U' + HEX + '{8})' UCHAR = r'\\' + UCHAR_NO_BACKSLASH IRIREF = r'<(?:[^\x00-\x20<>"{}|^`\\]|' + UCHAR + ')*>' BLANK_NODE_LABEL = '_:[0-9' + PN_CHARS_U_GRP + '](?:[' + PN_CHARS_GRP + \ '.]*' + PN_CHARS + ')?' PN_PREFIX = PN_CHARS_BASE + '(?:[' + PN_CHARS_GRP + '.]*' + PN_CHARS + ')?' PERCENT = '%' + HEX + HEX PN_LOCAL_ESC = r'\\' + PN_LOCAL_ESC_CHARS PLX = '(?:' + PERCENT + ')|(?:' + PN_LOCAL_ESC + ')' PN_LOCAL = ('(?:[' + PN_CHARS_U_GRP + ':0-9' + ']|' + PLX + ')' + '(?:(?:[' + PN_CHARS_GRP + '.:]|' + PLX + ')*(?:[' + PN_CHARS_GRP + ':]|' + PLX + '))?') EXPONENT = r'[eE][+-]?\d+' # Lexer token definitions :: tokens = { 'root': [ (r'\s+', Text), # keywords :: (r'(?i)(base|prefix|start|external|' r'literal|iri|bnode|nonliteral|length|minlength|maxlength|' r'mininclusive|minexclusive|maxinclusive|maxexclusive|' r'totaldigits|fractiondigits|' r'closed|extra)\b', Keyword), (r'(a)\b', Keyword), # IRIs :: ('(' + IRIREF + ')', Name.Label), # blank nodes :: ('(' + BLANK_NODE_LABEL + ')', Name.Label), # prefixed names :: (r'(' + PN_PREFIX + r')?(\:)(' + PN_LOCAL + ')?', bygroups(Name.Namespace, Punctuation, Name.Tag)), # boolean literals :: (r'(true|false)', Keyword.Constant), # double literals :: (r'[+\-]?(\d+\.\d*' + EXPONENT + r'|\.?\d+' + EXPONENT + ')', Number.Float), # decimal literals :: (r'[+\-]?(\d+\.\d*|\.\d+)', Number.Float), # integer literals :: (r'[+\-]?\d+', Number.Integer), # operators :: (r'[@|$&=*+?^\-~]', Operator), # operator keywords :: (r'(?i)(and|or|not)\b', Operator.Word), # punctuation characters :: (r'[(){}.;,:^\[\]]', Punctuation), # line comments :: (r'#[^\n]*', Comment), # strings :: (r'"""', String, 'triple-double-quoted-string'), (r'"', String, 'single-double-quoted-string'), (r"'''", String, 'triple-single-quoted-string'), (r"'", String, 'single-single-quoted-string'), ], 'triple-double-quoted-string': [ (r'"""', String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String, 'string-escape'), ], 'single-double-quoted-string': [ (r'"', String, 'end-of-string'), (r'[^"\\\n]+', String), (r'\\', String, 'string-escape'), ], 'triple-single-quoted-string': [ (r"'''", String, 'end-of-string'), (r'[^\\]+', String), (r'\\', String.Escape, 'string-escape'), ], 'single-single-quoted-string': [ (r"'", String, 'end-of-string'), (r"[^'\\\n]+", String), (r'\\', String, 'string-escape'), ], 'string-escape': [ (UCHAR_NO_BACKSLASH, String.Escape, '#pop'), (r'.', String.Escape, '#pop'), ], 'end-of-string': [ (r'(@)([a-zA-Z]+(?:-[a-zA-Z0-9]+)*)', bygroups(Operator, Name.Function), '#pop:2'), (r'\^\^', Operator, '#pop:2'), default('#pop:2'), ], }
15,790
Python
33.105831
97
0.421786
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/_mql_builtins.py
""" pygments.lexers._mql_builtins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Builtins for the MqlLexer. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ types = ( 'AccountBalance', 'AccountCompany', 'AccountCredit', 'AccountCurrency', 'AccountEquity', 'AccountFreeMarginCheck', 'AccountFreeMarginMode', 'AccountFreeMargin', 'AccountInfoDouble', 'AccountInfoInteger', 'AccountInfoString', 'AccountLeverage', 'AccountMargin', 'AccountName', 'AccountNumber', 'AccountProfit', 'AccountServer', 'AccountStopoutLevel', 'AccountStopoutMode', 'Alert', 'ArrayBsearch', 'ArrayCompare', 'ArrayCopyRates', 'ArrayCopySeries', 'ArrayCopy', 'ArrayDimension', 'ArrayFill', 'ArrayFree', 'ArrayGetAsSeries', 'ArrayInitialize', 'ArrayIsDynamic', 'ArrayIsSeries', 'ArrayMaximum', 'ArrayMinimum', 'ArrayRange', 'ArrayResize', 'ArraySetAsSeries', 'ArraySize', 'ArraySort', 'CharArrayToString', 'CharToString', 'CharToStr', 'CheckPointer', 'ColorToARGB', 'ColorToString', 'Comment', 'CopyClose', 'CopyHigh', 'CopyLow', 'CopyOpen', 'CopyRates', 'CopyRealVolume', 'CopySpread', 'CopyTickVolume', 'CopyTime', 'DayOfWeek', 'DayOfYear', 'Day', 'DebugBreak', 'Digits', 'DoubleToString', 'DoubleToStr', 'EnumToString', 'EventChartCustom', 'EventKillTimer', 'EventSetMillisecondTimer', 'EventSetTimer', 'ExpertRemove', 'FileClose', 'FileCopy', 'FileDelete', 'FileFindClose', 'FileFindFirst', 'FileFindNext', 'FileFlush', 'FileGetInteger', 'FileIsEnding', 'FileIsExist', 'FileIsLineEnding', 'FileMove', 'FileOpenHistory', 'FileOpen', 'FileReadArray', 'FileReadBool', 'FileReadDatetime', 'FileReadDouble', 'FileReadFloat', 'FileReadInteger', 'FileReadLong', 'FileReadNumber', 'FileReadString', 'FileReadStruct', 'FileSeek', 'FileSize', 'FileTell', 'FileWriteArray', 'FileWriteDouble', 'FileWriteFloat', 'FileWriteInteger', 'FileWriteLong', 'FileWriteString', 'FileWriteStruct', 'FileWrite', 'FolderClean', 'FolderCreate', 'FolderDelete', 'GetLastError', 'GetPointer', 'GetTickCount', 'GlobalVariableCheck', 'GlobalVariableDel', 'GlobalVariableGet', 'GlobalVariableName', 'GlobalVariableSetOnCondition', 'GlobalVariableSet', 'GlobalVariableTemp', 'GlobalVariableTime', 'GlobalVariablesDeleteAll', 'GlobalVariablesFlush', 'GlobalVariablesTotal', 'HideTestIndicators', 'Hour', 'IndicatorBuffers', 'IndicatorCounted', 'IndicatorDigits', 'IndicatorSetDouble', 'IndicatorSetInteger', 'IndicatorSetString', 'IndicatorShortName', 'IntegerToString', 'IsConnected', 'IsDemo', 'IsDllsAllowed', 'IsExpertEnabled', 'IsLibrariesAllowed', 'IsOptimization', 'IsStopped', 'IsTesting', 'IsTradeAllowed', 'IsTradeContextBusy', 'IsVisualMode', 'MQLInfoInteger', 'MQLInfoString', 'MarketInfo', 'MathAbs', 'MathArccos', 'MathArcsin', 'MathArctan', 'MathCeil', 'MathCos', 'MathExp', 'MathFloor', 'MathIsValidNumber', 'MathLog', 'MathMax', 'MathMin', 'MathMod', 'MathPow', 'MathRand', 'MathRound', 'MathSin', 'MathSqrt', 'MathSrand', 'MathTan', 'MessageBox', 'Minute', 'Month', 'NormalizeDouble', 'ObjectCreate', 'ObjectDelete', 'ObjectDescription', 'ObjectFind', 'ObjectGetDouble', 'ObjectGetFiboDescription', 'ObjectGetInteger', 'ObjectGetShiftByValue', 'ObjectGetString', 'ObjectGetTimeByValue', 'ObjectGetValueByShift', 'ObjectGetValueByTime', 'ObjectGet', 'ObjectMove', 'ObjectName', 'ObjectSetDouble', 'ObjectSetFiboDescription', 'ObjectSetInteger', 'ObjectSetString', 'ObjectSetText', 'ObjectSet', 'ObjectType', 'ObjectsDeleteAll', 'ObjectsTotal', 'OrderCloseBy', 'OrderClosePrice', 'OrderCloseTime', 'OrderClose', 'OrderComment', 'OrderCommission', 'OrderDelete', 'OrderExpiration', 'OrderLots', 'OrderMagicNumber', 'OrderModify', 'OrderOpenPrice', 'OrderOpenTime', 'OrderPrint', 'OrderProfit', 'OrderSelect', 'OrderSend', 'OrderStopLoss', 'OrderSwap', 'OrderSymbol', 'OrderTakeProfit', 'OrderTicket', 'OrderType', 'OrdersHistoryTotal', 'OrdersTotal', 'PeriodSeconds', 'Period', 'PlaySound', 'Point', 'PrintFormat', 'Print', 'RefreshRates', 'ResetLastError', 'ResourceCreate', 'ResourceFree', 'ResourceReadImage', 'ResourceSave', 'Seconds', 'SendFTP', 'SendMail', 'SendNotification', 'SeriesInfoInteger', 'SetIndexArrow', 'SetIndexBuffer', 'SetIndexDrawBegin', 'SetIndexEmptyValue', 'SetIndexLabel', 'SetIndexShift', 'SetIndexStyle', 'SetLevelStyle', 'SetLevelValue', 'ShortArrayToString', 'ShortToString', 'Sleep', 'StrToDouble', 'StrToInteger', 'StrToTime', 'StringAdd', 'StringBufferLen', 'StringCompare', 'StringConcatenate', 'StringFill', 'StringFind', 'StringFormat', 'StringGetCharacter', 'StringGetChar', 'StringInit', 'StringLen', 'StringReplace', 'StringSetCharacter', 'StringSetChar', 'StringSplit', 'StringSubstr', 'StringToCharArray', 'StringToColor', 'StringToDouble', 'StringToInteger', 'StringToLower', 'StringToShortArray', 'StringToTime', 'StringToUpper', 'StringTrimLeft', 'StringTrimRight', 'StructToTime', 'SymbolInfoDouble', 'SymbolInfoInteger', 'SymbolInfoSessionQuote', 'SymbolInfoSessionTrade', 'SymbolInfoString', 'SymbolInfoTick', 'SymbolIsSynchronized', 'SymbolName', 'SymbolSelect', 'SymbolsTotal', 'Symbol', 'TerminalClose', 'TerminalCompany', 'TerminalName', 'TerminalPath', 'TesterStatistics', 'TextGetSize', 'TextOut', 'TextSetFont', 'TimeCurrent', 'TimeDayOfWeek', 'TimeDayOfYear', 'TimeDaylightSavings', 'TimeDay', 'TimeGMTOffset', 'TimeGMT', 'TimeHour', 'TimeLocal', 'TimeMinute', 'TimeMonth', 'TimeSeconds', 'TimeToString', 'TimeToStruct', 'TimeToStr', 'TimeTradeServer', 'TimeYear', 'UninitializeReason', 'WindowBarsPerChart', 'WindowExpertName', 'WindowFind', 'WindowFirstVisibleBar', 'WindowHandle', 'WindowIsVisible', 'WindowOnDropped', 'WindowPriceMax', 'WindowPriceMin', 'WindowPriceOnDropped', 'WindowRedraw', 'WindowScreenShot', 'WindowTimeOnDropped', 'WindowXOnDropped', 'WindowYOnDropped', 'WindowsTotal', 'Year', 'ZeroMemory', 'iAC', 'iADX', 'iAD', 'iAO', 'iATR', 'iAlligator', 'iBWMFI', 'iBandsOnArray', 'iBands', 'iBarShift', 'iBars', 'iBearsPower', 'iBullsPower', 'iCCIOnArray', 'iCCI', 'iClose', 'iCustom', 'iDeMarker', 'iEnvelopesOnArray', 'iEnvelopes', 'iForce', 'iFractals', 'iGator', 'iHighest', 'iHigh', 'iIchimoku', 'iLowest', 'iLow', 'iMACD', 'iMAOnArray', 'iMA', 'iMFI', 'iMomentumOnArray', 'iMomentum', 'iOBV', 'iOpen', 'iOsMA', 'iRSIOnArray', 'iRSI', 'iRVI', 'iSAR', 'iStdDevOnArray', 'iStdDev', 'iStochastic', 'iTime', 'iVolume', 'iWPR', ) constants = ( 'ACCOUNT_BALANCE', 'ACCOUNT_COMPANY', 'ACCOUNT_CREDIT', 'ACCOUNT_CURRENCY', 'ACCOUNT_EQUITY', 'ACCOUNT_FREEMARGIN', 'ACCOUNT_LEVERAGE', 'ACCOUNT_LIMIT_ORDERS', 'ACCOUNT_LOGIN', 'ACCOUNT_MARGIN', 'ACCOUNT_MARGIN_LEVEL', 'ACCOUNT_MARGIN_SO_CALL', 'ACCOUNT_MARGIN_SO_MODE', 'ACCOUNT_MARGIN_SO_SO', 'ACCOUNT_NAME', 'ACCOUNT_PROFIT', 'ACCOUNT_SERVER', 'ACCOUNT_STOPOUT_MODE_MONEY', 'ACCOUNT_STOPOUT_MODE_PERCENT', 'ACCOUNT_TRADE_ALLOWED', 'ACCOUNT_TRADE_EXPERT', 'ACCOUNT_TRADE_MODE', 'ACCOUNT_TRADE_MODE_CONTEST', 'ACCOUNT_TRADE_MODE_DEMO', 'ACCOUNT_TRADE_MODE_REAL', 'ALIGN_CENTER', 'ALIGN_LEFT', 'ALIGN_RIGHT', 'ANCHOR_BOTTOM', 'ANCHOR_CENTER', 'ANCHOR_LEFT', 'ANCHOR_LEFT_LOWER', 'ANCHOR_LEFT_UPPER', 'ANCHOR_LOWER', 'ANCHOR_RIGHT', 'ANCHOR_RIGHT_LOWER', 'ANCHOR_RIGHT_UPPER', 'ANCHOR_TOP', 'ANCHOR_UPPER', 'BORDER_FLAT', 'BORDER_RAISED', 'BORDER_SUNKEN', 'CHARTEVENT_CHART_CHANGE', 'CHARTEVENT_CLICK', 'CHARTEVENT_CUSTOM', 'CHARTEVENT_CUSTOM_LAST', 'CHARTEVENT_KEYDOWN', 'CHARTEVENT_MOUSE_MOVE', 'CHARTEVENT_OBJECT_CHANGE', 'CHARTEVENT_OBJECT_CLICK', 'CHARTEVENT_OBJECT_CREATE', 'CHARTEVENT_OBJECT_DELETE', 'CHARTEVENT_OBJECT_DRAG', 'CHARTEVENT_OBJECT_ENDEDIT', 'CHARTS_MAX', 'CHART_AUTOSCROLL', 'CHART_BARS', 'CHART_BEGIN', 'CHART_BRING_TO_TOP', 'CHART_CANDLES', 'CHART_COLOR_ASK', 'CHART_COLOR_BACKGROUND', 'CHART_COLOR_BID', 'CHART_COLOR_CANDLE_BEAR', 'CHART_COLOR_CANDLE_BULL', 'CHART_COLOR_CHART_DOWN', 'CHART_COLOR_CHART_LINE', 'CHART_COLOR_CHART_UP', 'CHART_COLOR_FOREGROUND', 'CHART_COLOR_GRID', 'CHART_COLOR_LAST', 'CHART_COLOR_STOP_LEVEL', 'CHART_COLOR_VOLUME', 'CHART_COMMENT', 'CHART_CURRENT_POS', 'CHART_DRAG_TRADE_LEVELS', 'CHART_END', 'CHART_EVENT_MOUSE_MOVE', 'CHART_EVENT_OBJECT_CREATE', 'CHART_EVENT_OBJECT_DELETE', 'CHART_FIRST_VISIBLE_BAR', 'CHART_FIXED_MAX', 'CHART_FIXED_MIN', 'CHART_FIXED_POSITION', 'CHART_FOREGROUND', 'CHART_HEIGHT_IN_PIXELS', 'CHART_IS_OBJECT', 'CHART_LINE', 'CHART_MODE', 'CHART_MOUSE_SCROLL', 'CHART_POINTS_PER_BAR', 'CHART_PRICE_MAX', 'CHART_PRICE_MIN', 'CHART_SCALEFIX', 'CHART_SCALEFIX_11', 'CHART_SCALE', 'CHART_SCALE_PT_PER_BAR', 'CHART_SHIFT', 'CHART_SHIFT_SIZE', 'CHART_SHOW_ASK_LINE', 'CHART_SHOW_BID_LINE', 'CHART_SHOW_DATE_SCALE', 'CHART_SHOW_GRID', 'CHART_SHOW_LAST_LINE', 'CHART_SHOW_OBJECT_DESCR', 'CHART_SHOW_OHLC', 'CHART_SHOW_PERIOD_SEP', 'CHART_SHOW_PRICE_SCALE', 'CHART_SHOW_TRADE_LEVELS', 'CHART_SHOW_VOLUMES', 'CHART_VISIBLE_BARS', 'CHART_VOLUME_HIDE', 'CHART_VOLUME_REAL', 'CHART_VOLUME_TICK', 'CHART_WIDTH_IN_BARS', 'CHART_WIDTH_IN_PIXELS', 'CHART_WINDOWS_TOTAL', 'CHART_WINDOW_HANDLE', 'CHART_WINDOW_IS_VISIBLE', 'CHART_WINDOW_YDISTANCE', 'CHAR_MAX', 'CHAR_MIN', 'CLR_NONE', 'CORNER_LEFT_LOWER', 'CORNER_LEFT_UPPER', 'CORNER_RIGHT_LOWER', 'CORNER_RIGHT_UPPER', 'CP_ACP', 'CP_MACCP', 'CP_OEMCP', 'CP_SYMBOL', 'CP_THREAD_ACP', 'CP_UTF7', 'CP_UTF8', 'DBL_DIG', 'DBL_EPSILON', 'DBL_MANT_DIG', 'DBL_MAX', 'DBL_MAX_10_EXP', 'DBL_MAX_EXP', 'DBL_MIN', 'DBL_MIN_10_EXP', 'DBL_MIN_EXP', 'DRAW_ARROW', 'DRAW_FILLING', 'DRAW_HISTOGRAM', 'DRAW_LINE', 'DRAW_NONE', 'DRAW_SECTION', 'DRAW_ZIGZAG', 'EMPTY', 'EMPTY_VALUE', 'ERR_ACCOUNT_DISABLED', 'ERR_BROKER_BUSY', 'ERR_COMMON_ERROR', 'ERR_INVALID_ACCOUNT', 'ERR_INVALID_PRICE', 'ERR_INVALID_STOPS', 'ERR_INVALID_TRADE_PARAMETERS', 'ERR_INVALID_TRADE_VOLUME', 'ERR_LONG_POSITIONS_ONLY_ALLOWED', 'ERR_MALFUNCTIONAL_TRADE', 'ERR_MARKET_CLOSED', 'ERR_NOT_ENOUGH_MONEY', 'ERR_NOT_ENOUGH_RIGHTS', 'ERR_NO_CONNECTION', 'ERR_NO_ERROR', 'ERR_NO_RESULT', 'ERR_OFF_QUOTES', 'ERR_OLD_VERSION', 'ERR_ORDER_LOCKED', 'ERR_PRICE_CHANGED', 'ERR_REQUOTE', 'ERR_SERVER_BUSY', 'ERR_TOO_FREQUENT_REQUESTS', 'ERR_TOO_MANY_REQUESTS', 'ERR_TRADE_CONTEXT_BUSY', 'ERR_TRADE_DISABLED', 'ERR_TRADE_EXPIRATION_DENIED', 'ERR_TRADE_HEDGE_PROHIBITED', 'ERR_TRADE_MODIFY_DENIED', 'ERR_TRADE_PROHIBITED_BY_FIFO', 'ERR_TRADE_TIMEOUT', 'ERR_TRADE_TOO_MANY_ORDERS', 'FILE_ACCESS_DATE', 'FILE_ANSI', 'FILE_BIN', 'FILE_COMMON', 'FILE_CREATE_DATE', 'FILE_CSV', 'FILE_END', 'FILE_EXISTS', 'FILE_IS_ANSI', 'FILE_IS_BINARY', 'FILE_IS_COMMON', 'FILE_IS_CSV', 'FILE_IS_READABLE', 'FILE_IS_TEXT', 'FILE_IS_WRITABLE', 'FILE_LINE_END', 'FILE_MODIFY_DATE', 'FILE_POSITION', 'FILE_READ', 'FILE_REWRITE', 'FILE_SHARE_READ', 'FILE_SHARE_WRITE', 'FILE_SIZE', 'FILE_TXT', 'FILE_UNICODE', 'FILE_WRITE', 'FLT_DIG', 'FLT_EPSILON', 'FLT_MANT_DIG', 'FLT_MAX', 'FLT_MAX_10_EXP', 'FLT_MAX_EXP', 'FLT_MIN', 'FLT_MIN_10_EXP', 'FLT_MIN_EXP', 'FRIDAY', 'GANN_DOWN_TREND', 'GANN_UP_TREND', 'IDABORT', 'IDCANCEL', 'IDCONTINUE', 'IDIGNORE', 'IDNO', 'IDOK', 'IDRETRY', 'IDTRYAGAIN', 'IDYES', 'INDICATOR_CALCULATIONS', 'INDICATOR_COLOR_INDEX', 'INDICATOR_DATA', 'INDICATOR_DIGITS', 'INDICATOR_HEIGHT', 'INDICATOR_LEVELCOLOR', 'INDICATOR_LEVELSTYLE', 'INDICATOR_LEVELS', 'INDICATOR_LEVELTEXT', 'INDICATOR_LEVELVALUE', 'INDICATOR_LEVELWIDTH', 'INDICATOR_MAXIMUM', 'INDICATOR_MINIMUM', 'INDICATOR_SHORTNAME', 'INT_MAX', 'INT_MIN', 'INVALID_HANDLE', 'IS_DEBUG_MODE', 'IS_PROFILE_MODE', 'LICENSE_DEMO', 'LICENSE_FREE', 'LICENSE_FULL', 'LICENSE_TIME', 'LONG_MAX', 'LONG_MIN', 'MB_ABORTRETRYIGNORE', 'MB_CANCELTRYCONTINUE', 'MB_DEFBUTTON1', 'MB_DEFBUTTON2', 'MB_DEFBUTTON3', 'MB_DEFBUTTON4', 'MB_ICONASTERISK', 'MB_ICONERROR', 'MB_ICONEXCLAMATION', 'MB_ICONHAND', 'MB_ICONINFORMATION', 'MB_ICONQUESTION', 'MB_ICONSTOP', 'MB_ICONWARNING', 'MB_OKCANCEL', 'MB_OK', 'MB_RETRYCANCEL', 'MB_YESNOCANCEL', 'MB_YESNO', 'MODE_ASK', 'MODE_BID', 'MODE_CHINKOUSPAN', 'MODE_CLOSE', 'MODE_DIGITS', 'MODE_EMA', 'MODE_EXPIRATION', 'MODE_FREEZELEVEL', 'MODE_GATORJAW', 'MODE_GATORLIPS', 'MODE_GATORTEETH', 'MODE_HIGH', 'MODE_KIJUNSEN', 'MODE_LOTSIZE', 'MODE_LOTSTEP', 'MODE_LOWER', 'MODE_LOW', 'MODE_LWMA', 'MODE_MAIN', 'MODE_MARGINCALCMODE', 'MODE_MARGINHEDGED', 'MODE_MARGININIT', 'MODE_MARGINMAINTENANCE', 'MODE_MARGINREQUIRED', 'MODE_MAXLOT', 'MODE_MINLOT', 'MODE_MINUSDI', 'MODE_OPEN', 'MODE_PLUSDI', 'MODE_POINT', 'MODE_PROFITCALCMODE', 'MODE_SENKOUSPANA', 'MODE_SENKOUSPANB', 'MODE_SIGNAL', 'MODE_SMA', 'MODE_SMMA', 'MODE_SPREAD', 'MODE_STARTING', 'MODE_STOPLEVEL', 'MODE_SWAPLONG', 'MODE_SWAPSHORT', 'MODE_SWAPTYPE', 'MODE_TENKANSEN', 'MODE_TICKSIZE', 'MODE_TICKVALUE', 'MODE_TIME', 'MODE_TRADEALLOWED', 'MODE_UPPER', 'MODE_VOLUME', 'MONDAY', 'MQL_DEBUG', 'MQL_DLLS_ALLOWED', 'MQL_FRAME_MODE', 'MQL_LICENSE_TYPE', 'MQL_OPTIMIZATION', 'MQL_PROFILER', 'MQL_PROGRAM_NAME', 'MQL_PROGRAM_PATH', 'MQL_PROGRAM_TYPE', 'MQL_TESTER', 'MQL_TRADE_ALLOWED', 'MQL_VISUAL_MODE', 'M_1_PI', 'M_2_PI', 'M_2_SQRTPI', 'M_E', 'M_LN2', 'M_LN10', 'M_LOG2E', 'M_LOG10E', 'M_PI', 'M_PI_2', 'M_PI_4', 'M_SQRT1_2', 'M_SQRT2', 'NULL', 'OBJPROP_ALIGN', 'OBJPROP_ANCHOR', 'OBJPROP_ANGLE', 'OBJPROP_ARROWCODE', 'OBJPROP_BACK', 'OBJPROP_BGCOLOR', 'OBJPROP_BMPFILE', 'OBJPROP_BORDER_COLOR', 'OBJPROP_BORDER_TYPE', 'OBJPROP_CHART_ID', 'OBJPROP_CHART_SCALE', 'OBJPROP_COLOR', 'OBJPROP_CORNER', 'OBJPROP_CREATETIME', 'OBJPROP_DATE_SCALE', 'OBJPROP_DEVIATION', 'OBJPROP_DRAWLINES', 'OBJPROP_ELLIPSE', 'OBJPROP_FIBOLEVELS', 'OBJPROP_FILL', 'OBJPROP_FIRSTLEVEL', 'OBJPROP_FONTSIZE', 'OBJPROP_FONT', 'OBJPROP_HIDDEN', 'OBJPROP_LEVELCOLOR', 'OBJPROP_LEVELSTYLE', 'OBJPROP_LEVELS', 'OBJPROP_LEVELTEXT', 'OBJPROP_LEVELVALUE', 'OBJPROP_LEVELWIDTH', 'OBJPROP_NAME', 'OBJPROP_PERIOD', 'OBJPROP_PRICE1', 'OBJPROP_PRICE2', 'OBJPROP_PRICE3', 'OBJPROP_PRICE', 'OBJPROP_PRICE_SCALE', 'OBJPROP_RAY', 'OBJPROP_RAY_RIGHT', 'OBJPROP_READONLY', 'OBJPROP_SCALE', 'OBJPROP_SELECTABLE', 'OBJPROP_SELECTED', 'OBJPROP_STATE', 'OBJPROP_STYLE', 'OBJPROP_SYMBOL', 'OBJPROP_TEXT', 'OBJPROP_TIME1', 'OBJPROP_TIME2', 'OBJPROP_TIME3', 'OBJPROP_TIMEFRAMES', 'OBJPROP_TIME', 'OBJPROP_TOOLTIP', 'OBJPROP_TYPE', 'OBJPROP_WIDTH', 'OBJPROP_XDISTANCE', 'OBJPROP_XOFFSET', 'OBJPROP_XSIZE', 'OBJPROP_YDISTANCE', 'OBJPROP_YOFFSET', 'OBJPROP_YSIZE', 'OBJPROP_ZORDER', 'OBJ_ALL_PERIODS', 'OBJ_ARROW', 'OBJ_ARROW_BUY', 'OBJ_ARROW_CHECK', 'OBJ_ARROW_DOWN', 'OBJ_ARROW_LEFT_PRICE', 'OBJ_ARROW_RIGHT_PRICE', 'OBJ_ARROW_SELL', 'OBJ_ARROW_STOP', 'OBJ_ARROW_THUMB_DOWN', 'OBJ_ARROW_THUMB_UP', 'OBJ_ARROW_UP', 'OBJ_BITMAP', 'OBJ_BITMAP_LABEL', 'OBJ_BUTTON', 'OBJ_CHANNEL', 'OBJ_CYCLES', 'OBJ_EDIT', 'OBJ_ELLIPSE', 'OBJ_EVENT', 'OBJ_EXPANSION', 'OBJ_FIBOARC', 'OBJ_FIBOCHANNEL', 'OBJ_FIBOFAN', 'OBJ_FIBOTIMES', 'OBJ_FIBO', 'OBJ_GANNFAN', 'OBJ_GANNGRID', 'OBJ_GANNLINE', 'OBJ_HLINE', 'OBJ_LABEL', 'OBJ_NO_PERIODS', 'OBJ_PERIOD_D1', 'OBJ_PERIOD_H1', 'OBJ_PERIOD_H4', 'OBJ_PERIOD_M1', 'OBJ_PERIOD_M5', 'OBJ_PERIOD_M15', 'OBJ_PERIOD_M30', 'OBJ_PERIOD_MN1', 'OBJ_PERIOD_W1', 'OBJ_PITCHFORK', 'OBJ_RECTANGLE', 'OBJ_RECTANGLE_LABEL', 'OBJ_REGRESSION', 'OBJ_STDDEVCHANNEL', 'OBJ_TEXT', 'OBJ_TRENDBYANGLE', 'OBJ_TREND', 'OBJ_TRIANGLE', 'OBJ_VLINE', 'OP_BUYLIMIT', 'OP_BUYSTOP', 'OP_BUY', 'OP_SELLLIMIT', 'OP_SELLSTOP', 'OP_SELL', 'PERIOD_CURRENT', 'PERIOD_D1', 'PERIOD_H1', 'PERIOD_H2', 'PERIOD_H3', 'PERIOD_H4', 'PERIOD_H6', 'PERIOD_H8', 'PERIOD_H12', 'PERIOD_M1', 'PERIOD_M2', 'PERIOD_M3', 'PERIOD_M4', 'PERIOD_M5', 'PERIOD_M6', 'PERIOD_M10', 'PERIOD_M12', 'PERIOD_M15', 'PERIOD_M20', 'PERIOD_M30', 'PERIOD_MN1', 'PERIOD_W1', 'POINTER_AUTOMATIC', 'POINTER_DYNAMIC', 'POINTER_INVALID', 'PRICE_CLOSE', 'PRICE_HIGH', 'PRICE_LOW', 'PRICE_MEDIAN', 'PRICE_OPEN', 'PRICE_TYPICAL', 'PRICE_WEIGHTED', 'PROGRAM_EXPERT', 'PROGRAM_INDICATOR', 'PROGRAM_SCRIPT', 'REASON_ACCOUNT', 'REASON_CHARTCHANGE', 'REASON_CHARTCLOSE', 'REASON_CLOSE', 'REASON_INITFAILED', 'REASON_PARAMETERS', 'REASON_PROGRAM' 'REASON_RECOMPILE', 'REASON_REMOVE', 'REASON_TEMPLATE', 'SATURDAY', 'SEEK_CUR', 'SEEK_END', 'SEEK_SET', 'SERIES_BARS_COUNT', 'SERIES_FIRSTDATE', 'SERIES_LASTBAR_DATE', 'SERIES_SERVER_FIRSTDATE', 'SERIES_SYNCHRONIZED', 'SERIES_TERMINAL_FIRSTDATE', 'SHORT_MAX', 'SHORT_MIN', 'STAT_BALANCEDD_PERCENT', 'STAT_BALANCEMIN', 'STAT_BALANCE_DDREL_PERCENT', 'STAT_BALANCE_DD', 'STAT_BALANCE_DD_RELATIVE', 'STAT_CONLOSSMAX', 'STAT_CONLOSSMAX_TRADES', 'STAT_CONPROFITMAX', 'STAT_CONPROFITMAX_TRADES', 'STAT_CUSTOM_ONTESTER', 'STAT_DEALS', 'STAT_EQUITYDD_PERCENT', 'STAT_EQUITYMIN', 'STAT_EQUITY_DDREL_PERCENT', 'STAT_EQUITY_DD', 'STAT_EQUITY_DD_RELATIVE', 'STAT_EXPECTED_PAYOFF', 'STAT_GROSS_LOSS', 'STAT_GROSS_PROFIT', 'STAT_INITIAL_DEPOSIT', 'STAT_LONG_TRADES', 'STAT_LOSSTRADES_AVGCON', 'STAT_LOSS_TRADES', 'STAT_MAX_CONLOSSES', 'STAT_MAX_CONLOSS_TRADES', 'STAT_MAX_CONPROFIT_TRADES', 'STAT_MAX_CONWINS', 'STAT_MAX_LOSSTRADE', 'STAT_MAX_PROFITTRADE', 'STAT_MIN_MARGINLEVEL', 'STAT_PROFITTRADES_AVGCON', 'STAT_PROFIT', 'STAT_PROFIT_FACTOR', 'STAT_PROFIT_LONGTRADES', 'STAT_PROFIT_SHORTTRADES', 'STAT_PROFIT_TRADES', 'STAT_RECOVERY_FACTOR', 'STAT_SHARPE_RATIO', 'STAT_SHORT_TRADES', 'STAT_TRADES', 'STAT_WITHDRAWAL', 'STO_CLOSECLOSE', 'STO_LOWHIGH', 'STYLE_DASHDOTDOT', 'STYLE_DASHDOT', 'STYLE_DASH', 'STYLE_DOT', 'STYLE_SOLID', 'SUNDAY', 'SYMBOL_ARROWDOWN', 'SYMBOL_ARROWUP', 'SYMBOL_CHECKSIGN', 'SYMBOL_LEFTPRICE', 'SYMBOL_RIGHTPRICE', 'SYMBOL_STOPSIGN', 'SYMBOL_THUMBSDOWN', 'SYMBOL_THUMBSUP', 'TERMINAL_BUILD', 'TERMINAL_CODEPAGE', 'TERMINAL_COMMONDATA_PATH', 'TERMINAL_COMPANY', 'TERMINAL_CONNECTED', 'TERMINAL_CPU_CORES', 'TERMINAL_DATA_PATH', 'TERMINAL_DISK_SPACE', 'TERMINAL_DLLS_ALLOWED', 'TERMINAL_EMAIL_ENABLED', 'TERMINAL_FTP_ENABLED', 'TERMINAL_LANGUAGE', 'TERMINAL_MAXBARS', 'TERMINAL_MEMORY_AVAILABLE', 'TERMINAL_MEMORY_PHYSICAL', 'TERMINAL_MEMORY_TOTAL', 'TERMINAL_MEMORY_USED', 'TERMINAL_NAME', 'TERMINAL_OPENCL_SUPPORT', 'TERMINAL_PATH', 'TERMINAL_TRADE_ALLOWED', 'TERMINAL_X64', 'THURSDAY', 'TRADE_ACTION_DEAL', 'TRADE_ACTION_MODIFY', 'TRADE_ACTION_PENDING', 'TRADE_ACTION_REMOVE', 'TRADE_ACTION_SLTP', 'TUESDAY', 'UCHAR_MAX', 'UINT_MAX', 'ULONG_MAX', 'USHORT_MAX', 'VOLUME_REAL', 'VOLUME_TICK', 'WEDNESDAY', 'WHOLE_ARRAY', 'WRONG_VALUE', 'clrNONE', '__DATETIME__', '__DATE__', '__FILE__', '__FUNCSIG__', '__FUNCTION__', '__LINE__', '__MQL4BUILD__', '__MQLBUILD__', '__PATH__', ) colors = ( 'AliceBlue', 'AntiqueWhite', 'Aquamarine', 'Aqua', 'Beige', 'Bisque', 'Black', 'BlanchedAlmond', 'BlueViolet', 'Blue', 'Brown', 'BurlyWood', 'CadetBlue', 'Chartreuse', 'Chocolate', 'Coral', 'CornflowerBlue', 'Cornsilk', 'Crimson', 'DarkBlue', 'DarkGoldenrod', 'DarkGray', 'DarkGreen', 'DarkKhaki', 'DarkOliveGreen', 'DarkOrange', 'DarkOrchid', 'DarkSalmon', 'DarkSeaGreen', 'DarkSlateBlue', 'DarkSlateGray', 'DarkTurquoise', 'DarkViolet', 'DeepPink', 'DeepSkyBlue', 'DimGray', 'DodgerBlue', 'FireBrick', 'ForestGreen', 'Gainsboro', 'Goldenrod', 'Gold', 'Gray', 'GreenYellow', 'Green', 'Honeydew', 'HotPink', 'IndianRed', 'Indigo', 'Ivory', 'Khaki', 'LavenderBlush', 'Lavender', 'LawnGreen', 'LemonChiffon', 'LightBlue', 'LightCoral', 'LightCyan', 'LightGoldenrod', 'LightGray', 'LightGreen', 'LightPink', 'LightSalmon', 'LightSeaGreen', 'LightSkyBlue', 'LightSlateGray', 'LightSteelBlue', 'LightYellow', 'LimeGreen', 'Lime', 'Linen', 'Magenta', 'Maroon', 'MediumAquamarine', 'MediumBlue', 'MediumOrchid', 'MediumPurple', 'MediumSeaGreen', 'MediumSlateBlue', 'MediumSpringGreen', 'MediumTurquoise', 'MediumVioletRed', 'MidnightBlue', 'MintCream', 'MistyRose', 'Moccasin', 'NavajoWhite', 'Navy', 'OldLace', 'OliveDrab', 'Olive', 'OrangeRed', 'Orange', 'Orchid', 'PaleGoldenrod', 'PaleGreen', 'PaleTurquoise', 'PaleVioletRed', 'PapayaWhip', 'PeachPuff', 'Peru', 'Pink', 'Plum', 'PowderBlue', 'Purple', 'Red', 'RosyBrown', 'RoyalBlue', 'SaddleBrown', 'Salmon', 'SandyBrown', 'SeaGreen', 'Seashell', 'Sienna', 'Silver', 'SkyBlue', 'SlateBlue', 'SlateGray', 'Snow', 'SpringGreen', 'SteelBlue', 'Tan', 'Teal', 'Thistle', 'Tomato', 'Turquoise', 'Violet', 'Wheat', 'WhiteSmoke', 'White', 'YellowGreen', 'Yellow', ) keywords = ( 'input', '_Digits', '_Point', '_LastError', '_Period', '_RandomSeed', '_StopFlag', '_Symbol', '_UninitReason', 'Ask', 'Bars', 'Bid', 'Close', 'Digits', 'High', 'Low', 'Open', 'Point', 'Time', 'Volume', ) c_types = ( 'void', 'char', 'uchar', 'bool', 'short', 'ushort', 'int', 'uint', 'color', 'long', 'ulong', 'datetime', 'float', 'double', 'string', )
24,713
Python
20.087031
73
0.579533
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/yang.py
""" pygments.lexers.yang ~~~~~~~~~~~~~~~~~~~~ Lexer for the YANG 1.1 modeling language. See :rfc:`7950`. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, bygroups, words from pygments.token import Text, Token, Name, String, Comment, Number __all__ = ['YangLexer'] class YangLexer(RegexLexer): """ Lexer for YANG, based on RFC7950. .. versionadded:: 2.7 """ name = 'YANG' url = 'https://tools.ietf.org/html/rfc7950/' aliases = ['yang'] filenames = ['*.yang'] mimetypes = ['application/yang'] #Keywords from RFC7950 ; oriented at BNF style TOP_STMTS_KEYWORDS = ("module", "submodule") MODULE_HEADER_STMT_KEYWORDS = ("belongs-to", "namespace", "prefix", "yang-version") META_STMT_KEYWORDS = ("contact", "description", "organization", "reference", "revision") LINKAGE_STMTS_KEYWORDS = ("import", "include", "revision-date") BODY_STMT_KEYWORDS = ("action", "argument", "augment", "deviation", "extension", "feature", "grouping", "identity", "if-feature", "input", "notification", "output", "rpc", "typedef") DATA_DEF_STMT_KEYWORDS = ("anydata", "anyxml", "case", "choice", "config", "container", "deviate", "leaf", "leaf-list", "list", "must", "presence", "refine", "uses", "when") TYPE_STMT_KEYWORDS = ("base", "bit", "default", "enum", "error-app-tag", "error-message", "fraction-digits", "length", "max-elements", "min-elements", "modifier", "ordered-by", "path", "pattern", "position", "range", "require-instance", "status", "type", "units", "value", "yin-element") LIST_STMT_KEYWORDS = ("key", "mandatory", "unique") #RFC7950 other keywords CONSTANTS_KEYWORDS = ("add", "current", "delete", "deprecated", "false", "invert-match", "max", "min", "not-supported", "obsolete", "replace", "true", "unbounded", "user") #RFC7950 Built-In Types TYPES = ("binary", "bits", "boolean", "decimal64", "empty", "enumeration", "identityref", "instance-identifier", "int16", "int32", "int64", "int8", "leafref", "string", "uint16", "uint32", "uint64", "uint8", "union") suffix_re_pattern = r'(?=[^\w\-:])' tokens = { 'comments': [ (r'[^*/]', Comment), (r'/\*', Comment, '#push'), (r'\*/', Comment, '#pop'), (r'[*/]', Comment), ], "root": [ (r'\s+', Text.Whitespace), (r'[{};]+', Token.Punctuation), (r'(?<![\-\w])(and|or|not|\+|\.)(?![\-\w])', Token.Operator), (r'"(?:\\"|[^"])*?"', String.Double), (r"'(?:\\'|[^'])*?'", String.Single), (r'/\*', Comment, 'comments'), (r'//.*?$', Comment), #match BNF stmt for `node-identifier` with [ prefix ":"] (r'(?:^|(?<=[\s{};]))([\w.-]+)(:)([\w.-]+)(?=[\s{};])', bygroups(Name.Namespace, Token.Punctuation, Name.Variable)), #match BNF stmt `date-arg-str` (r'([0-9]{4}\-[0-9]{2}\-[0-9]{2})(?=[\s{};])', Name.Label), (r'([0-9]+\.[0-9]+)(?=[\s{};])', Number.Float), (r'([0-9]+)(?=[\s{};])', Number.Integer), (words(TOP_STMTS_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(MODULE_HEADER_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(META_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(LINKAGE_STMTS_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(BODY_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(DATA_DEF_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(TYPE_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(LIST_STMT_KEYWORDS, suffix=suffix_re_pattern), Token.Keyword), (words(TYPES, suffix=suffix_re_pattern), Name.Class), (words(CONSTANTS_KEYWORDS, suffix=suffix_re_pattern), Name.Class), (r'[^;{}\s\'"]+', Name.Variable), ] }
4,500
Python
41.866666
90
0.505556
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/typoscript.py
""" pygments.lexers.typoscript ~~~~~~~~~~~~~~~~~~~~~~~~~~ Lexers for TypoScript `TypoScriptLexer` A TypoScript lexer. `TypoScriptCssDataLexer` Lexer that highlights markers, constants and registers within css. `TypoScriptHtmlDataLexer` Lexer that highlights markers, constants and registers within html tags. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, include, bygroups, using from pygments.token import Text, Comment, Name, String, Number, \ Operator, Punctuation __all__ = ['TypoScriptLexer', 'TypoScriptCssDataLexer', 'TypoScriptHtmlDataLexer'] class TypoScriptCssDataLexer(RegexLexer): """ Lexer that highlights markers, constants and registers within css blocks. .. versionadded:: 2.2 """ name = 'TypoScriptCssData' aliases = ['typoscriptcssdata'] tokens = { 'root': [ # marker: ###MARK### (r'(.*)(###\w+###)(.*)', bygroups(String, Name.Constant, String)), # constant: {$some.constant} (r'(\{)(\$)((?:[\w\-]+\.)*)([\w\-]+)(\})', bygroups(String.Symbol, Operator, Name.Constant, Name.Constant, String.Symbol)), # constant # constant: {register:somevalue} (r'(.*)(\{)([\w\-]+)(\s*:\s*)([\w\-]+)(\})(.*)', bygroups(String, String.Symbol, Name.Constant, Operator, Name.Constant, String.Symbol, String)), # constant # whitespace (r'\s+', Text), # comments (r'/\*(?:(?!\*/).)*\*/', Comment), (r'(?<!(#|\'|"))(?:#(?!(?:[a-fA-F0-9]{6}|[a-fA-F0-9]{3}))[^\n#]+|//[^\n]*)', Comment), # other (r'[<>,:=.*%+|]', String), (r'[\w"\-!/&;(){}]+', String), ] } class TypoScriptHtmlDataLexer(RegexLexer): """ Lexer that highlights markers, constants and registers within html tags. .. versionadded:: 2.2 """ name = 'TypoScriptHtmlData' aliases = ['typoscripthtmldata'] tokens = { 'root': [ # INCLUDE_TYPOSCRIPT (r'(INCLUDE_TYPOSCRIPT)', Name.Class), # Language label or extension resource FILE:... or LLL:... or EXT:... (r'(EXT|FILE|LLL):[^}\n"]*', String), # marker: ###MARK### (r'(.*)(###\w+###)(.*)', bygroups(String, Name.Constant, String)), # constant: {$some.constant} (r'(\{)(\$)((?:[\w\-]+\.)*)([\w\-]+)(\})', bygroups(String.Symbol, Operator, Name.Constant, Name.Constant, String.Symbol)), # constant # constant: {register:somevalue} (r'(.*)(\{)([\w\-]+)(\s*:\s*)([\w\-]+)(\})(.*)', bygroups(String, String.Symbol, Name.Constant, Operator, Name.Constant, String.Symbol, String)), # constant # whitespace (r'\s+', Text), # other (r'[<>,:=.*%+|]', String), (r'[\w"\-!/&;(){}#]+', String), ] } class TypoScriptLexer(RegexLexer): """ Lexer for TypoScript code. .. versionadded:: 2.2 """ name = 'TypoScript' url = 'http://docs.typo3.org/typo3cms/TyposcriptReference/' aliases = ['typoscript'] filenames = ['*.typoscript'] mimetypes = ['text/x-typoscript'] flags = re.DOTALL | re.MULTILINE tokens = { 'root': [ include('comment'), include('constant'), include('html'), include('label'), include('whitespace'), include('keywords'), include('punctuation'), include('operator'), include('structure'), include('literal'), include('other'), ], 'keywords': [ # Conditions (r'(?i)(\[)(browser|compatVersion|dayofmonth|dayofweek|dayofyear|' r'device|ELSE|END|GLOBAL|globalString|globalVar|hostname|hour|IP|' r'language|loginUser|loginuser|minute|month|page|PIDinRootline|' r'PIDupinRootline|system|treeLevel|useragent|userFunc|usergroup|' r'version)([^\]]*)(\])', bygroups(String.Symbol, Name.Constant, Text, String.Symbol)), # Functions (r'(?=[\w\-])(HTMLparser|HTMLparser_tags|addParams|cache|encapsLines|' r'filelink|if|imageLinkWrap|imgResource|makelinks|numRows|numberFormat|' r'parseFunc|replacement|round|select|split|stdWrap|strPad|tableStyle|' r'tags|textStyle|typolink)(?![\w\-])', Name.Function), # Toplevel objects and _* (r'(?:(=?\s*<?\s+|^\s*))(cObj|field|config|content|constants|FEData|' r'file|frameset|includeLibs|lib|page|plugin|register|resources|sitemap|' r'sitetitle|styles|temp|tt_[^:.\s]*|types|xmlnews|INCLUDE_TYPOSCRIPT|' r'_CSS_DEFAULT_STYLE|_DEFAULT_PI_VARS|_LOCAL_LANG)(?![\w\-])', bygroups(Operator, Name.Builtin)), # Content objects (r'(?=[\w\-])(CASE|CLEARGIF|COA|COA_INT|COBJ_ARRAY|COLUMNS|CONTENT|' r'CTABLE|EDITPANEL|FILE|FILES|FLUIDTEMPLATE|FORM|HMENU|HRULER|HTML|' r'IMAGE|IMGTEXT|IMG_RESOURCE|LOAD_REGISTER|MEDIA|MULTIMEDIA|OTABLE|' r'PAGE|QTOBJECT|RECORDS|RESTORE_REGISTER|SEARCHRESULT|SVG|SWFOBJECT|' r'TEMPLATE|TEXT|USER|USER_INT)(?![\w\-])', Name.Class), # Menu states (r'(?=[\w\-])(ACTIFSUBRO|ACTIFSUB|ACTRO|ACT|CURIFSUBRO|CURIFSUB|CURRO|' r'CUR|IFSUBRO|IFSUB|NO|SPC|USERDEF1RO|USERDEF1|USERDEF2RO|USERDEF2|' r'USRRO|USR)', Name.Class), # Menu objects (r'(?=[\w\-])(GMENU_FOLDOUT|GMENU_LAYERS|GMENU|IMGMENUITEM|IMGMENU|' r'JSMENUITEM|JSMENU|TMENUITEM|TMENU_LAYERS|TMENU)', Name.Class), # PHP objects (r'(?=[\w\-])(PHP_SCRIPT(_EXT|_INT)?)', Name.Class), (r'(?=[\w\-])(userFunc)(?![\w\-])', Name.Function), ], 'whitespace': [ (r'\s+', Text), ], 'html': [ (r'<\S[^\n>]*>', using(TypoScriptHtmlDataLexer)), (r'&[^;\n]*;', String), (r'(?s)(_CSS_DEFAULT_STYLE)(\s*)(\()(.*(?=\n\)))', bygroups(Name.Class, Text, String.Symbol, using(TypoScriptCssDataLexer))), ], 'literal': [ (r'0x[0-9A-Fa-f]+t?', Number.Hex), # (r'[0-9]*\.[0-9]+([eE][0-9]+)?[fd]?\s*(?:[^=])', Number.Float), (r'[0-9]+', Number.Integer), (r'(###\w+###)', Name.Constant), ], 'label': [ # Language label or extension resource FILE:... or LLL:... or EXT:... (r'(EXT|FILE|LLL):[^}\n"]*', String), # Path to a resource (r'(?![^\w\-])([\w\-]+(?:/[\w\-]+)+/?)(\S*\n)', bygroups(String, String)), ], 'punctuation': [ (r'[,.]', Punctuation), ], 'operator': [ (r'[<>,:=.*%+|]', Operator), ], 'structure': [ # Brackets and braces (r'[{}()\[\]\\]', String.Symbol), ], 'constant': [ # Constant: {$some.constant} (r'(\{)(\$)((?:[\w\-]+\.)*)([\w\-]+)(\})', bygroups(String.Symbol, Operator, Name.Constant, Name.Constant, String.Symbol)), # constant # Constant: {register:somevalue} (r'(\{)([\w\-]+)(\s*:\s*)([\w\-]+)(\})', bygroups(String.Symbol, Name.Constant, Operator, Name.Constant, String.Symbol)), # constant # Hex color: #ff0077 (r'(#[a-fA-F0-9]{6}\b|#[a-fA-F0-9]{3}\b)', String.Char) ], 'comment': [ (r'(?<!(#|\'|"))(?:#(?!(?:[a-fA-F0-9]{6}|[a-fA-F0-9]{3}))[^\n#]+|//[^\n]*)', Comment), (r'/\*(?:(?!\*/).)*\*/', Comment), (r'(\s*#\s*\n)', Comment), ], 'other': [ (r'[\w"\-!/&;]+', Text), ], }
8,207
Python
36.651376
88
0.485805
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/sophia.py
""" pygments.lexers.sophia ~~~~~~~~~~~~~~~~~~~~~~ Lexer for Sophia. Derived from pygments/lexers/reason.py. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, include, default, words from pygments.token import Comment, Keyword, Name, Number, Operator, \ Punctuation, String, Text __all__ = ['SophiaLexer'] class SophiaLexer(RegexLexer): """ A Sophia lexer. .. versionadded:: 2.11 """ name = 'Sophia' aliases = ['sophia'] filenames = ['*.aes'] mimetypes = [] keywords = ( 'contract', 'include', 'let', 'switch', 'type', 'record', 'datatype', 'if', 'elif', 'else', 'function', 'stateful', 'payable', 'public', 'entrypoint', 'private', 'indexed', 'namespace', 'interface', 'main', 'using', 'as', 'for', 'hiding', ) builtins = ('state', 'put', 'abort', 'require') word_operators = ('mod', 'band', 'bor', 'bxor', 'bnot') primitive_types = ('int', 'address', 'bool', 'bits', 'bytes', 'string', 'list', 'option', 'char', 'unit', 'map', 'event', 'hash', 'signature', 'oracle', 'oracle_query') tokens = { 'escape-sequence': [ (r'\\[\\"\'ntbr]', String.Escape), (r'\\[0-9]{3}', String.Escape), (r'\\x[0-9a-fA-F]{2}', String.Escape), ], 'root': [ (r'\s+', Text.Whitespace), (r'(true|false)\b', Keyword.Constant), (r'\b([A-Z][\w\']*)(?=\s*\.)', Name.Class, 'dotted'), (r'\b([A-Z][\w\']*)', Name.Function), (r'//.*?\n', Comment.Single), (r'\/\*(?!/)', Comment.Multiline, 'comment'), (r'0[xX][\da-fA-F][\da-fA-F_]*', Number.Hex), (r'#[\da-fA-F][\da-fA-F_]*', Name.Label), (r'\d[\d_]*', Number.Integer), (words(keywords, suffix=r'\b'), Keyword), (words(builtins, suffix=r'\b'), Name.Builtin), (words(word_operators, prefix=r'\b', suffix=r'\b'), Operator.Word), (words(primitive_types, prefix=r'\b', suffix=r'\b'), Keyword.Type), (r'[=!<>+\\*/:&|?~@^-]', Operator.Word), (r'[.;:{}(),\[\]]', Punctuation), (r"(ak_|ok_|oq_|ct_)[\w']*", Name.Label), (r"[^\W\d][\w']*", Name), (r"'(?:(\\[\\\"'ntbr ])|(\\[0-9]{3})|(\\x[0-9a-fA-F]{2}))'", String.Char), (r"'.'", String.Char), (r"'[a-z][\w]*", Name.Variable), (r'"', String.Double, 'string') ], 'comment': [ (r'[^/*]+', Comment.Multiline), (r'\/\*', Comment.Multiline, '#push'), (r'\*\/', Comment.Multiline, '#pop'), (r'\*', Comment.Multiline), ], 'string': [ (r'[^\\"]+', String.Double), include('escape-sequence'), (r'\\\n', String.Double), (r'"', String.Double, '#pop'), ], 'dotted': [ (r'\s+', Text), (r'\.', Punctuation), (r'[A-Z][\w\']*(?=\s*\.)', Name.Function), (r'[A-Z][\w\']*', Name.Function, '#pop'), (r'[a-z_][\w\']*', Name, '#pop'), default('#pop'), ], }
3,330
Python
31.028846
79
0.439339
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/int_fiction.py
""" pygments.lexers.int_fiction ~~~~~~~~~~~~~~~~~~~~~~~~~~~ Lexers for interactive fiction languages. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, include, bygroups, using, \ this, default, words from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Error, Generic __all__ = ['Inform6Lexer', 'Inform6TemplateLexer', 'Inform7Lexer', 'Tads3Lexer'] class Inform6Lexer(RegexLexer): """ For Inform 6 source code. .. versionadded:: 2.0 """ name = 'Inform 6' url = 'http://inform-fiction.org/' aliases = ['inform6', 'i6'] filenames = ['*.inf'] flags = re.MULTILINE | re.DOTALL _name = r'[a-zA-Z_]\w*' # Inform 7 maps these four character classes to their ASCII # equivalents. To support Inform 6 inclusions within Inform 7, # Inform6Lexer maps them too. _dash = '\\-\u2010-\u2014' _dquote = '"\u201c\u201d' _squote = "'\u2018\u2019" _newline = '\\n\u0085\u2028\u2029' tokens = { 'root': [ (r'\A(!%%[^%s]*[%s])+' % (_newline, _newline), Comment.Preproc, 'directive'), default('directive') ], '_whitespace': [ (r'\s+', Text), (r'![^%s]*' % _newline, Comment.Single) ], 'default': [ include('_whitespace'), (r'\[', Punctuation, 'many-values'), # Array initialization (r':|(?=;)', Punctuation, '#pop'), (r'<', Punctuation), # Second angle bracket in an action statement default(('expression', '_expression')) ], # Expressions '_expression': [ include('_whitespace'), (r'(?=sp\b)', Text, '#pop'), (r'(?=[%s%s$0-9#a-zA-Z_])' % (_dquote, _squote), Text, ('#pop', 'value')), (r'\+\+|[%s]{1,2}(?!>)|~~?' % _dash, Operator), (r'(?=[()\[%s,?@{:;])' % _dash, Text, '#pop') ], 'expression': [ include('_whitespace'), (r'\(', Punctuation, ('expression', '_expression')), (r'\)', Punctuation, '#pop'), (r'\[', Punctuation, ('#pop', 'statements', 'locals')), (r'>(?=(\s+|(![^%s]*))*[>;])' % _newline, Punctuation), (r'\+\+|[%s]{2}(?!>)' % _dash, Operator), (r',', Punctuation, '_expression'), (r'&&?|\|\|?|[=~><]?=|[%s]{1,2}>?|\.\.?[&#]?|::|[<>+*/%%]' % _dash, Operator, '_expression'), (r'(has|hasnt|in|notin|ofclass|or|provides)\b', Operator.Word, '_expression'), (r'sp\b', Name), (r'\?~?', Name.Label, 'label?'), (r'[@{]', Error), default('#pop') ], '_assembly-expression': [ (r'\(', Punctuation, ('#push', '_expression')), (r'[\[\]]', Punctuation), (r'[%s]>' % _dash, Punctuation, '_expression'), (r'sp\b', Keyword.Pseudo), (r';', Punctuation, '#pop:3'), include('expression') ], '_for-expression': [ (r'\)', Punctuation, '#pop:2'), (r':', Punctuation, '#pop'), include('expression') ], '_keyword-expression': [ (r'(from|near|to)\b', Keyword, '_expression'), include('expression') ], '_list-expression': [ (r',', Punctuation, '#pop'), include('expression') ], '_object-expression': [ (r'has\b', Keyword.Declaration, '#pop'), include('_list-expression') ], # Values 'value': [ include('_whitespace'), # Strings (r'[%s][^@][%s]' % (_squote, _squote), String.Char, '#pop'), (r'([%s])(@\{[0-9a-fA-F]*\})([%s])' % (_squote, _squote), bygroups(String.Char, String.Escape, String.Char), '#pop'), (r'([%s])(@.{2})([%s])' % (_squote, _squote), bygroups(String.Char, String.Escape, String.Char), '#pop'), (r'[%s]' % _squote, String.Single, ('#pop', 'dictionary-word')), (r'[%s]' % _dquote, String.Double, ('#pop', 'string')), # Numbers (r'\$[<>]?[+%s][0-9]*\.?[0-9]*([eE][+%s]?[0-9]+)?' % (_dash, _dash), Number.Float, '#pop'), (r'\$[0-9a-fA-F]+', Number.Hex, '#pop'), (r'\$\$[01]+', Number.Bin, '#pop'), (r'[0-9]+', Number.Integer, '#pop'), # Values prefixed by hashes (r'(##|#a\$)(%s)' % _name, bygroups(Operator, Name), '#pop'), (r'(#g\$)(%s)' % _name, bygroups(Operator, Name.Variable.Global), '#pop'), (r'#[nw]\$', Operator, ('#pop', 'obsolete-dictionary-word')), (r'(#r\$)(%s)' % _name, bygroups(Operator, Name.Function), '#pop'), (r'#', Name.Builtin, ('#pop', 'system-constant')), # System functions (words(( 'child', 'children', 'elder', 'eldest', 'glk', 'indirect', 'metaclass', 'parent', 'random', 'sibling', 'younger', 'youngest'), suffix=r'\b'), Name.Builtin, '#pop'), # Metaclasses (r'(?i)(Class|Object|Routine|String)\b', Name.Builtin, '#pop'), # Veneer routines (words(( 'Box__Routine', 'CA__Pr', 'CDefArt', 'CInDefArt', 'Cl__Ms', 'Copy__Primitive', 'CP__Tab', 'DA__Pr', 'DB__Pr', 'DefArt', 'Dynam__String', 'EnglishNumber', 'Glk__Wrap', 'IA__Pr', 'IB__Pr', 'InDefArt', 'Main__', 'Meta__class', 'OB__Move', 'OB__Remove', 'OC__Cl', 'OP__Pr', 'Print__Addr', 'Print__PName', 'PrintShortName', 'RA__Pr', 'RA__Sc', 'RL__Pr', 'R_Process', 'RT__ChG', 'RT__ChGt', 'RT__ChLDB', 'RT__ChLDW', 'RT__ChPR', 'RT__ChPrintA', 'RT__ChPrintC', 'RT__ChPrintO', 'RT__ChPrintS', 'RT__ChPS', 'RT__ChR', 'RT__ChSTB', 'RT__ChSTW', 'RT__ChT', 'RT__Err', 'RT__TrPS', 'RV__Pr', 'Symb__Tab', 'Unsigned__Compare', 'WV__Pr', 'Z__Region'), prefix='(?i)', suffix=r'\b'), Name.Builtin, '#pop'), # Other built-in symbols (words(( 'call', 'copy', 'create', 'DEBUG', 'destroy', 'DICT_CHAR_SIZE', 'DICT_ENTRY_BYTES', 'DICT_IS_UNICODE', 'DICT_WORD_SIZE', 'DOUBLE_HI_INFINITY', 'DOUBLE_HI_NAN', 'DOUBLE_HI_NINFINITY', 'DOUBLE_LO_INFINITY', 'DOUBLE_LO_NAN', 'DOUBLE_LO_NINFINITY', 'false', 'FLOAT_INFINITY', 'FLOAT_NAN', 'FLOAT_NINFINITY', 'GOBJFIELD_CHAIN', 'GOBJFIELD_CHILD', 'GOBJFIELD_NAME', 'GOBJFIELD_PARENT', 'GOBJFIELD_PROPTAB', 'GOBJFIELD_SIBLING', 'GOBJ_EXT_START', 'GOBJ_TOTAL_LENGTH', 'Grammar__Version', 'INDIV_PROP_START', 'INFIX', 'infix__watching', 'MODULE_MODE', 'name', 'nothing', 'NUM_ATTR_BYTES', 'print', 'print_to_array', 'recreate', 'remaining', 'self', 'sender', 'STRICT_MODE', 'sw__var', 'sys__glob0', 'sys__glob1', 'sys__glob2', 'sys_statusline_flag', 'TARGET_GLULX', 'TARGET_ZCODE', 'temp__global2', 'temp__global3', 'temp__global4', 'temp_global', 'true', 'USE_MODULES', 'WORDSIZE'), prefix='(?i)', suffix=r'\b'), Name.Builtin, '#pop'), # Other values (_name, Name, '#pop') ], 'value?': [ include('value'), default('#pop') ], # Strings 'dictionary-word': [ (r'[~^]+', String.Escape), (r'[^~^\\@({%s]+' % _squote, String.Single), (r'[({]', String.Single), (r'@\{[0-9a-fA-F]*\}', String.Escape), (r'@.{2}', String.Escape), (r'[%s]' % _squote, String.Single, '#pop') ], 'string': [ (r'[~^]+', String.Escape), (r'[^~^\\@({%s]+' % _dquote, String.Double), (r'[({]', String.Double), (r'\\', String.Escape), (r'@(\\\s*[%s]\s*)*@((\\\s*[%s]\s*)*[0-9])*' % (_newline, _newline), String.Escape), (r'@(\\\s*[%s]\s*)*[({]((\\\s*[%s]\s*)*[0-9a-zA-Z_])*' r'(\\\s*[%s]\s*)*[)}]' % (_newline, _newline, _newline), String.Escape), (r'@(\\\s*[%s]\s*)*.(\\\s*[%s]\s*)*.' % (_newline, _newline), String.Escape), (r'[%s]' % _dquote, String.Double, '#pop') ], 'plain-string': [ (r'[^~^\\({\[\]%s]+' % _dquote, String.Double), (r'[~^({\[\]]', String.Double), (r'\\', String.Escape), (r'[%s]' % _dquote, String.Double, '#pop') ], # Names '_constant': [ include('_whitespace'), (_name, Name.Constant, '#pop'), include('value') ], 'constant*': [ include('_whitespace'), (r',', Punctuation), (r'=', Punctuation, 'value?'), (_name, Name.Constant, 'value?'), default('#pop') ], '_global': [ include('_whitespace'), (_name, Name.Variable.Global, '#pop'), include('value') ], 'label?': [ include('_whitespace'), (_name, Name.Label, '#pop'), default('#pop') ], 'variable?': [ include('_whitespace'), (_name, Name.Variable, '#pop'), default('#pop') ], # Values after hashes 'obsolete-dictionary-word': [ (r'\S\w*', String.Other, '#pop') ], 'system-constant': [ include('_whitespace'), (_name, Name.Builtin, '#pop') ], # Directives 'directive': [ include('_whitespace'), (r'#', Punctuation), (r';', Punctuation, '#pop'), (r'\[', Punctuation, ('default', 'statements', 'locals', 'routine-name?')), (words(( 'abbreviate', 'endif', 'dictionary', 'ifdef', 'iffalse', 'ifndef', 'ifnot', 'iftrue', 'ifv3', 'ifv5', 'release', 'serial', 'switches', 'system_file', 'version'), prefix='(?i)', suffix=r'\b'), Keyword, 'default'), (r'(?i)(array|global)\b', Keyword, ('default', 'directive-keyword?', '_global')), (r'(?i)attribute\b', Keyword, ('default', 'alias?', '_constant')), (r'(?i)class\b', Keyword, ('object-body', 'duplicates', 'class-name')), (r'(?i)(constant|default)\b', Keyword, ('default', 'constant*')), (r'(?i)(end\b)(.*)', bygroups(Keyword, Text)), (r'(?i)(extend|verb)\b', Keyword, 'grammar'), (r'(?i)fake_action\b', Keyword, ('default', '_constant')), (r'(?i)import\b', Keyword, 'manifest'), (r'(?i)(include|link|origsource)\b', Keyword, ('default', 'before-plain-string?')), (r'(?i)(lowstring|undef)\b', Keyword, ('default', '_constant')), (r'(?i)message\b', Keyword, ('default', 'diagnostic')), (r'(?i)(nearby|object)\b', Keyword, ('object-body', '_object-head')), (r'(?i)property\b', Keyword, ('default', 'alias?', '_constant', 'property-keyword*')), (r'(?i)replace\b', Keyword, ('default', 'routine-name?', 'routine-name?')), (r'(?i)statusline\b', Keyword, ('default', 'directive-keyword?')), (r'(?i)stub\b', Keyword, ('default', 'routine-name?')), (r'(?i)trace\b', Keyword, ('default', 'trace-keyword?', 'trace-keyword?')), (r'(?i)zcharacter\b', Keyword, ('default', 'directive-keyword?', 'directive-keyword?')), (_name, Name.Class, ('object-body', '_object-head')) ], # [, Replace, Stub 'routine-name?': [ include('_whitespace'), (_name, Name.Function, '#pop'), default('#pop') ], 'locals': [ include('_whitespace'), (r';', Punctuation, '#pop'), (r'\*', Punctuation), (r'"', String.Double, 'plain-string'), (_name, Name.Variable) ], # Array 'many-values': [ include('_whitespace'), (r';', Punctuation), (r'\]', Punctuation, '#pop'), (r':', Error), default(('expression', '_expression')) ], # Attribute, Property 'alias?': [ include('_whitespace'), (r'alias\b', Keyword, ('#pop', '_constant')), default('#pop') ], # Class, Object, Nearby 'class-name': [ include('_whitespace'), (r'(?=[,;]|(class|has|private|with)\b)', Text, '#pop'), (_name, Name.Class, '#pop') ], 'duplicates': [ include('_whitespace'), (r'\(', Punctuation, ('#pop', 'expression', '_expression')), default('#pop') ], '_object-head': [ (r'[%s]>' % _dash, Punctuation), (r'(class|has|private|with)\b', Keyword.Declaration, '#pop'), include('_global') ], 'object-body': [ include('_whitespace'), (r';', Punctuation, '#pop:2'), (r',', Punctuation), (r'class\b', Keyword.Declaration, 'class-segment'), (r'(has|private|with)\b', Keyword.Declaration), (r':', Error), default(('_object-expression', '_expression')) ], 'class-segment': [ include('_whitespace'), (r'(?=[,;]|(class|has|private|with)\b)', Text, '#pop'), (_name, Name.Class), default('value') ], # Extend, Verb 'grammar': [ include('_whitespace'), (r'=', Punctuation, ('#pop', 'default')), (r'\*', Punctuation, ('#pop', 'grammar-line')), default('_directive-keyword') ], 'grammar-line': [ include('_whitespace'), (r';', Punctuation, '#pop'), (r'[/*]', Punctuation), (r'[%s]>' % _dash, Punctuation, 'value'), (r'(noun|scope)\b', Keyword, '=routine'), default('_directive-keyword') ], '=routine': [ include('_whitespace'), (r'=', Punctuation, 'routine-name?'), default('#pop') ], # Import 'manifest': [ include('_whitespace'), (r';', Punctuation, '#pop'), (r',', Punctuation), (r'(?i)global\b', Keyword, '_global'), default('_global') ], # Include, Link, Message 'diagnostic': [ include('_whitespace'), (r'[%s]' % _dquote, String.Double, ('#pop', 'message-string')), default(('#pop', 'before-plain-string?', 'directive-keyword?')) ], 'before-plain-string?': [ include('_whitespace'), (r'[%s]' % _dquote, String.Double, ('#pop', 'plain-string')), default('#pop') ], 'message-string': [ (r'[~^]+', String.Escape), include('plain-string') ], # Keywords used in directives '_directive-keyword!': [ include('_whitespace'), (words(( 'additive', 'alias', 'buffer', 'class', 'creature', 'data', 'error', 'fatalerror', 'first', 'has', 'held', 'individual', 'initial', 'initstr', 'last', 'long', 'meta', 'multi', 'multiexcept', 'multiheld', 'multiinside', 'noun', 'number', 'only', 'private', 'replace', 'reverse', 'scope', 'score', 'special', 'string', 'table', 'terminating', 'time', 'topic', 'warning', 'with'), suffix=r'\b'), Keyword, '#pop'), (r'static\b', Keyword), (r'[%s]{1,2}>|[+=]' % _dash, Punctuation, '#pop') ], '_directive-keyword': [ include('_directive-keyword!'), include('value') ], 'directive-keyword?': [ include('_directive-keyword!'), default('#pop') ], 'property-keyword*': [ include('_whitespace'), (words(('additive', 'individual', 'long'), suffix=r'\b(?=(\s*|(![^%s]*[%s]))*[_a-zA-Z])' % (_newline, _newline)), Keyword), default('#pop') ], 'trace-keyword?': [ include('_whitespace'), (words(( 'assembly', 'dictionary', 'expressions', 'lines', 'linker', 'objects', 'off', 'on', 'symbols', 'tokens', 'verbs'), suffix=r'\b'), Keyword, '#pop'), default('#pop') ], # Statements 'statements': [ include('_whitespace'), (r'\]', Punctuation, '#pop'), (r'[;{}]', Punctuation), (words(( 'box', 'break', 'continue', 'default', 'give', 'inversion', 'new_line', 'quit', 'read', 'remove', 'return', 'rfalse', 'rtrue', 'spaces', 'string', 'until'), suffix=r'\b'), Keyword, 'default'), (r'(do|else)\b', Keyword), (r'(font|style)\b', Keyword, ('default', 'miscellaneous-keyword?')), (r'for\b', Keyword, ('for', '(?')), (r'(if|switch|while)', Keyword, ('expression', '_expression', '(?')), (r'(jump|save|restore)\b', Keyword, ('default', 'label?')), (r'objectloop\b', Keyword, ('_keyword-expression', 'variable?', '(?')), (r'print(_ret)?\b|(?=[%s])' % _dquote, Keyword, 'print-list'), (r'\.', Name.Label, 'label?'), (r'@', Keyword, 'opcode'), (r'#(?![agrnw]\$|#)', Punctuation, 'directive'), (r'<', Punctuation, 'default'), (r'move\b', Keyword, ('default', '_keyword-expression', '_expression')), default(('default', '_keyword-expression', '_expression')) ], 'miscellaneous-keyword?': [ include('_whitespace'), (r'(bold|fixed|from|near|off|on|reverse|roman|to|underline)\b', Keyword, '#pop'), (r'(a|A|an|address|char|name|number|object|property|string|the|' r'The)\b(?=(\s+|(![^%s]*))*\))' % _newline, Keyword.Pseudo, '#pop'), (r'%s(?=(\s+|(![^%s]*))*\))' % (_name, _newline), Name.Function, '#pop'), default('#pop') ], '(?': [ include('_whitespace'), (r'\(', Punctuation, '#pop'), default('#pop') ], 'for': [ include('_whitespace'), (r';', Punctuation, ('_for-expression', '_expression')), default(('_for-expression', '_expression')) ], 'print-list': [ include('_whitespace'), (r';', Punctuation, '#pop'), (r':', Error), default(('_list-expression', '_expression', '_list-expression', 'form')) ], 'form': [ include('_whitespace'), (r'\(', Punctuation, ('#pop', 'miscellaneous-keyword?')), default('#pop') ], # Assembly 'opcode': [ include('_whitespace'), (r'[%s]' % _dquote, String.Double, ('operands', 'plain-string')), (_name, Keyword, 'operands') ], 'operands': [ (r':', Error), default(('_assembly-expression', '_expression')) ] } def get_tokens_unprocessed(self, text): # 'in' is either a keyword or an operator. # If the token two tokens after 'in' is ')', 'in' is a keyword: # objectloop(a in b) # Otherwise, it is an operator: # objectloop(a in b && true) objectloop_queue = [] objectloop_token_count = -1 previous_token = None for index, token, value in RegexLexer.get_tokens_unprocessed(self, text): if previous_token is Name.Variable and value == 'in': objectloop_queue = [[index, token, value]] objectloop_token_count = 2 elif objectloop_token_count > 0: if token not in Comment and token not in Text: objectloop_token_count -= 1 objectloop_queue.append((index, token, value)) else: if objectloop_token_count == 0: if objectloop_queue[-1][2] == ')': objectloop_queue[0][1] = Keyword while objectloop_queue: yield objectloop_queue.pop(0) objectloop_token_count = -1 yield index, token, value if token not in Comment and token not in Text: previous_token = token while objectloop_queue: yield objectloop_queue.pop(0) def analyse_text(text): """We try to find a keyword which seem relatively common, unfortunately there is a decent overlap with Smalltalk keywords otherwise here..""" result = 0 if re.search('\borigsource\b', text, re.IGNORECASE): result += 0.05 return result class Inform7Lexer(RegexLexer): """ For Inform 7 source code. .. versionadded:: 2.0 """ name = 'Inform 7' url = 'http://inform7.com/' aliases = ['inform7', 'i7'] filenames = ['*.ni', '*.i7x'] flags = re.MULTILINE | re.DOTALL _dash = Inform6Lexer._dash _dquote = Inform6Lexer._dquote _newline = Inform6Lexer._newline _start = r'\A|(?<=[%s])' % _newline # There are three variants of Inform 7, differing in how to # interpret at signs and braces in I6T. In top-level inclusions, at # signs in the first column are inweb syntax. In phrase definitions # and use options, tokens in braces are treated as I7. Use options # also interpret "{N}". tokens = {} token_variants = ['+i6t-not-inline', '+i6t-inline', '+i6t-use-option'] for level in token_variants: tokens[level] = { '+i6-root': list(Inform6Lexer.tokens['root']), '+i6t-root': [ # For Inform6TemplateLexer (r'[^%s]*' % Inform6Lexer._newline, Comment.Preproc, ('directive', '+p')) ], 'root': [ (r'(\|?\s)+', Text), (r'\[', Comment.Multiline, '+comment'), (r'[%s]' % _dquote, Generic.Heading, ('+main', '+titling', '+titling-string')), default(('+main', '+heading?')) ], '+titling-string': [ (r'[^%s]+' % _dquote, Generic.Heading), (r'[%s]' % _dquote, Generic.Heading, '#pop') ], '+titling': [ (r'\[', Comment.Multiline, '+comment'), (r'[^%s.;:|%s]+' % (_dquote, _newline), Generic.Heading), (r'[%s]' % _dquote, Generic.Heading, '+titling-string'), (r'[%s]{2}|(?<=[\s%s])\|[\s%s]' % (_newline, _dquote, _dquote), Text, ('#pop', '+heading?')), (r'[.;:]|(?<=[\s%s])\|' % _dquote, Text, '#pop'), (r'[|%s]' % _newline, Generic.Heading) ], '+main': [ (r'(?i)[^%s:a\[(|%s]+' % (_dquote, _newline), Text), (r'[%s]' % _dquote, String.Double, '+text'), (r':', Text, '+phrase-definition'), (r'(?i)\bas\b', Text, '+use-option'), (r'\[', Comment.Multiline, '+comment'), (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), bygroups(Punctuation, using(this, state=('+i6-root', 'directive'), i6t='+i6t-not-inline'), Punctuation)), (r'(%s|(?<=[\s;:.%s]))\|\s|[%s]{2,}' % (_start, _dquote, _newline), Text, '+heading?'), (r'(?i)[a(|%s]' % _newline, Text) ], '+phrase-definition': [ (r'\s+', Text), (r'\[', Comment.Multiline, '+comment'), (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), bygroups(Punctuation, using(this, state=('+i6-root', 'directive', 'default', 'statements'), i6t='+i6t-inline'), Punctuation), '#pop'), default('#pop') ], '+use-option': [ (r'\s+', Text), (r'\[', Comment.Multiline, '+comment'), (r'(\([%s])(.*?)([%s]\))' % (_dash, _dash), bygroups(Punctuation, using(this, state=('+i6-root', 'directive'), i6t='+i6t-use-option'), Punctuation), '#pop'), default('#pop') ], '+comment': [ (r'[^\[\]]+', Comment.Multiline), (r'\[', Comment.Multiline, '#push'), (r'\]', Comment.Multiline, '#pop') ], '+text': [ (r'[^\[%s]+' % _dquote, String.Double), (r'\[.*?\]', String.Interpol), (r'[%s]' % _dquote, String.Double, '#pop') ], '+heading?': [ (r'(\|?\s)+', Text), (r'\[', Comment.Multiline, '+comment'), (r'[%s]{4}\s+' % _dash, Text, '+documentation-heading'), (r'[%s]{1,3}' % _dash, Text), (r'(?i)(volume|book|part|chapter|section)\b[^%s]*' % _newline, Generic.Heading, '#pop'), default('#pop') ], '+documentation-heading': [ (r'\s+', Text), (r'\[', Comment.Multiline, '+comment'), (r'(?i)documentation\s+', Text, '+documentation-heading2'), default('#pop') ], '+documentation-heading2': [ (r'\s+', Text), (r'\[', Comment.Multiline, '+comment'), (r'[%s]{4}\s' % _dash, Text, '+documentation'), default('#pop:2') ], '+documentation': [ (r'(?i)(%s)\s*(chapter|example)\s*:[^%s]*' % (_start, _newline), Generic.Heading), (r'(?i)(%s)\s*section\s*:[^%s]*' % (_start, _newline), Generic.Subheading), (r'((%s)\t.*?[%s])+' % (_start, _newline), using(this, state='+main')), (r'[^%s\[]+|[%s\[]' % (_newline, _newline), Text), (r'\[', Comment.Multiline, '+comment'), ], '+i6t-not-inline': [ (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), Comment.Preproc), (r'(%s)@([%s]+|Purpose:)[^%s]*' % (_start, _dash, _newline), Comment.Preproc), (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), Generic.Heading, '+p') ], '+i6t-use-option': [ include('+i6t-not-inline'), (r'(\{)(N)(\})', bygroups(Punctuation, Text, Punctuation)) ], '+i6t-inline': [ (r'(\{)(\S[^}]*)?(\})', bygroups(Punctuation, using(this, state='+main'), Punctuation)) ], '+i6t': [ (r'(\{[%s])(![^}]*)(\}?)' % _dash, bygroups(Punctuation, Comment.Single, Punctuation)), (r'(\{[%s])(lines)(:)([^}]*)(\}?)' % _dash, bygroups(Punctuation, Keyword, Punctuation, Text, Punctuation), '+lines'), (r'(\{[%s])([^:}]*)(:?)([^}]*)(\}?)' % _dash, bygroups(Punctuation, Keyword, Punctuation, Text, Punctuation)), (r'(\(\+)(.*?)(\+\)|\Z)', bygroups(Punctuation, using(this, state='+main'), Punctuation)) ], '+p': [ (r'[^@]+', Comment.Preproc), (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), Comment.Preproc, '#pop'), (r'(%s)@([%s]|Purpose:)' % (_start, _dash), Comment.Preproc), (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), Generic.Heading), (r'@', Comment.Preproc) ], '+lines': [ (r'(%s)@c( .*?)?([%s]|\Z)' % (_start, _newline), Comment.Preproc), (r'(%s)@([%s]|Purpose:)[^%s]*' % (_start, _dash, _newline), Comment.Preproc), (r'(%s)@p( .*?)?([%s]|\Z)' % (_start, _newline), Generic.Heading, '+p'), (r'(%s)@\w*[ %s]' % (_start, _newline), Keyword), (r'![^%s]*' % _newline, Comment.Single), (r'(\{)([%s]endlines)(\})' % _dash, bygroups(Punctuation, Keyword, Punctuation), '#pop'), (r'[^@!{]+?([%s]|\Z)|.' % _newline, Text) ] } # Inform 7 can include snippets of Inform 6 template language, # so all of Inform6Lexer's states are copied here, with # modifications to account for template syntax. Inform7Lexer's # own states begin with '+' to avoid name conflicts. Some of # Inform6Lexer's states begin with '_': these are not modified. # They deal with template syntax either by including modified # states, or by matching r'' then pushing to modified states. for token in Inform6Lexer.tokens: if token == 'root': continue tokens[level][token] = list(Inform6Lexer.tokens[token]) if not token.startswith('_'): tokens[level][token][:0] = [include('+i6t'), include(level)] def __init__(self, **options): level = options.get('i6t', '+i6t-not-inline') if level not in self._all_tokens: self._tokens = self.__class__.process_tokendef(level) else: self._tokens = self._all_tokens[level] RegexLexer.__init__(self, **options) class Inform6TemplateLexer(Inform7Lexer): """ For Inform 6 template code. .. versionadded:: 2.0 """ name = 'Inform 6 template' aliases = ['i6t'] filenames = ['*.i6t'] def get_tokens_unprocessed(self, text, stack=('+i6t-root',)): return Inform7Lexer.get_tokens_unprocessed(self, text, stack) class Tads3Lexer(RegexLexer): """ For TADS 3 source code. """ name = 'TADS 3' aliases = ['tads3'] filenames = ['*.t'] flags = re.DOTALL | re.MULTILINE _comment_single = r'(?://(?:[^\\\n]|\\+[\w\W])*$)' _comment_multiline = r'(?:/\*(?:[^*]|\*(?!/))*\*/)' _escape = (r'(?:\\(?:[\n\\<>"\'^v bnrt]|u[\da-fA-F]{,4}|x[\da-fA-F]{,2}|' r'[0-3]?[0-7]{1,2}))') _name = r'(?:[_a-zA-Z]\w*)' _no_quote = r'(?=\s|\\?>)' _operator = (r'(?:&&|\|\||\+\+|--|\?\?|::|[.,@\[\]~]|' r'(?:[=+\-*/%!&|^]|<<?|>>?>?)=?)') _ws = r'(?:\\|\s|%s|%s)' % (_comment_single, _comment_multiline) _ws_pp = r'(?:\\\n|[^\S\n]|%s|%s)' % (_comment_single, _comment_multiline) def _make_string_state(triple, double, verbatim=None, _escape=_escape): if verbatim: verbatim = ''.join(['(?:%s|%s)' % (re.escape(c.lower()), re.escape(c.upper())) for c in verbatim]) char = r'"' if double else r"'" token = String.Double if double else String.Single escaped_quotes = r'+|%s(?!%s{2})' % (char, char) if triple else r'' prefix = '%s%s' % ('t' if triple else '', 'd' if double else 's') tag_state_name = '%sqt' % prefix state = [] if triple: state += [ (r'%s{3,}' % char, token, '#pop'), (r'\\%s+' % char, String.Escape), (char, token) ] else: state.append((char, token, '#pop')) state += [ include('s/verbatim'), (r'[^\\<&{}%s]+' % char, token) ] if verbatim: # This regex can't use `(?i)` because escape sequences are # case-sensitive. `<\XMP>` works; `<\xmp>` doesn't. state.append((r'\\?<(/|\\\\|(?!%s)\\)%s(?=[\s=>])' % (_escape, verbatim), Name.Tag, ('#pop', '%sqs' % prefix, tag_state_name))) else: state += [ (r'\\?<!([^><\\%s]|<(?!<)|\\%s%s|%s|\\.)*>?' % (char, char, escaped_quotes, _escape), Comment.Multiline), (r'(?i)\\?<listing(?=[\s=>]|\\>)', Name.Tag, ('#pop', '%sqs/listing' % prefix, tag_state_name)), (r'(?i)\\?<xmp(?=[\s=>]|\\>)', Name.Tag, ('#pop', '%sqs/xmp' % prefix, tag_state_name)), (r'\\?<([^\s=><\\%s]|<(?!<)|\\%s%s|%s|\\.)*' % (char, char, escaped_quotes, _escape), Name.Tag, tag_state_name), include('s/entity') ] state += [ include('s/escape'), (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % (char, char, escaped_quotes, _escape), String.Interpol), (r'[\\&{}<]', token) ] return state def _make_tag_state(triple, double, _escape=_escape): char = r'"' if double else r"'" quantifier = r'{3,}' if triple else r'' state_name = '%s%sqt' % ('t' if triple else '', 'd' if double else 's') token = String.Double if double else String.Single escaped_quotes = r'+|%s(?!%s{2})' % (char, char) if triple else r'' return [ (r'%s%s' % (char, quantifier), token, '#pop:2'), (r'(\s|\\\n)+', Text), (r'(=)(\\?")', bygroups(Punctuation, String.Double), 'dqs/%s' % state_name), (r"(=)(\\?')", bygroups(Punctuation, String.Single), 'sqs/%s' % state_name), (r'=', Punctuation, 'uqs/%s' % state_name), (r'\\?>', Name.Tag, '#pop'), (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % (char, char, escaped_quotes, _escape), String.Interpol), (r'([^\s=><\\%s]|<(?!<)|\\%s%s|%s|\\.)+' % (char, char, escaped_quotes, _escape), Name.Attribute), include('s/escape'), include('s/verbatim'), include('s/entity'), (r'[\\{}&]', Name.Attribute) ] def _make_attribute_value_state(terminator, host_triple, host_double, _escape=_escape): token = (String.Double if terminator == r'"' else String.Single if terminator == r"'" else String.Other) host_char = r'"' if host_double else r"'" host_quantifier = r'{3,}' if host_triple else r'' host_token = String.Double if host_double else String.Single escaped_quotes = (r'+|%s(?!%s{2})' % (host_char, host_char) if host_triple else r'') return [ (r'%s%s' % (host_char, host_quantifier), host_token, '#pop:3'), (r'%s%s' % (r'' if token is String.Other else r'\\?', terminator), token, '#pop'), include('s/verbatim'), include('s/entity'), (r'\{([^}<\\%s]|<(?!<)|\\%s%s|%s|\\.)*\}' % (host_char, host_char, escaped_quotes, _escape), String.Interpol), (r'([^\s"\'<%s{}\\&])+' % (r'>' if token is String.Other else r''), token), include('s/escape'), (r'["\'\s&{<}\\]', token) ] tokens = { 'root': [ ('\ufeff', Text), (r'\{', Punctuation, 'object-body'), (r';+', Punctuation), (r'(?=(argcount|break|case|catch|continue|default|definingobj|' r'delegated|do|else|for|foreach|finally|goto|if|inherited|' r'invokee|local|nil|new|operator|replaced|return|self|switch|' r'targetobj|targetprop|throw|true|try|while)\b)', Text, 'block'), (r'(%s)(%s*)(\()' % (_name, _ws), bygroups(Name.Function, using(this, state='whitespace'), Punctuation), ('block?/root', 'more/parameters', 'main/parameters')), include('whitespace'), (r'\++', Punctuation), (r'[^\s!"%-(*->@-_a-z{-~]+', Error), # Averts an infinite loop (r'(?!\Z)', Text, 'main/root') ], 'main/root': [ include('main/basic'), default(('#pop', 'object-body/no-braces', 'classes', 'class')) ], 'object-body/no-braces': [ (r';', Punctuation, '#pop'), (r'\{', Punctuation, ('#pop', 'object-body')), include('object-body') ], 'object-body': [ (r';', Punctuation), (r'\{', Punctuation, '#push'), (r'\}', Punctuation, '#pop'), (r':', Punctuation, ('classes', 'class')), (r'(%s?)(%s*)(\()' % (_name, _ws), bygroups(Name.Function, using(this, state='whitespace'), Punctuation), ('block?', 'more/parameters', 'main/parameters')), (r'(%s)(%s*)(\{)' % (_name, _ws), bygroups(Name.Function, using(this, state='whitespace'), Punctuation), 'block'), (r'(%s)(%s*)(:)' % (_name, _ws), bygroups(Name.Variable, using(this, state='whitespace'), Punctuation), ('object-body/no-braces', 'classes', 'class')), include('whitespace'), (r'->|%s' % _operator, Punctuation, 'main'), default('main/object-body') ], 'main/object-body': [ include('main/basic'), (r'(%s)(%s*)(=?)' % (_name, _ws), bygroups(Name.Variable, using(this, state='whitespace'), Punctuation), ('#pop', 'more', 'main')), default('#pop:2') ], 'block?/root': [ (r'\{', Punctuation, ('#pop', 'block')), include('whitespace'), (r'(?=[\[\'"<(:])', Text, # It might be a VerbRule macro. ('#pop', 'object-body/no-braces', 'grammar', 'grammar-rules')), # It might be a macro like DefineAction. default(('#pop', 'object-body/no-braces')) ], 'block?': [ (r'\{', Punctuation, ('#pop', 'block')), include('whitespace'), default('#pop') ], 'block/basic': [ (r'[;:]+', Punctuation), (r'\{', Punctuation, '#push'), (r'\}', Punctuation, '#pop'), (r'default\b', Keyword.Reserved), (r'(%s)(%s*)(:)' % (_name, _ws), bygroups(Name.Label, using(this, state='whitespace'), Punctuation)), include('whitespace') ], 'block': [ include('block/basic'), (r'(?!\Z)', Text, ('more', 'main')) ], 'block/embed': [ (r'>>', String.Interpol, '#pop'), include('block/basic'), (r'(?!\Z)', Text, ('more/embed', 'main')) ], 'main/basic': [ include('whitespace'), (r'\(', Punctuation, ('#pop', 'more', 'main')), (r'\[', Punctuation, ('#pop', 'more/list', 'main')), (r'\{', Punctuation, ('#pop', 'more/inner', 'main/inner', 'more/parameters', 'main/parameters')), (r'\*|\.{3}', Punctuation, '#pop'), (r'(?i)0x[\da-f]+', Number.Hex, '#pop'), (r'(\d+\.(?!\.)\d*|\.\d+)([eE][-+]?\d+)?|\d+[eE][-+]?\d+', Number.Float, '#pop'), (r'0[0-7]+', Number.Oct, '#pop'), (r'\d+', Number.Integer, '#pop'), (r'"""', String.Double, ('#pop', 'tdqs')), (r"'''", String.Single, ('#pop', 'tsqs')), (r'"', String.Double, ('#pop', 'dqs')), (r"'", String.Single, ('#pop', 'sqs')), (r'R"""', String.Regex, ('#pop', 'tdqr')), (r"R'''", String.Regex, ('#pop', 'tsqr')), (r'R"', String.Regex, ('#pop', 'dqr')), (r"R'", String.Regex, ('#pop', 'sqr')), # Two-token keywords (r'(extern)(%s+)(object\b)' % _ws, bygroups(Keyword.Reserved, using(this, state='whitespace'), Keyword.Reserved)), (r'(function|method)(%s*)(\()' % _ws, bygroups(Keyword.Reserved, using(this, state='whitespace'), Punctuation), ('#pop', 'block?', 'more/parameters', 'main/parameters')), (r'(modify)(%s+)(grammar\b)' % _ws, bygroups(Keyword.Reserved, using(this, state='whitespace'), Keyword.Reserved), ('#pop', 'object-body/no-braces', ':', 'grammar')), (r'(new)(%s+(?=(?:function|method)\b))' % _ws, bygroups(Keyword.Reserved, using(this, state='whitespace'))), (r'(object)(%s+)(template\b)' % _ws, bygroups(Keyword.Reserved, using(this, state='whitespace'), Keyword.Reserved), ('#pop', 'template')), (r'(string)(%s+)(template\b)' % _ws, bygroups(Keyword, using(this, state='whitespace'), Keyword.Reserved), ('#pop', 'function-name')), # Keywords (r'(argcount|definingobj|invokee|replaced|targetobj|targetprop)\b', Name.Builtin, '#pop'), (r'(break|continue|goto)\b', Keyword.Reserved, ('#pop', 'label')), (r'(case|extern|if|intrinsic|return|static|while)\b', Keyword.Reserved), (r'catch\b', Keyword.Reserved, ('#pop', 'catch')), (r'class\b', Keyword.Reserved, ('#pop', 'object-body/no-braces', 'class')), (r'(default|do|else|finally|try)\b', Keyword.Reserved, '#pop'), (r'(dictionary|property)\b', Keyword.Reserved, ('#pop', 'constants')), (r'enum\b', Keyword.Reserved, ('#pop', 'enum')), (r'export\b', Keyword.Reserved, ('#pop', 'main')), (r'(for|foreach)\b', Keyword.Reserved, ('#pop', 'more/inner', 'main/inner')), (r'(function|method)\b', Keyword.Reserved, ('#pop', 'block?', 'function-name')), (r'grammar\b', Keyword.Reserved, ('#pop', 'object-body/no-braces', 'grammar')), (r'inherited\b', Keyword.Reserved, ('#pop', 'inherited')), (r'local\b', Keyword.Reserved, ('#pop', 'more/local', 'main/local')), (r'(modify|replace|switch|throw|transient)\b', Keyword.Reserved, '#pop'), (r'new\b', Keyword.Reserved, ('#pop', 'class')), (r'(nil|true)\b', Keyword.Constant, '#pop'), (r'object\b', Keyword.Reserved, ('#pop', 'object-body/no-braces')), (r'operator\b', Keyword.Reserved, ('#pop', 'operator')), (r'propertyset\b', Keyword.Reserved, ('#pop', 'propertyset', 'main')), (r'self\b', Name.Builtin.Pseudo, '#pop'), (r'template\b', Keyword.Reserved, ('#pop', 'template')), # Operators (r'(__objref|defined)(%s*)(\()' % _ws, bygroups(Operator.Word, using(this, state='whitespace'), Operator), ('#pop', 'more/__objref', 'main')), (r'delegated\b', Operator.Word), # Compiler-defined macros and built-in properties (r'(__DATE__|__DEBUG|__LINE__|__FILE__|' r'__TADS_MACRO_FORMAT_VERSION|__TADS_SYS_\w*|__TADS_SYSTEM_NAME|' r'__TADS_VERSION_MAJOR|__TADS_VERSION_MINOR|__TADS3|__TIME__|' r'construct|finalize|grammarInfo|grammarTag|lexicalParent|' r'miscVocab|sourceTextGroup|sourceTextGroupName|' r'sourceTextGroupOrder|sourceTextOrder)\b', Name.Builtin, '#pop') ], 'main': [ include('main/basic'), (_name, Name, '#pop'), default('#pop') ], 'more/basic': [ (r'\(', Punctuation, ('more/list', 'main')), (r'\[', Punctuation, ('more', 'main')), (r'\.{3}', Punctuation), (r'->|\.\.', Punctuation, 'main'), (r'(?=;)|[:)\]]', Punctuation, '#pop'), include('whitespace'), (_operator, Operator, 'main'), (r'\?', Operator, ('main', 'more/conditional', 'main')), (r'(is|not)(%s+)(in\b)' % _ws, bygroups(Operator.Word, using(this, state='whitespace'), Operator.Word)), (r'[^\s!"%-_a-z{-~]+', Error) # Averts an infinite loop ], 'more': [ include('more/basic'), default('#pop') ], # Then expression (conditional operator) 'more/conditional': [ (r':(?!:)', Operator, '#pop'), include('more') ], # Embedded expressions 'more/embed': [ (r'>>', String.Interpol, '#pop:2'), include('more') ], # For/foreach loop initializer or short-form anonymous function 'main/inner': [ (r'\(', Punctuation, ('#pop', 'more/inner', 'main/inner')), (r'local\b', Keyword.Reserved, ('#pop', 'main/local')), include('main') ], 'more/inner': [ (r'\}', Punctuation, '#pop'), (r',', Punctuation, 'main/inner'), (r'(in|step)\b', Keyword, 'main/inner'), include('more') ], # Local 'main/local': [ (_name, Name.Variable, '#pop'), include('whitespace') ], 'more/local': [ (r',', Punctuation, 'main/local'), include('more') ], # List 'more/list': [ (r'[,:]', Punctuation, 'main'), include('more') ], # Parameter list 'main/parameters': [ (r'(%s)(%s*)(?=:)' % (_name, _ws), bygroups(Name.Variable, using(this, state='whitespace')), '#pop'), (r'(%s)(%s+)(%s)' % (_name, _ws, _name), bygroups(Name.Class, using(this, state='whitespace'), Name.Variable), '#pop'), (r'\[+', Punctuation), include('main/basic'), (_name, Name.Variable, '#pop'), default('#pop') ], 'more/parameters': [ (r'(:)(%s*(?=[?=,:)]))' % _ws, bygroups(Punctuation, using(this, state='whitespace'))), (r'[?\]]+', Punctuation), (r'[:)]', Punctuation, ('#pop', 'multimethod?')), (r',', Punctuation, 'main/parameters'), (r'=', Punctuation, ('more/parameter', 'main')), include('more') ], 'more/parameter': [ (r'(?=[,)])', Text, '#pop'), include('more') ], 'multimethod?': [ (r'multimethod\b', Keyword, '#pop'), include('whitespace'), default('#pop') ], # Statements and expressions 'more/__objref': [ (r',', Punctuation, 'mode'), (r'\)', Operator, '#pop'), include('more') ], 'mode': [ (r'(error|warn)\b', Keyword, '#pop'), include('whitespace') ], 'catch': [ (r'\(+', Punctuation), (_name, Name.Exception, ('#pop', 'variables')), include('whitespace') ], 'enum': [ include('whitespace'), (r'token\b', Keyword, ('#pop', 'constants')), default(('#pop', 'constants')) ], 'grammar': [ (r'\)+', Punctuation), (r'\(', Punctuation, 'grammar-tag'), (r':', Punctuation, 'grammar-rules'), (_name, Name.Class), include('whitespace') ], 'grammar-tag': [ include('whitespace'), (r'"""([^\\"<]|""?(?!")|\\"+|\\.|<(?!<))+("{3,}|<<)|' r'R"""([^\\"]|""?(?!")|\\"+|\\.)+"{3,}|' r"'''([^\\'<]|''?(?!')|\\'+|\\.|<(?!<))+('{3,}|<<)|" r"R'''([^\\']|''?(?!')|\\'+|\\.)+'{3,}|" r'"([^\\"<]|\\.|<(?!<))+("|<<)|R"([^\\"]|\\.)+"|' r"'([^\\'<]|\\.|<(?!<))+('|<<)|R'([^\\']|\\.)+'|" r"([^)\s\\/]|/(?![/*]))+|\)", String.Other, '#pop') ], 'grammar-rules': [ include('string'), include('whitespace'), (r'(\[)(%s*)(badness)' % _ws, bygroups(Punctuation, using(this, state='whitespace'), Keyword), 'main'), (r'->|%s|[()]' % _operator, Punctuation), (_name, Name.Constant), default('#pop:2') ], ':': [ (r':', Punctuation, '#pop') ], 'function-name': [ (r'(<<([^>]|>>>|>(?!>))*>>)+', String.Interpol), (r'(?=%s?%s*[({])' % (_name, _ws), Text, '#pop'), (_name, Name.Function, '#pop'), include('whitespace') ], 'inherited': [ (r'<', Punctuation, ('#pop', 'classes', 'class')), include('whitespace'), (_name, Name.Class, '#pop'), default('#pop') ], 'operator': [ (r'negate\b', Operator.Word, '#pop'), include('whitespace'), (_operator, Operator), default('#pop') ], 'propertyset': [ (r'\(', Punctuation, ('more/parameters', 'main/parameters')), (r'\{', Punctuation, ('#pop', 'object-body')), include('whitespace') ], 'template': [ (r'(?=;)', Text, '#pop'), include('string'), (r'inherited\b', Keyword.Reserved), include('whitespace'), (r'->|\?|%s' % _operator, Punctuation), (_name, Name.Variable) ], # Identifiers 'class': [ (r'\*|\.{3}', Punctuation, '#pop'), (r'object\b', Keyword.Reserved, '#pop'), (r'transient\b', Keyword.Reserved), (_name, Name.Class, '#pop'), include('whitespace'), default('#pop') ], 'classes': [ (r'[:,]', Punctuation, 'class'), include('whitespace'), (r'>', Punctuation, '#pop'), default('#pop') ], 'constants': [ (r',+', Punctuation), (r';', Punctuation, '#pop'), (r'property\b', Keyword.Reserved), (_name, Name.Constant), include('whitespace') ], 'label': [ (_name, Name.Label, '#pop'), include('whitespace'), default('#pop') ], 'variables': [ (r',+', Punctuation), (r'\)', Punctuation, '#pop'), include('whitespace'), (_name, Name.Variable) ], # Whitespace and comments 'whitespace': [ (r'^%s*#(%s|[^\n]|(?<=\\)\n)*\n?' % (_ws_pp, _comment_multiline), Comment.Preproc), (_comment_single, Comment.Single), (_comment_multiline, Comment.Multiline), (r'\\+\n+%s*#?|\n+|([^\S\n]|\\)+' % _ws_pp, Text) ], # Strings 'string': [ (r'"""', String.Double, 'tdqs'), (r"'''", String.Single, 'tsqs'), (r'"', String.Double, 'dqs'), (r"'", String.Single, 'sqs') ], 's/escape': [ (r'\{\{|\}\}|%s' % _escape, String.Escape) ], 's/verbatim': [ (r'<<\s*(as\s+decreasingly\s+likely\s+outcomes|cycling|else|end|' r'first\s+time|one\s+of|only|or|otherwise|' r'(sticky|(then\s+)?(purely\s+)?at)\s+random|stopping|' r'(then\s+)?(half\s+)?shuffled|\|\|)\s*>>', String.Interpol), (r'<<(%%(_(%s|\\?.)|[\-+ ,#]|\[\d*\]?)*\d*\.?\d*(%s|\\?.)|' r'\s*((else|otherwise)\s+)?(if|unless)\b)?' % (_escape, _escape), String.Interpol, ('block/embed', 'more/embed', 'main')) ], 's/entity': [ (r'(?i)&(#(x[\da-f]+|\d+)|[a-z][\da-z]*);?', Name.Entity) ], 'tdqs': _make_string_state(True, True), 'tsqs': _make_string_state(True, False), 'dqs': _make_string_state(False, True), 'sqs': _make_string_state(False, False), 'tdqs/listing': _make_string_state(True, True, 'listing'), 'tsqs/listing': _make_string_state(True, False, 'listing'), 'dqs/listing': _make_string_state(False, True, 'listing'), 'sqs/listing': _make_string_state(False, False, 'listing'), 'tdqs/xmp': _make_string_state(True, True, 'xmp'), 'tsqs/xmp': _make_string_state(True, False, 'xmp'), 'dqs/xmp': _make_string_state(False, True, 'xmp'), 'sqs/xmp': _make_string_state(False, False, 'xmp'), # Tags 'tdqt': _make_tag_state(True, True), 'tsqt': _make_tag_state(True, False), 'dqt': _make_tag_state(False, True), 'sqt': _make_tag_state(False, False), 'dqs/tdqt': _make_attribute_value_state(r'"', True, True), 'dqs/tsqt': _make_attribute_value_state(r'"', True, False), 'dqs/dqt': _make_attribute_value_state(r'"', False, True), 'dqs/sqt': _make_attribute_value_state(r'"', False, False), 'sqs/tdqt': _make_attribute_value_state(r"'", True, True), 'sqs/tsqt': _make_attribute_value_state(r"'", True, False), 'sqs/dqt': _make_attribute_value_state(r"'", False, True), 'sqs/sqt': _make_attribute_value_state(r"'", False, False), 'uqs/tdqt': _make_attribute_value_state(_no_quote, True, True), 'uqs/tsqt': _make_attribute_value_state(_no_quote, True, False), 'uqs/dqt': _make_attribute_value_state(_no_quote, False, True), 'uqs/sqt': _make_attribute_value_state(_no_quote, False, False), # Regular expressions 'tdqr': [ (r'[^\\"]+', String.Regex), (r'\\"*', String.Regex), (r'"{3,}', String.Regex, '#pop'), (r'"', String.Regex) ], 'tsqr': [ (r"[^\\']+", String.Regex), (r"\\'*", String.Regex), (r"'{3,}", String.Regex, '#pop'), (r"'", String.Regex) ], 'dqr': [ (r'[^\\"]+', String.Regex), (r'\\"?', String.Regex), (r'"', String.Regex, '#pop') ], 'sqr': [ (r"[^\\']+", String.Regex), (r"\\'?", String.Regex), (r"'", String.Regex, '#pop') ] } def get_tokens_unprocessed(self, text, **kwargs): pp = r'^%s*#%s*' % (self._ws_pp, self._ws_pp) if_false_level = 0 for index, token, value in ( RegexLexer.get_tokens_unprocessed(self, text, **kwargs)): if if_false_level == 0: # Not in a false #if if (token is Comment.Preproc and re.match(r'%sif%s+(0|nil)%s*$\n?' % (pp, self._ws_pp, self._ws_pp), value)): if_false_level = 1 else: # In a false #if if token is Comment.Preproc: if (if_false_level == 1 and re.match(r'%sel(if|se)\b' % pp, value)): if_false_level = 0 elif re.match(r'%sif' % pp, value): if_false_level += 1 elif re.match(r'%sendif\b' % pp, value): if_false_level -= 1 else: token = Comment yield index, token, value def analyse_text(text): """This is a rather generic descriptive language without strong identifiers. It looks like a 'GameMainDef' has to be present, and/or a 'versionInfo' with an 'IFID' field.""" result = 0 if '__TADS' in text or 'GameMainDef' in text: result += 0.2 # This is a fairly unique keyword which is likely used in source as well if 'versionInfo' in text and 'IFID' in text: result += 0.1 return result
57,119
Python
40.301518
99
0.431117
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/forth.py
""" pygments.lexers.forth ~~~~~~~~~~~~~~~~~~~~~ Lexer for the Forth language. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, bygroups from pygments.token import Text, Comment, Keyword, Name, String, Number, \ Whitespace __all__ = ['ForthLexer'] class ForthLexer(RegexLexer): """ Lexer for Forth files. .. versionadded:: 2.2 """ name = 'Forth' url = 'https://www.forth.com/forth/' aliases = ['forth'] filenames = ['*.frt', '*.fs'] mimetypes = ['application/x-forth'] flags = re.IGNORECASE | re.MULTILINE tokens = { 'root': [ (r'\s+', Whitespace), # All comment types (r'\\.*?$', Comment.Single), (r'\([\s].*?\)', Comment.Single), # defining words. The next word is a new command name (r'(:|variable|constant|value|buffer:)(\s+)', bygroups(Keyword.Namespace, Whitespace), 'worddef'), # strings are rather simple (r'([.sc]")(\s+?)', bygroups(String, Whitespace), 'stringdef'), # keywords from the various wordsets # *** Wordset BLOCK (r'(blk|block|buffer|evaluate|flush|load|save-buffers|update|' # *** Wordset BLOCK-EXT r'empty-buffers|list|refill|scr|thru|' # *** Wordset CORE r'\#s|\*\/mod|\+loop|\/mod|0<|0=|1\+|1-|2!|' r'2\*|2\/|2@|2drop|2dup|2over|2swap|>body|' r'>in|>number|>r|\?dup|abort|abort\"|abs|' r'accept|align|aligned|allot|and|base|begin|' r'bl|c!|c,|c@|cell\+|cells|char|char\+|' r'chars|constant|count|cr|create|decimal|' r'depth|do|does>|drop|dup|else|emit|environment\?|' r'evaluate|execute|exit|fill|find|fm\/mod|' r'here|hold|i|if|immediate|invert|j|key|' r'leave|literal|loop|lshift|m\*|max|min|' r'mod|move|negate|or|over|postpone|quit|' r'r>|r@|recurse|repeat|rot|rshift|s\"|s>d|' r'sign|sm\/rem|source|space|spaces|state|swap|' r'then|type|u\.|u\<|um\*|um\/mod|unloop|until|' r'variable|while|word|xor|\[char\]|\[\'\]|' r'@|!|\#|<\#|\#>|:|;|\+|-|\*|\/|,|<|>|\|1\+|1-|\.|' # *** Wordset CORE-EXT r'\.r|0<>|' r'0>|2>r|2r>|2r@|:noname|\?do|again|c\"|' r'case|compile,|endcase|endof|erase|false|' r'hex|marker|nip|of|pad|parse|pick|refill|' r'restore-input|roll|save-input|source-id|to|' r'true|tuck|u\.r|u>|unused|value|within|' r'\[compile\]|' # *** Wordset CORE-EXT-obsolescent r'\#tib|convert|expect|query|span|' r'tib|' # *** Wordset DOUBLE r'2constant|2literal|2variable|d\+|d-|' r'd\.|d\.r|d0<|d0=|d2\*|d2\/|d<|d=|d>s|' r'dabs|dmax|dmin|dnegate|m\*\/|m\+|' # *** Wordset DOUBLE-EXT r'2rot|du<|' # *** Wordset EXCEPTION r'catch|throw|' # *** Wordset EXCEPTION-EXT r'abort|abort\"|' # *** Wordset FACILITY r'at-xy|key\?|page|' # *** Wordset FACILITY-EXT r'ekey|ekey>char|ekey\?|emit\?|ms|time&date|' # *** Wordset FILE r'BIN|CLOSE-FILE|CREATE-FILE|DELETE-FILE|FILE-POSITION|' r'FILE-SIZE|INCLUDE-FILE|INCLUDED|OPEN-FILE|R\/O|' r'R\/W|READ-FILE|READ-LINE|REPOSITION-FILE|RESIZE-FILE|' r'S\"|SOURCE-ID|W/O|WRITE-FILE|WRITE-LINE|' # *** Wordset FILE-EXT r'FILE-STATUS|FLUSH-FILE|REFILL|RENAME-FILE|' # *** Wordset FLOAT r'>float|d>f|' r'f!|f\*|f\+|f-|f\/|f0<|f0=|f<|f>d|f@|' r'falign|faligned|fconstant|fdepth|fdrop|fdup|' r'fliteral|float\+|floats|floor|fmax|fmin|' r'fnegate|fover|frot|fround|fswap|fvariable|' r'represent|' # *** Wordset FLOAT-EXT r'df!|df@|dfalign|dfaligned|dfloat\+|' r'dfloats|f\*\*|f\.|fabs|facos|facosh|falog|' r'fasin|fasinh|fatan|fatan2|fatanh|fcos|fcosh|' r'fe\.|fexp|fexpm1|fln|flnp1|flog|fs\.|fsin|' r'fsincos|fsinh|fsqrt|ftan|ftanh|f~|precision|' r'set-precision|sf!|sf@|sfalign|sfaligned|sfloat\+|' r'sfloats|' # *** Wordset LOCAL r'\(local\)|to|' # *** Wordset LOCAL-EXT r'locals\||' # *** Wordset MEMORY r'allocate|free|resize|' # *** Wordset SEARCH r'definitions|find|forth-wordlist|get-current|' r'get-order|search-wordlist|set-current|set-order|' r'wordlist|' # *** Wordset SEARCH-EXT r'also|forth|only|order|previous|' # *** Wordset STRING r'-trailing|\/string|blank|cmove|cmove>|compare|' r'search|sliteral|' # *** Wordset TOOLS r'.s|dump|see|words|' # *** Wordset TOOLS-EXT r';code|' r'ahead|assembler|bye|code|cs-pick|cs-roll|' r'editor|state|\[else\]|\[if\]|\[then\]|' # *** Wordset TOOLS-EXT-obsolescent r'forget|' # Forth 2012 r'defer|defer@|defer!|action-of|begin-structure|field:|buffer:|' r'parse-name|buffer:|traverse-wordlist|n>r|nr>|2value|fvalue|' r'name>interpret|name>compile|name>string|' r'cfield:|end-structure)(?!\S)', Keyword), # Numbers (r'(\$[0-9A-F]+)', Number.Hex), (r'(\#|%|&|\-|\+)?[0-9]+', Number.Integer), (r'(\#|%|&|\-|\+)?[0-9.]+', Keyword.Type), # amforth specific (r'(@i|!i|@e|!e|pause|noop|turnkey|sleep|' r'itype|icompare|sp@|sp!|rp@|rp!|up@|up!|' r'>a|a>|a@|a!|a@+|a@-|>b|b>|b@|b!|b@+|b@-|' r'find-name|1ms|' r'sp0|rp0|\(evaluate\)|int-trap|int!)(?!\S)', Name.Constant), # a proposal (r'(do-recognizer|r:fail|recognizer:|get-recognizers|' r'set-recognizers|r:float|r>comp|r>int|r>post|' r'r:name|r:word|r:dnum|r:num|recognizer|forth-recognizer|' r'rec:num|rec:float|rec:word)(?!\S)', Name.Decorator), # defining words. The next word is a new command name (r'(Evalue|Rvalue|Uvalue|Edefer|Rdefer|Udefer)(\s+)', bygroups(Keyword.Namespace, Text), 'worddef'), (r'\S+', Name.Function), # Anything else is executed ], 'worddef': [ (r'\S+', Name.Class, '#pop'), ], 'stringdef': [ (r'[^"]+', String, '#pop'), ], } def analyse_text(text): """Forth uses : COMMAND ; quite a lot in a single line, so we're trying to find that.""" if re.search('\n:[^\n]+;\n', text): return 0.3
7,194
Python
38.972222
79
0.493328
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/_lua_builtins.py
""" pygments.lexers._lua_builtins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This file contains the names and modules of lua functions It is able to re-generate itself, but for adding new functions you probably have to add some callbacks (see function module_callbacks). Do not edit the MODULES dict by hand. Run with `python -I` to regenerate. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ MODULES = {'basic': ('_G', '_VERSION', 'assert', 'collectgarbage', 'dofile', 'error', 'getmetatable', 'ipairs', 'load', 'loadfile', 'next', 'pairs', 'pcall', 'print', 'rawequal', 'rawget', 'rawlen', 'rawset', 'select', 'setmetatable', 'tonumber', 'tostring', 'type', 'warn', 'xpcall'), 'bit32': ('bit32.arshift', 'bit32.band', 'bit32.bnot', 'bit32.bor', 'bit32.btest', 'bit32.bxor', 'bit32.extract', 'bit32.lrotate', 'bit32.lshift', 'bit32.replace', 'bit32.rrotate', 'bit32.rshift'), 'coroutine': ('coroutine.close', 'coroutine.create', 'coroutine.isyieldable', 'coroutine.resume', 'coroutine.running', 'coroutine.status', 'coroutine.wrap', 'coroutine.yield'), 'debug': ('debug.debug', 'debug.gethook', 'debug.getinfo', 'debug.getlocal', 'debug.getmetatable', 'debug.getregistry', 'debug.getupvalue', 'debug.getuservalue', 'debug.sethook', 'debug.setlocal', 'debug.setmetatable', 'debug.setupvalue', 'debug.setuservalue', 'debug.traceback', 'debug.upvalueid', 'debug.upvaluejoin'), 'io': ('io.close', 'io.flush', 'io.input', 'io.lines', 'io.open', 'io.output', 'io.popen', 'io.read', 'io.stderr', 'io.stdin', 'io.stdout', 'io.tmpfile', 'io.type', 'io.write'), 'math': ('math.abs', 'math.acos', 'math.asin', 'math.atan', 'math.atan2', 'math.ceil', 'math.cos', 'math.cosh', 'math.deg', 'math.exp', 'math.floor', 'math.fmod', 'math.frexp', 'math.huge', 'math.ldexp', 'math.log', 'math.max', 'math.maxinteger', 'math.min', 'math.mininteger', 'math.modf', 'math.pi', 'math.pow', 'math.rad', 'math.random', 'math.randomseed', 'math.sin', 'math.sinh', 'math.sqrt', 'math.tan', 'math.tanh', 'math.tointeger', 'math.type', 'math.ult'), 'modules': ('package.config', 'package.cpath', 'package.loaded', 'package.loadlib', 'package.path', 'package.preload', 'package.searchers', 'package.searchpath', 'require'), 'os': ('os.clock', 'os.date', 'os.difftime', 'os.execute', 'os.exit', 'os.getenv', 'os.remove', 'os.rename', 'os.setlocale', 'os.time', 'os.tmpname'), 'string': ('string.byte', 'string.char', 'string.dump', 'string.find', 'string.format', 'string.gmatch', 'string.gsub', 'string.len', 'string.lower', 'string.match', 'string.pack', 'string.packsize', 'string.rep', 'string.reverse', 'string.sub', 'string.unpack', 'string.upper'), 'table': ('table.concat', 'table.insert', 'table.move', 'table.pack', 'table.remove', 'table.sort', 'table.unpack'), 'utf8': ('utf8.char', 'utf8.charpattern', 'utf8.codepoint', 'utf8.codes', 'utf8.len', 'utf8.offset')} if __name__ == '__main__': # pragma: no cover import re from urllib.request import urlopen import pprint # you can't generally find out what module a function belongs to if you # have only its name. Because of this, here are some callback functions # that recognize if a gioven function belongs to a specific module def module_callbacks(): def is_in_coroutine_module(name): return name.startswith('coroutine.') def is_in_modules_module(name): if name in ['require', 'module'] or name.startswith('package'): return True else: return False def is_in_string_module(name): return name.startswith('string.') def is_in_table_module(name): return name.startswith('table.') def is_in_math_module(name): return name.startswith('math') def is_in_io_module(name): return name.startswith('io.') def is_in_os_module(name): return name.startswith('os.') def is_in_debug_module(name): return name.startswith('debug.') return {'coroutine': is_in_coroutine_module, 'modules': is_in_modules_module, 'string': is_in_string_module, 'table': is_in_table_module, 'math': is_in_math_module, 'io': is_in_io_module, 'os': is_in_os_module, 'debug': is_in_debug_module} def get_newest_version(): f = urlopen('http://www.lua.org/manual/') r = re.compile(r'^<A HREF="(\d\.\d)/">(Lua )?\1</A>') for line in f: m = r.match(line.decode('iso-8859-1')) if m is not None: return m.groups()[0] def get_lua_functions(version): f = urlopen('http://www.lua.org/manual/%s/' % version) r = re.compile(r'^<A HREF="manual.html#pdf-(?!lua|LUA)([^:]+)">\1</A>') functions = [] for line in f: m = r.match(line.decode('iso-8859-1')) if m is not None: functions.append(m.groups()[0]) return functions def get_function_module(name): for mod, cb in module_callbacks().items(): if cb(name): return mod if '.' in name: return name.split('.')[0] else: return 'basic' def regenerate(filename, modules): with open(filename) as fp: content = fp.read() header = content[:content.find('MODULES = {')] footer = content[content.find("if __name__ == '__main__':"):] with open(filename, 'w') as fp: fp.write(header) fp.write('MODULES = %s\n\n' % pprint.pformat(modules)) fp.write(footer) def run(): version = get_newest_version() functions = set() for v in ('5.2', version): print('> Downloading function index for Lua %s' % v) f = get_lua_functions(v) print('> %d functions found, %d new:' % (len(f), len(set(f) - functions))) functions |= set(f) functions = sorted(functions) modules = {} for full_function_name in functions: print('>> %s' % full_function_name) m = get_function_module(full_function_name) modules.setdefault(m, []).append(full_function_name) modules = {k: tuple(v) for k, v in modules.items()} regenerate(__file__, modules) run()
8,080
Python
27.255245
79
0.469431
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/erlang.py
""" pygments.lexers.erlang ~~~~~~~~~~~~~~~~~~~~~~ Lexers for Erlang. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import Lexer, RegexLexer, bygroups, words, do_insertions, \ include, default, line_re from pygments.token import Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Generic, Whitespace __all__ = ['ErlangLexer', 'ErlangShellLexer', 'ElixirConsoleLexer', 'ElixirLexer'] class ErlangLexer(RegexLexer): """ For the Erlang functional programming language. .. versionadded:: 0.9 """ name = 'Erlang' url = 'https://www.erlang.org/' aliases = ['erlang'] filenames = ['*.erl', '*.hrl', '*.es', '*.escript'] mimetypes = ['text/x-erlang'] keywords = ( 'after', 'begin', 'case', 'catch', 'cond', 'end', 'fun', 'if', 'let', 'of', 'query', 'receive', 'try', 'when', ) builtins = ( # See erlang(3) man page 'abs', 'append_element', 'apply', 'atom_to_list', 'binary_to_list', 'bitstring_to_list', 'binary_to_term', 'bit_size', 'bump_reductions', 'byte_size', 'cancel_timer', 'check_process_code', 'delete_module', 'demonitor', 'disconnect_node', 'display', 'element', 'erase', 'exit', 'float', 'float_to_list', 'fun_info', 'fun_to_list', 'function_exported', 'garbage_collect', 'get', 'get_keys', 'group_leader', 'hash', 'hd', 'integer_to_list', 'iolist_to_binary', 'iolist_size', 'is_atom', 'is_binary', 'is_bitstring', 'is_boolean', 'is_builtin', 'is_float', 'is_function', 'is_integer', 'is_list', 'is_number', 'is_pid', 'is_port', 'is_process_alive', 'is_record', 'is_reference', 'is_tuple', 'length', 'link', 'list_to_atom', 'list_to_binary', 'list_to_bitstring', 'list_to_existing_atom', 'list_to_float', 'list_to_integer', 'list_to_pid', 'list_to_tuple', 'load_module', 'localtime_to_universaltime', 'make_tuple', 'md5', 'md5_final', 'md5_update', 'memory', 'module_loaded', 'monitor', 'monitor_node', 'node', 'nodes', 'open_port', 'phash', 'phash2', 'pid_to_list', 'port_close', 'port_command', 'port_connect', 'port_control', 'port_call', 'port_info', 'port_to_list', 'process_display', 'process_flag', 'process_info', 'purge_module', 'put', 'read_timer', 'ref_to_list', 'register', 'resume_process', 'round', 'send', 'send_after', 'send_nosuspend', 'set_cookie', 'setelement', 'size', 'spawn', 'spawn_link', 'spawn_monitor', 'spawn_opt', 'split_binary', 'start_timer', 'statistics', 'suspend_process', 'system_flag', 'system_info', 'system_monitor', 'system_profile', 'term_to_binary', 'tl', 'trace', 'trace_delivered', 'trace_info', 'trace_pattern', 'trunc', 'tuple_size', 'tuple_to_list', 'universaltime_to_localtime', 'unlink', 'unregister', 'whereis' ) operators = r'(\+\+?|--?|\*|/|<|>|/=|=:=|=/=|=<|>=|==?|<-|!|\?)' word_operators = ( 'and', 'andalso', 'band', 'bnot', 'bor', 'bsl', 'bsr', 'bxor', 'div', 'not', 'or', 'orelse', 'rem', 'xor' ) atom_re = r"(?:[a-z]\w*|'[^\n']*[^\\]')" variable_re = r'(?:[A-Z_]\w*)' esc_char_re = r'[bdefnrstv\'"\\]' esc_octal_re = r'[0-7][0-7]?[0-7]?' esc_hex_re = r'(?:x[0-9a-fA-F]{2}|x\{[0-9a-fA-F]+\})' esc_ctrl_re = r'\^[a-zA-Z]' escape_re = r'(?:\\(?:'+esc_char_re+r'|'+esc_octal_re+r'|'+esc_hex_re+r'|'+esc_ctrl_re+r'))' macro_re = r'(?:'+variable_re+r'|'+atom_re+r')' base_re = r'(?:[2-9]|[12][0-9]|3[0-6])' tokens = { 'root': [ (r'\s+', Whitespace), (r'(%.*)(\n)', bygroups(Comment, Whitespace)), (words(keywords, suffix=r'\b'), Keyword), (words(builtins, suffix=r'\b'), Name.Builtin), (words(word_operators, suffix=r'\b'), Operator.Word), (r'^-', Punctuation, 'directive'), (operators, Operator), (r'"', String, 'string'), (r'<<', Name.Label), (r'>>', Name.Label), ('(' + atom_re + ')(:)', bygroups(Name.Namespace, Punctuation)), ('(?:^|(?<=:))(' + atom_re + r')(\s*)(\()', bygroups(Name.Function, Whitespace, Punctuation)), (r'[+-]?' + base_re + r'#[0-9a-zA-Z]+', Number.Integer), (r'[+-]?\d+', Number.Integer), (r'[+-]?\d+.\d+', Number.Float), (r'[]\[:_@\".{}()|;,]', Punctuation), (variable_re, Name.Variable), (atom_re, Name), (r'\?'+macro_re, Name.Constant), (r'\$(?:'+escape_re+r'|\\[ %]|[^\\])', String.Char), (r'#'+atom_re+r'(:?\.'+atom_re+r')?', Name.Label), # Erlang script shebang (r'\A#!.+\n', Comment.Hashbang), # EEP 43: Maps # http://www.erlang.org/eeps/eep-0043.html (r'#\{', Punctuation, 'map_key'), ], 'string': [ (escape_re, String.Escape), (r'"', String, '#pop'), (r'~[0-9.*]*[~#+BPWXb-ginpswx]', String.Interpol), (r'[^"\\~]+', String), (r'~', String), ], 'directive': [ (r'(define)(\s*)(\()('+macro_re+r')', bygroups(Name.Entity, Whitespace, Punctuation, Name.Constant), '#pop'), (r'(record)(\s*)(\()('+macro_re+r')', bygroups(Name.Entity, Whitespace, Punctuation, Name.Label), '#pop'), (atom_re, Name.Entity, '#pop'), ], 'map_key': [ include('root'), (r'=>', Punctuation, 'map_val'), (r':=', Punctuation, 'map_val'), (r'\}', Punctuation, '#pop'), ], 'map_val': [ include('root'), (r',', Punctuation, '#pop'), (r'(?=\})', Punctuation, '#pop'), ], } class ErlangShellLexer(Lexer): """ Shell sessions in erl (for Erlang code). .. versionadded:: 1.1 """ name = 'Erlang erl session' aliases = ['erl'] filenames = ['*.erl-sh'] mimetypes = ['text/x-erl-shellsession'] _prompt_re = re.compile(r'(?:\([\w@_.]+\))?\d+>(?=\s|\Z)') def get_tokens_unprocessed(self, text): erlexer = ErlangLexer(**self.options) curcode = '' insertions = [] for match in line_re.finditer(text): line = match.group() m = self._prompt_re.match(line) if m is not None: end = m.end() insertions.append((len(curcode), [(0, Generic.Prompt, line[:end])])) curcode += line[end:] else: if curcode: yield from do_insertions(insertions, erlexer.get_tokens_unprocessed(curcode)) curcode = '' insertions = [] if line.startswith('*'): yield match.start(), Generic.Traceback, line else: yield match.start(), Generic.Output, line if curcode: yield from do_insertions(insertions, erlexer.get_tokens_unprocessed(curcode)) def gen_elixir_string_rules(name, symbol, token): states = {} states['string_' + name] = [ (r'[^#%s\\]+' % (symbol,), token), include('escapes'), (r'\\.', token), (r'(%s)' % (symbol,), bygroups(token), "#pop"), include('interpol') ] return states def gen_elixir_sigstr_rules(term, term_class, token, interpol=True): if interpol: return [ (r'[^#%s\\]+' % (term_class,), token), include('escapes'), (r'\\.', token), (r'%s[a-zA-Z]*' % (term,), token, '#pop'), include('interpol') ] else: return [ (r'[^%s\\]+' % (term_class,), token), (r'\\.', token), (r'%s[a-zA-Z]*' % (term,), token, '#pop'), ] class ElixirLexer(RegexLexer): """ For the Elixir language. .. versionadded:: 1.5 """ name = 'Elixir' url = 'http://elixir-lang.org' aliases = ['elixir', 'ex', 'exs'] filenames = ['*.ex', '*.eex', '*.exs', '*.leex'] mimetypes = ['text/x-elixir'] KEYWORD = ('fn', 'do', 'end', 'after', 'else', 'rescue', 'catch') KEYWORD_OPERATOR = ('not', 'and', 'or', 'when', 'in') BUILTIN = ( 'case', 'cond', 'for', 'if', 'unless', 'try', 'receive', 'raise', 'quote', 'unquote', 'unquote_splicing', 'throw', 'super', ) BUILTIN_DECLARATION = ( 'def', 'defp', 'defmodule', 'defprotocol', 'defmacro', 'defmacrop', 'defdelegate', 'defexception', 'defstruct', 'defimpl', 'defcallback', ) BUILTIN_NAMESPACE = ('import', 'require', 'use', 'alias') CONSTANT = ('nil', 'true', 'false') PSEUDO_VAR = ('_', '__MODULE__', '__DIR__', '__ENV__', '__CALLER__') OPERATORS3 = ( '<<<', '>>>', '|||', '&&&', '^^^', '~~~', '===', '!==', '~>>', '<~>', '|~>', '<|>', ) OPERATORS2 = ( '==', '!=', '<=', '>=', '&&', '||', '<>', '++', '--', '|>', '=~', '->', '<-', '|', '.', '=', '~>', '<~', ) OPERATORS1 = ('<', '>', '+', '-', '*', '/', '!', '^', '&') PUNCTUATION = ( '\\\\', '<<', '>>', '=>', '(', ')', ':', ';', ',', '[', ']', ) def get_tokens_unprocessed(self, text): for index, token, value in RegexLexer.get_tokens_unprocessed(self, text): if token is Name: if value in self.KEYWORD: yield index, Keyword, value elif value in self.KEYWORD_OPERATOR: yield index, Operator.Word, value elif value in self.BUILTIN: yield index, Keyword, value elif value in self.BUILTIN_DECLARATION: yield index, Keyword.Declaration, value elif value in self.BUILTIN_NAMESPACE: yield index, Keyword.Namespace, value elif value in self.CONSTANT: yield index, Name.Constant, value elif value in self.PSEUDO_VAR: yield index, Name.Builtin.Pseudo, value else: yield index, token, value else: yield index, token, value def gen_elixir_sigil_rules(): # all valid sigil terminators (excluding heredocs) terminators = [ (r'\{', r'\}', '}', 'cb'), (r'\[', r'\]', r'\]', 'sb'), (r'\(', r'\)', ')', 'pa'), ('<', '>', '>', 'ab'), ('/', '/', '/', 'slas'), (r'\|', r'\|', '|', 'pipe'), ('"', '"', '"', 'quot'), ("'", "'", "'", 'apos'), ] # heredocs have slightly different rules triquotes = [(r'"""', 'triquot'), (r"'''", 'triapos')] token = String.Other states = {'sigils': []} for term, name in triquotes: states['sigils'] += [ (r'(~[a-z])(%s)' % (term,), bygroups(token, String.Heredoc), (name + '-end', name + '-intp')), (r'(~[A-Z])(%s)' % (term,), bygroups(token, String.Heredoc), (name + '-end', name + '-no-intp')), ] states[name + '-end'] = [ (r'[a-zA-Z]+', token, '#pop'), default('#pop'), ] states[name + '-intp'] = [ (r'^(\s*)(' + term + ')', bygroups(Whitespace, String.Heredoc), '#pop'), include('heredoc_interpol'), ] states[name + '-no-intp'] = [ (r'^(\s*)(' + term +')', bygroups(Whitespace, String.Heredoc), '#pop'), include('heredoc_no_interpol'), ] for lterm, rterm, rterm_class, name in terminators: states['sigils'] += [ (r'~[a-z]' + lterm, token, name + '-intp'), (r'~[A-Z]' + lterm, token, name + '-no-intp'), ] states[name + '-intp'] = \ gen_elixir_sigstr_rules(rterm, rterm_class, token) states[name + '-no-intp'] = \ gen_elixir_sigstr_rules(rterm, rterm_class, token, interpol=False) return states op3_re = "|".join(re.escape(s) for s in OPERATORS3) op2_re = "|".join(re.escape(s) for s in OPERATORS2) op1_re = "|".join(re.escape(s) for s in OPERATORS1) ops_re = r'(?:%s|%s|%s)' % (op3_re, op2_re, op1_re) punctuation_re = "|".join(re.escape(s) for s in PUNCTUATION) alnum = r'\w' name_re = r'(?:\.\.\.|[a-z_]%s*[!?]?)' % alnum modname_re = r'[A-Z]%(alnum)s*(?:\.[A-Z]%(alnum)s*)*' % {'alnum': alnum} complex_name_re = r'(?:%s|%s|%s)' % (name_re, modname_re, ops_re) special_atom_re = r'(?:\.\.\.|<<>>|%\{\}|%|\{\})' long_hex_char_re = r'(\\x\{)([\da-fA-F]+)(\})' hex_char_re = r'(\\x[\da-fA-F]{1,2})' escape_char_re = r'(\\[abdefnrstv])' tokens = { 'root': [ (r'\s+', Whitespace), (r'#.*$', Comment.Single), # Various kinds of characters (r'(\?)' + long_hex_char_re, bygroups(String.Char, String.Escape, Number.Hex, String.Escape)), (r'(\?)' + hex_char_re, bygroups(String.Char, String.Escape)), (r'(\?)' + escape_char_re, bygroups(String.Char, String.Escape)), (r'\?\\?.', String.Char), # '::' has to go before atoms (r':::', String.Symbol), (r'::', Operator), # atoms (r':' + special_atom_re, String.Symbol), (r':' + complex_name_re, String.Symbol), (r':"', String.Symbol, 'string_double_atom'), (r":'", String.Symbol, 'string_single_atom'), # [keywords: ...] (r'(%s|%s)(:)(?=\s|\n)' % (special_atom_re, complex_name_re), bygroups(String.Symbol, Punctuation)), # @attributes (r'@' + name_re, Name.Attribute), # identifiers (name_re, Name), (r'(%%?)(%s)' % (modname_re,), bygroups(Punctuation, Name.Class)), # operators and punctuation (op3_re, Operator), (op2_re, Operator), (punctuation_re, Punctuation), (r'&\d', Name.Entity), # anon func arguments (op1_re, Operator), # numbers (r'0b[01]+', Number.Bin), (r'0o[0-7]+', Number.Oct), (r'0x[\da-fA-F]+', Number.Hex), (r'\d(_?\d)*\.\d(_?\d)*([eE][-+]?\d(_?\d)*)?', Number.Float), (r'\d(_?\d)*', Number.Integer), # strings and heredocs (r'(""")(\s*)', bygroups(String.Heredoc, Whitespace), 'heredoc_double'), (r"(''')(\s*)$", bygroups(String.Heredoc, Whitespace), 'heredoc_single'), (r'"', String.Double, 'string_double'), (r"'", String.Single, 'string_single'), include('sigils'), (r'%\{', Punctuation, 'map_key'), (r'\{', Punctuation, 'tuple'), ], 'heredoc_double': [ (r'^(\s*)(""")', bygroups(Whitespace, String.Heredoc), '#pop'), include('heredoc_interpol'), ], 'heredoc_single': [ (r"^\s*'''", String.Heredoc, '#pop'), include('heredoc_interpol'), ], 'heredoc_interpol': [ (r'[^#\\\n]+', String.Heredoc), include('escapes'), (r'\\.', String.Heredoc), (r'\n+', String.Heredoc), include('interpol'), ], 'heredoc_no_interpol': [ (r'[^\\\n]+', String.Heredoc), (r'\\.', String.Heredoc), (r'\n+', Whitespace), ], 'escapes': [ (long_hex_char_re, bygroups(String.Escape, Number.Hex, String.Escape)), (hex_char_re, String.Escape), (escape_char_re, String.Escape), ], 'interpol': [ (r'#\{', String.Interpol, 'interpol_string'), ], 'interpol_string': [ (r'\}', String.Interpol, "#pop"), include('root') ], 'map_key': [ include('root'), (r':', Punctuation, 'map_val'), (r'=>', Punctuation, 'map_val'), (r'\}', Punctuation, '#pop'), ], 'map_val': [ include('root'), (r',', Punctuation, '#pop'), (r'(?=\})', Punctuation, '#pop'), ], 'tuple': [ include('root'), (r'\}', Punctuation, '#pop'), ], } tokens.update(gen_elixir_string_rules('double', '"', String.Double)) tokens.update(gen_elixir_string_rules('single', "'", String.Single)) tokens.update(gen_elixir_string_rules('double_atom', '"', String.Symbol)) tokens.update(gen_elixir_string_rules('single_atom', "'", String.Symbol)) tokens.update(gen_elixir_sigil_rules()) class ElixirConsoleLexer(Lexer): """ For Elixir interactive console (iex) output like: .. sourcecode:: iex iex> [head | tail] = [1,2,3] [1,2,3] iex> head 1 iex> tail [2,3] iex> [head | tail] [1,2,3] iex> length [head | tail] 3 .. versionadded:: 1.5 """ name = 'Elixir iex session' aliases = ['iex'] mimetypes = ['text/x-elixir-shellsession'] _prompt_re = re.compile(r'(iex|\.{3})((?:\([\w@_.]+\))?\d+|\(\d+\))?> ') def get_tokens_unprocessed(self, text): exlexer = ElixirLexer(**self.options) curcode = '' in_error = False insertions = [] for match in line_re.finditer(text): line = match.group() if line.startswith('** '): in_error = True insertions.append((len(curcode), [(0, Generic.Error, line[:-1])])) curcode += line[-1:] else: m = self._prompt_re.match(line) if m is not None: in_error = False end = m.end() insertions.append((len(curcode), [(0, Generic.Prompt, line[:end])])) curcode += line[end:] else: if curcode: yield from do_insertions( insertions, exlexer.get_tokens_unprocessed(curcode)) curcode = '' insertions = [] token = Generic.Error if in_error else Generic.Output yield match.start(), token, line if curcode: yield from do_insertions( insertions, exlexer.get_tokens_unprocessed(curcode))
19,170
Python
35.240076
96
0.452374
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/ul4.py
""" pygments.lexers.ul4 ~~~~~~~~~~~~~~~~~~~ Lexer for the UL4 templating language. More information: https://python.livinglogic.de/UL4.html :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, DelegatingLexer, bygroups, words, include from pygments.token import Comment, Text, Keyword, String, Number, Literal, \ Name, Other, Operator from pygments.lexers.web import HtmlLexer, XmlLexer, CssLexer, JavascriptLexer from pygments.lexers.python import PythonLexer __all__ = ['UL4Lexer', 'HTMLUL4Lexer', 'XMLUL4Lexer', 'CSSUL4Lexer', 'JavascriptUL4Lexer', 'PythonUL4Lexer'] class UL4Lexer(RegexLexer): """ Generic lexer for UL4. .. versionadded:: 2.12 """ flags = re.MULTILINE | re.DOTALL name = 'UL4' aliases = ['ul4'] filenames = ['*.ul4'] tokens = { "root": [ ( # Template header without name: # ``<?ul4?>`` r"(<\?)(\s*)(ul4)(\s*)(\?>)", bygroups(Comment.Preproc, Text.Whitespace, Keyword, Text.Whitespace, Comment.Preproc), ), ( # Template header with name (potentially followed by the signature): # ``<?ul4 foo(bar=42)?>`` r"(<\?)(\s*)(ul4)(\s*)([a-zA-Z_][a-zA-Z_0-9]*)?", bygroups(Comment.Preproc, Text.Whitespace, Keyword, Text.Whitespace, Name.Function), "ul4", # Switch to "expression" mode ), ( # Comment: # ``<?note foobar?>`` r"<\?\s*note\s.*?\?>", Comment, ), ( # Template documentation: # ``<?doc foobar?>`` r"<\?\s*doc\s.*?\?>", String.Doc, ), ( # ``<?ignore?>`` tag for commenting out code: # ``<?ignore?>...<?end ignore?>`` r"<\?\s*ignore\s*\?>", Comment, "ignore", # Switch to "ignore" mode ), ( # ``<?def?>`` tag for defining local templates # ``<?def foo(bar=42)?>...<?end def?>`` r"(<\?)(\s*)(def)(\s*)([a-zA-Z_][a-zA-Z_0-9]*)?", bygroups(Comment.Preproc, Text.Whitespace, Keyword, Text.Whitespace, Name.Function), "ul4", # Switch to "expression" mode ), ( # The rest of the supported tags r"(<\?)(\s*)(printx|print|for|if|elif|else|while|code|renderblocks?|render)\b", bygroups(Comment.Preproc, Text.Whitespace, Keyword), "ul4", # Switch to "expression" mode ), ( # ``<?end?>`` tag for ending ``<?def?>``, ``<?for?>``, # ``<?if?>``, ``<?while?>``, ``<?renderblock?>`` and # ``<?renderblocks?>`` blocks. r"(<\?)(\s*)(end)\b", bygroups(Comment.Preproc, Text.Whitespace, Keyword), "end", # Switch to "end tag" mode ), ( # ``<?whitespace?>`` tag for configuring whitespace handlng r"(<\?)(\s*)(whitespace)\b", bygroups(Comment.Preproc, Text.Whitespace, Keyword), "whitespace", # Switch to "whitespace" mode ), # Plain text (r"[^<]+", Other), (r"<", Other), ], # Ignore mode ignores everything upto the matching ``<?end ignore?>`` tag "ignore": [ # Nested ``<?ignore?>`` tag (r"<\?\s*ignore\s*\?>", Comment, "#push"), # ``<?end ignore?>`` tag (r"<\?\s*end\s+ignore\s*\?>", Comment, "#pop"), # Everything else (r"[^<]+", Comment), (r".", Comment), ], # UL4 expressions "ul4": [ # End the tag (r"\?>", Comment.Preproc, "#pop"), # Start triple quoted string constant ("'''", String, "string13"), ('"""', String, "string23"), # Start single quoted string constant ("'", String, "string1"), ('"', String, "string2"), # Floating point number (r"\d+\.\d*([eE][+-]?\d+)?", Number.Float), (r"\.\d+([eE][+-]?\d+)?", Number.Float), (r"\d+[eE][+-]?\d+", Number.Float), # Binary integer: ``0b101010`` (r"0[bB][01]+", Number.Bin), # Octal integer: ``0o52`` (r"0[oO][0-7]+", Number.Oct), # Hexadecimal integer: ``0x2a`` (r"0[xX][0-9a-fA-F]+", Number.Hex), # Date or datetime: ``@(2000-02-29)``/``@(2000-02-29T12:34:56.987654)`` (r"@\(\d\d\d\d-\d\d-\d\d(T(\d\d:\d\d(:\d\d(\.\d{6})?)?)?)?\)", Literal.Date), # Color: ``#fff``, ``#fff8f0`` etc. (r"#[0-9a-fA-F]{8}", Literal.Color), (r"#[0-9a-fA-F]{6}", Literal.Color), (r"#[0-9a-fA-F]{3,4}", Literal.Color), # Decimal integer: ``42`` (r"\d+", Number.Integer), # Operators (r"//|==|!=|>=|<=|<<|>>|\+=|-=|\*=|/=|//=|<<=|>>=|&=|\|=|^=|=|[\[\]{},:*/().~%&|<>^+-]", Operator), # Keywords (words(("for", "in", "if", "else", "not", "is", "and", "or"), suffix=r"\b"), Keyword), # Builtin constants (words(("None", "False", "True"), suffix=r"\b"), Keyword.Constant), # Variable names (r"[a-zA-Z_][a-zA-Z0-9_]*", Name), # Whitespace (r"\s+", Text.Whitespace), ], # ``<?end ...?>`` tag for closing the last open block "end": [ (r"\?>", Comment.Preproc, "#pop"), (words(("for", "if", "def", "while", "renderblock", "renderblocks"), suffix=r"\b"), Keyword), (r"\s+", Text), ], # Content of the ``<?whitespace ...?>`` tag: # ``keep``, ``strip`` or ``smart`` "whitespace": [ (r"\?>", Comment.Preproc, "#pop"), (words(("keep", "strip", "smart"), suffix=r"\b"), Comment.Preproc), (r"\s+", Text.Whitespace), ], # Inside a string constant "stringescapes": [ (r"""\\[\\'"abtnfr]""", String.Escape), (r"\\x[0-9a-fA-F]{2}", String.Escape), (r"\\u[0-9a-fA-F]{4}", String.Escape), (r"\\U[0-9a-fA-F]{8}", String.Escape), ], # Inside a triple quoted string started with ``'''`` "string13": [ (r"'''", String, "#pop"), include("stringescapes"), (r"[^\\']+", String), (r'.', String), ], # Inside a triple quoted string started with ``"""`` "string23": [ (r'"""', String, "#pop"), include("stringescapes"), (r'[^\\"]+', String), (r'.', String), ], # Inside a single quoted string started with ``'`` "string1": [ (r"'", String, "#pop"), include("stringescapes"), (r"[^\\']+", String), (r'.', String), ], # Inside a single quoted string started with ``"`` "string2": [ (r'"', String, "#pop"), include("stringescapes"), (r'[^\\"]+', String), (r'.', String), ], } class HTMLUL4Lexer(DelegatingLexer): """ Lexer for UL4 embedded in HTML. """ name = 'HTML+UL4' aliases = ['html+ul4'] filenames = ['*.htmlul4'] def __init__(self, **options): super().__init__(HtmlLexer, UL4Lexer, **options) class XMLUL4Lexer(DelegatingLexer): """ Lexer for UL4 embedded in XML. """ name = 'XML+UL4' aliases = ['xml+ul4'] filenames = ['*.xmlul4'] def __init__(self, **options): super().__init__(XmlLexer, UL4Lexer, **options) class CSSUL4Lexer(DelegatingLexer): """ Lexer for UL4 embedded in CSS. """ name = 'CSS+UL4' aliases = ['css+ul4'] filenames = ['*.cssul4'] def __init__(self, **options): super().__init__(CssLexer, UL4Lexer, **options) class JavascriptUL4Lexer(DelegatingLexer): """ Lexer for UL4 embedded in Javascript. """ name = 'Javascript+UL4' aliases = ['js+ul4'] filenames = ['*.jsul4'] def __init__(self, **options): super().__init__(JavascriptLexer, UL4Lexer, **options) class PythonUL4Lexer(DelegatingLexer): """ Lexer for UL4 embedded in Python. """ name = 'Python+UL4' aliases = ['py+ul4'] filenames = ['*.pyul4'] def __init__(self, **options): super().__init__(PythonLexer, UL4Lexer, **options)
8,956
Python
32.421642
111
0.44473
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/futhark.py
""" pygments.lexers.futhark ~~~~~~~~~~~~~~~~~~~~~~~ Lexer for the Futhark language :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, bygroups from pygments.token import Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Whitespace from pygments import unistring as uni __all__ = ['FutharkLexer'] class FutharkLexer(RegexLexer): """ A Futhark lexer .. versionadded:: 2.8 """ name = 'Futhark' url = 'https://futhark-lang.org/' aliases = ['futhark'] filenames = ['*.fut'] mimetypes = ['text/x-futhark'] num_types = ('i8', 'i16', 'i32', 'i64', 'u8', 'u16', 'u32', 'u64', 'f32', 'f64') other_types = ('bool', ) reserved = ('if', 'then', 'else', 'def', 'let', 'loop', 'in', 'with', 'type', 'type~', 'type^', 'val', 'entry', 'for', 'while', 'do', 'case', 'match', 'include', 'import', 'module', 'open', 'local', 'assert', '_') ascii = ('NUL', 'SOH', '[SE]TX', 'EOT', 'ENQ', 'ACK', 'BEL', 'BS', 'HT', 'LF', 'VT', 'FF', 'CR', 'S[OI]', 'DLE', 'DC[1-4]', 'NAK', 'SYN', 'ETB', 'CAN', 'EM', 'SUB', 'ESC', '[FGRU]S', 'SP', 'DEL') num_postfix = r'(%s)?' % '|'.join(num_types) identifier_re = '[a-zA-Z_][a-zA-Z_0-9\']*' # opstart_re = '+\-\*/%=\!><\|&\^' tokens = { 'root': [ (r'--(.*?)$', Comment.Single), (r'\s+', Whitespace), (r'\(\)', Punctuation), (r'\b(%s)(?!\')\b' % '|'.join(reserved), Keyword.Reserved), (r'\b(%s)(?!\')\b' % '|'.join(num_types + other_types), Keyword.Type), # Identifiers (r'#\[([a-zA-Z_\(\) ]*)\]', Comment.Preproc), (r'[#!]?(%s\.)*%s' % (identifier_re, identifier_re), Name), (r'\\', Operator), (r'[-+/%=!><|&*^][-+/%=!><|&*^.]*', Operator), (r'[][(),:;`{}?.\'~^]', Punctuation), # Numbers (r'0[xX]_*[\da-fA-F](_*[\da-fA-F])*_*[pP][+-]?\d(_*\d)*' + num_postfix, Number.Float), (r'0[xX]_*[\da-fA-F](_*[\da-fA-F])*\.[\da-fA-F](_*[\da-fA-F])*' r'(_*[pP][+-]?\d(_*\d)*)?' + num_postfix, Number.Float), (r'\d(_*\d)*_*[eE][+-]?\d(_*\d)*' + num_postfix, Number.Float), (r'\d(_*\d)*\.\d(_*\d)*(_*[eE][+-]?\d(_*\d)*)?' + num_postfix, Number.Float), (r'0[bB]_*[01](_*[01])*' + num_postfix, Number.Bin), (r'0[xX]_*[\da-fA-F](_*[\da-fA-F])*' + num_postfix, Number.Hex), (r'\d(_*\d)*' + num_postfix, Number.Integer), # Character/String Literals (r"'", String.Char, 'character'), (r'"', String, 'string'), # Special (r'\[[a-zA-Z_\d]*\]', Keyword.Type), (r'\(\)', Name.Builtin), ], 'character': [ # Allows multi-chars, incorrectly. (r"[^\\']'", String.Char, '#pop'), (r"\\", String.Escape, 'escape'), ("'", String.Char, '#pop'), ], 'string': [ (r'[^\\"]+', String), (r"\\", String.Escape, 'escape'), ('"', String, '#pop'), ], 'escape': [ (r'[abfnrtv"\'&\\]', String.Escape, '#pop'), (r'\^[][' + uni.Lu + r'@^_]', String.Escape, '#pop'), ('|'.join(ascii), String.Escape, '#pop'), (r'o[0-7]+', String.Escape, '#pop'), (r'x[\da-fA-F]+', String.Escape, '#pop'), (r'\d+', String.Escape, '#pop'), (r'(\s+)(\\)', bygroups(Whitespace, String.Escape), '#pop'), ], }
3,732
Python
33.88785
89
0.416667
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/configs.py
""" pygments.lexers.configs ~~~~~~~~~~~~~~~~~~~~~~~ Lexers for configuration file formats. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import ExtendedRegexLexer, RegexLexer, default, words, \ bygroups, include, using, line_re from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Whitespace, Literal, Error, Generic from pygments.lexers.shell import BashLexer from pygments.lexers.data import JsonLexer __all__ = ['IniLexer', 'RegeditLexer', 'PropertiesLexer', 'KconfigLexer', 'Cfengine3Lexer', 'ApacheConfLexer', 'SquidConfLexer', 'NginxConfLexer', 'LighttpdConfLexer', 'DockerLexer', 'TerraformLexer', 'TermcapLexer', 'TerminfoLexer', 'PkgConfigLexer', 'PacmanConfLexer', 'AugeasLexer', 'TOMLLexer', 'NestedTextLexer', 'SingularityLexer', 'UnixConfigLexer'] class IniLexer(RegexLexer): """ Lexer for configuration files in INI style. """ name = 'INI' aliases = ['ini', 'cfg', 'dosini'] filenames = [ '*.ini', '*.cfg', '*.inf', '.editorconfig', # systemd unit files # https://www.freedesktop.org/software/systemd/man/systemd.unit.html '*.service', '*.socket', '*.device', '*.mount', '*.automount', '*.swap', '*.target', '*.path', '*.timer', '*.slice', '*.scope', ] mimetypes = ['text/x-ini', 'text/inf'] tokens = { 'root': [ (r'\s+', Whitespace), (r'[;#].*', Comment.Single), (r'(\[.*?\])([ \t]*)$', bygroups(Keyword, Whitespace)), (r'(.*?)([  \t]*)([=:])([ \t]*)([^;#\n]*)(\\)(\s+)', bygroups(Name.Attribute, Whitespace, Operator, Whitespace, String, Text, Whitespace), "value"), (r'(.*?)([ \t]*)([=:])([  \t]*)([^ ;#\n]*(?: +[^ ;#\n]+)*)', bygroups(Name.Attribute, Whitespace, Operator, Whitespace, String)), # standalone option, supported by some INI parsers (r'(.+?)$', Name.Attribute), ], 'value': [ # line continuation (r'\s+', Whitespace), (r'(\s*)(.*)(\\)([ \t]*)', bygroups(Whitespace, String, Text, Whitespace)), (r'.*$', String, "#pop"), ], } def analyse_text(text): npos = text.find('\n') if npos < 3: return False return text[0] == '[' and text[npos-1] == ']' class RegeditLexer(RegexLexer): """ Lexer for Windows Registry files produced by regedit. .. versionadded:: 1.6 """ name = 'reg' url = 'http://en.wikipedia.org/wiki/Windows_Registry#.REG_files' aliases = ['registry'] filenames = ['*.reg'] mimetypes = ['text/x-windows-registry'] tokens = { 'root': [ (r'Windows Registry Editor.*', Text), (r'\s+', Whitespace), (r'[;#].*', Comment.Single), (r'(\[)(-?)(HKEY_[A-Z_]+)(.*?\])$', bygroups(Keyword, Operator, Name.Builtin, Keyword)), # String keys, which obey somewhat normal escaping (r'("(?:\\"|\\\\|[^"])+")([ \t]*)(=)([ \t]*)', bygroups(Name.Attribute, Whitespace, Operator, Whitespace), 'value'), # Bare keys (includes @) (r'(.*?)([ \t]*)(=)([ \t]*)', bygroups(Name.Attribute, Whitespace, Operator, Whitespace), 'value'), ], 'value': [ (r'-', Operator, '#pop'), # delete value (r'(dword|hex(?:\([0-9a-fA-F]\))?)(:)([0-9a-fA-F,]+)', bygroups(Name.Variable, Punctuation, Number), '#pop'), # As far as I know, .reg files do not support line continuation. (r'.+', String, '#pop'), default('#pop'), ] } def analyse_text(text): return text.startswith('Windows Registry Editor') class PropertiesLexer(RegexLexer): """ Lexer for configuration files in Java's properties format. Note: trailing whitespace counts as part of the value as per spec .. versionadded:: 1.4 """ name = 'Properties' aliases = ['properties', 'jproperties'] filenames = ['*.properties'] mimetypes = ['text/x-java-properties'] tokens = { 'root': [ (r'\s+', Whitespace), (r'[!#].*|/{2}.*', Comment.Single), # search for first separator (r'([^\\\n]|\\.)*?(?=[ \f\t=:])', Name.Attribute, "separator"), # empty key (r'.+?$', Name.Attribute), ], 'separator': [ # search for line continuation escape (r'([ \f\t]*)([=:]*)([ \f\t]*)(.*(?<!\\)(?:\\{2})*)(\\)(?!\\)$', bygroups(Whitespace, Operator, Whitespace, String, Text), "value", "#pop"), (r'([ \f\t]*)([=:]*)([ \f\t]*)(.*)', bygroups(Whitespace, Operator, Whitespace, String), "#pop"), ], 'value': [ # line continuation (r'\s+', Whitespace), # search for line continuation escape (r'(\s*)(.*(?<!\\)(?:\\{2})*)(\\)(?!\\)([ \t]*)', bygroups(Whitespace, String, Text, Whitespace)), (r'.*$', String, "#pop"), ], } def _rx_indent(level): # Kconfig *always* interprets a tab as 8 spaces, so this is the default. # Edit this if you are in an environment where KconfigLexer gets expanded # input (tabs expanded to spaces) and the expansion tab width is != 8, # e.g. in connection with Trac (trac.ini, [mimeviewer], tab_width). # Value range here is 2 <= {tab_width} <= 8. tab_width = 8 # Regex matching a given indentation {level}, assuming that indentation is # a multiple of {tab_width}. In other cases there might be problems. if tab_width == 2: space_repeat = '+' else: space_repeat = '{1,%d}' % (tab_width - 1) if level == 1: level_repeat = '' else: level_repeat = '{%s}' % level return r'(?:\t| %s\t| {%s})%s.*\n' % (space_repeat, tab_width, level_repeat) class KconfigLexer(RegexLexer): """ For Linux-style Kconfig files. .. versionadded:: 1.6 """ name = 'Kconfig' aliases = ['kconfig', 'menuconfig', 'linux-config', 'kernel-config'] # Adjust this if new kconfig file names appear in your environment filenames = ['Kconfig*', '*Config.in*', 'external.in*', 'standard-modules.in'] mimetypes = ['text/x-kconfig'] # No re.MULTILINE, indentation-aware help text needs line-by-line handling flags = 0 def call_indent(level): # If indentation >= {level} is detected, enter state 'indent{level}' return (_rx_indent(level), String.Doc, 'indent%s' % level) def do_indent(level): # Print paragraphs of indentation level >= {level} as String.Doc, # ignoring blank lines. Then return to 'root' state. return [ (_rx_indent(level), String.Doc), (r'\s*\n', Text), default('#pop:2') ] tokens = { 'root': [ (r'\s+', Whitespace), (r'#.*?\n', Comment.Single), (words(( 'mainmenu', 'config', 'menuconfig', 'choice', 'endchoice', 'comment', 'menu', 'endmenu', 'visible if', 'if', 'endif', 'source', 'prompt', 'select', 'depends on', 'default', 'range', 'option'), suffix=r'\b'), Keyword), (r'(---help---|help)[\t ]*\n', Keyword, 'help'), (r'(bool|tristate|string|hex|int|defconfig_list|modules|env)\b', Name.Builtin), (r'[!=&|]', Operator), (r'[()]', Punctuation), (r'[0-9]+', Number.Integer), (r"'(''|[^'])*'", String.Single), (r'"(""|[^"])*"', String.Double), (r'\S+', Text), ], # Help text is indented, multi-line and ends when a lower indentation # level is detected. 'help': [ # Skip blank lines after help token, if any (r'\s*\n', Text), # Determine the first help line's indentation level heuristically(!). # Attention: this is not perfect, but works for 99% of "normal" # indentation schemes up to a max. indentation level of 7. call_indent(7), call_indent(6), call_indent(5), call_indent(4), call_indent(3), call_indent(2), call_indent(1), default('#pop'), # for incomplete help sections without text ], # Handle text for indentation levels 7 to 1 'indent7': do_indent(7), 'indent6': do_indent(6), 'indent5': do_indent(5), 'indent4': do_indent(4), 'indent3': do_indent(3), 'indent2': do_indent(2), 'indent1': do_indent(1), } class Cfengine3Lexer(RegexLexer): """ Lexer for CFEngine3 policy files. .. versionadded:: 1.5 """ name = 'CFEngine3' url = 'http://cfengine.org' aliases = ['cfengine3', 'cf3'] filenames = ['*.cf'] mimetypes = [] tokens = { 'root': [ (r'#.*?\n', Comment), (r'(body)(\s+)(\S+)(\s+)(control)', bygroups(Keyword, Whitespace, Keyword, Whitespace, Keyword)), (r'(body|bundle)(\s+)(\S+)(\s+)(\w+)(\()', bygroups(Keyword, Whitespace, Keyword, Whitespace, Name.Function, Punctuation), 'arglist'), (r'(body|bundle)(\s+)(\S+)(\s+)(\w+)', bygroups(Keyword, Whitespace, Keyword, Whitespace, Name.Function)), (r'(")([^"]+)(")(\s+)(string|slist|int|real)(\s*)(=>)(\s*)', bygroups(Punctuation, Name.Variable, Punctuation, Whitespace, Keyword.Type, Whitespace, Operator, Whitespace)), (r'(\S+)(\s*)(=>)(\s*)', bygroups(Keyword.Reserved, Whitespace, Operator, Text)), (r'"', String, 'string'), (r'(\w+)(\()', bygroups(Name.Function, Punctuation)), (r'([\w.!&|()]+)(::)', bygroups(Name.Class, Punctuation)), (r'(\w+)(:)', bygroups(Keyword.Declaration, Punctuation)), (r'@[{(][^)}]+[})]', Name.Variable), (r'[(){},;]', Punctuation), (r'=>', Operator), (r'->', Operator), (r'\d+\.\d+', Number.Float), (r'\d+', Number.Integer), (r'\w+', Name.Function), (r'\s+', Whitespace), ], 'string': [ (r'\$[{(]', String.Interpol, 'interpol'), (r'\\.', String.Escape), (r'"', String, '#pop'), (r'\n', String), (r'.', String), ], 'interpol': [ (r'\$[{(]', String.Interpol, '#push'), (r'[})]', String.Interpol, '#pop'), (r'[^${()}]+', String.Interpol), ], 'arglist': [ (r'\)', Punctuation, '#pop'), (r',', Punctuation), (r'\w+', Name.Variable), (r'\s+', Whitespace), ], } class ApacheConfLexer(RegexLexer): """ Lexer for configuration files following the Apache config file format. .. versionadded:: 0.6 """ name = 'ApacheConf' aliases = ['apacheconf', 'aconf', 'apache'] filenames = ['.htaccess', 'apache.conf', 'apache2.conf'] mimetypes = ['text/x-apacheconf'] flags = re.MULTILINE | re.IGNORECASE tokens = { 'root': [ (r'\s+', Whitespace), (r'#(.*\\\n)+.*$|(#.*?)$', Comment), (r'(<[^\s>/][^\s>]*)(?:(\s+)(.*))?(>)', bygroups(Name.Tag, Whitespace, String, Name.Tag)), (r'(</[^\s>]+)(>)', bygroups(Name.Tag, Name.Tag)), (r'[a-z]\w*', Name.Builtin, 'value'), (r'\.+', Text), ], 'value': [ (r'\\\n', Text), (r'\n+', Whitespace, '#pop'), (r'\\', Text), (r'[^\S\n]+', Whitespace), (r'\d+\.\d+\.\d+\.\d+(?:/\d+)?', Number), (r'\d+', Number), (r'/([*a-z0-9][*\w./-]+)', String.Other), (r'(on|off|none|any|all|double|email|dns|min|minimal|' r'os|productonly|full|emerg|alert|crit|error|warn|' r'notice|info|debug|registry|script|inetd|standalone|' r'user|group)\b', Keyword), (r'"([^"\\]*(?:\\(.|\n)[^"\\]*)*)"', String.Double), (r'[^\s"\\]+', Text) ], } class SquidConfLexer(RegexLexer): """ Lexer for squid configuration files. .. versionadded:: 0.9 """ name = 'SquidConf' url = 'http://www.squid-cache.org/' aliases = ['squidconf', 'squid.conf', 'squid'] filenames = ['squid.conf'] mimetypes = ['text/x-squidconf'] flags = re.IGNORECASE keywords = ( "access_log", "acl", "always_direct", "announce_host", "announce_period", "announce_port", "announce_to", "anonymize_headers", "append_domain", "as_whois_server", "auth_param_basic", "authenticate_children", "authenticate_program", "authenticate_ttl", "broken_posts", "buffered_logs", "cache_access_log", "cache_announce", "cache_dir", "cache_dns_program", "cache_effective_group", "cache_effective_user", "cache_host", "cache_host_acl", "cache_host_domain", "cache_log", "cache_mem", "cache_mem_high", "cache_mem_low", "cache_mgr", "cachemgr_passwd", "cache_peer", "cache_peer_access", "cache_replacement_policy", "cache_stoplist", "cache_stoplist_pattern", "cache_store_log", "cache_swap", "cache_swap_high", "cache_swap_log", "cache_swap_low", "client_db", "client_lifetime", "client_netmask", "connect_timeout", "coredump_dir", "dead_peer_timeout", "debug_options", "delay_access", "delay_class", "delay_initial_bucket_level", "delay_parameters", "delay_pools", "deny_info", "dns_children", "dns_defnames", "dns_nameservers", "dns_testnames", "emulate_httpd_log", "err_html_text", "fake_user_agent", "firewall_ip", "forwarded_for", "forward_snmpd_port", "fqdncache_size", "ftpget_options", "ftpget_program", "ftp_list_width", "ftp_passive", "ftp_user", "half_closed_clients", "header_access", "header_replace", "hierarchy_stoplist", "high_response_time_warning", "high_page_fault_warning", "hosts_file", "htcp_port", "http_access", "http_anonymizer", "httpd_accel", "httpd_accel_host", "httpd_accel_port", "httpd_accel_uses_host_header", "httpd_accel_with_proxy", "http_port", "http_reply_access", "icp_access", "icp_hit_stale", "icp_port", "icp_query_timeout", "ident_lookup", "ident_lookup_access", "ident_timeout", "incoming_http_average", "incoming_icp_average", "inside_firewall", "ipcache_high", "ipcache_low", "ipcache_size", "local_domain", "local_ip", "logfile_rotate", "log_fqdn", "log_icp_queries", "log_mime_hdrs", "maximum_object_size", "maximum_single_addr_tries", "mcast_groups", "mcast_icp_query_timeout", "mcast_miss_addr", "mcast_miss_encode_key", "mcast_miss_port", "memory_pools", "memory_pools_limit", "memory_replacement_policy", "mime_table", "min_http_poll_cnt", "min_icp_poll_cnt", "minimum_direct_hops", "minimum_object_size", "minimum_retry_timeout", "miss_access", "negative_dns_ttl", "negative_ttl", "neighbor_timeout", "neighbor_type_domain", "netdb_high", "netdb_low", "netdb_ping_period", "netdb_ping_rate", "never_direct", "no_cache", "passthrough_proxy", "pconn_timeout", "pid_filename", "pinger_program", "positive_dns_ttl", "prefer_direct", "proxy_auth", "proxy_auth_realm", "query_icmp", "quick_abort", "quick_abort_max", "quick_abort_min", "quick_abort_pct", "range_offset_limit", "read_timeout", "redirect_children", "redirect_program", "redirect_rewrites_host_header", "reference_age", "refresh_pattern", "reload_into_ims", "request_body_max_size", "request_size", "request_timeout", "shutdown_lifetime", "single_parent_bypass", "siteselect_timeout", "snmp_access", "snmp_incoming_address", "snmp_port", "source_ping", "ssl_proxy", "store_avg_object_size", "store_objects_per_bucket", "strip_query_terms", "swap_level1_dirs", "swap_level2_dirs", "tcp_incoming_address", "tcp_outgoing_address", "tcp_recv_bufsize", "test_reachability", "udp_hit_obj", "udp_hit_obj_size", "udp_incoming_address", "udp_outgoing_address", "unique_hostname", "unlinkd_program", "uri_whitespace", "useragent_log", "visible_hostname", "wais_relay", "wais_relay_host", "wais_relay_port", ) opts = ( "proxy-only", "weight", "ttl", "no-query", "default", "round-robin", "multicast-responder", "on", "off", "all", "deny", "allow", "via", "parent", "no-digest", "heap", "lru", "realm", "children", "q1", "q2", "credentialsttl", "none", "disable", "offline_toggle", "diskd", ) actions = ( "shutdown", "info", "parameter", "server_list", "client_list", r'squid.conf', ) actions_stats = ( "objects", "vm_objects", "utilization", "ipcache", "fqdncache", "dns", "redirector", "io", "reply_headers", "filedescriptors", "netdb", ) actions_log = ("status", "enable", "disable", "clear") acls = ( "url_regex", "urlpath_regex", "referer_regex", "port", "proto", "req_mime_type", "rep_mime_type", "method", "browser", "user", "src", "dst", "time", "dstdomain", "ident", "snmp_community", ) ip_re = ( r'(?:(?:(?:[3-9]\d?|2(?:5[0-5]|[0-4]?\d)?|1\d{0,2}|0x0*[0-9a-f]{1,2}|' r'0+[1-3]?[0-7]{0,2})(?:\.(?:[3-9]\d?|2(?:5[0-5]|[0-4]?\d)?|1\d{0,2}|' r'0x0*[0-9a-f]{1,2}|0+[1-3]?[0-7]{0,2})){3})|(?!.*::.*::)(?:(?!:)|' r':(?=:))(?:[0-9a-f]{0,4}(?:(?<=::)|(?<!::):)){6}(?:[0-9a-f]{0,4}' r'(?:(?<=::)|(?<!::):)[0-9a-f]{0,4}(?:(?<=::)|(?<!:)|(?<=:)(?<!::):)|' r'(?:25[0-4]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-4]|2[0-4]\d|1\d\d|' r'[1-9]?\d)){3}))' ) tokens = { 'root': [ (r'\s+', Whitespace), (r'#', Comment, 'comment'), (words(keywords, prefix=r'\b', suffix=r'\b'), Keyword), (words(opts, prefix=r'\b', suffix=r'\b'), Name.Constant), # Actions (words(actions, prefix=r'\b', suffix=r'\b'), String), (words(actions_stats, prefix=r'stats/', suffix=r'\b'), String), (words(actions_log, prefix=r'log/', suffix=r'='), String), (words(acls, prefix=r'\b', suffix=r'\b'), Keyword), (ip_re + r'(?:/(?:' + ip_re + r'|\b\d+\b))?', Number.Float), (r'(?:\b\d+\b(?:-\b\d+|%)?)', Number), (r'\S+', Text), ], 'comment': [ (r'\s*TAG:.*', String.Escape, '#pop'), (r'.+', Comment, '#pop'), default('#pop'), ], } class NginxConfLexer(RegexLexer): """ Lexer for Nginx configuration files. .. versionadded:: 0.11 """ name = 'Nginx configuration file' url = 'http://nginx.net/' aliases = ['nginx'] filenames = ['nginx.conf'] mimetypes = ['text/x-nginx-conf'] tokens = { 'root': [ (r'(include)(\s+)([^\s;]+)', bygroups(Keyword, Whitespace, Name)), (r'[^\s;#]+', Keyword, 'stmt'), include('base'), ], 'block': [ (r'\}', Punctuation, '#pop:2'), (r'[^\s;#]+', Keyword.Namespace, 'stmt'), include('base'), ], 'stmt': [ (r'\{', Punctuation, 'block'), (r';', Punctuation, '#pop'), include('base'), ], 'base': [ (r'#.*\n', Comment.Single), (r'on|off', Name.Constant), (r'\$[^\s;#()]+', Name.Variable), (r'([a-z0-9.-]+)(:)([0-9]+)', bygroups(Name, Punctuation, Number.Integer)), (r'[a-z-]+/[a-z-+]+', String), # mimetype # (r'[a-zA-Z._-]+', Keyword), (r'[0-9]+[km]?\b', Number.Integer), (r'(~)(\s*)([^\s{]+)', bygroups(Punctuation, Whitespace, String.Regex)), (r'[:=~]', Punctuation), (r'[^\s;#{}$]+', String), # catch all (r'/[^\s;#]*', Name), # pathname (r'\s+', Whitespace), (r'[$;]', Text), # leftover characters ], } class LighttpdConfLexer(RegexLexer): """ Lexer for Lighttpd configuration files. .. versionadded:: 0.11 """ name = 'Lighttpd configuration file' url = 'http://lighttpd.net/' aliases = ['lighttpd', 'lighty'] filenames = ['lighttpd.conf'] mimetypes = ['text/x-lighttpd-conf'] tokens = { 'root': [ (r'#.*\n', Comment.Single), (r'/\S*', Name), # pathname (r'[a-zA-Z._-]+', Keyword), (r'\d+\.\d+\.\d+\.\d+(?:/\d+)?', Number), (r'[0-9]+', Number), (r'=>|=~|\+=|==|=|\+', Operator), (r'\$[A-Z]+', Name.Builtin), (r'[(){}\[\],]', Punctuation), (r'"([^"\\]*(?:\\.[^"\\]*)*)"', String.Double), (r'\s+', Whitespace), ], } class DockerLexer(RegexLexer): """ Lexer for Docker configuration files. .. versionadded:: 2.0 """ name = 'Docker' url = 'http://docker.io' aliases = ['docker', 'dockerfile'] filenames = ['Dockerfile', '*.docker'] mimetypes = ['text/x-dockerfile-config'] _keywords = (r'(?:MAINTAINER|EXPOSE|WORKDIR|USER|STOPSIGNAL)') _bash_keywords = (r'(?:RUN|CMD|ENTRYPOINT|ENV|ARG|LABEL|ADD|COPY)') _lb = r'(?:\s*\\?\s*)' # dockerfile line break regex flags = re.IGNORECASE | re.MULTILINE tokens = { 'root': [ (r'#.*', Comment), (r'(FROM)([ \t]*)(\S*)([ \t]*)(?:(AS)([ \t]*)(\S*))?', bygroups(Keyword, Whitespace, String, Whitespace, Keyword, Whitespace, String)), (r'(ONBUILD)(\s+)(%s)' % (_lb,), bygroups(Keyword, Whitespace, using(BashLexer))), (r'(HEALTHCHECK)(\s+)((%s--\w+=\w+%s)*)' % (_lb, _lb), bygroups(Keyword, Whitespace, using(BashLexer))), (r'(VOLUME|ENTRYPOINT|CMD|SHELL)(\s+)(%s)(\[.*?\])' % (_lb,), bygroups(Keyword, Whitespace, using(BashLexer), using(JsonLexer))), (r'(LABEL|ENV|ARG)(\s+)((%s\w+=\w+%s)*)' % (_lb, _lb), bygroups(Keyword, Whitespace, using(BashLexer))), (r'(%s|VOLUME)\b(\s+)(.*)' % (_keywords), bygroups(Keyword, Whitespace, String)), (r'(%s)(\s+)' % (_bash_keywords,), bygroups(Keyword, Whitespace)), (r'(.*\\\n)*.+', using(BashLexer)), ] } class TerraformLexer(ExtendedRegexLexer): """ Lexer for terraformi ``.tf`` files. .. versionadded:: 2.1 """ name = 'Terraform' url = 'https://www.terraform.io/' aliases = ['terraform', 'tf'] filenames = ['*.tf'] mimetypes = ['application/x-tf', 'application/x-terraform'] classes = ('backend', 'data', 'module', 'output', 'provider', 'provisioner', 'resource', 'variable') classes_re = "({})".format(('|').join(classes)) types = ('string', 'number', 'bool', 'list', 'tuple', 'map', 'set', 'object', 'null') numeric_functions = ('abs', 'ceil', 'floor', 'log', 'max', 'mix', 'parseint', 'pow', 'signum') string_functions = ('chomp', 'format', 'formatlist', 'indent', 'join', 'lower', 'regex', 'regexall', 'replace', 'split', 'strrev', 'substr', 'title', 'trim', 'trimprefix', 'trimsuffix', 'trimspace', 'upper' ) collection_functions = ('alltrue', 'anytrue', 'chunklist', 'coalesce', 'coalescelist', 'compact', 'concat', 'contains', 'distinct', 'element', 'flatten', 'index', 'keys', 'length', 'list', 'lookup', 'map', 'matchkeys', 'merge', 'range', 'reverse', 'setintersection', 'setproduct', 'setsubtract', 'setunion', 'slice', 'sort', 'sum', 'transpose', 'values', 'zipmap' ) encoding_functions = ('base64decode', 'base64encode', 'base64gzip', 'csvdecode', 'jsondecode', 'jsonencode', 'textdecodebase64', 'textencodebase64', 'urlencode', 'yamldecode', 'yamlencode') filesystem_functions = ('abspath', 'dirname', 'pathexpand', 'basename', 'file', 'fileexists', 'fileset', 'filebase64', 'templatefile') date_time_functions = ('formatdate', 'timeadd', 'timestamp') hash_crypto_functions = ('base64sha256', 'base64sha512', 'bcrypt', 'filebase64sha256', 'filebase64sha512', 'filemd5', 'filesha1', 'filesha256', 'filesha512', 'md5', 'rsadecrypt', 'sha1', 'sha256', 'sha512', 'uuid', 'uuidv5') ip_network_functions = ('cidrhost', 'cidrnetmask', 'cidrsubnet', 'cidrsubnets') type_conversion_functions = ('can', 'defaults', 'tobool', 'tolist', 'tomap', 'tonumber', 'toset', 'tostring', 'try') builtins = numeric_functions + string_functions + collection_functions + encoding_functions +\ filesystem_functions + date_time_functions + hash_crypto_functions + ip_network_functions +\ type_conversion_functions builtins_re = "({})".format(('|').join(builtins)) def heredoc_callback(self, match, ctx): # Parse a terraform heredoc # match: 1 = <<[-]?, 2 = name 3 = rest of line start = match.start(1) yield start, Operator, match.group(1) # <<[-]? yield match.start(2), String.Delimiter, match.group(2) # heredoc name ctx.pos = match.start(3) ctx.end = match.end(3) yield ctx.pos, String.Heredoc, match.group(3) ctx.pos = match.end() hdname = match.group(2) tolerant = True # leading whitespace is always accepted lines = [] for match in line_re.finditer(ctx.text, ctx.pos): if tolerant: check = match.group().strip() else: check = match.group().rstrip() if check == hdname: for amatch in lines: yield amatch.start(), String.Heredoc, amatch.group() yield match.start(), String.Delimiter, match.group() ctx.pos = match.end() break else: lines.append(match) else: # end of heredoc not found -- error! for amatch in lines: yield amatch.start(), Error, amatch.group() ctx.end = len(ctx.text) tokens = { 'root': [ include('basic'), include('whitespace'), # Strings (r'(".*")', bygroups(String.Double)), # Constants (words(('true', 'false'), prefix=r'\b', suffix=r'\b'), Name.Constant), # Types (words(types, prefix=r'\b', suffix=r'\b'), Keyword.Type), include('identifier'), include('punctuation'), (r'[0-9]+', Number), ], 'basic': [ (r'\s*/\*', Comment.Multiline, 'comment'), (r'\s*(#|//).*\n', Comment.Single), include('whitespace'), # e.g. terraform { # e.g. egress { (r'(\s*)([0-9a-zA-Z-_]+)(\s*)(=?)(\s*)(\{)', bygroups(Whitespace, Name.Builtin, Whitespace, Operator, Whitespace, Punctuation)), # Assignment with attributes, e.g. something = ... (r'(\s*)([0-9a-zA-Z-_]+)(\s*)(=)(\s*)', bygroups(Whitespace, Name.Attribute, Whitespace, Operator, Whitespace)), # Assignment with environment variables and similar, e.g. "something" = ... # or key value assignment, e.g. "SlotName" : ... (r'(\s*)("\S+")(\s*)([=:])(\s*)', bygroups(Whitespace, Literal.String.Double, Whitespace, Operator, Whitespace)), # Functions, e.g. jsonencode(element("value")) (builtins_re + r'(\()', bygroups(Name.Function, Punctuation)), # List of attributes, e.g. ignore_changes = [last_modified, filename] (r'(\[)([a-z_,\s]+)(\])', bygroups(Punctuation, Name.Builtin, Punctuation)), # e.g. resource "aws_security_group" "allow_tls" { # e.g. backend "consul" { (classes_re + r'(\s+)("[0-9a-zA-Z-_]+")?(\s*)("[0-9a-zA-Z-_]+")(\s+)(\{)', bygroups(Keyword.Reserved, Whitespace, Name.Class, Whitespace, Name.Variable, Whitespace, Punctuation)), # here-doc style delimited strings (r'(<<-?)\s*([a-zA-Z_]\w*)(.*?\n)', heredoc_callback), ], 'identifier': [ (r'\b(var\.[0-9a-zA-Z-_\.\[\]]+)\b', bygroups(Name.Variable)), (r'\b([0-9a-zA-Z-_\[\]]+\.[0-9a-zA-Z-_\.\[\]]+)\b', bygroups(Name.Variable)), ], 'punctuation': [ (r'[\[\]()\{\},.?:!=]', Punctuation), ], 'comment': [ (r'[^*/]', Comment.Multiline), (r'/\*', Comment.Multiline, '#push'), (r'\*/', Comment.Multiline, '#pop'), (r'[*/]', Comment.Multiline) ], 'whitespace': [ (r'\n', Whitespace), (r'\s+', Whitespace), (r'(\\)(\n)', bygroups(Text, Whitespace)), ], } class TermcapLexer(RegexLexer): """ Lexer for termcap database source. This is very simple and minimal. .. versionadded:: 2.1 """ name = 'Termcap' aliases = ['termcap'] filenames = ['termcap', 'termcap.src'] mimetypes = [] # NOTE: # * multiline with trailing backslash # * separator is ':' # * to embed colon as data, we must use \072 # * space after separator is not allowed (mayve) tokens = { 'root': [ (r'^#.*', Comment), (r'^[^\s#:|]+', Name.Tag, 'names'), (r'\s+', Whitespace), ], 'names': [ (r'\n', Whitespace, '#pop'), (r':', Punctuation, 'defs'), (r'\|', Punctuation), (r'[^:|]+', Name.Attribute), ], 'defs': [ (r'(\\)(\n[ \t]*)', bygroups(Text, Whitespace)), (r'\n[ \t]*', Whitespace, '#pop:2'), (r'(#)([0-9]+)', bygroups(Operator, Number)), (r'=', Operator, 'data'), (r':', Punctuation), (r'[^\s:=#]+', Name.Class), ], 'data': [ (r'\\072', Literal), (r':', Punctuation, '#pop'), (r'[^:\\]+', Literal), # for performance (r'.', Literal), ], } class TerminfoLexer(RegexLexer): """ Lexer for terminfo database source. This is very simple and minimal. .. versionadded:: 2.1 """ name = 'Terminfo' aliases = ['terminfo'] filenames = ['terminfo', 'terminfo.src'] mimetypes = [] # NOTE: # * multiline with leading whitespace # * separator is ',' # * to embed comma as data, we can use \, # * space after separator is allowed tokens = { 'root': [ (r'^#.*$', Comment), (r'^[^\s#,|]+', Name.Tag, 'names'), (r'\s+', Whitespace), ], 'names': [ (r'\n', Whitespace, '#pop'), (r'(,)([ \t]*)', bygroups(Punctuation, Whitespace), 'defs'), (r'\|', Punctuation), (r'[^,|]+', Name.Attribute), ], 'defs': [ (r'\n[ \t]+', Whitespace), (r'\n', Whitespace, '#pop:2'), (r'(#)([0-9]+)', bygroups(Operator, Number)), (r'=', Operator, 'data'), (r'(,)([ \t]*)', bygroups(Punctuation, Whitespace)), (r'[^\s,=#]+', Name.Class), ], 'data': [ (r'\\[,\\]', Literal), (r'(,)([ \t]*)', bygroups(Punctuation, Whitespace), '#pop'), (r'[^\\,]+', Literal), # for performance (r'.', Literal), ], } class PkgConfigLexer(RegexLexer): """ Lexer for pkg-config (see also `manual page <http://linux.die.net/man/1/pkg-config>`_). .. versionadded:: 2.1 """ name = 'PkgConfig' url = 'http://www.freedesktop.org/wiki/Software/pkg-config/' aliases = ['pkgconfig'] filenames = ['*.pc'] mimetypes = [] tokens = { 'root': [ (r'#.*$', Comment.Single), # variable definitions (r'^(\w+)(=)', bygroups(Name.Attribute, Operator)), # keyword lines (r'^([\w.]+)(:)', bygroups(Name.Tag, Punctuation), 'spvalue'), # variable references include('interp'), # fallback (r'\s+', Whitespace), (r'[^${}#=:\n.]+', Text), (r'.', Text), ], 'interp': [ # you can escape literal "$" as "$$" (r'\$\$', Text), # variable references (r'\$\{', String.Interpol, 'curly'), ], 'curly': [ (r'\}', String.Interpol, '#pop'), (r'\w+', Name.Attribute), ], 'spvalue': [ include('interp'), (r'#.*$', Comment.Single, '#pop'), (r'\n', Whitespace, '#pop'), # fallback (r'\s+', Whitespace), (r'[^${}#\n\s]+', Text), (r'.', Text), ], } class PacmanConfLexer(RegexLexer): """ Lexer for pacman.conf. Actually, IniLexer works almost fine for this format, but it yield error token. It is because pacman.conf has a form without assignment like: UseSyslog Color TotalDownload CheckSpace VerbosePkgLists These are flags to switch on. .. versionadded:: 2.1 """ name = 'PacmanConf' url = 'https://www.archlinux.org/pacman/pacman.conf.5.html' aliases = ['pacmanconf'] filenames = ['pacman.conf'] mimetypes = [] tokens = { 'root': [ # comment (r'#.*$', Comment.Single), # section header (r'^(\s*)(\[.*?\])(\s*)$', bygroups(Whitespace, Keyword, Whitespace)), # variable definitions # (Leading space is allowed...) (r'(\w+)(\s*)(=)', bygroups(Name.Attribute, Whitespace, Operator)), # flags to on (r'^(\s*)(\w+)(\s*)$', bygroups(Whitespace, Name.Attribute, Whitespace)), # built-in special values (words(( '$repo', # repository '$arch', # architecture '%o', # outfile '%u', # url ), suffix=r'\b'), Name.Variable), # fallback (r'\s+', Whitespace), (r'.', Text), ], } class AugeasLexer(RegexLexer): """ Lexer for Augeas. .. versionadded:: 2.4 """ name = 'Augeas' url = 'http://augeas.net' aliases = ['augeas'] filenames = ['*.aug'] tokens = { 'root': [ (r'(module)(\s*)([^\s=]+)', bygroups(Keyword.Namespace, Whitespace, Name.Namespace)), (r'(let)(\s*)([^\s=]+)', bygroups(Keyword.Declaration, Whitespace, Name.Variable)), (r'(del|store|value|counter|seq|key|label|autoload|incl|excl|transform|test|get|put)(\s+)', bygroups(Name.Builtin, Whitespace)), (r'(\()([^:]+)(\:)(unit|string|regexp|lens|tree|filter)(\))', bygroups(Punctuation, Name.Variable, Punctuation, Keyword.Type, Punctuation)), (r'\(\*', Comment.Multiline, 'comment'), (r'[*+\-.;=?|]', Operator), (r'[()\[\]{}]', Operator), (r'"', String.Double, 'string'), (r'\/', String.Regex, 'regex'), (r'([A-Z]\w*)(\.)(\w+)', bygroups(Name.Namespace, Punctuation, Name.Variable)), (r'.', Name.Variable), (r'\s+', Whitespace), ], 'string': [ (r'\\.', String.Escape), (r'[^"]', String.Double), (r'"', String.Double, '#pop'), ], 'regex': [ (r'\\.', String.Escape), (r'[^/]', String.Regex), (r'\/', String.Regex, '#pop'), ], 'comment': [ (r'[^*)]', Comment.Multiline), (r'\(\*', Comment.Multiline, '#push'), (r'\*\)', Comment.Multiline, '#pop'), (r'[)*]', Comment.Multiline) ], } class TOMLLexer(RegexLexer): """ Lexer for TOML, a simple language for config files. .. versionadded:: 2.4 """ name = 'TOML' url = 'https://github.com/toml-lang/toml' aliases = ['toml'] filenames = ['*.toml', 'Pipfile', 'poetry.lock'] tokens = { 'root': [ # Table (r'^(\s*)(\[.*?\])$', bygroups(Whitespace, Keyword)), # Basics, comments, strings (r'[ \t]+', Whitespace), (r'\n', Whitespace), (r'#.*?$', Comment.Single), # Basic string (r'"(\\\\|\\[^\\]|[^"\\])*"', String), # Literal string (r'\'\'\'(.*)\'\'\'', String), (r'\'[^\']*\'', String), (r'(true|false)$', Keyword.Constant), (r'[a-zA-Z_][\w\-]*', Name), # Datetime # TODO this needs to be expanded, as TOML is rather flexible: # https://github.com/toml-lang/toml#offset-date-time (r'\d{4}-\d{2}-\d{2}(?:T| )\d{2}:\d{2}:\d{2}(?:Z|[-+]\d{2}:\d{2})', Number.Integer), # Numbers (r'(\d+\.\d*|\d*\.\d+)([eE][+-]?[0-9]+)?j?', Number.Float), (r'\d+[eE][+-]?[0-9]+j?', Number.Float), # Handle +-inf, +-infinity, +-nan (r'[+-]?(?:(inf(?:inity)?)|nan)', Number.Float), (r'[+-]?\d+', Number.Integer), # Punctuation (r'[]{}:(),;[]', Punctuation), (r'\.', Punctuation), # Operators (r'=', Operator) ] } class NestedTextLexer(RegexLexer): """ Lexer for NextedText, a human-friendly data format. .. versionadded:: 2.9 """ name = 'NestedText' url = 'https://nestedtext.org' aliases = ['nestedtext', 'nt'] filenames = ['*.nt'] _quoted_dict_item = r'^(\s*)({0})(.*?)({0}: ?)(.*?)(\s*)$' tokens = { 'root': [ (r'^(\s*)(#.*?)$', bygroups(Whitespace, Comment)), (r'^(\s*)(>)( ?)(.*?)(\s*)$', bygroups(Whitespace, Punctuation, Whitespace, String, Whitespace)), (r'^(\s*)(-)( ?)(.*?)(\s*)$', bygroups(Whitespace, Punctuation, Whitespace, String, Whitespace)), (_quoted_dict_item.format("'"), bygroups(Whitespace, Punctuation, Name, Punctuation, String, Whitespace)), (_quoted_dict_item.format('"'), bygroups(Whitespace, Punctuation, Name, Punctuation, String, Whitespace)), (r'^(\s*)(.*?)(:)( ?)(.*?)(\s*)$', bygroups(Whitespace, Name, Punctuation, Whitespace, String, Whitespace)), ], } class SingularityLexer(RegexLexer): """ Lexer for Singularity definition files. .. versionadded:: 2.6 """ name = 'Singularity' url = 'https://www.sylabs.io/guides/3.0/user-guide/definition_files.html' aliases = ['singularity'] filenames = ['*.def', 'Singularity'] flags = re.IGNORECASE | re.MULTILINE | re.DOTALL _headers = r'^(\s*)(bootstrap|from|osversion|mirrorurl|include|registry|namespace|includecmd)(:)' _section = r'^(%(?:pre|post|setup|environment|help|labels|test|runscript|files|startscript))(\s*)' _appsect = r'^(%app(?:install|help|run|labels|env|test|files))(\s*)' tokens = { 'root': [ (_section, bygroups(Generic.Heading, Whitespace), 'script'), (_appsect, bygroups(Generic.Heading, Whitespace), 'script'), (_headers, bygroups(Whitespace, Keyword, Text)), (r'\s*#.*?\n', Comment), (r'\b(([0-9]+\.?[0-9]*)|(\.[0-9]+))\b', Number), (r'[ \t]+', Whitespace), (r'(?!^\s*%).', Text), ], 'script': [ (r'(.+?(?=^\s*%))|(.*)', using(BashLexer), '#pop'), ], } def analyse_text(text): """This is a quite simple script file, but there are a few keywords which seem unique to this language.""" result = 0 if re.search(r'\b(?:osversion|includecmd|mirrorurl)\b', text, re.IGNORECASE): result += 0.5 if re.search(SingularityLexer._section[1:], text): result += 0.49 return result class UnixConfigLexer(RegexLexer): """ Lexer for Unix/Linux config files using colon-separated values, e.g. * ``/etc/group`` * ``/etc/passwd`` * ``/etc/shadow`` .. versionadded:: 2.12 """ name = 'Unix/Linux config files' aliases = ['unixconfig', 'linuxconfig'] filenames = [] tokens = { 'root': [ (r'^#.*', Comment), (r'\n', Whitespace), (r':', Punctuation), (r'[0-9]+', Number), (r'((?!\n)[a-zA-Z0-9\_\-\s\(\),]){2,}', Text), (r'[^:\n]+', String), ], }
41,823
Python
34.594894
152
0.485331
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/_asy_builtins.py
""" pygments.lexers._asy_builtins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ This file contains the asy-function names and asy-variable names of Asymptote. Do not edit the ASYFUNCNAME and ASYVARNAME sets by hand. TODO: perl/python script in Asymptote SVN similar to asy-list.pl but only for function and variable names. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ ASYFUNCNAME = { 'AND', 'Arc', 'ArcArrow', 'ArcArrows', 'Arrow', 'Arrows', 'Automatic', 'AvantGarde', 'BBox', 'BWRainbow', 'BWRainbow2', 'Bar', 'Bars', 'BeginArcArrow', 'BeginArrow', 'BeginBar', 'BeginDotMargin', 'BeginMargin', 'BeginPenMargin', 'Blank', 'Bookman', 'Bottom', 'BottomTop', 'Bounds', 'Break', 'Broken', 'BrokenLog', 'Ceil', 'Circle', 'CircleBarIntervalMarker', 'Cos', 'Courier', 'CrossIntervalMarker', 'DefaultFormat', 'DefaultLogFormat', 'Degrees', 'Dir', 'DotMargin', 'DotMargins', 'Dotted', 'Draw', 'Drawline', 'Embed', 'EndArcArrow', 'EndArrow', 'EndBar', 'EndDotMargin', 'EndMargin', 'EndPenMargin', 'Fill', 'FillDraw', 'Floor', 'Format', 'Full', 'Gaussian', 'Gaussrand', 'Gaussrandpair', 'Gradient', 'Grayscale', 'Helvetica', 'Hermite', 'HookHead', 'InOutTicks', 'InTicks', 'J', 'Label', 'Landscape', 'Left', 'LeftRight', 'LeftTicks', 'Legend', 'Linear', 'Link', 'Log', 'LogFormat', 'Margin', 'Margins', 'Mark', 'MidArcArrow', 'MidArrow', 'NOT', 'NewCenturySchoolBook', 'NoBox', 'NoMargin', 'NoModifier', 'NoTicks', 'NoTicks3', 'NoZero', 'NoZeroFormat', 'None', 'OR', 'OmitFormat', 'OmitTick', 'OutTicks', 'Ox', 'Oy', 'Palatino', 'PaletteTicks', 'Pen', 'PenMargin', 'PenMargins', 'Pentype', 'Portrait', 'RadialShade', 'Rainbow', 'Range', 'Relative', 'Right', 'RightTicks', 'Rotate', 'Round', 'SQR', 'Scale', 'ScaleX', 'ScaleY', 'ScaleZ', 'Seascape', 'Shift', 'Sin', 'Slant', 'Spline', 'StickIntervalMarker', 'Straight', 'Symbol', 'Tan', 'TeXify', 'Ticks', 'Ticks3', 'TildeIntervalMarker', 'TimesRoman', 'Top', 'TrueMargin', 'UnFill', 'UpsideDown', 'Wheel', 'X', 'XEquals', 'XOR', 'XY', 'XYEquals', 'XYZero', 'XYgrid', 'XZEquals', 'XZZero', 'XZero', 'XZgrid', 'Y', 'YEquals', 'YXgrid', 'YZ', 'YZEquals', 'YZZero', 'YZero', 'YZgrid', 'Z', 'ZX', 'ZXgrid', 'ZYgrid', 'ZapfChancery', 'ZapfDingbats', '_cputime', '_draw', '_eval', '_image', '_labelpath', '_projection', '_strokepath', '_texpath', 'aCos', 'aSin', 'aTan', 'abort', 'abs', 'accel', 'acos', 'acosh', 'acot', 'acsc', 'add', 'addArrow', 'addMargins', 'addSaveFunction', 'addnode', 'addnodes', 'addpenarc', 'addpenline', 'addseg', 'adjust', 'alias', 'align', 'all', 'altitude', 'angabscissa', 'angle', 'angpoint', 'animate', 'annotate', 'anticomplementary', 'antipedal', 'apply', 'approximate', 'arc', 'arcarrowsize', 'arccircle', 'arcdir', 'arcfromcenter', 'arcfromfocus', 'arclength', 'arcnodesnumber', 'arcpoint', 'arcsubtended', 'arcsubtendedcenter', 'arctime', 'arctopath', 'array', 'arrow', 'arrow2', 'arrowbase', 'arrowbasepoints', 'arrowsize', 'asec', 'asin', 'asinh', 'ask', 'assert', 'asy', 'asycode', 'asydir', 'asyfigure', 'asyfilecode', 'asyinclude', 'asywrite', 'atan', 'atan2', 'atanh', 'atbreakpoint', 'atexit', 'atime', 'attach', 'attract', 'atupdate', 'autoformat', 'autoscale', 'autoscale3', 'axes', 'axes3', 'axialshade', 'axis', 'axiscoverage', 'azimuth', 'babel', 'background', 'bangles', 'bar', 'barmarksize', 'barsize', 'basealign', 'baseline', 'bbox', 'beep', 'begin', 'beginclip', 'begingroup', 'beginpoint', 'between', 'bevel', 'bezier', 'bezierP', 'bezierPP', 'bezierPPP', 'bezulate', 'bibliography', 'bibliographystyle', 'binarytree', 'binarytreeNode', 'binomial', 'binput', 'bins', 'bisector', 'bisectorpoint', 'blend', 'boutput', 'box', 'bqe', 'breakpoint', 'breakpoints', 'brick', 'buildRestoreDefaults', 'buildRestoreThunk', 'buildcycle', 'bulletcolor', 'canonical', 'canonicalcartesiansystem', 'cartesiansystem', 'case1', 'case2', 'case3', 'cbrt', 'cd', 'ceil', 'center', 'centerToFocus', 'centroid', 'cevian', 'change2', 'changecoordsys', 'checkSegment', 'checkconditionlength', 'checker', 'checklengths', 'checkposition', 'checktriangle', 'choose', 'circle', 'circlebarframe', 'circlemarkradius', 'circlenodesnumber', 'circumcenter', 'circumcircle', 'clamped', 'clear', 'clip', 'clipdraw', 'close', 'cmyk', 'code', 'colatitude', 'collect', 'collinear', 'color', 'colorless', 'colors', 'colorspace', 'comma', 'compassmark', 'complement', 'complementary', 'concat', 'concurrent', 'cone', 'conic', 'conicnodesnumber', 'conictype', 'conj', 'connect', 'containmentTree', 'contains', 'contour', 'contour3', 'controlSpecifier', 'convert', 'coordinates', 'coordsys', 'copy', 'cos', 'cosh', 'cot', 'countIntersections', 'cputime', 'crop', 'cropcode', 'cross', 'crossframe', 'crosshatch', 'crossmarksize', 'csc', 'cubicroots', 'curabscissa', 'curlSpecifier', 'curpoint', 'currentarrow', 'currentexitfunction', 'currentmomarrow', 'currentpolarconicroutine', 'curve', 'cut', 'cutafter', 'cutbefore', 'cyclic', 'cylinder', 'debugger', 'deconstruct', 'defaultdir', 'defaultformat', 'defaultpen', 'defined', 'degenerate', 'degrees', 'delete', 'deletepreamble', 'determinant', 'diagonal', 'diamond', 'diffdiv', 'dir', 'dirSpecifier', 'dirtime', 'display', 'distance', 'divisors', 'do_overpaint', 'dot', 'dotframe', 'dotsize', 'downcase', 'draw', 'drawAll', 'drawDoubleLine', 'drawFermion', 'drawGhost', 'drawGluon', 'drawMomArrow', 'drawPhoton', 'drawScalar', 'drawVertex', 'drawVertexBox', 'drawVertexBoxO', 'drawVertexBoxX', 'drawVertexO', 'drawVertexOX', 'drawVertexTriangle', 'drawVertexTriangleO', 'drawVertexX', 'drawarrow', 'drawarrow2', 'drawline', 'drawtick', 'duplicate', 'elle', 'ellipse', 'ellipsenodesnumber', 'embed', 'embed3', 'empty', 'enclose', 'end', 'endScript', 'endclip', 'endgroup', 'endl', 'endpoint', 'endpoints', 'eof', 'eol', 'equation', 'equations', 'erase', 'erasestep', 'erf', 'erfc', 'error', 'errorbar', 'errorbars', 'eval', 'excenter', 'excircle', 'exit', 'exitXasyMode', 'exitfunction', 'exp', 'expfactors', 'expi', 'expm1', 'exradius', 'extend', 'extension', 'extouch', 'fabs', 'factorial', 'fermat', 'fft', 'fhorner', 'figure', 'file', 'filecode', 'fill', 'filldraw', 'filloutside', 'fillrule', 'filltype', 'find', 'finite', 'finiteDifferenceJacobian', 'firstcut', 'firstframe', 'fit', 'fit2', 'fixedscaling', 'floor', 'flush', 'fmdefaults', 'fmod', 'focusToCenter', 'font', 'fontcommand', 'fontsize', 'foot', 'format', 'frac', 'frequency', 'fromCenter', 'fromFocus', 'fspline', 'functionshade', 'gamma', 'generate_random_backtrace', 'generateticks', 'gergonne', 'getc', 'getint', 'getpair', 'getreal', 'getstring', 'gettriple', 'gluon', 'gouraudshade', 'graph', 'graphic', 'gray', 'grestore', 'grid', 'grid3', 'gsave', 'halfbox', 'hatch', 'hdiffdiv', 'hermite', 'hex', 'histogram', 'history', 'hline', 'hprojection', 'hsv', 'hyperbola', 'hyperbolanodesnumber', 'hyperlink', 'hypot', 'identity', 'image', 'incenter', 'incentral', 'incircle', 'increasing', 'incrementposition', 'indexedTransform', 'indexedfigure', 'initXasyMode', 'initdefaults', 'input', 'inradius', 'insert', 'inside', 'integrate', 'interactive', 'interior', 'interp', 'interpolate', 'intersect', 'intersection', 'intersectionpoint', 'intersectionpoints', 'intersections', 'intouch', 'inverse', 'inversion', 'invisible', 'is3D', 'isDuplicate', 'isogonal', 'isogonalconjugate', 'isotomic', 'isotomicconjugate', 'isparabola', 'italic', 'item', 'key', 'kurtosis', 'kurtosisexcess', 'label', 'labelaxis', 'labelmargin', 'labelpath', 'labels', 'labeltick', 'labelx', 'labelx3', 'labely', 'labely3', 'labelz', 'labelz3', 'lastcut', 'latex', 'latitude', 'latticeshade', 'layer', 'layout', 'ldexp', 'leastsquares', 'legend', 'legenditem', 'length', 'lift', 'light', 'limits', 'line', 'linear', 'linecap', 'lineinversion', 'linejoin', 'linemargin', 'lineskip', 'linetype', 'linewidth', 'link', 'list', 'lm_enorm', 'lm_evaluate_default', 'lm_lmdif', 'lm_lmpar', 'lm_minimize', 'lm_print_default', 'lm_print_quiet', 'lm_qrfac', 'lm_qrsolv', 'locale', 'locate', 'locatefile', 'location', 'log', 'log10', 'log1p', 'logaxiscoverage', 'longitude', 'lookup', 'magnetize', 'makeNode', 'makedraw', 'makepen', 'map', 'margin', 'markangle', 'markangleradius', 'markanglespace', 'markarc', 'marker', 'markinterval', 'marknodes', 'markrightangle', 'markuniform', 'mass', 'masscenter', 'massformat', 'math', 'max', 'max3', 'maxbezier', 'maxbound', 'maxcoords', 'maxlength', 'maxratio', 'maxtimes', 'mean', 'medial', 'median', 'midpoint', 'min', 'min3', 'minbezier', 'minbound', 'minipage', 'minratio', 'mintimes', 'miterlimit', 'momArrowPath', 'momarrowsize', 'monotonic', 'multifigure', 'nativeformat', 'natural', 'needshipout', 'newl', 'newpage', 'newslide', 'newton', 'newtree', 'nextframe', 'nextnormal', 'nextpage', 'nib', 'nodabscissa', 'none', 'norm', 'normalvideo', 'notaknot', 'nowarn', 'numberpage', 'nurb', 'object', 'offset', 'onpath', 'opacity', 'opposite', 'orientation', 'orig_circlenodesnumber', 'orig_circlenodesnumber1', 'orig_draw', 'orig_ellipsenodesnumber', 'orig_ellipsenodesnumber1', 'orig_hyperbolanodesnumber', 'orig_parabolanodesnumber', 'origin', 'orthic', 'orthocentercenter', 'outformat', 'outline', 'outprefix', 'output', 'overloadedMessage', 'overwrite', 'pack', 'pad', 'pairs', 'palette', 'parabola', 'parabolanodesnumber', 'parallel', 'partialsum', 'path', 'path3', 'pattern', 'pause', 'pdf', 'pedal', 'periodic', 'perp', 'perpendicular', 'perpendicularmark', 'phantom', 'phi1', 'phi2', 'phi3', 'photon', 'piecewisestraight', 'point', 'polar', 'polarconicroutine', 'polargraph', 'polygon', 'postcontrol', 'postscript', 'pow10', 'ppoint', 'prc', 'prc0', 'precision', 'precontrol', 'prepend', 'print_random_addresses', 'project', 'projection', 'purge', 'pwhermite', 'quadrant', 'quadraticroots', 'quantize', 'quarticroots', 'quotient', 'radialshade', 'radians', 'radicalcenter', 'radicalline', 'radius', 'rand', 'randompath', 'rd', 'readline', 'realmult', 'realquarticroots', 'rectangle', 'rectangular', 'rectify', 'reflect', 'relabscissa', 'relative', 'relativedistance', 'reldir', 'relpoint', 'reltime', 'remainder', 'remark', 'removeDuplicates', 'rename', 'replace', 'report', 'resetdefaultpen', 'restore', 'restoredefaults', 'reverse', 'reversevideo', 'rf', 'rfind', 'rgb', 'rgba', 'rgbint', 'rms', 'rotate', 'rotateO', 'rotation', 'round', 'roundbox', 'roundedpath', 'roundrectangle', 'samecoordsys', 'sameside', 'sample', 'save', 'savedefaults', 'saveline', 'scale', 'scale3', 'scaleO', 'scaleT', 'scaleless', 'scientific', 'search', 'searchtree', 'sec', 'secondaryX', 'secondaryY', 'seconds', 'section', 'sector', 'seek', 'seekeof', 'segment', 'sequence', 'setpens', 'sgn', 'sgnd', 'sharpangle', 'sharpdegrees', 'shift', 'shiftless', 'shipout', 'shipout3', 'show', 'side', 'simeq', 'simpson', 'sin', 'single', 'sinh', 'size', 'size3', 'skewness', 'skip', 'slant', 'sleep', 'slope', 'slopefield', 'solve', 'solveBVP', 'sort', 'sourceline', 'sphere', 'split', 'sqrt', 'square', 'srand', 'standardizecoordsys', 'startScript', 'startTrembling', 'stdev', 'step', 'stickframe', 'stickmarksize', 'stickmarkspace', 'stop', 'straight', 'straightness', 'string', 'stripdirectory', 'stripextension', 'stripfile', 'strokepath', 'subdivide', 'subitem', 'subpath', 'substr', 'sum', 'surface', 'symmedial', 'symmedian', 'system', 'tab', 'tableau', 'tan', 'tangent', 'tangential', 'tangents', 'tanh', 'tell', 'tensionSpecifier', 'tensorshade', 'tex', 'texcolor', 'texify', 'texpath', 'texpreamble', 'texreset', 'texshipout', 'texsize', 'textpath', 'thick', 'thin', 'tick', 'tickMax', 'tickMax3', 'tickMin', 'tickMin3', 'ticklabelshift', 'ticklocate', 'tildeframe', 'tildemarksize', 'tile', 'tiling', 'time', 'times', 'title', 'titlepage', 'topbox', 'transform', 'transformation', 'transpose', 'tremble', 'trembleFuzz', 'tremble_circlenodesnumber', 'tremble_circlenodesnumber1', 'tremble_draw', 'tremble_ellipsenodesnumber', 'tremble_ellipsenodesnumber1', 'tremble_hyperbolanodesnumber', 'tremble_marknodes', 'tremble_markuniform', 'tremble_parabolanodesnumber', 'triangle', 'triangleAbc', 'triangleabc', 'triangulate', 'tricoef', 'tridiagonal', 'trilinear', 'trim', 'trueMagnetize', 'truepoint', 'tube', 'uncycle', 'unfill', 'uniform', 'unit', 'unitrand', 'unitsize', 'unityroot', 'unstraighten', 'upcase', 'updatefunction', 'uperiodic', 'upscale', 'uptodate', 'usepackage', 'usersetting', 'usetypescript', 'usleep', 'value', 'variance', 'variancebiased', 'vbox', 'vector', 'vectorfield', 'verbatim', 'view', 'vline', 'vperiodic', 'vprojection', 'warn', 'warning', 'windingnumber', 'write', 'xaxis', 'xaxis3', 'xaxis3At', 'xaxisAt', 'xequals', 'xinput', 'xlimits', 'xoutput', 'xpart', 'xscale', 'xscaleO', 'xtick', 'xtick3', 'xtrans', 'yaxis', 'yaxis3', 'yaxis3At', 'yaxisAt', 'yequals', 'ylimits', 'ypart', 'yscale', 'yscaleO', 'ytick', 'ytick3', 'ytrans', 'zaxis3', 'zaxis3At', 'zero', 'zero3', 'zlimits', 'zpart', 'ztick', 'ztick3', 'ztrans' } ASYVARNAME = { 'AliceBlue', 'Align', 'Allow', 'AntiqueWhite', 'Apricot', 'Aqua', 'Aquamarine', 'Aspect', 'Azure', 'BeginPoint', 'Beige', 'Bisque', 'Bittersweet', 'Black', 'BlanchedAlmond', 'Blue', 'BlueGreen', 'BlueViolet', 'Both', 'Break', 'BrickRed', 'Brown', 'BurlyWood', 'BurntOrange', 'CCW', 'CW', 'CadetBlue', 'CarnationPink', 'Center', 'Centered', 'Cerulean', 'Chartreuse', 'Chocolate', 'Coeff', 'Coral', 'CornflowerBlue', 'Cornsilk', 'Crimson', 'Crop', 'Cyan', 'Dandelion', 'DarkBlue', 'DarkCyan', 'DarkGoldenrod', 'DarkGray', 'DarkGreen', 'DarkKhaki', 'DarkMagenta', 'DarkOliveGreen', 'DarkOrange', 'DarkOrchid', 'DarkRed', 'DarkSalmon', 'DarkSeaGreen', 'DarkSlateBlue', 'DarkSlateGray', 'DarkTurquoise', 'DarkViolet', 'DeepPink', 'DeepSkyBlue', 'DefaultHead', 'DimGray', 'DodgerBlue', 'Dotted', 'Draw', 'E', 'ENE', 'EPS', 'ESE', 'E_Euler', 'E_PC', 'E_RK2', 'E_RK3BS', 'Emerald', 'EndPoint', 'Euler', 'Fill', 'FillDraw', 'FireBrick', 'FloralWhite', 'ForestGreen', 'Fuchsia', 'Gainsboro', 'GhostWhite', 'Gold', 'Goldenrod', 'Gray', 'Green', 'GreenYellow', 'Honeydew', 'HookHead', 'Horizontal', 'HotPink', 'I', 'IgnoreAspect', 'IndianRed', 'Indigo', 'Ivory', 'JOIN_IN', 'JOIN_OUT', 'JungleGreen', 'Khaki', 'LM_DWARF', 'LM_MACHEP', 'LM_SQRT_DWARF', 'LM_SQRT_GIANT', 'LM_USERTOL', 'Label', 'Lavender', 'LavenderBlush', 'LawnGreen', 'LeftJustified', 'LeftSide', 'LemonChiffon', 'LightBlue', 'LightCoral', 'LightCyan', 'LightGoldenrodYellow', 'LightGreen', 'LightGrey', 'LightPink', 'LightSalmon', 'LightSeaGreen', 'LightSkyBlue', 'LightSlateGray', 'LightSteelBlue', 'LightYellow', 'Lime', 'LimeGreen', 'Linear', 'Linen', 'Log', 'Logarithmic', 'Magenta', 'Mahogany', 'Mark', 'MarkFill', 'Maroon', 'Max', 'MediumAquamarine', 'MediumBlue', 'MediumOrchid', 'MediumPurple', 'MediumSeaGreen', 'MediumSlateBlue', 'MediumSpringGreen', 'MediumTurquoise', 'MediumVioletRed', 'Melon', 'MidPoint', 'MidnightBlue', 'Min', 'MintCream', 'MistyRose', 'Moccasin', 'Move', 'MoveQuiet', 'Mulberry', 'N', 'NE', 'NNE', 'NNW', 'NW', 'NavajoWhite', 'Navy', 'NavyBlue', 'NoAlign', 'NoCrop', 'NoFill', 'NoSide', 'OldLace', 'Olive', 'OliveDrab', 'OliveGreen', 'Orange', 'OrangeRed', 'Orchid', 'Ox', 'Oy', 'PC', 'PaleGoldenrod', 'PaleGreen', 'PaleTurquoise', 'PaleVioletRed', 'PapayaWhip', 'Peach', 'PeachPuff', 'Periwinkle', 'Peru', 'PineGreen', 'Pink', 'Plum', 'PowderBlue', 'ProcessBlue', 'Purple', 'RK2', 'RK3', 'RK3BS', 'RK4', 'RK5', 'RK5DP', 'RK5F', 'RawSienna', 'Red', 'RedOrange', 'RedViolet', 'Rhodamine', 'RightJustified', 'RightSide', 'RosyBrown', 'RoyalBlue', 'RoyalPurple', 'RubineRed', 'S', 'SE', 'SSE', 'SSW', 'SW', 'SaddleBrown', 'Salmon', 'SandyBrown', 'SeaGreen', 'Seashell', 'Sepia', 'Sienna', 'Silver', 'SimpleHead', 'SkyBlue', 'SlateBlue', 'SlateGray', 'Snow', 'SpringGreen', 'SteelBlue', 'Suppress', 'SuppressQuiet', 'Tan', 'TeXHead', 'Teal', 'TealBlue', 'Thistle', 'Ticksize', 'Tomato', 'Turquoise', 'UnFill', 'VERSION', 'Value', 'Vertical', 'Violet', 'VioletRed', 'W', 'WNW', 'WSW', 'Wheat', 'White', 'WhiteSmoke', 'WildStrawberry', 'XYAlign', 'YAlign', 'Yellow', 'YellowGreen', 'YellowOrange', 'addpenarc', 'addpenline', 'align', 'allowstepping', 'angularsystem', 'animationdelay', 'appendsuffix', 'arcarrowangle', 'arcarrowfactor', 'arrow2sizelimit', 'arrowangle', 'arrowbarb', 'arrowdir', 'arrowfactor', 'arrowhookfactor', 'arrowlength', 'arrowsizelimit', 'arrowtexfactor', 'authorpen', 'axis', 'axiscoverage', 'axislabelfactor', 'background', 'backgroundcolor', 'backgroundpen', 'barfactor', 'barmarksizefactor', 'basealign', 'baselinetemplate', 'beveljoin', 'bigvertexpen', 'bigvertexsize', 'black', 'blue', 'bm', 'bottom', 'bp', 'brown', 'bullet', 'byfoci', 'byvertices', 'camerafactor', 'chartreuse', 'circlemarkradiusfactor', 'circlenodesnumberfactor', 'circleprecision', 'circlescale', 'cm', 'codefile', 'codepen', 'codeskip', 'colorPen', 'coloredNodes', 'coloredSegments', 'conditionlength', 'conicnodesfactor', 'count', 'cputimeformat', 'crossmarksizefactor', 'currentcoordsys', 'currentlight', 'currentpatterns', 'currentpen', 'currentpicture', 'currentposition', 'currentprojection', 'curvilinearsystem', 'cuttings', 'cyan', 'darkblue', 'darkbrown', 'darkcyan', 'darkgray', 'darkgreen', 'darkgrey', 'darkmagenta', 'darkolive', 'darkred', 'dashdotted', 'dashed', 'datepen', 'dateskip', 'debuggerlines', 'debugging', 'deepblue', 'deepcyan', 'deepgray', 'deepgreen', 'deepgrey', 'deepmagenta', 'deepred', 'default', 'defaultControl', 'defaultS', 'defaultbackpen', 'defaultcoordsys', 'defaultfilename', 'defaultformat', 'defaultmassformat', 'defaultpen', 'diagnostics', 'differentlengths', 'dot', 'dotfactor', 'dotframe', 'dotted', 'doublelinepen', 'doublelinespacing', 'down', 'duplicateFuzz', 'ellipsenodesnumberfactor', 'eps', 'epsgeo', 'epsilon', 'evenodd', 'extendcap', 'fermionpen', 'figureborder', 'figuremattpen', 'firstnode', 'firststep', 'foregroundcolor', 'fuchsia', 'fuzz', 'gapfactor', 'ghostpen', 'gluonamplitude', 'gluonpen', 'gluonratio', 'gray', 'green', 'grey', 'hatchepsilon', 'havepagenumber', 'heavyblue', 'heavycyan', 'heavygray', 'heavygreen', 'heavygrey', 'heavymagenta', 'heavyred', 'hline', 'hwratio', 'hyperbolanodesnumberfactor', 'identity4', 'ignore', 'inXasyMode', 'inch', 'inches', 'includegraphicscommand', 'inf', 'infinity', 'institutionpen', 'intMax', 'intMin', 'invert', 'invisible', 'itempen', 'itemskip', 'itemstep', 'labelmargin', 'landscape', 'lastnode', 'left', 'legendhskip', 'legendlinelength', 'legendmargin', 'legendmarkersize', 'legendmaxrelativewidth', 'legendvskip', 'lightblue', 'lightcyan', 'lightgray', 'lightgreen', 'lightgrey', 'lightmagenta', 'lightolive', 'lightred', 'lightyellow', 'linemargin', 'lm_infmsg', 'lm_shortmsg', 'longdashdotted', 'longdashed', 'magenta', 'magneticPoints', 'magneticRadius', 'mantissaBits', 'markangleradius', 'markangleradiusfactor', 'markanglespace', 'markanglespacefactor', 'mediumblue', 'mediumcyan', 'mediumgray', 'mediumgreen', 'mediumgrey', 'mediummagenta', 'mediumred', 'mediumyellow', 'middle', 'minDistDefault', 'minblockheight', 'minblockwidth', 'mincirclediameter', 'minipagemargin', 'minipagewidth', 'minvertexangle', 'miterjoin', 'mm', 'momarrowfactor', 'momarrowlength', 'momarrowmargin', 'momarrowoffset', 'momarrowpen', 'monoPen', 'morepoints', 'nCircle', 'newbulletcolor', 'ngraph', 'nil', 'nmesh', 'nobasealign', 'nodeMarginDefault', 'nodesystem', 'nomarker', 'nopoint', 'noprimary', 'nullpath', 'nullpen', 'numarray', 'ocgindex', 'oldbulletcolor', 'olive', 'orange', 'origin', 'overpaint', 'page', 'pageheight', 'pagemargin', 'pagenumberalign', 'pagenumberpen', 'pagenumberposition', 'pagewidth', 'paleblue', 'palecyan', 'palegray', 'palegreen', 'palegrey', 'palemagenta', 'palered', 'paleyellow', 'parabolanodesnumberfactor', 'perpfactor', 'phi', 'photonamplitude', 'photonpen', 'photonratio', 'pi', 'pink', 'plain', 'plus', 'preamblenodes', 'pt', 'purple', 'r3', 'r4a', 'r4b', 'randMax', 'realDigits', 'realEpsilon', 'realMax', 'realMin', 'red', 'relativesystem', 'reverse', 'right', 'roundcap', 'roundjoin', 'royalblue', 'salmon', 'saveFunctions', 'scalarpen', 'sequencereal', 'settings', 'shipped', 'signedtrailingzero', 'solid', 'springgreen', 'sqrtEpsilon', 'squarecap', 'squarepen', 'startposition', 'stdin', 'stdout', 'stepfactor', 'stepfraction', 'steppagenumberpen', 'stepping', 'stickframe', 'stickmarksizefactor', 'stickmarkspacefactor', 'textpen', 'ticksize', 'tildeframe', 'tildemarksizefactor', 'tinv', 'titlealign', 'titlepagepen', 'titlepageposition', 'titlepen', 'titleskip', 'top', 'trailingzero', 'treeLevelStep', 'treeMinNodeWidth', 'treeNodeStep', 'trembleAngle', 'trembleFrequency', 'trembleRandom', 'tremblingMode', 'undefined', 'unitcircle', 'unitsquare', 'up', 'urlpen', 'urlskip', 'version', 'vertexpen', 'vertexsize', 'viewportmargin', 'viewportsize', 'vline', 'white', 'wye', 'xformStack', 'yellow', 'ylabelwidth', 'zerotickfuzz', 'zerowinding' }
27,287
Python
15.58845
77
0.51574
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/berry.py
""" pygments.lexers.berry ~~~~~~~~~~~~~~~~~~~~~ Lexer for Berry. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, words, include, bygroups from pygments.token import Comment, Whitespace, Operator, Keyword, Name, \ String, Number, Punctuation __all__ = ['BerryLexer'] class BerryLexer(RegexLexer): """ For `berry <http://github.com/berry-lang/berry>`_ source code. .. versionadded:: 2.12.0 """ name = 'Berry' aliases = ['berry', 'be'] filenames = ['*.be'] mimetypes = ['text/x-berry', 'application/x-berry'] _name = r'\b[^\W\d]\w*' tokens = { 'root': [ include('whitespace'), include('numbers'), include('keywords'), (rf'(def)(\s+)({_name})', bygroups(Keyword.Declaration, Whitespace, Name.Function)), (rf'\b(class)(\s+)({_name})', bygroups(Keyword.Declaration, Whitespace, Name.Class)), (rf'\b(import)(\s+)({_name})', bygroups(Keyword.Namespace, Whitespace, Name.Namespace)), include('expr') ], 'expr': [ (r'[^\S\n]+', Whitespace), (r'\.\.|[~!%^&*+=|?:<>/-]', Operator), (r'[(){}\[\],.;]', Punctuation), include('controls'), include('builtins'), include('funccall'), include('member'), include('name'), include('strings') ], 'whitespace': [ (r'\s+', Whitespace), (r'#-(.|\n)*?-#', Comment.Multiline), (r'#.*?$', Comment.Single) ], 'keywords': [ (words(( 'as', 'break', 'continue', 'import', 'static', 'self', 'super'), suffix=r'\b'), Keyword.Reserved), (r'(true|false|nil)\b', Keyword.Constant), (r'(var|def)\b', Keyword.Declaration) ], 'controls': [ (words(( 'if', 'elif', 'else', 'for', 'while', 'do', 'end', 'break', 'continue', 'return', 'try', 'except', 'raise'), suffix=r'\b'), Keyword) ], 'builtins': [ (words(( 'assert', 'bool', 'input', 'classname', 'classof', 'number', 'real', 'bytes', 'compile', 'map', 'list', 'int', 'isinstance', 'print', 'range', 'str', 'super', 'module', 'size', 'issubclass', 'open', 'file', 'type', 'call'), suffix=r'\b'), Name.Builtin) ], 'numbers': [ (r'0[xX][a-fA-F0-9]+', Number.Hex), (r'-?\d+', Number.Integer), (r'(-?\d+\.?|\.\d)\d*([eE][+-]?\d+)?', Number.Float) ], 'name': [ (_name, Name) ], 'funccall': [ (rf'{_name}(?=\s*\()', Name.Function, '#pop') ], 'member': [ (rf'(?<=\.){_name}\b(?!\()', Name.Attribute, '#pop') ], 'strings': [ (r'"([^\\]|\\.)*?"', String.Double, '#pop'), (r'\'([^\\]|\\.)*?\'', String.Single, '#pop') ] }
3,211
Python
31.12
84
0.431641
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/xorg.py
""" pygments.lexers.xorg ~~~~~~~~~~~~~~~~~~~~ Lexers for Xorg configs. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ from pygments.lexer import RegexLexer, bygroups from pygments.token import Comment, String, Name, Text __all__ = ['XorgLexer'] class XorgLexer(RegexLexer): """Lexer for xorg.conf files.""" name = 'Xorg' url = 'https://www.x.org/wiki/' aliases = ['xorg.conf'] filenames = ['xorg.conf'] mimetypes = [] tokens = { 'root': [ (r'\s+', Text), (r'#.*$', Comment), (r'((?:Sub)?Section)(\s+)("\w+")', bygroups(String.Escape, Text, String.Escape)), (r'(End(?:Sub)?Section)', String.Escape), (r'(\w+)(\s+)([^\n#]+)', bygroups(Name.Builtin, Text, Name.Constant)), ], }
902
Python
22.763157
70
0.519956
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/parsers.py
""" pygments.lexers.parsers ~~~~~~~~~~~~~~~~~~~~~~~ Lexers for parser generators. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, DelegatingLexer, \ include, bygroups, using from pygments.token import Punctuation, Other, Text, Comment, Operator, \ Keyword, Name, String, Number, Whitespace from pygments.lexers.jvm import JavaLexer from pygments.lexers.c_cpp import CLexer, CppLexer from pygments.lexers.objective import ObjectiveCLexer from pygments.lexers.d import DLexer from pygments.lexers.dotnet import CSharpLexer from pygments.lexers.ruby import RubyLexer from pygments.lexers.python import PythonLexer from pygments.lexers.perl import PerlLexer __all__ = ['RagelLexer', 'RagelEmbeddedLexer', 'RagelCLexer', 'RagelDLexer', 'RagelCppLexer', 'RagelObjectiveCLexer', 'RagelRubyLexer', 'RagelJavaLexer', 'AntlrLexer', 'AntlrPythonLexer', 'AntlrPerlLexer', 'AntlrRubyLexer', 'AntlrCppLexer', 'AntlrCSharpLexer', 'AntlrObjectiveCLexer', 'AntlrJavaLexer', 'AntlrActionScriptLexer', 'TreetopLexer', 'EbnfLexer'] class RagelLexer(RegexLexer): """A pure `Ragel <www.colm.net/open-source/ragel>`_ lexer. Use this for fragments of Ragel. For ``.rl`` files, use :class:`RagelEmbeddedLexer` instead (or one of the language-specific subclasses). .. versionadded:: 1.1 """ name = 'Ragel' url = 'http://www.colm.net/open-source/ragel/' aliases = ['ragel'] filenames = [] tokens = { 'whitespace': [ (r'\s+', Whitespace) ], 'comments': [ (r'\#.*$', Comment), ], 'keywords': [ (r'(access|action|alphtype)\b', Keyword), (r'(getkey|write|machine|include)\b', Keyword), (r'(any|ascii|extend|alpha|digit|alnum|lower|upper)\b', Keyword), (r'(xdigit|cntrl|graph|print|punct|space|zlen|empty)\b', Keyword) ], 'numbers': [ (r'0x[0-9A-Fa-f]+', Number.Hex), (r'[+-]?[0-9]+', Number.Integer), ], 'literals': [ (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'\[(\\\\|\\[^\\]|[^\\\]])*\]', String), # square bracket literals (r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', String.Regex), # regular expressions ], 'identifiers': [ (r'[a-zA-Z_]\w*', Name.Variable), ], 'operators': [ (r',', Operator), # Join (r'\||&|--?', Operator), # Union, Intersection and Subtraction (r'\.|<:|:>>?', Operator), # Concatention (r':', Operator), # Label (r'->', Operator), # Epsilon Transition (r'(>|\$|%|<|@|<>)(/|eof\b)', Operator), # EOF Actions (r'(>|\$|%|<|@|<>)(!|err\b)', Operator), # Global Error Actions (r'(>|\$|%|<|@|<>)(\^|lerr\b)', Operator), # Local Error Actions (r'(>|\$|%|<|@|<>)(~|to\b)', Operator), # To-State Actions (r'(>|\$|%|<|@|<>)(\*|from\b)', Operator), # From-State Actions (r'>|@|\$|%', Operator), # Transition Actions and Priorities (r'\*|\?|\+|\{[0-9]*,[0-9]*\}', Operator), # Repetition (r'!|\^', Operator), # Negation (r'\(|\)', Operator), # Grouping ], 'root': [ include('literals'), include('whitespace'), include('comments'), include('keywords'), include('numbers'), include('identifiers'), include('operators'), (r'\{', Punctuation, 'host'), (r'=', Operator), (r';', Punctuation), ], 'host': [ (r'(' + r'|'.join(( # keep host code in largest possible chunks r'[^{}\'"/#]+', # exclude unsafe characters r'[^\\]\\[{}]', # allow escaped { or } # strings and comments may safely contain unsafe characters r'"(\\\\|\\[^\\]|[^"\\])*"', r"'(\\\\|\\[^\\]|[^'\\])*'", r'//.*$\n?', # single line comment r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment r'\#.*$\n?', # ruby comment # regular expression: There's no reason for it to start # with a * and this stops confusion with comments. r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', # / is safe now that we've handled regex and javadoc comments r'/', )) + r')+', Other), (r'\{', Punctuation, '#push'), (r'\}', Punctuation, '#pop'), ], } class RagelEmbeddedLexer(RegexLexer): """ A lexer for Ragel embedded in a host language file. This will only highlight Ragel statements. If you want host language highlighting then call the language-specific Ragel lexer. .. versionadded:: 1.1 """ name = 'Embedded Ragel' aliases = ['ragel-em'] filenames = ['*.rl'] tokens = { 'root': [ (r'(' + r'|'.join(( # keep host code in largest possible chunks r'[^%\'"/#]+', # exclude unsafe characters r'%(?=[^%]|$)', # a single % sign is okay, just not 2 of them # strings and comments may safely contain unsafe characters r'"(\\\\|\\[^\\]|[^"\\])*"', r"'(\\\\|\\[^\\]|[^'\\])*'", r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment r'//.*$\n?', # single line comment r'\#.*$\n?', # ruby/ragel comment r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', # regular expression # / is safe now that we've handled regex and javadoc comments r'/', )) + r')+', Other), # Single Line FSM. # Please don't put a quoted newline in a single line FSM. # That's just mean. It will break this. (r'(%%)(?![{%])(.*)($|;)(\n?)', bygroups(Punctuation, using(RagelLexer), Punctuation, Text)), # Multi Line FSM. (r'(%%%%|%%)\{', Punctuation, 'multi-line-fsm'), ], 'multi-line-fsm': [ (r'(' + r'|'.join(( # keep ragel code in largest possible chunks. r'(' + r'|'.join(( r'[^}\'"\[/#]', # exclude unsafe characters r'\}(?=[^%]|$)', # } is okay as long as it's not followed by % r'\}%(?=[^%]|$)', # ...well, one %'s okay, just not two... r'[^\\]\\[{}]', # ...and } is okay if it's escaped # allow / if it's preceded with one of these symbols # (ragel EOF actions) r'(>|\$|%|<|@|<>)/', # specifically allow regex followed immediately by * # so it doesn't get mistaken for a comment r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/\*', # allow / as long as it's not followed by another / or by a * r'/(?=[^/*]|$)', # We want to match as many of these as we can in one block. # Not sure if we need the + sign here, # does it help performance? )) + r')+', # strings and comments may safely contain unsafe characters r'"(\\\\|\\[^\\]|[^"\\])*"', r"'(\\\\|\\[^\\]|[^'\\])*'", r"\[(\\\\|\\[^\\]|[^\]\\])*\]", # square bracket literal r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment r'//.*$\n?', # single line comment r'\#.*$\n?', # ruby/ragel comment )) + r')+', using(RagelLexer)), (r'\}%%', Punctuation, '#pop'), ] } def analyse_text(text): return '@LANG: indep' in text class RagelRubyLexer(DelegatingLexer): """ A lexer for Ragel in a Ruby host file. .. versionadded:: 1.1 """ name = 'Ragel in Ruby Host' aliases = ['ragel-ruby', 'ragel-rb'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(RubyLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: ruby' in text class RagelCLexer(DelegatingLexer): """ A lexer for Ragel in a C host file. .. versionadded:: 1.1 """ name = 'Ragel in C Host' aliases = ['ragel-c'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(CLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: c' in text class RagelDLexer(DelegatingLexer): """ A lexer for Ragel in a D host file. .. versionadded:: 1.1 """ name = 'Ragel in D Host' aliases = ['ragel-d'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(DLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: d' in text class RagelCppLexer(DelegatingLexer): """ A lexer for Ragel in a C++ host file. .. versionadded:: 1.1 """ name = 'Ragel in CPP Host' aliases = ['ragel-cpp'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(CppLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: c++' in text class RagelObjectiveCLexer(DelegatingLexer): """ A lexer for Ragel in an Objective C host file. .. versionadded:: 1.1 """ name = 'Ragel in Objective C Host' aliases = ['ragel-objc'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(ObjectiveCLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: objc' in text class RagelJavaLexer(DelegatingLexer): """ A lexer for Ragel in a Java host file. .. versionadded:: 1.1 """ name = 'Ragel in Java Host' aliases = ['ragel-java'] filenames = ['*.rl'] def __init__(self, **options): super().__init__(JavaLexer, RagelEmbeddedLexer, **options) def analyse_text(text): return '@LANG: java' in text class AntlrLexer(RegexLexer): """ Generic `ANTLR`_ Lexer. Should not be called directly, instead use DelegatingLexer for your target language. .. versionadded:: 1.1 .. _ANTLR: http://www.antlr.org/ """ name = 'ANTLR' aliases = ['antlr'] filenames = [] _id = r'[A-Za-z]\w*' _TOKEN_REF = r'[A-Z]\w*' _RULE_REF = r'[a-z]\w*' _STRING_LITERAL = r'\'(?:\\\\|\\\'|[^\']*)\'' _INT = r'[0-9]+' tokens = { 'whitespace': [ (r'\s+', Whitespace), ], 'comments': [ (r'//.*$', Comment), (r'/\*(.|\n)*?\*/', Comment), ], 'root': [ include('whitespace'), include('comments'), (r'(lexer|parser|tree)?(\s*)(grammar\b)(\s*)(' + _id + ')(;)', bygroups(Keyword, Whitespace, Keyword, Whitespace, Name.Class, Punctuation)), # optionsSpec (r'options\b', Keyword, 'options'), # tokensSpec (r'tokens\b', Keyword, 'tokens'), # attrScope (r'(scope)(\s*)(' + _id + r')(\s*)(\{)', bygroups(Keyword, Whitespace, Name.Variable, Whitespace, Punctuation), 'action'), # exception (r'(catch|finally)\b', Keyword, 'exception'), # action (r'(@' + _id + r')(\s*)(::)?(\s*)(' + _id + r')(\s*)(\{)', bygroups(Name.Label, Whitespace, Punctuation, Whitespace, Name.Label, Whitespace, Punctuation), 'action'), # rule (r'((?:protected|private|public|fragment)\b)?(\s*)(' + _id + ')(!)?', bygroups(Keyword, Whitespace, Name.Label, Punctuation), ('rule-alts', 'rule-prelims')), ], 'exception': [ (r'\n', Whitespace, '#pop'), (r'\s', Whitespace), include('comments'), (r'\[', Punctuation, 'nested-arg-action'), (r'\{', Punctuation, 'action'), ], 'rule-prelims': [ include('whitespace'), include('comments'), (r'returns\b', Keyword), (r'\[', Punctuation, 'nested-arg-action'), (r'\{', Punctuation, 'action'), # throwsSpec (r'(throws)(\s+)(' + _id + ')', bygroups(Keyword, Whitespace, Name.Label)), (r'(,)(\s*)(' + _id + ')', bygroups(Punctuation, Whitespace, Name.Label)), # Additional throws # optionsSpec (r'options\b', Keyword, 'options'), # ruleScopeSpec - scope followed by target language code or name of action # TODO finish implementing other possibilities for scope # L173 ANTLRv3.g from ANTLR book (r'(scope)(\s+)(\{)', bygroups(Keyword, Whitespace, Punctuation), 'action'), (r'(scope)(\s+)(' + _id + r')(\s*)(;)', bygroups(Keyword, Whitespace, Name.Label, Whitespace, Punctuation)), # ruleAction (r'(@' + _id + r')(\s*)(\{)', bygroups(Name.Label, Whitespace, Punctuation), 'action'), # finished prelims, go to rule alts! (r':', Punctuation, '#pop') ], 'rule-alts': [ include('whitespace'), include('comments'), # These might need to go in a separate 'block' state triggered by ( (r'options\b', Keyword, 'options'), (r':', Punctuation), # literals (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'<<([^>]|>[^>])>>', String), # identifiers # Tokens start with capital letter. (r'\$?[A-Z_]\w*', Name.Constant), # Rules start with small letter. (r'\$?[a-z_]\w*', Name.Variable), # operators (r'(\+|\||->|=>|=|\(|\)|\.\.|\.|\?|\*|\^|!|\#|~)', Operator), (r',', Punctuation), (r'\[', Punctuation, 'nested-arg-action'), (r'\{', Punctuation, 'action'), (r';', Punctuation, '#pop') ], 'tokens': [ include('whitespace'), include('comments'), (r'\{', Punctuation), (r'(' + _TOKEN_REF + r')(\s*)(=)?(\s*)(' + _STRING_LITERAL + r')?(\s*)(;)', bygroups(Name.Label, Whitespace, Punctuation, Whitespace, String, Whitespace, Punctuation)), (r'\}', Punctuation, '#pop'), ], 'options': [ include('whitespace'), include('comments'), (r'\{', Punctuation), (r'(' + _id + r')(\s*)(=)(\s*)(' + '|'.join((_id, _STRING_LITERAL, _INT, r'\*')) + r')(\s*)(;)', bygroups(Name.Variable, Whitespace, Punctuation, Whitespace, Text, Whitespace, Punctuation)), (r'\}', Punctuation, '#pop'), ], 'action': [ (r'(' + r'|'.join(( # keep host code in largest possible chunks r'[^${}\'"/\\]+', # exclude unsafe characters # strings and comments may safely contain unsafe characters r'"(\\\\|\\[^\\]|[^"\\])*"', r"'(\\\\|\\[^\\]|[^'\\])*'", r'//.*$\n?', # single line comment r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment # regular expression: There's no reason for it to start # with a * and this stops confusion with comments. r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', # backslashes are okay, as long as we are not backslashing a % r'\\(?!%)', # Now that we've handled regex and javadoc comments # it's safe to let / through. r'/', )) + r')+', Other), (r'(\\)(%)', bygroups(Punctuation, Other)), (r'(\$[a-zA-Z]+)(\.?)(text|value)?', bygroups(Name.Variable, Punctuation, Name.Property)), (r'\{', Punctuation, '#push'), (r'\}', Punctuation, '#pop'), ], 'nested-arg-action': [ (r'(' + r'|'.join(( # keep host code in largest possible chunks. r'[^$\[\]\'"/]+', # exclude unsafe characters # strings and comments may safely contain unsafe characters r'"(\\\\|\\[^\\]|[^"\\])*"', r"'(\\\\|\\[^\\]|[^'\\])*'", r'//.*$\n?', # single line comment r'/\*(.|\n)*?\*/', # multi-line javadoc-style comment # regular expression: There's no reason for it to start # with a * and this stops confusion with comments. r'/(?!\*)(\\\\|\\[^\\]|[^/\\])*/', # Now that we've handled regex and javadoc comments # it's safe to let / through. r'/', )) + r')+', Other), (r'\[', Punctuation, '#push'), (r'\]', Punctuation, '#pop'), (r'(\$[a-zA-Z]+)(\.?)(text|value)?', bygroups(Name.Variable, Punctuation, Name.Property)), (r'(\\\\|\\\]|\\\[|[^\[\]])+', Other), ] } def analyse_text(text): return re.search(r'^\s*grammar\s+[a-zA-Z0-9]+\s*;', text, re.M) # http://www.antlr.org/wiki/display/ANTLR3/Code+Generation+Targets class AntlrCppLexer(DelegatingLexer): """ ANTLR with C++ Target .. versionadded:: 1.1 """ name = 'ANTLR With CPP Target' aliases = ['antlr-cpp'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(CppLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*C\s*;', text, re.M) class AntlrObjectiveCLexer(DelegatingLexer): """ ANTLR with Objective-C Target .. versionadded:: 1.1 """ name = 'ANTLR With ObjectiveC Target' aliases = ['antlr-objc'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(ObjectiveCLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*ObjC\s*;', text) class AntlrCSharpLexer(DelegatingLexer): """ ANTLR with C# Target .. versionadded:: 1.1 """ name = 'ANTLR With C# Target' aliases = ['antlr-csharp', 'antlr-c#'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(CSharpLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*CSharp2\s*;', text, re.M) class AntlrPythonLexer(DelegatingLexer): """ ANTLR with Python Target .. versionadded:: 1.1 """ name = 'ANTLR With Python Target' aliases = ['antlr-python'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(PythonLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*Python\s*;', text, re.M) class AntlrJavaLexer(DelegatingLexer): """ ANTLR with Java Target .. versionadded:: 1. """ name = 'ANTLR With Java Target' aliases = ['antlr-java'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(JavaLexer, AntlrLexer, **options) def analyse_text(text): # Antlr language is Java by default return AntlrLexer.analyse_text(text) and 0.9 class AntlrRubyLexer(DelegatingLexer): """ ANTLR with Ruby Target .. versionadded:: 1.1 """ name = 'ANTLR With Ruby Target' aliases = ['antlr-ruby', 'antlr-rb'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(RubyLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*Ruby\s*;', text, re.M) class AntlrPerlLexer(DelegatingLexer): """ ANTLR with Perl Target .. versionadded:: 1.1 """ name = 'ANTLR With Perl Target' aliases = ['antlr-perl'] filenames = ['*.G', '*.g'] def __init__(self, **options): super().__init__(PerlLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*Perl5\s*;', text, re.M) class AntlrActionScriptLexer(DelegatingLexer): """ ANTLR with ActionScript Target .. versionadded:: 1.1 """ name = 'ANTLR With ActionScript Target' aliases = ['antlr-actionscript', 'antlr-as'] filenames = ['*.G', '*.g'] def __init__(self, **options): from pygments.lexers.actionscript import ActionScriptLexer super().__init__(ActionScriptLexer, AntlrLexer, **options) def analyse_text(text): return AntlrLexer.analyse_text(text) and \ re.search(r'^\s*language\s*=\s*ActionScript\s*;', text, re.M) class TreetopBaseLexer(RegexLexer): """ A base lexer for `Treetop <http://treetop.rubyforge.org/>`_ grammars. Not for direct use; use :class:`TreetopLexer` instead. .. versionadded:: 1.6 """ tokens = { 'root': [ include('space'), (r'require[ \t]+[^\n\r]+[\n\r]', Other), (r'module\b', Keyword.Namespace, 'module'), (r'grammar\b', Keyword, 'grammar'), ], 'module': [ include('space'), include('end'), (r'module\b', Keyword, '#push'), (r'grammar\b', Keyword, 'grammar'), (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Namespace), ], 'grammar': [ include('space'), include('end'), (r'rule\b', Keyword, 'rule'), (r'include\b', Keyword, 'include'), (r'[A-Z]\w*', Name), ], 'include': [ include('space'), (r'[A-Z]\w*(?:::[A-Z]\w*)*', Name.Class, '#pop'), ], 'rule': [ include('space'), include('end'), (r'"(\\\\|\\[^\\]|[^"\\])*"', String.Double), (r"'(\\\\|\\[^\\]|[^'\\])*'", String.Single), (r'([A-Za-z_]\w*)(:)', bygroups(Name.Label, Punctuation)), (r'[A-Za-z_]\w*', Name), (r'[()]', Punctuation), (r'[?+*/&!~]', Operator), (r'\[(?:\\.|\[:\^?[a-z]+:\]|[^\\\]])+\]', String.Regex), (r'([0-9]*)(\.\.)([0-9]*)', bygroups(Number.Integer, Operator, Number.Integer)), (r'(<)([^>]+)(>)', bygroups(Punctuation, Name.Class, Punctuation)), (r'\{', Punctuation, 'inline_module'), (r'\.', String.Regex), ], 'inline_module': [ (r'\{', Other, 'ruby'), (r'\}', Punctuation, '#pop'), (r'[^{}]+', Other), ], 'ruby': [ (r'\{', Other, '#push'), (r'\}', Other, '#pop'), (r'[^{}]+', Other), ], 'space': [ (r'[ \t\n\r]+', Whitespace), (r'#[^\n]*', Comment.Single), ], 'end': [ (r'end\b', Keyword, '#pop'), ], } class TreetopLexer(DelegatingLexer): """ A lexer for `Treetop <http://treetop.rubyforge.org/>`_ grammars. .. versionadded:: 1.6 """ name = 'Treetop' aliases = ['treetop'] filenames = ['*.treetop', '*.tt'] def __init__(self, **options): super().__init__(RubyLexer, TreetopBaseLexer, **options) class EbnfLexer(RegexLexer): """ Lexer for `ISO/IEC 14977 EBNF <http://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_Form>`_ grammars. .. versionadded:: 2.0 """ name = 'EBNF' aliases = ['ebnf'] filenames = ['*.ebnf'] mimetypes = ['text/x-ebnf'] tokens = { 'root': [ include('whitespace'), include('comment_start'), include('identifier'), (r'=', Operator, 'production'), ], 'production': [ include('whitespace'), include('comment_start'), include('identifier'), (r'"[^"]*"', String.Double), (r"'[^']*'", String.Single), (r'(\?[^?]*\?)', Name.Entity), (r'[\[\]{}(),|]', Punctuation), (r'-', Operator), (r';', Punctuation, '#pop'), (r'\.', Punctuation, '#pop'), ], 'whitespace': [ (r'\s+', Text), ], 'comment_start': [ (r'\(\*', Comment.Multiline, 'comment'), ], 'comment': [ (r'[^*)]', Comment.Multiline), include('comment_start'), (r'\*\)', Comment.Multiline, '#pop'), (r'[*)]', Comment.Multiline), ], 'identifier': [ (r'([a-zA-Z][\w \-]*)', Keyword), ], }
25,904
Python
31.300499
93
0.462438
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/r.py
""" pygments.lexers.r ~~~~~~~~~~~~~~~~~ Lexers for the R/S languages. :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import Lexer, RegexLexer, include, do_insertions from pygments.token import Text, Comment, Operator, Keyword, Name, String, \ Number, Punctuation, Generic, Whitespace __all__ = ['RConsoleLexer', 'SLexer', 'RdLexer'] line_re = re.compile('.*?\n') class RConsoleLexer(Lexer): """ For R console transcripts or R CMD BATCH output files. """ name = 'RConsole' aliases = ['rconsole', 'rout'] filenames = ['*.Rout'] def get_tokens_unprocessed(self, text): slexer = SLexer(**self.options) current_code_block = '' insertions = [] for match in line_re.finditer(text): line = match.group() if line.startswith('>') or line.startswith('+'): # Colorize the prompt as such, # then put rest of line into current_code_block insertions.append((len(current_code_block), [(0, Generic.Prompt, line[:2])])) current_code_block += line[2:] else: # We have reached a non-prompt line! # If we have stored prompt lines, need to process them first. if current_code_block: # Weave together the prompts and highlight code. yield from do_insertions( insertions, slexer.get_tokens_unprocessed(current_code_block)) # Reset vars for next code block. current_code_block = '' insertions = [] # Now process the actual line itself, this is output from R. yield match.start(), Generic.Output, line # If we happen to end on a code block with nothing after it, need to # process the last code block. This is neither elegant nor DRY so # should be changed. if current_code_block: yield from do_insertions( insertions, slexer.get_tokens_unprocessed(current_code_block)) class SLexer(RegexLexer): """ For S, S-plus, and R source code. .. versionadded:: 0.10 """ name = 'S' aliases = ['splus', 's', 'r'] filenames = ['*.S', '*.R', '.Rhistory', '.Rprofile', '.Renviron'] mimetypes = ['text/S-plus', 'text/S', 'text/x-r-source', 'text/x-r', 'text/x-R', 'text/x-r-history', 'text/x-r-profile'] valid_name = r'`[^`\\]*(?:\\.[^`\\]*)*`|(?:[a-zA-Z]|\.[A-Za-z_.])[\w.]*|\.' tokens = { 'comments': [ (r'#.*$', Comment.Single), ], 'valid_name': [ (valid_name, Name), ], 'punctuation': [ (r'\[{1,2}|\]{1,2}|\(|\)|;|,', Punctuation), ], 'keywords': [ (r'(if|else|for|while|repeat|in|next|break|return|switch|function)' r'(?![\w.])', Keyword.Reserved), ], 'operators': [ (r'<<?-|->>?|-|==|<=|>=|<|>|&&?|!=|\|\|?|\?', Operator), (r'\*|\+|\^|/|!|%[^%]*%|=|~|\$|@|:{1,3}', Operator), ], 'builtin_symbols': [ (r'(NULL|NA(_(integer|real|complex|character)_)?|' r'letters|LETTERS|Inf|TRUE|FALSE|NaN|pi|\.\.(\.|[0-9]+))' r'(?![\w.])', Keyword.Constant), (r'(T|F)\b', Name.Builtin.Pseudo), ], 'numbers': [ # hex number (r'0[xX][a-fA-F0-9]+([pP][0-9]+)?[Li]?', Number.Hex), # decimal number (r'[+-]?([0-9]+(\.[0-9]+)?|\.[0-9]+|\.)([eE][+-]?[0-9]+)?[Li]?', Number), ], 'statements': [ include('comments'), # whitespaces (r'\s+', Whitespace), (r'\'', String, 'string_squote'), (r'\"', String, 'string_dquote'), include('builtin_symbols'), include('valid_name'), include('numbers'), include('keywords'), include('punctuation'), include('operators'), ], 'root': [ # calls: (r'(%s)\s*(?=\()' % valid_name, Name.Function), include('statements'), # blocks: (r'\{|\}', Punctuation), # (r'\{', Punctuation, 'block'), (r'.', Text), ], # 'block': [ # include('statements'), # ('\{', Punctuation, '#push'), # ('\}', Punctuation, '#pop') # ], 'string_squote': [ (r'([^\'\\]|\\.)*\'', String, '#pop'), ], 'string_dquote': [ (r'([^"\\]|\\.)*"', String, '#pop'), ], } def analyse_text(text): if re.search(r'[a-z0-9_\])\s]<-(?!-)', text): return 0.11 class RdLexer(RegexLexer): """ Pygments Lexer for R documentation (Rd) files This is a very minimal implementation, highlighting little more than the macros. A description of Rd syntax is found in `Writing R Extensions <http://cran.r-project.org/doc/manuals/R-exts.html>`_ and `Parsing Rd files <http://developer.r-project.org/parseRd.pdf>`_. .. versionadded:: 1.6 """ name = 'Rd' aliases = ['rd'] filenames = ['*.Rd'] mimetypes = ['text/x-r-doc'] # To account for verbatim / LaTeX-like / and R-like areas # would require parsing. tokens = { 'root': [ # catch escaped brackets and percent sign (r'\\[\\{}%]', String.Escape), # comments (r'%.*$', Comment), # special macros with no arguments (r'\\(?:cr|l?dots|R|tab)\b', Keyword.Constant), # macros (r'\\[a-zA-Z]+\b', Keyword), # special preprocessor macros (r'^\s*#(?:ifn?def|endif).*\b', Comment.Preproc), # non-escaped brackets (r'[{}]', Name.Builtin), # everything else (r'[^\\%\n{}]+', Text), (r'.', Text), ] }
6,185
Python
31.387434
86
0.470008
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/bibtex.py
""" pygments.lexers.bibtex ~~~~~~~~~~~~~~~~~~~~~~ Lexers for BibTeX bibliography data and styles :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ import re from pygments.lexer import RegexLexer, ExtendedRegexLexer, include, default, \ words from pygments.token import Name, Comment, String, Error, Number, Keyword, \ Punctuation, Whitespace __all__ = ['BibTeXLexer', 'BSTLexer'] class BibTeXLexer(ExtendedRegexLexer): """ A lexer for BibTeX bibliography data format. .. versionadded:: 2.2 """ name = 'BibTeX' aliases = ['bibtex', 'bib'] filenames = ['*.bib'] mimetypes = ["text/x-bibtex"] flags = re.IGNORECASE ALLOWED_CHARS = r'@!$&*+\-./:;<>?\[\\\]^`|~' IDENTIFIER = '[{}][{}]*'.format('a-z_' + ALLOWED_CHARS, r'\w' + ALLOWED_CHARS) def open_brace_callback(self, match, ctx): opening_brace = match.group() ctx.opening_brace = opening_brace yield match.start(), Punctuation, opening_brace ctx.pos = match.end() def close_brace_callback(self, match, ctx): closing_brace = match.group() if ( ctx.opening_brace == '{' and closing_brace != '}' or ctx.opening_brace == '(' and closing_brace != ')' ): yield match.start(), Error, closing_brace else: yield match.start(), Punctuation, closing_brace del ctx.opening_brace ctx.pos = match.end() tokens = { 'root': [ include('whitespace'), (r'@comment(?!ary)', Comment), ('@preamble', Name.Class, ('closing-brace', 'value', 'opening-brace')), ('@string', Name.Class, ('closing-brace', 'field', 'opening-brace')), ('@' + IDENTIFIER, Name.Class, ('closing-brace', 'command-body', 'opening-brace')), ('.+', Comment), ], 'opening-brace': [ include('whitespace'), (r'[{(]', open_brace_callback, '#pop'), ], 'closing-brace': [ include('whitespace'), (r'[})]', close_brace_callback, '#pop'), ], 'command-body': [ include('whitespace'), (r'[^\s\,\}]+', Name.Label, ('#pop', 'fields')), ], 'fields': [ include('whitespace'), (',', Punctuation, 'field'), default('#pop'), ], 'field': [ include('whitespace'), (IDENTIFIER, Name.Attribute, ('value', '=')), default('#pop'), ], '=': [ include('whitespace'), ('=', Punctuation, '#pop'), ], 'value': [ include('whitespace'), (IDENTIFIER, Name.Variable), ('"', String, 'quoted-string'), (r'\{', String, 'braced-string'), (r'[\d]+', Number), ('#', Punctuation), default('#pop'), ], 'quoted-string': [ (r'\{', String, 'braced-string'), ('"', String, '#pop'), (r'[^\{\"]+', String), ], 'braced-string': [ (r'\{', String, '#push'), (r'\}', String, '#pop'), (r'[^\{\}]+', String), ], 'whitespace': [ (r'\s+', Whitespace), ], } class BSTLexer(RegexLexer): """ A lexer for BibTeX bibliography styles. .. versionadded:: 2.2 """ name = 'BST' aliases = ['bst', 'bst-pybtex'] filenames = ['*.bst'] flags = re.IGNORECASE | re.MULTILINE tokens = { 'root': [ include('whitespace'), (words(['read', 'sort']), Keyword), (words(['execute', 'integers', 'iterate', 'reverse', 'strings']), Keyword, ('group')), (words(['function', 'macro']), Keyword, ('group', 'group')), (words(['entry']), Keyword, ('group', 'group', 'group')), ], 'group': [ include('whitespace'), (r'\{', Punctuation, ('#pop', 'group-end', 'body')), ], 'group-end': [ include('whitespace'), (r'\}', Punctuation, '#pop'), ], 'body': [ include('whitespace'), (r"\'[^#\"\{\}\s]+", Name.Function), (r'[^#\"\{\}\s]+\$', Name.Builtin), (r'[^#\"\{\}\s]+', Name.Variable), (r'"[^\"]*"', String), (r'#-?\d+', Number), (r'\{', Punctuation, ('group-end', 'body')), default('#pop'), ], 'whitespace': [ (r'\s+', Whitespace), ('%.*?$', Comment.Single), ], }
4,723
Python
28.525
83
0.45289
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/pygments/lexers/_csound_builtins.py
""" pygments.lexers._csound_builtins ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. """ REMOVED_OPCODES = set(''' OSCsendA beadsynt beosc buchla getrowlin lua_exec lua_iaopcall lua_iaopcall_off lua_ikopcall lua_ikopcall_off lua_iopcall lua_iopcall_off lua_opdef mp3scal_check mp3scal_load mp3scal_load2 mp3scal_play mp3scal_play2 pvsgendy socksend_k signalflowgraph sumTableFilter systime tabrowlin vbap1move '''.split()) # Opcodes in Csound 6.18.0 using: # python3 -c " # import re # from subprocess import Popen, PIPE # output = Popen(['csound', '--list-opcodes0'], stderr=PIPE, text=True).communicate()[1] # opcodes = output[re.search(r'^\$', output, re.M).end() : re.search(r'^\d+ opcodes\$', output, re.M).start()].split() # output = Popen(['csound', '--list-opcodes2'], stderr=PIPE, text=True).communicate()[1] # all_opcodes = output[re.search(r'^\$', output, re.M).end() : re.search(r'^\d+ opcodes\$', output, re.M).start()].split() # deprecated_opcodes = [opcode for opcode in all_opcodes if opcode not in opcodes] # # Remove opcodes that csound.py treats as keywords. # keyword_opcodes = [ # 'cggoto', # https://csound.com/docs/manual/cggoto.html # 'cigoto', # https://csound.com/docs/manual/cigoto.html # 'cingoto', # (undocumented) # 'ckgoto', # https://csound.com/docs/manual/ckgoto.html # 'cngoto', # https://csound.com/docs/manual/cngoto.html # 'cnkgoto', # (undocumented) # 'endin', # https://csound.com/docs/manual/endin.html # 'endop', # https://csound.com/docs/manual/endop.html # 'goto', # https://csound.com/docs/manual/goto.html # 'igoto', # https://csound.com/docs/manual/igoto.html # 'instr', # https://csound.com/docs/manual/instr.html # 'kgoto', # https://csound.com/docs/manual/kgoto.html # 'loop_ge', # https://csound.com/docs/manual/loop_ge.html # 'loop_gt', # https://csound.com/docs/manual/loop_gt.html # 'loop_le', # https://csound.com/docs/manual/loop_le.html # 'loop_lt', # https://csound.com/docs/manual/loop_lt.html # 'opcode', # https://csound.com/docs/manual/opcode.html # 'reinit', # https://csound.com/docs/manual/reinit.html # 'return', # https://csound.com/docs/manual/return.html # 'rireturn', # https://csound.com/docs/manual/rireturn.html # 'rigoto', # https://csound.com/docs/manual/rigoto.html # 'tigoto', # https://csound.com/docs/manual/tigoto.html # 'timout' # https://csound.com/docs/manual/timout.html # ] # opcodes = [opcode for opcode in opcodes if opcode not in keyword_opcodes] # newline = '\n' # print(f'''OPCODES = set(\''' # {newline.join(opcodes)} # \'''.split()) # # DEPRECATED_OPCODES = set(\''' # {newline.join(deprecated_opcodes)} # \'''.split()) # ''') # " OPCODES = set(''' ATSadd ATSaddnz ATSbufread ATScross ATSinfo ATSinterpread ATSpartialtap ATSread ATSreadnz ATSsinnoi FLbox FLbutBank FLbutton FLcloseButton FLcolor FLcolor2 FLcount FLexecButton FLgetsnap FLgroup FLgroupEnd FLgroup_end FLhide FLhvsBox FLhvsBoxSetValue FLjoy FLkeyIn FLknob FLlabel FLloadsnap FLmouse FLpack FLpackEnd FLpack_end FLpanel FLpanelEnd FLpanel_end FLprintk FLprintk2 FLroller FLrun FLsavesnap FLscroll FLscrollEnd FLscroll_end FLsetAlign FLsetBox FLsetColor FLsetColor2 FLsetFont FLsetPosition FLsetSize FLsetSnapGroup FLsetText FLsetTextColor FLsetTextSize FLsetTextType FLsetVal FLsetVal_i FLsetVali FLsetsnap FLshow FLslidBnk FLslidBnk2 FLslidBnk2Set FLslidBnk2Setk FLslidBnkGetHandle FLslidBnkSet FLslidBnkSetk FLslider FLtabs FLtabsEnd FLtabs_end FLtext FLupdate FLvalue FLvkeybd FLvslidBnk FLvslidBnk2 FLxyin JackoAudioIn JackoAudioInConnect JackoAudioOut JackoAudioOutConnect JackoFreewheel JackoInfo JackoInit JackoMidiInConnect JackoMidiOut JackoMidiOutConnect JackoNoteOut JackoOn JackoTransport K35_hpf K35_lpf MixerClear MixerGetLevel MixerReceive MixerSend MixerSetLevel MixerSetLevel_i OSCbundle OSCcount OSCinit OSCinitM OSClisten OSCraw OSCsend OSCsend_lo S STKBandedWG STKBeeThree STKBlowBotl STKBlowHole STKBowed STKBrass STKClarinet STKDrummer STKFMVoices STKFlute STKHevyMetl STKMandolin STKModalBar STKMoog STKPercFlut STKPlucked STKResonate STKRhodey STKSaxofony STKShakers STKSimple STKSitar STKStifKarp STKTubeBell STKVoicForm STKWhistle STKWurley a abs active adsr adsyn adsynt adsynt2 aftouch allpole alpass alwayson ampdb ampdbfs ampmidi ampmidicurve ampmidid apoleparams arduinoRead arduinoReadF arduinoStart arduinoStop areson aresonk atone atonek atonex autocorr babo balance balance2 bamboo barmodel bbcutm bbcuts betarand bexprnd bformdec1 bformdec2 bformenc1 binit biquad biquada birnd bob bpf bpfcos bqrez butbp butbr buthp butlp butterbp butterbr butterhp butterlp button buzz c2r cabasa cauchy cauchyi cbrt ceil cell cent centroid ceps cepsinv chanctrl changed changed2 chani chano chebyshevpoly checkbox chn_S chn_a chn_k chnclear chnexport chnget chngeta chngeti chngetk chngetks chngets chnmix chnparams chnset chnseta chnseti chnsetk chnsetks chnsets chuap clear clfilt clip clockoff clockon cmp cmplxprod cntCreate cntCycles cntDelete cntDelete_i cntRead cntReset cntState comb combinv compilecsd compileorc compilestr compress compress2 connect control convle convolve copya2ftab copyf2array cos cosh cosinv cosseg cossegb cossegr count count_i cps2pch cpsmidi cpsmidib cpsmidinn cpsoct cpspch cpstmid cpstun cpstuni cpsxpch cpumeter cpuprc cross2 crossfm crossfmi crossfmpm crossfmpmi crosspm crosspmi crunch ctlchn ctrl14 ctrl21 ctrl7 ctrlinit ctrlpreset ctrlprint ctrlprintpresets ctrlsave ctrlselect cuserrnd dam date dates db dbamp dbfsamp dcblock dcblock2 dconv dct dctinv deinterleave delay delay1 delayk delayr delayw deltap deltap3 deltapi deltapn deltapx deltapxw denorm diff diode_ladder directory diskgrain diskin diskin2 dispfft display distort distort1 divz doppler dot downsamp dripwater dssiactivate dssiaudio dssictls dssiinit dssilist dumpk dumpk2 dumpk3 dumpk4 duserrnd dust dust2 elapsedcycles elapsedtime envlpx envlpxr ephasor eqfil evalstr event event_i eventcycles eventtime exciter exitnow exp expcurve expon exprand exprandi expseg expsega expsegb expsegba expsegr fareylen fareyleni faustaudio faustcompile faustctl faustdsp faustgen faustplay fft fftinv ficlose filebit filelen filenchnls filepeak filescal filesr filevalid fillarray filter2 fin fini fink fiopen flanger flashtxt flooper flooper2 floor fluidAllOut fluidCCi fluidCCk fluidControl fluidEngine fluidInfo fluidLoad fluidNote fluidOut fluidProgramSelect fluidSetInterpMethod fmanal fmax fmb3 fmbell fmin fmmetal fmod fmpercfl fmrhode fmvoice fmwurlie fof fof2 fofilter fog fold follow follow2 foscil foscili fout fouti foutir foutk fprintks fprints frac fractalnoise framebuffer freeverb ftaudio ftchnls ftconv ftcps ftexists ftfree ftgen ftgenonce ftgentmp ftlen ftload ftloadk ftlptim ftmorf ftom ftprint ftresize ftresizei ftsamplebank ftsave ftsavek ftset ftslice ftslicei ftsr gain gainslider gauss gaussi gausstrig gbuzz genarray genarray_i gendy gendyc gendyx getcfg getcol getftargs getrow getseed gogobel grain grain2 grain3 granule gtadsr gtf guiro harmon harmon2 harmon3 harmon4 hdf5read hdf5write hilbert hilbert2 hrtfearly hrtfmove hrtfmove2 hrtfreverb hrtfstat hsboscil hvs1 hvs2 hvs3 hypot i ihold imagecreate imagefree imagegetpixel imageload imagesave imagesetpixel imagesize in in32 inch inh init initc14 initc21 initc7 inleta inletf inletk inletkid inletv ino inq inrg ins insglobal insremot int integ interleave interp invalue inx inz jacktransport jitter jitter2 joystick jspline k la_i_add_mc la_i_add_mr la_i_add_vc la_i_add_vr la_i_assign_mc la_i_assign_mr la_i_assign_t la_i_assign_vc la_i_assign_vr la_i_conjugate_mc la_i_conjugate_mr la_i_conjugate_vc la_i_conjugate_vr la_i_distance_vc la_i_distance_vr la_i_divide_mc la_i_divide_mr la_i_divide_vc la_i_divide_vr la_i_dot_mc la_i_dot_mc_vc la_i_dot_mr la_i_dot_mr_vr la_i_dot_vc la_i_dot_vr la_i_get_mc la_i_get_mr la_i_get_vc la_i_get_vr la_i_invert_mc la_i_invert_mr la_i_lower_solve_mc la_i_lower_solve_mr la_i_lu_det_mc la_i_lu_det_mr la_i_lu_factor_mc la_i_lu_factor_mr la_i_lu_solve_mc la_i_lu_solve_mr la_i_mc_create la_i_mc_set la_i_mr_create la_i_mr_set la_i_multiply_mc la_i_multiply_mr la_i_multiply_vc la_i_multiply_vr la_i_norm1_mc la_i_norm1_mr la_i_norm1_vc la_i_norm1_vr la_i_norm_euclid_mc la_i_norm_euclid_mr la_i_norm_euclid_vc la_i_norm_euclid_vr la_i_norm_inf_mc la_i_norm_inf_mr la_i_norm_inf_vc la_i_norm_inf_vr la_i_norm_max_mc la_i_norm_max_mr la_i_print_mc la_i_print_mr la_i_print_vc la_i_print_vr la_i_qr_eigen_mc la_i_qr_eigen_mr la_i_qr_factor_mc la_i_qr_factor_mr la_i_qr_sym_eigen_mc la_i_qr_sym_eigen_mr la_i_random_mc la_i_random_mr la_i_random_vc la_i_random_vr la_i_size_mc la_i_size_mr la_i_size_vc la_i_size_vr la_i_subtract_mc la_i_subtract_mr la_i_subtract_vc la_i_subtract_vr la_i_t_assign la_i_trace_mc la_i_trace_mr la_i_transpose_mc la_i_transpose_mr la_i_upper_solve_mc la_i_upper_solve_mr la_i_vc_create la_i_vc_set la_i_vr_create la_i_vr_set la_k_a_assign la_k_add_mc la_k_add_mr la_k_add_vc la_k_add_vr la_k_assign_a la_k_assign_f la_k_assign_mc la_k_assign_mr la_k_assign_t la_k_assign_vc la_k_assign_vr la_k_conjugate_mc la_k_conjugate_mr la_k_conjugate_vc la_k_conjugate_vr la_k_current_f la_k_current_vr la_k_distance_vc la_k_distance_vr la_k_divide_mc la_k_divide_mr la_k_divide_vc la_k_divide_vr la_k_dot_mc la_k_dot_mc_vc la_k_dot_mr la_k_dot_mr_vr la_k_dot_vc la_k_dot_vr la_k_f_assign la_k_get_mc la_k_get_mr la_k_get_vc la_k_get_vr la_k_invert_mc la_k_invert_mr la_k_lower_solve_mc la_k_lower_solve_mr la_k_lu_det_mc la_k_lu_det_mr la_k_lu_factor_mc la_k_lu_factor_mr la_k_lu_solve_mc la_k_lu_solve_mr la_k_mc_set la_k_mr_set la_k_multiply_mc la_k_multiply_mr la_k_multiply_vc la_k_multiply_vr la_k_norm1_mc la_k_norm1_mr la_k_norm1_vc la_k_norm1_vr la_k_norm_euclid_mc la_k_norm_euclid_mr la_k_norm_euclid_vc la_k_norm_euclid_vr la_k_norm_inf_mc la_k_norm_inf_mr la_k_norm_inf_vc la_k_norm_inf_vr la_k_norm_max_mc la_k_norm_max_mr la_k_qr_eigen_mc la_k_qr_eigen_mr la_k_qr_factor_mc la_k_qr_factor_mr la_k_qr_sym_eigen_mc la_k_qr_sym_eigen_mr la_k_random_mc la_k_random_mr la_k_random_vc la_k_random_vr la_k_subtract_mc la_k_subtract_mr la_k_subtract_vc la_k_subtract_vr la_k_t_assign la_k_trace_mc la_k_trace_mr la_k_upper_solve_mc la_k_upper_solve_mr la_k_vc_set la_k_vr_set lag lagud lastcycle lenarray lfo lfsr limit limit1 lincos line linen linenr lineto link_beat_force link_beat_get link_beat_request link_create link_enable link_is_enabled link_metro link_peers link_tempo_get link_tempo_set linlin linrand linseg linsegb linsegr liveconv locsend locsig log log10 log2 logbtwo logcurve loopseg loopsegp looptseg loopxseg lorenz loscil loscil3 loscil3phs loscilphs loscilx lowpass2 lowres lowresx lpcanal lpcfilter lpf18 lpform lpfreson lphasor lpinterp lposcil lposcil3 lposcila lposcilsa lposcilsa2 lpread lpreson lpshold lpsholdp lpslot lufs mac maca madsr mags mandel mandol maparray maparray_i marimba massign max max_k maxabs maxabsaccum maxaccum maxalloc maxarray mclock mdelay median mediank metro metro2 metrobpm mfb midglobal midiarp midic14 midic21 midic7 midichannelaftertouch midichn midicontrolchange midictrl mididefault midifilestatus midiin midinoteoff midinoteoncps midinoteonkey midinoteonoct midinoteonpch midion midion2 midiout midiout_i midipgm midipitchbend midipolyaftertouch midiprogramchange miditempo midremot min minabs minabsaccum minaccum minarray mincer mirror mode modmatrix monitor moog moogladder moogladder2 moogvcf moogvcf2 moscil mp3bitrate mp3in mp3len mp3nchnls mp3out mp3scal mp3sr mpulse mrtmsg ms2st mtof mton multitap mute mvchpf mvclpf1 mvclpf2 mvclpf3 mvclpf4 mvmfilter mxadsr nchnls_hw nestedap nlalp nlfilt nlfilt2 noise noteoff noteon noteondur noteondur2 notnum nreverb nrpn nsamp nstance nstrnum nstrstr ntof ntom ntrpol nxtpow2 octave octcps octmidi octmidib octmidinn octpch olabuffer oscbnk oscil oscil1 oscil1i oscil3 oscili oscilikt osciliktp oscilikts osciln oscils oscilx out out32 outall outc outch outh outiat outic outic14 outipat outipb outipc outkat outkc outkc14 outkpat outkpb outkpc outleta outletf outletk outletkid outletv outo outq outq1 outq2 outq3 outq4 outrg outs outs1 outs2 outvalue outx outz p p5gconnect p5gdata pan pan2 pareq part2txt partials partikkel partikkelget partikkelset partikkelsync passign paulstretch pcauchy pchbend pchmidi pchmidib pchmidinn pchoct pchtom pconvolve pcount pdclip pdhalf pdhalfy peak pgmassign pgmchn phaser1 phaser2 phasor phasorbnk phs pindex pinker pinkish pitch pitchac pitchamdf planet platerev plltrack pluck poisson pol2rect polyaft polynomial port portk poscil poscil3 pow powershape powoftwo pows prealloc prepiano print print_type printarray printf printf_i printk printk2 printks printks2 println prints printsk product pset ptablew ptrack puts pvadd pvbufread pvcross pvinterp pvoc pvread pvs2array pvs2tab pvsadsyn pvsanal pvsarp pvsbandp pvsbandr pvsbandwidth pvsbin pvsblur pvsbuffer pvsbufread pvsbufread2 pvscale pvscent pvsceps pvscfs pvscross pvsdemix pvsdiskin pvsdisp pvsenvftw pvsfilter pvsfread pvsfreeze pvsfromarray pvsftr pvsftw pvsfwrite pvsgain pvsgendy pvshift pvsifd pvsin pvsinfo pvsinit pvslock pvslpc pvsmaska pvsmix pvsmooth pvsmorph pvsosc pvsout pvspitch pvstanal pvstencil pvstrace pvsvoc pvswarp pvsynth pwd pyassign pyassigni pyassignt pycall pycall1 pycall1i pycall1t pycall2 pycall2i pycall2t pycall3 pycall3i pycall3t pycall4 pycall4i pycall4t pycall5 pycall5i pycall5t pycall6 pycall6i pycall6t pycall7 pycall7i pycall7t pycall8 pycall8i pycall8t pycalli pycalln pycallni pycallt pyeval pyevali pyevalt pyexec pyexeci pyexect pyinit pylassign pylassigni pylassignt pylcall pylcall1 pylcall1i pylcall1t pylcall2 pylcall2i pylcall2t pylcall3 pylcall3i pylcall3t pylcall4 pylcall4i pylcall4t pylcall5 pylcall5i pylcall5t pylcall6 pylcall6i pylcall6t pylcall7 pylcall7i pylcall7t pylcall8 pylcall8i pylcall8t pylcalli pylcalln pylcallni pylcallt pyleval pylevali pylevalt pylexec pylexeci pylexect pylrun pylruni pylrunt pyrun pyruni pyrunt qinf qnan r2c rand randc randh randi random randomh randomi rbjeq readclock readf readfi readk readk2 readk3 readk4 readks readscore readscratch rect2pol release remoteport remove repluck reshapearray reson resonbnk resonk resonr resonx resonxk resony resonz resyn reverb reverb2 reverbsc rewindscore rezzy rfft rifft rms rnd rnd31 rndseed round rspline rtclock s16b14 s32b14 samphold sandpaper sc_lag sc_lagud sc_phasor sc_trig scale scale2 scalearray scanhammer scanmap scans scansmap scantable scanu scanu2 schedkwhen schedkwhennamed schedule schedulek schedwhen scoreline scoreline_i seed sekere select semitone sense sensekey seqtime seqtime2 sequ sequstate serialBegin serialEnd serialFlush serialPrint serialRead serialWrite serialWrite_i setcol setctrl setksmps setrow setscorepos sfilist sfinstr sfinstr3 sfinstr3m sfinstrm sfload sflooper sfpassign sfplay sfplay3 sfplay3m sfplaym sfplist sfpreset shaker shiftin shiftout signum sin sinh sininv sinsyn skf sleighbells slicearray slicearray_i slider16 slider16f slider16table slider16tablef slider32 slider32f slider32table slider32tablef slider64 slider64f slider64table slider64tablef slider8 slider8f slider8table slider8tablef sliderKawai sndloop sndwarp sndwarpst sockrecv sockrecvs socksend socksends sorta sortd soundin space spat3d spat3di spat3dt spdist spf splitrig sprintf sprintfk spsend sqrt squinewave st2ms statevar sterrain stix strcat strcatk strchar strchark strcmp strcmpk strcpy strcpyk strecv streson strfromurl strget strindex strindexk string2array strlen strlenk strlower strlowerk strrindex strrindexk strset strstrip strsub strsubk strtod strtodk strtol strtolk strupper strupperk stsend subinstr subinstrinit sum sumarray svfilter svn syncgrain syncloop syncphasor system system_i tab tab2array tab2pvs tab_i tabifd table table3 table3kt tablecopy tablefilter tablefilteri tablegpw tablei tableicopy tableigpw tableikt tableimix tablekt tablemix tableng tablera tableseg tableshuffle tableshufflei tablew tablewa tablewkt tablexkt tablexseg tabmorph tabmorpha tabmorphak tabmorphi tabplay tabrec tabsum tabw tabw_i tambourine tan tanh taninv taninv2 tbvcf tempest tempo temposcal tempoval timedseq timeinstk timeinsts timek times tival tlineto tone tonek tonex tradsyn trandom transeg transegb transegr trcross trfilter trhighest trigExpseg trigLinseg trigexpseg trigger trighold triglinseg trigphasor trigseq trim trim_i trirand trlowest trmix trscale trshift trsplit turnoff turnoff2 turnoff2_i turnoff3 turnon tvconv unirand unwrap upsamp urandom urd vactrol vadd vadd_i vaddv vaddv_i vaget valpass vaset vbap vbapg vbapgmove vbaplsinit vbapmove vbapz vbapzmove vcella vclpf vco vco2 vco2ft vco2ift vco2init vcomb vcopy vcopy_i vdel_k vdelay vdelay3 vdelayk vdelayx vdelayxq vdelayxs vdelayxw vdelayxwq vdelayxws vdivv vdivv_i vecdelay veloc vexp vexp_i vexpseg vexpv vexpv_i vibes vibr vibrato vincr vlimit vlinseg vlowres vmap vmirror vmult vmult_i vmultv vmultv_i voice vosim vphaseseg vport vpow vpow_i vpowv vpowv_i vps vpvoc vrandh vrandi vsubv vsubv_i vtaba vtabi vtabk vtable1k vtablea vtablei vtablek vtablewa vtablewi vtablewk vtabwa vtabwi vtabwk vwrap waveset websocket weibull wgbow wgbowedbar wgbrass wgclar wgflute wgpluck wgpluck2 wguide1 wguide2 wiiconnect wiidata wiirange wiisend window wrap writescratch wterrain wterrain2 xadsr xin xout xtratim xyscale zacl zakinit zamod zar zarg zaw zawm zdf_1pole zdf_1pole_mode zdf_2pole zdf_2pole_mode zdf_ladder zfilter2 zir ziw ziwm zkcl zkmod zkr zkw zkwm '''.split()) DEPRECATED_OPCODES = set(''' array bformdec bformenc copy2ftab copy2ttab hrtfer ktableseg lentab maxtab mintab pop pop_f ptable ptable3 ptablei ptableiw push push_f scalet sndload soundout soundouts specaddm specdiff specdisp specfilt spechist specptrk specscal specsum spectrum stack sumtab tabgen tableiw tabmap tabmap_i tabslice tb0 tb0_init tb1 tb10 tb10_init tb11 tb11_init tb12 tb12_init tb13 tb13_init tb14 tb14_init tb15 tb15_init tb1_init tb2 tb2_init tb3 tb3_init tb4 tb4_init tb5 tb5_init tb6 tb6_init tb7 tb7_init tb8 tb8_init tb9 tb9_init vbap16 vbap4 vbap4move vbap8 vbap8move xscanmap xscans xscansmap xscanu xyin '''.split())
18,414
Python
9.339697
124
0.809113
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/wcwidth/wcwidth.py
""" This is a python implementation of wcwidth() and wcswidth(). https://github.com/jquast/wcwidth from Markus Kuhn's C code, retrieved from: http://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c This is an implementation of wcwidth() and wcswidth() (defined in IEEE Std 1002.1-2001) for Unicode. http://www.opengroup.org/onlinepubs/007904975/functions/wcwidth.html http://www.opengroup.org/onlinepubs/007904975/functions/wcswidth.html In fixed-width output devices, Latin characters all occupy a single "cell" position of equal width, whereas ideographic CJK characters occupy two such cells. Interoperability between terminal-line applications and (teletype-style) character terminals using the UTF-8 encoding requires agreement on which character should advance the cursor by how many cell positions. No established formal standards exist at present on which Unicode character shall occupy how many cell positions on character terminals. These routines are a first attempt of defining such behavior based on simple rules applied to data provided by the Unicode Consortium. For some graphical characters, the Unicode standard explicitly defines a character-cell width via the definition of the East Asian FullWidth (F), Wide (W), Half-width (H), and Narrow (Na) classes. In all these cases, there is no ambiguity about which width a terminal shall use. For characters in the East Asian Ambiguous (A) class, the width choice depends purely on a preference of backward compatibility with either historic CJK or Western practice. Choosing single-width for these characters is easy to justify as the appropriate long-term solution, as the CJK practice of displaying these characters as double-width comes from historic implementation simplicity (8-bit encoded characters were displayed single-width and 16-bit ones double-width, even for Greek, Cyrillic, etc.) and not any typographic considerations. Much less clear is the choice of width for the Not East Asian (Neutral) class. Existing practice does not dictate a width for any of these characters. It would nevertheless make sense typographically to allocate two character cells to characters such as for instance EM SPACE or VOLUME INTEGRAL, which cannot be represented adequately with a single-width glyph. The following routines at present merely assign a single-cell width to all neutral characters, in the interest of simplicity. This is not entirely satisfactory and should be reconsidered before establishing a formal standard in this area. At the moment, the decision which Not East Asian (Neutral) characters should be represented by double-width glyphs cannot yet be answered by applying a simple rule from the Unicode database content. Setting up a proper standard for the behavior of UTF-8 character terminals will require a careful analysis not only of each Unicode character, but also of each presentation form, something the author of these routines has avoided to do so far. http://www.unicode.org/unicode/reports/tr11/ Latest version: http://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c """ from __future__ import division # std imports import os import sys import warnings # local from .table_wide import WIDE_EASTASIAN from .table_zero import ZERO_WIDTH from .unicode_versions import list_versions try: # std imports from functools import lru_cache except ImportError: # lru_cache was added in Python 3.2 # 3rd party from backports.functools_lru_cache import lru_cache # global cache _UNICODE_CMPTABLE = None _PY3 = (sys.version_info[0] >= 3) # NOTE: created by hand, there isn't anything identifiable other than # general Cf category code to identify these, and some characters in Cf # category code are of non-zero width. # Also includes some Cc, Mn, Zl, and Zp characters ZERO_WIDTH_CF = set([ 0, # Null (Cc) 0x034F, # Combining grapheme joiner (Mn) 0x200B, # Zero width space 0x200C, # Zero width non-joiner 0x200D, # Zero width joiner 0x200E, # Left-to-right mark 0x200F, # Right-to-left mark 0x2028, # Line separator (Zl) 0x2029, # Paragraph separator (Zp) 0x202A, # Left-to-right embedding 0x202B, # Right-to-left embedding 0x202C, # Pop directional formatting 0x202D, # Left-to-right override 0x202E, # Right-to-left override 0x2060, # Word joiner 0x2061, # Function application 0x2062, # Invisible times 0x2063, # Invisible separator ]) def _bisearch(ucs, table): """ Auxiliary function for binary search in interval table. :arg int ucs: Ordinal value of unicode character. :arg list table: List of starting and ending ranges of ordinal values, in form of ``[(start, end), ...]``. :rtype: int :returns: 1 if ordinal value ucs is found within lookup table, else 0. """ lbound = 0 ubound = len(table) - 1 if ucs < table[0][0] or ucs > table[ubound][1]: return 0 while ubound >= lbound: mid = (lbound + ubound) // 2 if ucs > table[mid][1]: lbound = mid + 1 elif ucs < table[mid][0]: ubound = mid - 1 else: return 1 return 0 @lru_cache(maxsize=1000) def wcwidth(wc, unicode_version='auto'): r""" Given one Unicode character, return its printable length on a terminal. :param str wc: A single Unicode character. :param str unicode_version: A Unicode version number, such as ``'6.0.0'``, the list of available version levels may be listed by pairing function :func:`list_versions`. Any version string may be specified without error -- the nearest matching version is selected. When ``latest`` (default), the highest Unicode version level is used. :return: The width, in cells, necessary to display the character of Unicode string character, ``wc``. Returns 0 if the ``wc`` argument has no printable effect on a terminal (such as NUL '\0'), -1 if ``wc`` is not printable, or has an indeterminate effect on the terminal, such as a control character. Otherwise, the number of column positions the character occupies on a graphic terminal (1 or 2) is returned. :rtype: int The following have a column width of -1: - C0 control characters (U+001 through U+01F). - C1 control characters and DEL (U+07F through U+0A0). The following have a column width of 0: - Non-spacing and enclosing combining characters (general category code Mn or Me in the Unicode database). - NULL (``U+0000``). - COMBINING GRAPHEME JOINER (``U+034F``). - ZERO WIDTH SPACE (``U+200B``) *through* RIGHT-TO-LEFT MARK (``U+200F``). - LINE SEPARATOR (``U+2028``) *and* PARAGRAPH SEPARATOR (``U+2029``). - LEFT-TO-RIGHT EMBEDDING (``U+202A``) *through* RIGHT-TO-LEFT OVERRIDE (``U+202E``). - WORD JOINER (``U+2060``) *through* INVISIBLE SEPARATOR (``U+2063``). The following have a column width of 1: - SOFT HYPHEN (``U+00AD``). - All remaining characters, including all printable ISO 8859-1 and WGL4 characters, Unicode control characters, etc. The following have a column width of 2: - Spacing characters in the East Asian Wide (W) or East Asian Full-width (F) category as defined in Unicode Technical Report #11 have a column width of 2. - Some kinds of Emoji or symbols. """ # NOTE: created by hand, there isn't anything identifiable other than # general Cf category code to identify these, and some characters in Cf # category code are of non-zero width. ucs = ord(wc) if ucs in ZERO_WIDTH_CF: return 0 # C0/C1 control characters if ucs < 32 or 0x07F <= ucs < 0x0A0: return -1 _unicode_version = _wcmatch_version(unicode_version) # combining characters with zero width if _bisearch(ucs, ZERO_WIDTH[_unicode_version]): return 0 # "Wide AastAsian" (and emojis) return 1 + _bisearch(ucs, WIDE_EASTASIAN[_unicode_version]) def wcswidth(pwcs, n=None, unicode_version='auto'): """ Given a unicode string, return its printable length on a terminal. :param str pwcs: Measure width of given unicode string. :param int n: When ``n`` is None (default), return the length of the entire string, otherwise width the first ``n`` characters specified. :param str unicode_version: An explicit definition of the unicode version level to use for determination, may be ``auto`` (default), which uses the Environment Variable, ``UNICODE_VERSION`` if defined, or the latest available unicode version, otherwise. :rtype: int :returns: The width, in cells, necessary to display the first ``n`` characters of the unicode string ``pwcs``. Returns ``-1`` if a non-printable character is encountered. """ # pylint: disable=C0103 # Invalid argument name "n" end = len(pwcs) if n is None else n idx = slice(0, end) width = 0 for char in pwcs[idx]: wcw = wcwidth(char, unicode_version) if wcw < 0: return -1 width += wcw return width @lru_cache(maxsize=128) def _wcversion_value(ver_string): """ Integer-mapped value of given dotted version string. :param str ver_string: Unicode version string, of form ``n.n.n``. :rtype: tuple(int) :returns: tuple of digit tuples, ``tuple(int, [...])``. """ retval = tuple(map(int, (ver_string.split('.')))) return retval @lru_cache(maxsize=8) def _wcmatch_version(given_version): """ Return nearest matching supported Unicode version level. If an exact match is not determined, the nearest lowest version level is returned after a warning is emitted. For example, given supported levels ``4.1.0`` and ``5.0.0``, and a version string of ``4.9.9``, then ``4.1.0`` is selected and returned: >>> _wcmatch_version('4.9.9') '4.1.0' >>> _wcmatch_version('8.0') '8.0.0' >>> _wcmatch_version('1') '4.1.0' :param str given_version: given version for compare, may be ``auto`` (default), to select Unicode Version from Environment Variable, ``UNICODE_VERSION``. If the environment variable is not set, then the latest is used. :rtype: str :returns: unicode string, or non-unicode ``str`` type for python 2 when given ``version`` is also type ``str``. """ # Design note: the choice to return the same type that is given certainly # complicates it for python 2 str-type, but allows us to define an api that # to use 'string-type', for unicode version level definitions, so all of our # example code works with all versions of python. That, along with the # string-to-numeric and comparisons of earliest, latest, matching, or # nearest, greatly complicates this function. _return_str = not _PY3 and isinstance(given_version, str) if _return_str: unicode_versions = [ucs.encode() for ucs in list_versions()] else: unicode_versions = list_versions() latest_version = unicode_versions[-1] if given_version in (u'auto', 'auto'): given_version = os.environ.get( 'UNICODE_VERSION', 'latest' if not _return_str else latest_version.encode()) if given_version in (u'latest', 'latest'): # default match, when given as 'latest', use the most latest unicode # version specification level supported. return latest_version if not _return_str else latest_version.encode() if given_version in unicode_versions: # exact match, downstream has specified an explicit matching version # matching any value of list_versions(). return given_version if not _return_str else given_version.encode() # The user's version is not supported by ours. We return the newest unicode # version level that we support below their given value. try: cmp_given = _wcversion_value(given_version) except ValueError: # submitted value raises ValueError in int(), warn and use latest. warnings.warn("UNICODE_VERSION value, {given_version!r}, is invalid. " "Value should be in form of `integer[.]+', the latest " "supported unicode version {latest_version!r} has been " "inferred.".format(given_version=given_version, latest_version=latest_version)) return latest_version if not _return_str else latest_version.encode() # given version is less than any available version, return earliest # version. earliest_version = unicode_versions[0] cmp_earliest_version = _wcversion_value(earliest_version) if cmp_given <= cmp_earliest_version: # this probably isn't what you wanted, the oldest wcwidth.c you will # find in the wild is likely version 5 or 6, which we both support, # but it's better than not saying anything at all. warnings.warn("UNICODE_VERSION value, {given_version!r}, is lower " "than any available unicode version. Returning lowest " "version level, {earliest_version!r}".format( given_version=given_version, earliest_version=earliest_version)) return earliest_version if not _return_str else earliest_version.encode() # create list of versions which are less than our equal to given version, # and return the tail value, which is the highest level we may support, # or the latest value we support, when completely unmatched or higher # than any supported version. # # function will never complete, always returns. for idx, unicode_version in enumerate(unicode_versions): # look ahead to next value try: cmp_next_version = _wcversion_value(unicode_versions[idx + 1]) except IndexError: # at end of list, return latest version return latest_version if not _return_str else latest_version.encode() # Maybe our given version has less parts, as in tuple(8, 0), than the # next compare version tuple(8, 0, 0). Test for an exact match by # comparison of only the leading dotted piece(s): (8, 0) == (8, 0). if cmp_given == cmp_next_version[:len(cmp_given)]: return unicode_versions[idx + 1] # Or, if any next value is greater than our given support level # version, return the current value in index. Even though it must # be less than the given value, its our closest possible match. That # is, 4.1 is returned for given 4.9.9, where 4.1 and 5.0 are available. if cmp_next_version > cmp_given: return unicode_version assert False, ("Code path unreachable", given_version, unicode_versions)
14,942
Python
38.427441
81
0.67849
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/wcwidth/__init__.py
""" wcwidth module. https://github.com/jquast/wcwidth """ # re-export all functions & definitions, even private ones, from top-level # module path, to allow for 'from wcwidth import _private_func'. Of course, # user beware that any _private function may disappear or change signature at # any future version. # local from .wcwidth import ZERO_WIDTH # noqa from .wcwidth import (WIDE_EASTASIAN, wcwidth, wcswidth, _bisearch, list_versions, _wcmatch_version, _wcversion_value) # The __all__ attribute defines the items exported from statement, # 'from wcwidth import *', but also to say, "This is the public API". __all__ = ('wcwidth', 'wcswidth', 'list_versions') # We also used pkg_resources to load unicode version tables from version.json, # generated by bin/update-tables.py, but some environments are unable to # import pkg_resources for one reason or another, yikes! __version__ = '0.2.6'
1,032
Python
34.620688
78
0.643411
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/wcwidth/table_zero.py
""" Exports ZERO_WIDTH table keyed by supporting unicode version level. This code generated by wcwidth/bin/update-tables.py on 2023-01-14 03:25:41 UTC. """ ZERO_WIDTH = { '4.1.0': ( # Source: DerivedGeneralCategory-4.1.0.txt # Date: 2005-02-26, 02:35:50 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00486,), # Combining Cyrillic Titlo..Combining Cyrillic Psili (0x00488, 0x00489,), # Combining Cyrillic Hundr..Combining Cyrillic Milli (0x00591, 0x005b9,), # Hebrew Accent Etnahta ..Hebrew Point Holam (0x005bb, 0x005bd,), # Hebrew Point Qubuts ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x00615,), # Arabic Sign Sallallahou ..Arabic Small High Tah (0x0064b, 0x0065e,), # Arabic Fathatan ..Arabic Fatha With Two Do (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006de, 0x006e4,), # Arabic Start Of Rub El H..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x00901, 0x00902,), # Devanagari Sign Candrabi..Devanagari Sign Anusvara (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00954,), # Devanagari Stress Sign U..Devanagari Acute Accent (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b43,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00d41, 0x00d43,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f90, 0x00f97,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01032,), # Myanmar Vowel Sign Ai (0x01036, 0x01037,), # Myanmar Sign Anusvara ..Myanmar Sign Dot Below (0x01039, 0x01039,), # Myanmar Sign Virama (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0135f, 0x0135f,), # Ethiopic Combining Gemination Mark (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01dc0, 0x01dc3,), # Combining Dotted Grave A..Combining Suspension Mar (0x020d0, 0x020eb,), # Combining Left Harpoon A..Combining Long Double So (0x0302a, 0x0302f,), # Ideographic Level Tone M..Hangul Double Dot Tone M (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe23,), # Combining Ligature Left ..Combining Double Tilde R (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '5.0.0': ( # Source: DerivedGeneralCategory-5.0.0.txt # Date: 2006-02-27, 23:41:27 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00486,), # Combining Cyrillic Titlo..Combining Cyrillic Psili (0x00488, 0x00489,), # Combining Cyrillic Hundr..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x00615,), # Arabic Sign Sallallahou ..Arabic Small High Tah (0x0064b, 0x0065e,), # Arabic Fathatan ..Arabic Fatha With Two Do (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006de, 0x006e4,), # Arabic Start Of Rub El H..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00901, 0x00902,), # Devanagari Sign Candrabi..Devanagari Sign Anusvara (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00954,), # Devanagari Stress Sign U..Devanagari Acute Accent (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b43,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d43,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f90, 0x00f97,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01032,), # Myanmar Vowel Sign Ai (0x01036, 0x01037,), # Myanmar Sign Anusvara ..Myanmar Sign Dot Below (0x01039, 0x01039,), # Myanmar Sign Virama (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0135f, 0x0135f,), # Ethiopic Combining Gemination Mark (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01dc0, 0x01dca,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfe, 0x01dff,), # Combining Left Arrowhead..Combining Right Arrowhea (0x020d0, 0x020ef,), # Combining Left Harpoon A..Combining Right Arrow Be (0x0302a, 0x0302f,), # Ideographic Level Tone M..Hangul Double Dot Tone M (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe23,), # Combining Ligature Left ..Combining Double Tilde R (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '5.1.0': ( # Source: DerivedGeneralCategory-5.1.0.txt # Date: 2008-03-20, 17:54:57 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065e,), # Arabic Fathatan ..Arabic Fatha With Two Do (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006de, 0x006e4,), # Arabic Start Of Rub El H..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00901, 0x00902,), # Devanagari Sign Candrabi..Devanagari Sign Anusvara (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00954,), # Devanagari Stress Sign U..Devanagari Acute Accent (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f90, 0x00f97,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0135f, 0x0135f,), # Ethiopic Combining Gemination Mark (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfe, 0x01dff,), # Combining Left Arrowhead..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302f,), # Ideographic Level Tone M..Hangul Double Dot Tone M (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a67c, 0x0a67d,), # Combining Cyrillic Kavyk..Combining Cyrillic Payer (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '5.2.0': ( # Source: DerivedGeneralCategory-5.2.0.txt # Date: 2009-08-22, 04:58:21 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065e,), # Arabic Fathatan ..Arabic Fatha With Two Do (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006de, 0x006e4,), # Arabic Start Of Rub El H..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00900, 0x00902,), # Devanagari Sign Inverted..Devanagari Sign Anusvara (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00955,), # Devanagari Stress Sign U..Devanagari Vowel Sign Ca (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f90, 0x00f97,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135f, 0x0135f,), # Ethiopic Combining Gemination Mark (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfd, 0x01dff,), # Combining Almost Equal T..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302f,), # Ideographic Level Tone M..Hangul Double Dot Tone M (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a67c, 0x0a67d,), # Combining Cyrillic Kavyk..Combining Cyrillic Payer (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x11080, 0x11081,), # Kaithi Sign Candrabindu ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '6.0.0': ( # Source: DerivedGeneralCategory-6.0.0.txt # Date: 2010-08-19, 00:48:09 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x00900, 0x00902,), # Devanagari Sign Inverted..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302f,), # Ideographic Level Tone M..Hangul Double Dot Tone M (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a67c, 0x0a67d,), # Combining Cyrillic Kavyk..Combining Cyrillic Payer (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11080, 0x11081,), # Kaithi Sign Candrabindu ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '6.1.0': ( # Source: DerivedGeneralCategory-6.1.0.txt # Date: 2011-11-27, 05:10:22 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008e4, 0x008fe,), # Arabic Curly Fatha ..Arabic Damma With Dot (0x00900, 0x00902,), # Devanagari Sign Inverted..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bab,), # Sundanese Sign Virama (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69f, 0x0a69f,), # Combining Cyrillic Letter Iotified E (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11080, 0x11081,), # Kaithi Sign Candrabindu ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '6.2.0': ( # Source: DerivedGeneralCategory-6.2.0.txt # Date: 2012-05-20, 00:42:34 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008e4, 0x008fe,), # Arabic Curly Fatha ..Arabic Damma With Dot (0x00900, 0x00902,), # Devanagari Sign Inverted..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bab,), # Sundanese Sign Virama (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69f, 0x0a69f,), # Combining Cyrillic Letter Iotified E (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11080, 0x11081,), # Kaithi Sign Candrabindu ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '6.3.0': ( # Source: DerivedGeneralCategory-6.3.0.txt # Date: 2013-07-05, 14:08:45 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008e4, 0x008fe,), # Arabic Curly Fatha ..Arabic Damma With Dot (0x00900, 0x00902,), # Devanagari Sign Inverted..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bab,), # Sundanese Sign Virama (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01dc0, 0x01de6,), # Combining Dotted Grave A..Combining Latin Small Le (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69f, 0x0a69f,), # Combining Cyrillic Letter Iotified E (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe26,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11080, 0x11081,), # Kaithi Sign Candrabindu ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '7.0.0': ( # Source: DerivedGeneralCategory-7.0.0.txt # Date: 2014-02-07, 18:42:12 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008e4, 0x00902,), # Arabic Curly Fatha ..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d01, 0x00d01,), # Malayalam Sign Candrabindu (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df5,), # Combining Dotted Grave A..Combining Up Tack Above (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69f, 0x0a69f,), # Combining Cyrillic Letter Iotified E (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2d,), # Combining Ligature Left ..Combining Conjoining Mac (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11301, 0x11301,), # Grantha Sign Candrabindu (0x1133c, 0x1133c,), # Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '8.0.0': ( # Source: DerivedGeneralCategory-8.0.0.txt # Date: 2015-02-13, 13:47:11 GMT [MD] # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d01, 0x00d01,), # Malayalam Sign Candrabindu (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df5,), # Combining Dotted Grave A..Combining Up Tack Above (0x01dfc, 0x01dff,), # Combining Double Inverte..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c4,), # Saurashtra Sign Virama (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111ca, 0x111cc,), # Sharada Sign Nukta ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133c, 0x1133c,), # Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '9.0.0': ( # Source: DerivedGeneralCategory-9.0.0.txt # Date: 2016-06-01, 10:34:26 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d4, 0x008e1,), # Arabic Small High Word A..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d01, 0x00d01,), # Malayalam Sign Candrabindu (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df5,), # Combining Dotted Grave A..Combining Up Tack Above (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111ca, 0x111cc,), # Sharada Sign Nukta ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133c, 0x1133c,), # Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '10.0.0': ( # Source: DerivedGeneralCategory-10.0.0.txt # Date: 2017-03-08, 08:41:49 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d4, 0x008e1,), # Arabic Small High Word A..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df9,), # Combining Dotted Grave A..Combining Wide Inverted (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111ca, 0x111cc,), # Sharada Sign Nukta ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133c, 0x1133c,), # Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x11a01, 0x11a06,), # Zanabazar Square Vowel S..Zanabazar Square Vowel S (0x11a09, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '11.0.0': ( # Source: DerivedGeneralCategory-11.0.0.txt # Date: 2018-02-21, 05:34:04 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d3, 0x008e1,), # Arabic Small Low Waw ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00eb9,), # Lao Vowel Sign I ..Lao Vowel Sign Uu (0x00ebb, 0x00ebc,), # Lao Vowel Sign Mai Kon ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df9,), # Combining Dotted Grave A..Combining Wide Inverted (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bc,), # Javanese Vowel Sign Pepet (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '12.0.0': ( # Source: DerivedGeneralCategory-12.0.0.txt # Date: 2019-01-22, 08:18:28 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d3, 0x008e1,), # Arabic Small Low Waw ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00ebc,), # Lao Vowel Sign I ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df9,), # Combining Dotted Grave A..Combining Wide Inverted (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bd,), # Javanese Vowel Sign Pepe..Javanese Consonant Sign (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x119d4, 0x119d7,), # Nandinagari Vowel Sign U..Nandinagari Vowel Sign V (0x119da, 0x119db,), # Nandinagari Vowel Sign E..Nandinagari Vowel Sign A (0x119e0, 0x119e0,), # Nandinagari Sign Virama (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f4f, 0x16f4f,), # Miao Sign Consonant Modifier Bar (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e130, 0x1e136,), # Nyiakeng Puachue Hmong T..Nyiakeng Puachue Hmong T (0x1e2ec, 0x1e2ef,), # Wancho Tone Tup ..Wancho Tone Koini (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '12.1.0': ( # Source: DerivedGeneralCategory-12.1.0.txt # Date: 2019-03-10, 10:53:08 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d3, 0x008e1,), # Arabic Small Low Waw ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b56, 0x00b56,), # Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00ebc,), # Lao Vowel Sign I ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01abe,), # Combining Doubled Circum..Combining Parentheses Ov (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df9,), # Combining Dotted Grave A..Combining Wide Inverted (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bd,), # Javanese Vowel Sign Pepe..Javanese Consonant Sign (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x119d4, 0x119d7,), # Nandinagari Vowel Sign U..Nandinagari Vowel Sign V (0x119da, 0x119db,), # Nandinagari Vowel Sign E..Nandinagari Vowel Sign A (0x119e0, 0x119e0,), # Nandinagari Sign Virama (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f4f, 0x16f4f,), # Miao Sign Consonant Modifier Bar (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e130, 0x1e136,), # Nyiakeng Puachue Hmong T..Nyiakeng Puachue Hmong T (0x1e2ec, 0x1e2ef,), # Wancho Tone Tup ..Wancho Tone Koini (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '13.0.0': ( # Source: DerivedGeneralCategory-13.0.0.txt # Date: 2019-10-21, 14:30:32 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x008d3, 0x008e1,), # Arabic Small Low Waw ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b55, 0x00b56,), # Oriya Sign Overline ..Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00d81, 0x00d81,), # Sinhala Sign Candrabindu (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00ebc,), # Lao Vowel Sign I ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01734,), # Hanunoo Vowel Sign I ..Hanunoo Sign Pamudpod (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01ac0,), # Combining Doubled Circum..Combining Latin Small Le (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01df9,), # Combining Dotted Grave A..Combining Wide Inverted (0x01dfb, 0x01dff,), # Combining Deletion Mark ..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a82c, 0x0a82c,), # Syloti Nagri Sign Alternate Hasanta (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bd,), # Javanese Vowel Sign Pepe..Javanese Consonant Sign (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10eab, 0x10eac,), # Yezidi Combining Hamza M..Yezidi Combining Madda M (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x111cf, 0x111cf,), # Sharada Sign Inverted Candrabindu (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x1193b, 0x1193c,), # Dives Akuru Sign Anusvar..Dives Akuru Sign Candrab (0x1193e, 0x1193e,), # Dives Akuru Virama (0x11943, 0x11943,), # Dives Akuru Sign Nukta (0x119d4, 0x119d7,), # Nandinagari Vowel Sign U..Nandinagari Vowel Sign V (0x119da, 0x119db,), # Nandinagari Vowel Sign E..Nandinagari Vowel Sign A (0x119e0, 0x119e0,), # Nandinagari Sign Virama (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f4f, 0x16f4f,), # Miao Sign Consonant Modifier Bar (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x16fe4, 0x16fe4,), # Khitan Small Script Filler (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e130, 0x1e136,), # Nyiakeng Puachue Hmong T..Nyiakeng Puachue Hmong T (0x1e2ec, 0x1e2ef,), # Wancho Tone Tup ..Wancho Tone Koini (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '14.0.0': ( # Source: DerivedGeneralCategory-14.0.0.txt # Date: 2021-07-10, 00:35:08 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x00898, 0x0089f,), # Arabic Small High Word A..Arabic Half Madda Over M (0x008ca, 0x008e1,), # Arabic Small High Farsi ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b55, 0x00b56,), # Oriya Sign Overline ..Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3c, 0x00c3c,), # Telugu Sign Nukta (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00d81, 0x00d81,), # Sinhala Sign Candrabindu (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00ebc,), # Lao Vowel Sign I ..Lao Semivowel Sign Lo (0x00ec8, 0x00ecd,), # Lao Tone Mai Ek ..Lao Niggahita (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01733,), # Hanunoo Vowel Sign I ..Hanunoo Vowel Sign U (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x0180f, 0x0180f,), # Mongolian Free Variation Selector Four (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01ace,), # Combining Doubled Circum..Combining Latin Small Le (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01dff,), # Combining Dotted Grave A..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a82c, 0x0a82c,), # Syloti Nagri Sign Alternate Hasanta (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bd,), # Javanese Vowel Sign Pepe..Javanese Consonant Sign (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10eab, 0x10eac,), # Yezidi Combining Hamza M..Yezidi Combining Madda M (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x10f82, 0x10f85,), # Old Uyghur Combining Dot..Old Uyghur Combining Two (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11070, 0x11070,), # Brahmi Sign Old Tamil Virama (0x11073, 0x11074,), # Brahmi Vowel Sign Old Ta..Brahmi Vowel Sign Old Ta (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x110c2, 0x110c2,), # Kaithi Vowel Sign Vocalic R (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x111cf, 0x111cf,), # Sharada Sign Inverted Candrabindu (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x1193b, 0x1193c,), # Dives Akuru Sign Anusvar..Dives Akuru Sign Candrab (0x1193e, 0x1193e,), # Dives Akuru Virama (0x11943, 0x11943,), # Dives Akuru Sign Nukta (0x119d4, 0x119d7,), # Nandinagari Vowel Sign U..Nandinagari Vowel Sign V (0x119da, 0x119db,), # Nandinagari Vowel Sign E..Nandinagari Vowel Sign A (0x119e0, 0x119e0,), # Nandinagari Sign Virama (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f4f, 0x16f4f,), # Miao Sign Consonant Modifier Bar (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x16fe4, 0x16fe4,), # Khitan Small Script Filler (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1cf00, 0x1cf2d,), # Znamenny Combining Mark ..Znamenny Combining Mark (0x1cf30, 0x1cf46,), # Znamenny Combining Tonal..Znamenny Priznak Modifie (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e130, 0x1e136,), # Nyiakeng Puachue Hmong T..Nyiakeng Puachue Hmong T (0x1e2ae, 0x1e2ae,), # Toto Sign Rising Tone (0x1e2ec, 0x1e2ef,), # Wancho Tone Tup ..Wancho Tone Koini (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), '15.0.0': ( # Source: DerivedGeneralCategory-15.0.0.txt # Date: 2022-04-26, 23:14:35 GMT # (0x00300, 0x0036f,), # Combining Grave Accent ..Combining Latin Small Le (0x00483, 0x00489,), # Combining Cyrillic Titlo..Combining Cyrillic Milli (0x00591, 0x005bd,), # Hebrew Accent Etnahta ..Hebrew Point Meteg (0x005bf, 0x005bf,), # Hebrew Point Rafe (0x005c1, 0x005c2,), # Hebrew Point Shin Dot ..Hebrew Point Sin Dot (0x005c4, 0x005c5,), # Hebrew Mark Upper Dot ..Hebrew Mark Lower Dot (0x005c7, 0x005c7,), # Hebrew Point Qamats Qatan (0x00610, 0x0061a,), # Arabic Sign Sallallahou ..Arabic Small Kasra (0x0064b, 0x0065f,), # Arabic Fathatan ..Arabic Wavy Hamza Below (0x00670, 0x00670,), # Arabic Letter Superscript Alef (0x006d6, 0x006dc,), # Arabic Small High Ligatu..Arabic Small High Seen (0x006df, 0x006e4,), # Arabic Small High Rounde..Arabic Small High Madda (0x006e7, 0x006e8,), # Arabic Small High Yeh ..Arabic Small High Noon (0x006ea, 0x006ed,), # Arabic Empty Centre Low ..Arabic Small Low Meem (0x00711, 0x00711,), # Syriac Letter Superscript Alaph (0x00730, 0x0074a,), # Syriac Pthaha Above ..Syriac Barrekh (0x007a6, 0x007b0,), # Thaana Abafili ..Thaana Sukun (0x007eb, 0x007f3,), # Nko Combining Short High..Nko Combining Double Dot (0x007fd, 0x007fd,), # Nko Dantayalan (0x00816, 0x00819,), # Samaritan Mark In ..Samaritan Mark Dagesh (0x0081b, 0x00823,), # Samaritan Mark Epentheti..Samaritan Vowel Sign A (0x00825, 0x00827,), # Samaritan Vowel Sign Sho..Samaritan Vowel Sign U (0x00829, 0x0082d,), # Samaritan Vowel Sign Lon..Samaritan Mark Nequdaa (0x00859, 0x0085b,), # Mandaic Affrication Mark..Mandaic Gemination Mark (0x00898, 0x0089f,), # Arabic Small High Word A..Arabic Half Madda Over M (0x008ca, 0x008e1,), # Arabic Small High Farsi ..Arabic Small High Sign S (0x008e3, 0x00902,), # Arabic Turned Damma Belo..Devanagari Sign Anusvara (0x0093a, 0x0093a,), # Devanagari Vowel Sign Oe (0x0093c, 0x0093c,), # Devanagari Sign Nukta (0x00941, 0x00948,), # Devanagari Vowel Sign U ..Devanagari Vowel Sign Ai (0x0094d, 0x0094d,), # Devanagari Sign Virama (0x00951, 0x00957,), # Devanagari Stress Sign U..Devanagari Vowel Sign Uu (0x00962, 0x00963,), # Devanagari Vowel Sign Vo..Devanagari Vowel Sign Vo (0x00981, 0x00981,), # Bengali Sign Candrabindu (0x009bc, 0x009bc,), # Bengali Sign Nukta (0x009c1, 0x009c4,), # Bengali Vowel Sign U ..Bengali Vowel Sign Vocal (0x009cd, 0x009cd,), # Bengali Sign Virama (0x009e2, 0x009e3,), # Bengali Vowel Sign Vocal..Bengali Vowel Sign Vocal (0x009fe, 0x009fe,), # Bengali Sandhi Mark (0x00a01, 0x00a02,), # Gurmukhi Sign Adak Bindi..Gurmukhi Sign Bindi (0x00a3c, 0x00a3c,), # Gurmukhi Sign Nukta (0x00a41, 0x00a42,), # Gurmukhi Vowel Sign U ..Gurmukhi Vowel Sign Uu (0x00a47, 0x00a48,), # Gurmukhi Vowel Sign Ee ..Gurmukhi Vowel Sign Ai (0x00a4b, 0x00a4d,), # Gurmukhi Vowel Sign Oo ..Gurmukhi Sign Virama (0x00a51, 0x00a51,), # Gurmukhi Sign Udaat (0x00a70, 0x00a71,), # Gurmukhi Tippi ..Gurmukhi Addak (0x00a75, 0x00a75,), # Gurmukhi Sign Yakash (0x00a81, 0x00a82,), # Gujarati Sign Candrabind..Gujarati Sign Anusvara (0x00abc, 0x00abc,), # Gujarati Sign Nukta (0x00ac1, 0x00ac5,), # Gujarati Vowel Sign U ..Gujarati Vowel Sign Cand (0x00ac7, 0x00ac8,), # Gujarati Vowel Sign E ..Gujarati Vowel Sign Ai (0x00acd, 0x00acd,), # Gujarati Sign Virama (0x00ae2, 0x00ae3,), # Gujarati Vowel Sign Voca..Gujarati Vowel Sign Voca (0x00afa, 0x00aff,), # Gujarati Sign Sukun ..Gujarati Sign Two-circle (0x00b01, 0x00b01,), # Oriya Sign Candrabindu (0x00b3c, 0x00b3c,), # Oriya Sign Nukta (0x00b3f, 0x00b3f,), # Oriya Vowel Sign I (0x00b41, 0x00b44,), # Oriya Vowel Sign U ..Oriya Vowel Sign Vocalic (0x00b4d, 0x00b4d,), # Oriya Sign Virama (0x00b55, 0x00b56,), # Oriya Sign Overline ..Oriya Ai Length Mark (0x00b62, 0x00b63,), # Oriya Vowel Sign Vocalic..Oriya Vowel Sign Vocalic (0x00b82, 0x00b82,), # Tamil Sign Anusvara (0x00bc0, 0x00bc0,), # Tamil Vowel Sign Ii (0x00bcd, 0x00bcd,), # Tamil Sign Virama (0x00c00, 0x00c00,), # Telugu Sign Combining Candrabindu Above (0x00c04, 0x00c04,), # Telugu Sign Combining Anusvara Above (0x00c3c, 0x00c3c,), # Telugu Sign Nukta (0x00c3e, 0x00c40,), # Telugu Vowel Sign Aa ..Telugu Vowel Sign Ii (0x00c46, 0x00c48,), # Telugu Vowel Sign E ..Telugu Vowel Sign Ai (0x00c4a, 0x00c4d,), # Telugu Vowel Sign O ..Telugu Sign Virama (0x00c55, 0x00c56,), # Telugu Length Mark ..Telugu Ai Length Mark (0x00c62, 0x00c63,), # Telugu Vowel Sign Vocali..Telugu Vowel Sign Vocali (0x00c81, 0x00c81,), # Kannada Sign Candrabindu (0x00cbc, 0x00cbc,), # Kannada Sign Nukta (0x00cbf, 0x00cbf,), # Kannada Vowel Sign I (0x00cc6, 0x00cc6,), # Kannada Vowel Sign E (0x00ccc, 0x00ccd,), # Kannada Vowel Sign Au ..Kannada Sign Virama (0x00ce2, 0x00ce3,), # Kannada Vowel Sign Vocal..Kannada Vowel Sign Vocal (0x00d00, 0x00d01,), # Malayalam Sign Combining..Malayalam Sign Candrabin (0x00d3b, 0x00d3c,), # Malayalam Sign Vertical ..Malayalam Sign Circular (0x00d41, 0x00d44,), # Malayalam Vowel Sign U ..Malayalam Vowel Sign Voc (0x00d4d, 0x00d4d,), # Malayalam Sign Virama (0x00d62, 0x00d63,), # Malayalam Vowel Sign Voc..Malayalam Vowel Sign Voc (0x00d81, 0x00d81,), # Sinhala Sign Candrabindu (0x00dca, 0x00dca,), # Sinhala Sign Al-lakuna (0x00dd2, 0x00dd4,), # Sinhala Vowel Sign Ketti..Sinhala Vowel Sign Ketti (0x00dd6, 0x00dd6,), # Sinhala Vowel Sign Diga Paa-pilla (0x00e31, 0x00e31,), # Thai Character Mai Han-akat (0x00e34, 0x00e3a,), # Thai Character Sara I ..Thai Character Phinthu (0x00e47, 0x00e4e,), # Thai Character Maitaikhu..Thai Character Yamakkan (0x00eb1, 0x00eb1,), # Lao Vowel Sign Mai Kan (0x00eb4, 0x00ebc,), # Lao Vowel Sign I ..Lao Semivowel Sign Lo (0x00ec8, 0x00ece,), # Lao Tone Mai Ek ..(nil) (0x00f18, 0x00f19,), # Tibetan Astrological Sig..Tibetan Astrological Sig (0x00f35, 0x00f35,), # Tibetan Mark Ngas Bzung Nyi Zla (0x00f37, 0x00f37,), # Tibetan Mark Ngas Bzung Sgor Rtags (0x00f39, 0x00f39,), # Tibetan Mark Tsa -phru (0x00f71, 0x00f7e,), # Tibetan Vowel Sign Aa ..Tibetan Sign Rjes Su Nga (0x00f80, 0x00f84,), # Tibetan Vowel Sign Rever..Tibetan Mark Halanta (0x00f86, 0x00f87,), # Tibetan Sign Lci Rtags ..Tibetan Sign Yang Rtags (0x00f8d, 0x00f97,), # Tibetan Subjoined Sign L..Tibetan Subjoined Letter (0x00f99, 0x00fbc,), # Tibetan Subjoined Letter..Tibetan Subjoined Letter (0x00fc6, 0x00fc6,), # Tibetan Symbol Padma Gdan (0x0102d, 0x01030,), # Myanmar Vowel Sign I ..Myanmar Vowel Sign Uu (0x01032, 0x01037,), # Myanmar Vowel Sign Ai ..Myanmar Sign Dot Below (0x01039, 0x0103a,), # Myanmar Sign Virama ..Myanmar Sign Asat (0x0103d, 0x0103e,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01058, 0x01059,), # Myanmar Vowel Sign Vocal..Myanmar Vowel Sign Vocal (0x0105e, 0x01060,), # Myanmar Consonant Sign M..Myanmar Consonant Sign M (0x01071, 0x01074,), # Myanmar Vowel Sign Geba ..Myanmar Vowel Sign Kayah (0x01082, 0x01082,), # Myanmar Consonant Sign Shan Medial Wa (0x01085, 0x01086,), # Myanmar Vowel Sign Shan ..Myanmar Vowel Sign Shan (0x0108d, 0x0108d,), # Myanmar Sign Shan Council Emphatic Tone (0x0109d, 0x0109d,), # Myanmar Vowel Sign Aiton Ai (0x0135d, 0x0135f,), # Ethiopic Combining Gemin..Ethiopic Combining Gemin (0x01712, 0x01714,), # Tagalog Vowel Sign I ..Tagalog Sign Virama (0x01732, 0x01733,), # Hanunoo Vowel Sign I ..Hanunoo Vowel Sign U (0x01752, 0x01753,), # Buhid Vowel Sign I ..Buhid Vowel Sign U (0x01772, 0x01773,), # Tagbanwa Vowel Sign I ..Tagbanwa Vowel Sign U (0x017b4, 0x017b5,), # Khmer Vowel Inherent Aq ..Khmer Vowel Inherent Aa (0x017b7, 0x017bd,), # Khmer Vowel Sign I ..Khmer Vowel Sign Ua (0x017c6, 0x017c6,), # Khmer Sign Nikahit (0x017c9, 0x017d3,), # Khmer Sign Muusikatoan ..Khmer Sign Bathamasat (0x017dd, 0x017dd,), # Khmer Sign Atthacan (0x0180b, 0x0180d,), # Mongolian Free Variation..Mongolian Free Variation (0x0180f, 0x0180f,), # Mongolian Free Variation Selector Four (0x01885, 0x01886,), # Mongolian Letter Ali Gal..Mongolian Letter Ali Gal (0x018a9, 0x018a9,), # Mongolian Letter Ali Gali Dagalga (0x01920, 0x01922,), # Limbu Vowel Sign A ..Limbu Vowel Sign U (0x01927, 0x01928,), # Limbu Vowel Sign E ..Limbu Vowel Sign O (0x01932, 0x01932,), # Limbu Small Letter Anusvara (0x01939, 0x0193b,), # Limbu Sign Mukphreng ..Limbu Sign Sa-i (0x01a17, 0x01a18,), # Buginese Vowel Sign I ..Buginese Vowel Sign U (0x01a1b, 0x01a1b,), # Buginese Vowel Sign Ae (0x01a56, 0x01a56,), # Tai Tham Consonant Sign Medial La (0x01a58, 0x01a5e,), # Tai Tham Sign Mai Kang L..Tai Tham Consonant Sign (0x01a60, 0x01a60,), # Tai Tham Sign Sakot (0x01a62, 0x01a62,), # Tai Tham Vowel Sign Mai Sat (0x01a65, 0x01a6c,), # Tai Tham Vowel Sign I ..Tai Tham Vowel Sign Oa B (0x01a73, 0x01a7c,), # Tai Tham Vowel Sign Oa A..Tai Tham Sign Khuen-lue (0x01a7f, 0x01a7f,), # Tai Tham Combining Cryptogrammic Dot (0x01ab0, 0x01ace,), # Combining Doubled Circum..Combining Latin Small Le (0x01b00, 0x01b03,), # Balinese Sign Ulu Ricem ..Balinese Sign Surang (0x01b34, 0x01b34,), # Balinese Sign Rerekan (0x01b36, 0x01b3a,), # Balinese Vowel Sign Ulu ..Balinese Vowel Sign Ra R (0x01b3c, 0x01b3c,), # Balinese Vowel Sign La Lenga (0x01b42, 0x01b42,), # Balinese Vowel Sign Pepet (0x01b6b, 0x01b73,), # Balinese Musical Symbol ..Balinese Musical Symbol (0x01b80, 0x01b81,), # Sundanese Sign Panyecek ..Sundanese Sign Panglayar (0x01ba2, 0x01ba5,), # Sundanese Consonant Sign..Sundanese Vowel Sign Pan (0x01ba8, 0x01ba9,), # Sundanese Vowel Sign Pam..Sundanese Vowel Sign Pan (0x01bab, 0x01bad,), # Sundanese Sign Virama ..Sundanese Consonant Sign (0x01be6, 0x01be6,), # Batak Sign Tompi (0x01be8, 0x01be9,), # Batak Vowel Sign Pakpak ..Batak Vowel Sign Ee (0x01bed, 0x01bed,), # Batak Vowel Sign Karo O (0x01bef, 0x01bf1,), # Batak Vowel Sign U For S..Batak Consonant Sign H (0x01c2c, 0x01c33,), # Lepcha Vowel Sign E ..Lepcha Consonant Sign T (0x01c36, 0x01c37,), # Lepcha Sign Ran ..Lepcha Sign Nukta (0x01cd0, 0x01cd2,), # Vedic Tone Karshana ..Vedic Tone Prenkha (0x01cd4, 0x01ce0,), # Vedic Sign Yajurvedic Mi..Vedic Tone Rigvedic Kash (0x01ce2, 0x01ce8,), # Vedic Sign Visarga Svari..Vedic Sign Visarga Anuda (0x01ced, 0x01ced,), # Vedic Sign Tiryak (0x01cf4, 0x01cf4,), # Vedic Tone Candra Above (0x01cf8, 0x01cf9,), # Vedic Tone Ring Above ..Vedic Tone Double Ring A (0x01dc0, 0x01dff,), # Combining Dotted Grave A..Combining Right Arrowhea (0x020d0, 0x020f0,), # Combining Left Harpoon A..Combining Asterisk Above (0x02cef, 0x02cf1,), # Coptic Combining Ni Abov..Coptic Combining Spiritu (0x02d7f, 0x02d7f,), # Tifinagh Consonant Joiner (0x02de0, 0x02dff,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0302a, 0x0302d,), # Ideographic Level Tone M..Ideographic Entering Ton (0x03099, 0x0309a,), # Combining Katakana-hirag..Combining Katakana-hirag (0x0a66f, 0x0a672,), # Combining Cyrillic Vzmet..Combining Cyrillic Thous (0x0a674, 0x0a67d,), # Combining Cyrillic Lette..Combining Cyrillic Payer (0x0a69e, 0x0a69f,), # Combining Cyrillic Lette..Combining Cyrillic Lette (0x0a6f0, 0x0a6f1,), # Bamum Combining Mark Koq..Bamum Combining Mark Tuk (0x0a802, 0x0a802,), # Syloti Nagri Sign Dvisvara (0x0a806, 0x0a806,), # Syloti Nagri Sign Hasanta (0x0a80b, 0x0a80b,), # Syloti Nagri Sign Anusvara (0x0a825, 0x0a826,), # Syloti Nagri Vowel Sign ..Syloti Nagri Vowel Sign (0x0a82c, 0x0a82c,), # Syloti Nagri Sign Alternate Hasanta (0x0a8c4, 0x0a8c5,), # Saurashtra Sign Virama ..Saurashtra Sign Candrabi (0x0a8e0, 0x0a8f1,), # Combining Devanagari Dig..Combining Devanagari Sig (0x0a8ff, 0x0a8ff,), # Devanagari Vowel Sign Ay (0x0a926, 0x0a92d,), # Kayah Li Vowel Ue ..Kayah Li Tone Calya Plop (0x0a947, 0x0a951,), # Rejang Vowel Sign I ..Rejang Consonant Sign R (0x0a980, 0x0a982,), # Javanese Sign Panyangga ..Javanese Sign Layar (0x0a9b3, 0x0a9b3,), # Javanese Sign Cecak Telu (0x0a9b6, 0x0a9b9,), # Javanese Vowel Sign Wulu..Javanese Vowel Sign Suku (0x0a9bc, 0x0a9bd,), # Javanese Vowel Sign Pepe..Javanese Consonant Sign (0x0a9e5, 0x0a9e5,), # Myanmar Sign Shan Saw (0x0aa29, 0x0aa2e,), # Cham Vowel Sign Aa ..Cham Vowel Sign Oe (0x0aa31, 0x0aa32,), # Cham Vowel Sign Au ..Cham Vowel Sign Ue (0x0aa35, 0x0aa36,), # Cham Consonant Sign La ..Cham Consonant Sign Wa (0x0aa43, 0x0aa43,), # Cham Consonant Sign Final Ng (0x0aa4c, 0x0aa4c,), # Cham Consonant Sign Final M (0x0aa7c, 0x0aa7c,), # Myanmar Sign Tai Laing Tone-2 (0x0aab0, 0x0aab0,), # Tai Viet Mai Kang (0x0aab2, 0x0aab4,), # Tai Viet Vowel I ..Tai Viet Vowel U (0x0aab7, 0x0aab8,), # Tai Viet Mai Khit ..Tai Viet Vowel Ia (0x0aabe, 0x0aabf,), # Tai Viet Vowel Am ..Tai Viet Tone Mai Ek (0x0aac1, 0x0aac1,), # Tai Viet Tone Mai Tho (0x0aaec, 0x0aaed,), # Meetei Mayek Vowel Sign ..Meetei Mayek Vowel Sign (0x0aaf6, 0x0aaf6,), # Meetei Mayek Virama (0x0abe5, 0x0abe5,), # Meetei Mayek Vowel Sign Anap (0x0abe8, 0x0abe8,), # Meetei Mayek Vowel Sign Unap (0x0abed, 0x0abed,), # Meetei Mayek Apun Iyek (0x0fb1e, 0x0fb1e,), # Hebrew Point Judeo-spanish Varika (0x0fe00, 0x0fe0f,), # Variation Selector-1 ..Variation Selector-16 (0x0fe20, 0x0fe2f,), # Combining Ligature Left ..Combining Cyrillic Titlo (0x101fd, 0x101fd,), # Phaistos Disc Sign Combining Oblique Stroke (0x102e0, 0x102e0,), # Coptic Epact Thousands Mark (0x10376, 0x1037a,), # Combining Old Permic Let..Combining Old Permic Let (0x10a01, 0x10a03,), # Kharoshthi Vowel Sign I ..Kharoshthi Vowel Sign Vo (0x10a05, 0x10a06,), # Kharoshthi Vowel Sign E ..Kharoshthi Vowel Sign O (0x10a0c, 0x10a0f,), # Kharoshthi Vowel Length ..Kharoshthi Sign Visarga (0x10a38, 0x10a3a,), # Kharoshthi Sign Bar Abov..Kharoshthi Sign Dot Belo (0x10a3f, 0x10a3f,), # Kharoshthi Virama (0x10ae5, 0x10ae6,), # Manichaean Abbreviation ..Manichaean Abbreviation (0x10d24, 0x10d27,), # Hanifi Rohingya Sign Har..Hanifi Rohingya Sign Tas (0x10eab, 0x10eac,), # Yezidi Combining Hamza M..Yezidi Combining Madda M (0x10efd, 0x10eff,), # (nil) (0x10f46, 0x10f50,), # Sogdian Combining Dot Be..Sogdian Combining Stroke (0x10f82, 0x10f85,), # Old Uyghur Combining Dot..Old Uyghur Combining Two (0x11001, 0x11001,), # Brahmi Sign Anusvara (0x11038, 0x11046,), # Brahmi Vowel Sign Aa ..Brahmi Virama (0x11070, 0x11070,), # Brahmi Sign Old Tamil Virama (0x11073, 0x11074,), # Brahmi Vowel Sign Old Ta..Brahmi Vowel Sign Old Ta (0x1107f, 0x11081,), # Brahmi Number Joiner ..Kaithi Sign Anusvara (0x110b3, 0x110b6,), # Kaithi Vowel Sign U ..Kaithi Vowel Sign Ai (0x110b9, 0x110ba,), # Kaithi Sign Virama ..Kaithi Sign Nukta (0x110c2, 0x110c2,), # Kaithi Vowel Sign Vocalic R (0x11100, 0x11102,), # Chakma Sign Candrabindu ..Chakma Sign Visarga (0x11127, 0x1112b,), # Chakma Vowel Sign A ..Chakma Vowel Sign Uu (0x1112d, 0x11134,), # Chakma Vowel Sign Ai ..Chakma Maayyaa (0x11173, 0x11173,), # Mahajani Sign Nukta (0x11180, 0x11181,), # Sharada Sign Candrabindu..Sharada Sign Anusvara (0x111b6, 0x111be,), # Sharada Vowel Sign U ..Sharada Vowel Sign O (0x111c9, 0x111cc,), # Sharada Sandhi Mark ..Sharada Extra Short Vowe (0x111cf, 0x111cf,), # Sharada Sign Inverted Candrabindu (0x1122f, 0x11231,), # Khojki Vowel Sign U ..Khojki Vowel Sign Ai (0x11234, 0x11234,), # Khojki Sign Anusvara (0x11236, 0x11237,), # Khojki Sign Nukta ..Khojki Sign Shadda (0x1123e, 0x1123e,), # Khojki Sign Sukun (0x11241, 0x11241,), # (nil) (0x112df, 0x112df,), # Khudawadi Sign Anusvara (0x112e3, 0x112ea,), # Khudawadi Vowel Sign U ..Khudawadi Sign Virama (0x11300, 0x11301,), # Grantha Sign Combining A..Grantha Sign Candrabindu (0x1133b, 0x1133c,), # Combining Bindu Below ..Grantha Sign Nukta (0x11340, 0x11340,), # Grantha Vowel Sign Ii (0x11366, 0x1136c,), # Combining Grantha Digit ..Combining Grantha Digit (0x11370, 0x11374,), # Combining Grantha Letter..Combining Grantha Letter (0x11438, 0x1143f,), # Newa Vowel Sign U ..Newa Vowel Sign Ai (0x11442, 0x11444,), # Newa Sign Virama ..Newa Sign Anusvara (0x11446, 0x11446,), # Newa Sign Nukta (0x1145e, 0x1145e,), # Newa Sandhi Mark (0x114b3, 0x114b8,), # Tirhuta Vowel Sign U ..Tirhuta Vowel Sign Vocal (0x114ba, 0x114ba,), # Tirhuta Vowel Sign Short E (0x114bf, 0x114c0,), # Tirhuta Sign Candrabindu..Tirhuta Sign Anusvara (0x114c2, 0x114c3,), # Tirhuta Sign Virama ..Tirhuta Sign Nukta (0x115b2, 0x115b5,), # Siddham Vowel Sign U ..Siddham Vowel Sign Vocal (0x115bc, 0x115bd,), # Siddham Sign Candrabindu..Siddham Sign Anusvara (0x115bf, 0x115c0,), # Siddham Sign Virama ..Siddham Sign Nukta (0x115dc, 0x115dd,), # Siddham Vowel Sign Alter..Siddham Vowel Sign Alter (0x11633, 0x1163a,), # Modi Vowel Sign U ..Modi Vowel Sign Ai (0x1163d, 0x1163d,), # Modi Sign Anusvara (0x1163f, 0x11640,), # Modi Sign Virama ..Modi Sign Ardhacandra (0x116ab, 0x116ab,), # Takri Sign Anusvara (0x116ad, 0x116ad,), # Takri Vowel Sign Aa (0x116b0, 0x116b5,), # Takri Vowel Sign U ..Takri Vowel Sign Au (0x116b7, 0x116b7,), # Takri Sign Nukta (0x1171d, 0x1171f,), # Ahom Consonant Sign Medi..Ahom Consonant Sign Medi (0x11722, 0x11725,), # Ahom Vowel Sign I ..Ahom Vowel Sign Uu (0x11727, 0x1172b,), # Ahom Vowel Sign Aw ..Ahom Sign Killer (0x1182f, 0x11837,), # Dogra Vowel Sign U ..Dogra Sign Anusvara (0x11839, 0x1183a,), # Dogra Sign Virama ..Dogra Sign Nukta (0x1193b, 0x1193c,), # Dives Akuru Sign Anusvar..Dives Akuru Sign Candrab (0x1193e, 0x1193e,), # Dives Akuru Virama (0x11943, 0x11943,), # Dives Akuru Sign Nukta (0x119d4, 0x119d7,), # Nandinagari Vowel Sign U..Nandinagari Vowel Sign V (0x119da, 0x119db,), # Nandinagari Vowel Sign E..Nandinagari Vowel Sign A (0x119e0, 0x119e0,), # Nandinagari Sign Virama (0x11a01, 0x11a0a,), # Zanabazar Square Vowel S..Zanabazar Square Vowel L (0x11a33, 0x11a38,), # Zanabazar Square Final C..Zanabazar Square Sign An (0x11a3b, 0x11a3e,), # Zanabazar Square Cluster..Zanabazar Square Cluster (0x11a47, 0x11a47,), # Zanabazar Square Subjoiner (0x11a51, 0x11a56,), # Soyombo Vowel Sign I ..Soyombo Vowel Sign Oe (0x11a59, 0x11a5b,), # Soyombo Vowel Sign Vocal..Soyombo Vowel Length Mar (0x11a8a, 0x11a96,), # Soyombo Final Consonant ..Soyombo Sign Anusvara (0x11a98, 0x11a99,), # Soyombo Gemination Mark ..Soyombo Subjoiner (0x11c30, 0x11c36,), # Bhaiksuki Vowel Sign I ..Bhaiksuki Vowel Sign Voc (0x11c38, 0x11c3d,), # Bhaiksuki Vowel Sign E ..Bhaiksuki Sign Anusvara (0x11c3f, 0x11c3f,), # Bhaiksuki Sign Virama (0x11c92, 0x11ca7,), # Marchen Subjoined Letter..Marchen Subjoined Letter (0x11caa, 0x11cb0,), # Marchen Subjoined Letter..Marchen Vowel Sign Aa (0x11cb2, 0x11cb3,), # Marchen Vowel Sign U ..Marchen Vowel Sign E (0x11cb5, 0x11cb6,), # Marchen Sign Anusvara ..Marchen Sign Candrabindu (0x11d31, 0x11d36,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3a, 0x11d3a,), # Masaram Gondi Vowel Sign E (0x11d3c, 0x11d3d,), # Masaram Gondi Vowel Sign..Masaram Gondi Vowel Sign (0x11d3f, 0x11d45,), # Masaram Gondi Vowel Sign..Masaram Gondi Virama (0x11d47, 0x11d47,), # Masaram Gondi Ra-kara (0x11d90, 0x11d91,), # Gunjala Gondi Vowel Sign..Gunjala Gondi Vowel Sign (0x11d95, 0x11d95,), # Gunjala Gondi Sign Anusvara (0x11d97, 0x11d97,), # Gunjala Gondi Virama (0x11ef3, 0x11ef4,), # Makasar Vowel Sign I ..Makasar Vowel Sign U (0x11f00, 0x11f01,), # (nil) (0x11f36, 0x11f3a,), # (nil) (0x11f40, 0x11f40,), # (nil) (0x11f42, 0x11f42,), # (nil) (0x13440, 0x13440,), # (nil) (0x13447, 0x13455,), # (nil) (0x16af0, 0x16af4,), # Bassa Vah Combining High..Bassa Vah Combining High (0x16b30, 0x16b36,), # Pahawh Hmong Mark Cim Tu..Pahawh Hmong Mark Cim Ta (0x16f4f, 0x16f4f,), # Miao Sign Consonant Modifier Bar (0x16f8f, 0x16f92,), # Miao Tone Right ..Miao Tone Below (0x16fe4, 0x16fe4,), # Khitan Small Script Filler (0x1bc9d, 0x1bc9e,), # Duployan Thick Letter Se..Duployan Double Mark (0x1cf00, 0x1cf2d,), # Znamenny Combining Mark ..Znamenny Combining Mark (0x1cf30, 0x1cf46,), # Znamenny Combining Tonal..Znamenny Priznak Modifie (0x1d167, 0x1d169,), # Musical Symbol Combining..Musical Symbol Combining (0x1d17b, 0x1d182,), # Musical Symbol Combining..Musical Symbol Combining (0x1d185, 0x1d18b,), # Musical Symbol Combining..Musical Symbol Combining (0x1d1aa, 0x1d1ad,), # Musical Symbol Combining..Musical Symbol Combining (0x1d242, 0x1d244,), # Combining Greek Musical ..Combining Greek Musical (0x1da00, 0x1da36,), # Signwriting Head Rim ..Signwriting Air Sucking (0x1da3b, 0x1da6c,), # Signwriting Mouth Closed..Signwriting Excitement (0x1da75, 0x1da75,), # Signwriting Upper Body Tilting From Hip Joints (0x1da84, 0x1da84,), # Signwriting Location Head Neck (0x1da9b, 0x1da9f,), # Signwriting Fill Modifie..Signwriting Fill Modifie (0x1daa1, 0x1daaf,), # Signwriting Rotation Mod..Signwriting Rotation Mod (0x1e000, 0x1e006,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e008, 0x1e018,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e01b, 0x1e021,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e023, 0x1e024,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e026, 0x1e02a,), # Combining Glagolitic Let..Combining Glagolitic Let (0x1e08f, 0x1e08f,), # (nil) (0x1e130, 0x1e136,), # Nyiakeng Puachue Hmong T..Nyiakeng Puachue Hmong T (0x1e2ae, 0x1e2ae,), # Toto Sign Rising Tone (0x1e2ec, 0x1e2ef,), # Wancho Tone Tup ..Wancho Tone Koini (0x1e4ec, 0x1e4ef,), # (nil) (0x1e8d0, 0x1e8d6,), # Mende Kikakui Combining ..Mende Kikakui Combining (0x1e944, 0x1e94a,), # Adlam Alif Lengthener ..Adlam Nukta (0xe0100, 0xe01ef,), # Variation Selector-17 ..Variation Selector-256 ), }
329,095
Python
70.542609
82
0.63678
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/wcwidth/unicode_versions.py
""" Exports function list_versions() for unicode version level support. This code generated by wcwidth/bin/update-tables.py on 2023-01-14 00:53:07 UTC. """ def list_versions(): """ Return Unicode version levels supported by this module release. Any of the version strings returned may be used as keyword argument ``unicode_version`` to the ``wcwidth()`` family of functions. :returns: Supported Unicode version numbers in ascending sorted order. :rtype: list[str] """ return ( "4.1.0", "5.0.0", "5.1.0", "5.2.0", "6.0.0", "6.1.0", "6.2.0", "6.3.0", "7.0.0", "8.0.0", "9.0.0", "10.0.0", "11.0.0", "12.0.0", "12.1.0", "13.0.0", "14.0.0", "15.0.0", )
833
Python
20.947368
79
0.509004
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.repl/pip_prebundle/wcwidth/table_wide.py
""" Exports WIDE_EASTASIAN table keyed by supporting unicode version level. This code generated by wcwidth/bin/update-tables.py on 2023-01-14 03:25:41 UTC. """ WIDE_EASTASIAN = { '4.1.0': ( # Source: EastAsianWidth-4.1.0.txt # Date: 2005-03-17, 15:21:00 PST [KW] # (0x01100, 0x01159,), # Hangul Choseong Kiyeok ..Hangul Choseong Yeorinhi (0x0115f, 0x0115f,), # Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312c,), # Bopomofo Letter B ..Bopomofo Letter Gn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031b7,), # Ideographic Annotation L..Bopomofo Final Letter H (0x031c0, 0x031cf,), # Cjk Stroke T ..Cjk Stroke N (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03243,), # Parenthesized Ideograph ..Parenthesized Ideograph (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04db5,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x09fbb,), # Cjk Unified Ideograph-4e..Cjk Unified Ideograph-9f (0x0a000, 0x0a48c,), # Yi Syllable It ..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0fa2d,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa30, 0x0fa6a,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa70, 0x0fad9,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '5.0.0': ( # Source: EastAsianWidth-5.0.0.txt # Date: 2006-02-15, 14:39:00 PST [KW] # (0x01100, 0x01159,), # Hangul Choseong Kiyeok ..Hangul Choseong Yeorinhi (0x0115f, 0x0115f,), # Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312c,), # Bopomofo Letter B ..Bopomofo Letter Gn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031b7,), # Ideographic Annotation L..Bopomofo Final Letter H (0x031c0, 0x031cf,), # Cjk Stroke T ..Cjk Stroke N (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03243,), # Parenthesized Ideograph ..Parenthesized Ideograph (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04db5,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x09fbb,), # Cjk Unified Ideograph-4e..Cjk Unified Ideograph-9f (0x0a000, 0x0a48c,), # Yi Syllable It ..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0fa2d,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa30, 0x0fa6a,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa70, 0x0fad9,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '5.1.0': ( # Source: EastAsianWidth-5.1.0.txt # Date: 2008-03-20, 17:42:00 PDT [KW] # (0x01100, 0x01159,), # Hangul Choseong Kiyeok ..Hangul Choseong Yeorinhi (0x0115f, 0x0115f,), # Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031b7,), # Ideographic Annotation L..Bopomofo Final Letter H (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03243,), # Parenthesized Ideograph ..Parenthesized Ideograph (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04db5,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x09fc3,), # Cjk Unified Ideograph-4e..Cjk Unified Ideograph-9f (0x0a000, 0x0a48c,), # Yi Syllable It ..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0fa2d,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa30, 0x0fa6a,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fa70, 0x0fad9,), # Cjk Compatibility Ideogr..Cjk Compatibility Ideogr (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '5.2.0': ( # Source: EastAsianWidth-5.2.0.txt # Date: 2009-06-09, 17:47:00 PDT [KW] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x011a3, 0x011a7,), # Hangul Jungseong A-eu ..Hangul Jungseong O-yae (0x011fa, 0x011ff,), # Hangul Jongseong Kiyeok-..Hangul Jongseong Ssangni (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031b7,), # Ideographic Annotation L..Bopomofo Final Letter H (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0d7b0, 0x0d7c6,), # Hangul Jungseong O-yeo ..Hangul Jungseong Araea-e (0x0d7cb, 0x0d7fb,), # Hangul Jongseong Nieun-r..Hangul Jongseong Phieuph (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1f200, 0x1f200,), # Square Hiragana Hoka (0x1f210, 0x1f231,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '6.0.0': ( # Source: EastAsianWidth-6.0.0.txt # Date: 2010-08-17, 12:17:00 PDT [KW] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x011a3, 0x011a7,), # Hangul Jungseong A-eu ..Hangul Jungseong O-yae (0x011fa, 0x011ff,), # Hangul Jongseong Kiyeok-..Hangul Jongseong Ssangni (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0d7b0, 0x0d7c6,), # Hangul Jungseong O-yeo ..Hangul Jungseong Araea-e (0x0d7cb, 0x0d7fb,), # Hangul Jongseong Nieun-r..Hangul Jongseong Phieuph (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '6.1.0': ( # Source: EastAsianWidth-6.1.0.txt # Date: 2011-09-19, 18:46:00 GMT [KW] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x011a3, 0x011a7,), # Hangul Jungseong A-eu ..Hangul Jungseong O-yae (0x011fa, 0x011ff,), # Hangul Jongseong Kiyeok-..Hangul Jongseong Ssangni (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0d7b0, 0x0d7c6,), # Hangul Jungseong O-yeo ..Hangul Jungseong Araea-e (0x0d7cb, 0x0d7fb,), # Hangul Jongseong Nieun-r..Hangul Jongseong Phieuph (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '6.2.0': ( # Source: EastAsianWidth-6.2.0.txt # Date: 2012-05-15, 18:30:00 GMT [KW] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '6.3.0': ( # Source: EastAsianWidth-6.3.0.txt # Date: 2013-02-05, 20:09:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '7.0.0': ( # Source: EastAsianWidth-7.0.0.txt # Date: 2014-02-28, 23:15:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '8.0.0': ( # Source: EastAsianWidth-8.0.0.txt # Date: 2015-02-10, 21:00:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23a,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '9.0.0': ( # Source: EastAsianWidth-9.0.0.txt # Date: 2016-05-27, 17:00:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312d,), # Bopomofo Letter B ..Bopomofo Letter Ih (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe0,), # Tangut Iteration Mark (0x17000, 0x187ec,), # (nil) (0x18800, 0x18af2,), # Tangut Component-001 ..Tangut Component-755 (0x1b000, 0x1b001,), # Katakana Letter Archaic ..Hiragana Letter Archaic (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6f6,), # Scooter ..Canoe (0x1f910, 0x1f91e,), # Zipper-mouth Face ..Hand With Index And Midd (0x1f920, 0x1f927,), # Face With Cowboy Hat ..Sneezing Face (0x1f930, 0x1f930,), # Pregnant Woman (0x1f933, 0x1f93e,), # Selfie ..Handball (0x1f940, 0x1f94b,), # Wilted Flower ..Martial Arts Uniform (0x1f950, 0x1f95e,), # Croissant ..Pancakes (0x1f980, 0x1f991,), # Crab ..Squid (0x1f9c0, 0x1f9c0,), # Cheese Wedge (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '10.0.0': ( # Source: EastAsianWidth-10.0.0.txt # Date: 2017-03-08, 02:00:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312e,), # Bopomofo Letter B ..Bopomofo Letter O With D (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe1,), # Tangut Iteration Mark ..Nushu Iteration Mark (0x17000, 0x187ec,), # (nil) (0x18800, 0x18af2,), # Tangut Component-001 ..Tangut Component-755 (0x1b000, 0x1b11e,), # Katakana Letter Archaic ..Hentaigana Letter N-mu-m (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6f8,), # Scooter ..Flying Saucer (0x1f910, 0x1f93e,), # Zipper-mouth Face ..Handball (0x1f940, 0x1f94c,), # Wilted Flower ..Curling Stone (0x1f950, 0x1f96b,), # Croissant ..Canned Food (0x1f980, 0x1f997,), # Crab ..Cricket (0x1f9c0, 0x1f9c0,), # Cheese Wedge (0x1f9d0, 0x1f9e6,), # Face With Monocle ..Socks (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '11.0.0': ( # Source: EastAsianWidth-11.0.0.txt # Date: 2018-05-14, 09:41:59 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe1,), # Tangut Iteration Mark ..Nushu Iteration Mark (0x17000, 0x187f1,), # (nil) (0x18800, 0x18af2,), # Tangut Component-001 ..Tangut Component-755 (0x1b000, 0x1b11e,), # Katakana Letter Archaic ..Hentaigana Letter N-mu-m (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6f9,), # Scooter ..Skateboard (0x1f910, 0x1f93e,), # Zipper-mouth Face ..Handball (0x1f940, 0x1f970,), # Wilted Flower ..Smiling Face With Smilin (0x1f973, 0x1f976,), # Face With Party Horn And..Freezing Face (0x1f97a, 0x1f97a,), # Face With Pleading Eyes (0x1f97c, 0x1f9a2,), # Lab Coat ..Swan (0x1f9b0, 0x1f9b9,), # Emoji Component Red Hair..Supervillain (0x1f9c0, 0x1f9c2,), # Cheese Wedge ..Salt Shaker (0x1f9d0, 0x1f9ff,), # Face With Monocle ..Nazar Amulet (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '12.0.0': ( # Source: EastAsianWidth-12.0.0.txt # Date: 2019-01-21, 14:12:58 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x032fe,), # Partnership Sign ..Circled Katakana Wo (0x03300, 0x04dbf,), # Square Apaato ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe3,), # Tangut Iteration Mark ..Old Chinese Iteration Ma (0x17000, 0x187f7,), # (nil) (0x18800, 0x18af2,), # Tangut Component-001 ..Tangut Component-755 (0x1b000, 0x1b11e,), # Katakana Letter Archaic ..Hentaigana Letter N-mu-m (0x1b150, 0x1b152,), # Hiragana Letter Small Wi..Hiragana Letter Small Wo (0x1b164, 0x1b167,), # Katakana Letter Small Wi..Katakana Letter Small N (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6d5, 0x1f6d5,), # Hindu Temple (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6fa,), # Scooter ..Auto Rickshaw (0x1f7e0, 0x1f7eb,), # Large Orange Circle ..Large Brown Square (0x1f90d, 0x1f971,), # White Heart ..Yawning Face (0x1f973, 0x1f976,), # Face With Party Horn And..Freezing Face (0x1f97a, 0x1f9a2,), # Face With Pleading Eyes ..Swan (0x1f9a5, 0x1f9aa,), # Sloth ..Oyster (0x1f9ae, 0x1f9ca,), # Guide Dog ..Ice Cube (0x1f9cd, 0x1f9ff,), # Standing Person ..Nazar Amulet (0x1fa70, 0x1fa73,), # Ballet Shoes ..Shorts (0x1fa78, 0x1fa7a,), # Drop Of Blood ..Stethoscope (0x1fa80, 0x1fa82,), # Yo-yo ..Parachute (0x1fa90, 0x1fa95,), # Ringed Planet ..Banjo (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '12.1.0': ( # Source: EastAsianWidth-12.1.0.txt # Date: 2019-03-31, 22:01:58 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031ba,), # Ideographic Annotation L..Bopomofo Letter Zy (0x031c0, 0x031e3,), # Cjk Stroke T ..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x04dbf,), # Partnership Sign ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe3,), # Tangut Iteration Mark ..Old Chinese Iteration Ma (0x17000, 0x187f7,), # (nil) (0x18800, 0x18af2,), # Tangut Component-001 ..Tangut Component-755 (0x1b000, 0x1b11e,), # Katakana Letter Archaic ..Hentaigana Letter N-mu-m (0x1b150, 0x1b152,), # Hiragana Letter Small Wi..Hiragana Letter Small Wo (0x1b164, 0x1b167,), # Katakana Letter Small Wi..Katakana Letter Small N (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6d5, 0x1f6d5,), # Hindu Temple (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6fa,), # Scooter ..Auto Rickshaw (0x1f7e0, 0x1f7eb,), # Large Orange Circle ..Large Brown Square (0x1f90d, 0x1f971,), # White Heart ..Yawning Face (0x1f973, 0x1f976,), # Face With Party Horn And..Freezing Face (0x1f97a, 0x1f9a2,), # Face With Pleading Eyes ..Swan (0x1f9a5, 0x1f9aa,), # Sloth ..Oyster (0x1f9ae, 0x1f9ca,), # Guide Dog ..Ice Cube (0x1f9cd, 0x1f9ff,), # Standing Person ..Nazar Amulet (0x1fa70, 0x1fa73,), # Ballet Shoes ..Shorts (0x1fa78, 0x1fa7a,), # Drop Of Blood ..Stethoscope (0x1fa80, 0x1fa82,), # Yo-yo ..Parachute (0x1fa90, 0x1fa95,), # Ringed Planet ..Banjo (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '13.0.0': ( # Source: EastAsianWidth-13.0.0.txt # Date: 2029-01-21, 18:14:00 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031e3,), # Ideographic Annotation L..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x04dbf,), # Partnership Sign ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe4,), # Tangut Iteration Mark ..Khitan Small Script Fill (0x16ff0, 0x16ff1,), # Vietnamese Alternate Rea..Vietnamese Alternate Rea (0x17000, 0x187f7,), # (nil) (0x18800, 0x18cd5,), # Tangut Component-001 ..Khitan Small Script Char (0x18d00, 0x18d08,), # (nil) (0x1b000, 0x1b11e,), # Katakana Letter Archaic ..Hentaigana Letter N-mu-m (0x1b150, 0x1b152,), # Hiragana Letter Small Wi..Hiragana Letter Small Wo (0x1b164, 0x1b167,), # Katakana Letter Small Wi..Katakana Letter Small N (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6d5, 0x1f6d7,), # Hindu Temple ..Elevator (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6fc,), # Scooter ..Roller Skate (0x1f7e0, 0x1f7eb,), # Large Orange Circle ..Large Brown Square (0x1f90c, 0x1f93a,), # Pinched Fingers ..Fencer (0x1f93c, 0x1f945,), # Wrestlers ..Goal Net (0x1f947, 0x1f978,), # First Place Medal ..Disguised Face (0x1f97a, 0x1f9cb,), # Face With Pleading Eyes ..Bubble Tea (0x1f9cd, 0x1f9ff,), # Standing Person ..Nazar Amulet (0x1fa70, 0x1fa74,), # Ballet Shoes ..Thong Sandal (0x1fa78, 0x1fa7a,), # Drop Of Blood ..Stethoscope (0x1fa80, 0x1fa86,), # Yo-yo ..Nesting Dolls (0x1fa90, 0x1faa8,), # Ringed Planet ..Rock (0x1fab0, 0x1fab6,), # Fly ..Feather (0x1fac0, 0x1fac2,), # Anatomical Heart ..People Hugging (0x1fad0, 0x1fad6,), # Blueberries ..Teapot (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '14.0.0': ( # Source: EastAsianWidth-14.0.0.txt # Date: 2021-07-06, 09:58:53 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031e3,), # Ideographic Annotation L..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x04dbf,), # Partnership Sign ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe4,), # Tangut Iteration Mark ..Khitan Small Script Fill (0x16ff0, 0x16ff1,), # Vietnamese Alternate Rea..Vietnamese Alternate Rea (0x17000, 0x187f7,), # (nil) (0x18800, 0x18cd5,), # Tangut Component-001 ..Khitan Small Script Char (0x18d00, 0x18d08,), # (nil) (0x1aff0, 0x1aff3,), # Katakana Letter Minnan T..Katakana Letter Minnan T (0x1aff5, 0x1affb,), # Katakana Letter Minnan T..Katakana Letter Minnan N (0x1affd, 0x1affe,), # Katakana Letter Minnan N..Katakana Letter Minnan N (0x1b000, 0x1b122,), # Katakana Letter Archaic ..Katakana Letter Archaic (0x1b150, 0x1b152,), # Hiragana Letter Small Wi..Hiragana Letter Small Wo (0x1b164, 0x1b167,), # Katakana Letter Small Wi..Katakana Letter Small N (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6d5, 0x1f6d7,), # Hindu Temple ..Elevator (0x1f6dd, 0x1f6df,), # Playground Slide ..Ring Buoy (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6fc,), # Scooter ..Roller Skate (0x1f7e0, 0x1f7eb,), # Large Orange Circle ..Large Brown Square (0x1f7f0, 0x1f7f0,), # Heavy Equals Sign (0x1f90c, 0x1f93a,), # Pinched Fingers ..Fencer (0x1f93c, 0x1f945,), # Wrestlers ..Goal Net (0x1f947, 0x1f9ff,), # First Place Medal ..Nazar Amulet (0x1fa70, 0x1fa74,), # Ballet Shoes ..Thong Sandal (0x1fa78, 0x1fa7c,), # Drop Of Blood ..Crutch (0x1fa80, 0x1fa86,), # Yo-yo ..Nesting Dolls (0x1fa90, 0x1faac,), # Ringed Planet ..Hamsa (0x1fab0, 0x1faba,), # Fly ..Nest With Eggs (0x1fac0, 0x1fac5,), # Anatomical Heart ..Person With Crown (0x1fad0, 0x1fad9,), # Blueberries ..Jar (0x1fae0, 0x1fae7,), # Melting Face ..Bubbles (0x1faf0, 0x1faf6,), # Hand With Index Finger A..Heart Hands (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), '15.0.0': ( # Source: EastAsianWidth-15.0.0.txt # Date: 2022-05-24, 17:40:20 GMT [KW, LI] # (0x01100, 0x0115f,), # Hangul Choseong Kiyeok ..Hangul Choseong Filler (0x0231a, 0x0231b,), # Watch ..Hourglass (0x02329, 0x0232a,), # Left-pointing Angle Brac..Right-pointing Angle Bra (0x023e9, 0x023ec,), # Black Right-pointing Dou..Black Down-pointing Doub (0x023f0, 0x023f0,), # Alarm Clock (0x023f3, 0x023f3,), # Hourglass With Flowing Sand (0x025fd, 0x025fe,), # White Medium Small Squar..Black Medium Small Squar (0x02614, 0x02615,), # Umbrella With Rain Drops..Hot Beverage (0x02648, 0x02653,), # Aries ..Pisces (0x0267f, 0x0267f,), # Wheelchair Symbol (0x02693, 0x02693,), # Anchor (0x026a1, 0x026a1,), # High Voltage Sign (0x026aa, 0x026ab,), # Medium White Circle ..Medium Black Circle (0x026bd, 0x026be,), # Soccer Ball ..Baseball (0x026c4, 0x026c5,), # Snowman Without Snow ..Sun Behind Cloud (0x026ce, 0x026ce,), # Ophiuchus (0x026d4, 0x026d4,), # No Entry (0x026ea, 0x026ea,), # Church (0x026f2, 0x026f3,), # Fountain ..Flag In Hole (0x026f5, 0x026f5,), # Sailboat (0x026fa, 0x026fa,), # Tent (0x026fd, 0x026fd,), # Fuel Pump (0x02705, 0x02705,), # White Heavy Check Mark (0x0270a, 0x0270b,), # Raised Fist ..Raised Hand (0x02728, 0x02728,), # Sparkles (0x0274c, 0x0274c,), # Cross Mark (0x0274e, 0x0274e,), # Negative Squared Cross Mark (0x02753, 0x02755,), # Black Question Mark Orna..White Exclamation Mark O (0x02757, 0x02757,), # Heavy Exclamation Mark Symbol (0x02795, 0x02797,), # Heavy Plus Sign ..Heavy Division Sign (0x027b0, 0x027b0,), # Curly Loop (0x027bf, 0x027bf,), # Double Curly Loop (0x02b1b, 0x02b1c,), # Black Large Square ..White Large Square (0x02b50, 0x02b50,), # White Medium Star (0x02b55, 0x02b55,), # Heavy Large Circle (0x02e80, 0x02e99,), # Cjk Radical Repeat ..Cjk Radical Rap (0x02e9b, 0x02ef3,), # Cjk Radical Choke ..Cjk Radical C-simplified (0x02f00, 0x02fd5,), # Kangxi Radical One ..Kangxi Radical Flute (0x02ff0, 0x02ffb,), # Ideographic Description ..Ideographic Description (0x03000, 0x0303e,), # Ideographic Space ..Ideographic Variation In (0x03041, 0x03096,), # Hiragana Letter Small A ..Hiragana Letter Small Ke (0x03099, 0x030ff,), # Combining Katakana-hirag..Katakana Digraph Koto (0x03105, 0x0312f,), # Bopomofo Letter B ..Bopomofo Letter Nn (0x03131, 0x0318e,), # Hangul Letter Kiyeok ..Hangul Letter Araeae (0x03190, 0x031e3,), # Ideographic Annotation L..Cjk Stroke Q (0x031f0, 0x0321e,), # Katakana Letter Small Ku..Parenthesized Korean Cha (0x03220, 0x03247,), # Parenthesized Ideograph ..Circled Ideograph Koto (0x03250, 0x04dbf,), # Partnership Sign ..Cjk Unified Ideograph-4d (0x04e00, 0x0a48c,), # Cjk Unified Ideograph-4e..Yi Syllable Yyr (0x0a490, 0x0a4c6,), # Yi Radical Qot ..Yi Radical Ke (0x0a960, 0x0a97c,), # Hangul Choseong Tikeut-m..Hangul Choseong Ssangyeo (0x0ac00, 0x0d7a3,), # Hangul Syllable Ga ..Hangul Syllable Hih (0x0f900, 0x0faff,), # Cjk Compatibility Ideogr..(nil) (0x0fe10, 0x0fe19,), # Presentation Form For Ve..Presentation Form For Ve (0x0fe30, 0x0fe52,), # Presentation Form For Ve..Small Full Stop (0x0fe54, 0x0fe66,), # Small Semicolon ..Small Equals Sign (0x0fe68, 0x0fe6b,), # Small Reverse Solidus ..Small Commercial At (0x0ff01, 0x0ff60,), # Fullwidth Exclamation Ma..Fullwidth Right White Pa (0x0ffe0, 0x0ffe6,), # Fullwidth Cent Sign ..Fullwidth Won Sign (0x16fe0, 0x16fe4,), # Tangut Iteration Mark ..Khitan Small Script Fill (0x16ff0, 0x16ff1,), # Vietnamese Alternate Rea..Vietnamese Alternate Rea (0x17000, 0x187f7,), # (nil) (0x18800, 0x18cd5,), # Tangut Component-001 ..Khitan Small Script Char (0x18d00, 0x18d08,), # (nil) (0x1aff0, 0x1aff3,), # Katakana Letter Minnan T..Katakana Letter Minnan T (0x1aff5, 0x1affb,), # Katakana Letter Minnan T..Katakana Letter Minnan N (0x1affd, 0x1affe,), # Katakana Letter Minnan N..Katakana Letter Minnan N (0x1b000, 0x1b122,), # Katakana Letter Archaic ..Katakana Letter Archaic (0x1b132, 0x1b132,), # (nil) (0x1b150, 0x1b152,), # Hiragana Letter Small Wi..Hiragana Letter Small Wo (0x1b155, 0x1b155,), # (nil) (0x1b164, 0x1b167,), # Katakana Letter Small Wi..Katakana Letter Small N (0x1b170, 0x1b2fb,), # Nushu Character-1b170 ..Nushu Character-1b2fb (0x1f004, 0x1f004,), # Mahjong Tile Red Dragon (0x1f0cf, 0x1f0cf,), # Playing Card Black Joker (0x1f18e, 0x1f18e,), # Negative Squared Ab (0x1f191, 0x1f19a,), # Squared Cl ..Squared Vs (0x1f200, 0x1f202,), # Square Hiragana Hoka ..Squared Katakana Sa (0x1f210, 0x1f23b,), # Squared Cjk Unified Ideo..Squared Cjk Unified Ideo (0x1f240, 0x1f248,), # Tortoise Shell Bracketed..Tortoise Shell Bracketed (0x1f250, 0x1f251,), # Circled Ideograph Advant..Circled Ideograph Accept (0x1f260, 0x1f265,), # Rounded Symbol For Fu ..Rounded Symbol For Cai (0x1f300, 0x1f320,), # Cyclone ..Shooting Star (0x1f32d, 0x1f335,), # Hot Dog ..Cactus (0x1f337, 0x1f37c,), # Tulip ..Baby Bottle (0x1f37e, 0x1f393,), # Bottle With Popping Cork..Graduation Cap (0x1f3a0, 0x1f3ca,), # Carousel Horse ..Swimmer (0x1f3cf, 0x1f3d3,), # Cricket Bat And Ball ..Table Tennis Paddle And (0x1f3e0, 0x1f3f0,), # House Building ..European Castle (0x1f3f4, 0x1f3f4,), # Waving Black Flag (0x1f3f8, 0x1f43e,), # Badminton Racquet And Sh..Paw Prints (0x1f440, 0x1f440,), # Eyes (0x1f442, 0x1f4fc,), # Ear ..Videocassette (0x1f4ff, 0x1f53d,), # Prayer Beads ..Down-pointing Small Red (0x1f54b, 0x1f54e,), # Kaaba ..Menorah With Nine Branch (0x1f550, 0x1f567,), # Clock Face One Oclock ..Clock Face Twelve-thirty (0x1f57a, 0x1f57a,), # Man Dancing (0x1f595, 0x1f596,), # Reversed Hand With Middl..Raised Hand With Part Be (0x1f5a4, 0x1f5a4,), # Black Heart (0x1f5fb, 0x1f64f,), # Mount Fuji ..Person With Folded Hands (0x1f680, 0x1f6c5,), # Rocket ..Left Luggage (0x1f6cc, 0x1f6cc,), # Sleeping Accommodation (0x1f6d0, 0x1f6d2,), # Place Of Worship ..Shopping Trolley (0x1f6d5, 0x1f6d7,), # Hindu Temple ..Elevator (0x1f6dc, 0x1f6df,), # (nil) ..Ring Buoy (0x1f6eb, 0x1f6ec,), # Airplane Departure ..Airplane Arriving (0x1f6f4, 0x1f6fc,), # Scooter ..Roller Skate (0x1f7e0, 0x1f7eb,), # Large Orange Circle ..Large Brown Square (0x1f7f0, 0x1f7f0,), # Heavy Equals Sign (0x1f90c, 0x1f93a,), # Pinched Fingers ..Fencer (0x1f93c, 0x1f945,), # Wrestlers ..Goal Net (0x1f947, 0x1f9ff,), # First Place Medal ..Nazar Amulet (0x1fa70, 0x1fa7c,), # Ballet Shoes ..Crutch (0x1fa80, 0x1fa88,), # Yo-yo ..(nil) (0x1fa90, 0x1fabd,), # Ringed Planet ..(nil) (0x1fabf, 0x1fac5,), # (nil) ..Person With Crown (0x1face, 0x1fadb,), # (nil) (0x1fae0, 0x1fae8,), # Melting Face ..(nil) (0x1faf0, 0x1faf8,), # Hand With Index Finger A..(nil) (0x20000, 0x2fffd,), # Cjk Unified Ideograph-20..(nil) (0x30000, 0x3fffd,), # Cjk Unified Ideograph-30..(nil) ), }
91,708
Python
66.582166
82
0.597505
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.lula_test_widget/omni/isaac/lula_test_widget/test_scenarios.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.core.objects.cuboid import VisualCuboid from omni.isaac.core.objects.cylinder import VisualCylinder from omni.isaac.core.objects.cone import VisualCone from omni.isaac.core.prims import XFormPrim from omni.isaac.core.utils.prims import is_prim_path_valid, delete_prim from omni.isaac.core.utils.string import find_unique_string_name from omni.isaac.core.utils.rotations import euler_angles_to_quat from omni.isaac.core.utils.numpy import rot_matrices_to_quats from omni.isaac.core.utils.types import ArticulationAction from .controllers import KinematicsController, TrajectoryController from omni.isaac.motion_generation import ( MotionPolicyController, LulaKinematicsSolver, LulaTaskSpaceTrajectoryGenerator, ArticulationKinematicsSolver, ArticulationMotionPolicy, ArticulationTrajectory, RmpFlow, ) import numpy as np import carb class LulaTestScenarios: def __init__(self): self._target = None self._obstacles = [] self._trajectory_base_frame = None self._trajectory_targets = [] self._controller = None self.timestep = 0 self.lula_ik = None self.rmpflow = None self.traj_gen = None self.use_orientation = True self.scenario_name = "" self.rmpflow_debug_mode = False self._ee_frame_prim = None self.art_ik = None def visualize_ee_frame(self, articulation, ee_frame): if self.lula_ik is None or articulation is None: return if self._ee_frame_prim is not None: delete_prim(self._ee_frame_prim.prim_path) self.art_ik = ArticulationKinematicsSolver(articulation, self.lula_ik, ee_frame) position, orientation = self.art_ik.compute_end_effector_pose() orientation = rot_matrices_to_quats(orientation) self._ee_frame_prim = self._create_frame_prim(position, orientation, "/Lula/end_effector") def stop_visualize_ee_frame(self): if self._ee_frame_prim is not None: delete_prim(self._ee_frame_prim.prim_path) self._ee_frame_prim = None self.art_ik = None def toggle_rmpflow_debug_mode(self): self.rmpflow_debug_mode = not self.rmpflow_debug_mode if self.rmpflow is None: return if self.rmpflow_debug_mode: self.rmpflow.set_ignore_state_updates(True) self.rmpflow.visualize_collision_spheres() else: self.rmpflow.set_ignore_state_updates(False) self.rmpflow.stop_visualizing_collision_spheres() def initialize_ik_solver(self, robot_description_path, urdf_path): self.lula_ik = LulaKinematicsSolver(robot_description_path, urdf_path) def get_ik_frames(self): if self.lula_ik is None: return [] return self.lula_ik.get_all_frame_names() def on_ik_follow_target(self, articulation, ee_frame_name): self.scenario_reset() if self.lula_ik is None: return art_ik = ArticulationKinematicsSolver(articulation, self.lula_ik, ee_frame_name) self._controller = KinematicsController("Lula Kinematics Controller", art_ik) self._create_target() def on_custom_trajectory(self, robot_description_path, urdf_path): self.scenario_reset() if self.lula_ik is None: return self.scenario_name = "Custom Trajectory" orientation = np.array([0, 1, 0, 0]) rect_path = np.array([[0.3, -0.3, 0.1], [0.3, 0.3, 0.1], [0.3, 0.3, 0.5], [0.3, -0.3, 0.5], [0.3, -0.3, 0.1]]) self.traj_gen = LulaTaskSpaceTrajectoryGenerator(robot_description_path, urdf_path) self._trajectory_base_frame = XFormPrim("/Trajectory", position=np.array([0, 0, 0])) for i in range(4): frame_prim = self._create_frame_prim(rect_path[i], orientation, f"/Trajectory/Target_{i+1}") self._trajectory_targets.append(frame_prim) def create_trajectory_controller(self, articulation, ee_frame): if self.traj_gen is None: return positions = np.empty((len(self._trajectory_targets), 3)) orientations = np.empty((len(self._trajectory_targets), 4)) for i, target in enumerate(self._trajectory_targets): positions[i], orientations[i] = target.get_world_pose() trajectory = self.traj_gen.compute_task_space_trajectory_from_points(positions, orientations, ee_frame) art_traj = ArticulationTrajectory(articulation, trajectory, 1 / 60) self._controller = TrajectoryController("Trajectory Controller", art_traj) def delete_waypoint(self): if self.scenario_name == "Custom Trajectory" and len(self._trajectory_targets) > 2: waypoint = self._trajectory_targets[-1] delete_prim(waypoint.prim_path) self._trajectory_targets = self._trajectory_targets[:-1] def add_waypoint(self): if self.scenario_name == "Custom Trajectory": orientation = self._trajectory_targets[-1].get_world_pose()[1] positions = [] for waypoint in self._trajectory_targets: positions.append(waypoint.get_world_pose()[0]) waypoint = self._create_frame_prim( np.mean(positions, axis=0), orientation, f"/Trajectory/Target_{len(self._trajectory_targets)+1}" ) self._trajectory_targets.append(waypoint) def on_rmpflow_follow_target_obstacles(self, articulation, **rmp_config): self.scenario_reset() self.rmpflow = RmpFlow(**rmp_config) if self.rmpflow_debug_mode: self.rmpflow.set_ignore_state_updates(True) self.rmpflow.visualize_collision_spheres() self.rmpflow.set_robot_base_pose(*articulation.get_world_pose()) art_rmp = ArticulationMotionPolicy(articulation, self.rmpflow, 1 / 60) self._controller = MotionPolicyController("RmpFlow Controller", art_rmp) self._create_target() self._create_wall() self._create_wall(position=np.array([0.4, 0, 0.1]), orientation=np.array([1, 0, 0, 0])) for obstacle in self._obstacles: self.rmpflow.add_obstacle(obstacle) def on_rmpflow_follow_sinusoidal_target(self, articulation, **rmp_config): self.scenario_reset() self.scenario_name = "Sinusoidal Target" self.rmpflow = RmpFlow(**rmp_config) if self.rmpflow_debug_mode: self.rmpflow.set_ignore_state_updates(True) self.rmpflow.visualize_collision_spheres() self.rmpflow.set_robot_base_pose(*articulation.get_world_pose()) art_rmp = ArticulationMotionPolicy(articulation, self.rmpflow, 1 / 60) self._controller = MotionPolicyController("RmpFlow Controller", art_rmp) self._create_target() def get_rmpflow(self): return self.rmpflow def _create_target(self, position=None, orientation=None): if position is None: position = np.array([0.5, 0, 0.5]) if orientation is None: orientation = np.array([0, -1, 0, 0]) self._target = VisualCuboid( "/World/Target", size=0.05, position=position, orientation=orientation, color=np.array([1.0, 0, 0]) ) def _create_frame_prim(self, position, orientation, parent_prim_path): frame_xform = XFormPrim(parent_prim_path, position=position, orientation=orientation) line_len = 0.04 line_width = 0.004 cone_radius = 0.01 cone_len = 0.02 x_axis = VisualCylinder( parent_prim_path + "/X_line", translation=np.array([line_len / 2, 0, 0]), orientation=euler_angles_to_quat([0, np.pi / 2, 0]), color=np.array([1, 0, 0]), height=line_len, radius=line_width, ) x_tip = VisualCone( parent_prim_path + "/X_tip", translation=np.array([line_len + cone_len / 2, 0, 0]), orientation=euler_angles_to_quat([0, np.pi / 2, 0]), color=np.array([1, 0, 0]), height=cone_len, radius=cone_radius, ) y_axis = VisualCylinder( parent_prim_path + "/Y_line", translation=np.array([0, line_len / 2, 0]), orientation=euler_angles_to_quat([-np.pi / 2, 0, 0]), color=np.array([0, 1, 0]), height=line_len, radius=line_width, ) y_tip = VisualCone( parent_prim_path + "/Y_tip", translation=np.array([0, line_len + cone_len / 2, 0]), orientation=euler_angles_to_quat([-np.pi / 2, 0, 0]), color=np.array([0, 1, 0]), height=cone_len, radius=cone_radius, ) z_axis = VisualCylinder( parent_prim_path + "/Z_line", translation=np.array([0, 0, line_len / 2]), orientation=euler_angles_to_quat([0, 0, 0]), color=np.array([0, 0, 1]), height=line_len, radius=line_width, ) z_tip = VisualCone( parent_prim_path + "/Z_tip", translation=np.array([0, 0, line_len + cone_len / 2]), orientation=euler_angles_to_quat([0, 0, 0]), color=np.array([0, 0, 1]), height=cone_len, radius=cone_radius, ) return frame_xform def _create_wall(self, position=None, orientation=None): cube_prim_path = find_unique_string_name( initial_name="/World/WallObstacle", is_unique_fn=lambda x: not is_prim_path_valid(x) ) if position is None: position = np.array([0.45, -0.15, 0.5]) if orientation is None: orientation = euler_angles_to_quat(np.array([0, 0, np.pi / 2])) cube = VisualCuboid( prim_path=cube_prim_path, position=position, orientation=orientation, size=1.0, scale=np.array([0.1, 0.5, 0.6]), color=np.array([0, 0, 1.0]), ) self._obstacles.append(cube) def set_use_orientation(self, use_orientation): self.use_orientation = use_orientation def full_reset(self): self.scenario_reset() self.lula_ik = None self.use_orientation = True if self._ee_frame_prim is not None: delete_prim("/Lula") self._ee_frame_prim = None self.art_ik = None def scenario_reset(self): if self._target is not None: delete_prim(self._target.prim_path) if self._trajectory_base_frame is not None: delete_prim(self._trajectory_base_frame.prim_path) for obstacle in self._obstacles: delete_prim(obstacle.prim_path) self._target = None self._obstacles = [] self._trajectory_targets = [] self._trajectory_base_frame = None self._controller = None if self.rmpflow is not None: self.rmpflow.stop_visualizing_collision_spheres() self.timestep = 0 self.scenario_name = "" def update_scenario(self, **scenario_params): if self.scenario_name == "Sinusoidal Target": w_z = scenario_params["w_z"] w_xy = scenario_params["w_xy"] rad_z = scenario_params["rad_z"] rad_xy = scenario_params["rad_xy"] height = scenario_params["height"] z = height + rad_z * np.sin(2 * np.pi * w_z * self.timestep / 60) a = 2 * np.pi * w_xy * self.timestep / 60 if (a / np.pi) % 4 > 2: a = -a x, y = rad_xy * np.cos(a), rad_xy * np.sin(a) target_position = np.array([x, y, z]) target_orientation = euler_angles_to_quat(np.array([np.pi / 2, 0, np.pi / 2 + a])) self._target.set_world_pose(target_position, target_orientation) self.timestep += 1 def get_next_action(self, **scenario_params): if self._ee_frame_prim is not None: position, orientation = self.art_ik.compute_end_effector_pose() orientation = rot_matrices_to_quats(orientation) self._ee_frame_prim.set_world_pose(position, orientation) if self._controller is None: return ArticulationAction() self.update_scenario(**scenario_params) if self._target is not None: position, orientation = self._target.get_local_pose() if not self.use_orientation: orientation = None return self._controller.forward(position, orientation) else: return self._controller.forward(np.empty((3,)), None)
13,138
Python
36.433048
118
0.607018
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.lula_test_widget/omni/isaac/lula_test_widget/extension.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import weakref import asyncio import gc import carb import omni from pxr import Usd from omni.kit.window.property.templates import LABEL_WIDTH import omni.ui as ui import omni.usd import omni.timeline import omni.kit.commands from omni.kit.menu.utils import add_menu_items, remove_menu_items from omni.isaac.ui.menu import make_menu_item_description from omni.isaac.core.utils.prims import get_prim_object_type from omni.isaac.core.articulations import Articulation from omni.isaac.ui.widgets import DynamicComboBoxModel from .test_scenarios import LulaTestScenarios from omni.isaac.ui.ui_utils import ( add_line_rect_flourish, btn_builder, state_btn_builder, float_builder, setup_ui_headers, get_style, str_builder, ) from omni.kit.window.extensions import SimpleCheckBox import omni.physx as _physx import numpy as np import os EXTENSION_NAME = "Lula Test Widget" MAX_DOF_NUM = 100 def is_yaml_file(path: str): _, ext = os.path.splitext(path.lower()) return ext in [".yaml", ".YAML"] def is_urdf_file(path: str): _, ext = os.path.splitext(path.lower()) return ext in [".urdf", ".URDF"] def on_filter_yaml_item(item) -> bool: if not item or item.is_folder: return not (item.name == "Omniverse" or item.path.startswith("omniverse:")) return is_yaml_file(item.path) def on_filter_urdf_item(item) -> bool: if not item or item.is_folder: return not (item.name == "Omniverse" or item.path.startswith("omniverse:")) return is_urdf_file(item.path) class Extension(omni.ext.IExt): def on_startup(self, ext_id: str): """Initialize extension and UI elements""" # Events self._usd_context = omni.usd.get_context() self._physxIFace = _physx.acquire_physx_interface() self._physx_subscription = None self._stage_event_sub = None self._timeline = omni.timeline.get_timeline_interface() # Build Window self._window = ui.Window( title=EXTENSION_NAME, width=600, height=500, visible=False, dockPreference=ui.DockPreference.LEFT_BOTTOM ) self._window.set_visibility_changed_fn(self._on_window) # UI self._models = {} self._ext_id = ext_id self._menu_items = [ make_menu_item_description(ext_id, EXTENSION_NAME, lambda a=weakref.proxy(self): a._menu_callback()) ] add_menu_items(self._menu_items, "Isaac Utils") # Selection self._new_window = True self.new_selection = True self._selected_index = None self._selected_prim_path = None self._prev_art_prim_path = None # Articulation self.articulation = None self.num_dof = 0 self.dof_names = [] self.link_names = [] # Lula Config Files self._selected_robot_description_file = None self._selected_robot_urdf_file = None self._robot_description_file = None self._robot_urdf_file = None self._ee_frame_options = [] self._rmpflow_config_yaml = None # Lula Test Scenarios self._test_scenarios = LulaTestScenarios() # Visualize End Effector self._visualize_end_effector = True def on_shutdown(self): self._test_scenarios.full_reset() self.articulation = None self._usd_context = None self._stage_event_sub = None self._timeline_event_sub = None self._physx_subscription = None self._models = {} remove_menu_items(self._menu_items, "Isaac Utils") if self._window: self._window = None gc.collect() def _on_window(self, visible): if self._window.visible: # Subscribe to Stage and Timeline Events self._usd_context = omni.usd.get_context() events = self._usd_context.get_stage_event_stream() self._stage_event_sub = events.create_subscription_to_pop(self._on_stage_event) stream = self._timeline.get_timeline_event_stream() self._timeline_event_sub = stream.create_subscription_to_pop(self._on_timeline_event) self._build_ui() if not self._new_window and self.articulation: self._refresh_ui(self.articulation) self._new_window = False else: self._usd_context = None self._stage_event_sub = None self._timeline_event_sub = None def _menu_callback(self): self._window.visible = not self._window.visible # Update the Selection Box if the Timeline is already playing if self._timeline.is_playing(): self._refresh_selection_combobox() def _build_ui(self): # if not self._window: with self._window.frame: with ui.VStack(spacing=5, height=0): self._build_info_ui() self._build_selection_ui() self._build_kinematics_ui() self._build_trajectory_generation_ui() self._build_rmpflow_ui() async def dock_window(): await omni.kit.app.get_app().next_update_async() def dock(space, name, location, pos=0.5): window = omni.ui.Workspace.get_window(name) if window and space: window.dock_in(space, location, pos) return window tgt = ui.Workspace.get_window("Viewport") dock(tgt, EXTENSION_NAME, omni.ui.DockPosition.LEFT, 0.33) await omni.kit.app.get_app().next_update_async() self._task = asyncio.ensure_future(dock_window()) def _on_selection(self, prim_path): """Creates an Articulation Object from the selected articulation prim path. Updates the UI with the Selected articulation. Args: prim_path (string): path to selected articulation """ if prim_path == self._prev_art_prim_path: return else: self._prev_art_prim_path = prim_path self.new_selection = True self._prev_link = None if self.articulation_list and prim_path != "None": # Create and Initialize the Articulation self.articulation = Articulation(prim_path) if not self.articulation.handles_initialized: self.articulation.initialize() # Update the entire UI with the selected articulaiton self._refresh_ui(self.articulation) # start event subscriptions if not self._physx_subscription: self._physx_subscription = self._physxIFace.subscribe_physics_step_events(self._on_physics_step) # Deselect and Reset else: if self.articulation is not None: self._reset_ui() self._refresh_selection_combobox() self.articulation = None # carb.log_warn("Resetting Articulation Inspector") def _on_combobox_selection(self, model=None, val=None): # index = model.get_item_value_model().as_int index = self._models["ar_selection_model"].get_item_value_model().as_int if index >= 0 and index < len(self.articulation_list): self._selected_index = index item = self.articulation_list[index] self._selected_prim_path = item self._on_selection(item) def _refresh_selection_combobox(self): self.articulation_list = self.get_all_articulations() if self._prev_art_prim_path is not None and self._prev_art_prim_path not in self.articulation_list: self._reset_ui() self._models["ar_selection_model"] = DynamicComboBoxModel(self.articulation_list) self._models["ar_selection_combobox"].model = self._models["ar_selection_model"] self._models["ar_selection_combobox"].model.add_item_changed_fn(self._on_combobox_selection) # If something was already selected, reselect after refresh if self._selected_index is not None and self._selected_prim_path is not None: # If the item is still in the articulation list if self._selected_prim_path in self.articulation_list: self._models["ar_selection_combobox"].model.set_item_value_model( ui.SimpleIntModel(self._selected_index) ) def _clear_selection_combobox(self): self._selected_index = None self._selected_prim_path = None self.articulation_list = [] self._models["ar_selection_model"] = DynamicComboBoxModel(self.articulation_list) self._models["ar_selection_combobox"].model = self._models["ar_selection_model"] self._models["ar_selection_combobox"].model.add_item_changed_fn(self._on_combobox_selection) def get_all_articulations(self): """Get all the articulation objects from the Stage. Returns: list(str): list of prim_paths as strings """ articulations = ["None"] stage = self._usd_context.get_stage() if stage: for prim in Usd.PrimRange(stage.GetPrimAtPath("/")): path = str(prim.GetPath()) # Get prim type get_prim_object_type type = get_prim_object_type(path) if type == "articulation": articulations.append(path) return articulations def get_articulation_values(self, articulation): """Get and store the latest dof_properties from the articulation. Update the Properties UI. Args: articulation (Articulation): Selected Articulation """ # Update static dof properties on new selection if self.new_selection: self.num_dof = articulation.num_dof self.dof_names = articulation.dof_names self.new_selection = False self._joint_positions = articulation.get_joint_positions() def _refresh_ee_frame_combobox(self): if self._robot_description_file is not None and self._robot_urdf_file is not None: self._test_scenarios.initialize_ik_solver(self._robot_description_file, self._robot_urdf_file) ee_frames = self._test_scenarios.get_ik_frames() else: ee_frames = [] name = "ee_frame" self._models[name] = DynamicComboBoxModel(ee_frames) self._models[name + "_combobox"].model = self._models[name] if len(ee_frames) > 0: self._models[name].get_item_value_model().set_value(len(ee_frames) - 1) self._models[name].add_item_changed_fn(self._reset_scenario) self._ee_frame_options = ee_frames def _reset_scenario(self, model=None, value=None): self._enable_lula_dropdowns() self._set_enable_trajectory_panel(False) if self.articulation is not None: self.articulation.post_reset() def _refresh_ui(self, articulation): """Updates the GUI with a new Articulation's properties. Args: articulation (Articulation): [description] """ # Get the latest articulation values and update the Properties UI self.get_articulation_values(articulation) if is_yaml_file(self._models["input_robot_description_file"].get_value_as_string()): self._enable_load_button def _reset_ui(self): """Reset / Hide UI Elements. """ self._clear_selection_combobox() self._test_scenarios.full_reset() self._prev_art_prim_path = None self._visualize_end_effector = True ################################## # Callbacks ################################## def _on_stage_event(self, event): """Callback for Stage Events Args: event (omni.usd.StageEventType): Event Type """ # On every stage event check if any articulations have been added/removed from the Stage self._refresh_selection_combobox() if event.type == int(omni.usd.StageEventType.SELECTION_CHANGED): # self._on_selection_changed() pass elif event.type == int(omni.usd.StageEventType.OPENED) or event.type == int(omni.usd.StageEventType.CLOSED): # stage was opened or closed, cleanup self._physx_subscription = None def _on_physics_step(self, step): """Callback for Physics Step. Args: step ([type]): [description] """ if self.articulation is not None: if not self.articulation.handles_initialized: self.articulation.initialize() # Get the latest values from the articulation self.get_articulation_values(self.articulation) action = self._get_next_action() self.articulation.get_articulation_controller().apply_action(action) return def _get_next_action(self): if self._test_scenarios.scenario_name == "Sinusoidal Target": w_xy = self._models["rmpflow_follow_sinusoid_w_xy"].get_value_as_float() w_z = self._models["rmpflow_follow_sinusoid_w_z"].get_value_as_float() rad_z = self._models["rmpflow_follow_sinusoid_rad_z"].get_value_as_float() rad_xy = self._models["rmpflow_follow_sinusoid_rad_xy"].get_value_as_float() height = self._models["rmpflow_follow_sinusoid_height"].get_value_as_float() return self._test_scenarios.get_next_action(w_xy=w_xy, w_z=w_z, rad_z=rad_z, rad_xy=rad_xy, height=height) else: return self._test_scenarios.get_next_action() def _on_timeline_event(self, e): """Callback for Timeline Events Args: event (omni.timeline.TimelineEventType): Event Type """ if e.type == int(omni.timeline.TimelineEventType.PLAY): # BUG: get_all_articulations returns ['None'] after STOP/PLAY <-- articulations show up as xforms self._refresh_selection_combobox() elif e.type == int(omni.timeline.TimelineEventType.STOP): self._reset_ui() ################################## # UI Builders ################################## def _build_info_ui(self): title = EXTENSION_NAME doc_link = "https://docs.omniverse.nvidia.com/app_isaacsim/app_isaacsim/overview.html" overview = "This utility is used to help generate and refine the collision sphere representation of a robot. " overview += "Select the Articulation for which you would like to edit spheres from the dropdown menu. Then select a link from the robot Articulation to begin using the Sphere Editor." overview += "\n\nPress the 'Open in IDE' button to view the source code." setup_ui_headers(self._ext_id, __file__, title, doc_link, overview) def _build_selection_ui(self): frame = ui.CollapsableFrame( title="Selection Panel", height=0, collapsed=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) with frame: with ui.VStack(style=get_style(), spacing=5, height=0): # Create a dynamic ComboBox for Articulation Selection self.articulation_list = [] self._models["ar_selection_model"] = DynamicComboBoxModel(self.articulation_list) with ui.HStack(): ui.Label( "Select Articulation", width=LABEL_WIDTH, alignment=ui.Alignment.LEFT_CENTER, tooltip="Select Articulation", ) self._models["ar_selection_combobox"] = ui.ComboBox(self._models["ar_selection_model"]) add_line_rect_flourish(False) self._models["ar_selection_combobox"].model.add_item_changed_fn(self._on_combobox_selection) # Select Robot Description YAML file def check_file_type(model=None): path = model.get_value_as_string() if is_yaml_file(path): self._selected_robot_description_file = model.get_value_as_string() self._enable_load_button() else: self._selected_robot_description_file = None carb.log_warn(f"Invalid path to Robot Desctiption YAML: {path}") kwargs = { "label": "Robot Description YAML", "default_val": "", "tooltip": "Click the Folder Icon to Set Filepath", "use_folder_picker": True, "item_filter_fn": on_filter_yaml_item, "folder_dialog_title": "Select Robot Description YAML file", "folder_button_title": "Select YAML", } self._models["input_robot_description_file"] = str_builder(**kwargs) self._models["input_robot_description_file"].add_value_changed_fn(check_file_type) # Select Robot URDF file def check_urdf_file_type(model=None): path = model.get_value_as_string() if is_urdf_file(path): self._selected_robot_urdf_file = model.get_value_as_string() self._enable_load_button() else: self._selected_robot_urdf_file = None carb.log_warn(f"Invalid path to Robot URDF: {path}") kwargs = { "label": "Robot URDF", "default_val": "", "tooltip": "Click the Folder Icon to Set Filepath", "use_folder_picker": True, "item_filter_fn": on_filter_urdf_item, "folder_dialog_title": "Select Robot URDF file", "folder_button_title": "Select URDF", } self._models["input_robot_urdf_file"] = str_builder(**kwargs) self._models["input_robot_urdf_file"].add_value_changed_fn(check_urdf_file_type) # Load the currently selected config files def on_load_config(model=None, val=None): self._robot_description_file = self._selected_robot_description_file self._robot_urdf_file = self._selected_robot_urdf_file self._refresh_ee_frame_combobox() self._enable_lula_dropdowns() self._set_enable_trajectory_panel(False) self._models["load_config_btn"] = btn_builder( label="Load Selected Config", text="Load", tooltip="Load the selected Lula config files", on_clicked_fn=on_load_config, ) # Select End Effector Frame Name name = "ee_frame" self._models[name] = DynamicComboBoxModel([]) with ui.HStack(): ui.Label( "Select End Effector Frame", width=LABEL_WIDTH, alignment=ui.Alignment.LEFT_CENTER, tooltip="End Effector Frame to Use when following a target", ) self._models[name + "_combobox"] = ui.ComboBox(self._models[name]) add_line_rect_flourish(False) self._models[name].add_item_changed_fn(self._reset_scenario) # Button for ignoring IK targets def on_clicked_fn(use_orientation): self._test_scenarios.set_use_orientation(use_orientation) with ui.HStack(width=0): label = "Use Orientation Targets" ui.Label(label, width=LABEL_WIDTH - 12, alignment=ui.Alignment.LEFT_TOP) cb = ui.SimpleBoolModel(default_value=1) SimpleCheckBox(1, on_clicked_fn, model=cb) # Button for visualizing end effector def on_vis_ee_clicked_fn(visualize_ee): self._visalize_end_effector = visualize_ee if visualize_ee: self._test_scenarios.visualize_ee_frame(self.articulation, self._get_selected_ee_frame()) else: self._test_scenarios.stop_visualize_ee_frame() with ui.HStack(width=0): label = "Visualize End Effector Pose" ui.Label(label, width=LABEL_WIDTH - 12, alignment=ui.Alignment.LEFT_TOP) cb = ui.SimpleBoolModel(default_value=1) SimpleCheckBox(1, on_vis_ee_clicked_fn, model=cb) def _build_kinematics_ui(self): frame = ui.CollapsableFrame( title="Lula Kinematics Solver", height=0, collapsed=True, enabled=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) self._models["kinematics_frame"] = frame with frame: with ui.VStack(style=get_style(), spacing=5, height=0): def ik_follow_target(model=None): ee_frame = self._get_selected_ee_frame() self.articulation.post_reset() self._test_scenarios.on_ik_follow_target(self.articulation, ee_frame) self._models["kinematics_follow_target_btn"] = btn_builder( label="Follow Target", text="Follow Target", tooltip="Use IK to follow a target", on_clicked_fn=ik_follow_target, ) def _build_trajectory_generation_ui(self): frame = ui.CollapsableFrame( title="Lula Trajectory Generator", height=0, collapsed=True, enabled=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) self._models["trajectory_frame"] = frame with frame: with ui.VStack(style=get_style(), spacing=5, height=0): def on_custom_trajectory(model=None, val=None): self.articulation.post_reset() self._test_scenarios.on_custom_trajectory(self._robot_description_file, self._robot_urdf_file) self._set_enable_trajectory_panel(True) self._models["custom_trajectory_btn"] = btn_builder( label="Custom Trajectory", text="Custom Trajectory", tooltip="Create a basic customizable trajectory and unlock the Custom Trajectory Panel", on_clicked_fn=on_custom_trajectory, ) frame = ui.CollapsableFrame( title="Custom Trajectory Panel", height=0, collapsed=True, enabled=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) self._models["trajectory_panel"] = frame def follow_trajectory(model=None, val=None): self._test_scenarios.create_trajectory_controller(self.articulation, self._get_selected_ee_frame()) def on_add_waypoint(model=None, val=None): self._test_scenarios.add_waypoint() def on_delete_waypoint(model=None, val=None): self._test_scenarios.delete_waypoint() with frame: with ui.VStack(style=get_style(), spacing=5, height=0): self._models["follow_trajectory_btn"] = btn_builder( label="Follow Trajectory", text="Follow Trajectory", tooltip="Follow the trajectory shown in front of the robot", on_clicked_fn=follow_trajectory, ) self._models["add_trajectory_waypoint_btn"] = btn_builder( label="Add Waypoint", text="Add Waypoint", tooltip="Add waypoint to trajectory", on_clicked_fn=on_add_waypoint, ) self._models["remove_trajectory_waypoint_btn"] = btn_builder( label="Remove Waypoint", text="Remove Waypoint", tooltip="Remove waypoint from trajectory", on_clicked_fn=on_delete_waypoint, ) def _build_rmpflow_ui(self): frame = ui.CollapsableFrame( title="RmpFlow", height=0, collapsed=True, enabled=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) self._models["rmpflow_frame"] = frame with frame: with ui.VStack(style=get_style(), spacing=5, height=0): def check_file_type(model=None): path = model.get_value_as_string() if is_yaml_file(path): self._rmpflow_config_yaml = model.get_value_as_string() self._set_enable_rmpflow_buttons(True) else: self._rmpflow_config_yaml = None self._set_enable_rmpflow_buttons(False) carb.log_warn(f"Invalid path to RmpFlow config YAML: {path}") kwargs = { "label": "RmpFlow Config YAML", "default_val": "", "tooltip": "Click the Folder Icon to Set Filepath", "use_folder_picker": True, "item_filter_fn": on_filter_yaml_item, "folder_dialog_title": "Select RmpFlow config YAML file", "folder_button_title": "Select YAML", } self._models["input_rmp_config_file"] = str_builder(**kwargs) self._models["input_rmp_config_file"].add_value_changed_fn(check_file_type) # TODO: remove hard coded line below # self._rmpflow_config_yaml = ( # "/home/arudich/Desktop/Denso/Cobotta_Pro_900_Assets/cobotta_rmpflow_config_final.yaml" # ) def toggle_rmpflow_debug_mode(model=None): self._test_scenarios.toggle_rmpflow_debug_mode() self._models["rmpflow_debug_mode"] = state_btn_builder( label="Debugger", a_text="Debugging Mode", b_text="Normal Mode", tooltip="Toggle Debugging Mode", on_clicked_fn=toggle_rmpflow_debug_mode, ) ###################################################### # Follow Target ###################################################### def rmpflow_follow_target(model=None): ee_frame = self._get_selected_ee_frame() rmpflow_config_dict = { "end_effector_frame_name": ee_frame, "maximum_substep_size": 0.0034, "ignore_robot_state_updates": False, "robot_description_path": self._robot_description_file, "urdf_path": self._robot_urdf_file, "rmpflow_config_path": self._rmpflow_config_yaml, } self.articulation.post_reset() self._test_scenarios.on_rmpflow_follow_target_obstacles(self.articulation, **rmpflow_config_dict) self._models["rmpflow_follow_target_btn"] = btn_builder( label="Follow Target", text="Follow Target", tooltip="Use RmpFlow to follow a target", on_clicked_fn=rmpflow_follow_target, ) self._models["rmpflow_follow_target_btn"].enabled = False ####################################################### # Sinusoidal Target ####################################################### def rmpflow_follow_sinusoidal_target(model=None): ee_frame = self._get_selected_ee_frame() rmpflow_config_dict = { "end_effector_frame_name": ee_frame, "maximum_substep_size": 0.0034, "ignore_robot_state_updates": False, "robot_description_path": self._robot_description_file, "urdf_path": self._robot_urdf_file, "rmpflow_config_path": self._rmpflow_config_yaml, } self.articulation.post_reset() self._test_scenarios.on_rmpflow_follow_sinusoidal_target(self.articulation, **rmpflow_config_dict) self._models["rmpflow_follow_sinusoid_btn"] = btn_builder( label="Follow Sinusoid", text="Follow Sinusoid", tooltip="Use RmpFlow to follow a rotating sinusoidal target", on_clicked_fn=rmpflow_follow_sinusoidal_target, ) self._models["rmpflow_follow_sinusoid_btn"].enabled = False frame = ui.CollapsableFrame( title="Sinusoid Parameters", height=0, collapsed=True, enabled=False, style=get_style(), style_type_name_override="CollapsableFrame", horizontal_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_AS_NEEDED, vertical_scrollbar_policy=ui.ScrollBarPolicy.SCROLLBAR_ALWAYS_ON, ) self._models["rmpflow_sinusoidal_target_frame"] = frame with frame: with ui.VStack(style=get_style(), spacing=5, height=0): self._models["rmpflow_follow_sinusoid_w_z"] = float_builder( label="Vertical Wave Frequency", default_val=0.05, tooltip="Speed [rad/sec] at which the target makes vertical oscilations", ) self._models["rmpflow_follow_sinusoid_rad_z"] = float_builder( label="Vertical Wave Radius", default_val=0.2, tooltip="Height [m] of vertical oscilations" ) self._models["rmpflow_follow_sinusoid_w_xy"] = float_builder( label="Z Axis Rotation Frequency", default_val=0.05, tooltip="Speed [rad/sec] at which the target makes a full circle about the z axis", ) self._models["rmpflow_follow_sinusoid_rad_xy"] = float_builder( label="Distance From Origin", default_val=0.5, tooltip="Distance on the XY plane from the origin [m] of the target", ) self._models["rmpflow_follow_sinusoid_height"] = float_builder( label="Sinusoid Height", default_val=0.5, tooltip="Average height of target [m]" ) def _disable_lula_dropdowns(self): frame_names = ["kinematics_frame", "trajectory_frame", "rmpflow_frame", "trajectory_panel"] for n in frame_names: frame = self._models[n] frame.enabled = False frame.collapsed = True def _enable_load_button(self): self._models["load_config_btn"].enabled = True def _enable_lula_dropdowns(self): if self.articulation is None or self._robot_description_file is None or self._robot_urdf_file is None: return frame_names = ["kinematics_frame", "trajectory_frame", "rmpflow_frame"] for n in frame_names: frame = self._models[n] frame.enabled = True self._test_scenarios.scenario_reset() self._test_scenarios.initialize_ik_solver(self._robot_description_file, self._robot_urdf_file) if self._visualize_end_effector: self._test_scenarios.visualize_ee_frame(self.articulation, self._get_selected_ee_frame()) def _set_enable_trajectory_panel(self, enable): frame = self._models["trajectory_panel"] frame.enabled = enable frame.collapsed = not enable def _set_enable_rmpflow_buttons(self, enable): self._models["rmpflow_follow_target_btn"].enabled = enable self._models["rmpflow_follow_sinusoid_btn"].enabled = enable def _get_selected_ee_frame(self): name = "ee_frame" return self._ee_frame_options[self._models[name].get_item_value_model().as_int]
34,702
Python
40.810843
192
0.554464
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.lula_test_widget/omni/isaac/lula_test_widget/controllers.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.motion_generation import ArticulationKinematicsSolver, PathPlannerVisualizer, ArticulationTrajectory from omni.isaac.core.controllers import BaseController import carb from omni.isaac.core.utils.types import ArticulationAction from omni.isaac.core.articulations import Articulation from omni.isaac.core import objects from typing import Optional import numpy as np class LulaController(BaseController): def __init__(self): pass def forward( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ) -> ArticulationAction: return class KinematicsController(LulaController): def __init__(self, name: str, art_kinematics: ArticulationKinematicsSolver): BaseController.__init__(self, name) self._art_kinematics = art_kinematics def forward( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ) -> ArticulationAction: action, succ = self._art_kinematics.compute_inverse_kinematics( target_end_effector_position, target_end_effector_orientation ) if succ: return action else: carb.log_warn("Failed to compute Inverse Kinematics") return ArticulationAction() class TrajectoryController(LulaController): def __init__(self, name: str, art_trajectory: ArticulationTrajectory): BaseController.__init__(self, name) self._art_trajectory = art_trajectory self._actions = self._art_trajectory.get_action_sequence(1 / 60) self._action_index = 0 def forward( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ): if self._action_index == 0: first_action = self._actions[0] desired_joint_positions = first_action.joint_positions robot_articulation = self._art_trajectory.get_robot_articulation() current_joint_positions = robot_articulation.get_joint_positions() is_none_mask = desired_joint_positions == None desired_joint_positions[is_none_mask] = current_joint_positions[is_none_mask] robot_articulation.set_joint_positions(desired_joint_positions) action = first_action elif self._action_index >= len(self._actions): return ArticulationAction( self._actions[-1].joint_positions, np.zeros_like(self._actions[-1].joint_velocities) ) else: action = self._actions[self._action_index] self._action_index += 1 return action class PathPlannerController(LulaController): def __init__( self, name: str, path_planner_visualizer: PathPlannerVisualizer, cspace_interpolation_max_dist: float = 0.5, frames_per_waypoint: int = 30, ): BaseController.__init__(self, name) self._path_planner_visualizer = path_planner_visualizer self._path_planner = path_planner_visualizer.get_path_planner() self._cspace_interpolation_max_dist = cspace_interpolation_max_dist self._frames_per_waypoint = frames_per_waypoint self._plan = None self._frame_counter = 1 def make_new_plan( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ) -> None: self._path_planner.set_end_effector_target(target_end_effector_position, target_end_effector_orientation) self._path_planner.update_world() self._plan = self._path_planner_visualizer.compute_plan_as_articulation_actions( max_cspace_dist=self._cspace_interpolation_max_dist ) if self._plan is None or self._plan == []: carb.log_warn("No plan could be generated to target pose: " + str(target_end_effector_position)) def forward( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ) -> ArticulationAction: if self._plan is None: # This will only happen the first time the forward function is used self.make_new_plan(target_end_effector_position, target_end_effector_orientation) if len(self._plan) == 0: # The plan is completed; return null action to remain in place self._frame_counter = 1 return ArticulationAction() if self._frame_counter % self._frames_per_waypoint != 0: # Stop at each waypoint in the plan for self._frames_per_waypoint frames self._frame_counter += 1 return self._plan[0] else: self._frame_counter += 1 return self._plan.pop(0) def add_obstacle(self, obstacle: objects, static: bool = False) -> None: self._path_planner.add_obstacle(obstacle, static) def remove_obstacle(self, obstacle: objects) -> None: self._path_planner.remove_obstacle(obstacle) def reset(self) -> None: # PathPlannerController will make one plan per reset self._path_planner.reset() self._plan = None self._frame_counter = 1
5,686
Python
38.220689
116
0.668484
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.lula_test_widget/docs/CHANGELOG.md
# Changelog ## [0.1.0] - 2023-01-06 ### Added - Initial version of Lula Test Widget
87
Markdown
9.999999
37
0.632184
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/config/extension.toml
[core] reloadable = true order = 0 [package] version = "1.2.3" category = "Simulation" title = "Isaac Sim Dynamic Control" description = "Dynamic Control" authors = ["NVIDIA"] repository = "" keywords = ["isaac", "physics"] changelog = "docs/CHANGELOG.md" readme = "docs/README.md" icon = "data/icon.png" writeTarget.kit = true [dependencies] "omni.physx" = {} "omni.timeline" = {} # Needed for simulation to occur "omni.kit.numpy.common" = {} "omni.usd.libs" = {} "omni.kit.commands" = {} "omni.kit.pip_archive" = {} # pulls in numpy "omni.kit.test" = {} [[python.module]] name = "omni.isaac.dynamic_control" [[python.module]] name = "omni.isaac.dynamic_control.tests" [[native.plugin]] path = "bin/*.plugin" recursive = false
735
TOML
18.368421
53
0.672109
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/scripts/extension.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.ext import omni.kit.commands import gc from .. import _dynamic_control EXTENSION_NAME = "Dynamic Control" class Extension(omni.ext.IExt): def on_startup(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() def on_shutdown(self): _dynamic_control.release_dynamic_control_interface(self._dc) gc.collect()
803
Python
31.159999
76
0.759651
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/scripts/utils.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from pxr import Usd def set_scene_physics_type(gpu=False, scene_path="/physicsScene"): import omni from pxr import PhysxSchema, UsdPhysics, UsdGeom, Gf stage = omni.usd.get_context().get_stage() scene = stage.GetPrimAtPath(scene_path) if not scene: scene = UsdPhysics.Scene.Define(stage, scene_path) scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) scene.CreateGravityMagnitudeAttr().Set(9.81 / UsdGeom.GetStageMetersPerUnit(stage)) physxSceneAPI = PhysxSchema.PhysxSceneAPI.Get(stage, scene_path) if physxSceneAPI.GetEnableCCDAttr().HasValue(): physxSceneAPI.GetEnableCCDAttr().Set(True) else: physxSceneAPI.CreateEnableCCDAttr(True) if physxSceneAPI.GetEnableStabilizationAttr().HasValue(): physxSceneAPI.GetEnableStabilizationAttr().Set(True) else: physxSceneAPI.CreateEnableStabilizationAttr(True) if physxSceneAPI.GetSolverTypeAttr().HasValue(): physxSceneAPI.GetSolverTypeAttr().Set("TGS") else: physxSceneAPI.CreateSolverTypeAttr("TGS") if not physxSceneAPI.GetEnableGPUDynamicsAttr().HasValue(): physxSceneAPI.CreateEnableGPUDynamicsAttr(False) if not physxSceneAPI.GetBroadphaseTypeAttr().HasValue(): physxSceneAPI.CreateBroadphaseTypeAttr("MBP") if gpu: physxSceneAPI.GetEnableGPUDynamicsAttr().Set(True) physxSceneAPI.GetBroadphaseTypeAttr().Set("GPU") else: physxSceneAPI.GetEnableGPUDynamicsAttr().Set(False) physxSceneAPI.GetBroadphaseTypeAttr().Set("MBP") def set_physics_frequency(frequency=60): import carb carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(frequency)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(frequency)) async def simulate(seconds, dc=None, art=None, steps_per_sec=60): import omni for frame in range(int(steps_per_sec * seconds)): if art is not None and dc is not None: dc.wake_up_articulation(art) await omni.kit.app.get_app().next_update_async() async def add_cube(stage, path, size, offset, physics=True, mass=0.0) -> Usd.Prim: import omni from pxr import UsdGeom, UsdPhysics cube_geom = UsdGeom.Cube.Define(stage, path) cube_prim = stage.GetPrimAtPath(path) cube_geom.CreateSizeAttr(size) cube_geom.AddTranslateOp().Set(offset) await omni.kit.app.get_app().next_update_async() # Need this to avoid flatcache errors if physics: rigid_api = UsdPhysics.RigidBodyAPI.Apply(cube_prim) rigid_api.CreateRigidBodyEnabledAttr(True) if mass > 0: mass_api = UsdPhysics.MassAPI.Apply(cube_prim) mass_api.CreateMassAttr(mass) UsdPhysics.CollisionAPI.Apply(cube_prim) await omni.kit.app.get_app().next_update_async() return cube_prim
3,406
Python
37.280898
97
0.719612
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/scripts/conversions.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from pxr import Gf from omni.isaac.dynamic_control import _dynamic_control def _vec3d_quatd_to_dctransform(translation: Gf.Vec3d, quat: Gf.Quatd) -> _dynamic_control.Transform: pose_t = (translation[0], translation[1], translation[2]) pose_r = (quat.GetImaginary()[0], quat.GetImaginary()[1], quat.GetImaginary()[2], quat.GetReal()) return _dynamic_control.Transform(pose_t, pose_r) def create_transform(translation, rotation) -> _dynamic_control.Transform: if isinstance(rotation, Gf.Rotation): return _vec3d_quatd_to_dctransform(translation, rotation.GetQuat()) if isinstance(rotation, Gf.Quatd): return _vec3d_quatd_to_dctransform(translation, rotation) def create_transform_from_mat(mat: Gf.Matrix4d) -> _dynamic_control.Transform: trans = mat.ExtractTranslation() q = mat.ExtractRotation().GetQuaternion() (q_x, q_y, q_z) = q.GetImaginary() quat = [q_x, q_y, q_z, q.GetReal()] tr = _dynamic_control.Transform() tr.p = trans tr.r = quat return tr
1,454
Python
39.416666
101
0.72696
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/common.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from pxr import Usd import omni import typing import carb import json import omni.client from omni.client._omniclient import Result def build_server_list() -> typing.List: """Return list with all known servers to check Returns: all_servers (typing.List): List of servers found """ mounted_drives = carb.settings.get_settings().get_settings_dictionary("/persistent/app/omniverse/mountedDrives") all_servers = [] if mounted_drives is not None: mounted_dict = json.loads(mounted_drives.get_dict()) for drive in mounted_dict.items(): all_servers.append(drive[1]) else: carb.log_warn("/persistent/app/omniverse/mountedDrives setting not found") return all_servers def check_server(server: str, path: str) -> bool: """Check a specific server for a path Args: server (str): Name of Nucleus server path (str): Path to search Returns: bool: True if folder is found """ carb.log_info("Checking path: {}{}".format(server, path)) # Increase hang detection timeout omni.client.set_hang_detection_time_ms(10000) result, _ = omni.client.stat("{}{}".format(server, path)) if result == Result.OK: carb.log_info("Success: {}{}".format(server, path)) return True else: carb.log_info("Failure: {}{} not accessible".format(server, path)) return False def get_assets_root_path() -> typing.Union[str, None]: """Tries to find the root path to the Isaac Sim assets on a Nucleus server Returns: url (str): URL of Nucleus server with root path to assets folder. Returns None if Nucleus server not found. """ # 1 - Check /persistent/isaac/asset_root/default setting carb.log_info("Check /persistent/isaac/asset_root/default setting") default_asset_root = carb.settings.get_settings().get("/persistent/isaac/asset_root/default") if default_asset_root: result = check_server(default_asset_root, "/Isaac") if result: result = check_server(default_asset_root, "/NVIDIA") if result: carb.log_info("Assets root found at {}".format(default_asset_root)) return default_asset_root # 2 - Check root on mountedDrives setting connected_servers = build_server_list() if len(connected_servers): for server_name in connected_servers: # carb.log_info("Found {}".format(server_name)) result = check_server(server_name, "/Isaac") if result: result = check_server(server_name, "/NVIDIA") if result: carb.log_info("Assets root found at {}".format(server_name)) return server_name # 3 - Check cloud for /Assets/Isaac/{version_major}.{version_minor} folder cloud_assets_url = carb.settings.get_settings().get("/persistent/isaac/asset_root/cloud") carb.log_info("Checking {}...".format(cloud_assets_url)) if cloud_assets_url: result = check_server(cloud_assets_url, "/Isaac") if result: result = check_server(cloud_assets_url, "/NVIDIA") if result: carb.log_info("Assets root found at {}".format(cloud_assets_url)) return cloud_assets_url carb.log_warn("Could not find assets root folder") return None async def open_stage_async(usd_path: str) -> bool: """ Open the given usd file and replace currently opened stage Args: usd_path (str): Path to open """ if not Usd.Stage.IsSupportedFile(usd_path): raise ValueError("Only USD files can be loaded with this method") usd_context = omni.usd.get_context() usd_context.disable_save_to_recent_files() (result, error) = await omni.usd.get_context().open_stage_async(usd_path) usd_context.enable_save_to_recent_files() return (result, error)
4,352
Python
35.88983
116
0.653263
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_core.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.kit.test import omni.usd from omni.isaac.dynamic_control import _dynamic_control from .common import get_assets_root_path from pxr import Sdf import carb import asyncio # Having a test class dervived from omni.kit.test.AsyncTestCase declared on the root of module will make it auto-discoverable by omni.kit.test class TestCore(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() self._timeline = omni.timeline.get_timeline_interface() await omni.kit.app.get_app().next_update_async() await omni.usd.get_context().new_stage_async() await omni.kit.app.get_app().next_update_async() pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await omni.kit.app.get_app().next_update_async() pass async def test_is_simulating(self): await omni.kit.app.get_app().next_update_async() self.assertFalse(self._dc.is_simulating()) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() self.assertTrue(self._dc.is_simulating()) self._timeline.stop() await omni.kit.app.get_app().next_update_async() self.assertFalse(self._dc.is_simulating()) await omni.kit.app.get_app().next_update_async() pass async def test_print(self): t = _dynamic_control.Transform((1, 2, 3), (1, 2, 3, 4)) v = _dynamic_control.Velocity((1, 2, 3), (4, 5, 6)) self.assertEqual("(1, 2, 3), (1, 2, 3, 4)", str(t)) self.assertEqual("(1, 2, 3), (4, 5, 6)", str(v)) self.assertEqual("(1, 2, 3), (1, 2, 3, 4), (1, 2, 3), (4, 5, 6)", str(_dynamic_control.RigidBodyState(t, v))) self.assertEqual("(1, 2, 3)", str(_dynamic_control.DofState(1, 2, 3))) async def test_delete(self): self._assets_root_path = get_assets_root_path() if self._assets_root_path is None: carb.log_error("Could not find Isaac Sim assets folder") return await omni.kit.app.get_app().next_update_async() self._stage = omni.usd.get_context().get_stage() await omni.kit.app.get_app().next_update_async() prim_a = self._stage.DefinePrim("/World/Franka_1", "Xform") prim_a.GetReferences().AddReference(self._assets_root_path + "/Isaac/Robots/Franka/franka.usd") prim_b = self._stage.DefinePrim("/World/Franka_2", "Xform") prim_b.GetReferences().AddReference(self._assets_root_path + "/Isaac/Robots/Franka/franka.usd") self._timeline.play() await omni.kit.app.get_app().next_update_async() self._handle = self._dc.get_articulation("/World/Franka_1") await omni.kit.app.get_app().next_update_async() with Sdf.ChangeBlock(): omni.usd.commands.DeletePrimsCommand(["/World/Franka_1"]).do() omni.usd.commands.DeletePrimsCommand(["/World/Franka_2"]).do() await omni.kit.app.get_app().next_update_async()
3,714
Python
44.864197
142
0.650512
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_articulation_simple.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.kit.test import math import carb # carb data types are used as return values, need this import numpy as np from pxr import Gf, UsdPhysics, Sdf import omni.physx as _physx import asyncio from omni.isaac.dynamic_control import _dynamic_control from omni.isaac.dynamic_control import utils as dc_utils from omni.isaac.dynamic_control import conversions as dc_conversions # from omni.isaac.core.utils.nucleus import get_assets_root_path from .common import get_assets_root_path from .common import open_stage_async # Having a test class dervived from omni.kit.test.AsyncTestCase declared on the root of module will make it auto-discoverable by omni.kit.test class TestArticulationSimple(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() self._physx_interface = omni.physx.acquire_physx_interface() self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.dynamic_control") self._extension_path = ext_manager.get_extension_path(ext_id) self._assets_root_path = get_assets_root_path() await omni.kit.app.get_app().next_update_async() # open remote self.usd_path = self._assets_root_path + "/Isaac/Robots/Simple/simple_articulation.usd" (result, error) = await open_stage_async(self.usd_path) await omni.kit.app.get_app().next_update_async() self.assertTrue(result) # Make sure the stage loaded self._stage = omni.usd.get_context().get_stage() dc_utils.set_physics_frequency(60) # set this after loading pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await omni.kit.app.get_app().next_update_async() pass async def test_load(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() # Check the object type to make sure its an articulation obj_type = self._dc.peek_object_type("/Articulation") self.assertEqual(obj_type, _dynamic_control.ObjectType.OBJECT_ARTICULATION) # Get handle to articulation and make sure its valid art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # Use articulation handle to do something and make sure its works dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is not None) pass async def test_non_sim(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Articulation should be invalid as sim has not started obj_type = self._dc.peek_object_type("/Articulation") self.assertEqual(obj_type, _dynamic_control.ObjectType.OBJECT_NONE) art = self._dc.get_articulation("/Articulation") self.assertEqual(art, _dynamic_control.INVALID_HANDLE) # force physics to load and some information should be valid self._physx_interface.force_load_physics_from_usd() obj_type = self._dc.peek_object_type("/Articulation") self.assertEqual(obj_type, _dynamic_control.ObjectType.OBJECT_ARTICULATION) art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) rb = self._dc.get_rigid_body("/Articulation/Arm") self.assertNotEqual(rb, _dynamic_control.INVALID_HANDLE) # Not Implemented yet # joint = self._dc.get_joint("/Articulation/Arm/RevoluteJoint") # self.assertNotEqual(joint, _dynamic_control.INVALID_HANDLE) # dof = self._dc.get_dof("/Articulation/Arm/RevoluteJoint") # self.assertNotEqual(joint, _dynamic_control.INVALID_HANDLE) self.assertTrue( self._dc.peek_object_type("/Articulation/Arm/RevoluteJoint"), _dynamic_control.ObjectType.OBJECT_JOINT ) # Dof states will still be none dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is None) dof_props = self._dc.get_articulation_dof_properties(art) self.assertTrue(dof_props is None) async def test_physics_manual(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._physx_interface.start_simulation() self._physx_interface.force_load_physics_from_usd() dt = 1.0 / 60.0 # manually load and step physics self._physx_interface.update_simulation(dt, 0) art = self._dc.get_articulation("/Articulation") dof_ptr = self._dc.find_articulation_dof(art, "RevoluteJoint") slider_body = self._dc.find_articulation_body(art, "Slider") props = self._dc.get_articulation_dof_properties(art) num_dofs = self._dc.get_articulation_dof_count(art) # drive in velocity mode for one second for i in range(num_dofs): props[i]["stiffness"] = 0 props[i]["damping"] = 1e15 self._dc.set_articulation_dof_properties(art, props) new_state = [math.radians(45), 0] self._dc.set_articulation_dof_velocity_targets(art, new_state) for frame in range(0, 60): self._physx_interface.update_simulation(dt, frame * dt) state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) # print(state) new_pose = self._dc.get_rigid_body_pose(slider_body) # after one second it should reach this pose self.assertAlmostEqual(state.pos, math.radians(45), delta=1e-4, msg=f"{state.pos} != {math.radians(45)}") self.assertAlmostEqual(state.vel, math.radians(45), delta=1e-4, msg=f"{state.vel} != {math.radians(45)}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.06778, 1.06781, 0], atol=1e-2), f"{new_pose.p}" ) self._physx_interface.update_transformations( updateToFastCache=False, updateToUsd=True, updateVelocitiesToUsd=True, outputVelocitiesLocalSpace=False ) self._physx_interface.reset_simulation() def call_all_articulation_apis(self, art, joint, dof): self._dc.wake_up_articulation(art) self._dc.get_articulation_name(art) self._dc.get_articulation_path(art) self._dc.get_articulation_body_count(art) self._dc.get_articulation_body(art, 0) self._dc.get_articulation_body(art, 100) self._dc.find_articulation_body(art, "Arm") self._dc.find_articulation_body(art, "DoesntExist") self._dc.get_articulation_root_body(art) self._dc.get_articulation_body_states(art, _dynamic_control.STATE_ALL) self._dc.get_articulation_properties(art) self._dc.set_articulation_properties(art, _dynamic_control.ArticulationProperties()) self._dc.get_articulation_joint_count(art) self._dc.get_articulation_joint(art, 0) self._dc.get_articulation_joint(art, 100) self._dc.find_articulation_joint(art, "RevoluteJoint") self._dc.get_articulation_dof_count(art) self._dc.get_articulation_dof(art, 0) self._dc.get_articulation_dof(art, 100) self._dc.find_articulation_dof(art, "RevoluteJoint") self._dc.find_articulation_dof(art, "DoesntExist") self._dc.find_articulation_dof_index(art, "RevoluteJoint") self._dc.find_articulation_dof_index(art, "DoesntExist") self._dc.get_articulation_dof_properties(art) self._dc.set_articulation_dof_properties(art, []) self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self._dc.set_articulation_dof_states(art, [], _dynamic_control.STATE_ALL) self._dc.set_articulation_dof_position_targets(art, []) self._dc.get_articulation_dof_position_targets(art) self._dc.set_articulation_dof_velocity_targets(art, []) self._dc.get_articulation_dof_velocity_targets(art) self._dc.set_articulation_dof_efforts(art, []) self._dc.get_articulation_dof_efforts(art) self._dc.get_articulation_dof_masses(art) self._dc.get_joint_name(joint) self._dc.get_joint_path(joint) self._dc.get_joint_type(joint) self._dc.get_joint_dof_count(joint) self._dc.get_joint_dof(joint, 0) self._dc.get_joint_dof(joint, 100) self._dc.get_joint_parent_body(joint) self._dc.get_joint_child_body(joint) self._dc.get_dof_name(dof) self._dc.get_dof_path(dof) self._dc.get_dof_type(dof) self._dc.get_dof_joint(dof) self._dc.get_dof_parent_body(dof) self._dc.get_dof_child_body(dof) self._dc.get_dof_state(dof, _dynamic_control.STATE_ALL) self._dc.set_dof_state(dof, _dynamic_control.DofState(), _dynamic_control.STATE_ALL) self._dc.get_dof_position(dof) self._dc.set_dof_position(dof, 0) self._dc.get_dof_velocity(dof) self._dc.set_dof_velocity(dof, 0) self._dc.get_dof_properties(dof) self._dc.set_dof_properties(dof, _dynamic_control.DofProperties()) self._dc.set_dof_position_target(dof, 0) self._dc.set_dof_velocity_target(dof, 0) self._dc.get_dof_position_target(dof) self._dc.get_dof_velocity_target(dof) self._dc.set_dof_effort(dof, 0) self._dc.get_dof_effort(dof) async def test_start_stop(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() # get articulation handle art = self._dc.get_articulation("/Articulation") joint = self._dc.find_articulation_joint(art, "RevoluteJoint") dof = self._dc.find_articulation_dof(art, "RevoluteJoint") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) self.call_all_articulation_apis(art, joint, dof) # make sure handle is still valid after a stop/play self._timeline.stop() await omni.kit.app.get_app().next_update_async() self.call_all_articulation_apis(art, joint, dof) # getting this while stopped should fail dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is None) self._timeline.play() await omni.kit.app.get_app().next_update_async() dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is not None) async def test_delete_joint(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) root_body = self._dc.get_articulation_root_body(art) new_pose = self._dc.get_rigid_body_pose(root_body) self.assertAlmostEqual(new_pose.p.z, 0, msg=f"new_pose.p.z = {new_pose.p.z}") # test to make sure articulation falls when joint is deleted. self._timeline.stop() await omni.kit.app.get_app().next_update_async() omni.usd.commands.DeletePrimsCommand(["/Articulation/CenterPivot/FixedJoint"]).do() # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() await dc_utils.simulate(0.1, self._dc, art) new_pose = self._dc.get_rigid_body_pose(root_body) self.assertAlmostEqual(new_pose.p.z, -0.076222, delta=0.02, msg=f"new_pose.p.z = {new_pose.p.z}") pass async def test_disable_joint(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) root_body = self._dc.get_articulation_root_body(art) new_pose = self._dc.get_rigid_body_pose(root_body) self.assertAlmostEqual(new_pose.p.z, 0, msg=f"new_pose.p.z = {new_pose.p.z}") # test to make sure articulation falls when joint is disabled. self._timeline.stop() await omni.kit.app.get_app().next_update_async() omni.kit.commands.execute( "ChangeProperty", prop_path=Sdf.Path("/Articulation/CenterPivot/FixedJoint.physics:jointEnabled"), value=False, prev=None, ) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() await dc_utils.simulate(0.1, self._dc, art) new_pose = self._dc.get_rigid_body_pose(root_body) self.assertAlmostEqual(new_pose.p.z, -0.076222, delta=0.02, msg=f"new_pose.p.z = {new_pose.p.z}") pass async def test_root_transform(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) root_body = self._dc.get_articulation_root_body(art) pivot_body = self._dc.find_articulation_body(art, "CenterPivot") new_pose = dc_conversions.create_transform(Gf.Vec3d(0.100, 0.200, 0.030), Gf.Rotation(Gf.Vec3d(0, 0, 1), 0)) self._dc.set_rigid_body_pose(root_body, new_pose) await omni.kit.app.get_app().next_update_async() arm_body = self._dc.find_articulation_body(art, "Arm") # Check the arm body pose self.assertEqual( self._dc.get_rigid_body_pose(arm_body), _dynamic_control.Transform((0.60, 0.20, 0.03), (0, 0, 0, 1)) ) # Move the body that corresponds to the root, should act the same as above new_pose = dc_conversions.create_transform(Gf.Vec3d(-0.100, 0.200, 0.030), Gf.Rotation(Gf.Vec3d(0, 0, 1), 0)) self._dc.set_rigid_body_pose(pivot_body, new_pose) await omni.kit.app.get_app().next_update_async() self.assertEqual( self._dc.get_rigid_body_pose(arm_body), _dynamic_control.Transform((0.40, 0.20, 0.03), (0, 0, 0, 1)) ) # Rotate the body in place by 45 degrees, x,y of pose should be the same new_pose = dc_conversions.create_transform(Gf.Vec3d(0, 0, 0), Gf.Rotation(Gf.Vec3d(0, 0, 1), 45)) self._dc.set_rigid_body_pose(pivot_body, new_pose) await omni.kit.app.get_app().next_update_async() new_pose = self._dc.get_rigid_body_pose(arm_body) self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [0.3535535, 0.3535535, 0], atol=1e-5), f"{new_pose.p}", ) ### This will fail as expected because its not a root link # body = self._dc.find_articulation_body(art, "Arm") # new_pose = dc_conversions.create_transform(Gf.Vec3d(10.0, 20.0, 3.0), Gf.Rotation(Gf.Vec3d(0, 0, 1), 90)) # self._dc.set_rigid_body_pose(body, new_pose) pass async def test_root_velocity(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) delete_cmd = omni.usd.commands.DeletePrimsCommand(["/Articulation/CenterPivot/FixedJoint"]) delete_cmd.do() self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) root_body = self._dc.get_articulation_root_body(art) pivot_body = self._dc.find_articulation_body(art, "CenterPivot") self._dc.set_rigid_body_linear_velocity(root_body, (10, 0, 0)) await dc_utils.simulate(0.1, self._dc, art) lin_vel = self._dc.get_rigid_body_linear_velocity(pivot_body) self.assertAlmostEqual(lin_vel.x, 10, delta=1e-3, msg=f"lin_vel.x = {lin_vel.x}") self._dc.set_rigid_body_linear_velocity(root_body, (0, 0, 0)) await dc_utils.simulate(0.1, self._dc, art) lin_vel = self._dc.get_rigid_body_linear_velocity(pivot_body) self.assertAlmostEqual(lin_vel.x, 0, delta=1e-3, msg=f"lin_vel.x = {lin_vel.x}") self._dc.set_rigid_body_angular_velocity(root_body, (10, 0, 0)) await dc_utils.simulate(0.1, self._dc, art) ang_vel = self._dc.get_rigid_body_angular_velocity(pivot_body) self.assertTrue(np.allclose([ang_vel.x, ang_vel.y, ang_vel.z], [10, 0, 0], atol=1e-5), f"{ang_vel}") pass async def test_get_articulation_dof_states(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) # set gravity sideways to force articulation to have state self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 1.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() # get articulation handle art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) await dc_utils.simulate(0.1, self._dc, art) state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_NONE) zeros = np.zeros(2, dtype=np.float32) self.assertTrue(np.array_equal(state["pos"], zeros), f'{state["pos"]}') self.assertTrue(np.array_equal(state["vel"], zeros), f'{state["vel"]}') self.assertTrue(np.array_equal(state["effort"], zeros), f'{state["effort"]}') state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) self.assertFalse(np.array_equal(state["pos"], zeros), f'{state["pos"]}') self.assertTrue(np.array_equal(state["vel"], zeros), f'{state["vel"]}') self.assertTrue(np.array_equal(state["effort"], zeros), f'{state["effort"]}') state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_VEL) self.assertTrue(np.array_equal(state["pos"], zeros), f'{state["pos"]}') self.assertFalse(np.array_equal(state["vel"], zeros), f'{state["vel"]}') self.assertTrue(np.array_equal(state["effort"], zeros), f'{state["effort"]}') state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_EFFORT) self.assertTrue(np.array_equal(state["pos"], zeros), f'{state["pos"]}') self.assertTrue(np.array_equal(state["vel"], zeros), f'{state["vel"]}') self.assertFalse(np.array_equal(state["effort"], zeros), f'{state["effort"]}') state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertFalse(np.array_equal(state["pos"], zeros), f'{state["pos"]}') self.assertFalse(np.array_equal(state["vel"], zeros), f'{state["vel"]}') self.assertFalse(np.array_equal(state["effort"], zeros), f'{state["effort"]}') async def test_set_articulation_dof_states(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() # get articulation handle art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) slider_body = self._dc.find_articulation_body(art, "Slider") await omni.kit.app.get_app().next_update_async() state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) props = self._dc.get_articulation_dof_properties(art) num_dofs = self._dc.get_articulation_dof_count(art) # set both dof state and targets for position for i in range(num_dofs): props[i]["stiffness"] = 1e8 props[i]["damping"] = 1e8 self._dc.set_articulation_dof_properties(art, props) # Rotate 45 degrees and set prismatic to 100 new_state = [math.radians(45), 1.00] state["pos"] = new_state self._dc.set_articulation_dof_states(art, state, _dynamic_control.STATE_POS) self._dc.set_articulation_dof_position_targets(art, new_state) await omni.kit.app.get_app().next_update_async() state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) # check that the states match # print(new_state, state["pos"]) self.assertTrue(np.allclose(new_state, state["pos"]), f'{new_state}, {state["pos"]}') new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.76777, 1.76777, 0], atol=1e-5), f"{new_pose.p}" ) # velocity control test for i in range(num_dofs): props[i]["stiffness"] = 0 props[i]["damping"] = 1e15 self._dc.set_articulation_dof_properties(art, props) new_state = [0, -0.10] state["vel"] = new_state # set both state and target self._dc.set_articulation_dof_states(art, state, _dynamic_control.STATE_VEL) self._dc.set_articulation_dof_velocity_targets(art, new_state) await omni.kit.app.get_app().next_update_async() await omni.kit.app.get_app().next_update_async() # need a second step before dof_states are updated state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) g_vel = self._dc.get_rigid_body_linear_velocity(slider_body) l_vel = self._dc.get_rigid_body_local_linear_velocity(slider_body) self.assertTrue( np.allclose([g_vel.x, g_vel.y, g_vel.z], [-0.0707107, -0.0707107, 0], atol=1e-3), f"g_vel {g_vel}" ) self.assertTrue(np.allclose([l_vel.x, l_vel.y, l_vel.z], [-0.10, 0, 0], atol=1e-3), f"l_vel {l_vel}") self.assertTrue(np.allclose(new_state, state["vel"], atol=1e-3), f'new_state {new_state} ~= {state["vel"]}') # effort control for first joint, second joint is position drive props[0]["stiffness"] = 0 props[0]["damping"] = 0 props[1]["stiffness"] = 1e15 props[1]["damping"] = 1e15 self._dc.set_articulation_dof_properties(art, props) # reset state of articulation and apply effort state["pos"] = [0, 0] state["vel"] = [0, 0] state["effort"] = [1e1, 0] self._dc.set_articulation_dof_position_targets(art, [0, 0]) self._dc.set_articulation_dof_velocity_targets(art, [0, 0]) self._dc.set_articulation_dof_states(art, state, _dynamic_control.STATE_ALL) await dc_utils.simulate(1.0, self._dc, art) state = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_VEL) self.assertAlmostEqual(state["vel"][0], 3.5, delta=1e-2, msg=f'{state["vel"][0]}') async def test_get_gravity_effort(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) gravity = -9.81 self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 1.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(gravity) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") slider_body = self._dc.find_articulation_body(art, "Slider") dof_ptr = self._dc.find_articulation_dof(art, "RevoluteJoint") arm_body = self._dc.find_articulation_body(art, "Arm") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) props = self._dc.get_articulation_dof_properties(art) num_dofs = self._dc.get_articulation_dof_count(art) for i in range(num_dofs): props[i]["driveMode"] = _dynamic_control.DRIVE_FORCE props[i]["stiffness"] = 1e10 props[i]["damping"] = 1e10 props[i]["maxEffort"] = 1e10 self._dc.set_articulation_dof_properties(art, props) await omni.kit.app.get_app().next_update_async() await dc_utils.simulate(1.0, self._dc, art) # check both state apis dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_EFFORT) dof_state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) # compute torque analytically fg_slider = self._dc.get_rigid_body_properties(slider_body).mass * gravity fg_arm = self._dc.get_rigid_body_properties(arm_body).mass * gravity pose_slider = self._dc.get_rigid_body_pose(slider_body) pose_arm = self._dc.get_rigid_body_pose(arm_body) torque_0 = pose_arm.p.x * fg_arm + pose_slider.p.x * fg_slider self.assertAlmostEqual( -torque_0, dof_states["effort"][0], delta=6, msg=f'{-torque_0} != {dof_states["effort"][0]}' ) self.assertAlmostEqual(-torque_0, dof_state.effort, delta=6, msg=f"{-torque_0} != {dof_state.effort}") async def test_dof_state(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # get handles slider_body = self._dc.find_articulation_body(art, "Slider") dof_ptr = self._dc.find_articulation_dof(art, "RevoluteJoint") props = self._dc.get_dof_properties(dof_ptr) pos_target = math.radians(45) vel_target = math.radians(45) # configure for position control props.damping = 1e8 props.stiffness = 1e8 self._dc.set_dof_properties(dof_ptr, props) # use set_dof_state api self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(pos_target, 0, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_position_target(dof_ptr, pos_target) await omni.kit.app.get_app().next_update_async() new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.06066, 1.06066, 0], atol=1e-5), f"{new_pose.p}" ) # reset state before next test self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_position_target(dof_ptr, 0) await omni.kit.app.get_app().next_update_async() # use set_dof_position api self._dc.set_dof_position(dof_ptr, pos_target) self._dc.set_dof_position_target(dof_ptr, pos_target) await omni.kit.app.get_app().next_update_async() new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.06066, 1.06066, 0], atol=1e-5), f"{new_pose.p}" ) # reset state before next test self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_position_target(dof_ptr, 0) await omni.kit.app.get_app().next_update_async() # velocity control props.damping = 1e15 props.stiffness = 0 self._dc.set_dof_properties(dof_ptr, props) # use set_dof_state api self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, vel_target, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_velocity_target(dof_ptr, vel_target) await dc_utils.simulate(1.0, self._dc, art) state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) new_pose = self._dc.get_rigid_body_pose(slider_body) # after one second it should reach this pose self.assertAlmostEqual(state.pos, pos_target, delta=1e-4, msg=f"{state.pos} != {pos_target}") self.assertAlmostEqual(state.vel, vel_target, delta=1e-4, msg=f"{state.vel} != {vel_target}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.0607, 1.0607, 0], atol=1e-2), f"{new_pose.p}" ) # reset state before next test self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_velocity_target(dof_ptr, 0) await omni.kit.app.get_app().next_update_async() # use set_dof_velocity api self._dc.set_dof_velocity(dof_ptr, vel_target) self._dc.set_dof_velocity_target(dof_ptr, vel_target) await dc_utils.simulate(1.0, self._dc, art) new_pose = self._dc.get_rigid_body_pose(slider_body) # after one second it should reach this pose self.assertAlmostEqual(state.pos, pos_target, delta=1e-4, msg=f"{state.pos} != {pos_target}") self.assertAlmostEqual(state.vel, vel_target, delta=1e-4, msg=f"{state.vel} != {vel_target}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [1.0607, 1.0607, 0], atol=1e-2), f"{new_pose.p}" ) # reset state before next test self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) self._dc.set_dof_velocity_target(dof_ptr, 0) await omni.kit.app.get_app().next_update_async() # effort control props.damping = 0 props.stiffness = 0 self._dc.set_dof_properties(dof_ptr, props) self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 1e1), _dynamic_control.STATE_ALL) await dc_utils.simulate(1.0, self._dc, art) # use get_dof_state api state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertAlmostEqual(state.pos, 1.8822, delta=1e-3, msg=f"state.pos = {state.pos}") self.assertAlmostEqual(state.vel, 3.6385, delta=1e-3, msg=f"state.vel = {state.vel}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [-0.46066, 1.4307, 2.34091e-05], atol=1e-2), f"{new_pose.p}", ) self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) await omni.kit.app.get_app().next_update_async() # use set_dof_effort api self._dc.set_dof_effort(dof_ptr, 1e1) self.assertEqual(self._dc.get_dof_effort(dof_ptr), 1e1) await dc_utils.simulate(1.0, self._dc, art) state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertAlmostEqual(state.pos, 1.8822, delta=1e-3, msg=f"state.pos = {state.pos}") self.assertAlmostEqual(state.vel, 3.6385, delta=1e-3, msg=f"state.vel = {state.vel}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [-0.46066, 1.4307, 2.34091e-05], atol=1e-2), f"{new_pose.p}", ) # reset state before next test self._dc.set_dof_state(dof_ptr, _dynamic_control.DofState(0, 0, 0), _dynamic_control.STATE_ALL) await omni.kit.app.get_app().next_update_async() # use set_articulation_dof_efforts api self._dc.set_articulation_dof_efforts(art, [1e1, 0]) self.assertTrue( np.allclose(self._dc.get_articulation_dof_efforts(art), [1e1, 0]), f"{self._dc.get_articulation_dof_efforts(art)}", ) await dc_utils.simulate(1.0, self._dc, art) state = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) new_pose = self._dc.get_rigid_body_pose(slider_body) self.assertAlmostEqual(state.pos, 1.8822, delta=1e-3, msg=f"state.pos = {state.pos}") self.assertAlmostEqual(state.vel, 3.6385, delta=1e-3, msg=f"state.vel = {state.vel}") self.assertTrue( np.allclose([new_pose.p.x, new_pose.p.y, new_pose.p.z], [-0.46066, 1.4307, 2.34091e-05], atol=1e-2), f"new_pose.p = {new_pose.p}", ) # async def test_get_effort(self, gpu=False): # (result, error) = await open_stage_async( # self._assets_root_path + "/Isaac/Robots/Simple/revolute_articulation.usd" # ) # self.assertTrue(result) # Make sure the stage loaded # self._stage = omni.usd.get_context().get_stage() # dc_utils.set_scene_physics_type(gpu) # self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) # gravity = 9.81 # self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) # self._physics_scene.CreateGravityMagnitudeAttr().Set(gravity) # # sensorAPI = PhysxSchema.PhysxArticulationForceSensorAPI.Apply(self._stage.GetPrimAtPath("/Articulation/Arm")) # # sensorAPI.CreateConstraintSolverForcesEnabledAttr().Set(True) # # sensorAPI.CreateForwardDynamicsForcesEnabledAttr().Set(True) # sensorAPI = PhysxSchema.PhysxArticulationForceSensorAPI.Apply( # self._stage.GetPrimAtPath("/Articulation/CenterPivot") # ) # sensorAPI.CreateConstraintSolverForcesEnabledAttr().Set(True) # sensorAPI.CreateForwardDynamicsForcesEnabledAttr().Set(True) # await dc_utils.add_cube(self._stage, "/cube", 10, (90, 0, 20), True, 5) # # Start Simulation and wait # self._timeline.play() # await omni.kit.app.get_app().next_update_async() # art = self._dc.get_articulation("/Articulation") # slider_body = self._dc.find_articulation_body(art, "Arm") # dof_ptr = self._dc.find_articulation_dof(art, "RevoluteJoint") # self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # cube_handle = self._dc.get_rigid_body("/cube") # cube_props = self._dc.get_rigid_body_properties(cube_handle) # cube_props.solver_position_iteration_count = 32 # cube_props.solver_velocity_iteration_count = 32 # self._dc.set_rigid_body_properties(cube_handle, cube_props) # self._timeline.play() # await omni.kit.app.get_app().next_update_async() # props = self._dc.get_articulation_dof_properties(art) # num_dofs = self._dc.get_articulation_dof_count(art) # props[0]["driveMode"] = _dynamic_control.DRIVE_FORCE # props[0]["maxEffort"] = 1e10 # props[0]["stiffness"] = 1e15 # props[0]["damping"] = 1e15 # self._dc.set_articulation_dof_properties(art, props) # # change dof target: modifying current state # dof_vel = [math.radians(45)] # # self._dc.set_articulation_dof_velocity_targets(art, dof_vel) # # await dc_utils.simulate(1.0, self._dc, art) # for frame in range(60 * 1): # if art is not None: # self._dc.wake_up_articulation(art) # await omni.kit.app.get_app().next_update_async() # dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_EFFORT) # # print(dof_states["effort"]) # # fg_slider = self._dc.get_rigid_body_properties(slider_body).mass * gravity # arm_body = self._dc.find_articulation_body(art, "Arm") # fg_arm = self._dc.get_rigid_body_properties(arm_body).mass * gravity # # pose_slider = self._dc.get_rigid_body_pose(slider_body) # pose_arm = self._dc.get_rigid_body_pose(arm_body) # torque_0 = pose_arm.p.x * fg_arm # print(torque_0) # if cube_handle is not _dynamic_control.INVALID_HANDLE: # pose_cube = self._dc.get_rigid_body_pose(cube_handle) # fg_cube = self._dc.get_rigid_body_properties(cube_handle).mass * gravity # torque_body = fg_cube * pose_cube.p.x # print(torque_body) # print(torque_0 + torque_body) # # self.assertLess(dof_states[0][2], -1000) # # print(dof_states[0][2]) # # dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_EFFORT) # # print(dof_states["effort"])
37,315
Python
50.827778
142
0.635133
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_articulation_franka.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.kit.test import carb # carb data types are used as return values, need this import numpy as np from pxr import Gf import asyncio from omni.isaac.dynamic_control import _dynamic_control from omni.isaac.dynamic_control import utils as dc_utils from omni.isaac.dynamic_control import conversions as dc_conversions from .common import get_assets_root_path # Having a test class dervived from omni.kit.test.AsyncTestCase declared on the root of module will make it auto-discoverable by omni.kit.test class TestArticulationFranka(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() self._timeline = omni.timeline.get_timeline_interface() await omni.usd.get_context().new_stage_async() await omni.kit.app.get_app().next_update_async() self._stage = omni.usd.get_context().get_stage() prim = self._stage.DefinePrim("/panda", "Xform") self._assets_root_path = get_assets_root_path() if self._assets_root_path is None: carb.log_error("Could not find Isaac Sim assets folder") return prim.GetReferences().AddReference(self._assets_root_path + "/Isaac/Robots/Franka/franka.usd") dc_utils.set_physics_frequency(60) pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await omni.kit.app.get_app().next_update_async() pass async def test_load(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() # Check the object type to make sure its an articulation obj_type = self._dc.peek_object_type("/panda") self.assertEqual(obj_type, _dynamic_control.ObjectType.OBJECT_ARTICULATION) # Get handle to articulation and make sure its valud art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # Use articulation handle to do something and make sure its works dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is not None) # check basics for articulation num_joints = self._dc.get_articulation_joint_count(art) num_dofs = self._dc.get_articulation_dof_count(art) num_bodies = self._dc.get_articulation_body_count(art) self.assertEqual(num_joints, 11) self.assertEqual(num_dofs, 9) self.assertEqual(num_bodies, 12) # difference between joint and dof fixed_joint_ptr = self._dc.find_articulation_joint(art, "panda_hand_joint") fixed_dof_ptr = self._dc.find_articulation_dof(art, "panda_hand_joint") self.assertNotEqual(fixed_joint_ptr, _dynamic_control.INVALID_HANDLE) self.assertEqual(fixed_dof_ptr, _dynamic_control.INVALID_HANDLE) # get joint properties joint_type = self._dc.get_joint_type(fixed_joint_ptr) joint_dof_count = self._dc.get_joint_dof_count(fixed_joint_ptr) # dof of the joint self.assertEqual(joint_type, _dynamic_control.JOINT_FIXED) self.assertEqual(joint_dof_count, 0) # get dof states dof_ptr = self._dc.find_articulation_dof(art, "panda_finger_joint1") dof_type = self._dc.get_dof_type(dof_ptr) self.assertEqual(dof_type, _dynamic_control.DOF_TRANSLATION) dof_state_v1 = self._dc.get_dof_state(dof_ptr, _dynamic_control.STATE_ALL) # get all dof states for articulation dof_idx = self._dc.find_articulation_dof_index(art, "panda_finger_joint1") dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertTrue(dof_states is not None) dof_state_v2 = dof_states["pos"][dof_idx] # make sure they both match self.assertAlmostEqual(dof_state_v1.pos, dof_state_v2, msg=f"{dof_state_v1.pos} += {dof_state_v2}") pass async def test_teleport(self, gpu=False): dc_utils.set_scene_physics_type(gpu) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) root_body = self._dc.get_articulation_root_body(art) hand_idx = self._dc.find_articulation_body_index(art, "panda_hand") # teleport joints to target pose dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) targets = self._dc.get_articulation_dof_position_targets(art) dof_states["pos"] = targets self._dc.set_articulation_dof_states(art, dof_states, _dynamic_control.STATE_POS) await omni.kit.app.get_app().next_update_async() body_states = self._dc.get_articulation_body_states(art, _dynamic_control.STATE_POS) expected_pos = body_states["pose"]["p"][hand_idx] self.assertTrue( np.allclose( [expected_pos[0], expected_pos[1], expected_pos[2]], [0.36756575, 0.00441444, 0.42769492], atol=1e-5 ), f"[0.36756575, 0.00441444, 0.42769492] != {expected_pos}", ) new_pose = dc_conversions.create_transform(Gf.Vec3d(0.10, 0.10, 0.10), Gf.Rotation(Gf.Vec3d(0, 0, 1), 90)) self._dc.set_rigid_body_pose(root_body, new_pose) await omni.kit.app.get_app().next_update_async() body_states = self._dc.get_articulation_body_states(art, _dynamic_control.STATE_POS) expected_pos = body_states["pose"]["p"][hand_idx] self.assertTrue( np.allclose( [expected_pos[0], expected_pos[1], expected_pos[2]], [0.09577966, 0.45144385, 0.4985129], atol=1e-5 ), f"[0.09577966, 0.45144385, 0.4985129] != {expected_pos}", ) pass async def test_teleport_target(self): self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # turn off gravity because velocity drives will act differently with different damping settings otherwise body_count = self._dc.get_articulation_body_count(art) for bodyIdx in range(body_count): body = self._dc.get_articulation_body(art, bodyIdx) self._dc.set_rigid_body_disable_gravity(body, True) franka_joint_names = [ "panda_joint1", "panda_joint2", "panda_joint3", "panda_joint4", "panda_joint5", "panda_joint6", "panda_joint7", ] # make change to dynamic_control params props = _dynamic_control.DofProperties() props.drive_mode = _dynamic_control.DRIVE_FORCE props.damping = 1e1 props.stiffness = 0 for joint in franka_joint_names: self._dc.set_dof_properties(self._dc.find_articulation_dof(art, joint), props) await omni.kit.app.get_app().next_update_async() # get states with efforts and velocity set to 0 dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) pos_targets = self._dc.get_articulation_dof_position_targets(art) dof_states["pos"] = pos_targets self._dc.set_articulation_dof_states(art, dof_states, _dynamic_control.STATE_ALL) await omni.kit.app.get_app().next_update_async() # record position dof_states1 = np.array(self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL)) # teleport again from a different position without changing any dc params dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) pos_targets = self._dc.get_articulation_dof_position_targets(art) dof_states["pos"] = pos_targets self._dc.set_articulation_dof_states(art, dof_states, _dynamic_control.STATE_ALL) await omni.kit.app.get_app().next_update_async() # record position dof_states2 = np.array(self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL)) # make change to dynamic_control params props = _dynamic_control.DofProperties() props.drive_mode = _dynamic_control.DRIVE_FORCE props.damping = 1e7 props.stiffness = 0 for joint in franka_joint_names: self._dc.set_dof_properties(self._dc.find_articulation_dof(art, joint), props) await omni.kit.app.get_app().next_update_async() # teleport again dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) pos_targets = self._dc.get_articulation_dof_position_targets(art) dof_states["pos"] = pos_targets self._dc.set_articulation_dof_states(art, dof_states, _dynamic_control.STATE_ALL) await omni.kit.app.get_app().next_update_async() dof_states3 = np.array(self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL)) # print("dof_states1:\n", dof_states1) # print("dof_states2:\n", dof_states2) # print("dof_states3:\n", dof_states3) for i in range(len(dof_states1)): for j in range(3): self.assertAlmostEqual( dof_states1[i][j], dof_states2[i][j], delta=1e-4, msg=f"{dof_states1[i][j]} != {dof_states2[i][j]}" ) self.assertAlmostEqual( dof_states1[i][j], dof_states3[i][j], delta=1e-4, msg=f"{dof_states1[i][j]} != {dof_states3[i][j]}" ) pass async def test_movement(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # in order for test to pass, self collisions must be disabled art_props = _dynamic_control.ArticulationProperties() art_props.solver_position_iteration_count = 32 art_props.solver_velocity_iteration_count = 32 art_props.enable_self_collisions = False self._dc.set_articulation_properties(art, art_props) dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) props = self._dc.get_articulation_dof_properties(art) num_dofs = self._dc.get_articulation_dof_count(art) # set all joints to velocity mode for i in range(num_dofs): props["stiffness"][i] = 0 props["damping"][i] = 1e15 dof_states["vel"][i] = -10.0 self._dc.set_articulation_dof_properties(art, props) self._dc.set_articulation_dof_states(art, dof_states, _dynamic_control.STATE_VEL) self._dc.set_articulation_dof_velocity_targets(art, dof_states["vel"]) await dc_utils.simulate(1.5, self._dc, art) # check that we are at the limits dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_POS) for i in range(num_dofs): self.assertAlmostEqual( dof_states["pos"][i], props["lower"][i], delta=1e-3, msg=f'{dof_states["pos"][i]} += {props["lower"][i]}', ) pass async def test_position_franka(self, gpu=False): dc_utils.set_scene_physics_type(gpu) # Start Simulation and wait self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) dof_ptr_left = self._dc.find_articulation_dof(art, "panda_finger_joint1") dof_ptr_right = self._dc.find_articulation_dof(art, "panda_finger_joint2") # set new dof pos target new_pos_list = [0.02, 0.0, 0.04] for new_pos in new_pos_list: for dof_ptr in [dof_ptr_left, dof_ptr_right]: self.assertTrue(self._dc.set_dof_position_target(dof_ptr, new_pos)) await dc_utils.simulate(2.0, self._dc, art) for t in [dof_ptr_left, dof_ptr_right]: self.assertAlmostEqual( self._dc.get_dof_position(dof_ptr), new_pos, delta=0.01, msg=f"{self._dc.get_dof_position(dof_ptr)} += {new_pos}", ) self.assertAlmostEqual( self._dc.get_dof_position_target(dof_ptr), new_pos, delta=0.01, msg=f"{self._dc.get_dof_position_target(dof_ptr)} += {new_pos}", ) # async def test_masses(self, gpu=False): # dc_utils.set_scene_physics_type(gpu) # self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) # self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) # self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) # # Start Simulation and wait # self._timeline.play() # await omni.kit.app.get_app().next_update_async() # art = self._dc.get_articulation("/panda") # self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # dof_masses = self._dc.get_articulation_dof_masses(art) # dof_props = self._dc.get_articulation_dof_properties(art) # num_dofs = self._dc.get_articulation_dof_count(art) # for i in range(num_dofs): # print(dof_props[i], dof_masses[i]) # dof_props[i]["driveMode"] = _dynamic_control.DRIVE_FORCE # dof_props[i]["damping"] = dof_props[i]["damping"] * dof_masses[i] # dof_props[i]["stiffness"] = dof_props[i]["stiffness"] * dof_masses[i] # print(dof_masses[i], dof_props[i]["damping"], dof_props[i]["stiffness"]) # self._dc.set_articulation_dof_properties(art, dof_props) # await dc_utils.simulate(5.0) # # TODO: Test each property async def test_physics_no_render(self): await omni.usd.get_context().new_stage_async() self._stage = omni.usd.get_context().get_stage() self._physx_interface = omni.physx.acquire_physx_interface() self._physx_interface.start_simulation() self._physx_interface.force_load_physics_from_usd() prim = self._stage.DefinePrim("/panda", "Xform") prim.GetReferences().AddReference(self._assets_root_path + "/Isaac/Robots/Franka/franka.usd") self._physx_interface.force_load_physics_from_usd() art = self._dc.get_articulation("/panda") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) # do a zero time step, should not crash self._timeline.play() omni.physx.acquire_physx_interface().update_simulation(elapsedStep=0, currentTime=0) self._timeline.stop() self._timeline.play() await omni.kit.app.get_app().next_update_async()
15,816
Python
46.498498
142
0.62892
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_articulation_other.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.kit.test import carb # carb data types are used as return values, need this import numpy as np from pxr import Gf, UsdPhysics import omni.physx as _physx import asyncio from omni.isaac.dynamic_control import _dynamic_control from omni.isaac.dynamic_control import utils as dc_utils from .common import open_stage_async, get_assets_root_path # Having a test class dervived from omni.kit.test.AsyncTestCase declared on the root of module will make it auto-discoverable by omni.kit.test class TestArticulationOther(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.dynamic_control") self._extension_path = ext_manager.get_extension_path(ext_id) self._assets_root_path = get_assets_root_path() if self._assets_root_path is None: carb.log_error("Could not find Isaac Sim assets folder") return dc_utils.set_physics_frequency(60) await omni.kit.app.get_app().next_update_async() pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await omni.kit.app.get_app().next_update_async() pass async def test_articulation_wheeled(self, gpu=False): (result, error) = await open_stage_async(self._assets_root_path + "/Isaac/Robots/Simple/differential_base.usd") # Make sure the stage loaded self.assertTrue(result) dc_utils.set_scene_physics_type(gpu) dc_utils.set_physics_frequency(60) self._timeline.play() await omni.kit.app.get_app().next_update_async() # wait for robot to fall art = self._dc.get_articulation("/differential_base") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) await dc_utils.simulate(1.0, self._dc, art) left_wheel_ptr = self._dc.find_articulation_dof(art, "left_wheel") right_wheel_ptr = self._dc.find_articulation_dof(art, "right_wheel") self._dc.set_dof_velocity_target(left_wheel_ptr, -2.5) self._dc.set_dof_velocity_target(right_wheel_ptr, 2.5) await dc_utils.simulate(2, self._dc, art) root_body_ptr = self._dc.get_articulation_root_body(art) lin_vel = self._dc.get_rigid_body_linear_velocity(root_body_ptr) ang_vel = self._dc.get_rigid_body_angular_velocity(root_body_ptr) self.assertAlmostEqual(0, np.linalg.norm(lin_vel), 1) self.assertAlmostEqual(2.5, ang_vel.z, delta=1e-1) async def test_articulation_carter(self, gpu=False): (result, error) = await open_stage_async(self._assets_root_path + "/Isaac/Robots/Carter/carter_v1.usd") # Make sure the stage loaded self.assertTrue(result) dc_utils.set_scene_physics_type(gpu) dc_utils.set_physics_frequency(60) self._timeline.play() # wait for robot to fall await dc_utils.simulate(1) art = self._dc.get_articulation("/carter") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) left_wheel_ptr = self._dc.find_articulation_dof(art, "left_wheel") right_wheel_ptr = self._dc.find_articulation_dof(art, "right_wheel") left_dof_idx = self._dc.find_articulation_dof_index(art, "left_wheel") right_dof_idx = self._dc.find_articulation_dof_index(art, "right_wheel") imu_body_ptr = self._dc.find_articulation_body(art, "imu") # the wheels are offset 5cm from the wheel mesh, need to account for that in wheelbase wheel_base = 0.31613607 - 0.05 # in m wheel_radius = 0.240 # in m # Set drive target to a small linearvalue drive_target = 0.05 self._dc.wake_up_articulation(art) self._dc.set_dof_velocity_target(left_wheel_ptr, drive_target) self._dc.set_dof_velocity_target(right_wheel_ptr, drive_target) await dc_utils.simulate(2, self._dc, art) dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) # Check that the current velocity is close to target self.assertAlmostEqual(drive_target, dof_states["vel"][left_dof_idx], delta=0.01) self.assertAlmostEqual(drive_target, dof_states["vel"][right_dof_idx], delta=0.01) # check chassis linear velocity, angular should be zero lin_vel = self._dc.get_rigid_body_linear_velocity(imu_body_ptr) ang_vel = self._dc.get_rigid_body_angular_velocity(imu_body_ptr) self.assertAlmostEqual(drive_target * wheel_radius, np.linalg.norm([lin_vel.x, lin_vel.y, lin_vel.z]), 1) self.assertAlmostEqual(0, np.linalg.norm([ang_vel.x, ang_vel.y, ang_vel.z]), 1) # Set drive target to large linear value self._dc.wake_up_articulation(art) drive_target = 2.5 self._dc.set_dof_velocity_target(left_wheel_ptr, drive_target) self._dc.set_dof_velocity_target(right_wheel_ptr, drive_target) await dc_utils.simulate(1, self._dc, art) dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertAlmostEqual(drive_target, dof_states["vel"][left_dof_idx], delta=0.01) self.assertAlmostEqual(drive_target, dof_states["vel"][right_dof_idx], delta=0.01) lin_vel = self._dc.get_rigid_body_linear_velocity(imu_body_ptr) ang_vel = self._dc.get_rigid_body_angular_velocity(imu_body_ptr) self.assertAlmostEqual( drive_target * wheel_radius, np.linalg.norm([lin_vel.x, lin_vel.y, lin_vel.z]), delta=0.2 ) self.assertAlmostEqual(0, np.linalg.norm([ang_vel.x, ang_vel.y, ang_vel.z]), 1) # stop moving self._dc.set_dof_velocity_target(left_wheel_ptr, 0) self._dc.set_dof_velocity_target(right_wheel_ptr, 0) await dc_utils.simulate(1, self._dc, art) dof_states = self._dc.get_articulation_dof_states(art, _dynamic_control.STATE_ALL) self.assertAlmostEqual(0, dof_states["vel"][left_dof_idx], delta=0.01) self.assertAlmostEqual(0, dof_states["vel"][right_dof_idx], delta=0.01) # spin at slow velocity drive_target = 0.05 self._dc.wake_up_articulation(art) self._dc.set_dof_velocity_target(left_wheel_ptr, -drive_target) self._dc.set_dof_velocity_target(right_wheel_ptr, drive_target) await dc_utils.simulate(2, self._dc, art) lin_vel = self._dc.get_rigid_body_linear_velocity(imu_body_ptr) ang_vel = self._dc.get_rigid_body_angular_velocity(imu_body_ptr) # print(np.linalg.norm(lin_vel), ang_vel) self.assertLess(np.linalg.norm([lin_vel.x, lin_vel.y, lin_vel.z]), 1.5) # the wheels are offset 5cm from the wheel mesh, need to account for that in wheelbase self.assertAlmostEqual(drive_target * wheel_radius / wheel_base, ang_vel[2], delta=0.1) # spin at large velocity drive_target = 1.0 self._dc.wake_up_articulation(art) self._dc.set_dof_velocity_target(left_wheel_ptr, -drive_target) self._dc.set_dof_velocity_target(right_wheel_ptr, drive_target) await dc_utils.simulate(1, self._dc, art) lin_vel = self._dc.get_rigid_body_linear_velocity(imu_body_ptr) ang_vel = self._dc.get_rigid_body_angular_velocity(imu_body_ptr) # print(np.linalg.norm(lin_vel), ang_vel) self.assertLess(np.linalg.norm([lin_vel.x, lin_vel.y, lin_vel.z]), 3.5) self.assertAlmostEqual(drive_target * wheel_radius / wheel_base, ang_vel[2], delta=0.1) async def test_articulation_position_ur10(self, gpu=False): (result, error) = await open_stage_async(self._assets_root_path + "/Isaac/Robots/UR10/ur10.usd") # Make sure the stage loaded self.assertTrue(result) dc_utils.set_scene_physics_type(gpu) dc_utils.set_physics_frequency(60) # Start Simulation and wait timeline = omni.timeline.get_timeline_interface() timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/ur10") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) dof_ptr = self._dc.find_articulation_dof(art, "wrist_1_joint") new_pos_list = [4.0, 2.0, 0, -2, -4] # over pi, under pi , zero, and inverse. for new_pos in new_pos_list: # set new dof pos target self.assertTrue(self._dc.set_dof_position_target(dof_ptr, new_pos)) await dc_utils.simulate(4.0, self._dc, art) dof_pos_new = self._dc.get_dof_position(dof_ptr) self.assertAlmostEqual(dof_pos_new, new_pos, delta=0.02) dof_target_new = self._dc.get_dof_position_target(dof_ptr) self.assertAlmostEqual(dof_target_new, new_pos, delta=0.02) pass async def test_articulation_position_str(self, gpu=False): (result, error) = await open_stage_async(self._assets_root_path + "/Isaac/Robots/Transporter/transporter.usd") # Make sure the stage loaded self.assertTrue(result) dc_utils.set_scene_physics_type(gpu) dc_utils.set_physics_frequency(60) # await asyncio.sleep(1.0) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Transporter") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) dof_ptr = self._dc.find_articulation_dof(art, "lift_joint") # set new dof pos target new_pos_list = [0.04, 0.0, 0.02] for new_pos in new_pos_list: self.assertTrue(self._dc.set_dof_position_target(dof_ptr, new_pos)) await dc_utils.simulate(0.5, self._dc, art) self.assertAlmostEqual(self._dc.get_dof_position(dof_ptr), new_pos, delta=0.01) self.assertAlmostEqual(self._dc.get_dof_position_target(dof_ptr), new_pos, delta=0.01) async def test_revolute_masses(self, gpu=False): (result, error) = await open_stage_async( self._assets_root_path + "/Isaac/Robots/Simple/revolute_articulation.usd" ) # Make sure the stage loaded self.assertTrue(result) self._stage = omni.usd.get_context().get_stage() dc_utils.set_scene_physics_type(gpu) dc_utils.set_physics_frequency(60) self._physics_scene = UsdPhysics.Scene(self._stage.GetPrimAtPath("/physicsScene")) self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(1000) self._timeline.play() await omni.kit.app.get_app().next_update_async() art = self._dc.get_articulation("/Articulation") self.assertNotEqual(art, _dynamic_control.INVALID_HANDLE) dof_masses = self._dc.get_articulation_dof_masses(art) self.assertAlmostEqual(dof_masses[0], 2.0001, delta=1e-2)
11,725
Python
48.68644
142
0.657569
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_rigid.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.kit.test from pxr import Gf, UsdPhysics, Sdf, PhysxSchema from omni.isaac.dynamic_control import _dynamic_control from omni.isaac.dynamic_control import utils as dc_utils from omni.isaac.dynamic_control import conversions as dc_conversions import numpy as np import asyncio class TestRigidBody(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._dc = _dynamic_control.acquire_dynamic_control_interface() self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.dynamic_control") self._extension_path = ext_manager.get_extension_path(ext_id) await omni.usd.get_context().new_stage_async() await omni.kit.app.get_app().next_update_async() self._stage = omni.usd.get_context().get_stage() dc_utils.set_physics_frequency(60) self._physics_scene = UsdPhysics.Scene.Define(self._stage, Sdf.Path("/physicsScene")) dc_utils.set_scene_physics_type(gpu=False, scene_path="/physicsScene") await omni.kit.app.get_app().next_update_async() pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await omni.kit.app.get_app().next_update_async() pass async def test_pose(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") new_pose = _dynamic_control.Transform((1.00, 0, 0), (0, 0, 0, 1)) self._dc.set_rigid_body_pose(handle, new_pose) await dc_utils.simulate(1.0) pos = self._dc.get_rigid_body_pose(handle).p self.assertAlmostEqual(pos.x, 1.00, delta=0.1) async def test_linear_velocity(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") self._dc.set_rigid_body_linear_velocity(handle, (1.00, 0, 0)) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_linear_velocity(handle) self.assertAlmostEqual(vel.x, 1.00, delta=0.1) async def test_angular_velocity(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") self._dc.set_rigid_body_angular_velocity(handle, (5, 0, 0)) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) # cube slows down due to angular damping self.assertAlmostEqual(vel.x, 4.75, delta=0.1) # Actual test, notice it is "async" function, so "await" can be used if needed async def test_gravity(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") pos = self._dc.get_rigid_body_pose(handle).p self._dc.set_rigid_body_disable_gravity(handle, True) self._dc.wake_up_rigid_body(handle) self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) await dc_utils.simulate(1.0) pos = self._dc.get_rigid_body_pose(handle).p self.assertAlmostEqual(pos.z, 0.999, delta=0.1) self._dc.set_rigid_body_disable_gravity(handle, False) self._dc.wake_up_rigid_body(handle) await dc_utils.simulate(1.0) pos = self._dc.get_rigid_body_pose(handle).p self.assertLess(pos.z, 0) pass async def test_rigid_body_properties(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") props = self._dc.get_rigid_body_properties(handle) self._dc.set_rigid_body_properties(handle, props) await dc_utils.simulate(1.0) # TODO: Test each property def call_all_rigid_body_apis(self, handle): self._dc.get_rigid_body_name(handle) self._dc.get_rigid_body_path(handle) self._dc.get_rigid_body_parent_joint(handle) self._dc.get_rigid_body_child_joint_count(handle) self._dc.get_rigid_body_child_joint(handle, 0) self._dc.get_rigid_body_child_joint(handle, 100) self._dc.get_rigid_body_pose(handle) self._dc.set_rigid_body_pose(handle, _dynamic_control.Transform()) self._dc.set_rigid_body_disable_gravity(handle, True) self._dc.set_rigid_body_disable_simulation(handle, False) self._dc.get_rigid_body_linear_velocity(handle) self._dc.get_rigid_body_local_linear_velocity(handle) self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) self._dc.get_rigid_body_angular_velocity(handle) self._dc.set_rigid_body_angular_velocity(handle, (0, 0, 0)) self._dc.apply_body_force(handle, (0, 0, 0), (0, 0, 0), True) self._dc.apply_body_force(handle, (0, 0, 0), (0, 0, 0), False) self._dc.get_relative_body_poses(handle, [handle]) self._dc.get_rigid_body_properties(handle) self._dc.set_rigid_body_properties(handle, _dynamic_control.RigidBodyProperties()) async def test_start_stop(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") self.call_all_rigid_body_apis(handle) self._timeline.stop() await omni.kit.app.get_app().next_update_async() self.call_all_rigid_body_apis(handle) # compare values from dc to usd to see if they match async def test_update_usd(self, gpu=False): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) prim = await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") rigid_prim = UsdPhysics.RigidBodyAPI(prim) await dc_utils.simulate(1.0) dc_pose = self._dc.get_rigid_body_pose(handle) usd_pose = dc_conversions.create_transform_from_mat(omni.usd.utils.get_world_transform_matrix(prim)) self.assertTrue( np.allclose([dc_pose.p.x, dc_pose.p.y, dc_pose.p.z], [usd_pose.p.x, usd_pose.p.y, usd_pose.p.z], atol=1e-2) ) dc_velocity = self._dc.get_rigid_body_linear_velocity(handle) usd_velocity = rigid_prim.GetVelocityAttr().Get() self.assertTrue(np.allclose([dc_velocity.x, dc_velocity.y, dc_velocity.z], usd_velocity, atol=1e-2)) rigid_prim.GetVelocityAttr().Set((0, 0, 0)) await omni.kit.app.get_app().next_update_async() dc_velocity = self._dc.get_rigid_body_linear_velocity(handle) usd_velocity = rigid_prim.GetVelocityAttr().Get() self.assertTrue(np.allclose([dc_velocity.x, dc_velocity.y, dc_velocity.z], usd_velocity, atol=1e-2)) async def test_physics_no_render(self): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, 0.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(0.0) await dc_utils.add_cube(self._stage, "/cube", 1.00, (0, 0, 1.00)) self._physx_interface = omni.physx.acquire_physx_interface() self._physx_interface.start_simulation() self._physx_interface.force_load_physics_from_usd() handle = self._dc.get_rigid_body("/cube") self.assertNotEqual(handle, _dynamic_control.INVALID_HANDLE) self._dc.get_rigid_body_name(handle) self._dc.get_rigid_body_path(handle) self._dc.get_rigid_body_parent_joint(handle) self._dc.get_rigid_body_child_joint_count(handle) self._dc.get_rigid_body_child_joint(handle, 0) self._dc.get_rigid_body_child_joint(handle, 100) self._dc.get_rigid_body_pose(handle) self._dc.set_rigid_body_pose(handle, _dynamic_control.Transform()) self._dc.set_rigid_body_disable_gravity(handle, True) self._dc.set_rigid_body_disable_simulation(handle, False) self._dc.get_rigid_body_linear_velocity(handle) self._dc.get_rigid_body_local_linear_velocity(handle) self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) self._dc.get_rigid_body_angular_velocity(handle) self._dc.set_rigid_body_angular_velocity(handle, (0, 0, 0)) self._dc.apply_body_force(handle, (0, 0, 0), (0, 0, 0), True) self._dc.apply_body_force(handle, (0, 0, 0), (0, 0, 0), False) self._dc.get_relative_body_poses(handle, [handle]) self._dc.get_rigid_body_properties(handle) self._dc.set_rigid_body_properties(handle, _dynamic_control.RigidBodyProperties()) current_time = 0 self._physx_interface.update_simulation(elapsedStep=1.0 / 60.0, currentTime=current_time) self._physx_interface.update_transformations( updateToFastCache=True, updateToUsd=True, updateVelocitiesToUsd=True, outputVelocitiesLocalSpace=False ) async def test_apply_body_force(self): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) prim = await dc_utils.add_cube(self._stage, "/cube", 1.00, (2.00, 0, 1.00), True, 1) # make sure that motion is not damped physxRigidBodyAPI = PhysxSchema.PhysxRigidBodyAPI.Apply(prim) physxRigidBodyAPI.CreateLinearDampingAttr(0) physxRigidBodyAPI.CreateAngularDampingAttr(0) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") pos = self._dc.get_rigid_body_pose(handle).p self._dc.set_rigid_body_disable_gravity(handle, True) self._dc.wake_up_rigid_body(handle) self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) # rotate using local force self._dc.apply_body_force(handle, (0, 0, -1), (-2.00, 0, 0), False) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[1], -0.2, delta=0.001) # clear all motion await omni.kit.app.get_app().next_update_async() self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) self._dc.set_rigid_body_angular_velocity(handle, (0, 0, 0)) new_pose = _dynamic_control.Transform((2.00, 0, 1.00), (0, 0, 0, 1)) self._dc.set_rigid_body_pose(handle, new_pose) await omni.kit.app.get_app().next_update_async() # make sure that we stop moving await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[1], 0.0, delta=0.001) await omni.kit.app.get_app().next_update_async() # rotate the opposite direction via global force self._dc.apply_body_force(handle, (0, 0, 1), (0, 0, 0), True) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[1], 0.2, delta=0.001) async def test_apply_body_torque(self): self._physics_scene.CreateGravityDirectionAttr().Set(Gf.Vec3f(0.0, 0.0, -1.0)) self._physics_scene.CreateGravityMagnitudeAttr().Set(9.81) prim = await dc_utils.add_cube(self._stage, "/cube", 1.00, (2.00, 0, 1.00), True, 1) # make sure that motion is not damped physxRigidBodyAPI = PhysxSchema.PhysxRigidBodyAPI.Apply(prim) physxRigidBodyAPI.CreateLinearDampingAttr(0) physxRigidBodyAPI.CreateAngularDampingAttr(0) self._timeline.play() await omni.kit.app.get_app().next_update_async() handle = self._dc.get_rigid_body("/cube") pos = self._dc.get_rigid_body_pose(handle).p self._dc.set_rigid_body_disable_gravity(handle, True) self._dc.wake_up_rigid_body(handle) self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) # rotate using world torque self._dc.apply_body_torque(handle, (0, 0, -2.00), True) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[2], -0.2, delta=0.001) print(vel) # clear all motion await omni.kit.app.get_app().next_update_async() self._dc.set_rigid_body_linear_velocity(handle, (0, 0, 0)) self._dc.set_rigid_body_angular_velocity(handle, (0, 0, 0)) # flip the rigid body 180 around x so when we apply local torque we rotate the opposite new_pose = _dynamic_control.Transform((2.00, 0, 1.00), (1, 0, 0, 0)) self._dc.set_rigid_body_pose(handle, new_pose) await omni.kit.app.get_app().next_update_async() # make sure that we stop moving await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[1], 0.0, delta=0.001) await omni.kit.app.get_app().next_update_async() # shoudl rotate opposite self._dc.apply_body_torque(handle, (0, 0, -2.00), False) await dc_utils.simulate(1.0) vel = self._dc.get_rigid_body_angular_velocity(handle) self.assertAlmostEqual(vel[2], 0.2, delta=0.001) print(vel)
15,435
Python
48.003174
119
0.645092
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/omni/isaac/dynamic_control/tests/test_pickles.py
# Copyright (c) 2018-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # # NOTE: # omni.kit.test - std python's unittest module with additional wrapping to add suport for async/await tests # For most things refer to unittest docs: https://docs.python.org/3/library/unittest.html import omni.kit.test import carb.tokens import os import asyncio import numpy as np import carb import pickle # Import extension python module we are testing with absolute import path, as if we are external user (other extension) from omni.isaac.dynamic_control import _dynamic_control # Having a test class dervived from omni.kit.test.AsyncTestCase declared on the root of module will make it auto-discoverable by omni.kit.test class TestPickles(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): await omni.kit.app.get_app().next_update_async() pass # After running each test async def tearDown(self): await omni.kit.app.get_app().next_update_async() pass async def test_pickle_float3(self): f3_src = carb.Float3(2.0, -1.5, 13.37) f3_bytes = pickle.dumps(f3_src) f3_dst = pickle.loads(f3_bytes) error_f3 = sum(abs(np.array(f3_src)) - abs(np.array(f3_dst))) self.assertAlmostEqual(error_f3, 0) async def test_pickle_float4(self): f4_src = carb.Float4(2.0, -1.5, 13.37, 42) f4_bytes = pickle.dumps(f4_src) f4_dst = pickle.loads(f4_bytes) error_f4 = sum(abs(np.array(f4_src)) - abs(np.array(f4_dst))) self.assertAlmostEqual(error_f4, 0) async def test_pickle_transform(self): tx_src = _dynamic_control.Transform((0.5, 1.25, -1.0), (0.1, 0.2, 0.3, 0.4)) tx_bytes = pickle.dumps(tx_src) tx_dst = pickle.loads(tx_bytes) error_p = sum(abs(np.array(tx_src.p)) - abs(np.array(tx_dst.p))) error_r = sum(abs(np.array(tx_src.r)) - abs(np.array(tx_dst.r))) self.assertAlmostEqual(error_p, 0) self.assertAlmostEqual(error_r, 0) async def test_pickle_velocity(self): vel_src = _dynamic_control.Velocity((-1.1, -2.2, -3.3), (17, 42, 33)) vel_bytes = pickle.dumps(vel_src) vel_dst = pickle.loads(vel_bytes) error_linear = sum(abs(np.array(vel_src.linear)) - abs(np.array(vel_dst.linear))) error_angular = sum(abs(np.array(vel_src.angular)) - abs(np.array(vel_dst.angular))) self.assertAlmostEqual(error_linear, 0) self.assertAlmostEqual(error_angular, 0) async def test_pickle_rigid_body_state(self): rbs_src = _dynamic_control.RigidBodyState() tx_src = _dynamic_control.Transform((0.5, 1.25, -1.0), (0.1, 0.2, 0.3, 0.4)) vel_src = _dynamic_control.Velocity((-1.1, -2.2, -3.3), (17, 42, 33)) rbs_src.pose = tx_src rbs_src.vel = vel_src rbs_bytes = pickle.dumps(rbs_src) rbs_dst = pickle.loads(rbs_bytes) error_pose_p = sum(abs(np.array(rbs_src.pose.p)) - abs(np.array(rbs_dst.pose.p))) error_pose_r = sum(abs(np.array(rbs_src.pose.r)) - abs(np.array(rbs_dst.pose.r))) error_vel_linear = sum(abs(np.array(rbs_src.vel.linear)) - abs(np.array(rbs_dst.vel.linear))) error_vel_angular = sum(abs(np.array(rbs_src.vel.angular)) - abs(np.array(rbs_dst.vel.angular))) self.assertAlmostEqual(error_pose_p, 0) self.assertAlmostEqual(error_pose_r, 0) self.assertAlmostEqual(error_vel_linear, 0) self.assertAlmostEqual(error_vel_angular, 0) async def test_pickle_dof_state(self): ds_src = _dynamic_control.DofState(2.0, -1.5, 5.5) ds_bytes = pickle.dumps(ds_src) ds_dst = pickle.loads(ds_bytes) error_pos = abs(np.array(ds_src.pos)) - abs(np.array(ds_dst.pos)) error_vel = abs(np.array(ds_src.vel)) - abs(np.array(ds_dst.vel)) error_effort = abs(np.array(ds_src.effort)) - abs(np.array(ds_dst.effort)) self.assertAlmostEqual(error_pos, 0) self.assertAlmostEqual(error_vel, 0) self.assertAlmostEqual(error_effort, 0) async def test_pickle_dof_properties(self): dp_src = _dynamic_control.DofProperties() dp_src.type = _dynamic_control.DOF_ROTATION dp_src.has_limits = True dp_src.lower = -3.14 dp_src.upper = 1.57 dp_src.drive_mode = _dynamic_control.DRIVE_ACCELERATION dp_src.max_velocity = 123.4 dp_src.max_effort = 1234.5 dp_src.stiffness = 1e4 dp_src.damping = 1e3 dp_bytes = pickle.dumps(dp_src) dp_dst = pickle.loads(dp_bytes) self.assertEqual(dp_dst.type, dp_src.type) self.assertTrue(dp_dst.has_limits) self.assertAlmostEqual(dp_dst.lower, dp_src.lower) self.assertAlmostEqual(dp_dst.upper, dp_src.upper) self.assertEqual(dp_dst.drive_mode, dp_src.drive_mode) self.assertAlmostEqual(dp_dst.max_velocity, dp_src.max_velocity) self.assertAlmostEqual(dp_dst.max_effort, dp_src.max_effort) self.assertAlmostEqual(dp_dst.stiffness, dp_src.stiffness) self.assertAlmostEqual(dp_dst.damping, dp_src.damping) async def test_pickle_attractor_properties(self): ap_src = _dynamic_control.AttractorProperties() ap_src.body = 123456789 ap_src.axes = _dynamic_control.AXIS_ALL ap_src.target.p = (-1, -2, -3) ap_src.target.r = (1, 2, 3, 4) ap_src.offset.p = (-0.1, -0.2, -0.3) ap_src.offset.r = (0.1, 0.2, 0.3, 0.4) ap_src.stiffness = 1e5 ap_src.damping = 1e4 ap_src.force_limit = 1e3 ap_bytes = pickle.dumps(ap_src) ap_dst = pickle.loads(ap_bytes) self.assertEqual(ap_dst.body, ap_src.body) self.assertEqual(ap_dst.axes, ap_src.axes) error_target_p = sum(abs(np.array(ap_src.target.p)) - abs(np.array(ap_dst.target.p))) error_target_r = sum(abs(np.array(ap_src.target.r)) - abs(np.array(ap_dst.target.r))) error_offset_p = sum(abs(np.array(ap_src.offset.p)) - abs(np.array(ap_dst.offset.p))) error_offset_r = sum(abs(np.array(ap_src.offset.r)) - abs(np.array(ap_dst.offset.r))) self.assertAlmostEqual(error_target_p, 0) self.assertAlmostEqual(error_target_r, 0) self.assertAlmostEqual(error_offset_p, 0) self.assertAlmostEqual(error_offset_r, 0) self.assertAlmostEqual(ap_dst.stiffness, ap_src.stiffness) self.assertAlmostEqual(ap_dst.damping, ap_src.damping) self.assertAlmostEqual(ap_dst.force_limit, ap_src.force_limit) async def test_pickle_articulation_properties(self): ap_src = _dynamic_control.ArticulationProperties() ap_src.solver_position_iteration_count = 3 ap_src.solver_velocity_iteration_count = 4 ap_src.enable_self_collisions = True ap_bytes = pickle.dumps(ap_src) ap_dst = pickle.loads(ap_bytes) self.assertEqual(ap_dst.solver_position_iteration_count, ap_src.solver_position_iteration_count) self.assertEqual(ap_dst.solver_velocity_iteration_count, ap_src.solver_velocity_iteration_count) self.assertEqual(ap_dst.enable_self_collisions, ap_src.enable_self_collisions) async def test_pickle_rigid_body_properties(self): rb_src = _dynamic_control.RigidBodyProperties() rb_src.mass = 14.0 rb_src.moment = carb.Float3(1.0, 2.0, 3.0) rb_src.max_depeneration_velocity = 2.0 rb_src.max_contact_impulse = 3.0 rb_src.solver_position_iteration_count = 4 rb_src.solver_velocity_iteration_count = 5 rb_bytes = pickle.dumps(rb_src) rb_dst = pickle.loads(rb_bytes) self.assertEqual(rb_dst.mass, rb_src.mass) error_moment = sum(abs(np.array(rb_dst.moment)) - abs(np.array(rb_src.moment))) self.assertAlmostEqual(error_moment, 0) self.assertEqual(rb_dst.max_depeneration_velocity, rb_src.max_depeneration_velocity) self.assertEqual(rb_dst.max_contact_impulse, rb_src.max_contact_impulse) self.assertEqual(rb_dst.solver_position_iteration_count, rb_src.solver_position_iteration_count) self.assertEqual(rb_dst.solver_velocity_iteration_count, rb_src.solver_velocity_iteration_count)
8,579
Python
46.932961
142
0.656836
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/docs/CHANGELOG.md
# Changelog ## [1.2.3] - 2023-01-21 ### Fixed - Fix when multiple objects shared the same prim name using the isaac:nameOverride attribute for get_name ## [1.2.2] - 2022-10-20 ### Fixed - test golden values ## [1.2.1] - 2022-10-17 ### Fixed - explicitly handle prim deletion ## [1.2.0] - 2022-09-27 ### Changed - tests to use nucleus assets ### Removed - usd files local to extension ## [1.1.1] - 2022-09-07 ### Fixed - Fixes for kit 103.5 ## [1.1.0] - 2022-08-12 ### Added - cMassLocalPose to DcRigidBodyProperties ## [1.0.1] - 2022-08-09 ### Changed - Removed simple_articulation.usd, test_articulation_simple uses Nucleus asset ## [1.0.0] - 2022-05-11 ### Changed - non-backwards compatible change: dof indexing matches physx tensor API ## [0.2.2] - 2022-04-29 ### Fixed - Handle physx unwrapped revolute joints ## [0.2.1] - 2022-02-13 ### Fixed - Properly delete handles on prim deletion ## [0.2.0] - 2022-01-14 ### Fixed - Error message when waking up a kinematic rigid body - Error message when setting linear velocity on a body with simulation disabled - Error message when setting angular velocity on a body with simulation disabled ## [0.1.8] - 2021-08-16 ### Added - get_effort - get_articulation_dof_efforts - apply_body_torque ### Fixed - inconsistent return types - crash when stepping with a zero timestep as first step ### Changed - apply_effort -> set_effort - apply_articulation_dof_efforts -> set_articulation_dof_efforts - handle refresh messages are printed out as info messages, instead of always printing - apply_body_force now has a bool to specify if the force is global or local ## [0.1.7] - 2021-08-16 ### Added - Sleep functions for rigid bodies and articulations ### Changed - return types use size_t instead of int where appropriate ## [0.1.6] - 2021-08-04 ### Changed - DriveMode is now either DRIVE_FORCE or DRIVE_ACCELERATION, default is acceleration - Position/Velocity drive is not specified via DriveMode - All API calls verify if simulating, return otherwise - set_dof_properties will not enable or change drive limits - set_dof_state takes StateFlags to apply specific states - get_dof_state takes StateFlags to set which states to get ### Added - State variables can be printed - ArticulationProperties to control articulation settings - RigidBodyProperties can control iteration counts and contact impulse settings - get_articulation_properties - set_articulation_properties - get_articulation_dof_position_targets - get_articulation_dof_velocity_targets - get_articulation_dof_masses - set_rigid_body_properties - get_dof_properties - unit tests for most articulation, rigid body, dof and joint apis - utilities for common scene setup and testing ### Removed - get_articulation_dof_state_derivatives - DriveModes DRIVE_NONE, DRIVE_POS, DRIVE_VEL ### Fixed - apply_body_force now applies a force at a point - set_dof_properties does not break position/velocity drives - dof efforts report correct forces/torques due to gravity - when changing state of a dof or a root link, unrelated state values are not applied anymore - set_dof_state applies efforts now - get_dof_properties works correctly now ## [0.1.5] - 2021-07-23 ### Added - Split samples from extension ## [0.1.4] - 2021-07-14 ### Added - now works when running without editor/timeline and only physx events. - fixed crash with setting dof properties ## [0.1.3] - 2021-05-24 ### Added - force and torque sensors ## [0.1.2] - 2021-02-17 ### Added - update to python 3.7 - update to omni.kit.uiapp ## [0.1.1] - 2020-12-11 ### Added - Add unit tests to extension ## [0.1.0] - 2020-12-03 ### Added - Initial version of Isaac Sim Dynamic Control Extension
3,695
Markdown
23.64
105
0.728552
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.dynamic_control/docs/index.rst
Dynamic Control [omni.isaac.dynamic_control] ###################################################### The Dynamic Control extension provides a set of utilities to control physics objects. It provides opaque handles for different physics objects that remain valid between PhysX scene resets, which occur whenever play or stop is pressed. Basic Usage =========== Start physics simulation, at least one frame of simulation must occur before the Dynamic Control interface will become fully active. .. code-block:: python :linenos: import omni omni.timeline.get_timeline_interface().play() Acquire the Dynamic Control interface and interact with an articulation. The code block below assumes a Franka Emika Panda robot is in the stage with a base path of /Franka .. code-block:: python :linenos: from omni.isaac.dynamic_control import _dynamic_control dc = _dynamic_control.acquire_dynamic_control_interface() # Get a handle to the Franka articulation # This handle will automatically update if simulation is stopped and restarted art = dc.get_articulation("/Franka") # Get information about the structure of the articulation num_joints = dc.get_articulation_joint_count(art) num_dofs = dc.get_articulation_dof_count(art) num_bodies = dc.get_articulation_body_count(art) # Get a specific degree of freedom on an articulation dof_ptr = dc.find_articulation_dof(art, "panda_joint2") dof_state = dc.get_dof_state(dof_ptr) # print position for the degree of freedom print(dof_state.pos) # This should be called each frame of simulation if state on the articulation is being changed. dc.wake_up_articulation(art) dc.set_dof_position_target(dof_ptr, -1.5) Acquiring Extension Interface ============================== .. automethod:: omni.isaac.dynamic_control._dynamic_control.acquire_dynamic_control_interface .. automethod:: omni.isaac.dynamic_control._dynamic_control.release_dynamic_control_interface Dynamic Control API ==================== .. autoclass:: omni.isaac.dynamic_control._dynamic_control.DynamicControl :members: :undoc-members: :exclude-members: Transform and Velocity ====================== .. autoclass:: omni.isaac.dynamic_control._dynamic_control.Transform :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.Velocity :members: :undoc-members: :show-inheritance: Types ===== .. autoclass:: omni.isaac.dynamic_control._dynamic_control.ObjectType :members: :show-inheritance: :exclude-members: name .. autoclass:: omni.isaac.dynamic_control._dynamic_control.DofType :members: :show-inheritance: :exclude-members: name .. autoclass:: omni.isaac.dynamic_control._dynamic_control.JointType :members: :show-inheritance: :exclude-members: name .. autoclass:: omni.isaac.dynamic_control._dynamic_control.DriveMode :members: :show-inheritance: :exclude-members: name Properties ========== .. autoclass:: omni.isaac.dynamic_control._dynamic_control.ArticulationProperties :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.RigidBodyProperties :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.DofProperties :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.AttractorProperties :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.D6JointProperties :members: :undoc-members: :show-inheritance: States ========== .. autoclass:: omni.isaac.dynamic_control._dynamic_control.RigidBodyState :members: :undoc-members: :show-inheritance: .. autoclass:: omni.isaac.dynamic_control._dynamic_control.DofState :members: :undoc-members: :show-inheritance: Constants ========= Object handles -------------- .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.INVALID_HANDLE State Flags ----------- .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.STATE_NONE .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.STATE_POS .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.STATE_VEL .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.STATE_EFFORT .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.STATE_ALL Axis Flags ---------- .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_NONE .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_X .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_Y .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_Z .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_TWIST .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_SWING_1 .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_SWING_2 .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_ALL_TRANSLATION .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_ALL_ROTATION .. autoattribute:: omni.isaac.dynamic_control._dynamic_control.AXIS_ALL
5,319
reStructuredText
28.72067
148
0.715172
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Festo/Cobot/rmpflow/festo_cobot_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - a1 - a2 - a3 - a4 - a5 - a6 default_q: [ 0.0,0.0,0.0,-0.0,-0.0,-0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - link_1: - "center": [0.0, 0.032, 0.29] "radius": 0.11 - "center": [0.0, 0.073, 0.331] "radius": 0.08 - link_2: - "center": [-0.0, 0.024, -0.0] "radius": 0.08 - "center": [-0.0, 0.018, 0.11] "radius": 0.07 - "center": [-0.0, 0.021, 0.051] "radius": 0.08 - "center": [-0.0, 0.315, 0.132] "radius": 0.06 - "center": [-0.0, 0.26, 0.128] "radius": 0.062 - "center": [-0.0, 0.202, 0.124] "radius": 0.064 - "center": [-0.0, 0.143, 0.12] "radius": 0.066 - "center": [-0.0, 0.082, 0.115] "radius": 0.068 - "center": [-0.0, 0.336, 0.057] "radius": 0.06 - "center": [-0.0, 0.326, 0.095] "radius": 0.06 - link_3: - "center": [0.0, 0.035, 0.066] "radius": 0.06 - "center": [0.0, 0.0, 0.0] "radius": 0.07 - "center": [0.0, 0.001, 0.034] "radius": 0.065 - link_4: - "center": [0.0, -0.0, 0.124] "radius": 0.06 - "center": [-0.0, 0.118, 0.163] "radius": 0.07 - "center": [0.0, 0.037, 0.136] "radius": 0.063 - "center": [-0.0, 0.077, 0.149] "radius": 0.066 - "center": [-0.0, 0.131, 0.315] "radius": 0.06 - "center": [-0.0, 0.122, 0.203] "radius": 0.067 - "center": [-0.0, 0.125, 0.242] "radius": 0.065 - "center": [-0.0, 0.128, 0.279] "radius": 0.062 - "center": [0.0, 0.096, 0.327] "radius": 0.05 - link_5: - "center": [-0.0, -0.051, -0.0] "radius": 0.06 - "center": [0.0, 0.068, 0.0] "radius": 0.06 - "center": [-0.0, -0.011, -0.0] "radius": 0.06 - "center": [0.0, 0.029, 0.0] "radius": 0.06 - "center": [-0.0, 0.0, -0.028] "radius": 0.06 - link_6: - "center": [0.0, -0.0, 0.106] "radius": 0.05 - "center": [0.017, 0.047, 0.118] "radius": 0.02 - "center": [-0.008, 0.048, 0.12] "radius": 0.02
2,769
YAML
26.425742
79
0.522571
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/ur10/rmpflow/ur10_robot_description.yaml
# Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # The robot description file defines the generalized coordinates and how to map # those to the underlying URDF DOFs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF, except when otherwise specified below under # cspace_urdf_bridge. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint root_link: world default_q: [-1.57, -1.57, -1.57, -1.57, 1.57, 0] collision_spheres: - upper_arm_link: - center: [0.0, -0.045, 0.01] radius: 0.1 - center: [0.0, -0.045, 0.06] radius: 0.09 - center: [0.0, -0.045, 0.12] radius: 0.06 - center: [0.0, -0.045, 0.18] radius: 0.06 - center: [0.0, -0.045, 0.24] radius: 0.06 - center: [0.0, -0.045, 0.3] radius: 0.06 - center: [0.0, -0.045, 0.36] radius: 0.06 - center: [0.0, -0.045, 0.42] radius: 0.06 - center: [0.0, -0.045, 0.48] radius: 0.06 - center: [0.0, -0.045, 0.54] radius: 0.06 - center: [0.0, -0.045, 0.6] radius: 0.08 - forearm_link: - center: [0.0, 0.0, 0.0] radius: 0.08 - center: [0.0, 0.0, 0.06] radius: 0.07 - center: [0.0, 0.0, 0.12] radius: 0.05 - center: [0.0, 0.0, 0.18] radius: 0.05 - center: [0.0, 0.0, 0.24] radius: 0.05 - center: [0.0, 0.0, 0.30] radius: 0.05 - center: [0.0, 0.0, 0.36] radius: 0.05 - center: [0.0, 0.0, 0.42] radius: 0.05 - center: [0.0, 0.0, 0.48] radius: 0.05 - center: [0.0, 0.0, 0.54] radius: 0.05 - center: [0.0, 0.0, 0.57] radius: 0.065 - wrist_1_link: - center: [0.0, 0.0, 0.0] radius: 0.05 - center: [0.0, 0.055, 0.0] radius: 0.05 - center: [0.0, 0.11, 0.0] radius: 0.065 - wrist_2_link: - center: [0.0, 0.0, 0.0] radius: 0.05 - center: [0.0, 0.0, 0.055] radius: 0.05 - center: [0.0, 0, 0.11] radius: 0.065 - wrist_3_link: - center: [0.0, 0.0, 0.0] radius: 0.045 - center: [0.0, 0.05, 0.0] radius: 0.05
2,692
YAML
27.347368
79
0.543091
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/universal_robots/ur3/rmpflow/ur3_robot_description.yaml
# The robot description defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint default_q: [ 0.0,-1.0,0.9,0.0,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - shoulder_link: - "center": [-0.0, 0.0, -0.02] "radius": 0.055 - "center": [0.01, -0.019, -0.0] "radius": 0.045 - "center": [0.004, -0.007, 0.019] "radius": 0.05 - upper_arm_link: - "center": [0.003, 0.002, 0.104] "radius": 0.052 - "center": [-0.232, 0.002, 0.112] "radius": 0.043 - "center": [-0.121, -0.001, 0.12] "radius": 0.042 - "center": [-0.163, 0.002, 0.118] "radius": 0.041 - "center": [-0.086, 0.001, 0.121] "radius": 0.041 - "center": [-0.02, 0.014, 0.121] "radius": 0.041 - "center": [-0.026, -0.019, 0.126] "radius": 0.035 - "center": [-0.238, 0.0, 0.146] "radius": 0.04 - forearm_link: - "center": [-0.013, 0.001, 0.04] "radius": 0.042 - "center": [-0.214, -0.002, 0.035] "radius": 0.039 - "center": [-0.171, -0.0, 0.027] "radius": 0.036 - "center": [-0.083, 0.0, 0.029] "radius": 0.036 - "center": [0.009, -0.006, 0.054] "radius": 0.034 - "center": [-0.204, 0.006, 0.003] "radius": 0.036 - "center": [-0.103, 0.002, 0.028] "radius": 0.035 - "center": [0.006, 0.01, 0.054] "radius": 0.034 - "center": [-0.213, 0.005, 0.043] "radius": 0.037 - "center": [-0.022, -0.002, 0.025] "radius": 0.033 - "center": [-0.137, 0.001, 0.027] "radius": 0.036 - "center": [-0.05, 0.0, 0.034] "radius": 0.039 - wrist_1_link: - "center": [0.0, -0.009, -0.002] "radius": 0.041 - "center": [-0.003, 0.019, 0.001] "radius": 0.037 - "center": [0.006, 0.007, -0.024] "radius": 0.033 - wrist_2_link: - "center": [-0.0, 0.0, -0.015] "radius": 0.041 - "center": [-0.0, 0.012, 0.001] "radius": 0.039 - "center": [-0.0, -0.018, -0.001] "radius": 0.04 - wrist_3_link: - "center": [0.0, 0.002, -0.025] "radius": 0.035
2,844
YAML
28.329897
80
0.549226
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/universal_robots/ur16e/rmpflow/ur16e_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint default_q: [ 0.0,-1.2,1.1,0.0,0.0,-0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - shoulder_link: - "center": [0.0, 0.0, 0.01] "radius": 0.085 - "center": [0.003, -0.022, -0.009] "radius": 0.082 - "center": [-0.021, -0.041, 0.036] "radius": 0.064 - upper_arm_link: - "center": [-0.007, 0.0, 0.177] "radius": 0.085 - "center": [-0.475, -0.0, 0.176] "radius": 0.068 - "center": [-0.061, -0.0, 0.176] "radius": 0.084 - "center": [-0.317, -0.0, 0.176] "radius": 0.065 - "center": [-0.214, -0.001, 0.174] "radius": 0.063 - "center": [-0.382, -0.0, 0.176] "radius": 0.065 - "center": [-0.165, -0.001, 0.175] "radius": 0.064 - "center": [-0.002, 0.002, 0.188] "radius": 0.083 - "center": [-0.265, 0.0, 0.174] "radius": 0.063 - "center": [-0.465, 0.003, 0.034] "radius": 0.088 - forearm_link: - "center": [-0.074, -0.0, 0.04] "radius": 0.068 - "center": [-0.191, 0.0, 0.039] "radius": 0.063 - "center": [-0.301, 0.0, 0.037] "radius": 0.058 - "center": [-0.359, -0.001, 0.059] "radius": 0.055 - "center": [-0.02, 0.003, 0.051] "radius": 0.058 - "center": [-0.138, -0.0, 0.044] "radius": 0.065 - "center": [-0.248, 0.001, 0.056] "radius": 0.059 - "center": [-0.361, 0.004, 0.029] "radius": 0.052 - wrist_1_link: - "center": [0.0, 0.005, -0.007] "radius": 0.056 - "center": [-0.001, -0.02, 0.0] "radius": 0.055 - wrist_2_link: - "center": [-0.0, 0.001, -0.0] "radius": 0.056 - "center": [-0.0, 0.021, 0.0] "radius": 0.055 - "center": [-0.004, -0.011, -0.011] "radius": 0.053 - wrist_3_link: - "center": [-0.016, 0.002, -0.025] "radius": 0.034 - "center": [0.016, -0.011, -0.024] "radius": 0.034 - "center": [0.009, 0.018, -0.025] "radius": 0.034
2,786
YAML
28.336842
79
0.548816
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/universal_robots/ur3e/rmpflow/ur3e_robot_description.yaml
# The robot description defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint default_q: [ 0.0,-1.0,0.9,0.0,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - shoulder_link: - "center": [-0.0, 0.0, -0.02] "radius": 0.055 - "center": [0.01, -0.019, -0.0] "radius": 0.045 - "center": [0.004, -0.007, 0.019] "radius": 0.05 - wrist_1_link: - "center": [0.0, -0.009, -0.002] "radius": 0.041 - "center": [-0.003, 0.019, 0.001] "radius": 0.037 - "center": [0.006, 0.007, -0.024] "radius": 0.033 - wrist_2_link: - "center": [-0.0, 0.0, -0.015] "radius": 0.041 - "center": [-0.0, 0.012, 0.001] "radius": 0.039 - "center": [-0.0, -0.018, -0.001] "radius": 0.04 - wrist_3_link: - "center": [0.0, 0.002, -0.025] "radius": 0.035 - upper_arm_link: - "center": [-0.008, 0.0, 0.127] "radius": 0.056 - "center": [-0.091, 0.0, 0.127] "radius": 0.054 - "center": [-0.174, -0.0, 0.13] "radius": 0.051 - "center": [-0.242, -0.0, 0.106] "radius": 0.048 - "center": [-0.15, 0.0, 0.105] "radius": 0.051 - "center": [0.0, 0.0, 0.11] "radius": 0.056 - "center": [-0.245, 0.005, 0.143] "radius": 0.043 - "center": [-0.058, -0.002, 0.105] "radius": 0.052 - "center": [-0.055, 0.001, 0.132] "radius": 0.055 - "center": [-0.14, 0.0, 0.133] "radius": 0.052 - forearm_link: - "center": [-0.084, -0.0, 0.033] "radius": 0.044 - "center": [-0.157, -0.0, 0.035] "radius": 0.043 - "center": [-0.008, -0.0, 0.053] "radius": 0.043 - "center": [-0.213, 0.0, 0.074] "radius": 0.042 - "center": [-0.213, -0.0, 0.021] "radius": 0.042 - "center": [-0.13, -0.0, 0.022] "radius": 0.044 - "center": [-0.003, -0.003, 0.041] "radius": 0.037 - "center": [-0.118, 0.001, 0.039] "radius": 0.044 - "center": [-0.059, -0.001, 0.037] "radius": 0.044 - "center": [-0.168, -0.0, 0.016] "radius": 0.043
2,830
YAML
28.185567
80
0.544523
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/universal_robots/ur10e/rmpflow/ur10e_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint default_q: [ -0.0,-1.2,1.1,0.0,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - shoulder_link: - "center": [0.0, 0.0, 0.01] "radius": 0.085 - "center": [0.003, -0.022, -0.009] "radius": 0.082 - upper_arm_link: - "center": [-0.031, 0.0, 0.176] "radius": 0.084 - "center": [-0.589, 0.0, 0.177] "radius": 0.068 - "center": [-0.418, -0.0, 0.176] "radius": 0.064 - "center": [-0.224, -0.0, 0.176] "radius": 0.064 - "center": [-0.309, 0.002, 0.176] "radius": 0.063 - "center": [-0.14, -0.001, 0.177] "radius": 0.064 - "center": [-0.516, 0.0, 0.176] "radius": 0.064 - "center": [0.008, -0.001, 0.184] "radius": 0.077 - "center": [-0.617, -0.002, 0.167] "radius": 0.063 - "center": [-0.068, -0.005, 0.179] "radius": 0.079 - forearm_link: - "center": [-0.056, -0.0, 0.04] "radius": 0.067 - "center": [-0.182, -0.0, 0.038] "radius": 0.065 - "center": [-0.317, -0.0, 0.024] "radius": 0.062 - "center": [-0.429, 0.0, 0.029] "radius": 0.059 - "center": [-0.566, 0.0, 0.056] "radius": 0.057 - "center": [-0.256, 0.0, 0.024] "radius": 0.064 - "center": [-0.565, -0.001, 0.029] "radius": 0.057 - "center": [-0.106, 0.0, 0.044] "radius": 0.067 - "center": [-0.378, -0.0, 0.025] "radius": 0.061 - "center": [-0.017, 0.007, 0.053] "radius": 0.057 - "center": [-0.52, -0.001, 0.029] "radius": 0.058 - "center": [-0.475, -0.0, 0.029] "radius": 0.059 - "center": [-0.0, 0.005, 0.119] "radius": 0.06 - wrist_1_link: - "center": [0.0, 0.005, -0.007] "radius": 0.056 - "center": [-0.001, -0.02, 0.0] "radius": 0.055 - wrist_2_link: - "center": [-0.0, 0.001, -0.0] "radius": 0.056 - "center": [-0.0, 0.021, 0.0] "radius": 0.055 - "center": [-0.004, -0.011, -0.011] "radius": 0.053 - wrist_3_link: - "center": [-0.016, 0.002, -0.025] "radius": 0.034 - "center": [0.016, -0.011, -0.024] "radius": 0.034 - "center": [0.009, 0.018, -0.025] "radius": 0.034
3,020
YAML
28.330097
79
0.539404
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/universal_robots/ur5e/rmpflow/ur5e_robot_description.yaml
# The robot description defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - shoulder_pan_joint - shoulder_lift_joint - elbow_joint - wrist_1_joint - wrist_2_joint - wrist_3_joint default_q: [ 0.0,-1.0,0.9,0.0,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - wrist_1_link: - "center": [-0.0, 0.027, -0.002] "radius": 0.041 - "center": [-0.003, -0.032, 0.001] "radius": 0.037 - "center": [-0.002, -0.003, -0.0] "radius": 0.039 - "center": [-0.0, 0.0, -0.058] "radius": 0.045 - wrist_2_link: - "center": [-0.0, 0.0, -0.015] "radius": 0.041 - "center": [0.0, 0.018, 0.001] "radius": 0.039 - "center": [0.0, -0.033, -0.001] "radius": 0.04 - wrist_3_link: - "center": [-0.001, 0.002, -0.025] "radius": 0.038 - shoulder_link: - "center": [-0.006, -0.012, 0.027] "radius": 0.059 - "center": [0.011, 0.007, -0.048] "radius": 0.055 - "center": [0.018, -0.031, -0.001] "radius": 0.05 - upper_arm_link: - "center": [-0.183, 0.0, 0.15] "radius": 0.069 - "center": [-0.344, 0.0, 0.126] "radius": 0.069 - "center": [-0.03, 0.0, 0.146] "radius": 0.069 - "center": [-0.425, 0.0, 0.142] "radius": 0.069 - "center": [-0.27, -0.001, 0.151] "radius": 0.069 - "center": [-0.11, 0.0, 0.137] "radius": 0.069 - "center": [0.001, -0.0, 0.135] "radius": 0.068 - "center": [-0.226, -0.001, 0.123] "radius": 0.068 - "center": [-0.426, -0.001, 0.118] "radius": 0.067 - "center": [-0.359, 0.005, 0.155] "radius": 0.064 - "center": [-0.307, 0.0, 0.121] "radius": 0.069 - "center": [-0.156, -0.0, 0.129] "radius": 0.069 - "center": [-0.123, -0.001, 0.151] "radius": 0.068 - "center": [-0.064, 0.005, 0.125] "radius": 0.064 - forearm_link: - "center": [-0.005, 0.001, 0.048] "radius": 0.059 - "center": [-0.317, 0.0, -0.001] "radius": 0.053 - "center": [-0.386, -0.0, 0.021] "radius": 0.049 - "center": [-0.01, 0.001, 0.018] "radius": 0.052 - "center": [-0.268, 0.0, -0.001] "radius": 0.054 - "center": [-0.034, -0.0, 0.014] "radius": 0.058 - "center": [-0.393, 0.001, -0.019] "radius": 0.047 - "center": [-0.326, -0.009, 0.028] "radius": 0.042 - "center": [-0.342, 0.0, -0.008] "radius": 0.051 - "center": [0.031, -0.009, 0.037] "radius": 0.033 - "center": [-0.222, 0.0, 0.002] "radius": 0.055 - "center": [-0.176, 0.0, 0.005] "radius": 0.055 - "center": [-0.129, 0.0, 0.008] "radius": 0.056 - "center": [-0.082, 0.0, 0.011] "radius": 0.057
3,384
YAML
28.434782
80
0.529846
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Flexiv/rizon4/rmpflow/flexiv_rizon4_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - joint1 - joint2 - joint3 - joint4 - joint5 - joint6 - joint7 default_q: [ 0.0,-0.5,0.0002,0.5,-0.0,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - link1: - "center": [-0.002, -0.002, 0.071] "radius": 0.069 - "center": [-0.004, -0.011, 0.173] "radius": 0.062 - "center": [0.003, -0.015, 0.22] "radius": 0.058 - "center": [-0.002, -0.006, 0.113] "radius": 0.067 - link2: - "center": [0.001, 0.036, 0.126] "radius": 0.061 - "center": [0.005, 0.041, 0.031] "radius": 0.058 - "center": [-0.007, 0.042, -0.008] "radius": 0.056 - "center": [-0.004, 0.035, 0.151] "radius": 0.059 - link3: - "center": [-0.005, 0.002, 0.06] "radius": 0.059 - "center": [-0.012, 0.008, 0.144] "radius": 0.055 - "center": [-0.018, 0.012, 0.197] "radius": 0.052 - "center": [-0.01, 0.005, 0.105] "radius": 0.057 - link4: - "center": [-0.018, 0.026, 0.139] "radius": 0.06 - "center": [-0.003, 0.034, 0.039] "radius": 0.056 - "center": [-0.006, 0.038, 0.001] "radius": 0.054 - "center": [-0.013, 0.029, 0.096] "radius": 0.058 - link5: - "center": [0.001, -0.003, 0.069] "radius": 0.058 - "center": [0.003, -0.01, 0.169] "radius": 0.054 - "center": [-0.003, -0.006, 0.112] "radius": 0.057 - "center": [-0.0, -0.012, 0.195] "radius": 0.052 - "center": [0.0, 0.0, 0.0] "radius": 0.06 - link6: - "center": [0.014, 0.069, 0.107] "radius": 0.06 - "center": [0.002, 0.049, 0.035] "radius": 0.059 - "center": [-0.001, 0.043, -0.005] "radius": 0.053 - "center": [-0.001, 0.067, 0.106] "radius": 0.059 - link7: - "center": [-0.005, -0.006, 0.041] "radius": 0.05 - "center": [0.009, 0.002, 0.041] "radius": 0.05 - "center": [0.0, 0.0, 0.0] "radius": 0.05
2,661
YAML
27.021052
79
0.547914
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Denso/cobotta_pro_1300/rmpflow/robot_descriptor.yaml
# Copyright (c) 2019-2022, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # RMPflow will only use these joints to control the robot position. cspace: - joint_1 - joint_2 - joint_3 - joint_4 - joint_5 - joint_6 # Global frame of the URDF root_link: world # The default cspace position of this robot default_q: [ 0.0,0.3,1.2,0.0,0.0,0.0 ] # RMPflow uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, RMPflow will # not be able to avoid obstacles. collision_spheres: - J1: - "center": [0.0, 0.0, 0.1] "radius": 0.09 - "center": [0.0, 0.0, 0.15] "radius": 0.09 - "center": [0.0, 0.0, 0.2] "radius": 0.09 - J2: - "center": [0.0, 0.08, 0.0] "radius": 0.09 - "center": [0.0, 0.16, 0.0] "radius": 0.09 - "center": [0.0, 0.2, 0.0] "radius": 0.09 - "center": [0.0, 0.197, 0.05] "radius": 0.08 - "center": [0.0, 0.195, 0.1] "radius": 0.08 - "center": [0.0, 0.192, 0.15] "radius": 0.08 - "center": [0.0, 0.19, 0.2] "radius": 0.065 - "center": [0.0, 0.187, 0.25] "radius": 0.065 - "center": [0.0, 0.185, 0.3] "radius": 0.065 - "center": [0.0, 0.182, 0.35] "radius": 0.065 - "center": [0.0, 0.18, 0.4] "radius": 0.065 - "center": [0.0, 0.177, 0.45] "radius": 0.065 - "center": [0.0, 0.175, 0.5] "radius": 0.065 - "center": [0.0, 0.174, 0.55] "radius": 0.065 - "center": [0.0, 0.173, 0.6] "radius": 0.065 - "center": [0.0, 0.172, 0.65] "radius": 0.075 - "center": [0.0, 0.16, 0.7] "radius": 0.075 - J3: - "center": [0.0, 0.025, 0] "radius": 0.075 - "center": [0.0, -0.045, 0] "radius": 0.065 - "center": [0.0, -0.045, 0.05] "radius": 0.065 - "center": [0.0, -0.045, 0.1] "radius": 0.065 - "center": [0.0, -0.045, 0.15] "radius": 0.06 - "center": [0.0, -0.045, 0.2] "radius": 0.06 - "center": [0.0, -0.045, 0.25] "radius": 0.06 - "center": [0.0, -0.045, 0.3] "radius": 0.06 - "center": [0.0, -0.045, 0.35] "radius": 0.055 - "center": [0.0, -0.05, 0.4] "radius": 0.055 - "center": [0.0, -0.05, 0.45] "radius": 0.055 - "center": [0.0, -0.05, 0.5] "radius": 0.055 - "center": [0.0, -0.05, 0.55] "radius": 0.055 - "center": [0.0, -0.05, 0.59] "radius": 0.055 - J5: - "center": [0.0, 0.05, 0] "radius": 0.055 - "center": [0.0, 0.1, 0] "radius": 0.055 - J6: - "center": [0.0, 0.0, -0.05] "radius": 0.05 - "center": [0.0, 0.0, -0.1] "radius": 0.05 - "center": [0.0, 0.0, -0.15] "radius": 0.05 - "center": [0.0, 0.0, 0.04] "radius": 0.035 - "center": [0.0, 0.0, 0.08] "radius": 0.035 - "center": [0.0, 0.0, 0.12] "radius": 0.035 - right_inner_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.02 - "center": [0.0, -0.03, 0.025] "radius": 0.02 - "center": [0.0, -0.05, 0.05] "radius": 0.02 - right_inner_finger: - "center": [0.0, 0.02, 0.0] "radius": 0.015 - "center": [0.0, 0.02, 0.015] "radius": 0.015 - "center": [0.0, 0.02, 0.03] "radius": 0.015 - "center": [0.0, 0.025, 0.04] "radius": 0.01 - left_inner_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.02 - "center": [0.0, -0.03, 0.025] "radius": 0.02 - "center": [0.0, -0.05, 0.05] "radius": 0.02 - left_inner_finger: - "center": [0.0, 0.02, 0.0] "radius": 0.015 - "center": [0.0, 0.02, 0.015] "radius": 0.015 - "center": [0.0, 0.02, 0.03] "radius": 0.015 - "center": [0.0, 0.025, 0.04] "radius": 0.01
4,439
YAML
26.407407
80
0.511602
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/dofbot/rmpflow/robot_descriptor.yaml
# Copyright (c) 2019-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF, except when otherwise specified below under # cspace_urdf_bridge cspace: - joint1 - joint2 - joint3 - joint4 root_link: base_link default_q: [ 0.00, 0.00, 0.00, 0.00 ]
861
YAML
30.925925
79
0.765389
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/dofbot/rmpflow/dofbot_rmpflow_common.yaml
# Copyright (c) 2019-2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. joint_limit_buffers: [.01, .01, .01, .01] # Note: metric_weight and metric_scalar mean the same thing. Set to zero to turn it off. rmp_params: cspace_target_rmp: metric_scalar: 50. position_gain: 100. damping_gain: 50. robust_position_term_thresh: .5 inertia: 0. cspace_trajectory_rmp: # Note: unused p_gain: 100. d_gain: 10. ff_gain: .25 weight: 50. cspace_affine_rmp: # Note: unused final_handover_time_std_dev: .25 weight: 2000. joint_limit_rmp: metric_scalar: 1000. metric_length_scale: .01 metric_exploder_eps: 1e-3 metric_velocity_gate_length_scale: .01 accel_damper_gain: 200. accel_potential_gain: 1. accel_potential_exploder_length_scale: .1 accel_potential_exploder_eps: 1e-2 joint_velocity_cap_rmp: # Note: Less important max_velocity: 4. # max_xd velocity_damping_region: 1.5 damping_gain: 1000.0 metric_weight: 0. target_rmp: accel_p_gain: 100. accel_d_gain: 400. accel_norm_eps: .025 # TODO: meters metric_alpha_length_scale: .001 min_metric_alpha: .01 max_metric_scalar: 10000 min_metric_scalar: 2500 proximity_metric_boost_scalar: 20. # TODO: meters proximity_metric_boost_length_scale: .0025 xi_estimator_gate_std_dev: 20000. # unused accept_user_weights: false # Values >= .5 are true and < .5 are false axis_target_rmp: # Note: Won't be used for end effector position control accel_p_gain: 210. accel_d_gain: 60. metric_scalar: 10 proximity_metric_boost_scalar: 3000. # TODO: meters proximity_metric_boost_length_scale: .01 xi_estimator_gate_std_dev: 20000. accept_user_weights: false collision_rmp: # Note import if no obstacles damping_gain: 50. # TODO: meters damping_std_dev: .005 damping_robustness_eps: 1e-2 # TODO: meters damping_velocity_gate_length_scale: .001 repulsion_gain: 800. # TODO: meters repulsion_std_dev: .001 # TODO: meters metric_modulation_radius: .05 metric_scalar: 10000. # Real value should be this. #metric_scalar: 0. # Turns off collision avoidance. # TODO: meters metric_exploder_std_dev: .0025 metric_exploder_eps: .001 damping_rmp: accel_d_gain: 30. metric_scalar: 50. inertia: 0. canonical_resolve: max_acceleration_norm: 50. # TODO: try setting much larger projection_tolerance: .01 verbose: false body_cylinders: - name: base_stem pt1: [0,0,.333] pt2: [0,0,0.] radius: .05 body_collision_controllers: - name: link5 radius: .08
3,309
YAML
30.826923
88
0.618918
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Kawasaki/README.md
The Kawasaki RS robot URDF files have all been modified such that the +X axis lies in front of the robot to fit with Isaac Sim convention. This corresponds to the same change in each URDF: <joint name="world2base" type="fixed"> <parent link="world"/> <child link="base_link"/> <origin rpy="0 0 -1.5707963267948966" xyz="0 0 0"/> </joint> from the original <joint name="world2base" type="fixed"> <parent link="world"/> <child link="base_link"/> <origin rpy="0 0 0" xyz="0 0 0"/> </joint>. The URDFs have also been modified to include a new frame in the center of the robot gripper called "gripper_center". The following has been added at the bottom of each URDF: <link name="gripper_center"/> <joint name="gripper_center_joint" type="fixed"> <origin rpy="0 0 0" xyz="0.0 0.0 .2"/> <parent link="onrobot_rg2_base_link"/> <child link="gripper_center"/> </joint> These modified URDF files were used to generate the Kawasaki RS USD files that are stored on the Nucleus Isaac Sim server.
1,031
Markdown
37.222221
189
0.695441
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Kawasaki/rs007l/rmpflow/rs007l_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - joint1 - joint2 - joint3 - joint4 - joint5 - joint6 default_q: [ 0.0,-0.2,-1.7,-1.507,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: - {name: finger_joint, rule: fixed, value: -0.0} - {name: left_inner_knuckle_joint, rule: fixed, value: 0.0} - {name: right_inner_knuckle_joint, rule: fixed, value: -0.0} - {name: right_outer_knuckle_joint, rule: fixed, value: 0.0} - {name: left_inner_finger_joint, rule: fixed, value: -0.0} - {name: right_inner_finger_joint, rule: fixed, value: 0.0} # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - link1: - "center": [-0.031, 0.0, -0.07] "radius": 0.083 - "center": [-0.013, -0.001, -0.007] "radius": 0.077 - "center": [-0.079, -0.0, -0.051] "radius": 0.078 - link2: - "center": [0.031, -0.009, -0.106] "radius": 0.061 - "center": [0.103, 0.001, -0.117] "radius": 0.059 - "center": [0.267, -0.001, -0.119] "radius": 0.054 - "center": [0.191, 0.0, -0.121] "radius": 0.054 - "center": [0.351, 0.003, -0.116] "radius": 0.051 - "center": [-0.019, 0.004, -0.101] "radius": 0.056 - "center": [0.47, 0.013, -0.105] "radius": 0.044 - "center": [0.4, 0.011, -0.113] "radius": 0.048 - link3: - "center": [0.004, -0.0, 0.011] "radius": 0.105 - link4: - "center": [0.0, 0.0, 0.0] "radius": 0.05 - "center": [0.001, -0.001, 0.125] "radius": 0.05 - "center": [0.0, -0.0, 0.042] "radius": 0.05 - "center": [0.001, -0.001, 0.084] "radius": 0.05 - "center": [0.0, -0.0, 0.372] "radius": 0.065 - "center": [0.0, -0.0, 0.162] "radius": 0.065 - "center": [0.0, -0.0, 0.318] "radius": 0.064 - "center": [0.0, -0.0, 0.265] "radius": 0.065 - "center": [0.0, -0.0, 0.213] "radius": 0.065 - link5: - "center": [0.04, 0.0, 0.0] "radius": 0.041 - onrobot_rg2_base_link: - "center": [0.0, 0.001, 0.04] "radius": 0.044 - "center": [0.0, -0.002, 0.084] "radius": 0.037 - "center": [0.0, 0.01, 0.12] "radius": 0.031 - "center": [-0.0, -0.011, 0.115] "radius": 0.031 - left_outer_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.015 - "center": [-0.0, -0.04, 0.034] "radius": 0.015 - "center": [-0.0, -0.013, 0.011] "radius": 0.015 - "center": [-0.0, -0.027, 0.023] "radius": 0.015 - left_inner_knuckle: - "center": [0.0, -0.014, 0.014] "radius": 0.015 - "center": [-0.001, -0.002, 0.002] "radius": 0.015 - "center": [0.001, -0.031, 0.031] "radius": 0.015 - right_inner_knuckle: - "center": [0.0, -0.014, 0.014] "radius": 0.015 - "center": [-0.001, -0.002, 0.002] "radius": 0.015 - "center": [0.001, -0.031, 0.031] "radius": 0.015 - right_inner_finger: - "center": [0.002, 0.01, 0.028] "radius": 0.013 - "center": [0.003, 0.006, 0.014] "radius": 0.012 - "center": [-0.003, 0.012, 0.037] "radius": 0.012 - left_inner_finger: - "center": [0.002, 0.01, 0.028] "radius": 0.013 - "center": [0.003, 0.006, 0.014] "radius": 0.012 - "center": [-0.003, 0.012, 0.037] "radius": 0.012 - right_outer_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.015 - "center": [-0.0, -0.04, 0.034] "radius": 0.015 - "center": [-0.0, -0.013, 0.011] "radius": 0.015 - "center": [-0.0, -0.027, 0.023] "radius": 0.015
4,204
YAML
28.822695
79
0.529258
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/motion_policy_configs/Kawasaki/rs007n/rmpflow/rs007n_robot_description.yaml
# The robot descriptor defines the generalized coordinates and how to map those # to the underlying URDF dofs. api_version: 1.0 # Defines the generalized coordinates. Each generalized coordinate is assumed # to have an entry in the URDF. # Lula will only use these joints to control the robot position. cspace: - joint1 - joint2 - joint3 - joint4 - joint5 - joint6 default_q: [ 0.0,-0.2,-1.7,-1.507,0.0,0.0 ] # Most dimensions of the cspace have a direct corresponding element # in the URDF. This list of rules defines how unspecified coordinates # should be extracted or how values in the URDF should be overwritten. cspace_to_urdf_rules: - {name: finger_joint, rule: fixed, value: -0.0} - {name: left_inner_knuckle_joint, rule: fixed, value: 0.0} - {name: right_inner_knuckle_joint, rule: fixed, value: -0.0} - {name: right_outer_knuckle_joint, rule: fixed, value: 0.0} - {name: left_inner_finger_joint, rule: fixed, value: -0.0} - {name: right_inner_finger_joint, rule: fixed, value: 0.0} # Lula uses collision spheres to define the robot geometry in order to avoid # collisions with external obstacles. If no spheres are specified, Lula will # not be able to avoid obstacles. collision_spheres: - link1: - "center": [-0.031, 0.0, -0.07] "radius": 0.083 - "center": [-0.013, -0.001, -0.007] "radius": 0.077 - "center": [-0.079, -0.0, -0.051] "radius": 0.078 - link3: - "center": [0.004, -0.0, 0.011] "radius": 0.105 - link4: - "center": [0.0, 0.0, 0.0] "radius": 0.05 - "center": [0.001, -0.001, 0.125] "radius": 0.05 - "center": [-0.001, -0.001, 0.11] "radius": 0.067 - "center": [0.0, -0.0, 0.042] "radius": 0.055 - "center": [0.0, -0.0, 0.268] "radius": 0.067 - "center": [0.0, -0.0, 0.228] "radius": 0.067 - "center": [-0.0, -0.0, 0.189] "radius": 0.067 - "center": [-0.001, -0.001, 0.15] "radius": 0.067 - link5: - "center": [0.04, 0.0, 0.0] "radius": 0.041 - onrobot_rg2_base_link: - "center": [0.0, 0.001, 0.04] "radius": 0.044 - "center": [0.0, -0.002, 0.084] "radius": 0.037 - "center": [0.0, 0.01, 0.12] "radius": 0.031 - "center": [-0.0, -0.011, 0.115] "radius": 0.031 - left_outer_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.015 - "center": [-0.0, -0.04, 0.034] "radius": 0.015 - "center": [-0.0, -0.013, 0.011] "radius": 0.015 - "center": [-0.0, -0.027, 0.023] "radius": 0.015 - left_inner_knuckle: - "center": [0.0, -0.014, 0.014] "radius": 0.015 - "center": [-0.001, -0.002, 0.002] "radius": 0.015 - "center": [0.001, -0.031, 0.031] "radius": 0.015 - right_inner_knuckle: - "center": [0.0, -0.014, 0.014] "radius": 0.015 - "center": [-0.001, -0.002, 0.002] "radius": 0.015 - "center": [0.001, -0.031, 0.031] "radius": 0.015 - right_inner_finger: - "center": [0.002, 0.01, 0.028] "radius": 0.013 - "center": [0.003, 0.006, 0.014] "radius": 0.012 - "center": [-0.003, 0.012, 0.037] "radius": 0.012 - left_inner_finger: - "center": [0.002, 0.01, 0.028] "radius": 0.013 - "center": [0.003, 0.006, 0.014] "radius": 0.012 - "center": [-0.003, 0.012, 0.037] "radius": 0.012 - right_outer_knuckle: - "center": [0.0, 0.0, 0.0] "radius": 0.015 - "center": [-0.0, -0.04, 0.034] "radius": 0.015 - "center": [-0.0, -0.013, 0.011] "radius": 0.015 - "center": [-0.0, -0.027, 0.023] "radius": 0.015 - link2: - "center": [0.044, 0.001, -0.11] "radius": 0.065 - "center": [0.243, 0.0, -0.119] "radius": 0.055 - "center": [-0.008, 0.002, -0.108] "radius": 0.063 - "center": [0.333, 0.006, -0.114] "radius": 0.049 - "center": [0.373, -0.015, -0.111] "radius": 0.045 - "center": [0.284, 0.001, -0.118] "radius": 0.052 - "center": [0.075, 0.0, -0.116] "radius": 0.061 - "center": [0.133, 0.0, -0.117] "radius": 0.059 - "center": [0.189, 0.0, -0.118] "radius": 0.057
4,210
YAML
28.865248
79
0.529454
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/path_planner_configs/franka/rrt/franka_planner_config.yaml
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. seed: 123456 step_size: 0.1 max_iterations: 4000 max_sampling: 10000 distance_metric_weights: [3.0, 2.0, 2.0, 1.5, 1.5, 1.0, 1.0] task_space_frame_name: "panda_rightfingertip" task_space_limits: [[-0.8, 0.9], [-0.8, 0.8], [0.0, 1.2]] c_space_planning_params: exploration_fraction: 0.5 task_space_planning_params: x_target_zone_tolerance: [0.01, 0.01, 0.01] x_target_final_tolerance: 1e-5 task_space_exploitation_fraction: 0.4 task_space_exploration_fraction: 0.1
900
YAML
38.173911
76
0.751111
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/config/extension.toml
[core] reloadable = true order = 0 [package] version = "4.5.6" category = "Simulation" title = "Isaac Sim Motion Generation" description = "Extension that provides support for generating motion with Lula-based motion policies and an interface for writing arbitrary motion policies" repository = "" authors = ["NVIDIA"] keywords = ["isaac", "motion generation", "lula", "motion policy"] changelog = "docs/CHANGELOG.md" readme = "docs/README.md" icon = "data/icon.png" [dependencies] "omni.isaac.dynamic_control" = {} "omni.isaac.motion_planning" = {} # Fixes issue where ROS was sourced first "omni.isaac.lula" = {} "omni.isaac.core" = {} [[python.module]] name = "omni.isaac.motion_generation" [[python.module]] name = "omni.isaac.motion_generation.tests"
760
TOML
26.17857
156
0.722368
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/kinematics_interface.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np from typing import Tuple, Optional, List from .world_interface import WorldInterface class KinematicsSolver(WorldInterface): """An limitted interface for computing robot kinematics that includes forward and inverse kinematics. This interface ommits more advanced kinematics such as Jacobians, as they are not required for most use-cases. This interface inherits from the WorldInterface to standardize the inputs to collision-aware IK solvers, but it is not necessary for all implementations to implement the WorldInterface. See KinematicsSolver.supports_collision_avoidance() """ def __init__(self): pass def set_robot_base_pose(self, robot_positions: np.array, robot_orientation: np.array) -> None: """Update position of the robot base. This will be used to compute kinematics relative to the USD stage origin. Args: robot_positions (np.array): (3 x 1) translation vector describing the translation of the robot base relative to the USD stage origin. The translation vector should be specified in the units of the USD stage robot_orientation (np.array): (4 x 1) quaternion describing the orientation of the robot base relative to the USD stage global frame """ pass def get_joint_names(self) -> List[str]: """Return a list containing the names of all joints in the given kinematic structure. The order of this list determines the order in which the joint positions are expected in compute_forward_kinematics(joint_positions,...) and the order in which they are returned in compute_inverse_kinematics() Returns: List[str]: Names of all joints in the robot """ return [] def get_all_frame_names(self) -> List[str]: """Return a list of all the frame names in the given kinematic structure Returns: List[str]: All frame names in the kinematic structure. Any of which can be used to compute forward or inverse kinematics. """ return [] def compute_forward_kinematics( self, frame_name: str, joint_positions: np.array, position_only: Optional[bool] = False ) -> Tuple[np.array, np.array]: """ Compute the position of a given frame in the robot relative to the USD stage global frame Args: frame_name (str): Name of robot frame on which to calculate forward kinematics joint_positions (np.array): Joint positions for the joints returned by get_joint_names() position_only (bool): If True, only the frame positions need to be calculated and the returned rotation may be left undefined. Returns: Tuple[np.array,np.array]: frame_positions: (3x1) vector describing the translation of the frame relative to the USD stage origin frame_rotation: (3x3) rotation matrix describing the rotation of the frame relative to the USD stage global frame """ return np.zeros(3), np.eye(3) def compute_inverse_kinematics( self, frame_name: str, target_positions: np.array, target_orientation: Optional[np.array] = None, warm_start: Optional[np.array] = None, position_tolerance: Optional[float] = None, orientation_tolerance: Optional[float] = None, ) -> Tuple[np.array, bool]: """Compute joint positions such that the specified robot frame will reach the desired translations and rotations Args: frame_name (str): name of the target frame for inverse kinematics target_position (np.array): target translation of the target frame (in stage units) relative to the USD stage origin target_orientation (np.array): target orientation of the target frame relative to the USD stage global frame. Defaults to None. warm_start (np.array): a starting position that will be used when solving the IK problem. Defaults to None. position_tolerance (float): l-2 norm of acceptable position error (in stage units) between the target and achieved translations. Defaults to None. orientation tolerance (float): magnitude of rotation (in radians) separating the target orientation from the achieved orienatation. orientation_tolerance is well defined for values between 0 and pi. Defaults to None. Returns: Tuple[np.array,bool]: joint_positions: in the order specified by get_joint_names() which result in the target frame acheiving the desired position success: True if the solver converged to a solution within the given tolerances """ return np.empty() def supports_collision_avoidance(self) -> bool: """Returns a bool describing whether the inverse kinematics support collision avoidance. If the policy does not support collision avoidance, none of the obstacle add/remove/enable/disable functions need to be implemented. Returns: bool: If True, the IK solver will avoid any obstacles that have been added """ return False
5,604
Python
50.422018
158
0.695575
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/trajectory.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np from typing import Tuple, List class Trajectory: """Interface class for defining a continuous-time trajectory for a robot in Isaac Sim. A Trajectory may be passed to an ArticulationTrajectory to have its continuous-time output discretized and converted to a ArticulationActions. """ def __init__(self): pass @property def start_time(self) -> float: """Return the start time of the trajectory. Returns: float: Start time of the trajectory. """ pass @property def end_time(self) -> float: """Return the end time of the trajectory Returns: float: End time of the trajectory """ pass def get_active_joints(self) -> List[str]: """Active joints are directly controlled by this Trajectory A Trajectory may be specified for only a subset of the joints in a robot Articulation. For example, it may include the DOFs in a robot arm, but not in the gripper. Returns: List[str]: Names of active joints. The order of joints in this list determines the order in which a Trajectory will return joint targets for the robot. """ return [] def get_joint_targets(self, time: float) -> Tuple[np.array, np.array]: """Return joint targets for the robot at the given time. The Trajectory interface assumes trajectories to be represented continuously between a start time and end time. In instance of this class that internally generates discrete time trajectories will need to implement some form of interpolation for times that have not been computed. Args: time (float): Time in trajectory at which to return joint targets. Returns: Tuple[np.array,np.array]: joint position targets for the active robot joints\n joint velocity targets for the active robot joints """ pass
2,435
Python
36.476923
143
0.676386
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/interface_config_loader.py
import os import json import carb from omni.isaac.core.utils.extensions import get_extension_path_from_name from typing import List """This InterfaceLoader makes it trivial to load a valid config for supported interface implementations For example, RMPflow has a collection of robot-specific config files stored in the motion_generation extension. This loader makes it simple to load RMPflow for the Franka robot using load_supported_motion_policy_config("Franka","RMPflow") """ def get_supported_robot_policy_pairs() -> dict: """Get a dictionary of MotionPolicy names that are supported for each given robot name Returns: supported_policy_names_by_robot (dict): dictionary mapping robot names (keys) to a list of supported MotionPolicy config files (values) """ mg_extension_path = get_extension_path_from_name("omni.isaac.motion_generation") policy_config_dir = os.path.join(mg_extension_path, "motion_policy_configs") with open(os.path.join(policy_config_dir, "policy_map.json")) as policy_map: policy_map = json.load(policy_map) supported_policy_names_by_robot = dict() for k, v in policy_map.items(): supported_policy_names_by_robot[k] = list(v.keys()) return supported_policy_names_by_robot def get_supported_robots_with_lula_kinematics() -> List[str]: # Currently just uses robots that have RmpFlow supported robots = [] pairs = get_supported_robot_policy_pairs() for k, v in pairs.items(): if "RMPflow" in v: robots.append(k) return robots def get_supported_robot_path_planner_pairs() -> dict: """Get a dictionary of PathPlanner names that are supported for each given robot name Returns: supported_planner_names_by_robot (dict): dictionary mapping robot names (keys) to a list of supported PathPlanner config files (values) """ mg_extension_path = get_extension_path_from_name("omni.isaac.motion_generation") policy_config_dir = os.path.join(mg_extension_path, "path_planner_configs") with open(os.path.join(policy_config_dir, "path_planner_map.json")) as planner_map: planner_map = json.load(planner_map) supported_planner_names_by_robot = dict() for k, v in planner_map.items(): supported_planner_names_by_robot[k] = list(v.keys()) return supported_planner_names_by_robot def load_supported_lula_kinematics_solver_config(robot_name: str, policy_config_dir=None) -> dict: """Load lula kinematics solver for a supported robot. Use get_supported_robots_with_lula_kinematics() to get a list of robots with supported kinematics. Args: robot_name (str): name of robot Returns: solver_config (dict): a dictionary whose keyword arguments are sufficient to load the lula kinematics solver. e.g. lula.LulaKinematicsSolver(**load_supported_lula_kinematics_solver_config("Franka")) """ policy_name = "RMPflow" if policy_config_dir is None: mg_extension_path = get_extension_path_from_name("omni.isaac.motion_generation") policy_config_dir = os.path.join(mg_extension_path, "motion_policy_configs") with open(os.path.join(policy_config_dir, "policy_map.json")) as policy_map: policy_map = json.load(policy_map) if robot_name not in policy_map: carb.log_error( "Unsupported robot passed to InterfaceLoader. Use get_supported_robots_with_lula_kinematics() to get a list of robots with supported kinematics" ) return None if policy_name not in policy_map[robot_name]: carb.log_error( robot_name + " does not have supported lula kinematics. Use get_supported_robots_with_lula_kinematics() to get a list of robots with supported kinematics" ) return None config_path = os.path.join(policy_config_dir, policy_map[robot_name][policy_name]) rmp_config = _process_policy_config(config_path) kinematics_config = dict() kinematics_config["robot_description_path"] = rmp_config["robot_description_path"] kinematics_config["urdf_path"] = rmp_config["urdf_path"] return kinematics_config def load_supported_motion_policy_config(robot_name: str, policy_name: str, policy_config_dir: str = None) -> dict: """Load a MotionPolicy object by specifying the robot name and policy name For a dictionary mapping supported robots to supported policies on those robots, use get_supported_robot_policy_pairs() To use this loader for a new policy, a user may copy the config file structure found under /motion_policy_configs/ in the motion_generation extension, passing in a path to a directory containing a "policy_map.json" Args: robot_name (str): name of robot policy_name (str): name of MotionPolicy policy_config_dir (str): path to directory where a policy_map.json file is stored, defaults to ".../omni.isaac.motion_generation/motion_policy_configs" Returns: policy_config (dict): a dictionary whose keyword arguments are sufficient to load the desired motion policy e.g. lula.motion_policies.RmpFlow(**load_supported_motion_policy_config("Franka","RMPflow")) """ if policy_config_dir is None: mg_extension_path = get_extension_path_from_name("omni.isaac.motion_generation") policy_config_dir = os.path.join(mg_extension_path, "motion_policy_configs") with open(os.path.join(policy_config_dir, "policy_map.json")) as policy_map: policy_map = json.load(policy_map) if robot_name not in policy_map: carb.log_error( "Unsupported robot passed to InterfaceLoader. Use get_supported_robot_policy_pairs() to see supported robots and their corresponding supported policies" ) return None if policy_name not in policy_map[robot_name]: carb.log_error( 'Unsupported policy name passed to InterfaceLoader for robot "' + robot_name + '". Use get_supported_robot_policy_pairs() to see supported robots and their corresponding supported policies' ) return None config_path = os.path.join(policy_config_dir, policy_map[robot_name][policy_name]) config = _process_policy_config(config_path) return config def load_supported_path_planner_config(robot_name: str, planner_name: str, policy_config_dir: str = None) -> dict: if policy_config_dir is None: mg_extension_path = get_extension_path_from_name("omni.isaac.motion_generation") policy_config_dir = os.path.join(mg_extension_path, "path_planner_configs") with open(os.path.join(policy_config_dir, "path_planner_map.json")) as policy_map: policy_map = json.load(policy_map) if robot_name not in policy_map: carb.log_error( "Unsupported robot passed to InterfaceLoader. Use get_supported_robot_policy_pairs() to see supported robots and their corresponding supported policies" ) return None if planner_name not in policy_map[robot_name]: carb.log_error( 'Unsupported policy name passed to InterfaceLoader for robot "' + robot_name + '". Use get_supported_robot_policy_pairs() to see supported robots and their corresponding supported policies' ) return None config_path = os.path.join(policy_config_dir, policy_map[robot_name][planner_name]) config = _process_policy_config(config_path) return config def _process_policy_config(mg_config_file): mp_config_dir = os.path.dirname(mg_config_file) with open(mg_config_file) as config_file: config = json.load(config_file) rel_assets = config.get("relative_asset_paths", {}) for k, v in rel_assets.items(): config[k] = os.path.join(mp_config_dir, v) del config["relative_asset_paths"] return config
7,891
Python
42.60221
165
0.692941
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/__init__.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.motion_generation.articulation_motion_policy import ArticulationMotionPolicy from omni.isaac.motion_generation.world_interface import WorldInterface from omni.isaac.motion_generation.motion_policy_interface import MotionPolicy from omni.isaac.motion_generation.lula.motion_policies import RmpFlow, RmpFlowSmoothed from omni.isaac.motion_generation.lula.kinematics import LulaKinematicsSolver from omni.isaac.motion_generation.articulation_kinematics_solver import ArticulationKinematicsSolver from omni.isaac.motion_generation.kinematics_interface import KinematicsSolver from omni.isaac.motion_generation.trajectory import Trajectory from omni.isaac.motion_generation.articulation_trajectory import ArticulationTrajectory from omni.isaac.motion_generation.lula.trajectory_generator import ( LulaCSpaceTrajectoryGenerator, LulaTaskSpaceTrajectoryGenerator, ) from omni.isaac.motion_generation.path_planning_interface import PathPlanner from omni.isaac.motion_generation.path_planner_visualizer import PathPlannerVisualizer from omni.isaac.motion_generation.motion_policy_controller import MotionPolicyController from omni.isaac.motion_generation.wheel_base_pose_controller import WheelBasePoseController
1,657
Python
60.407405
100
0.858177
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/path_planner_visualizer.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. from .path_planning_interface import PathPlanner from omni.isaac.core.articulations import Articulation, ArticulationSubset from omni.isaac.core.utils.types import ArticulationAction import numpy as np import carb from typing import List class PathPlannerVisualizer: """A helper class for quickly visualizing the plans output by a PathPlanner. The main utility of this class lies in the compute_plan_as_articulation_actions() function, which returns a sequence of ArticulationActions that may be directly sent to the robot Articulation in order to visualize the planned path. Args: robot_articulation (Articulation): An Articulation object describing a single simulated robot. path_planner (PathPlanner): A PathPlanner object that has been configured to compute plans for the robot represented by the robot Articulation. """ def __init__(self, robot_articulation: Articulation, path_planner: PathPlanner) -> None: self._robot_articulation = robot_articulation self._planner = path_planner self._articulation_controller = self._robot_articulation.get_articulation_controller() self._active_joints_view = ArticulationSubset(robot_articulation, path_planner.get_active_joints()) self._watched_joints_view = ArticulationSubset(robot_articulation, path_planner.get_watched_joints()) def compute_plan_as_articulation_actions(self, max_cspace_dist: float = 0.05) -> List[ArticulationAction]: """Compute plan using a PathPlanner and linearly interpolate the result to enforce that the maximum distance (l2 norm) between any two points is max_cspace_dist. Args: max_cspace_dist (float, optional): Maximum distance between adjacent points in the path. Defaults to 0.05. Returns: List[ArticulationAction]: Linearly interpolated path given as a sequence of ArticulationActions that can be passed directly to the robot Articulation. This may rearrange and augment the plan output by the PathPlanner to match the number of DOFs available for control in the robot Articulation. """ active_joint_positions = self._active_joints_view.get_joint_positions() if active_joint_positions is None: carb.log_error( "Attempted to compute a path for an uninitialized robot Articulation. Cannot get joint positions" ) watched_joint_positions = self._watched_joints_view.get_joint_positions() path = self._planner.compute_path(active_joint_positions, watched_joint_positions) if path is None: return [] interpolated_path = self.interpolate_path(path, max_cspace_dist) actions_np_array = self._active_joints_view.map_to_articulation_order(interpolated_path) articulation_actions = [ ArticulationAction(joint_positions=actions_np_array[i]) for i in range(len(actions_np_array)) ] return articulation_actions def interpolate_path(self, path: np.array, max_cspace_dist: float = 0.05) -> np.array: """Linearly interpolate a sparse path such that the maximum distance (l2 norm) between any two points is max_cspace_dist Args: path (np.array): Sparse cspace path with shape (N x num_dofs) where N is number of points in the path max_cspace_dist (float, optional): _description_. Defaults to 0.05. Returns: np.array: Linearly interpolated path with shape (M x num_dofs) """ if path.shape[0] == 0: return path interpolated_path = [] for i in range(path.shape[0] - 1): n_pts = int(np.ceil(np.amax(abs(path[i + 1] - path[i])) / max_cspace_dist)) interpolated_path.append(np.array(np.linspace(path[i], path[i + 1], num=n_pts, endpoint=False))) interpolated_path.append(path[np.newaxis, -1, :]) interpolated_path = np.concatenate(interpolated_path) return interpolated_path def get_active_joints_subset(self) -> ArticulationSubset: """Get view into active joints Returns: ArticulationSubset: Returns robot states for active joints in an order compatible with the PathPlanner """ return self._active_joints_view def get_watched_joints_subset(self) -> ArticulationSubset: """Get view into watched joints Returns: ArticulationSubset: Returns robot states for watched joints in an order compatible with the PathPlanner """ return self._watched_joints_view def get_robot_articulation(self) -> Articulation: """Get the robot Articulation Returns: Articulation: Articulation object describing the robot. """ return self._robot_articulation def get_path_planner(self) -> PathPlanner: """Get the PathPlanner that is being used to generate paths Returns: PathPlanner: An instance of the PathPlanner interface for generating sparse paths to a target pose """ return self._planner
5,572
Python
42.881889
128
0.690596
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/motion_policy_interface.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np from typing import Tuple, List from omni.isaac.motion_generation.world_interface import WorldInterface class MotionPolicy(WorldInterface): """Interface for implementing a MotionPolicy: a collision-aware algorithm for dynamically moving a robot to a target. The MotionPolicy interface inherits from the WorldInterface class. A MotionPolicy can be passed to an ArticulationMotionPolicy to streamline moving the simulated robot. """ def __init__(self) -> None: pass def set_robot_base_pose(self, robot_translation: np.array, robot_orientation: np.array): """Update position of the robot base. Args: robot_translation (np.array): (3 x 1) translation vector describing the translation of the robot base relative to the USD stage origin. The translation vector should be specified in the units of the USD stage robot_orientation (np.array): (4 x 1) quaternion describing the orientation of the robot base relative to the USD stage global frame """ pass def compute_joint_targets( self, active_joint_positions: np.array, active_joint_velocities: np.array, watched_joint_positions: np.array, watched_joint_velocities: np.array, frame_duration: float, ) -> Tuple[np.array, np.array]: """Compute position and velocity targets for the next frame given the current robot state. Position and velocity targets are used in Isaac Sim to generate forces using the PD equation kp*(joint_position_targets-joint_positions) + kd*(joint_velocity_targets-joint_velocities). Args: active_joint_positions (np.array): current positions of joints specified by get_active_joints() active_joint_velocities (np.array): current velocities of joints specified by get_active_joints() watched_joint_positions (np.array): current positions of joints specified by get_watched_joints() watched_joint_velocities (np.array): current velocities of joints specified by get_watched_joints() frame_duration (float): duration of the physics frame Returns: Tuple[np.array,np.array]: joint position targets for the active robot joints for the next frame \n joint velocity targets for the active robot joints for the next frame """ return active_joint_positions, np.zeros_like(active_joint_velocities) def get_active_joints(self) -> List[str]: """Active joints are directly controlled by this MotionPolicy Some articulated robot joints may be ignored by some policies. E.g., the gripper of the Franka arm is not used to follow targets, and the RMPflow config files excludes the joints in the gripper from the list of articulated joints. Returns: List[str]: names of active joints. The order of joints in this list determines the order in which a MotionPolicy expects joint states to be specified in functions like compute_joint_targets(active_joint_positions,...) """ return [] def get_watched_joints(self) -> List[str]: """Watched joints are joints whose position/velocity matters to the MotionPolicy, but are not directly controlled. e.g. A MotionPolicy may control a robot arm on a mobile robot. The joint states in the rest of the robot directly affect the position of the arm, but they are not actively controlled by this MotionPolicy Returns: List[str]: Names of joints that are being watched by this MotionPolicy. The order of joints in this list determines the order in which a MotionPolicy expects joint states to be specified in functions like compute_joint_targets(...,watched_joint_positions,...) """ return [] def set_cspace_target(self, active_joint_targets: np.array) -> None: """Set configuration space target for the robot. Args: active_joint_target (np.array): Desired configuration for the robot as (m x 1) vector where m is the number of active joints. Returns: None """ pass def set_end_effector_target(self, target_translation=None, target_orientation=None) -> None: """Set end effector target. Args: target_translation (nd.array): Translation vector (3x1) for robot end effector. Target translation should be specified in the same units as the USD stage, relative to the stage origin. target_orientation (nd.array): Quaternion of desired rotation for robot end effector relative to USD stage global frame Returns: None """ pass
5,224
Python
48.761904
212
0.690084
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/articulation_motion_policy.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import torch import carb from .motion_policy_interface import MotionPolicy from omni.isaac.core.articulations import Articulation, ArticulationSubset from omni.isaac.core.utils.types import ArticulationAction class ArticulationMotionPolicy: """Wrapper class for running MotionPolicy on simulated robots. Args: robot_articulation (Articulation): an initialized robot Articulation object motion_policy (MotionPolicy): an instance of a class that implements the MotionPolicy interface default_physics_dt (float): Default physics step size to use when computing actions. A MotionPolicy computes a target position/velocity for the next frame of the simulation using the provided physics dt to know how far in the future that will be. Isaac Sim can be run with a constant or variable physics framerate. When not specified on an individual frame, the dt of the frame is assumed to be the provided default value. Returns: None """ def __init__( self, robot_articulation: Articulation, motion_policy: MotionPolicy, default_physics_dt: float = 1 / 60.0 ) -> None: self.physics_dt = default_physics_dt self._robot_articulation = robot_articulation self.motion_policy = motion_policy self._articulation_controller = self._robot_articulation.get_articulation_controller() self._active_joints_view = ArticulationSubset(robot_articulation, motion_policy.get_active_joints()) self._watched_joints_view = ArticulationSubset(robot_articulation, motion_policy.get_watched_joints()) self._default_physics_dt = default_physics_dt def move(self, physics_dt: float = None) -> None: """Use underlying MotionPolicy to compute and apply joint targets to the robot over the next frame. Args: physics_dt (float): Physics dt to use on this frame to calculate the next action. This overrides the default_physics_dt argument, but does not change the default on future calls. Return: None """ action = self.get_next_articulation_action(physics_dt=physics_dt) self._articulation_controller.apply_action(action) def get_next_articulation_action(self, physics_dt: float = None) -> ArticulationAction: """Use underlying MotionPolicy to compute joint targets for the robot over the next frame. Args: physics_dt (float): Physics dt to use on this frame to calculate the next action. This overrides the default_physics_dt argument, but does not change the default on future calls. Returns: ArticulationAction: Desired position/velocity target for the robot in the next frame """ if physics_dt is None: physics_dt = self._default_physics_dt joint_positions, joint_velocities = ( self._active_joints_view.get_joint_positions(), self._active_joints_view.get_joint_velocities(), ) watched_joint_positions, watched_joint_velocities = ( self._watched_joints_view.get_joint_positions(), self._watched_joints_view.get_joint_velocities(), ) if joint_positions is None: carb.log_error( "Attempted to compute an action, but the robot Articulation has not been initialized. Cannot get joint positions or velocities." ) # convert to numpy if torch tensor if isinstance(joint_positions, torch.Tensor): joint_positions = joint_positions.cpu().numpy() if isinstance(joint_velocities, torch.Tensor): joint_velocities = joint_velocities.cpu().numpy() if isinstance(watched_joint_positions, torch.Tensor): watched_joint_positions = watched_joint_positions.cpu().numpy() if isinstance(watched_joint_velocities, torch.Tensor): watched_joint_velocities = watched_joint_velocities.cpu().numpy() position_targets, velocity_targets = self.motion_policy.compute_joint_targets( joint_positions, joint_velocities, watched_joint_positions, watched_joint_velocities, physics_dt ) return self._active_joints_view.make_articulation_action(position_targets, velocity_targets) def get_active_joints_subset(self) -> ArticulationSubset: """Get view into active joints Returns: ArticulationSubset: returns robot states for active joints in an order compatible with the MotionPolicy """ return self._active_joints_view def get_watched_joints_subset(self) -> ArticulationSubset: """Get view into watched joints Returns: ArticulationSubset: returns robot states for watched joints in an order compatible with the MotionPolicy """ return self._watched_joints_view def get_robot_articulation(self) -> Articulation: """ Get the underlying Articulation object representing the robot. Returns: Articulation: Articulation object representing the robot. """ return self._robot_articulation def get_motion_policy(self) -> MotionPolicy: """Get MotionPolicy that is being used to compute ArticulationActions Returns: MotionPolicy: MotionPolicy being used to compute ArticulationActions """ return self.motion_policy def get_default_physics_dt(self) -> float: """Get the default value of the physics dt that is used to compute actions when none is provided Returns: float: Default physics dt """ return self._default_physics_dt def set_default_physics_dt(self, physics_dt: float) -> None: """Set the default value of the physics dt that is used to compute actions when none is provided Args: physics_dt (float): Default physics dt Returns: None """ self._default_physics_dt = physics_dt
6,492
Python
40.356688
145
0.677911
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/path_planning_interface.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np from typing import List from omni.isaac.motion_generation.world_interface import WorldInterface class PathPlanner(WorldInterface): """Interface for implementing a PathPlanner: An algorithm that outputs a series of configuration space waypoints, which when linearly interpolated, produce a collision-free path from a starting c-space pose to a c-space or task-space target pose. """ def __init__(self) -> None: pass def set_robot_base_pose(self, robot_translation: np.array, robot_orientation: np.array): """Set the position of the robot base. Computed paths will assume that the robot base remains stationary. Args: robot_translation (np.array): (3 x 1) translation vector describing the translation of the robot base relative to the USD stage origin. The translation vector should be specified in the units of the USD stage robot_orientation (np.array): (4 x 1) quaternion describing the orientation of the robot base relative to the USD stage global frame """ pass def compute_path(self, active_joint_positions: np.array, watched_joint_positions: np.array) -> np.array: """Compute a set of c-space waypoints, which when linearly interpolated, produce a collision-free path from a starting c-space pose to a c-space or task-space target pose. Args: active_joint_positions (np.array): current positions of joints specified by get_active_joints() watched_joint_positions (np.array): current positions of joints specified by get_watched_joints() Returns: np.array or None: path: An (N x m) sequence of joint positions for the active joints in the robot where N is the path length and m is the number of active joints in the robot. If no plan is found, or no target positions have been set, None is returned """ return active_joint_positions def get_active_joints(self) -> List[str]: """Active joints are directly controlled by this PathPlanner Some articulated robot joints may be ignored by some policies. E.g., the gripper of the Franka arm is not used to follow targets, and the RMPflow config files excludes the joints in the gripper from the list of articulated joints. Returns: List[str]: names of active joints. The order of joints in this list determines the order in which a PathPlanner expects joint states to be specified in functions like compute_path(active_joint_positions,...) """ return [] def get_watched_joints(self) -> List[str]: """Watched joints are joints whose position matters to the PathPlanner, but are not directly controlled. e.g. A robot may have a watched joint in the middle of its kinematic chain. Watched joints will be assumed to remain watched during the rollout of a path. Returns: List[str]: Names of joints that are being watched by this PathPlanner. The order of joints in this list determines the order in which a PathPlanner expects joint states to be specified in functions like compute_path(...,watched_joint_positions,...). """ return [] def set_cspace_target(self, active_joint_targets: np.array) -> None: """Set configuration space target for the robot. Args: active_joint_target (np.array): Desired configuration for the robot as (m x 1) vector where m is the number of active joints. Returns: None """ pass def set_end_effector_target(self, target_translation, target_orientation=None) -> None: """Set end effector target. Args: target_translation (nd.array): Translation vector (3x1) for robot end effector. Target translation should be specified in the same units as the USD stage, relative to the stage origin. target_orientation (nd.array): Quaternion of desired rotation for robot end effector relative to USD stage global frame Returns: None """ pass
4,640
Python
47.852631
148
0.685345
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/motion_policy_controller.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.core.controllers import BaseController from omni.isaac.motion_generation import ArticulationMotionPolicy, MotionPolicy from omni.isaac.core.utils.types import ArticulationAction from typing import Optional import omni.isaac.core.objects from omni.isaac.core.utils.rotations import euler_angles_to_quat import numpy as np class MotionPolicyController(BaseController): """A Controller that steps using an arbitrary MotionPolicy Args: name (str): name of this controller articulation_motion_policy (ArticulationMotionPolicy): a wrapper around a MotionPolicy for computing ArticulationActions that can be directly applied to the robot """ def __init__(self, name: str, articulation_motion_policy: ArticulationMotionPolicy) -> None: BaseController.__init__(self, name) self._articulation_motion_policy = articulation_motion_policy self._motion_policy = self._articulation_motion_policy.get_motion_policy() return def forward( self, target_end_effector_position: np.ndarray, target_end_effector_orientation: Optional[np.ndarray] = None ) -> ArticulationAction: """Compute an ArticulationAction representing the desired robot state for the next simulation frame Args: target_translation (nd.array): Translation vector (3x1) for robot end effector. Target translation should be specified in the same units as the USD stage, relative to the stage origin. target_orientation (Optional[np.ndarray], optional): Quaternion of desired rotation for robot end effector relative to USD stage global frame. Target orientation defaults to None, which means that the robot may reach the target with any orientation. Returns: ArticulationAction: A wrapper object containing the desired next state for the robot """ self._motion_policy.set_end_effector_target(target_end_effector_position, target_end_effector_orientation) self._motion_policy.update_world() action = self._articulation_motion_policy.get_next_articulation_action() return action def add_obstacle(self, obstacle: omni.isaac.core.objects, static: bool = False) -> None: """Add an object from omni.isaac.core.objects as an obstacle to the motion_policy Args: obstacle (omni.isaac.core.objects): Dynamic, Visual, or Fixed object from omni.isaac.core.objects static (bool): If True, the obstacle may be assumed by the MotionPolicy to remain stationary over time """ self._motion_policy.add_obstacle(obstacle, static=static) return def remove_obstacle(self, obstacle: omni.isaac.core.objects) -> None: """Remove and added obstacle from the motion_policy Args: obstacle (omni.isaac.core.objects): Object from omni.isaac.core.objects that has been added to the motion_policy """ self._motion_policy.remove_obstacle(obstacle) return def reset(self) -> None: """ """ self._motion_policy.reset() return def get_articulation_motion_policy(self) -> ArticulationMotionPolicy: """Get ArticulationMotionPolicy that was passed to this class on initialization Returns: ArticulationMotionPolicy: a wrapper around a MotionPolicy for computing ArticulationActions that can be directly applied to the robot """ return self._articulation_motion_policy def get_motion_policy(self) -> MotionPolicy: """Get MotionPolicy object that is being used to generate robot motions Returns: MotionPolicy: An instance of a MotionPolicy that is being used to compute robot motions """ return self._motion_policy
4,267
Python
43.458333
174
0.709632
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/wheel_base_pose_controller.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.core.controllers import BaseController from omni.isaac.core.utils.types import ArticulationAction from omni.isaac.core.utils.rotations import quat_to_euler_angles import numpy as np import math class WheelBasePoseController(BaseController): """[summary] Args: name (str): [description] open_loop_wheel_controller (BaseController): A controller that takes in a command of [longitudinal velocity, steering angle] and returns the ArticulationAction to be applied to the wheels if non holonomic. and [longitudinal velocity, latitude velocity, steering angle] if holonomic. is_holonomic (bool, optional): [description]. Defaults to False. """ def __init__(self, name: str, open_loop_wheel_controller: BaseController, is_holonomic: bool = False) -> None: super().__init__(name) self._open_loop_wheel_controller = open_loop_wheel_controller self._is_holonomic = is_holonomic return def forward( self, start_position: np.ndarray, start_orientation: np.ndarray, goal_position: np.ndarray, lateral_velocity: float = 0.2, yaw_velocity: float = 0.5, heading_tol: float = 0.05, position_tol: float = 0.04, ) -> ArticulationAction: """[summary] Args: start_position (np.ndarray): [description] start_orientation (np.ndarray): [description] goal_position (np.ndarray): [description] lateral_velocity (float, optional): [description]. Defaults to 20.0. yaw_velocity (float, optional): [description]. Defaults to 0.5. heading_tol (float, optional): [description]. Defaults to 0.05. position_tol (float, optional): [description]. Defaults to 4.0. Returns: ArticulationAction: [description] """ steering_yaw = math.atan2( goal_position[1] - start_position[1], float(goal_position[0] - start_position[0] + 1e-5) ) current_yaw_heading = quat_to_euler_angles(start_orientation)[-1] yaw_error = steering_yaw - current_yaw_heading if np.mean(np.abs(start_position[:2] - goal_position[:2])) < position_tol: if self._is_holonomic: command = [0.0, 0.0, 0.0] else: command = [0.0, 0.0] elif abs(yaw_error) > heading_tol: direction = 1 if yaw_error < 0: direction = -1 if self._is_holonomic: command = [0.0, 0.0, direction * yaw_velocity] else: command = [0.0, direction * yaw_velocity] else: if self._is_holonomic: command = [lateral_velocity, 0.0, 0.0] else: command = [lateral_velocity, 0] return self._open_loop_wheel_controller.forward(command) def reset(self) -> None: """[summary] """ return
3,614
Python
40.079545
116
0.586608
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/articulation_kinematics_solver.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import carb from omni.isaac.core.utils.types import ArticulationAction from omni.isaac.core.articulations import Articulation, ArticulationSubset from omni.isaac.motion_generation.kinematics_interface import KinematicsSolver from typing import Optional, Tuple import numpy as np class ArticulationKinematicsSolver: """Wrapper class for computing robot kinematics in a way that is easily transferable to the simulated robot Articulation. A KinematicsSolver computes FK and IK at any frame, possibly only using a subset of joints available on the simulated robot. This wrapper simplifies computing the current position of the simulated robot's end effector, as well as wrapping an IK result in an ArticulationAction that is recognized by the robot Articulation Args: robot_articulation (Articulation): Initialized robot Articulation object representing the simulated USD robot kinematics_solver (KinematicsSolver): An instance of a class that implements the KinematicsSolver end_effector_frame_name (str): The name of the robot's end effector frame. This frame must appear in kinematics_solver.get_all_frame_names() """ def __init__( self, robot_articulation: Articulation, kinematics_solver: KinematicsSolver, end_effector_frame_name: str ): self._robot_articulation = robot_articulation self._kinematics_solver = kinematics_solver self.set_end_effector_frame(end_effector_frame_name) self._joints_view = ArticulationSubset(robot_articulation, kinematics_solver.get_joint_names()) return def compute_end_effector_pose(self, position_only=False) -> Tuple[np.array, np.array]: """Compute the pose of the robot end effector using the simulated robot's current joint positions Args: position_only (bool): If True, only the frame positions need to be calculated. The returned rotation may be left undefined. Returns: Tuple[np.array,np.array]: position: Translation vector describing the translation of the robot end effector relative to the USD global frame (in stage units) rotation: (3x3) rotation matrix describing the rotation of the frame relative to the USD stage global frame """ joint_positions = self._joints_view.get_joint_positions() if joint_positions is None: carb.log_error( "Attempted to compute forward kinematics for an uninitialized robot Articulation. Cannot get joint positions" ) return self._kinematics_solver.compute_forward_kinematics( self._ee_frame, joint_positions, position_only=position_only ) def compute_inverse_kinematics( self, target_position: np.array, target_orientation: Optional[np.array] = None, position_tolerance: Optional[float] = None, orientation_tolerance: Optional[float] = None, ) -> Tuple[ArticulationAction, bool]: """ Compute inverse kinematics for the end effector frame using the current robot position as a warm start. The result is returned in an articulation action that can be directly applied to the robot. Args: target_position (np.array): target translation of the target frame (in stage units) relative to the USD stage origin target_orientation (np.array): target orientation of the target frame relative to the USD stage global frame. Defaults to None. position_tolerance (float): l-2 norm of acceptable position error (in stage units) between the target and achieved translations. Defaults to None. orientation tolerance (float): magnitude of rotation (in radians) separating the target orientation from the achieved orienatation. orientation_tolerance is well defined for values between 0 and pi. Defaults to None. Returns: Tuple[ArticulationAction, bool]: ik_result: An ArticulationAction that can be applied to the robot to move the end effector frame to the desired position. success: Solver converged successfully """ warm_start = self._joints_view.get_joint_positions() if warm_start is None: carb.log_error( "Attempted to compute inverse kinematics for an uninitialized robot Articulation. Cannot get joint positions" ) ik_result, succ = self._kinematics_solver.compute_inverse_kinematics( self._ee_frame, target_position, target_orientation, warm_start, position_tolerance, orientation_tolerance ) return ArticulationAction(joint_positions=self._joints_view.map_to_articulation_order(ik_result)), succ def set_end_effector_frame(self, end_effector_frame_name: str) -> None: """Set the name for the end effector frame. If the frame is not recognized by the internal KinematicsSolver instance, an error will be thrown Args: end_effector_frame_name (str): Name of the robot end effector frame. """ if end_effector_frame_name not in self._kinematics_solver.get_all_frame_names(): carb.log_error( "Frame name" + end_effector_frame_name + " not recognized by KinematicsSolver. Use KinematicsSolver.get_all_frame_names() to get a list of valid frames" ) self._ee_frame = end_effector_frame_name def get_end_effector_frame(self) -> str: """Get the end effector frame Returns: str: Name of the end effector frame """ return self._ee_frame def get_joints_subset(self) -> ArticulationSubset: """ Returns: ArticulationSubset: A wrapper class for querying USD robot joint states in the order expected by the kinematics solver """ return self._joints_view def get_kinematics_solver(self) -> KinematicsSolver: """Get the underlying KinematicsSolver instance used by this class. Returns: KinematicsSolver: A class that can solve forward and inverse kinematics for a specified robot. """ return self._kinematics_solver
6,659
Python
49.075188
163
0.697402
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/world_interface.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import carb from typing import List, Union, Optional import omni.isaac.core.objects from omni.isaac.core.objects import cuboid, sphere, capsule, cylinder, cone, ground_plane class WorldInterface: """Interface for translating USD world to a generic world-aware algorithm such as a MotionPolicy """ def __init__(self) -> None: pass def update_world(self, updated_obstacles: Optional[List] = None) -> None: """Applies all necessary updates to the internal world representation. Args: updated_obstacles (list, optional): If provided, only the given obstacles will have their poses updated. For motion policies that use obstacle poses relative to the robot base (e.g. Lula based policies), this list will be ignored if the robot base has moved because all object poses will have changed relative to the robot. Defaults to None. Returns: None """ pass def add_obstacle(self, obstacle: omni.isaac.core.objects, static: Optional[bool] = False) -> bool: """Add an obstacle Args: obstacle (omni.isaac.core.objects): An obstacle from the package omni.isaac.core.obstacles The type of the obstacle will be checked, and the appropriate add function will be called \n static (Optional[bool]): When True, the obstacle will be assumed to remain stationary relative to the USD global frame over time Returns: success (bool): Returns True if the obstacle type is valid and the appropriate add function has been implemented """ if ( isinstance(obstacle, cuboid.DynamicCuboid) or isinstance(obstacle, cuboid.VisualCuboid) or isinstance(obstacle, cuboid.FixedCuboid) ): return self.add_cuboid(obstacle, static=static) elif isinstance(obstacle, cylinder.DynamicCylinder) or isinstance(obstacle, cylinder.VisualCylinder): return self.add_cylinder(obstacle, static=static) elif isinstance(obstacle, sphere.DynamicSphere) or isinstance(obstacle, sphere.VisualSphere): return self.add_sphere(obstacle, static=static) elif isinstance(obstacle, capsule.DynamicCapsule) or isinstance(obstacle, capsule.VisualCapsule): return self.add_capsule(obstacle, static=static) elif isinstance(obstacle, cone.DynamicCone) or isinstance(obstacle, cone.VisualCone): return self.add_cone(obstacle, static=static) elif isinstance(obstacle, ground_plane.GroundPlane): return self.add_ground_plane(obstacle) else: carb.log_warning( "Obstacle added with unsuported type: " + str(type(obstacle)) + "\nObstacle should be from the package omni.isaac.core.objects" ) return False def add_cuboid( self, cuboid: Union[cuboid.DynamicCuboid, cuboid.FixedCuboid, cuboid.VisualCuboid], static: bool = False ) -> bool: """Add a block obstacle. Args: cuboid (core.objects.cuboid): Wrapper object for handling rectangular prism Usd Prims. static (bool, optional): If True, indicate that cuboid will never change pose, and may be ignored in internal world updates. Defaults to False. Returns: bool: Return True if underlying WorldInterface has implemented add_cuboid() """ carb.log_warning("Function add_cuboid() has not been implemented for this WorldInterface") return False def add_sphere(self, sphere: Union[sphere.DynamicSphere, sphere.VisualSphere], static: bool = False) -> bool: """Add a sphere obstacle. Args: sphere (core.objects.sphere): Wrapper object for handling sphere Usd Prims. static (bool, optional): If True, indicate that sphere will never change pose, and may be ignored in internal world updates. Defaults to False. Returns: bool: Return True if underlying WorldInterface has implemented add_sphere() """ carb.log_warning("Function add_sphere() has not been implemented for this WorldInterface") return False def add_capsule(self, capsule: Union[capsule.DynamicCapsule, capsule.VisualCapsule], static: bool = False) -> bool: """Add a capsule obstacle. Args: capsule (core.objects.capsule): Wrapper object for handling capsule Usd Prims. static (bool, optional): If True, indicate that capsule will never change pose, and may be ignored in internal world updates. Defaults to False. Returns: bool: Return True if underlying WorldInterface has implemented add_capsule() """ carb.log_warning("Function add_capsule() has not been implemented for this WorldInterface") return False def add_cylinder( self, cylinder: Union[cylinder.DynamicCylinder, cylinder.VisualCylinder], static: bool = False ) -> bool: """Add a cylinder obstacle. Args: cylinder (core.objects.cylinder): Wrapper object for handling rectangular prism Usd Prims. static (bool, optional): If True, indicate that cuboid will never change pose, and may be ignored in internal world updates. Defaults to False. Returns: bool: Return True if underlying WorldInterface has implemented add_cylinder() """ carb.log_warning("Function add_cylinder() has not been implemented for this WorldInterface") return False def add_cone(self, cone: Union[cone.DynamicCone, cone.VisualCone], static: bool = False) -> bool: """Add a cone obstacle. Args: cone (core.objects.cone): Wrapper object for handling cone Usd Prims. static (bool, optional): If True, indicate that cone will never change pose, and may be ignored in internal world updates. Defaults to False. Returns: bool: Return True if underlying WorldInterface has implemented add_cone() """ carb.log_warning("Function add_cone() has not been implemented for this WorldInterface") return False def add_ground_plane(self, ground_plane: ground_plane.GroundPlane) -> bool: """Add a ground_plane Args: ground_plane (core.objects.ground_plane.GroundPlane): Wrapper object for handling ground_plane Usd Prims. Returns: bool: Return True if underlying WorldInterface has implemented add_ground_plane() """ carb.log_warning("Function add_ground_plane() has not been implemented for this WorldInterface") return False def disable_obstacle(self, obstacle: omni.isaac.core.objects) -> bool: """Disable collision avoidance for obstacle. Args: obstacle (core.object): obstacle to be disabled. Returns: bool: Return True if obstacle was identified and successfully disabled. """ carb.log_warning("Function disable_obstacle() has not been implemented for this WorldInterface") return False def enable_obstacle(self, obstacle: omni.isaac.core.objects) -> bool: """Enable collision avoidance for obstacle. Args: obstacle (core.object): obstacle to be enabled. Returns: bool: Return True if obstacle was identified and successfully enabled. """ carb.log_warning("Function enable_obstacle() has not been implemented for this WorldInterface") return False def remove_obstacle(self, obstacle: omni.isaac.core.objects) -> bool: """Remove obstacle from collision avoidance. Obstacle cannot be re-enabled via enable_obstacle() after removal. Args: obstacle (core.object): obstacle to be removed. Returns: bool: Return True if obstacle was identified and successfully removed. """ carb.log_warning("Function remove_obstacle() has not been implemented for this WorldInterface") return False def reset(self) -> None: """Reset all state inside the WorldInterface to its initial values """ pass
8,802
Python
41.941463
140
0.659396
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/articulation_trajectory.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np from .trajectory import Trajectory from omni.isaac.core.articulations import Articulation, ArticulationSubset from omni.isaac.core.utils.types import ArticulationAction from typing import List import carb class ArticulationTrajectory: """Wrapper class which takes in a Trajectory object and converts the output to discrete ArticulationActions that may be sent to the provided robot Articulation. Args: robot_articulation (Articulation): Initialized robot Articulation object representing the simulated USD robot trajectory (Trajectory): An instance of a class that implements the Trajectory interface. physics_dt (float): Duration of a physics step in Isaac Sim (typically 1/60 s). """ def __init__(self, robot_articulation: Articulation, trajectory: Trajectory, physics_dt: float) -> None: self._articulation = robot_articulation self._trajectory = trajectory self._physics_dt = physics_dt self._active_joints_view = ArticulationSubset(robot_articulation, trajectory.get_active_joints()) def get_action_at_time(self, time: float) -> ArticulationAction: """Get an ArticulationAction that will send the robot to the desired position/velocity at a given time in the provided Trajectory. Args: time (float): Time between the start and end times in the provided Trajectory. If the time is out of bounds, an error will be thrown. Returns: ArticulationAction: ArticulationAction that may be passed directly to the robot Articulation to send it to the desired position/velocity at the given time. """ if time < self._trajectory.start_time: carb.log_error( f"Provided time {time} is before the start time {self._trajectory.start_time} of the Trajectory" ) if time > self._trajectory.end_time: carb.log_error(f"Provided time {time} is after the end time {self._trajectory.end_time} of the Trajectory") position_target, velocity_target = self._trajectory.get_joint_targets(time) position_action_np_array = self._active_joints_view.map_to_articulation_order(position_target) velocity_action_np_array = self._active_joints_view.map_to_articulation_order(velocity_target) return ArticulationAction(joint_positions=position_action_np_array, joint_velocities=velocity_action_np_array) def get_action_sequence(self, timestep: float = None) -> List[ArticulationAction]: """Get a sequence of ArticulationActions which sample the entire Trajectory according to the provided timestep. Args: timestep (float, optional): Timestep used for sampling the provided Trajectory. A vlue of 1/60, for example, returns ArticulationActions that represent the desired position/velocity of the robot at 1/60 second intervals. I.e. a one second trajectory with timestep=1/60 would result in 60 ArticulationActions. When not provided, the framerate of Isaac Sim is used. Defaults to None. Returns: List[ArticulationAction]: Sequence of ArticulationActions that may be passed to the robot Articulation to produce the desired trajectory. """ if timestep is None: timestep = self._physics_dt actions = [] for t in np.arange(self._trajectory.start_time, self._trajectory.end_time, timestep): actions.append(self.get_action_at_time(t)) return actions def get_trajectory_duration(self) -> float: """Returns the duration of the provided Trajectory Returns: float: Duration of the provided trajectory """ return self._trajectory.end_time - self._trajectory.start_time def get_active_joints_subset(self) -> ArticulationSubset: """Get view into active joints Returns: ArticulationSubset: Returns robot states for active joints in an order compatible with the TrajectoryGenerator """ return self._active_joints_view def get_robot_articulation(self) -> Articulation: """Get the robot Articulation Returns: Articulation: Articulation object describing the robot. """ return self._articulation def get_trajectory(self) -> Trajectory: return self._trajectory
4,831
Python
46.372549
167
0.704616
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/interface_helper.py
import lula import numpy as np from .world import LulaWorld from typing import List, Tuple, Union, Optional from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices from omni.isaac.core.utils.string import find_unique_string_name from omni.isaac.core.utils.prims import is_prim_path_valid, delete_prim from omni.isaac.core.utils.stage import get_stage_units from omni.isaac.core.prims.xform_prim import XFormPrim from omni.isaac.core import objects from . import utils as lula_utils class LulaInterfaceHelper(LulaWorld): """ Class containing functions common in Lula based algorithms. The main utility of this class is handling the tracking of the robot base and returning basic robot information """ def __init__(self, robot_description: lula.RobotDescription): LulaWorld.__init__(self) self._robot_description = robot_description self._kinematics = self._robot_description.kinematics() self._robot_base_moved = False self._robot_pos, self._robot_rot = np.zeros(3), np.eye(3) self._meters_per_unit = get_stage_units() def set_robot_base_pose(self, robot_position: np.array, robot_orientation: np.array) -> None: """Update position of the robot base. Until this function is called, Lula will assume the base pose to be at the origin with identity rotation. Args: robot_position (np.array): (3 x 1) translation vector describing the translation of the robot base relative to the USD stage origin. The translation vector should be specified in the units of the USD stage robot_orientation (np.array): (4 x 1) quaternion describing the orientation of the robot base relative to the USD stage global frame """ # all object poses are relative to the position of the robot base robot_position = robot_position * self._meters_per_unit robot_rot = quats_to_rot_matrices(robot_orientation) if np.any(self._robot_pos - robot_position) or np.any(self._robot_rot - robot_rot): self._robot_base_moved = True else: self._robot_base_moved = False self._robot_pos = robot_position self._robot_rot = robot_rot def get_active_joints(self): return [ self._robot_description.c_space_coord_name(i) for i in range(self._robot_description.num_c_space_coords()) ] def get_watched_joints(self) -> List: """Lula does not currently support watching joint states that are not controllable Returns: (List): Always returns an empty list. """ return [] def get_end_effector_pose(self, active_joint_positions: np.array, frame_name: str) -> Tuple[np.array, np.array]: """Return pose of robot end effector given current joint positions. The end effector position will be transformed into world coordinates based on the believed position of the robot base. See set_robot_base_pose() Args: active_joint_positions (np.array): positions of the active joints in the robot Returns: Tuple[np.array,np.array]: end_effector_translation: (3x1) translation vector for the robot end effector relative to the USD stage origin \n end_effector_rotation: (3x3) rotation matrix describing the orientation of the robot end effector relative to the USD global frame \n """ # returns pose of end effector in world coordinates pose = self._kinematics.pose(np.expand_dims(active_joint_positions, 1), frame_name) translation = self._robot_rot @ (pose.translation) + self._robot_pos rotation = self._robot_rot @ pose.rotation.matrix() return translation / self._meters_per_unit, rotation def update_world(self, updated_obstacles: Optional[List] = None): LulaWorld.update_world(self, updated_obstacles, self._robot_pos, self._robot_rot, self._robot_base_moved) self._robot_base_moved = False def add_cuboid( self, cuboid: Union[objects.cuboid.DynamicCuboid, objects.cuboid.FixedCuboid, objects.cuboid.VisualCuboid], static: Optional[bool] = False, ): return LulaWorld.add_cuboid(self, cuboid, static, self._robot_pos, self._robot_rot) def add_sphere( self, sphere: Union[objects.sphere.DynamicSphere, objects.sphere.VisualSphere], static: bool = False ): return LulaWorld.add_sphere(self, sphere, static, self._robot_pos, self._robot_rot) def add_capsule( self, capsule: Union[objects.capsule.DynamicCapsule, objects.capsule.VisualCapsule], static: bool = False ): return LulaWorld.add_capsule(self, capsule, static, self._robot_pos, self._robot_rot) def reset(self): LulaWorld.reset(self) self._robot_base_moved = False self._robot_pos, self._robot_rot = np.zeros(3), np.eye(3) def _get_prim_pose_rel_robot_base(self, prim): # returns the position of a prim relative to the position of the robot return lula_utils.get_prim_pose_in_meters_rel_robot_base( prim, self._meters_per_unit, self._robot_pos, self._robot_rot ) def _get_pose_rel_robot_base(self, trans, rot): return lula_utils.get_pose_rel_robot_base(trans, rot, self._robot_pos, self._robot_rot)
5,404
Python
42.943089
144
0.672835
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/trajectory_generator.py
# Copyright (c) 2022, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np import carb from typing import Tuple, List, Union from ..trajectory import Trajectory from .kinematics import LulaKinematicsSolver from .utils import get_pose3 import lula class LulaTrajectory(Trajectory): """Instance of Trajectory interface class for handling lula.Trajectory objects Args: trajectory (lula.Trajectory): C-space trajectory defined continuously """ def __init__(self, trajectory, active_joints): self.trajectory = trajectory self.active_joints = active_joints @property def start_time(self) -> float: __doc__ = Trajectory.start_time.__doc__ return self.trajectory.domain().lower @property def end_time(self) -> float: __doc__ = Trajectory.end_time.__doc__ return self.trajectory.domain().upper def get_active_joints(self) -> List[str]: __doc__ = Trajectory.get_active_joints.__doc__ return self.active_joints def get_joint_targets(self, time) -> Tuple[np.array, np.array]: __doc__ = Trajectory.get_joint_targets.__doc__ if time > self.end_time or time < self.start_time: carb.log_error("Could not compute joint targets because the provided time is out of bounds") return self.trajectory.eval(time, 0), self.trajectory.eval(time, 1) class LulaCSpaceTrajectoryGenerator: """LulaCSpaceTrajectoryGenerator is a class for generating time-optimal trajectories that connect a series of provided c-space waypoints. Args: robot_description_path (str): path to a robot description yaml file urdf_path (str): path to robot urdf """ def __init__(self, robot_description_path: str, urdf_path: str) -> None: self._robot_description = lula.load_robot(robot_description_path, urdf_path) self._lula_kinematics = self._robot_description.kinematics() self._kinematics_solver = LulaKinematicsSolver(robot_description_path, urdf_path, self._robot_description) self._c_space_trajectory_generator = None self._task_space_trajectory_generator = None self._c_space_trajectory_generator = lula.create_c_space_trajectory_generator(self._lula_kinematics) def compute_c_space_trajectory(self, waypoint_positions: np.array) -> LulaTrajectory: """Produce a trajectory from a set of provided c_space waypoint positions. The resulting trajectory will use spline-based interpolation to connect the waypoints with an initial and final velocity of 0. The trajectory is time-optimal: i.e. either the velocity, acceleration, or jerk limits are saturated at any given time to produce as trajectory with as short a duration as possible. Args: waypoint_positions (np.array): Set of c-space coordinates cooresponding to the output of get_active_joints(). The expected shape is (N x k) where N is the number of waypoints and k is the number of active joints. Returns: LulaTrajectory: Instance of the Trajectory class which specifies continuous joint_targets for the active joints over a span of time. """ if waypoint_positions.shape[0] < 2: carb.log_error("LulaTrajectoryGenerator must be passed at least two waypoints") if waypoint_positions.shape[1] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"LulaTrajectoryGenerator was passed a set of waypoints with invalid shape: {waypoint_positions.shape}." + f" Expecting shape ({waypoint_positions.shape[0]}, {self._lula_kinematics.num_c_space_coords()})." + " Make sure that the provided waypoint_positions corresponds to the output of get_active_joints()." ) trajectory = self._c_space_trajectory_generator.generate_trajectory(waypoint_positions.astype(np.float64)) if trajectory is None: carb.log_warn( "LulaTrajectoryGenerator could not generate a trajectory connecting the given waypoints. Returning None" ) return return LulaTrajectory(trajectory, self.get_active_joints()) def get_active_joints(self) -> List[str]: """Return the list of joints by name that are considered to be controllable by the TrajectoryGenerator. All inputs and outputs of the LulaTrajectoryGenerator correspond to the joints specified by get_active_joints(). Returns: List[str]: List of joints that are used to generate the desired trajectory. """ return self._kinematics_solver.get_joint_names() def set_c_space_position_limits(self, lower_position_limits: np.array, upper_position_limits: np.array) -> None: """Set the lower and upper position limits of the active joints to be used when generating a trajectory. Args: lower_position_limits (np.array): Lower position limits of active joints. upper_position_limits (np.array): Upper position limits of active joints. """ if lower_position_limits.shape[0] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"Provided lower position limits have an incorrect shape: {lower_position_limits.shape}\n" + f"Expected shape: ({self._lula_kinematics.num_c_space_coords()},)" + " Make sure that the provided position limits corresponds to the output of get_active_joints()." ) if upper_position_limits.shape[0] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"Provided upper position limits have an incorrect shape: {upper_position_limits.shape}\n" + f"Expected shape: ({self._lula_kinematics.num_c_space_coords()},)" + " Make sure that the provided position limits corresponds to the output of get_active_joints()." ) c_space_position_lower_limits = lower_position_limits.astype(np.float64) c_space_position_upper_limits = upper_position_limits.astype(np.float64) self._c_space_trajectory_generator.set_position_limits( c_space_position_lower_limits, c_space_position_upper_limits ) def set_c_space_velocity_limits(self, velocity_limits: np.array) -> None: """Set the velocity limits of the active joints to be used when generating a trajectory. Args: velocity_limits (np.array): Velocity limits of active joints. """ if velocity_limits.shape[0] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"Provided velocity limits have an incorrect shape: {velocity_limits.shape}\n" + f"Expected shape: ({self._lula_kinematics.num_c_space_coords()},)" + " Make sure that the provided velocity limits corresponds to the output of get_active_joints()." ) c_space_velocity_limits = velocity_limits.astype(np.float64) self._c_space_trajectory_generator.set_velocity_limits(c_space_velocity_limits) def set_c_space_acceleration_limits(self, acceleration_limits: np.array) -> None: """Set the acceleration limits of the active joints to be used when generating a trajectory. Args: acceleration_limits (np.array): Acceleration limits of active joints. """ if acceleration_limits.shape[0] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"Provided acceleration limits have an incorrect shape: {acceleration_limits.shape}\n" + f"Expected shape: ({self._lula_kinematics.num_c_space_coords()},)" + " Make sure that the provided acceleration limits corresponds to the output of get_active_joints()." ) c_space_acceleration_limits = acceleration_limits.astype(np.float64) self._c_space_trajectory_generator.set_acceleration_limits(c_space_acceleration_limits) def set_c_space_jerk_limits(self, jerk_limits: np.array) -> None: """Set the jerk limits of the active joints to be used when generating a trajectory. Args: jerk_limits (np.array): Jerk limits of active joints. """ if jerk_limits.shape[0] != self._lula_kinematics.num_c_space_coords(): carb.log_error( f"Provided jerk limits have an incorrect shape: {jerk_limits.shape}\n" + f"Expected shape: ({self._lula_kinematics.num_c_space_coords()},)" + " Make sure that the provided jerk limits corresponds to the output of get_active_joints()." ) c_space_jerk_limits = jerk_limits.astype(np.float64) self._c_space_trajectory_generator.set_jerk_limits(c_space_jerk_limits) def set_solver_param(self, param_name: str, param_val: Union[int, float, str]): """Set solver parameters for the cspace trajectory generator. A complete list of parameters is provided in this docstring. 'max_segment_iterations': (int) In general, a trajectory is locally time-optimal if at least one derivative for one of the c-space coordinates is fully saturated, with no derivative limits for any of the c-space coordinates exceeded. This time-optimality can be enforced for each `CubicSpline` segment or for each `PiecewiseCubicSpline` as a whole. The former will, in general, generate trajectories with smaller spans, but will require more expensive iterations (and thus more time) to converge. The latter will, in general, require less iterations (and thus less time) to converge, but the generated trajectories will tend to have longer spans. When attempting to find a time-optimal trajectory, the (more expensive) per-segment method will first be attempted for `max_per_segment_iterations`. Then, if not yet converged, the method acting on the entire spline will be attempted for `max_aggregate_iterations`. To maximize speed, `max_segment_iterations` should be relatively low (or even zero to remove this search completely). To maximize time-optimality of the generated trajectory, `max_segment_iterations` should be relatively high. The sum of `max_segment_iterations` and `max_aggregate_iterations` must be at least 1 'max_aggragate_iterations': (int) See max_segment_iterations 'convergence_dt': (float) The search for optimal time values will terminate if the maximum change to any time value during a given iteration is less than the `convergence_dt`. `convergence_dt` must be positive. 'max_dilation_iterations': (int) After the segment-wise and/or aggregate time-optimal search has converged or reached maximum iterations, the resulting set of splines will be tested to see if any derivative limits are exceeded. If any derivative limits are exceeded, the splines will be iteratively scaled in time to reduce the maximum achieved derivative. This process will repeat until no derivative limits are exceeded (success) or `max_dilation_iterations_` are reached (failure). For a well-tuned set of solver parameters, very few dilation steps should be required (often none will be required or a single iteration is sufficient to bring a slightly over-saturated trajectory within the derivative limits). 'dilation_dt': (float) For the iterative dilation step described in `setMaxDilationIterations()` documentation, the `dilation_dt` is the "epsilon" value added to the span of the trajectory that exceeds derivative limits. `dilation_dt` must be positive. 'min_time_span': (float) Specify the minimum allowable time span between adjacent waypoints/endpoints. `min_time_span` must be positive. This is most likely to affect the time span between the endpoints and "free-position" points that are used to enable acceleration bound constraints. If no jerk limit is provided, these free-position points may tend to become arbitrarily close in position and time to the endpoints. This `min_time_span` prevents this time span from approaching zero. In general, a jerk limit is recommended for preventing abrupt changes in acceleration rather than relying on the `min_time_span` for this purpose. 'time_split_method': (string) Often waypoints for a trajectory may specify positions without providing time values for when these waypoint position should be attained. In this case, we can use the distance between waypoints to assign time values for each waypoint. Assuming a unitary time domain s.t. t_0 = 0 and t_N = 1, we can assign the intermediate time values according to: t_k = t_(k-1) + (d_k / d), where d = sum(d_k) for k = [0, N-1] and N is the number of points. Many options exist for the computing the distance metric d_k, with common options described below (and implemented in `ComputeTimeValues()`. See Eqn 4.37 in "Trajectory Planning for Automatic Machines and Robots" (2008) by Biagiotti & Melchiorri for more detailed motivations. Valid distribution choices are given below: 'uniform': For a "uniform distribution" w.r.t time, the positions are ignored and d_k can simply be computed as: d_k = 1 / (N - 1) resulting in uniform time intervals between all points. 'chord_length': For a "chord length distribution", the time intervals between waypoints are proportional to the Euclidean distance between waypoints: d_k = \|q_(k+1) - q_k\| where q represents the position of the waypoint. 'centripetal': For a "centripetal distribution", the time intervals between waypoints are proportional to the square root of the Euclidean distance between waypoints: d_k = \|q_(k+1) - q_k\|^(1/2) where q represents the position of the waypoint. Args: param_name (str): Parameter name from the above list of parameters param_val (Union[int, float, str]): Value to which the given parameter will be set """ self._c_space_trajectory_generator.set_solver_param(param_name, param_val) class LulaTaskSpaceTrajectoryGenerator: get_active_joints = LulaCSpaceTrajectoryGenerator.get_active_joints set_c_space_position_limits = LulaCSpaceTrajectoryGenerator.set_c_space_position_limits set_c_space_velocity_limits = LulaCSpaceTrajectoryGenerator.set_c_space_velocity_limits set_c_space_acceleration_limits = LulaCSpaceTrajectoryGenerator.set_c_space_acceleration_limits set_c_space_jerk_limits = LulaCSpaceTrajectoryGenerator.set_c_space_jerk_limits set_c_space_trajectory_generator_solver_param = LulaCSpaceTrajectoryGenerator.set_solver_param def __init__(self, robot_description_path: str, urdf_path: str) -> None: self._robot_description = lula.load_robot(robot_description_path, urdf_path) self._lula_kinematics = self._robot_description.kinematics() self._kinematics_solver = LulaKinematicsSolver(robot_description_path, urdf_path, self._robot_description) self._c_space_trajectory_generator = None self._task_space_trajectory_generator = None self._c_space_trajectory_generator = lula.create_c_space_trajectory_generator(self._lula_kinematics) self._path_conversion_config = lula.TaskSpacePathConversionConfig() def get_all_frame_names(self) -> List[str]: """Return a list of all frames in the robot URDF that may be used to follow a trajectory Returns: List[str]: List of all frame names in the robot URDF """ return self._lula_kinematics.frame_names() def compute_task_space_trajectory_from_points( self, positions: np.array, orientations: np.array, frame_name: str ) -> LulaTrajectory: """Return a LulaTrajectory that connects the provided positions and orientations at the specified frame in the robot. Args: positions (np.array): Taskspace positions that the robot end effector should pass through with shape (N x 3) where N is the number of provided positions. Positions is assumed to be in meters. orientations (np.array): Taskspace quaternion orientations that the robot end effector should pass through with shape (N x 4) where N is the number of provided orientations. The length of this argument must match the length of the positions argument. frame_name (str): Name of the end effector frame in the robot URDF. Returns: LulaTrajectory: Instance of the omni.isaac.motion_generation.Trajectory class. If no trajectory could be generated, None is returned. """ if positions.shape[0] != orientations.shape[0]: carb.log_error( "Provided positions must have the same number of rows as provided orientations: one for each point in the task_space." ) return None path_spec = lula.create_task_space_path_spec(get_pose3(positions[0], rot_quat=orientations[0])) for i in range(1, len(positions)): path_spec.add_linear_path(get_pose3(positions[i], rot_quat=orientations[i])) return self.compute_task_space_trajectory_from_path_spec(path_spec, frame_name) def compute_task_space_trajectory_from_path_spec( self, task_space_path_spec: lula.TaskSpacePathSpec, frame_name: str ) -> LulaTrajectory: """Return a LulaTrajectory that follows the path specified by the provided TaskSpacePathSpec Args: task_space_path_spec (lula.TaskSpacePathSpec): An object describing a taskspace path frame_name (str): Name of the end effector frame Returns: LulaTrajectory: Instance of the omni.isaac.motion_generation.Trajectory class. If no trajectory could be generated, None is returned. """ c_space_path = lula.convert_task_space_path_spec_to_c_space( task_space_path_spec, self._lula_kinematics, frame_name, self._path_conversion_config ) if c_space_path is None: return None trajectory = self._c_space_trajectory_generator.generate_trajectory(c_space_path.waypoints()) return LulaTrajectory(trajectory, self.get_active_joints()) def get_path_conversion_config(self) -> lula.TaskSpacePathConversionConfig: """Get a reference to the config object that lula uses to convert task-space paths to c-space paths. The values of the returned TaskSpacePathConversionConfig object can be modified directly to affect lula task-space path conversions. See help(lula.TaskSpacePathConversionConfig) for a detailed description of the editable parameters. Returns: lula.TaskSpacePathConversionConfig: Configuration class for converting from task-space paths to c-space paths. """ return self._path_conversion_config
20,057
Python
49.523929
171
0.672184
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/__init__.py
from .motion_policies import RmpFlow from .kinematics import LulaKinematicsSolver from .trajectory_generator import LulaCSpaceTrajectoryGenerator, LulaTaskSpaceTrajectoryGenerator, LulaTrajectory from .path_planners import RRT
227
Python
44.599991
113
0.881057
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/path_planners.py
# # Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np import carb from typing import List, Union import lula from ..path_planning_interface import PathPlanner from .interface_helper import LulaInterfaceHelper from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices from omni.isaac.core import objects class RRT(LulaInterfaceHelper, PathPlanner): """RRT is a stochastic algorithm for quickly finding a feasible path in cspace to move a robot from a starting pose to a target pose. This class implements the PathPlanner interface, as well as exposing RRT-specific parameters. Args: robot_description_path (str): path to a robot description yaml file urdf_path (str): path to robot urdf rrt_config_path (str): path to an rrt parameter yaml file end_effector_frame_name (str): name of the robot end effector frame (must be present in the robot urdf) """ def __init__(self, robot_description_path: str, urdf_path: str, rrt_config_path: str, end_effector_frame_name: str): robot_description = lula.load_robot(robot_description_path, urdf_path) self.end_effector_frame_name = end_effector_frame_name LulaInterfaceHelper.__init__(self, robot_description) world_view = self._world.add_world_view() self.rrt_config_path = rrt_config_path self._rrt = lula.create_motion_planner(self.rrt_config_path, self._robot_description, world_view) self._rrt.set_param("task_space_frame_name", self.end_effector_frame_name) self._seed = 123456 self._plan = None self._cspace_target = None self._taskspace_target_position = None self._taskspace_target_rotation = None def compute_path(self, active_joint_positions, watched_joint_positions) -> np.array: __doc__ = PathPlanner.compute_path.__doc__ active_joint_positions = active_joint_positions.astype(np.float64) if self._taskspace_target_position is None and self._cspace_target is not None: self._generate_plan_to_cspace_target(active_joint_positions) elif self._taskspace_target_position is None: self._plan = None else: self._generate_plan_to_taskspace_target(active_joint_positions) return self._plan def set_robot_base_pose(self, robot_position: np.array, robot_orientation: np.array) -> None: __doc__ = LulaInterfaceHelper.set_robot_base_pose.__doc__ return LulaInterfaceHelper.set_robot_base_pose(self, robot_position, robot_orientation) def set_cspace_target(self, active_joint_targets: np.array) -> None: __doc__ = PathPlanner.set_cspace_target.__doc__ self._cspace_target = active_joint_targets self._taskspace_target_position = None self._taskspace_target_rotation = None def set_end_effector_target(self, target_translation, target_orientation=None) -> None: __doc__ = PathPlanner.set_end_effector_target.__doc__ if target_translation is not None: self._taskspace_target_position = (target_translation * self._meters_per_unit).astype(np.float64) else: self._taskspace_target_position = None if target_orientation is not None: target_rotation = quats_to_rot_matrices(target_orientation) else: target_rotation = None self._taskspace_target_rotation = target_rotation self._cspace_target = None if self._taskspace_target_rotation is not None: carb.log_warn( "Lula's RRT implementation does not currently support orientation targets. The generated plan will ignore the orientation target" ) def get_active_joints(self) -> List: __doc__ = PathPlanner.get_active_joints.__doc__ return LulaInterfaceHelper.get_active_joints(self) def get_watched_joints(self) -> List: return LulaInterfaceHelper.get_watched_joints(self) def add_obstacle(self, obstacle: objects, static: bool = False) -> bool: __doc__ = PathPlanner.add_obstacle.__doc__ return PathPlanner.add_obstacle(self, obstacle, static) def add_cuboid( self, cuboid: Union[objects.cuboid.DynamicCuboid, objects.cuboid.FixedCuboid, objects.cuboid.VisualCuboid], static: bool = False, ) -> bool: return LulaInterfaceHelper.add_cuboid(self, cuboid, static) def add_sphere( self, sphere: Union[objects.sphere.DynamicSphere, objects.sphere.VisualSphere], static: bool = False ) -> bool: return LulaInterfaceHelper.add_sphere(self, sphere, static) def add_capsule( self, capsule: Union[objects.capsule.DynamicCapsule, objects.capsule.VisualCapsule], static: bool = False ) -> bool: return LulaInterfaceHelper.add_capsule(self, capsule, static) def add_ground_plane(self, ground_plane: objects.ground_plane.GroundPlane) -> bool: return LulaInterfaceHelper.add_ground_plane(self, ground_plane) def disable_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.disable_obstacle(self, obstacle) def enable_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.enable_obstacle(self, obstacle) def remove_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.remove_obstacle(self, obstacle) def update_world(self, updated_obstacles: List = None) -> None: LulaInterfaceHelper.update_world(self, updated_obstacles) self._rrt.update_world_view() def reset(self) -> None: LulaInterfaceHelper.reset(self) self._rrt = lula.create_motion_planner( self.rrt_config_path, self._robot_description, self._world.add_world_view() ) self._rrt.set_param("task_space_frame_name", self.end_effector_frame_name) self._seed = 123456 def set_max_iterations(self, max_iter: int) -> None: """Set the maximum number of iterations of RRT before a failure is returned Args: max_iter (int): Maximum number of iterations of RRT before a failure is returned. The time it takes to return a failure scales quadratically with max_iter """ self._rrt.set_param("max_iterations", max_iter) def set_random_seed(self, random_seed: int) -> None: """Set the random seed that RRT uses to generate a solution Args: random_seed (int): Used to initialize random sampling. random_seed must be positive. """ self._seed = random_seed def set_param(self, param_name: str, value: Union[np.array, float, int, str]) -> bool: """Set a parameter for the RRT algorithm. The parameters and their appropriate values are enumerated below: `seed` (int): -Used to initialize random sampling. -`seed` must be positive. -This parameter may also be set through the set_random_seed() function `step_size` (float): -Step size for tree extension. -It is assumed that a straight path connecting two valid c-space configurations with separation distance <= `step_size` is a valid edge, where separation distance is defined as the L2-norm of the difference between the two configurations. -`step_size` must be positive. `max_iterations` (int) - Maximum number of iterations of tree extensions that will be attempted. - If `max_iterations` is reached without finding a valid path, the `Results` will indicate `path_found` is `false` and `path` will be an empty vector. - `max_iterations` must be positive. `distance_metric_weights` (np.array[np.float64[num_dof,]]) - When selecting a node for tree extension, the closest node is defined using a weighted, squared L2-norm: distance = (q0 - q1)^T * W * (q0 - q1) where q0 and q1 represent two configurations and W is a diagonal matrix formed from `distance_metric_weights`. - The length of the `distance_metric_weights` must be equal to the number of c-space coordinates for the robot and each weight must be positive. `task_space_frame_name` (string) - Indicate the name (from URDF) of the frame to be used for task space planning. - With current implementation, setting a `task_space_frame_name` that is not found in the kinematics will throw an exception rather than failing gracefully. `task_space_limits` (np.array[np.float64[3,2]]) - Task space limits define a bounding box used for sampling task space when planning a path to a task space target. - The specified `task_space_limits` should be a (3 x 2) matrix. Rows correspond to the xyz dimensions of the bounding box, and columns 0 and 1 correspond to the lower and upper limit repectively. - Each upper limit must be >= the corresponding lower limit. `c_space_planning_params/exploration_fraction` (float) - The c-space planner uses RRT-Connect to try to find a path to a c-space target. - RRT-Connect attempts to iteratively extend two trees (one from the initial configuration and one from the target configuration) until the two trees can be connected. The configuration to which a tree is extended can be either a random sample (i.e., exploration) or a node on the tree to which connection is desired (i.e., exploitation). The `exploration_fraction` controls the fraction of steps that are exploration steps. It is generally recommended to set `exploration_fraction` in range [0.5, 1), where 1 corresponds to a single initial exploitation step followed by only exploration steps. Values of between [0, 0.5) correspond to more exploitation than exploration and are not recommended. If a value outside range [0, 1] is provided, a warning is logged and the value is clamped to range [0, 1]. - A default value of 0.5 is recommended as a starting value for initial testing with a given system. `task_space_planning_params/x_target_zone_tolerance` (np.array[np.float64[3,]]) - A configuration has reached the task space target when task space position, x(i), is in the range x_target(i) +/- x_target_zone_tolerance(i). - It is assumed that a valid configuration within the target tolerance can be moved directly to the target configuration using Jacobian transpose control. - In general, it is recommended that the target zone bounding box have dimensions close to the `step_size`. `task_space_planning_params/x_target_final_tolerance` (float) - Once a path is found that terminates within `x_target_zone_tolerance`, a numeric solver is used to find a configuration space solution corresponding to the task space target. This solver terminates when the L2-norm of the corresponding task space position is within `x_target_final_tolerance` of the target. - Note: This solver assumes that if a c-space configuration within `x_target_zone_tolerance` is found then this c-space configuration can be extended towards the task space target using the Jacobian transpose method. If this assumption is NOT met, the returned path will not reach the task space target within the `x_target_final_tolerance` and an error is logged. - The recommended default value is 1e-5, but in general this value should be set to a positive value that is considered "good enough" precision for the specific system. `task_space_planning_params/task_space_exploitation_fraction` (float) - Fraction of iterations for which tree is extended towards target position in task space. - Must be in range [0, 1]. Additionally, the sum of `task_space_exploitation_fraction` and `task_space_exploration_fraction` must be <= 1. - A default value of 0.4 is recommended as a starting value for initial testing with a given system. `task_space_planning_params/task_space_exploration_fraction` (float) - Fraction of iterations for which tree is extended towards random position in task space. - Must be in range [0, 1]. Additionally, the sum of `task_space_exploitation_fraction` and `task_space_exploration_fraction` must be <= 1. - A default value of 0.1 is recommended as a starting value for initial testing with a given system. The remaining fraction beyond `task_space_exploitation_fraction` and `task_space_exploration_fraction` is a `c_space_exploration_fraction` that is implicitly defined as: 1 - (`task_space_exploitation_fraction` + `task_space_exploration_fraction`) In general, easier path searches will take less time with higher exploitation fraction while more difficult searches will waste time if the exploitation fraction is too high and benefit from greater combined exploration fraction. Args: param_name (str): Name of parameter value (Union[np.ndarray[np.float64],float,int,str]): value of parameter Returns: bool: True if the parameter was set successfully """ if param_name == "seed": self.set_random_seed(value) return if param_name == "task_space_limits": value = [self._rrt.Limit(row[0], row[1]) for row in value] return self._rrt.set_param(param_name, value) def _generate_plan_to_cspace_target(self, joint_positions): if self._cspace_target is None: self._plan = None return plan = self._rrt.plan_to_cspace_target(joint_positions, self._cspace_target) if plan.path_found: self._plan = np.array(plan.path) else: self._plan = None def _generate_plan_to_taskspace_target(self, joint_positions): if self._taskspace_target_position is None: self._plan = None return trans_rel, _ = LulaInterfaceHelper._get_pose_rel_robot_base(self, self._taskspace_target_position, None) self._rrt.set_param("seed", self._seed) plan = self._rrt.plan_to_task_space_target(joint_positions, trans_rel, generate_interpolated_path=False) if plan.path_found: self._plan = np.array(plan.path) else: self._plan = None
15,356
Python
47.907643
146
0.660328
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/kinematics.py
from ...motion_generation.kinematics_interface import KinematicsSolver from .interface_helper import LulaInterfaceHelper import lula import numpy as np from typing import Tuple, List, Optional from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices from omni.isaac.core.utils.stage import get_stage_units from . import utils as lula_utils class LulaKinematicsSolver(KinematicsSolver): """A Lula-based implementaion of the KinematicsSolver interface. Lula uses a URDF file describing the robot and a custom yaml file that specifies the cspace of the robot and other parameters. This class provides functions beyond the specified interface for getting and setting solver parameters. Args: robot_description_path (str): path to a robot description yaml file describing the cspace of the robot and other relevant parameters urdf_path (str): path to a URDF file describing the robot robot_description (Optional[lula.RobotDescription]): An initialized lula.RobotDescription object. Other Lula-based classes such as RmpFlow may use a lula.RobotDescription object that they have already created to initialize a LulaKinematicsSolver. When specified, the provided file paths are unused. Defaults to None. """ def __init__( self, robot_description_path: str, urdf_path: str, robot_description: Optional[lula.RobotDescription] = None ): # Other Lula classes may initialize a KinematicsSolver using a pre-existing lula robot_description if robot_description is None: self._robot_description = lula.load_robot(robot_description_path, urdf_path) else: self._robot_description = robot_description self._kinematics = self._robot_description.kinematics() self._ik_config = lula.CyclicCoordDescentIkConfig() LulaInterfaceHelper.__init__(self, self._robot_description) # for tracking robot base self._meters_per_unit = get_stage_units() self._default_orientation_tolerance = self._lula_orientation_tol_to_rad_tol( self._ik_config.orientation_tolerance ) self._default_position_tolerance = self._ik_config.position_tolerance self._default_orientation_weight = self._ik_config.orientation_weight self._default_max_iter = self._ik_config.max_iterations_per_descent self._default_descent_termination_delta = self._ik_config.descent_termination_delta self._default_cspace_seeds = [] def set_robot_base_pose(self, robot_position: np.array, robot_orientation: np.array) -> None: LulaInterfaceHelper.set_robot_base_pose(self, robot_position, robot_orientation) def get_joint_names(self) -> List[str]: return LulaInterfaceHelper.get_active_joints(self) def get_all_frame_names(self) -> List[str]: return self._kinematics.frame_names() def compute_forward_kinematics( self, frame_name: str, joint_positions: np.array, position_only: Optional[bool] = False ) -> Tuple[np.array, np.array]: """ Compute the position of a given frame in the robot relative to the USD stage global frame Args: frame_name (str): Name of robot frame on which to calculate forward kinematics joint_positions (np.array): Joint positions for the joints returned by get_joint_names() position_only (bool): Lula Kinematics ignore this flag and always computes both position and orientation Returns: Tuple[np.array,np.array]: frame_positions: (3x1) vector describing the translation of the frame relative to the USD stage origin frame_rotation: (3x3) rotation matrix describing the rotation of the frame relative to the USD stage global frame """ return LulaInterfaceHelper.get_end_effector_pose(self, joint_positions, frame_name) def compute_inverse_kinematics( self, frame_name: str, target_position: np.array, target_orientation: np.array = None, warm_start: np.array = None, position_tolerance: float = None, orientation_tolerance: float = None, ) -> Tuple[np.array, bool]: """Compute joint positions such that the specified robot frame will reach the desired translations and rotations. Lula Kinematics interpret the orientation tolerance as being the maximum rotation separating any standard axes. e.g. For a tolerance of .1: The X axes, Y axes, and Z axes of the rotation matrices may independently be as far as .1 radians apart Default values for position and orientation tolerances may be seen and changed with setter and getter functions. Args: frame_name (str): name of the target frame for inverse kinematics target_position (np.array): target translation of the target frame (in stage units) relative to the USD stage origin target_orientation (np.array): target orientation of the target frame relative to the USD stage global frame. Defaults to None. warm_start (np.array): a starting position that will be used when solving the IK problem. If default cspace seeds have been set, the warm start will be given priority, but the default seeds will still be used. Defaults to None. position_tolerance (float): l-2 norm of acceptable position error (in stage units) between the target and achieved translations. Defaults to None. orientation tolerance (float): magnitude of rotation (in radians) separating the target orientation from the achieved orienatation. orientation_tolerance is well defined for values between 0 and pi. Defaults to None. Returns: Tuple[np.array,bool]: joint_positions: in the order specified by get_joint_names() which result in the target frame acheiving the desired position success: True if the solver converged to a solution within the given tolerances """ if position_tolerance is None: self._ik_config.position_tolerance = self._default_position_tolerance else: self._ik_config.position_tolerance = position_tolerance * self._meters_per_unit if orientation_tolerance is None: self._ik_config.orientation_tolerance = self._rad_tol_to_lula_orientation_tol( self._default_orientation_tolerance ) else: self._ik_config.orientation_tolerance = self._rad_tol_to_lula_orientation_tol(orientation_tolerance) if target_orientation is None: target_orientation = np.array([1, 0, 0, 0]) self._ik_config.orientation_tolerance = 2.0 self._ik_config.orientation_weight = 0.0 else: self._ik_config.orientation_weight = self._default_orientation_weight rot = quats_to_rot_matrices(target_orientation).astype(np.float64) pos = target_position.astype(np.float64) * self._meters_per_unit pos, rot = LulaInterfaceHelper._get_pose_rel_robot_base(self, pos, rot) target_pose = lula_utils.get_pose3(pos, rot) if warm_start is not None: seeds = [warm_start] seeds.extend(self._default_cspace_seeds) self._ik_config.cspace_seeds = seeds else: self._ik_config.cspace_seeds = self._default_cspace_seeds results = lula.compute_ik_ccd(self._kinematics, target_pose, frame_name, self._ik_config) return results.cspace_position, results.success def supports_collision_avoidance(self) -> bool: """Lula Inverse Kinematics do not support collision avoidance with USD obstacles Returns: bool: Always False """ return False def set_orientation_weight(self, weight: float) -> None: """Orientation weight describes a ratio of importance betwee hitting the position and orientation target. A weight of 0 implies that the solver cares only about the orientation target. When no orientation target is given to compute_inverse_kinematics(), a weight of 0 is automatically used over the default. Args: weight (float): Ratio describing the relative importance of the orientation target vs. the position target when solving IK """ self._default_orientation_weight = weight def set_default_orientation_tolerance(self, tolerance: float) -> None: """Default orientation tolerance to be used when calculating IK when none is specified Args: tolerance (float): magnitude of rotation (in radians) separating the target orientation from the achieved orienatation. orientation_tolerance is well defined for values between 0 and pi. """ self._default_orientation_tolerance = tolerance def set_default_position_tolerance(self, tolerance: float) -> None: """Default position tolerance to be used when calculating IK when none is specified Args: tolerance (float): l-2 norm of acceptable position error (in stage units) between the target and achieved translations """ self._default_position_tolerance = tolerance * self._meters_per_unit def set_max_iterations(self, max_iterations: int) -> None: """Set the maximum number of iterations that the IK solver will attempt before giving up Args: max_iterations (int): maximum number of iterations that the IK solver will attempt before giving up """ self._ik_config.max_iterations_per_descent = max_iterations def set_descent_termination_delta(self, delta: float) -> None: """Set the minimum delta between two solutions at which the IK solver may terminate due to the solution not improving anymore Args: delta (float): minimum delta between two solutions at which the IK solver may terminate due to the solution not improving anymore """ self._ik_config.descent_termination_delta def set_default_cspace_seeds(self, seeds: np.array) -> None: """Set a list of cspace seeds that the solver may use as starting points for solutions Args: seeds (np.array): An N x num_dof list of cspace seeds """ self._default_cspace_seeds = seeds def get_orientation_weight(self) -> float: """Orientation weight describes a ratio of importance betwee hitting the position and orientation target. A weight of 0 implies that the solver cares only about the orientation target. When no orientation target is given to compute_inverse_kinematics(), a weight of 0 is automatically used over the default. Returns: float: Ratio describing the relative importance of the orientation target vs. the position target when solving IK """ return self._default_orientation_weight def get_default_orientation_tolerance(self) -> float: """Get the default orientation tolerance to be used when calculating IK when none is specified Returns: float: magnitude of rotation (in radians) separating the target orientation from the achieved orienatation. orientation_tolerance is well defined for values between 0 and pi. """ return self._default_orientation_tolerance def get_default_position_tolerance(self) -> float: """Get the default position tolerance to be used when calculating IK when none is specified Returns: float: l-2 norm of acceptable position error (in stage units) between the target and achieved translations """ return self._default_position_tolerance / self._meters_per_unit def get_max_iterations(self) -> int: """Get the maximum number of iterations that the IK solver will attempt before giving up Returns: int: maximum number of iterations that the IK solver will attempt before giving up """ return self._ik_config.max_iterations_per_descent def get_descent_termination_delta(self) -> float: """Get the minimum delta between two solutions at which the IK solver may terminate due to the solution not improving anymore Returns: float: minimum delta between two solutions at which the IK solver may terminate due to the solution not improving anymore """ return self._ik_config.descent_termination_delta def get_default_cspace_seeds(self) -> List[np.array]: """Get a list of cspace seeds that the solver may use as starting points for solutions Returns: List[np.array]: An N x num_dof list of cspace seeds """ return self._default_cspace_seeds def get_cspace_position_limits(self) -> Tuple[np.array, np.array]: """Get the default upper and lower joint limits of the active joints. Returns: Tuple[np.array, np.array]: default_lower_joint_position_limits : Default lower position limits of active joints default_upper_joint_position_limits : Default upper position limits of active joints """ num_coords = self._kinematics.num_c_space_coords() lower = [] upper = [] for i in range(num_coords): limits = self._kinematics.c_space_coord_limits(i) lower.append(limits.lower) upper.append(limits.upper) c_space_position_upper_limits = np.array(upper, dtype=np.float64) c_space_position_lower_limits = np.array(lower, dtype=np.float64) return c_space_position_lower_limits, c_space_position_upper_limits def get_cspace_velocity_limits(self) -> np.array: """Get the default velocity limits of the active joints Returns: np.array: Default velocity limits of the active joints """ num_coords = self._kinematics.num_c_space_coords() c_space_velocity_limits = np.array( [self._kinematics.c_space_coord_velocity_limit(i) for i in range(num_coords)], dtype=np.float64 ) return c_space_velocity_limits def get_cspace_acceleration_limits(self) -> np.array: """Get the default acceleration limits of the active joints. Default acceleration limits are read from the robot_description YAML file. Returns: np.array: Default acceleration limits of the active joints """ num_coords = self._kinematics.num_c_space_coords() if self._kinematics.has_c_space_acceleration_limits(): c_space_acceleration_limits = np.array( [self._kinematics.c_space_coord_acceleration_limit(i) for i in range(num_coords)], dtype=np.float64 ) else: c_space_acceleration_limits = None return c_space_acceleration_limits def get_cspace_jerk_limits(self) -> np.array: """Get the default jerk limits of the active joints. Default jerk limits are read from the robot_description YAML file. Returns: np.array: Default jerk limits of the active joints. """ num_coords = self._kinematics.num_c_space_coords() if self._kinematics.has_c_space_jerk_limits(): c_space_jerk_limits = np.array( [self._kinematics.c_space_coord_jerk_limit(i) for i in range(num_coords)], dtype=np.float64 ) else: c_space_jerk_limits = None return c_space_jerk_limits def _lula_orientation_tol_to_rad_tol(self, tol): # convert from lula IK orientation tolerance to radian magnitude tolerance # This function is the inverse of _rad_tol_to_lula_orientation_tol return np.arccos(1 - tol ** 2 / 2) def _rad_tol_to_lula_orientation_tol(self, tol): # convert from radian magnitude tolerance to lula IK orientation tolerance # Orientation tolerance in Lula is defined as the maximum l2-norm between rotation matrix columns paired by index. # e.g. rotating pi rad about the z axis maps to a norm of 2.0 when comparing the x columns return np.linalg.norm(np.subtract([1, 0], [np.cos(tol), np.sin(tol)]))
16,298
Python
45.971181
164
0.675359
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/utils.py
import lula from omni.isaac.core.prims.xform_prim import XFormPrim from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices def get_prim_pose_in_meters(prim: XFormPrim, meters_per_unit: float): pos, quat_rot = prim.get_world_pose() rot = quats_to_rot_matrices(quat_rot) pos *= meters_per_unit return pos, rot def get_prim_pose_in_meters_rel_robot_base(prim, meters_per_unit, robot_pos, robot_rot): # returns the position of a prim relative to the position of the robot trans, rot = get_prim_pose_in_meters(prim, meters_per_unit) return get_pose_rel_robot_base(trans, rot, robot_pos, robot_rot) def get_pose_rel_robot_base(trans, rot, robot_pos, robot_rot): inv_rob_rot = robot_rot.T if trans is not None: trans_rel = inv_rob_rot @ (trans - robot_pos) else: trans_rel = None if rot is not None: rot_rel = inv_rob_rot @ rot else: rot_rel = None return trans_rel, rot_rel def get_pose3(trans=None, rot_mat=None, rot_quat=None) -> lula.Pose3: """ Get lula.Pose3 type representing a transformation. rot_mat will take precedence over rot_quat if both are supplied """ if trans is None and rot_mat is None and rot_quat is None: return lula.Pose3() if trans is None: if rot_mat is not None: return lula.Pose3.from_rotation(lula.Rotation3(rot_mat)) else: return lula.Pose3.from_rotation(lula.Rotation3(*rot_quat)) if rot_mat is None and rot_quat is None: return lula.Pose3.from_translation(trans) if rot_mat is not None: return lula.Pose3(lula.Rotation3(rot_mat), trans) else: return lula.Pose3(lula.Rotation3(*rot_quat), trans)
1,742
Python
29.578947
88
0.663031
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/world.py
import lula import carb import numpy as np from typing import List, Union, Optional from omni.isaac.motion_generation.world_interface import WorldInterface from omni.isaac.core import objects from omni.isaac.core.utils.string import find_unique_string_name from omni.isaac.core.utils.prims import is_prim_path_valid, delete_prim from omni.isaac.core.utils.stage import get_stage_units from .utils import get_prim_pose_in_meters_rel_robot_base, get_pose3 class LulaWorld(WorldInterface): def __init__(self): self._world = lula.create_world() self._dynamic_obstacles = dict() self._static_obstacles = dict() self._meters_per_unit = get_stage_units() # maintain a map of core.objects.ground_plane to ground-like cuboids that lula made to support the ground plane add function self._ground_plane_map = dict() def update_world( self, updated_obstacles: Optional[List] = None, robot_pos: Optional[np.array] = np.zeros(3), robot_rot: Optional[np.array] = np.eye(3), robot_base_moved: bool = False, ) -> None: """Update the internal world state of Lula. This function automatically tracks the positions of obstacles that have been added with add_obstacle() Args: updated_obstacles (List[core.objects], optional): Obstacles that have been added by add_obstacle() that need to be updated. If not specified, all non-static obstacle positions will be updated. If specified, only the obstacles that have been listed will have their positions updated """ if updated_obstacles is None or robot_base_moved: # assume that all obstacle poses need to be updated updated_obstacles = self._dynamic_obstacles.keys() for obstacle_prim in updated_obstacles: obstacle_handle = self._dynamic_obstacles[obstacle_prim] trans, rot = get_prim_pose_in_meters_rel_robot_base( obstacle_prim, self._meters_per_unit, robot_pos, robot_rot ) pose = get_pose3(trans, rot) self._world.set_pose(obstacle_handle, pose) if robot_base_moved: # update static obstacles for (obstacle_prim, obstacle_handle) in self._static_obstacles.items(): trans, rot = get_prim_pose_in_meters_rel_robot_base( obstacle_prim, self._meters_per_unit, robot_pos, robot_rot ) pose = get_pose3(trans, rot) self._world.set_pose(obstacle_handle, pose) def add_cuboid( self, cuboid: Union[objects.cuboid.DynamicCuboid, objects.cuboid.FixedCuboid, objects.cuboid.VisualCuboid], static: Optional[bool] = False, robot_pos: Optional[np.array] = np.zeros(3), robot_rot: Optional[np.array] = np.eye(3), ): """Add a block obstacle. Args: cuboid (core.objects.cuboid): Wrapper object for handling rectangular prism Usd Prims. static (bool, optional): If True, indicate that cuboid will never change pose, and may be ignored in internal world updates. Since Lula specifies object positions relative to the robot's frame of reference, static obstacles will have their positions queried any time that set_robot_base_pose() is called. Defaults to False. Returns: bool: Always True, indicating that this adder has been implemented """ if cuboid in self._static_obstacles or cuboid in self._dynamic_obstacles: carb.log_warn( "A cuboid was added twice to a Lula based MotionPolicy. This has no effect beyond adding the cuboid once." ) return False side_lengths = cuboid.get_size() * cuboid.get_local_scale() * self._meters_per_unit trans, rot = get_prim_pose_in_meters_rel_robot_base(cuboid, self._meters_per_unit, robot_pos, robot_rot) lula_cuboid = lula.create_obstacle(lula.Obstacle.Type.CUBE) lula_cuboid.set_attribute(lula.Obstacle.Attribute.SIDE_LENGTHS, side_lengths.astype(np.float64)) lula_cuboid_pose = get_pose3(trans, rot) world_view = self._world.add_world_view() lula_cuboid_handle = self._world.add_obstacle(lula_cuboid, lula_cuboid_pose) world_view.update() if static: self._static_obstacles[cuboid] = lula_cuboid_handle else: self._dynamic_obstacles[cuboid] = lula_cuboid_handle return True def add_sphere( self, sphere: Union[objects.sphere.DynamicSphere, objects.sphere.VisualSphere], static: bool = False, robot_pos: Optional[np.array] = np.zeros(3), robot_rot: Optional[np.array] = np.eye(3), ) -> bool: """Add a sphere obstacle. Args: sphere (core.objects.sphere): Wrapper object for handling sphere Usd Prims. static (bool, optional): If True, indicate that sphere will never change pose, and may be ignored in internal world updates. Since Lula specifies object positions relative to the robot's frame of reference, static obstacles will have their positions queried any time that set_robot_base_pose() is called. Defaults to False. Returns: bool: Always True, indicating that this adder has been implemented """ if sphere in self._static_obstacles or sphere in self._dynamic_obstacles: carb.log_warn( "A sphere was added twice to a Lula based MotionPolicy. This has no effect beyond adding the sphere once." ) return False radius = sphere.get_radius() * self._meters_per_unit trans, rot = get_prim_pose_in_meters_rel_robot_base(sphere, self._meters_per_unit, robot_pos, robot_rot) lula_sphere = lula.create_obstacle(lula.Obstacle.Type.SPHERE) lula_sphere.set_attribute(lula.Obstacle.Attribute.RADIUS, radius) lula_sphere_pose = get_pose3(trans, rot) lula_sphere_handle = self._world.add_obstacle(lula_sphere, lula_sphere_pose) if static: self._static_obstacles[sphere] = lula_sphere_handle else: self._dynamic_obstacles[sphere] = lula_sphere_handle return True def add_capsule( self, capsule: Union[objects.capsule.DynamicCapsule, objects.capsule.VisualCapsule], static: bool = False, robot_pos: Optional[np.array] = np.zeros(3), robot_rot: Optional[np.array] = np.eye(3), ) -> bool: """Add a capsule obstacle. Args: capsule (core.objects.capsule): Wrapper object for handling capsule Usd Prims. static (bool, optional): If True, indicate that capsule will never change pose, and may be ignored in internal world updates. Since Lula specifies object positions relative to the robot's frame of reference, static obstacles will have their positions queried any time that set_robot_base_pose() is called. Defaults to False. Returns: bool: Always True, indicating that this function has been implemented """ # As of Lula 0.5.0, what Lula calls a "cylinder" is actually a capsule (i.e., the surface # defined by the set of all points a fixed distance from a line segment). This will be # corrected in a future release of Lula. if capsule in self._static_obstacles or capsule in self._dynamic_obstacles: carb.log_warn( "A capsule was added twice to a Lula based MotionPolicy. This has no effect beyond adding the capsule once." ) return False radius = capsule.get_radius() * self._meters_per_unit height = capsule.get_height() * self._meters_per_unit trans, rot = get_prim_pose_in_meters_rel_robot_base(capsule, self._meters_per_unit, robot_pos, robot_rot) lula_capsule = lula.create_obstacle(lula.Obstacle.Type.CYLINDER) lula_capsule.set_attribute(lula.Obstacle.Attribute.RADIUS, radius) lula_capsule.set_attribute(lula.Obstacle.Attribute.HEIGHT, height) lula_capsule_pose = get_pose3(trans, rot) lula_capsule_handle = self._world.add_obstacle(lula_capsule, lula_capsule_pose) if static: self._static_obstacles[capsule] = lula_capsule_handle else: self._dynamic_obstacles[capsule] = lula_capsule_handle return True def add_ground_plane( self, ground_plane: objects.ground_plane.GroundPlane, plane_width: Optional[float] = 50.0 ) -> bool: """Add a ground_plane. Lula does not support ground planes directly, and instead internally creates a cuboid with an expansive face (dimensions 200x200 stage units) coplanar to the ground_plane. Args: ground_plane (core.objects.ground_plane.GroundPlane): Wrapper object for handling ground_plane Usd Prims. plane_width (Optional[float]): The width of the ground plane (in meters) that Lula creates to constrain this robot. Defaults to 50.0 m Returns: bool: Always True, indicating that this adder has been implemented """ if ground_plane in self._ground_plane_map: carb.log_warn( "A ground plane was added twice to a Lula based MotionPolicy. This has no effect beyond adding the ground plane once." ) return False plane_width = plane_width / self._meters_per_unit # ignore the ground plane and make a block instead, as lula doesn't support ground planes prim_path = find_unique_string_name("/lula/ground_plane", lambda x: not is_prim_path_valid(x)) ground_width = 0.001 # meters lula_ground_plane_cuboid = objects.cuboid.VisualCuboid( prim_path, size=1.0, scale=np.array([plane_width, plane_width, ground_width / self._meters_per_unit]) ) lula_ground_plane_translation = ground_plane.get_world_pose()[0] - ( np.array([0, 0, ground_width / 2]) / self._meters_per_unit ) lula_ground_plane_cuboid.set_world_pose(lula_ground_plane_translation) lula_ground_plane_cuboid.set_visibility(False) self._ground_plane_map[ground_plane] = lula_ground_plane_cuboid self.add_cuboid(lula_ground_plane_cuboid, static=True) return True def disable_obstacle(self, obstacle: objects) -> bool: """Disable collision avoidance for obstacle. Args: obstacle (core.objects): obstacle to be disabled. Returns: bool: Return True if obstacle was identified and successfully disabled. """ if obstacle in self._dynamic_obstacles: obstacle_handle = self._dynamic_obstacles[obstacle] elif obstacle in self._static_obstacles: obstacle_handle = self._static_obstacles[obstacle] elif obstacle in self._ground_plane_map: obstacle_handle = self._static_obstacles[self._ground_plane_map[obstacle]] else: return False self._world.disable_obstacle(obstacle_handle) return True def enable_obstacle(self, obstacle: objects) -> bool: """Enable collision avoidance for obstacle. Args: obstacle (core.objects): obstacle to be enabled. Returns: bool: Return True if obstacle was identified and successfully enabled. """ if obstacle in self._dynamic_obstacles: obstacle_handle = self._dynamic_obstacles[obstacle] elif obstacle in self._static_obstacles: obstacle_handle = self._static_obstacles[obstacle] elif obstacle in self._ground_plane_map: obstacle_handle = self._static_obstacles[self._ground_plane_map[obstacle]] else: return False self._world.enable_obstacle(obstacle_handle) return True def remove_obstacle(self, obstacle: objects) -> bool: """Remove obstacle from collision avoidance. Obstacle cannot be re-enabled via enable_obstacle() after removal. Args: obstacle (core.objects): obstacle to be removed. Returns: bool: Return True if obstacle was identified and successfully removed. """ if obstacle in self._dynamic_obstacles: obstacle_handle = self._dynamic_obstacles[obstacle] del self._dynamic_obstacles[obstacle] elif obstacle in self._static_obstacles: obstacle_handle = self._static_obstacles[obstacle] del self._static_obstacles[obstacle] elif obstacle in self._ground_plane_map: lula_ground_plane_cuboid = self._ground_plane_map[obstacle] obstacle_handle = self._static_obstacles[lula_ground_plane_cuboid] delete_prim(lula_ground_plane_cuboid.prim_path) del self._static_obstacles[lula_ground_plane_cuboid] del self._ground_plane_map[obstacle] else: return False self._world.remove_obstacle(obstacle_handle) return True def reset(self) -> None: """reset the world to its initial state """ self._world = lula.create_world() self._dynamic_obstacles = dict() self._static_obstacles = dict() for lula_ground_plane_cuboid in self._ground_plane_map.values(): delete_prim(lula_ground_plane_cuboid.prim_path) self._ground_plane_map = dict()
13,702
Python
42.640127
147
0.638593
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/lula/motion_policies.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import numpy as np import time from typing import Tuple, List, Union import lula import carb from ..motion_policy_interface import MotionPolicy from .interface_helper import LulaInterfaceHelper from .kinematics import LulaKinematicsSolver from omni.isaac.core.utils.string import find_unique_string_name from omni.isaac.core.utils.prims import is_prim_path_valid, delete_prim from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices, rot_matrices_to_quats from omni.isaac.core.utils.math import normalized from omni.isaac.core import objects from pxr import Sdf class RmpFlow(LulaInterfaceHelper, MotionPolicy): """ RMPflow is a real-time, reactive motion policy that smoothly guides a robot to task space targets while avoiding dynamic obstacles. This class implements the MotionPolicy interface, as well as providing a number of RmpFlow-specific functions such as visualizing the believed robot position and changing internal settings. Args: robot_description_path (str): Path to a robot description yaml file urdf_path (str): Path to robot urdf rmpflow_config_path (str): Path to an rmpflow parameter yaml file end_effector_frame_name (str): Name of the robot end effector frame (must be present in the robot urdf) maximum_substep_size (float): Maximum substep size [sec] that RmpFlow will use when internally integrating between steps of a simulation. For stability and performance, RmpFlow rolls out the robot actions at a higher framerate than Isaac Sim. For example, while Isaac Sim may be running at 60 Hz, RmpFlow can be set to take internal steps that are no larger than 1/300 seconds. In this case, RmpFlow will perform 5 sub-steps every time it returns an action to the 60 Hz simulation. In general, the maximum_substep_size argument should be at most 1/200. Choosing a very small maximum_substep_size such as 1/1000 is unnecessary, as the resulting actions will not significantly differ from a choice of 1/500, but it will internally require twice the steps to compute. ignore_robot_state_updates (bool): Defaults to False. If False: RmpFlow will set the internal robot state to match the arguments to compute_joint_targets(). When paired with ArticulationMotionPolicy, this means that RMPflow uses the simulated robot's state at every frame. If True: RmpFlow will roll out the robot state internally after it is initially specified in the first call to compute_joint_targets(). """ def __init__( self, robot_description_path: str, urdf_path: str, rmpflow_config_path: str, end_effector_frame_name: str, maximum_substep_size: float, ignore_robot_state_updates=False, ) -> None: self.maximum_substep_size = maximum_substep_size if maximum_substep_size <= 0: carb.log_error("maximum_substep_size argument must be positive.") self.ignore_robot_state_updates = ignore_robot_state_updates self.end_effector_frame_name = end_effector_frame_name MotionPolicy.__init__(self) robot_description = lula.load_robot(robot_description_path, urdf_path) LulaInterfaceHelper.__init__(self, robot_description) self._rmpflow_config_path = rmpflow_config_path # Create RMPflow configuration. rmpflow_config = lula.create_rmpflow_config( rmpflow_config_path, self._robot_description, self.end_effector_frame_name, self._world.add_world_view() ) # Create RMPflow policy. self._policy = lula.create_rmpflow(rmpflow_config) self._robot_joint_positions = None self._robot_joint_velocities = None self._end_effector_position_target = None self._end_effector_rotation_target = None self._collision_spheres = [] self._ee_visual = None def set_ignore_state_updates(self, ignore_robot_state_updates) -> None: """An RmpFlow specific method; set an internal flag in RmpFlow: ignore_robot_state_updates Args: ignore_robot_state_updates (bool): If False: RmpFlow will set the internal robot state to match the arguments to compute_joint_targets(). When paired with ArticulationMotionPolicy, this means that RMPflow uses the simulated robot's state at every frame. If True: RmpFlow will roll out the robot state internally after it is initially specified in the first call to compute_joint_targets(). The caller may override this flag and directly change the internal robot state with RmpFlow.set_internal_robot_joint_states(). """ self.ignore_robot_state_updates = ignore_robot_state_updates def set_cspace_target(self, active_joint_targets) -> None: """Set a cspace target for RmpFlow. RmpFlow always has a cspace target, and setting a new cspace target does not override a position target. RmpFlow uses the cspace target to help resolve null space behavior when a position target can be acheived in a variety of ways. If the end effector target is explicitly set to None, RmpFlow will move the robot to the cspace target Args: active_joint_targets (np.array): cspace position target for active joints in the robot """ self._policy.set_cspace_attractor(active_joint_targets.astype(np.float64)) def update_world(self, updated_obstacles: List = None) -> None: LulaInterfaceHelper.update_world(self, updated_obstacles) self._policy.update_world_view() def compute_joint_targets( self, active_joint_positions: np.array, active_joint_velocities: np.array, watched_joint_positions: np.array, watched_joint_velocities: np.array, frame_duration: float, ) -> Tuple[np.array, np.array]: """Compute robot joint targets for the next frame based on the current robot position. RmpFlow will ignore active joint positions and velocities if it has been set to ignore_robot_state_updates RmpFlow does not currently support watching joints that it is not actively controlling. Args: active_joint_positions (np.array): current positions of joints specified by get_active_joints() active_joint_velocities (np.array): current velocities of joints specified by get_active_joints() watched_joint_positions (np.array): current positions of joints specified by get_watched_joints() This will always be empty for RmpFlow. watched_joint_velocities (np.array): current velocities of joints specified by get_watched_joints() This will always be empty for RmpFlow. frame_duration (float): duration of the physics frame Returns: Tuple[np.array,np.array]: active_joint_position_targets : Position targets for the robot in the next frame active_joint_velocity_targets : Velocity targets for the robot in the next frame """ self._update_robot_joint_states(active_joint_positions, active_joint_velocities, frame_duration) return self._robot_joint_positions, self._robot_joint_velocities def visualize_collision_spheres(self) -> None: """An RmpFlow specific debugging method. This function creates visible sphere prims that match the locations and radii of the collision spheres that RmpFlow uses to prevent robot collisions. Once created, RmpFlow will update the sphere locations whenever its internal robot state changes. This can be used alongside RmpFlow.ignore_robot_state_updates(True) to validate RmpFlow's internal representation of the robot as well as help tune the PD gains on the simulated robot; i.e. the simulated robot should match the positions of the RmpFlow collision spheres over time. Visualizing collision spheres as prims on the stage is likely to significantly slow down the framerate of the simulation. This function should only be used for debugging purposes """ if len(self._collision_spheres) == 0: self._create_collision_sphere_prims(True) else: with Sdf.ChangeBlock(): for sphere in self._collision_spheres: sphere.set_visibility(True) def visualize_end_effector_position(self) -> None: """An RmpFlow specific debugging method. This function creates a visible cube whose translation and orientation match where RmpFlow believes the robot end effector to be. Once created, RmpFlow will update the position of the cube whenever its internal robot state changes. """ if self._ee_visual is None: self._create_ee_visual(True) else: self._ee_visual.set_visibility(True) def stop_visualizing_collision_spheres(self) -> None: """An RmpFlow specific debugging method. This function removes the collision sphere prims created by either RmpFlow.visualize_collision_spheres() or RmpFlow.get_collision_spheres_as_prims(). Rather than making the prims invisible, they are deleted from the stage to increase performance """ self.delete_collision_sphere_prims() self._collision_spheres = [] def stop_visualizing_end_effector(self) -> None: """An RmpFlow specific debugging method. This function removes the end effector prim that can be created by visualize_end_effector_position() or get_end_effector_position_as_prim() """ self.delete_end_effector_prim() def get_collision_spheres_as_prims(self) -> List: """An RmpFlow specific debugging method. This function is similar to RmpFlow.visualize_collision_spheres(). If the collision spheres have already been added to the stage as prims, they will be returned. If the collision spheres have not been added to the stage as prims, they will be created and returned. If created in this function, the spheres will be invisible until RmpFlow.visualize_collision_spheres() is called. Visualizing collision spheres on the stage is likely to significantly slow down the framerate of the simulation. This function should only be used for debugging purposes Returns: collision_spheres (List[core.objects.sphere.VisualSphere]): List of prims representing RmpFlow's internal collision spheres """ if len(self._collision_spheres) == 0: self._create_collision_sphere_prims(False) return self._collision_spheres def get_end_effector_as_prim(self) -> objects.cuboid.VisualCuboid: """An RmpFlow specific debugging method. This function is similar to RmpFlow.visualize_end_effector_position(). If the end effector has already been visualized as a prim, it will be returned. If the end effector is not being visualized, a cuboid will be created and returned. If created in this function, the end effector will be invisible until RmpFlow.visualize_end_effector_position() is called. Returns: end_effector_prim (objects.cuboid.VisualCuboid): Cuboid whose translation and orientation match RmpFlow's believed robot end effector position. """ if self._ee_visual is not None: return self._ee_visual self._create_ee_visual(False) return self._ee_visual def delete_collision_sphere_prims(self) -> None: """An RmpFlow specific debugging method. This function deletes any prims that have been created by RmpFlow to visualize its internal collision spheres """ for sphere in self._collision_spheres: delete_prim(sphere.prim_path) self._collision_spheres = [] def delete_end_effector_prim(self) -> None: """An RmpFlow specific debugging method. If RmpFlow is maintaining a prim for its believed end effector position, this function will delete the prim. """ if self._ee_visual is not None: delete_prim(self._ee_visual.prim_path) self._ee_visual = None def reset(self) -> None: """Reset RmpFlow to its initial state """ LulaInterfaceHelper.reset(self) rmpflow_config = lula.create_rmpflow_config( self._rmpflow_config_path, self._robot_description, self.end_effector_frame_name, self._world.add_world_view(), ) self._policy = lula.create_rmpflow(rmpflow_config) self._robot_joint_positions = None self._robot_joint_velocities = None self._end_effector_position_target = None self._end_effector_rotation_target = None self.configure_visualize = False self.delete_collision_sphere_prims() self.delete_end_effector_prim() self._collision_spheres = [] self._ee_visual = None def set_internal_robot_joint_states( self, active_joint_positions: np.array, active_joint_velocities: np.array, watched_joint_positions: np.array, watched_joint_velocities: np.array, ) -> None: """An RmpFlow specific method; this function overwrites the robot state regardless of the ignore_robot_state_updates flag. RmpFlow does not currently support watching joints that it is not actively controlling. Args: active_joint_positions (np.array): current positions of joints specified by get_active_joints() active_joint_velocities (np.array): current velocities of joints specified by get_active_joints() watched_joint_positions (np.array): current positions of joints specified by get_watched_joints(). This will always be empty for RmpFlow. watched_joint_velocities (np.array): current velocities of joints specified by get_watched_joints() This will always be empty for RmpFlow. """ self._robot_joint_positions = active_joint_positions self._robot_joint_velocities = active_joint_velocities self._update_visuals() return def get_internal_robot_joint_states(self) -> Tuple[np.array, np.array, np.array, np.array]: """An RmpFlow specific method; this function returns the internal robot state that is believed by RmpFlow Returns: Tuple[np.array,np.array,np.array,np.array]: active_joint_positions: believed positions of active joints active_joint_velocities: believed velocities of active joints watched_joint_positions: believed positions of watched robot joints. This will always be empty for RmpFlow. watched_joint_velocities: believed velocities of watched robot joints. This will always be empty for RmpFlow. """ return self._robot_joint_positions, self._robot_joint_velocities, np.empty(0), np.empty(0) def get_default_cspace_position_target(self): """An RmpFlow specific method; this function returns the default cspace position specified in the Lula robot_description YAML file Returns: np.array: Default cspace position target used by RMPflow when none is specified. """ return self._robot_description.default_c_space_configuration() def get_active_joints(self) -> List[str]: """Returns a list of joint names that RmpFlow is controlling. Some articulated robot joints may be ignored by some policies. E.g., the gripper of the Franka arm is not used to follow targets, and the RmpFlow config files excludes the joints in the gripper from the list of active joints. Returns: active_joints (List[str]): Names of active joints. The order of the joints in this list matches the order that the joints are expected in functions like RmpFlow.compute_joint_targets(active_joint_positions, active_joint_velocities,...) """ return LulaInterfaceHelper.get_active_joints(self) def get_watched_joints(self) -> List[str]: """Currently, RmpFlow is not capable of watching joint states that are not being directly controlled (active joints) If RmpFlow is controlling a robot arm at the end of an externally controlled body, set_robot_base_pose() can be used to make RmpFlow aware of the robot position This means that RmpFlow is not currently able to support controlling a set of DOFs in a robot that are not sequentially linked to each other or are not connected via fixed transforms to the end effector. Returns: watched_joints (List[str]): Empty list """ return [] def get_end_effector_pose(self, active_joint_positions: np.array) -> Tuple[np.array, np.array]: return LulaInterfaceHelper.get_end_effector_pose(self, active_joint_positions, self.end_effector_frame_name) def get_kinematics_solver(self) -> LulaKinematicsSolver: """Return a LulaKinematicsSolver that uses the same robot description as RmpFlow. The robot base pose of the LulaKinematicsSolver will be set to the same base pose as RmpFlow, but the two objects must then have their base poses updated separately. Returns: LulaKinematicsSolver: Kinematics solver using the same cspace as RmpFlow """ solver = LulaKinematicsSolver(None, None, robot_description=self._robot_description) solver.set_robot_base_pose(self._robot_pos / self._meters_per_unit, rot_matrices_to_quats(self._robot_rot)) return solver def set_end_effector_target(self, target_position=None, target_orientation=None) -> None: __doc__ = MotionPolicy.set_end_effector_target.__doc__ if target_orientation is not None: target_rotation = quats_to_rot_matrices(target_orientation) else: target_rotation = None if target_position is not None: self._end_effector_position_target = target_position * self._meters_per_unit else: self._end_effector_position_target = None self._end_effector_rotation_target = target_rotation self._set_end_effector_target() def set_robot_base_pose(self, robot_position: np.array, robot_orientation: np.array) -> None: LulaInterfaceHelper.set_robot_base_pose(self, robot_position, robot_orientation) self._set_end_effector_target() def add_obstacle(self, obstacle: objects, static: bool = False) -> bool: __doc__ = MotionPolicy.add_obstacle.__doc__ return MotionPolicy.add_obstacle(self, obstacle, static) def add_cuboid( self, cuboid: Union[objects.cuboid.DynamicCuboid, objects.cuboid.FixedCuboid, objects.cuboid.VisualCuboid], static: bool = False, ) -> bool: return LulaInterfaceHelper.add_cuboid(self, cuboid, static) def add_sphere( self, sphere: Union[objects.sphere.DynamicSphere, objects.sphere.VisualSphere], static: bool = False ) -> bool: return LulaInterfaceHelper.add_sphere(self, sphere, static) def add_capsule( self, capsule: Union[objects.capsule.DynamicCapsule, objects.capsule.VisualCapsule], static: bool = False ) -> bool: return LulaInterfaceHelper.add_capsule(self, capsule, static) def add_ground_plane(self, ground_plane: objects.ground_plane.GroundPlane) -> bool: return LulaInterfaceHelper.add_ground_plane(self, ground_plane) def disable_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.disable_obstacle(self, obstacle) def enable_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.enable_obstacle(self, obstacle) def remove_obstacle(self, obstacle: objects) -> bool: return LulaInterfaceHelper.remove_obstacle(self, obstacle) def _set_end_effector_target(self): target_position = self._end_effector_position_target target_rotation = self._end_effector_rotation_target if target_position is None and target_rotation is None: self._policy.clear_end_effector_position_attractor() self._policy.clear_end_effector_orientation_attractor() return trans, rot = LulaInterfaceHelper._get_pose_rel_robot_base(self, target_position, target_rotation) if trans is not None: self._policy.set_end_effector_position_attractor(trans) else: self._policy.clear_end_effector_position_attractor() if rot is not None: self._policy.set_end_effector_orientation_attractor(lula.Rotation3(rot)) else: self._policy.clear_end_effector_orientation_attractor() def _create_ee_visual(self, is_visible): if self._robot_joint_positions is None: joint_positions = np.zeros(self._robot_description.num_c_space_coords()) else: joint_positions = self._robot_joint_positions ee_pos, rot_mat = self.get_end_effector_pose(joint_positions) prim_path = find_unique_string_name("/lula/end_effector", lambda x: not is_prim_path_valid(x)) self._ee_visual = objects.cuboid.VisualCuboid(prim_path, size=0.1 / self._meters_per_unit) self._ee_visual.set_world_pose(position=ee_pos, orientation=rot_matrices_to_quats(rot_mat)) self._ee_visual.set_visibility(is_visible) def _create_collision_sphere_prims(self, is_visible): if self._robot_joint_positions is None: joint_positions = self._robot_description.default_c_space_configuration() else: joint_positions = self._robot_joint_positions.astype(np.float64) sphere_poses = self._policy.collision_sphere_positions(joint_positions) sphere_radii = self._policy.collision_sphere_radii() for i, (sphere_pose, sphere_rad) in enumerate(zip(sphere_poses, sphere_radii)): prim_path = find_unique_string_name("/lula/collision_sphere" + str(i), lambda x: not is_prim_path_valid(x)) self._collision_spheres.append( objects.sphere.VisualSphere(prim_path, radius=sphere_rad / self._meters_per_unit) ) with Sdf.ChangeBlock(): for sphere, sphere_pose in zip(self._collision_spheres, sphere_poses): sphere.set_world_pose(sphere_pose / self._meters_per_unit) sphere.set_visibility(is_visible) def _update_collision_sphere_prims(self): if len(self._collision_spheres) == 0: return joint_positions = self._robot_joint_positions.astype(np.float64) sphere_poses = self._policy.collision_sphere_positions(joint_positions) for col_sphere, new_pose in zip(self._collision_spheres, sphere_poses): col_sphere.set_world_pose(position=new_pose / self._meters_per_unit) def _update_end_effector_prim(self): if self._ee_visual is None: return ee_pos, rot_mat = self.get_end_effector_pose(self._robot_joint_positions) self._ee_visual.set_world_pose(ee_pos, rot_matrices_to_quats(rot_mat)) def _update_visuals(self): with Sdf.ChangeBlock(): self._update_collision_sphere_prims() self._update_end_effector_prim() def _update_robot_joint_states(self, joint_positions, joint_velocities, frame_duration): if ( self._robot_joint_positions is None or self._robot_joint_velocities is None or not self.ignore_robot_state_updates ): self._robot_joint_positions, self._robot_joint_velocities = self._euler_integration( joint_positions, joint_velocities, frame_duration ) else: self._robot_joint_positions, self._robot_joint_velocities = self._euler_integration( self._robot_joint_positions, self._robot_joint_velocities, frame_duration ) self._update_visuals() def _euler_integration(self, joint_positions, joint_velocities, frame_duration): num_steps = np.ceil(frame_duration / self.maximum_substep_size).astype(int) policy_timestep = frame_duration / num_steps for i in range(num_steps): joint_accel = self._evaluate_acceleration(joint_positions, joint_velocities) joint_positions += policy_timestep * joint_velocities joint_velocities += policy_timestep * joint_accel return joint_positions, joint_velocities def _evaluate_acceleration(self, joint_positions, joint_velocities): joint_positions = joint_positions.astype(np.float64) joint_velocities = joint_velocities.astype(np.float64) joint_accel = np.zeros_like(joint_positions) self._policy.eval_accel(joint_positions, joint_velocities, joint_accel) return joint_accel class RmpFlowSmoothed(RmpFlow): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) self.desired_speed_scalar = 1.0 self.speed_scalar = 1.0 self.time_at_last_jerk_reduction = None self.qdd = None # Params self.min_time_between_jerk_reductions = 0.5 self.min_speed_scalar = 0.2 self.use_big_jerk_speed_scaling = True self.big_jerk_limit = 10.0 self.use_medium_jerk_truncation = True self.max_medium_jerk = 7.0 self.speed_scalar_alpha_blend = 0.985 # Used for real world experiments. self.verbose = False def _eval_speed_scaled_accel(self, joint_positions, joint_velocities): qdd_eval = self._evaluate_acceleration(joint_positions, joint_velocities / (self.speed_scalar)) qdd_eval *= self.speed_scalar ** 2 return qdd_eval def _euler_integration(self, joint_positions, joint_velocities, frame_duration): num_steps = np.ceil(frame_duration / self.maximum_substep_size).astype(int) step_dt = frame_duration / num_steps q = joint_positions qd = joint_velocities # Jerk monitoring and reduction is intended to handle jerk in physical robots. It's # important then to use real wall-clock time when monitoring it. now = time.time() for i in range(num_steps): if self.qdd is None: self.qdd = self._eval_speed_scaled_accel(q, qd) continue jerk_reduction_performed = False # Reduces the speed down to a minimum if a big jerk is experience. if self.use_big_jerk_speed_scaling: is_first = True while True: qdd_eval = self._eval_speed_scaled_accel(q, qd) # Just go through this once. We simply want to make sure qdd_eval is evaluated # again after the reduction. if not is_first: break # Don't do jerk reductions too frequently. if ( self.time_at_last_jerk_reduction is not None and (now - self.time_at_last_jerk_reduction) < self.min_time_between_jerk_reductions ): break jerk = np.linalg.norm(qdd_eval - self.qdd) if jerk > self.big_jerk_limit: self.speed_scalar = self.min_speed_scalar if self.verbose: print("<jerk reduction> new speed scalar = %f" % self.speed_scalar) jerk_reduction_performed = True is_first = False # Truncate the jerks. This addresses transient jerks. if self.use_medium_jerk_truncation: qdd_eval = self._eval_speed_scaled_accel(q, qd) jerk = np.linalg.norm(qdd_eval - self.qdd) if jerk > self.max_medium_jerk: if self.verbose: print("<jerk truncation>") jerk_truncation_performed = True v = normalized(qdd_eval - self.qdd) qdd_eval = self.qdd + self.max_medium_jerk * v if jerk_reduction_performed: self.time_at_last_jerk_reduction = now self.qdd = qdd_eval a = self.speed_scalar_alpha_blend self.speed_scalar = a * self.speed_scalar + (1.0 - a) * self.desired_speed_scalar q += step_dt * qd qd += step_dt * self.qdd return q, qd
29,180
Python
46.681372
231
0.664599
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/tests/test_motion_policy.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import omni.kit.test import carb import asyncio from pxr import Gf # Import extension python module we are testing with absolute import path, as if we are external user (other extension) from omni.isaac.motion_generation import ArticulationMotionPolicy, interface_config_loader from omni.isaac.motion_generation.lula.motion_policies import RmpFlow from omni.isaac.core.utils import distance_metrics from omni.isaac.core.utils.stage import ( open_stage_async, update_stage_async, add_reference_to_stage, create_new_stage_async, ) from omni.isaac.core.utils.rotations import gf_quat_to_np_array, quat_to_rot_matrix from omni.isaac.core.utils.prims import is_prim_path_valid, delete_prim import omni.isaac.core.objects as objects from omni.isaac.core.prims.xform_prim import XFormPrim from omni.isaac.core.robots.robot import Robot from omni.isaac.core.utils.nucleus import get_assets_root_path from omni.isaac.core.world import World import os import json import numpy as np # Having a test class derived from omni.kit.test.AsyncTestCase declared on the root of module will # make it auto-discoverable by omni.kit.test class TestMotionPolicy(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._physics_dt = 1 / 60 # duration of physics frame in seconds self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.motion_generation") self._articulation_policy_extension_path = ext_manager.get_extension_path(ext_id) self._polciy_config_dir = os.path.join(self._articulation_policy_extension_path, "motion_policy_configs") self.assertTrue(os.path.exists(os.path.join(self._polciy_config_dir, "policy_map.json"))) with open(os.path.join(self._polciy_config_dir, "policy_map.json")) as policy_map: self._policy_map = json.load(policy_map) carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) await create_new_stage_async() await update_stage_async() pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await update_stage_async() self._articulation_policy = None await update_stage_async() World.clear_instance() pass async def _set_determinism_settings(self, robot): World() carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) robot.disable_gravity() robot.set_solver_position_iteration_count(64) robot.set_solver_velocity_iteration_count(64) async def test_rmpflow_cspace_target(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) default_target = self._motion_policy.get_default_cspace_position_target() active_joints_subset = self._articulation_policy.get_active_joints_subset() # Can reach just a cspace target for i in range(180): action = self._articulation_policy.get_next_articulation_action() self._robot.get_articulation_controller().apply_action(action) await update_stage_async() if np.allclose(default_target, active_joints_subset.get_joint_positions(), atol=0.1): break self.assertTrue( np.allclose(default_target, active_joints_subset.get_joint_positions(), atol=0.1), f"{default_target} vs {active_joints_subset.get_joint_positions()}: Could not reach default cspace target in 300 frames!", ) ee_target_position = np.array([0.5, 0, 0.5]) self._motion_policy.set_end_effector_target(ee_target_position) new_target = np.array([1.0, 0, 1.0, -0.3, 0, 0.2, 0]) self._motion_policy.set_cspace_target(new_target) # Check cspace attractor doesn't override the ee target for i in range(180): action = self._articulation_policy.get_next_articulation_action() self._robot.get_articulation_controller().apply_action(action) await update_stage_async() ee_pose = self._motion_policy.get_end_effector_pose(active_joints_subset.get_joint_positions())[0] if np.linalg.norm(ee_target_position - ee_pose) < 0.01: break ee_pose = self._motion_policy.get_end_effector_pose(active_joints_subset.get_joint_positions())[0] self.assertTrue( np.linalg.norm(ee_target_position - ee_pose) < 0.01, f"Could not reach taskspace target target in 240 frames! {np.linalg.norm(ee_target_position - ee_pose)}", ) self._motion_policy.set_end_effector_target(None) # New cspace target is still active; check that robot reaches it for i in range(250): action = self._articulation_policy.get_next_articulation_action() self._robot.get_articulation_controller().apply_action(action) await update_stage_async() if np.allclose(new_target, active_joints_subset.get_joint_positions(), atol=0.1): break self.assertTrue( np.allclose(new_target, active_joints_subset.get_joint_positions(), atol=0.1), f"Could not reach new cspace target in 250 frames! {new_target} != {active_joints_subset.get_joint_positions()}", ) self.assertTrue( np.allclose(self._motion_policy.get_default_cspace_position_target(), default_target), f"{self._motion_policy.get_default_cspace_position_target()} != {default_target}", ) async def test_rmpflow_cobotta_900(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Denso/cobotta_pro_900.usd" robot_name = "Cobotta_Pro_900" robot_prim_path = "/cobotta_pro_900" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_cobotta_1300(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Denso/cobotta_pro_1300.usd" robot_name = "Cobotta_Pro_1300" robot_prim_path = "/cobotta_pro_1300" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_ur3(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur3/ur3.usd" robot_name = "UR3" robot_prim_path = "/ur3" await self._simple_robot_rmpflow_test( usd_path, robot_prim_path, robot_name, target_pos=np.array([0.3, 0.3, 0.5]) ) async def test_rmpflow_ur3e(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur3e/ur3e.usd" robot_name = "UR3e" robot_prim_path = "/ur3e" await self._simple_robot_rmpflow_test( usd_path, robot_prim_path, robot_name, target_pos=np.array([0.3, 0.3, 0.5]) ) async def test_rmpflow_ur5(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur5/ur5.usd" robot_name = "UR5" robot_prim_path = "/ur5" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_ur5e(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur5e/ur5e.usd" robot_name = "UR5e" robot_prim_path = "/ur5e" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_ur10(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur10/ur10.usd" robot_name = "UR10" robot_prim_path = "/ur10" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_ur10e(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur10e/ur10e.usd" robot_name = "UR10e" robot_prim_path = "/ur10e" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_ur16e(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/UniversalRobots/ur16e/ur16e.usd" robot_name = "UR16e" robot_prim_path = "/ur16e" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_rizon4(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Flexiv/Rizon4/flexiv_rizon4.usd" robot_name = "Rizon4" robot_prim_path = "/A02L_MP" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_rs007l(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Kawasaki/RS007L/rs007l_onrobot_rg2.usd" robot_name = "RS007L" robot_prim_path = "/khi_rs007l" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_rs007n(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Kawasaki/RS007N/rs007n_onrobot_rg2.usd" robot_name = "RS007N" robot_prim_path = "/khi_rs007n" await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name) async def test_rmpflow_rs013n(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Kawasaki/RS013N/rs013n_onrobot_rg2.usd" robot_name = "RS013N" robot_prim_path = "/khi_rs013n" obstacle_position = np.array([0.8, 0.3, 0.8]) target_position = np.array([0.85, 0.1, 0.55]) await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name, target_position, obstacle_position) async def test_rmpflow_rs025n(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Kawasaki/RS025N/rs025n_onrobot_rg2.usd" robot_name = "RS025N" robot_prim_path = "/khi_rs025n" obstacle_position = np.array([0.8, 0.3, 0.8]) target_position = np.array([0.85, 0.1, 0.55]) await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name, target_position, obstacle_position) async def test_rmpflow_rs080n(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Kawasaki/RS080N/rs080n_onrobot_rg2.usd" robot_name = "RS080N" robot_prim_path = "/khi_rs080n" obstacle_position = np.array([0.8, 0.3, 0.8]) target_position = np.array([0.85, 0.1, 0.55]) await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name, target_position, obstacle_position) async def test_rmpflow_festo_cobot(self): assets_root_path = get_assets_root_path() usd_path = assets_root_path + "/Isaac/Robots/Festo/FestoCobot/festo_cobot.usd" robot_name = "FestoCobot" robot_prim_path = "/bettina" obstacle_position = np.array([0.8, 0.3, 0.8]) target_position = np.array([0.78, 0.1, 0.55]) await self._simple_robot_rmpflow_test(usd_path, robot_prim_path, robot_name, target_position, obstacle_position) async def _simple_robot_rmpflow_test( self, usd_path, prim_path, robot_name, target_pos=np.array([0.6, 0.3, 0.5]), obstacle_pos=np.array([0.3, 0.1, 0.5]), ): (result, error) = await open_stage_async(usd_path) rmp_config = interface_config_loader.load_supported_motion_policy_config(robot_name, "RMPflow") self._motion_policy = RmpFlow(**rmp_config) robot_prim_path = prim_path # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) timeout = 10 await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) pass async def test_rmpflow_visualization_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) self._motion_policy = rmp_flow_motion_policy robot_prim_path = "/panda" # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) self._motion_policy.set_end_effector_target(np.array([0.4, 0.2, 0.4])) self._motion_policy.visualize_collision_spheres() self._motion_policy.visualize_end_effector_position() test_sphere = self._motion_policy.get_collision_spheres_as_prims()[-1] test_ee_visual = self._motion_policy.get_end_effector_as_prim() panda_hand_prim = XFormPrim("/panda/panda_hand") self._articulation_policy.move() for _ in range(100): sphere_pos, _ = test_sphere.get_world_pose() ee_pos, _ = test_ee_visual.get_world_pose() hand_pose, _ = panda_hand_prim.get_world_pose() self.assertTrue( abs(np.linalg.norm(sphere_pos - ee_pos) - 0.09014) < 0.001, f"End effector visualization is not consistent with sphere visualization: {np.linalg.norm(sphere_pos - ee_pos)}", ) self.assertTrue( abs(np.linalg.norm(hand_pose - ee_pos) - 0.10) < 0.01, f"Simulated robot moved too far from RMP belief robot: {np.linalg.norm(hand_pose - ee_pos)}", ) self._motion_policy.update_world() self._articulation_policy.move() await update_stage_async() self._motion_policy.delete_collision_sphere_prims() self._motion_policy.delete_end_effector_prim() self.assertTrue(not is_prim_path_valid("/lula/end_effector")) self.assertTrue(not is_prim_path_valid("/lula/collision_sphere0")) self._motion_policy.set_end_effector_target(np.array([0.8, 0.2, 0.8])) test_sphere = self._motion_policy.get_collision_spheres_as_prims()[-1] test_ee_visual = self._motion_policy.get_end_effector_as_prim() # self._articulation_policy.move() await update_stage_async() for _ in range(100): sphere_pos, _ = test_sphere.get_world_pose() ee_pos, _ = test_ee_visual.get_world_pose() hand_pose, _ = panda_hand_prim.get_world_pose() self.assertTrue( abs(np.linalg.norm(sphere_pos - ee_pos) - 0.09014) < 0.001, f"End effector visualization is not consistent with sphere visualization: {np.linalg.norm(sphere_pos - ee_pos) }", ) self.assertTrue( abs(np.linalg.norm(hand_pose - ee_pos) - 0.10) < 0.01, f"Simulated robot moved too far from RMP belief robot: {np.linalg.norm(hand_pose - ee_pos)}", ) self._motion_policy.update_world() self._articulation_policy.move() await update_stage_async() self._motion_policy.reset() self.assertTrue(not is_prim_path_valid("/lula/end_effector")) self.assertTrue(not is_prim_path_valid("/lula/collision_sphere0")) async def test_rmpflow_obstacle_adders(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) # These obstacle types are supported by RmpFlow obstacles = [ objects.cuboid.VisualCuboid("/visual_cube"), objects.cuboid.DynamicCuboid("/dynamic_cube"), objects.cuboid.FixedCuboid("/fixed_cube"), objects.sphere.VisualSphere("/visual_sphere"), objects.sphere.DynamicSphere("/dynamic_sphere"), objects.capsule.VisualCapsule("/visual_capsule"), objects.capsule.DynamicCapsule("/dynamic_capsule"), objects.ground_plane.GroundPlane("/ground_plane"), ] # check that all the supported world update functions return successfully without error for obstacle in obstacles: self.assertTrue(self._motion_policy.add_obstacle(obstacle)) self.assertTrue(self._motion_policy.disable_obstacle(obstacle)) self.assertTrue(self._motion_policy.enable_obstacle(obstacle)) self.assertTrue(self._motion_policy.remove_obstacle(obstacle)) # make sure lula cleaned up after removing ground plane : Lula creates a wide, flat cuboid to mimic the ground because it doesn't support ground planes directly self.assertFalse(is_prim_path_valid("/lula/ground_plane")) for obstacle in obstacles: self.assertTrue(self._motion_policy.add_obstacle(obstacle)) for obstacle in obstacles: # obstacle already in there self.assertFalse(self._motion_policy.add_obstacle(obstacle)) self._motion_policy.reset() for obstacle in obstacles: # obstacles should have been deleted in reset self.assertFalse(self._motion_policy.disable_obstacle(obstacle)) self.assertFalse(self._motion_policy.enable_obstacle(obstacle)) self.assertFalse(self._motion_policy.remove_obstacle(obstacle)) self.assertFalse(is_prim_path_valid("/lula/ground_plane")) async def test_articulation_motion_policy_init_order(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) self._motion_policy = rmp_flow_motion_policy self._robot = Robot(robot_prim_path) # Make sure that initializing this before robot is initialized doesn't cause any issues self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) self._timeline.play() await update_stage_async() self._robot.initialize() await self.reset_robot(self._robot) action = self._articulation_policy.get_next_articulation_action() pass async def test_rmpflow_on_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) rmp_flow_motion_policy.set_ignore_state_updates(False) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) ground_truths = { "no_target": np.array( [ -0.004417035728693008, -0.2752424478530884, 0.0009353954228572547, 0.032967355102300644, 0.0001806323998607695, -0.43320316076278687, 0.004497386049479246, None, None, ] ), "target_no_obstacle": np.array( [ 0.2209184467792511, -0.27475225925445557, 0.2051529437303543, 0.014692924916744232, -0.0313996896147728, -0.43752315640449524, 0.00518844835460186, None, None, ] ), "target_with_obstacle": np.array( [ -0.016765182837843895, -0.2309315949678421, -0.2107730507850647, -0.06896218657493591, -0.15911254286766052, -0.16595730185508728, -0.004891209304332733, None, None, ] ), "target_pos": np.array([0.40, 0.20, 0.40]), "obs_pos": np.array([0.3, 0.20, 0.50]), } await self.verify_policy_outputs(self._robot, ground_truths, dbg=False) timeout = 10 await self.reset_robot(self._robot) target_pos = np.array([0.5, 0.0, 0.5]) obstacle_pos = np.array([0.5, 0.0, 0.65]) await self.verify_robot_convergence( target_pos, timeout, target_orient=np.array([0.0, 0.0, 0.0, 1.0]), obs_pos=obstacle_pos ) self._robot.set_world_pose(np.array([0.1, 0.6, 0])) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(1.0, 0.0, 0.0), -15).GetQuat()) self._robot.set_world_pose(np.array([0.1, 0, 0.1]), orientation=gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(0.1, 0.0, 1.0), 45).GetQuat()) trans = np.array([0.1, -0.5, 0.0]) self._robot.set_world_pose(trans, gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) pass async def test_rmpflow_on_franka_ignore_state(self): # Perform an internal rollout of robot state, ignoring simulated robot state updates usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) rmp_flow_motion_policy.set_ignore_state_updates(True) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) """ verify_policy_outputs() is not used here because 1: The policy would not pass because it rolls out robot state internally rather than seeing that the robot is not moving, so the outputs become inconsistent. 2: It is sufficient to confirm that the world state is updated correctly in test_rmpflow_on_franka_velocity_control(). """ await self.reset_robot(self._robot) timeout = 10 target_pos = np.array([0.5, 0.0, 0.5]) obstacle_pos = np.array([0.5, 0.0, 0.65]) await self.verify_robot_convergence( target_pos, timeout, target_orient=np.array([0.0, 0.0, 0.0, 1.0]), obs_pos=obstacle_pos ) self._robot.set_world_pose(np.array([0.1, 0.6, 0])) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(1.0, 0.0, 0.0), -15).GetQuat()) self._robot.set_world_pose(np.array([0.1, 0, 0.1]), orientation=gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(0.1, 0.0, 1.0), 45).GetQuat()) trans = np.array([0.1, -0.5, 0.0]) self._robot.set_world_pose(trans, gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) pass async def test_rmpflow_static_obstacles_franka(self): # Perform an internal rollout of robot state, ignoring simulated robot state updates usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_prim_path = "/panda" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("Franka", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) rmp_flow_motion_policy.set_ignore_state_updates(True) self._motion_policy = rmp_flow_motion_policy robot_prim_path = "/panda" # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) timeout = 10 target_pos = np.array([0.5, 0.0, 0.5]) obstacle_pos = np.array([0.5, 0.0, 0.65]) await self.verify_robot_convergence( target_pos, timeout, target_orient=np.array([0.0, 0.0, 0.0, 1.0]), obs_pos=obstacle_pos, static=True ) self._robot.set_world_pose(np.array([0.1, 0.6, 0])) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos, static=True) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(1.0, 0.0, 0.0), -15).GetQuat()) self._robot.set_world_pose(np.array([0.1, 0, 0.1]), orientation=gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos, static=True) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(0.1, 0.0, 1.0), 45).GetQuat()) trans = np.array([0.1, -0.5, 0.0]) self._robot.set_world_pose(trans, gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos, static=True) async def test_rmpflow_on_ur10(self): usd_path = get_assets_root_path() + "/Isaac/Robots/UR10/ur10.usd" robot_prim_path = "/ur10" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("UR10", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) rmp_flow_motion_policy.set_ignore_state_updates(False) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) ground_truths = { "no_target": np.array([-0.07558637, -0.035313368, -0.14294432, -0.24767338, 0.25070193, 2.879336e-10]), "target_no_obstacle": np.array( [-0.43079016, 0.18957902, 0.33274212, 0.46673688, -0.36309126, 6.501429e-10] ), "target_with_obstacle": np.array( [-0.41054526, 0.08853104, 0.3780922, 0.47682625, -0.37121844, 6.5079464e-10] ), "target_pos": np.array([0.5, 0.0, 0.0]), "obs_pos": np.array([0.50, 0.0, -0.20]), } await self.verify_policy_outputs(self._robot, ground_truths, dbg=False) await self.reset_robot(self._robot) timeout = 10 target_pos = np.array([0.5, 0.0, 0.7]) obstacle_pos = np.array([0.8, 0.1, 0.8]) await self.verify_robot_convergence( target_pos, timeout, target_orient=np.array([0.0, 0.0, 0.0, 1.0]), obs_pos=obstacle_pos ) self._robot.set_world_pose(np.array([0.1, 0.7, 0])) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(1.0, 0.0, 0.0), -15).GetQuat()) self._robot.set_world_pose(np.array([0.1, 0, 0.1]), gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(0.2, 0.0, 1.0), 90).GetQuat()) trans = np.array([0.1, -0.5, 0.0]) self._robot.set_world_pose(trans, gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) pass async def test_rmpflow_on_ur10_ignore_state(self): # Perform an internal rollout of robot state, ignoring simulated robot state updates usd_path = get_assets_root_path() + "/Isaac/Robots/UR10/ur10.usd" robot_prim_path = "/ur10" add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() rmp_flow_motion_policy_config = interface_config_loader.load_supported_motion_policy_config("UR10", "RMPflow") rmp_flow_motion_policy = RmpFlow(**rmp_flow_motion_policy_config) rmp_flow_motion_policy.set_ignore_state_updates(True) self._motion_policy = rmp_flow_motion_policy # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) self._articulation_policy = ArticulationMotionPolicy(self._robot, self._motion_policy, self._physics_dt) """ verify_policy_outputs() is not used here because 1: The policy would not pass because it rolls out robot state internally rather than seeing that the robot is not moving, so the outputs become inconsistent. 2: It is sufficient to confirm that the world state is updated correctly in test_rmpflow_on_franka_velocity_control(). """ await self.reset_robot(self._robot) timeout = 10 target_pos = np.array([0.5, 0.0, 0.7]) obstacle_pos = np.array([0.8, 0.1, 0.8]) await self.verify_robot_convergence( target_pos, timeout, target_orient=np.array([0.0, 0.0, 0.0, 1.0]), obs_pos=obstacle_pos ) self._robot.set_world_pose(np.array([0.1, 0.7, 0])) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(1.0, 0.0, 0.0), -15).GetQuat()) self._robot.set_world_pose(np.array([0.1, 0, 0.1]), gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) rot_quat = Gf.Quatf(Gf.Rotation(Gf.Vec3d(0.2, 0.0, 1.0), 90).GetQuat()) trans = np.array([0.1, -0.5, 0.0]) self._robot.set_world_pose(trans, gf_quat_to_np_array(rot_quat)) await update_stage_async() await self.verify_robot_convergence(target_pos, timeout, obs_pos=obstacle_pos) pass async def reached_end_effector_target(self, target_trans, target_orient, trans_thresh=0.02, rot_thresh=0.1): ee_trans, ee_rot = self._motion_policy.get_end_effector_pose( self._articulation_policy.get_active_joints_subset().get_joint_positions() ) # TODO this only works for RMPflow, and will be updated in upcoming MR before there are non-RMPflow tests if target_orient is not None: target_rot = quat_to_rot_matrix(target_orient) else: target_rot = None if target_rot is None and target_trans is None: return True elif target_rot is None: trans_dist = distance_metrics.weighted_translational_distance(ee_trans, target_trans) return trans_dist < trans_thresh elif target_trans is None: rot_dist = distance_metrics.rotational_distance_angle(ee_rot, target_rot) return rot_dist < rot_thresh else: trans_dist = distance_metrics.weighted_translational_distance(ee_trans, target_trans) rot_dist = distance_metrics.rotational_distance_angle(ee_rot, target_rot) return trans_dist < trans_thresh and rot_dist < rot_thresh async def add_block(self, path, offset, size=np.array([0.01, 0.01, 0.01]), collidable=True): if collidable: cuboid = objects.cuboid.FixedCuboid(path, scale=size, size=1.0) await update_stage_async() else: cuboid = objects.cuboid.VisualCuboid(path, scale=size, size=1.0) await update_stage_async() cuboid.set_world_pose(offset, np.array([1.0, 0, 0, 0])) await update_stage_async() return cuboid async def assertAlmostEqual(self, a, b, msg=""): # overriding method because it doesn't support iterables a = np.array(a) b = np.array(b) self.assertFalse(np.any(abs((a[a != np.array(None)] - b[b != np.array(None)])) > 1e-3), msg) pass async def simulate_until_target_reached(self, timeout, target_trans, target_orient=None): for frame in range(int(1 / self._physics_dt * timeout)): self._motion_policy.update_world() self._articulation_policy.move() await omni.kit.app.get_app().next_update_async() if await self.reached_end_effector_target(target_trans, target_orient=target_orient): return True, frame * self._physics_dt return False, timeout async def reset_robot(self, robot): """ To make motion_generation outputs more deterministic, this method may be used to teleport the robot to specified position targets, setting velocity to 0 This prevents changes in dynamic_control from affecting motion_generation tests """ robot.post_reset() await self._set_determinism_settings(robot) await update_stage_async() pass async def verify_policy_outputs(self, robot, ground_truths, dbg=False): """ The ground truths are obtained by running this method in dbg mode when certain that motion_generation is working as intended. If position_control is True, motion_generation is expected to be using position targets In dbg mode, the returned velocity target values will be printed and no assertions will be checked. """ # outputs of mg in different scenarios no_target_truth = ground_truths["no_target"] target_no_obs_truth = ground_truths["target_no_obstacle"] target_obs_truth = ground_truths["target_with_obstacle"] # where to put the target and obstacle target_pos = ground_truths["target_pos"] obs_pos = ground_truths["obs_pos"] target_cube = await self.add_block("/scene/target", target_pos, size=0.05 * np.ones(3), collidable=False) await update_stage_async() obs = await self.add_block("/scene/obstacle", obs_pos, size=0.1 * np.ones(3)) await update_stage_async() await self.reset_robot(robot) await update_stage_async() self._motion_policy.set_end_effector_target(None) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nNo target:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( no_target_truth, mg_velocity_targets, f"{no_target_truth} != {mg_velocity_targets}" ) # Just the target self._motion_policy.set_end_effector_target(target_pos) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nWith target:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( target_no_obs_truth, mg_velocity_targets, f"{target_no_obs_truth} != {mg_velocity_targets}" ) # Add the obstacle self._motion_policy.add_obstacle(obs) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nWith target and obstacle:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( target_obs_truth, mg_velocity_targets, f"{target_obs_truth} != {mg_velocity_targets}" ) # Disable the obstacle: check that it matches no obstacle at all self._motion_policy.disable_obstacle(obs) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nWith target and disabled obstacle:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( target_no_obs_truth, mg_velocity_targets, f"{target_no_obs_truth} != {mg_velocity_targets}" ) # Enable the obstacle: check consistency self._motion_policy.enable_obstacle(obs) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nWith target and enabled obstacle:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( target_obs_truth, mg_velocity_targets, f"{target_obs_truth} != {mg_velocity_targets}" ) # Delete the obstacle: check consistency self._motion_policy.remove_obstacle(obs) self._motion_policy.update_world() action = self._articulation_policy.get_next_articulation_action() mg_velocity_targets = action.joint_velocities if dbg: print("\nWith target and deleted obstacle:") for target in mg_velocity_targets: print(target, end=",") print() else: await self.assertAlmostEqual( target_no_obs_truth, mg_velocity_targets, f"{target_no_obs_truth} != {mg_velocity_targets}" ) delete_prim(obs.prim_path) delete_prim(target_cube.prim_path) return async def verify_robot_convergence(self, target_pos, timeout, target_orient=None, obs_pos=None, static=False): # Assert that the robot can reach the target within a given timeout target = await self.add_block("/scene/target", target_pos, size=0.05 * np.ones(3), collidable=False) self._motion_policy.set_robot_base_pose(*self._robot.get_world_pose()) await omni.kit.app.get_app().next_update_async() obs_prim = None if obs_pos is not None: cuboid = await self.add_block("/scene/obstacle", obs_pos, size=0.1 * np.array([2.0, 3.0, 1.0])) await update_stage_async() self._motion_policy.add_obstacle(cuboid, static=static) self._motion_policy.set_end_effector_target(target_pos, target_orient) success, time_to_target = await self.simulate_until_target_reached( timeout, target_pos, target_orient=target_orient ) if not success: self.assertTrue(False) if obs_prim is not None: self._motion_policy.remove_obstacle(cuboid) return
44,785
Python
41.211122
168
0.627844
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/tests/test_path_planner.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. import omni.kit.test import carb import asyncio # Import extension python module we are testing with absolute import path, as if we are external user (other extension) from omni.isaac.motion_generation import ( PathPlannerVisualizer, interface_config_loader, LulaKinematicsSolver, ArticulationKinematicsSolver, ) from omni.isaac.motion_generation.lula.path_planners import RRT from omni.isaac.core.utils.stage import ( open_stage_async, add_reference_to_stage, create_new_stage_async, update_stage_async, ) from omni.isaac.core.objects import FixedCuboid, VisualCuboid from omni.isaac.core.objects.ground_plane import GroundPlane from omni.isaac.core.utils.nucleus import get_assets_root_path from omni.isaac.core.robots import Robot from omni.isaac.core.utils.numpy.rotations import euler_angles_to_quats from omni.isaac.core.prims import GeometryPrimView from omni.isaac.core.utils.viewports import set_camera_view from omni.isaac.core.world import World import os import json import numpy as np # Having a test class derived from omni.kit.test.AsyncTestCase declared on the root of module will # make it auto-discoverable by omni.kit.test class TestPathPlanner(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._physics_dt = 1 / 60 # duration of physics frame in seconds self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.motion_generation") self._articulation_policy_extension_path = ext_manager.get_extension_path(ext_id) self._polciy_config_dir = os.path.join(self._articulation_policy_extension_path, "motion_policy_configs") self.assertTrue( os.path.exists(os.path.join(self._polciy_config_dir, "policy_map.json")), f'{os.path.join(self._polciy_config_dir, "policy_map.json")}', ) with open(os.path.join(self._polciy_config_dir, "policy_map.json")) as policy_map: self._policy_map = json.load(policy_map) await update_stage_async() robot_prim_path = "/panda" usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" await create_new_stage_async() await update_stage_async() add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() set_camera_view( eye=[0.7 * 2.95, 0.7 * 3.3, 0.7 * 5.5], target=[0, 0, 0], camera_prim_path="/OmniverseKit_Persp" ) rrt_config = interface_config_loader.load_supported_path_planner_config("Franka", "RRT") rrt = RRT(**rrt_config) # rrt.set_random_seed(1234569) rrt.set_max_iterations(10000) rrt.set_param("step_size", 0.01) self._planner = rrt # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() await self.reset_robot(self._robot) gripper_geoms = GeometryPrimView("/panda/panda_.*finger/geometry", collisions=np.ones(2)) gripper_geoms.disable_collision() hand_geom = GeometryPrimView("/panda/panda_hand/geometry", collisions=np.ones(1)) hand_geom.disable_collision() kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config("Franka") self._kinematics_solver = LulaKinematicsSolver(**kinematics_config) self._articulation_kinematics_solver = ArticulationKinematicsSolver( self._robot, self._kinematics_solver, "right_gripper" ) self._planner_visualizer = PathPlannerVisualizer(self._robot, self._planner) self.PRINT_GOLDEN_VALUES = False self.TEST_FOR_DETERMINISM = ( False ) # Right now RRT paths are not deterministic across different machines. Later this will be fixed, and determinism will be tested # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await update_stage_async() self._articulation_policy = None await update_stage_async() World.clear_instance() pass async def _set_determinism_settings(self, robot): World() carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) robot.disable_gravity() robot.set_solver_position_iteration_count(64) robot.set_solver_velocity_iteration_count(64) async def reset_robot(self, robot): """ To make motion_generation outputs more deterministic, this method may be used to teleport the robot to specified position targets, setting velocity to 0 This prevents changes in dynamic_control from affecting motion_generation tests """ robot.post_reset() await self._set_determinism_settings(robot) await update_stage_async() pass async def test_set_params(self): self._planner.set_param("seed", 5) self._planner.set_param("step_size", 0.001) self._planner.set_param("max_iterations", 1000) self._planner.set_param("distance_metric_weights", np.ones(7, dtype=np.float64) * 0.8) self._planner.set_param("task_space_frame_name", "panda_hand") self._planner.set_param("task_space_limits", np.array([[-1, 1], [-1, 1], [0, 1]], dtype=np.float64)) self._planner.set_param("c_space_planning_params/exploration_fraction", 0.6) self._planner.set_param( "task_space_planning_params/x_target_zone_tolerance", np.ones(3, dtype=np.float64) * 0.02 ) self._planner.set_param("task_space_planning_params/x_target_final_tolerance", 1e-4) self._planner.set_param("task_space_planning_params/task_space_exploitation_fraction", 0.5) self._planner.set_param("task_space_planning_params/task_space_exploration_fraction", 0.2) self._planner.reset() async def test_rrt_franka(self): target_pose = np.array([-0.4, 0.3, 0.5]) self._planner.set_end_effector_target(target_pose) # Check that this doesn't mess anything up self._planner.set_cspace_target(np.zeros(7)) # Should just be overridden self._planner.set_end_effector_target(target_pose) left_barrier = FixedCuboid( "/obstacles/left_barrier", size=1.0, scale=np.array([0.01, 0.5, 1]), position=np.array([0, 0.45, 0.5]) ) right_barrier = FixedCuboid( "/obstacles/right_barrier", size=1.0, scale=np.array([0.04, 0.5, 0.5]), position=np.array([0, -0.45, 0.35]) ) back_barrier = FixedCuboid( "/obstacles/back_barrier", size=1.0, scale=np.array([0.5, 0.01, 1]), position=np.array([-0.45, 0, 1]) ) top_barrier = FixedCuboid( "/obstacles/top_barrier", size=1.0, scale=np.array([0.25, 0.25, 0.01]), position=np.array([0, 0, 1.2]) ) ground_plane = GroundPlane("/ground") target_prim = VisualCuboid( "/target", size=1.0, scale=np.full((3,), 0.05), position=target_pose, color=np.array([1, 0, 0]) ) self._planner.add_obstacle(left_barrier) self._planner.add_obstacle(right_barrier) self._planner.add_obstacle(back_barrier) self._planner.add_obstacle(top_barrier) self._planner.add_obstacle(ground_plane) self._planner.update_world() # Generate waypoints no more than .5 radians (l1 norm) from each other actions = self._planner_visualizer.compute_plan_as_articulation_actions(max_cspace_dist=0.3) if self.PRINT_GOLDEN_VALUES: print("Number of actions: ", len(actions)) print("Final action: ", end="") [print(actions[-1].joint_positions[i], ",", end="") for i in range(len(actions[-1].joint_positions))] LOGGED_PATH_LEN = 11 LOGGED_FINAL_POSITION = np.array( [ -2.2235743574338285, 1.2670535347824194, -1.5803078127051602, -2.044557783811974, -0.889700828512457, 1.6705503159953106, 0.41399271401981974, None, None, ] ) if self.TEST_FOR_DETERMINISM: self.assertTrue( len(actions) == LOGGED_PATH_LEN, "Logged plan has length " + str(LOGGED_PATH_LEN) + "; this plan has length " + str(len(actions)), ) await self.assertAlmostEqual( LOGGED_FINAL_POSITION, actions[-1].joint_positions, f"The final position in the path doesn't match the logged position: {LOGGED_FINAL_POSITION} != {actions[-1].joint_positions}", ) else: self.assertTrue(len(actions) > 0, f"{len(actions)}") await self.follow_plan(actions, target_pose) async def test_rrt_franka_moving_base(self): target_pose = np.array([1.4, -0.1, 0.5]) self._planner.set_end_effector_target(target_pose) robot_base_position = np.array([1, 0, 0.2]) robot_base_orientation = euler_angles_to_quats(np.array([0.1, 0, 0.3])) barrier = FixedCuboid( "/obstacles/barrier", size=1.0, scale=np.array([0.01, 0.5, 1]), position=np.array([1.2, -0.3, 0.5]) ) target_prim = VisualCuboid( "/target", size=1.0, scale=np.full((3,), 0.05), position=target_pose, color=np.array([1, 0, 0]) ) self._planner.add_obstacle(barrier) self._planner.set_robot_base_pose(robot_base_position, robot_base_orientation) self._kinematics_solver.set_robot_base_pose(robot_base_position, robot_base_orientation) self._robot.set_world_pose(robot_base_position, robot_base_orientation) self._planner.update_world() # Generate waypoints no more than .5 radians (l1 norm) from each other actions = self._planner_visualizer.compute_plan_as_articulation_actions(max_cspace_dist=0.5) if self.PRINT_GOLDEN_VALUES: print("Number of actions: ", len(actions)) print("Final action: ", end="") [print(actions[-1].joint_positions[i], ",", end="") for i in range(len(actions[-1].joint_positions))] LOGGED_PATH_LEN = 6 LOGGED_FINAL_POSITION = np.array( [ -1.287984743737736, -1.194971983321831, 1.3341467119855843, -3.0448501997009876, 0.229684493139643, 3.1069385805619922, -1.3131528226307583, None, None, ] ) if self.TEST_FOR_DETERMINISM: self.assertTrue( len(actions) == LOGGED_PATH_LEN, "Logged plan has length " + str(LOGGED_PATH_LEN) + "; this plan has length " + str(len(actions)), ) await self.assertAlmostEqual( LOGGED_FINAL_POSITION, actions[-1].joint_positions, f"The final position in the path doesn't match the logged position: {LOGGED_FINAL_POSITION} != {actions[-1].joint_positions}", ) else: self.assertTrue(len(actions) > 0, f"{len(actions)}") await self.follow_plan(actions, target_pose) async def test_rrt_franka_cspace_target(self): cspace_target = np.array( [ -2.2235743574338285, 1.2670535347824194, -1.5803078127051602, -2.044557783811974, -0.889700828512457, 1.6705503159953106, 0.41399271401981974, ] ) target_pose = np.array([-0.4, 0.3, 0.5]) self._planner.set_cspace_target(cspace_target) # Check that this doesn't mess anything up self._planner.set_end_effector_target(np.zeros(3)) # Should just be overridden self._planner.set_cspace_target(cspace_target) left_barrier = FixedCuboid( "/obstacles/left_barrier", size=1.0, scale=np.array([0.01, 0.5, 1]), position=np.array([0, 0.45, 0.5]) ) right_barrier = FixedCuboid( "/obstacles/right_barrier", size=1.0, scale=np.array([0.04, 0.5, 0.5]), position=np.array([0, -0.45, 0.35]) ) back_barrier = FixedCuboid( "/obstacles/back_barrier", size=1.0, scale=np.array([0.5, 0.01, 1]), position=np.array([-0.45, 0, 1]) ) top_barrier = FixedCuboid( "/obstacles/top_barrier", size=1.0, scale=np.array([0.25, 0.25, 0.01]), position=np.array([0, 0, 1.2]) ) ground_plane = GroundPlane("/ground", z_position=-0.0305) target_prim = VisualCuboid( "/target", size=1.0, scale=np.full((3,), 0.05), position=target_pose, color=np.array([1, 0, 0]) ) self._planner.add_obstacle(left_barrier) self._planner.add_obstacle(right_barrier) self._planner.add_obstacle(back_barrier) self._planner.add_obstacle(top_barrier) self._planner.add_obstacle(ground_plane) self._planner.update_world() # Generate waypoints no more than .5 radians (l1 norm) from each other actions = self._planner_visualizer.compute_plan_as_articulation_actions(max_cspace_dist=0.3) if self.PRINT_GOLDEN_VALUES: print("Number of actions: ", len(actions)) print("Final action: ", end="") [print(actions[-1].joint_positions[i], ",", end="") for i in range(len(actions[-1].joint_positions))] LOGGED_PATH_LEN = 11 LOGGED_FINAL_POSITION = np.array( [ -2.2235743574338285, 1.2670535347824194, -1.5803078127051602, -2.044557783811974, -0.889700828512457, 1.6705503159953106, 0.41399271401981974, None, None, ] ) if self.TEST_FOR_DETERMINISM: self.assertTrue( len(actions) == LOGGED_PATH_LEN, "Logged plan has length " + str(LOGGED_PATH_LEN) + "; this plan has length " + str(len(actions)), ) await self.assertAlmostEqual( LOGGED_FINAL_POSITION, actions[-1].joint_positions, f"The final position in the path doesn't match the logged position: {LOGGED_FINAL_POSITION} != {actions[-1].joint_positions}", ) else: self.assertTrue(len(actions) > 0, f"{len(actions)}") await self.follow_plan(actions, target_pose) async def follow_plan(self, actions, target_pose, max_frames_per_waypoint=120): for frame in range(len(actions)): self._robot.get_articulation_controller().apply_action(actions[frame]) # Spend 30 frames getting to each waypoint for i in range(max_frames_per_waypoint): await omni.kit.app.get_app().next_update_async() diff = self._robot.get_joint_positions() - actions[frame].joint_positions # print(np.around(diff.astype(np.float),decimals=3)) # print(np.amax(abs(diff))) if np.linalg.norm(diff) < 0.01: break # Check that the robot hit the waypoint diff = self._robot.get_joint_positions() - actions[frame].joint_positions self.assertTrue(np.linalg.norm(diff) < 0.05, f"np.linalg.norm(diff) = {np.linalg.norm(diff)}") for i in range(20): # extra time to converge very tightly at final position await omni.kit.app.get_app().next_update_async() # Check the the end effector position reached the target ee_position = self._articulation_kinematics_solver.compute_end_effector_pose()[0] self.assertTrue( np.linalg.norm(ee_position - target_pose) < 0.01, "Not close enough to target with distance: " + str(np.linalg.norm(ee_position - target_pose)), ) async def assertAlmostEqual(self, a, b, dbg_msg=""): # overriding method because it doesn't support iterables a = np.array(a) b = np.array(b) self.assertFalse(np.any(abs((a[a != np.array(None)] - b[b != np.array(None)])) > 1e-3), dbg_msg) pass
17,364
Python
41.046005
142
0.61138
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/tests/test_trajectory_generator.py
# Copyright (c) 2022, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. from omni.isaac.motion_generation.articulation_kinematics_solver import ArticulationKinematicsSolver from omni.isaac.motion_generation.articulation_trajectory import ArticulationTrajectory from omni.isaac.motion_generation.lula.trajectory_generator import ( LulaCSpaceTrajectoryGenerator, LulaTaskSpaceTrajectoryGenerator, ) import omni.kit.test import carb import asyncio # Import extension python module we are testing with absolute import path, as if we are external user (other extension) from omni.isaac.motion_generation import interface_config_loader from omni.isaac.motion_generation.lula import LulaKinematicsSolver import lula from omni.isaac.core.utils.stage import update_stage_async, add_reference_to_stage, create_new_stage_async from omni.isaac.core.robots.robot import Robot from omni.isaac.core.objects.cuboid import VisualCuboid from omni.isaac.core.utils.numpy.rotations import rotvecs_to_quats, quats_to_rot_matrices, rot_matrices_to_quats from omni.isaac.core.utils.nucleus import get_assets_root_path from omni.isaac.core.utils.prims import delete_prim from omni.isaac.core.world import World import os import json import numpy as np # Having a test class derived from omni.kit.test.AsyncTestCase declared on the root of module will # make it auto-discoverable by omni.kit.test class TestTrajectoryGenerator(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._physics_dt = 1 / 60 # duration of physics frame in seconds self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.motion_generation") self._mg_extension_path = ext_manager.get_extension_path(ext_id) self._polciy_config_dir = os.path.join(self._mg_extension_path, "motion_policy_configs") self.assertTrue(os.path.exists(os.path.join(self._polciy_config_dir, "policy_map.json"))) with open(os.path.join(self._polciy_config_dir, "policy_map.json")) as policy_map: self._policy_map = json.load(policy_map) await create_new_stage_async() await update_stage_async() pass async def _set_determinism_settings(self, robot): World() carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) robot.disable_gravity() robot.set_solver_position_iteration_count(64) robot.set_solver_velocity_iteration_count(64) # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await update_stage_async() self._mg = None await update_stage_async() World.clear_instance() pass async def test_lula_c_space_traj_gen_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_name = "Franka" robot_prim_path = "/panda" ee_frame = "panda_rightfinger" task_space_traj = np.array([[0.5, 0, 0.5], [0.3, -0.3, 0.3], [-0.3, -0.3, 0.6], [0, 0, 0.7]]) orientation_target = rotvecs_to_quats(np.array([np.pi, 0, 0])) await self._test_lula_c_space_traj_gen( usd_path, robot_name, robot_prim_path, ee_frame, task_space_traj, orientation_target ) task_space_traj = np.array([[0.5, 0, 0.5], [0, 0.5, 0.5], [-0.5, 0, 0.5]]) await self._test_lula_c_space_traj_gen( usd_path, robot_name, robot_prim_path, ee_frame, task_space_traj, orientation_target ) async def test_lula_c_space_traj_gen_cobotta(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Denso/cobotta_pro_900.usd" robot_name = "Cobotta_Pro_900" robot_prim_path = "/cobotta_pro_900" ee_frame = "gripper_center" task_space_traj = np.array([[0.5, 0, 0.5], [0.3, -0.3, 0.3], [-0.3, -0.3, 0.6]]) orientation_target = rotvecs_to_quats(np.array([np.pi, 0, 0])) await self._test_lula_c_space_traj_gen( usd_path, robot_name, robot_prim_path, ee_frame, task_space_traj, orientation_target ) async def _test_lula_c_space_traj_gen( self, usd_path, robot_name, robot_prim_path, ee_frame, task_space_targets, orientation_target ): add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._kinematics_solver = LulaKinematicsSolver(**kinematics_config) # Start Simulation and wait self._timeline.play() await update_stage_async() for i, target_pos in enumerate(task_space_targets): VisualCuboid(f"/targets/target_{i}", position=target_pos, size=0.05) self._robot = Robot(robot_prim_path) self._robot.initialize() await self._set_determinism_settings(self._robot) iks = [] ik = None for target_pos in task_space_targets: ik, succ = self._kinematics_solver.compute_inverse_kinematics( ee_frame, target_pos, target_orientation=orientation_target, warm_start=ik ) if not succ: carb.log_error(f"Could not compute ik for given task_space position {target_pos}") iks.append(ik) iks = np.array(iks) self._trajectory_generator = LulaCSpaceTrajectoryGenerator( kinematics_config["robot_description_path"], kinematics_config["urdf_path"] ) self._art_kinematics = ArticulationKinematicsSolver(self._robot, self._kinematics_solver, ee_frame) trajectory = self._trajectory_generator.compute_c_space_trajectory(iks) self.assertFalse(trajectory is None) self._art_trajectory = ArticulationTrajectory(self._robot, trajectory, self._physics_dt) art_traj = self._art_trajectory.get_action_sequence() initial_positions = art_traj[0].joint_positions initial_positions[initial_positions == None] = 0 self._robot.set_joint_positions(initial_positions) self._robot.set_joint_velocities(np.zeros_like(initial_positions)) await update_stage_async() target_dists = np.ones(len(task_space_targets)) for action in art_traj: await update_stage_async() self._robot.apply_action(action) robot_pos = self._art_kinematics.compute_end_effector_pose()[0] diff = np.linalg.norm(task_space_targets - robot_pos, axis=1) mask = target_dists > diff target_dists[mask] = diff[mask] delete_prim("/targets") self.assertTrue( np.all(target_dists < 0.01), f"Did not hit every task_space target: Distance to targets = {target_dists}" ) async def test_set_c_space_trajectory_solver_config_settings(self): robot_name = "Franka" kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._trajectory_generator = LulaCSpaceTrajectoryGenerator( kinematics_config["robot_description_path"], kinematics_config["urdf_path"] ) lula_kinematics = LulaKinematicsSolver(**kinematics_config) self._trajectory_generator.set_c_space_position_limits(*lula_kinematics.get_cspace_position_limits()) self._trajectory_generator.set_c_space_velocity_limits(lula_kinematics.get_cspace_velocity_limits()) self._trajectory_generator.set_c_space_acceleration_limits(lula_kinematics.get_cspace_acceleration_limits()) self._trajectory_generator.set_c_space_jerk_limits(lula_kinematics.get_cspace_jerk_limits()) self._trajectory_generator.set_solver_param("max_segment_iterations", 10) self._trajectory_generator.set_solver_param("max_aggregate_iterations", 10) self._trajectory_generator.set_solver_param("convergence_dt", 0.5) self._trajectory_generator.set_solver_param("max_dilation_iterations", 5) self._trajectory_generator.set_solver_param("min_time_span", 0.5) self._trajectory_generator.set_solver_param("time_split_method", "uniform") self._trajectory_generator.set_solver_param("time_split_method", "chord_length") self._trajectory_generator.set_solver_param("time_split_method", "centripetal") async def test_lula_task_space_traj_gen_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_name = "Franka" robot_prim_path = "/panda" ee_frame = "panda_hand" pos_targets = np.array([[0.5, 0, 0.5], [0.3, -0.3, 0.3], [-0.3, -0.3, 0.6], [0, 0, 0.7]]) orient_targets = np.tile(rotvecs_to_quats(np.array([np.pi, 0, 0])), (len(pos_targets), 1)) await self._test_lula_task_space_trajectory_generator( usd_path, robot_name, robot_prim_path, ee_frame, pos_targets, orient_targets ) async def test_lula_task_space_traj_gen_ur10(self): usd_path = get_assets_root_path() + "/Isaac/Robots/UR10/ur10.usd" robot_name = "UR10" robot_prim_path = "/ur10" ee_frame = "ee_link" path, pos_targets, orient_targets = await self._build_rect_path() await self._test_lula_task_space_trajectory_generator( usd_path, robot_name, robot_prim_path, ee_frame, pos_targets, orient_targets, path ) path, pos_targets, orient_targets = await self._build_circle_path_with_rotations() await self._test_lula_task_space_trajectory_generator( usd_path, robot_name, robot_prim_path, ee_frame, pos_targets, orient_targets, path ) async def test_lula_task_space_traj_gen_cobotta(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Denso/cobotta_pro_900.usd" robot_name = "Cobotta_Pro_900" robot_prim_path = "/cobotta_pro_900" ee_frame = "gripper_center" path, pos_targets, orient_targets = await self._build_rect_path() await self._test_lula_task_space_trajectory_generator( usd_path, robot_name, robot_prim_path, ee_frame, pos_targets, orient_targets, path ) path, pos_targets, orient_targets = await self._build_circle_path_with_rotations() await self._test_lula_task_space_trajectory_generator( usd_path, robot_name, robot_prim_path, ee_frame, pos_targets, orient_targets, path ) async def _build_rect_path(self, rot_vec=np.array([np.pi, 0, 0])): rect_path = np.array([[0.3, -0.3, 0.1], [0.3, 0.3, 0.1], [0.3, 0.3, 0.5], [0.3, -0.3, 0.5], [0.3, -0.3, 0.1]]) builder = lula.create_task_space_path_spec( lula.Pose3(lula.Rotation3(np.linalg.norm(rot_vec), rot_vec / np.linalg.norm(rot_vec)), rect_path[0]) ) builder.add_translation(rect_path[1]) builder.add_translation(rect_path[2]) builder.add_translation(rect_path[3]) builder.add_translation(rect_path[4]) path = builder position_targets = np.array( [[0.3, -0.3, 0.1], [0.3, 0.3, 0.1], [0.3, 0.3, 0.5], [0.3, -0.3, 0.5], [0.3, -0.3, 0.1]] ) orientation_targets = rotvecs_to_quats(np.tile(rot_vec, (len(position_targets), 1))) return path, position_targets, orientation_targets async def _build_circle_path_with_rotations(self): builder = lula.create_task_space_path_spec( lula.Pose3(lula.Rotation3(np.pi, np.array([1, 0, 0])), np.array([0.3, 0.2, 0.3])) ) builder.add_three_point_arc(np.array([0.3, -0.2, 0.3]), np.array([0.3, 0, 0.6]), True) builder.add_three_point_arc(np.array([0.3, 0.2, 0.3]), np.array([0.3, 0, 0]), True) builder.add_rotation(lula.Rotation3(np.pi / 2, np.array([1, 0, 0]))) position_targets = np.array( [[0.3, 0.2, 0.3], [0.3, 0, 0.6], [0.3, -0.2, 0.3], [0.3, 0, 0], [0.3, 0.2, 0.3], [0.3, 0.2, 0.3]] ) orientation_targets = rotvecs_to_quats(np.tile(np.array([np.pi, 0, 0]), (len(position_targets), 1))) orientation_targets[-1] = rotvecs_to_quats(np.array([np.pi / 2, 0, 0])) return builder, position_targets, orientation_targets async def _test_lula_task_space_trajectory_generator( self, usd_path, robot_name, robot_prim_path, ee_frame, task_space_targets, orientation_targets, built_path=None ): add_reference_to_stage(usd_path, robot_prim_path) self._timeline = omni.timeline.get_timeline_interface() kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._kinematics_solver = LulaKinematicsSolver(**kinematics_config) self._trajectory_generator = LulaTaskSpaceTrajectoryGenerator( kinematics_config["robot_description_path"], kinematics_config["urdf_path"] ) # Start Simulation and wait self._timeline.play() await update_stage_async() for i, target_pos in enumerate(task_space_targets): VisualCuboid(f"/targets/target_{i}", position=target_pos, size=0.05) self._robot = Robot(robot_prim_path) self._robot.initialize() await self._set_determinism_settings(self._robot) if built_path is None: trajectory = self._trajectory_generator.compute_task_space_trajectory_from_points( task_space_targets, orientation_targets, ee_frame ) self.assertTrue(trajectory is not None, "Failed to generate trajectory") else: trajectory = self._trajectory_generator.compute_task_space_trajectory_from_path_spec(built_path, ee_frame) self.assertTrue(trajectory is not None, "Failed to generate trajectory") self._art_kinematics = ArticulationKinematicsSolver(self._robot, self._kinematics_solver, ee_frame) self._art_trajectory = ArticulationTrajectory(self._robot, trajectory, self._physics_dt) art_traj = self._art_trajectory.get_action_sequence() initial_positions = art_traj[0].joint_positions initial_positions[initial_positions == None] = 0 self._robot.set_joint_positions(initial_positions) self._robot.set_joint_velocities(np.zeros_like(initial_positions)) await update_stage_async() target_dists = np.ones(len(task_space_targets)) for action in art_traj: await update_stage_async() self._robot.apply_action(action) robot_pos, robot_orient = self._art_kinematics.compute_end_effector_pose() pos_diff = np.linalg.norm(task_space_targets - robot_pos, axis=1) orient_diff = np.linalg.norm(orientation_targets - rot_matrices_to_quats(robot_orient), axis=1) diff = pos_diff + orient_diff mask = target_dists > diff target_dists[mask] = diff[mask] delete_prim("/targets") self.assertTrue( np.all(target_dists < 0.01), f"Did not hit every task_space target: Distance to targets = {target_dists}" ) async def test_set_task_space_trajectory_solver_config_settings(self): robot_name = "Franka" kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._trajectory_generator = LulaTaskSpaceTrajectoryGenerator( kinematics_config["robot_description_path"], kinematics_config["urdf_path"] ) lula_kinematics = LulaKinematicsSolver(**kinematics_config) self._trajectory_generator.set_c_space_position_limits(*lula_kinematics.get_cspace_position_limits()) self._trajectory_generator.set_c_space_velocity_limits(lula_kinematics.get_cspace_velocity_limits()) self._trajectory_generator.set_c_space_acceleration_limits(lula_kinematics.get_cspace_acceleration_limits()) self._trajectory_generator.set_c_space_jerk_limits(lula_kinematics.get_cspace_jerk_limits()) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("max_segment_iterations", 10) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("max_aggregate_iterations", 10) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("convergence_dt", 0.5) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("max_dilation_iterations", 5) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("min_time_span", 0.5) self._trajectory_generator.set_c_space_trajectory_generator_solver_param("time_split_method", "uniform") self._trajectory_generator.set_c_space_trajectory_generator_solver_param("time_split_method", "chord_length") self._trajectory_generator.set_c_space_trajectory_generator_solver_param("time_split_method", "centripetal") conversion_config = self._trajectory_generator.get_path_conversion_config() conversion_config.alpha = 1.3 conversion_config.initial_s_step_size = 0.04 conversion_config.initial_s_step_size_delta = 0.003 conversion_config.max_iterations = 40 conversion_config.max_position_deviation = 0.002 conversion_config.min_position_deviation = 0.0015 conversion_config.min_s_step_size = 1e-4 conversion_config.min_s_step_size_delta = 1e-4
18,274
Python
44.460199
119
0.663018
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/omni/isaac/motion_generation/tests/test_kinematics.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. from omni.isaac.motion_generation.articulation_kinematics_solver import ArticulationKinematicsSolver import omni.kit.test import carb import asyncio # Import extension python module we are testing with absolute import path, as if we are external user (other extension) from omni.isaac.motion_generation import interface_config_loader from omni.isaac.motion_generation.lula import LulaKinematicsSolver from omni.isaac.core.utils import distance_metrics from omni.isaac.core.utils.stage import update_stage_async, open_stage_async from omni.isaac.core.utils.nucleus import get_assets_root_path from omni.isaac.core.prims import XFormPrim from omni.isaac.core.utils.types import ArticulationAction from omni.isaac.core.robots.robot import Robot from omni.isaac.core.world import World from omni.isaac.core.utils.viewports import set_camera_view import os import json import numpy as np from omni.isaac.core.utils.prims import is_prim_path_valid from omni.isaac.core.utils.numpy.rotations import quats_to_rot_matrices from omni.isaac.core.world import World # Having a test class derived from omni.kit.test.AsyncTestCase declared on the root of module will # make it auto-discoverable by omni.kit.test class TestKinematics(omni.kit.test.AsyncTestCase): # Before running each test async def setUp(self): self._physics_dt = 1 / 60 # duration of physics frame in seconds self._timeline = omni.timeline.get_timeline_interface() ext_manager = omni.kit.app.get_app().get_extension_manager() ext_id = ext_manager.get_enabled_extension_id("omni.isaac.motion_generation") self._mg_extension_path = ext_manager.get_extension_path(ext_id) self._polciy_config_dir = os.path.join(self._mg_extension_path, "motion_policy_configs") self.assertTrue(os.path.exists(os.path.join(self._polciy_config_dir, "policy_map.json"))) with open(os.path.join(self._polciy_config_dir, "policy_map.json")) as policy_map: self._policy_map = json.load(policy_map) carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) pass # After running each test async def tearDown(self): self._timeline.stop() while omni.usd.get_context().get_stage_loading_status()[2] > 0: print("tearDown, assets still loading, waiting to finish...") await asyncio.sleep(1.0) await update_stage_async() self._mg = None await update_stage_async() World.clear_instance() pass async def _set_determinism_settings(self, robot): World() carb.settings.get_settings().set_bool("/app/runLoops/main/rateLimitEnabled", True) carb.settings.get_settings().set_int("/app/runLoops/main/rateLimitFrequency", int(1 / self._physics_dt)) carb.settings.get_settings().set_int("/persistent/simulation/minFrameRate", int(1 / self._physics_dt)) robot.disable_gravity() robot.set_solver_position_iteration_count(64) robot.set_solver_velocity_iteration_count(64) async def reset_robot(self, robot): """ To make motion_generation outputs more deterministic, this method may be used to teleport the robot to specified position targets, setting velocity to 0 This prevents changes in dynamic_control from affecting motion_generation tests """ robot.post_reset() await self._set_determinism_settings(robot) await update_stage_async() pass async def test_lula_fk_ur10(self): usd_path = get_assets_root_path() + "/Isaac/Robots/UR10/ur10.usd" robot_name = "UR10" robot_prim_path = "/ur10" trans_dist, rot_dist = await self._test_lula_fk( usd_path, robot_name, robot_prim_path, joint_target=-np.array([0.1, 0.1, 0.1, 0.1, 0.1, 0.2]) ) self.assertTrue(np.all(trans_dist < 0.001)) self.assertTrue(np.all(rot_dist < 0.005)) async def test_lula_fk_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_name = "Franka" robot_prim_path = "/panda" trans_dist, rot_dist = await self._test_lula_fk( usd_path, robot_name, robot_prim_path, base_pose=np.array([0.10, 0, 1.5]), base_orient=np.array([0.1, 0, 0.3, 0.7]), ) # There is a known bug with the kinematics not matching on the Franka finger frames self.assertTrue(np.all(trans_dist[:-2] < 0.005), trans_dist) self.assertTrue(np.all(rot_dist[:] < 0.005), rot_dist) async def _test_lula_fk( self, usd_path, robot_name, robot_prim_path, joint_target=None, base_pose=np.zeros(3), base_orient=np.array([1, 0, 0, 0]), ): await open_stage_async(usd_path) set_camera_view(eye=[3.5, 2.3, 2.1], target=[0, 0, 0], camera_prim_path="/OmniverseKit_Persp") self._timeline = omni.timeline.get_timeline_interface() kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._kinematics = LulaKinematicsSolver(**kinematics_config) # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() self._robot.set_world_pose(base_pose, base_orient) self._kinematics.set_robot_base_pose(base_pose, base_orient) if joint_target is not None: self._robot.get_articulation_controller().apply_action(ArticulationAction(joint_target)) # move towards target or default position await self.move_until_still(self._robot) frame_names = self._kinematics.get_all_frame_names() art_fk = ArticulationKinematicsSolver(self._robot, self._kinematics, frame_names[0]) trans_dists = [] rot_dist = [] # save the distance between lula and usd frames for each frame that exists for both robot views for frame in frame_names: if is_prim_path_valid(robot_prim_path + "/" + frame): art_fk.set_end_effector_frame(frame) lula_frame_pos, lula_frame_rot = art_fk.compute_end_effector_pose() usd_frame_pos, usd_frame_rot = XFormPrim(robot_prim_path + "/" + frame).get_world_pose() trans_dists.append(distance_metrics.weighted_translational_distance(lula_frame_pos, usd_frame_pos)) rot_dist.append( distance_metrics.rotational_distance_angle(lula_frame_rot, quats_to_rot_matrices(usd_frame_rot)) ) return np.array(trans_dists), np.array(rot_dist) async def test_lula_ik_ur10(self): usd_path = get_assets_root_path() + "/Isaac/Robots/UR10/ur10.usd" robot_name = "UR10" robot_prim_path = "/ur10" frame = "ee_link" # await self._test_lula_ik(usd_path,robot_name,robot_prim_path,frame,np.array([40,60,80]),np.array([0,1,0,0]),1,.1) await self._test_lula_ik( usd_path, robot_name, robot_prim_path, frame, np.array([0.40, 0.40, 0.80]), None, 1, 0.1, base_pose=np.array([0.10, 0, 0.5]), base_orient=np.array([0.1, 0, 0.3, 0.7]), ) async def test_lula_ik_franka(self): usd_path = get_assets_root_path() + "/Isaac/Robots/Franka/franka.usd" robot_name = "Franka" robot_prim_path = "/panda" frame = "right_gripper" # await self._test_lula_ik(usd_path,robot_name,robot_prim_path,frame,np.array([40,30,60]),np.array([.1,0,0,-1]),1,.1) await self._test_lula_ik( usd_path, robot_name, robot_prim_path, frame, np.array([0.40, 0.30, 0.60]), np.array([0.1, 0, 0, -1]), 1, 0.1, base_pose=np.array([0.10, 0, 0.5]), base_orient=np.array([0.1, 0, 0.3, 0.7]), ) frame = "panda_hand" await self._test_lula_ik( usd_path, robot_name, robot_prim_path, frame, np.array([0.40, 0.30, 0.60]), None, 1, 0.1, base_pose=np.array([0.10, 0, 0.5]), base_orient=np.array([0.1, 0, 0.3, 0.7]), ) async def _test_lula_ik( self, usd_path, robot_name, robot_prim_path, frame, position_target, orientation_target, position_tolerance, orientation_tolerance, base_pose=np.zeros(3), base_orient=np.array([0, 0, 0, 1]), ): await open_stage_async(usd_path) set_camera_view(eye=[3.5, 2.3, 2.1], target=[0, 0, 0], camera_prim_path="/OmniverseKit_Persp") self._timeline = omni.timeline.get_timeline_interface() kinematics_config = interface_config_loader.load_supported_lula_kinematics_solver_config(robot_name) self._kinematics = LulaKinematicsSolver(**kinematics_config) # Start Simulation and wait self._timeline.play() await update_stage_async() self._robot = Robot(robot_prim_path) self._robot.initialize() self._robot.set_world_pose(base_pose, base_orient) self._kinematics.set_robot_base_pose(base_pose, base_orient) art_ik = ArticulationKinematicsSolver(self._robot, self._kinematics, frame) # testing IK and ArticulationKinematicsSolver object wrapping IK alg_ik_action, success = art_ik.compute_inverse_kinematics( position_target, orientation_target, position_tolerance, orientation_tolerance ) alg_ik, _ = self._kinematics.compute_inverse_kinematics( frame, position_target, orientation_target, None, position_tolerance, orientation_tolerance ) self.assertTrue(success, "IK Solver did not converge to a solution") # check if USD robot can get to IK result self._robot.get_articulation_controller().apply_action(alg_ik_action) await self.move_until_still(self._robot) # check IK consistent with FK lula_pos, lula_rot = self._kinematics.compute_forward_kinematics(frame, joint_positions=alg_ik) self.assertTrue( distance_metrics.weighted_translational_distance(lula_pos, position_target) < position_tolerance ) if orientation_target is not None: tgt_rot = quats_to_rot_matrices(orientation_target) rot_dist = distance_metrics.rotational_distance_angle(lula_rot, tgt_rot) self.assertTrue(rot_dist < orientation_tolerance, "Rotational distance too large: " + str(rot_dist)) # check IK consistent with USD robot frames if is_prim_path_valid(robot_prim_path + "/" + frame): usd_pos, usd_rot = XFormPrim(robot_prim_path + "/" + frame).get_world_pose() trans_dist = distance_metrics.weighted_translational_distance(usd_pos, position_target) self.assertTrue(trans_dist < position_tolerance, str(usd_pos) + str(position_target)) if orientation_target is not None: rot_dist = distance_metrics.rotational_distance_angle(quats_to_rot_matrices(usd_rot), tgt_rot) self.assertTrue(rot_dist < orientation_tolerance) else: carb.log_warn("Frame " + frame + " does not exist on USD robot") async def move_until_still(self, robot, timeout=500): h = 10 positions = np.zeros((h, robot.num_dof)) for i in range(timeout): positions[i % h] = robot.get_joint_positions() await update_stage_async() if i > h: std = np.std(positions, axis=0) if np.all(std < 0.001): return i return timeout
12,635
Python
40.70297
125
0.630313
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/docs/CHANGELOG.md
# Changelog ## [4.5.6] - 2023-01-06 ### Fixed - Typo in variable name in ArticulationTrajectory.get_robot_articulation() ## [4.5.5] - 2022-12-12 ### Changed - Updates to API docs ## [4.5.4] - 2022-12-04 ### Changed - Small change to Cobotta RmpFlow configs for consistency with tutorials. ## [4.5.3] - 2022-12-01 ### Changed - Moved Cortex UR10 RMPflow config file and corresponding policy config to new directory (was only in legacy directory and unused). ## [4.5.2] - 2022-11-29 ### Changed - Updated old robot_description YAML files for Franka, UR10, DOFbot, and Cobotta to remove unecessary fields that had no effect. ## [4.5.1] - 2022-11-28 ### Added - Updated file paths to Nucleus assets in RmpFlow tests for Kawasaki, Flexiv, and Festo robots. ## [4.5.0] - 2022-11-28 ### Added - Added RmpFlow config and test for FestoCobot ## [4.4.0] - 2022-11-28 ### Added - Added RmpFlow configs and tests for Kawasaki and Flexiv robots ## [4.3.1] - 2022-11-22 ### Added - Cortex UR10 configs for UR10 bin supporting stacking demo ## [4.3.0] - 2022-11-22 ### Changed - Updated ArticulationSubset to handle sparse ArticulationActions. Previously, it None-padded the ArticulationAction. - Some modifications to ArticulationSubset to simplify the error checking code and change member names. - Updates ArticulationMotionPolicy to use the sparse API. - Moved ArticulationSubset to omni.isaac.core ## [4.2.0] - 2022-11-18 ### Added - Added RmpFlow configs for universal robots ## [4.1.1] - 2022-11-18 ### Fixed - Fixed missing import statement for ArticulationTrajectory in MotionGeneration __init__ ## [4.1.0] - 2022-11-17 ### Added - Added Trajectory interface, ArticulationTrajectory, and Lula Trajectory Generators ## [4.0.3] - 2022-11-10 ### Changed - Updated determinism settings to include omni.isaac.core World ## [4.0.2] - 2022-10-24 ### Changed - Moved Test cases using UR10 asset to use USD from Nucleus ## [4.0.1] - 2022-10-20 ### Changed - Moved Test cases using Franka asset to use USD from Nucleus ## [4.0.0] - 2022-10-17 ### Changed - Allow user to variable physics dt on each frame to an ArticulationMotionPolicy or set a default value. - Change RmpFlow parameter 'evaluations_per_frame' to 'maximum_substep_size' to account for a possibly varying framerate ## [3.6.4] - 2022-10-06 ### Changed - Updated outdated Franka URDF with new joint limits on joint 7 ## [3.6.3] - 2022-09-02 ### Added - Added function to get default rmpflow cspace target - Added test case for setting rmpflow cspace target ## [3.6.2] - 2022-09-01 ### Changed - Remove legacy viewport calls from tests ## [3.6.1] - 2022-08-16 ### Changed - Updated RMPflow parameters in config YAML files for Denso robots: Turned on velocity_cap_rmp ## [3.6.0] - 2022-08-10 ### Added - Added Cobotta Pro 900 and Cobotta Pro 1300 as supported robots with provided RMPflow config files and test cases. ## [3.5.1] - 2022-08-03 ### Fixed - `ArticulationSubset.get_joint_subset_indices()` fixed (was returning function rather than return value of function call.) ## [3.5.0] - 2022-07-26 ### Changed - Changed gripper_controller argument to gripper in the PickPlaceController. - moved PickPlaceController and StackingController to omni.isaac.manipulators ## [3.4.0] - 2022-07-20 ### Added - Added set_param() function to Lula RRT implementation. ### Changed - Changed docstrings for PathPlannerVisualizer and Lula RRT implementation ### Fixed - Fixed unreliable test case for lula RRT by reducing the RRT step size ## [3.3.1] - 2022-07-19 ### Fixed - Fixed bug in RmpFlow.set_cspace_target() which changed the end effector target when it shouldn't have - Fixed bug in RmpFlow.get_internal_robot_joint_states() which resulted in a TypeError ## [3.3.0] - 2022-07-18 ### Changed - Updated ArticulationSubset to wait until robot joint states are queried to access the Articulation object. This avoids annoying errors when attempting to initialize an ArticulationMotionPolicy before the "play" button has been pressed. ## [3.2.1] - 2022-06-28 ### Changed - Updated MotionPolicy to not assume a default orientation. It now passes None to the MotionPolicy. ## [3.2.0] - 2022-06-17 ### Added - Added PathPlanningInterface with Lula RRT implementation and simple class for aiding visualization ## [3.1.2] - 2022-05-23 ### Added - Added conversion to numpy if articulation backend is GPU/torch ## [3.1.1] - 2022-05-18 ### Added - Added getter to get the MotionPolicy from a MotionPolicyController. ## [3.1.0] - 2022-05-09 ### Changed - Updated all hard coded USD object values to meters in motion_generation tests ### Fixed - Fixed bug in RmpFlow.create_ground_plane() related to unit conversion ## [3.0.1] - 2022-05-02 ### Added - Added some accessors to ArticulationMotionPolicy and ArticulationSubset. ## [3.0.0] - 2022-04-29 ### Added - Added Kinematics interface with a Lula implementation - Added ArticulationKinematicsSolver wrapper for interfacing kinematics with USD robot ### Changed - Replaced InverseKinematicsSolver(BaseController) object with ArticulationKinematicsSolver ## [2.0.0] - 2022-04-21 ### Changed - Renamed MotionGenerator to ArticulationMotionPolicy ### Added - Created ArticulationSubset class to handle index mapping between Articulation and MotionPolicy ## [1.3.1] - 2022-04-27 ### Added - Added RmpFlowSmoothed to lula/motion_policies.py to support cortex. ## [1.3.0] - 2022-04-18 ### Changed - Extracted methods from MotionPolicy to form a WorldInterface class. This has no functional effect on any code outside MotionGeneration ## [1.2.0] - 2022-04-15 ### Changed - Obstacles are now marked as static explicitly when added to MotionPolicy ## [1.1.0] - 2022-04-14 ### Added - Separated RmpFlow visualization functions for end effector and collision spheres - Added test case for visualization - Added Sdf.ChangeBlock() to visualization functions for efficiency ## [1.0.3] - 2022-04-13 ### Changed - Fixed typo in interface_config_loader.py. ## [1.0.2] - 2022-04-01 ### Changed - modified default RmpFlow configs have fewer updates per frame (10 was unnecessary) and to not ignore robot state updates by default - updated golden values in tests as a direct result of config change ## [1.0.1] - 2022-04-01 ### Added - test case for motion_generation extension: test for proper behavior when add/enable/disable/remove objects to RmpFlow ### Fixed - ground plane handling: enable/disable/remove ground_plane didn't work - static obstacle handling: dictionary key error when enable/disable/remove static obstacles ## [1.0.0] - 2022-03-25 ### Changed - Restructured MotionGeneration extension to place emphasis on MotionPolicy over MotionGeneration. The user is now expected to interact directly with a MotionPolicy for adding/editing obstacles, and setting targets. MotionGeneration is a light utility class for interfacing the simulated USD robot to the MotionPolicy (get USD robot state and appropriately map the joint indeces). - RmpFlowController -> MotionPolicyController: - The RmpFlowController wrapper that was used to interface Core examples with RmpFlow has been expanded to wrap any MotionPolicy - omni.isaac.motion_generation/policy_configs -> omni.isaac.motion_generation/motion_policy_configs: changed folder containing config files for MotionPolicies to be named "motion_policy_configs" to leave room for future interfaces to have config directories - Path to RmpFlow: omni.isaac.motion_generation.LulaMotionPolicies.RmpFlow -> omni.isaac.motion_generation.lula.motion_policies.RmpFlow ### Added - interface_config_loader: a set of helper functions for checking what config files exist directly in the motion_generation extension and loading the configs as keyword arguments to the appropriate class e.g. RmpFlow(**loaded_config_dict) ## [0.2.1] - 2022-02-15 - Updated internal RMPflow implementation to allow for visualizing Lula collision spheres as prims on the stage ## [0.2.0] - 2022-02-10 ### Changed - Updated MotionGeneration to use Core API to query prim position and control the robot ## [0.1.5] - 2022-02-10 ### Fixed - Undefined joint in dofbot USD referenced by RMPflow config ## [0.1.4] - 2022-01-20 ### Added - moved kinematics.py from omni.isaac.core.utils to this extension ## [0.1.3] - 2021-12-13 ### Changed - Removed deprecated fields from the Lula robot description files and RMPflow configuration files for the DOFBOT and Franka robots. This also corrects an oversight in the Franka robot description file that had resulted in a lack of collision spheres (and thus obstacle avoidance) for panda_link6. ## [0.1.2] - 2021-12-02 ### Changed - event_velocities to events_dt in PickPlaceController - Added new phase of wait in PickPlaceController ## [0.1.1] - 2021-08-04 ### Added - Added a simple wheel base pose controller. ## [0.1.0] - 2021-08-04 ### Added - Initial version of Isaac Sim Motion Generation Extension
8,972
Markdown
27.305994
384
0.741864
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.motion_generation/docs/index.rst
Motion Generation Extension [omni.isaac.motion_generation] ########################################################## World Interface ================ .. autoclass:: omni.isaac.motion_generation.WorldInterface :members: :undoc-members: :member-order: bysource Motion Policy Interface ======================= .. autoclass:: omni.isaac.motion_generation.MotionPolicy :members: :undoc-members: :member-order: bysource .. autoclass:: omni.isaac.motion_generation.lula.motion_policies.RmpFlow :members: :undoc-members: :member-order: bysource ArticulationMotionPolicy ========================= .. autoclass:: omni.isaac.motion_generation.ArticulationMotionPolicy :members: :undoc-members: :member-order: bysource KinematicsSolver =========================== .. autoclass:: omni.isaac.motion_generation.KinematicsSolver :members: :undoc-members: :member-order: bysource .. autoclass:: omni.isaac.motion_generation.LulaKinematicsSolver :members: :undoc-members: :member-order: bysource ArticulationKinematicsSolver ============================= .. autoclass:: omni.isaac.motion_generation.ArticulationKinematicsSolver :members: :undoc-members: :member-order: bysource Path Planning Interface ======================== .. autoclass:: omni.isaac.motion_generation.PathPlanner :members: :undoc-members: :member-order: bysource .. autoclass:: omni.isaac.motion_generation.lula.RRT :members: :undoc-members: :member-order: bysource Trajectory =================== .. autoclass:: omni.isaac.motion_generation.Trajectory :members: :undoc-members: :member-order: bysource .. autoclass:: omni.isaac.motion_generation.lula.LulaTrajectory :members: :undoc-members: :member-order: bysource Lula Trajectory Generators ========================== .. autoclass:: omni.isaac.motion_generation.lula.LulaCSpaceTrajectoryGenerator :members: :undoc-members: :member-order: bysource .. autoclass:: omni.isaac.motion_generation.lula.LulaTaskSpaceTrajectoryGenerator :members: :undoc-members: :member-order: bysource ArticulationTrajectory ====================== .. autoclass:: omni.isaac.motion_generation.ArticulationTrajectory :members: :undoc-members: :member-order: bysource Motion Policy Base Controller ============================== .. automodule:: omni.isaac.motion_generation.motion_policy_controller :inherited-members: :members: :undoc-members: :exclude-members: Wheel Base Pose Controller =========================== .. automodule:: omni.isaac.motion_generation.wheel_base_pose_controller :inherited-members: :members: :undoc-members: :exclude-members:
2,677
reStructuredText
21.504201
81
0.663429
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.version/config/extension.toml
[core] reloadable = true order = 0 [package] version = "1.0.0" category = "Other" title = "Isaac Sim Version" description = "Isaac Sim Version" authors = ["NVIDIA"] repository = "" keywords = ["isaac"] changelog = "docs/CHANGELOG.md" readme = "docs/README.md" icon = "data/icon.png" [dependencies] [[python.module]] name = "omni.isaac.version"
347
TOML
15.571428
33
0.682997
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.version/omni/isaac/version/version.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import sys import os.path import typing import carb.settings import carb.tokens class Version: def __init__(self): self.core = "" self.prerelease = "" self.major = "" self.minor = "" self.patch = "" self.pretag = "" self.prebuild = "" self.buildtag = "" def parse_version(full_version: Version): parsed_version = Version() if "+" in full_version: full_version, parsed_version.buildtag = full_version.split("+") if "-" in full_version: parsed_version.core, parsed_version.prerelease = full_version.split("-", maxsplit=1) parsed_version.major, parsed_version.minor, parsed_version.patch = parsed_version.core.split(".", maxsplit=2) parsed_version.pretag, parsed_version.prebuild = parsed_version.prerelease.split(".", maxsplit=1) else: parsed_version.major, parsed_version.minor, parsed_version.patch = full_version.split(".", maxsplit=2) parsed_version.core = full_version return parsed_version def get_version() -> typing.Tuple[str, str, str, str, str, str, str, str]: """Retrieve version from file Returns: Core version (str) Pre-release tag and build number (str) Major version (str) Minor version (str) Patch version (str) Pre-release tag (str) Build number (str) Build tag (str) """ app_folder = carb.settings.get_settings().get_as_string("/app/folder") if not app_folder: app_folder = carb.tokens.get_tokens_interface().resolve("${app}") app_start_folder = os.path.normpath(os.path.join(app_folder, os.pardir)) app_version = open(f"{app_start_folder}/VERSION").readline().strip() parsed_version = parse_version(app_version) return ( parsed_version.core, parsed_version.prerelease, parsed_version.major, parsed_version.minor, parsed_version.patch, parsed_version.pretag, parsed_version.prebuild, parsed_version.buildtag, )
2,476
Python
32.931506
117
0.657512
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.version/docs/CHANGELOG.md
# Changelog ## [1.0.0] - 2022-05-12 ### Added - Added first version of version.
82
Markdown
10.857141
33
0.621951
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.franka/omni/isaac/franka/tasks/pick_place.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.isaac.core.tasks as tasks from omni.isaac.franka import Franka from omni.isaac.core.utils.prims import is_prim_path_valid from omni.isaac.core.utils.string import find_unique_string_name from typing import Optional import numpy as np class PickPlace(tasks.PickPlace): """[summary] Args: name (str, optional): [description]. Defaults to "franka_pick_place". cube_initial_position (Optional[np.ndarray], optional): [description]. Defaults to None. cube_initial_orientation (Optional[np.ndarray], optional): [description]. Defaults to None. target_position (Optional[np.ndarray], optional): [description]. Defaults to None. cube_size (Optional[np.ndarray], optional): [description]. Defaults to None. offset (Optional[np.ndarray], optional): [description]. Defaults to None. """ def __init__( self, name: str = "franka_pick_place", cube_initial_position: Optional[np.ndarray] = None, cube_initial_orientation: Optional[np.ndarray] = None, target_position: Optional[np.ndarray] = None, cube_size: Optional[np.ndarray] = None, offset: Optional[np.ndarray] = None, ) -> None: tasks.PickPlace.__init__( self, name=name, cube_initial_position=cube_initial_position, cube_initial_orientation=cube_initial_orientation, target_position=target_position, cube_size=cube_size, offset=offset, ) return def set_robot(self) -> Franka: """[summary] Returns: Franka: [description] """ franka_prim_path = find_unique_string_name( initial_name="/World/Franka", is_unique_fn=lambda x: not is_prim_path_valid(x) ) franka_robot_name = find_unique_string_name( initial_name="my_franka", is_unique_fn=lambda x: not self.scene.object_exists(x) ) return Franka(prim_path=franka_prim_path, name=franka_robot_name)
2,499
Python
39.32258
103
0.654662
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.franka/omni/isaac/franka/tasks/stacking.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # from omni.isaac.core.tasks import Stacking as BaseStacking from omni.isaac.franka import Franka from omni.isaac.core.utils.prims import is_prim_path_valid from omni.isaac.core.utils.string import find_unique_string_name from omni.isaac.core.utils.stage import get_stage_units import numpy as np from typing import Optional class Stacking(BaseStacking): """[summary] Args: name (str, optional): [description]. Defaults to "franka_stacking". target_position (Optional[np.ndarray], optional): [description]. Defaults to None. cube_size (Optional[np.ndarray], optional): [description]. Defaults to None. offset (Optional[np.ndarray], optional): [description]. Defaults to None. """ def __init__( self, name: str = "franka_stacking", target_position: Optional[np.ndarray] = None, cube_size: Optional[np.ndarray] = None, offset: Optional[np.ndarray] = None, ) -> None: if target_position is None: target_position = np.array([0.5, 0.5, 0]) / get_stage_units() BaseStacking.__init__( self, name=name, cube_initial_positions=np.array([[0.3, 0.3, 0.3], [0.3, -0.3, 0.3]]) / get_stage_units(), cube_initial_orientations=None, stack_target_position=target_position, cube_size=cube_size, offset=offset, ) return def set_robot(self) -> Franka: """[summary] Returns: Franka: [description] """ franka_prim_path = find_unique_string_name( initial_name="/World/Franka", is_unique_fn=lambda x: not is_prim_path_valid(x) ) franka_robot_name = find_unique_string_name( initial_name="my_franka", is_unique_fn=lambda x: not self.scene.object_exists(x) ) return Franka(prim_path=franka_prim_path, name=franka_robot_name)
2,379
Python
38.016393
101
0.644388
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.franka/omni/isaac/franka/tasks/follow_target.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.isaac.core.tasks as tasks from omni.isaac.franka import Franka from omni.isaac.core.utils.prims import is_prim_path_valid from omni.isaac.core.utils.string import find_unique_string_name from typing import Optional import numpy as np class FollowTarget(tasks.FollowTarget): """[summary] Args: name (str, optional): [description]. Defaults to "franka_follow_target". target_prim_path (Optional[str], optional): [description]. Defaults to None. target_name (Optional[str], optional): [description]. Defaults to None. target_position (Optional[np.ndarray], optional): [description]. Defaults to None. target_orientation (Optional[np.ndarray], optional): [description]. Defaults to None. offset (Optional[np.ndarray], optional): [description]. Defaults to None. franka_prim_path (Optional[str], optional): [description]. Defaults to None. franka_robot_name (Optional[str], optional): [description]. Defaults to None. """ def __init__( self, name: str = "franka_follow_target", target_prim_path: Optional[str] = None, target_name: Optional[str] = None, target_position: Optional[np.ndarray] = None, target_orientation: Optional[np.ndarray] = None, offset: Optional[np.ndarray] = None, franka_prim_path: Optional[str] = None, franka_robot_name: Optional[str] = None, ) -> None: tasks.FollowTarget.__init__( self, name=name, target_prim_path=target_prim_path, target_name=target_name, target_position=target_position, target_orientation=target_orientation, offset=offset, ) self._franka_prim_path = franka_prim_path self._franka_robot_name = franka_robot_name return def set_robot(self) -> Franka: """[summary] Returns: Franka: [description] """ if self._franka_prim_path is None: self._franka_prim_path = find_unique_string_name( initial_name="/World/Franka", is_unique_fn=lambda x: not is_prim_path_valid(x) ) if self._franka_robot_name is None: self._franka_robot_name = find_unique_string_name( initial_name="my_franka", is_unique_fn=lambda x: not self.scene.object_exists(x) ) return Franka(prim_path=self._franka_prim_path, name=self._franka_robot_name)
2,963
Python
41.342857
97
0.643267
swadaskar/Isaac_Sim_Folder/exts/omni.isaac.franka/omni/isaac/franka/controllers/stacking_controller.py
# Copyright (c) 2021, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and related documentation without an express # license agreement from NVIDIA CORPORATION is strictly prohibited. # import omni.isaac.manipulators.controllers as manipulators_controllers from omni.isaac.franka.controllers import PickPlaceController from omni.isaac.manipulators.grippers.parallel_gripper import ParallelGripper from omni.isaac.core.articulations import Articulation from typing import List class StackingController(manipulators_controllers.StackingController): """[summary] Args: name (str): [description] gripper (ParallelGripper): [description] robot_prim_path (str): [description] picking_order_cube_names (List[str]): [description] robot_observation_name (str): [description] """ def __init__( self, name: str, gripper: ParallelGripper, robot_articulation: Articulation, picking_order_cube_names: List[str], robot_observation_name: str, ) -> None: manipulators_controllers.StackingController.__init__( self, name=name, pick_place_controller=PickPlaceController( name=name + "_pick_place_controller", gripper=gripper, robot_articulation=robot_articulation ), picking_order_cube_names=picking_order_cube_names, robot_observation_name=robot_observation_name, ) return
1,749
Python
37.888888
108
0.691252