Home
last modified time | relevance | path

Searched refs:str (Results 1 – 25 of 314) sorted by relevance

12345678910>>...13

/petsc/src/binding/petsc4py/src/petsc4py/lib/
H A D__init__.pyi4 def ImportPETSc(arch: str | None = ...) -> ModuleType: ...
5 def getPathArchPETSc(arch: str | None = ...) -> tuple[str, str]: ...
8 def Import(pkg: str, name: str, path: str, arch: str) -> ModuleType: ...
9 def getPathArch(path: str, arch: str, rcvar: str = ..., rcfile: str = ...) -> tuple[str, str]: ...
10 def getInitArgs(args: str | list[str] | None) -> list[str]: ...
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/classes/
H A D_diag.py29 def _fuzzy_get_attribute(self, in_diags: dict[str, str], in_attr: str) -> tuple[bool, str]: argument
39 def __getattr__(self, attr: str) -> str: argument
42 return TYPE_CAST(str, getattr(diag_map, attr))
62 _diags: dict[str, dict[str, str]]
65 def _sanitize_input(input_it: Iterable[str]) -> dict[str, str]: argument
72 def __getattr__(self, attr: str) -> str: argument
110 def update(self, obj: Any, other: Iterable[str], **kwargs) -> None: argument
124 _registered: dict[str, str] = {}
126 disabled: set[str]
127 flagprefix: str
[all …]
H A D_cursor.py131 name: str
132 typename: str
133 derivedtypename: str
171 def __getattr__(self, attr: str) -> Any: argument
180 def __str__(self) -> str:
248 def error_view_from_cursor(cls, cursor: CursorLike) -> str:
273 def get_name_from_cursor(cls, cursor: CursorLike) -> str:
289 def cls_get_name_from_cursor_safe_call(cursor: CursorLike) -> str:
362 return TYPE_CAST(str, cursor.spelling)
377 def get_raw_name_from_cursor(cls, cursor: CursorLike) -> str:
[all …]
H A D_util.py39 def view(self, *args) -> str:
43 return ' '*self+' '.join(map(str, args))
56 def fully_qualify(t: clx.Type) -> list[str]:
63 def view_type(t: clx.Type, level: IndentLevel, title: str) -> list[str]: argument
67 ret_list = [level.view(title, str(t.kind), ' '.join(fully_qualify(t)))]
72 …] = verbose_print, level: IndentLevel = IndentLevel(), max_depth: int = -1, **kwargs) -> list[str]:
76 ret_list: list[str] = []
95 def read_file_lines_cached(*args, **kwargs) -> list[str]:
97 ret: list[str] = fd.readlines()
100 … num_after_context: int = 0, num_context: int = 0, trim: bool = False, tight: bool = False) -> str:
[all …]
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/
H A Dpkg_consistency_checks.py10 def assert_py_versions_match(config_file: str, toml_data: dict[str, Any]) -> None: argument
13 def tuplify_version_str(version_str: str) -> tuple[int, int, int]: argument
14 assert isinstance(version_str, str)
31 def assert_version_match(tool_name: str, version_str: str) -> None: argument
42 assert_version_match('vermin', str(toml_data['vermin']['targets']))
45 def assert_requirements_match(toml_file: str, toml_data: dict[str, Any], req_file: str, req_lines: … argument
54 def load_toml_data(toml_path: str) -> dict[str, Any]: argument
72 toml_data: dict[str, Any] = tomllib.load(fd)
75 def load_requirements_data(req_path: str) -> list[str]: argument
76 ret: list[str] = []
[all …]
H A Dtest_main.py30 shutil.copy2(str(self.fname), str(self.temp_path))
80 def test(generated_output: list[str], reference_file: Path) -> str: argument
91 fromfile=str(short_ref_name), tofile='Generated Output', n=0
96 def sanitize_output_file(text: Optional[str]) -> list[str]: argument
97 return [] if text is None else [l.replace(str(petsc_dir), '.') for l in text.splitlines(True)]
99 def sanitize_patch_file(text: Optional[str]) -> list[str]: argument
103 def rename_patch_file_target(text: str, new_path: Path) -> str: argument
106 lines[0] = lines[0].replace(out_file, str(new_path))
107 lines[1] = lines[1].replace(out_file, str(new_path))
H A Dqueue_main.py27 def __init__(self, filename: str, *args, **kwargs) -> None: argument
33 def __handle_error(error_prefix: str, filename: str, error_queue: ParallelPool.ErrorQueueType, file… argument
47 send_exception_trace = str(send_e) + '\n\n' + str(send_e2)
84 raise MainLoopError(str(filename)) from exc
91 _print_prefix: str
94 def __init__(self, verbose: bool, print_prefix: str, lock: ParallelPool.LockType) -> None: argument
136 updated_check_function_map: dict[str, FunctionChecker], argument
137 updated_classid_map: dict[str, str], argument
139 compiler_flags: list[str], argument
190 __handle_error(error_prefix, str(filename), error_queue, file_queue, base_e)
/petsc/lib/petsc/bin/maint/
H A Dcheck_header_guard.py20 __version_str__ = '.'.join(map(str, __version__))
35 def _strip_empty_lines(self, idx: int, ret: list[str]) -> list[str]: argument
57 def prologue(self, ret: Sequence[str]) -> list[str]: argument
73 def replace(self, last_line: str, line: str, ret: list[str]) -> list[str]: argument
77 def epilogue(self, last_endif: int, ret: list[str]) -> list[str]: argument
95 def prologue(self, ret: list[str]) -> list[str]: argument
98 def replace(self, prev_line: str, line: str, ret: list[str]) -> list[str]: argument
141 def epilogue(self, last_endif: int, ret: list[str]) -> list[str]: argument
172 new_ifndef: str
173 new_guard: str
[all …]
/petsc/config/BuildSystem/
H A Dnargs.py123 return 'Empty '+str(self.__class__)
126 return str(list(map(str, value)))
127 return str(value)
141 raise KeyError('Could not find value for key '+str(self.key))
146 if isinstance(self.deprecated, str):
175 raise TypeError('Invalid boolean value: '+str(value)+' for key '+str(self.key))
192 return str(value)
196 return 'Empty '+str(self.__class__)
198 return str(map(self.valueName, self.value))
217 raise TypeError('Invalid fuzzy boolean value: '+str(value)+' for key '+str(self.key))
[all …]
H A DRDict.py106 self.writeLogLine('SERVER: Last access '+str(self.lastAccess))
142 …self.logFile.write('('+str(os.getpid())+')('+str(id(self))+')'+message+' ['+time.asctime(time.loca…
157 self.writeLogLine('getType: Getting local type for '+key+' '+str(value))
189 self.writeLogLine('__getitem__: Parent had invalid entry: '+str(e))
192 self.writeLogLine('__getitem__: Setting parent value '+str(value))
217 …print('Warning! Incorrect argument type specified: -'+str(key)+'='+str(v.getValue())+' - expecting…
234 self.writeLogLine('__setitem__: Set value for '+key+' to '+str(dict.__getitem__(self, key)))
337 if isinstance(args[key], str):
342 elif isinstance(args, str):
365 …riteLogLine('CLIENT: Exception during server address determination: '+str(e.__class__)+': '+str(e))
[all …]
H A DsourceDatabase.py49 self.filename = os.path.join(str(root), 'bsSource.db')
58 output += ' Checksum: '+str(checksum)+'\n'
59 output += ' Mod Time: '+str(mtime)+'\n'
60 output += ' Timestamp: '+str(timestamp)+'\n'
61 output += ' Deps: '+str(dependencies)+'\n'
77 root = str(self.root)
87 raise ValueError('Source database values must be tuples, '+str(type(value))+' given')
89 raise ValueError('Source database values must have 4 items, '+str(len(value))+' given')
91 if not isinstance(checksum, str):
92 raise ValueError('Invalid checksum for source database, '+str(type(checksum))+' given')
[all …]
/petsc/share/petsc/matlab/
H A DPetscReadBinaryMatlab.m21 str=fgets(fid);
22 while (ischar(str))
25 …if strncmp(str,matlabHeader(1,:),matlabHeaderLen) || strncmp(str,matlabHeader(2,:),matlabHeaderLen)
26 str = str(1+matlabHeaderLen:end); variable
29 if strfind(str,'fopen(Set.filename')
30 str = 'fd = PetscOpenFile(Set.filename);'; variable
31 elseif strfind(str,'if (fd < 0) error'); % ignore this line
32 str = '%'; variable
33 elseif strfind(str,'fclose(fd)');
34 str = 'close(fd);'; variable
[all …]
/petsc/src/binding/petsc4py/src/petsc4py/
H A D__init__.pyi4 __version__: str = ...
5 def init(args: Union[str, list[str]] | None = ..., arch: str | None = ..., comm: Intracomm | None =…
6 def get_include() -> str: ...
7 def get_config() -> dict[str, str]: ...
/petsc/src/sys/utils/
H A Dpdisplay.c35 char *str, work[256]; in PetscOptionsGetenv() local
58 str = getenv(name); in PetscOptionsGetenv()
59 if (str) flg = PETSC_TRUE; in PetscOptionsGetenv()
60 if (str && env) PetscCall(PetscStrncpy(env, str, len)); in PetscOptionsGetenv()
104 const char *str; in PetscSetDisplay() local
115 str = getenv("DISPLAY"); in PetscSetDisplay()
116 if (!str) str = ":0.0"; in PetscSetDisplay()
126 str = ":15"; in PetscSetDisplay()
129 if (str[0] != ':' || singlehost) { in PetscSetDisplay()
130 PetscCall(PetscStrncpy(display, str, sizeof(display))); in PetscSetDisplay()
[all …]
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/classes/docs/
H A D_doc_section_base.py30 text: str
31 prefix: str
32 arg: str
33 description: str
34 sep: str
35 expected_sep: str
37 …def __init__(self, raw: str, prefixes: Optional[Sequence[str]] = None, expected_sep: str = '-') ->… argument
70 assert isinstance(descr, str)
80 def split_param(text: str, prefixes: Sequence[str], sep: str) -> tuple[str, str, str]: argument
164 __slots__: tuple[str, ...] = tuple()
[all …]
H A D_doc_str.py67 def __str__(self) -> str:
74 str.casefold,
107 _sections: dict[str, SectionBase]
108 _cachekey: tuple[str, ...]
109 _findcache: dict[tuple[str, ...], dict[str, str]]
134 def __getattr__(self, attr: str) -> SectionBase: argument
188 def find(self, heading: str, cache_result: bool = True, strict: bool = False) -> SectionBase: argument
307 def gen_titles(self) -> Generator[str, None, None]:
322 def is_heading(self, line: str, prev_line: str) -> Verdict: argument
337 def handle_header_with_colon(text: str) -> Verdict: argument
[all …]
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/util/
H A D_utility.py22 def traceback_format_exception(exc: ExceptionKind) -> list[str]:
77 def subprocess_capture_output(*args, **kwargs) -> subprocess.CompletedProcess[str]:
144 clxconf.set_library_file(str(clang_lib))
147 clxconf.set_library_path(str(clang_dir))
190 def get_petsc_extra_includes(petsc_dir: Path, petsc_arch: str) -> list[str]: argument
220 def split_and_strip(line: str) -> list[str]: argument
231 def filter_flags(flags: list[str], keep_prefix: str) -> Iterable[str]: argument
238 seen: set[str] = set()
244 def get_clang_sys_includes() -> list[str]:
262 …lags(petsc_dir: Path, petsc_arch: str, extra_compiler_flags: Optional[list[str]] = None, verbose: … argument
[all …]
H A D_color.py10 __COLOR_BRIGHT_RED__: str = colorama.Fore.RED + colorama.Style.BRIGHT
11 __COLOR_BRIGHT_YELLOW__: str = colorama.Fore.YELLOW + colorama.Style.BRIGHT
12 __COLOR_RESET__: str = colorama.Style.RESET_ALL
19 def bright_red(cls) -> str:
30 def bright_yellow(cls) -> str:
41 def reset(cls) -> str:
/petsc/doc/ext/
H A Dhtml5_petsc.py87 def _get_manpage_map(self) -> Dict[str,str]:
100 def _add_manpage_links(self, string: str) -> str: argument
196 def htmlmap_to_dict(htmlmap_filename: str) -> Dict[str,str]: argument
212 def dict_complete_links(string_to_link: Dict[str,str], prefix: str = '') -> Dict[str,str]: argument
216 def link_string(name: str, link: str, prefix: str) -> str: argument
/petsc/src/sys/fileio/
H A Dmprint.c175 PetscErrorCode PetscVSNPrintf(char str[], size_t len, const char format[], size_t *fullLength, va_l… in PetscVSNPrintf() argument
192 flen = vsnprintf(str, len, newformat, Argp); in PetscVSNPrintf()
200 PetscCall(PetscStrlen(str, &leng)); in PetscVSNPrintf()
203 if (str[cnt] == '[' && str[cnt + 1] == '|') { in PetscVSNPrintf()
209 if (str[cnt] == '|' && str[cnt + 1] == ']') { in PetscVSNPrintf()
211 if (!foundedot) str[ncnt++] = '.'; in PetscVSNPrintf()
215 if (str[cnt] == 'e' || str[cnt] == '.') foundedot = PETSC_TRUE; in PetscVSNPrintf()
216 str[ncnt++] = str[cnt]; in PetscVSNPrintf()
220 str[ncnt] = str[cnt]; in PetscVSNPrintf()
225 str[ncnt] = str[cnt]; in PetscVSNPrintf()
[all …]
/petsc/src/sys/classes/viewer/impls/ascii/ftn-custom/
H A Dzfilevf.c29 PETSC_EXTERN void petscviewerasciiprintf_(PetscViewer *viewer, char *str, PetscErrorCode *ierr, PET… in petscviewerasciiprintf_() argument
35 FIXCHAR(str, len1, c1); in petscviewerasciiprintf_()
38 FREECHAR(str, c1); in petscviewerasciiprintf_()
44 PETSC_EXTERN void petscviewerasciisynchronizedprintf_(PetscViewer *viewer, char *str, PetscErrorCod… in petscviewerasciisynchronizedprintf_() argument
50 FIXCHAR(str, len1, c1); in petscviewerasciisynchronizedprintf_()
53 FREECHAR(str, c1); in petscviewerasciisynchronizedprintf_()
/petsc/doc/
H A Dfix_pydata_margins.py11 str = source.read()
12str = str.replace('var(--pst-font-size-h2)}','var(--pst-font-size-h2);margin-bottom:4px;margin-top…
14 target.write(str)
H A Dfix_man_page_edit_links.py13 str = f.read()
14 m = re.findall(EDIT_URL_PATTERN, str)
19 str = re.sub(SHOW_SOURCE_PATTERN,'',str)
23 for line in str.split('\n'):
/petsc/src/sys/classes/viewer/impls/string/ftn-custom/
H A Dzstringvf.c14 PETSC_EXTERN void petscviewerstringopen_(MPI_Comm *comm, char *name, PetscViewer *str, PetscErrorCo… in petscviewerstringopen_() argument
16 PETSC_FORTRAN_OBJECT_CREATE(str); in petscviewerstringopen_()
17 *ierr = PetscViewerStringOpen(MPI_Comm_f2c(*(MPI_Fint *)&*comm), name, len1, str); in petscviewerstringopen_()
20 PETSC_EXTERN void petscviewerstringsetstring_(PetscViewer *str, char *name, PetscErrorCode *ierr, P… in petscviewerstringsetstring_() argument
22 PetscViewer v_a = PetscPatchDefaultViewers(str); in petscviewerstringsetstring_()
/petsc/lib/petsc/bin/maint/petsclinter/petsclinter/checks/
H A D_register.py15 classid_map: dict[str, str] = {}
16 check_function_map: dict[str, FunctionChecker] = {}
19 def filter_check_function_map(allowed_symbol_names: Collection[str]) -> None: argument
49 def register_classid(struct_name: str, classid_name: str, exist_ok: bool = False) -> None: argument
69 def register_symbol_check(name: str, function: FunctionChecker, exist_ok: bool = False) -> None: argument

12345678910>>...13