API: Should NumericIndex([1 2, 3]).dtype be int64 or int32 on 32-bit systems?

This issue has been created since 2022-11-21.

I've had some 32-bit issues while working on removing Int64Index and friends from the code base. One issue that I would appreciate input on the the desired dtype for numeric indexes on 32-bit systems. Currently we have (for 32-bit systems):

>>> from pandas.core.api import Series, NumericIndex
>>> Series([1, 2, 3]).dtype
dtype('int64')
>>> NumericIndex([1, 2, 3]).dtype
dtype('int32')

IMO these two should have the same dtype and because changing Series would break backwards compatability, I'd say that NumericIndex([1, 2, 3]).dtype should be dtype('int64')

Do you agree with me on this, or is there a need for discussion?

Added: BTW, NumericIndex will of course be removed also for pandas 2.0 and numerical functionality included in Index (as we previously have discussed), so the above question is the same as asking if in pandas 2.0 Index([1, 2, 3]).dtype should be int32 or int64 on 32-bit systems.

jreback wrote this answer on 2022-11-21

yes these should match and be 64bit

More Details About Repo
Owner Name pandas-dev
Repo Name pandas
Full Name pandas-dev/pandas
Language Python
Created Date 2010-08-24
Updated Date 2022-12-07
Star Count 36164
Watcher Count 1118
Fork Count 15472
Issue Count 3683

YOU MAY BE INTERESTED

Issue Title Created Date Comment Count Updated Date
CommonQueryOptions StartOrCursor, Rows, etc to long? 2 2021-07-08 2022-11-02
Biosphere updater should work independent of ecoinvent version 0 2022-09-12 2022-09-17
If your hardware is incompatible, your reports won't be even taken a look at. 5 2022-09-14 2022-11-10
Read HC-SR501- infrared detector module 6 2021-10-12 2022-10-27
incorporation with machinaris container 0 2022-02-15 2022-10-08
[BUG] 日志name是一堆可变的数字 0 2021-11-15 2022-11-24
[BUG] jackson-core 版本太低,导致系统错误 2 2021-10-21 2022-11-24
connect skin papilloma as a parent to common warts 2 2022-07-22 2022-11-06
Challenge mode not available 0 2021-03-25 2022-10-03
Build variant in kotlin source-set 2 2022-03-29 2022-08-07
Divide mouse motion by shape scale when dragging points 0 2022-01-10 2022-08-20
Bot detection and node client 2 2020-06-17 2022-11-22
[table] 可选中行(多选)的表格,分页情况下`selectChange`事件的`selectedRowData`值只返回本页数据 5 2022-08-09 2022-08-20
How do I initialize a large set? 1 2020-05-19 2022-11-06
More examples in help/man 1 2022-08-19 2022-11-13
Dependency Dashboard 0 2021-10-18 2022-12-02
[Feature request] Dark Mode for the website 1 2021-05-16 2022-10-23
Official request for Chinese Translation(中文翻译官方请求) 1 2021-05-21 2022-10-23
alicloud is not supported 2 2022-07-06 2022-11-04
Copy a section of text from MS Word to Onlyoffice, some of the whitespace characters are lost. 3 2022-05-20 2022-08-02
Icon request: magnifying-glass-auto 0 2022-06-02 2022-09-03
HP PageWide MFP P57750 1 2022-04-22 2022-11-22
The interplay between Backspace and CtrlH is complex (on Windows) and not documented 3 2021-10-12 2022-11-14
Mantine Modals throw an error when clicking mouse fast 1 2022-09-15 2022-09-29
Detecting or preventing running loop confusion 1 2022-07-05 2022-11-21
ENH: more parameters setting in .buffer() (unit, dissolve, shape preserving option) 1 2022-02-08 2022-10-30
ignore random local modules in .nf-core.yml 1 2022-09-28 2022-09-25
test dynamodb_local_create_table fails 2 2019-02-28 2022-09-27
Change the wording on TLS changes. "Deprecated" is ambiguous 2 2022-05-04 2022-10-20
Sidebar double scrollbar 4 2017-07-14 2022-11-28
ocsp-updater: do query and update work in separate goroutines 0 2021-09-07 2022-11-27
Nemo 5.4.3: horizontal scroll bar interferes with file name at the bottom 0 2022-11-05 2022-11-27
Is the system case sensitive? gpiod 2 2022-07-16 2022-11-13
Flicker during window resize on Windows with DirectComposition WS_EX_NOREDIRECTIONBITMAP 7 2022-10-04 2022-11-03
Tooltips obscure the code I'm working on 10 2022-05-08 2022-10-24
RigidBody2D does not fall when its support point is removed 17 2022-08-25 2022-08-28
Custom ables buttons problem with groups 4 2021-12-29 2022-11-07
Multiple Files Upload -Async/Multiprocessing 2 2022-06-13 2022-11-28
Rework Che-IDEA image to sidecar-less model 2 2021-12-01 2022-11-28
Don't add parentheses to logical operators 0 2022-10-13 2022-11-19
I need help with the Icon. 0 2020-11-24 2022-10-23
Players movements reset when other players move board tokens 25 2021-08-12 2022-11-07
pythonindet.newlineindent not found 2 2022-04-21 2022-11-16
[Feature] Enhancements to HTML reporter 1 2021-10-27 2022-10-10
Update HiveParseCsvIntoTable.pm fix DS issue 0 2021-08-25 2022-08-13
`tf.raw_ops.SegmentMax` Behaves Differently Under CPU and GPU 22 2022-11-07 2022-12-03
Security BC - Authentication Service and local file IAM adapter 1 2021-11-24 2022-09-14
`hsl` and `rgb` functional notation presentation can include `hsla` or `rgba` 0 2021-06-03 2022-11-23
Generated activesupport rbi does not include String#starts_with? & String#ends_with? 1 2021-11-30 2022-11-18
typo in article "Deploying with Git" 2 2022-03-13 2022-10-31