Questions tagged [int64]

The int is a datatype that represents an integer and is coded on 64 bits in memory.

int64 is a datatype that represents an (a whole number, not a fraction) and is coded on 64 bits in memory. Unlike its counterpart which is , int64 can be used to store positive and negative integers of values between -263 to 263 - 1.

260 questions
2
votes
3 answers

13 character digit string to number

I have a 13 digit string which is milliseconds since 1/1/1970. I need to convert it to a date time. The first step to do that is to get it into a useable number format. At 13 chars it's beyond the limits of ulong and long which have 10 digits…
2
votes
1 answer

assembly and 64 bit integer - created from pascal(delphi 6)?

I'm beginner in assembly and memory related stuffs. When we have int64 value inside a reg, the mov operator how changes that? I mean it is not a string but integer. Maybe it is silly of me but I do not understand ! for example what this code does?…
hamid
  • 852
  • 11
  • 27
2
votes
3 answers

Read int64 from node.js buffer with precision loss

What would be the best way to read an Int64BE from a node.js buffer into a Number primitive, like readInt32BE reads an Int32? I know that I'll lose precision with numbers +/- 9'007'199'254'740'992, but i won't get such high numbers in the protocol I…
Van Coding
  • 24,244
  • 24
  • 88
  • 132
1
vote
3 answers

_int64 bit field

I need to use a 6-byte (48-bit) bitfield in a structure that I can use as unsigned integer for comparison etc. Something along the following: pack (1) struct my_struct { _int64 var1:48; } s; if (s.var >= 0xaabbccddee) { // do something } But…
cool.2k7
  • 21
  • 1
  • 2
1
vote
2 answers

Inaccurate division of doubles (Visual C++ 2008)

I have some code to convert a time value returned from QueryPerformanceCounter to a double value in milliseconds, as this is more convenient to count with. The function looks like this: double timeGetExactTime() { LARGE_INTEGER…
Adion
  • 579
  • 1
  • 9
  • 21
1
vote
3 answers

Runtime error, makes my .exe crash and I am not sure why

I can take a guess that it has something to do with working with the unsigned long long int. #include #include #include using namespace std; typedef unsigned long long int uint64; int main(int argc, char…
ParoX
  • 5,685
  • 23
  • 81
  • 152
1
vote
2 answers

Issue with converting a pandas column from int64 to datetime64

I'm trying to convert a column of Year values from int64 to datetime64 in pandas. The column currently looks like Year 2003 2003 2003 2003 2003 ... 2021 2021 …
EcoHealthGuy
  • 51
  • 1
  • 1
  • 7
1
vote
1 answer

int64(math.Pow(2, 63) - 1) results in -9223372036854775808 rather than 9223372036854775807

I am trying to store max and min signed ints of different bits. The code works just fine for ints other than int64 package main import ( "fmt" "math" ) func main() { var minInt8 int8 = -128 var maxInt8 int8 = 127 …
1
vote
1 answer

Can cast pandas Series to `int64` but not to `Int64`

I am stuck with a weird type conversion issue.. I fill a pandas column of type 'float' with integer values. Naturally, they are represented as floating-point arithmetic figures, but still "accurate" to int precision. Converting them to int works…
KingOtto
  • 840
  • 5
  • 18
1
vote
1 answer

Int64 variable in Inno Setup

We use some Pascal Scripting in our Inno Setup 5.5.8 and in our Code section are some Integer variables. In this variable we store the actual date and time in this format: YYMMDDhhmm. Since the year 2022 the value is too big for an Integer. Is there…
ingolf
  • 13
  • 2
1
vote
1 answer

Save memory with big pandas dataframe

I have got a huge dataframe (pandas): 42 columns, 19 millions rows and different dtypes. I load this dataframe from a csv file to JupyterLab. Afterwards I do some operations on it (adding more colums) and I write it back to a csv file. A lot of the…
Bsleon
  • 135
  • 6
1
vote
2 answers

how to left-bitshift a char with an arbitrary value to produce a 64-bit integer?

I'm writing a function that would compute CRC *value for a string. ( * arbitrary width of 8-64 ). The function accepts 9 parameters, but to illustrate the problem with left-bitshifting, I'm posting only a snippet. void leftshift(unsigned char* str,…
SKAN
  • 66
  • 4
1
vote
0 answers

Python: How to to print a for loop with multiple arguments for a numpy.int64?

I want to print the samples from the classification that has been labeled wrong. I found this code from Sklearn SVM - how to get a list of the wrong predictions? for idx, input, prediction, label in zip(enumerate(X_test), X_test, predicted,…
JFFO
  • 11
  • 2
1
vote
1 answer

np.int64 behaves differently from int in math-operations

I have come across a very strange problem where i do a lot of math and the result is inf or nan when my input is of type , but i get the correct (checked analytically) results when my input is of type . The only…
1
vote
1 answer

How to work with big numbers (int64 / bigInt) in Google App Script?

As you can see below, in all the cases the number is shown wrong: var a = 714205074837649919; console.log(a); //>> 7.1420507483764992E17 console.log(parseInt(a)); //>> 7.1420507483764992E17 console.log(parseInt(a).toString()); //>>…
Bruno Yuzo
  • 469
  • 5
  • 18