OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
reader
/
hps
/
faces
/
.venv
/
lib
/
python3.10
/
site-packages
/
numpy
/
core
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
10/26/2024 01:26:35 PM
rwxr-xr-x
📄
__init__.py
5.62 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
__init__.pyi
126 bytes
10/26/2024 01:26:25 PM
rw-r--r--
📁
__pycache__
-
10/26/2024 01:27:31 PM
rwxr-xr-x
📄
_add_newdocs.py
204.07 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_add_newdocs_scalars.py
11.8 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_asarray.py
3.91 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_asarray.pyi
1.03 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_dtype.py
10.25 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_dtype_ctypes.py
3.59 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_exceptions.py
8.41 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_internal.py
27.53 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_internal.pyi
1.01 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_machar.py
11.35 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_methods.py
10.81 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_multiarray_tests.cpython-310-darwin.so
145.47 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
_multiarray_umath.cpython-310-darwin.so
3.53 MB
10/26/2024 01:26:24 PM
rw-r--r--
📄
_operand_flag_tests.cpython-310-darwin.so
50.35 KB
10/26/2024 01:26:24 PM
rw-r--r--
📄
_rational_tests.cpython-310-darwin.so
78.49 KB
10/26/2024 01:26:24 PM
rw-r--r--
📄
_simd.cpython-310-darwin.so
362.62 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_string_helpers.py
2.79 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_struct_ufunc_tests.cpython-310-darwin.so
50.66 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_type_aliases.py
7.36 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_type_aliases.pyi
374 bytes
10/26/2024 01:26:25 PM
rw-r--r--
📄
_ufunc_config.py
13.62 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_ufunc_config.pyi
1.04 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
_umath_tests.cpython-310-darwin.so
56.72 KB
10/26/2024 01:26:25 PM
rw-r--r--
📄
arrayprint.py
61.25 KB
10/26/2024 01:26:21 PM
rw-r--r--
📄
arrayprint.pyi
4.32 KB
10/26/2024 01:26:21 PM
rw-r--r--
📄
cversions.py
347 bytes
10/26/2024 01:26:21 PM
rw-r--r--
📄
defchararray.py
71.31 KB
10/26/2024 01:26:21 PM
rw-r--r--
📄
defchararray.pyi
9 KB
10/26/2024 01:26:21 PM
rw-r--r--
📄
einsumfunc.py
50.65 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
einsumfunc.pyi
3.69 KB
10/26/2024 01:26:21 PM
rw-r--r--
📄
fromnumeric.py
122.29 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
fromnumeric.pyi
22.92 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
function_base.py
18.83 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
function_base.pyi
4.61 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
generate_numpy_api.py
7.23 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
getlimits.py
24.31 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
getlimits.pyi
82 bytes
10/26/2024 01:26:22 PM
rw-r--r--
📁
include
-
10/26/2024 01:28:47 PM
rwxr-xr-x
📁
lib
-
10/26/2024 01:28:48 PM
rwxr-xr-x
📄
memmap.py
11.41 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
memmap.pyi
55 bytes
10/26/2024 01:26:22 PM
rw-r--r--
📄
multiarray.py
54.67 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
multiarray.pyi
24.18 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
numeric.py
75.82 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
numeric.pyi
13.9 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
numerictypes.py
16.83 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
numerictypes.pyi
3.31 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
overrides.py
8.11 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
records.py
36.67 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
records.pyi
5.56 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
setup.py
51.13 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
setup_common.py
19.06 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
shape_base.py
29.77 KB
10/26/2024 01:26:22 PM
rw-r--r--
📄
shape_base.pyi
2.71 KB
10/26/2024 01:26:23 PM
rw-r--r--
📁
tests
-
10/26/2024 01:29:54 PM
rwxr-xr-x
📄
umath.py
1.99 KB
10/26/2024 01:26:23 PM
rw-r--r--
📄
umath_tests.py
389 bytes
10/26/2024 01:26:23 PM
rw-r--r--
Editing: _string_helpers.py
Close
""" String-handling utilities to avoid locale-dependence. Used primarily to generate type name aliases. """ # "import string" is costly to import! # Construct the translation tables directly # "A" = chr(65), "a" = chr(97) _all_chars = [chr(_m) for _m in range(256)] _ascii_upper = _all_chars[65:65+26] _ascii_lower = _all_chars[97:97+26] LOWER_TABLE = "".join(_all_chars[:65] + _ascii_lower + _all_chars[65+26:]) UPPER_TABLE = "".join(_all_chars[:97] + _ascii_upper + _all_chars[97+26:]) def english_lower(s): """ Apply English case rules to convert ASCII strings to all lower case. This is an internal utility function to replace calls to str.lower() such that we can avoid changing behavior with changing locales. In particular, Turkish has distinct dotted and dotless variants of the Latin letter "I" in both lowercase and uppercase. Thus, "I".lower() != "i" in a "tr" locale. Parameters ---------- s : str Returns ------- lowered : str Examples -------- >>> from numpy.core.numerictypes import english_lower >>> english_lower('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_') 'abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz0123456789_' >>> english_lower('') '' """ lowered = s.translate(LOWER_TABLE) return lowered def english_upper(s): """ Apply English case rules to convert ASCII strings to all upper case. This is an internal utility function to replace calls to str.upper() such that we can avoid changing behavior with changing locales. In particular, Turkish has distinct dotted and dotless variants of the Latin letter "I" in both lowercase and uppercase. Thus, "i".upper() != "I" in a "tr" locale. Parameters ---------- s : str Returns ------- uppered : str Examples -------- >>> from numpy.core.numerictypes import english_upper >>> english_upper('ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_') 'ABCDEFGHIJKLMNOPQRSTUVWXYZABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_' >>> english_upper('') '' """ uppered = s.translate(UPPER_TABLE) return uppered def english_capitalize(s): """ Apply English case rules to convert the first character of an ASCII string to upper case. This is an internal utility function to replace calls to str.capitalize() such that we can avoid changing behavior with changing locales. Parameters ---------- s : str Returns ------- capitalized : str Examples -------- >>> from numpy.core.numerictypes import english_capitalize >>> english_capitalize('int8') 'Int8' >>> english_capitalize('Int8') 'Int8' >>> english_capitalize('') '' """ if s: return english_upper(s[0]) + s[1:] else: return s