search for: 5e5

Displaying 15 results from an estimated 15 matches for "5e5".

Did you mean: 55
2003 Nov 25
1
64-bit R on Opteron [was Re: Windows R 1.8.0 hangs when M em Usage >1.8GB]
...box). > > Does "could" mean you have verified that it did or is this a > theoretical statement? I.e., have you compiled and tested R on your > dual Opteron? Given my questionable memory of things, this question is very fair. Here's the evidence: > x <- matrix(0, 5e5, 5e5) > x2 <- matrix(0, 5e5, 5e5) > gc() used (Mb) gc trigger (Mb) Ncells 413379 22.1 741108 39.6 Vcells 1783900405 13610.1 1784288128 13613.1 Best, Andy
2003 Nov 25
1
64-bit R on Opteron [was Re: Windows R 1.8.0 hangs when M em Usage >1.8GB]
...box). > > Does "could" mean you have verified that it did or is this a > theoretical statement? I.e., have you compiled and tested R on your > dual Opteron? Given my questionable memory of things, this question is very fair. Here's the evidence: > x <- matrix(0, 5e5, 5e5) > x2 <- matrix(0, 5e5, 5e5) > gc() used (Mb) gc trigger (Mb) Ncells 413379 22.1 741108 39.6 Vcells 1783900405 13610.1 1784288128 13613.1 Best, Andy
2017 Aug 22
1
How to benchmark speed of load/readRDS correctly
Note that if you force a garbage collection each iteration the times are more stable. However, on the average it is faster to let the garbage collector decide when to leap into action. mb_gc <- microbenchmark::microbenchmark(gc(), { x <- as.list(sin(1:5e5)); x <- unlist(x) / cos(1:5e5) ; sum(x) }, times=1000, control=list(order="inorder")) with(mb_gc, plot(time[expr!="gc()"])) with(mb_gc, quantile(1e-6*time[expr!="gc()"], c(0, .5, .75, .9, .95, .99, 1))) # 0% 50% 75% 90% 95% 99%...
2023 Dec 11
1
Partial matching performance in data frame rownames using [
...ot;cg", sprintf("%06d",0:(1e6-1))) d1 <- data.frame(row.names=ids, v=1:(1e6) ) q1 <- sample(ids, 1e6, replace=F) system.time({r <- d1[q1,,drop=F]}) #?? user? system elapsed #? 0.464?? 0.000?? 0.465 # those will hang a long time, I stopped R after 10 minutes q2 <- c(q1[1:5e5], gsub("cg", "ct", q1[(5e5+1):1e6]) ) system.time({r <- d1[q2,,drop=F]}) # same here q3 <- c(q1[1:5e5], rep("FOO",5e5) ) system.time({r <- d1[q3,,drop=F]}) It seems that the penalty of partial matching the non-hits across the whole row name vector is not neg...
2017 Aug 22
0
How to benchmark speed of load/readRDS correctly
...may be due to garbage collection, which happens periodically. E.g., try the following, where the unlist(as.list()) creates a lot of garbage. I get a very large time every 102 or 51 iterations and a moderately large time more often mb <- microbenchmark::microbenchmark({ x <- as.list(sin(1:5e5)); x <- unlist(x) / cos(1:5e5) ; sum(x) }, times=1000) plot(mb$time) quantile(mb$time * 1e-6, c(0, .5, .75, .90, .95, .99, 1)) # 0% 50% 75% 90% 95% 99% 100% # 59.04446 82.15453 102.17522 180.36986 187.52667 233.42062 249.33970 diff(which(mb$time > qua...
2010 May 26
2
segfault on 2.11.0 with large POSIXct vector using as.character
...4-22) install. Seems to crash at around 9e4 ... on OSX and Ubuntu at least. > invisible(as.character(Sys.time()+1:7e4)) > invisible(as.character(Sys.time()+1:8e4)) > invisible(as.character(Sys.time()+1:9e4)) Error: segfault from C stack overflow > invisible(as.character(Sys.time()+1:5e5)) Error: segfault from C stack overflow Thanks, Jeff > sessionInfo() R version 2.11.0 (2010-04-22) x86_64-apple-darwin10.2.0 locale: [1] en_US.UTF-8/en_US.UTF-8/C/C/en_US.UTF-8/en_US.UTF-8 attached base packages: [1] stats graphics grDevices utils datasets methods base > ses...
2013 Aug 16
1
as.Date.character speed improvement suggestion
...)) user system elapsed 0.117 0.019 0.136 > identical(dt1, dt2) [1] TRUE ## Example2: In a "worst case" scenario of a 1,000,002 length character of 1,000,001 unique dates ## the new function is not any slower (within error). > dtch <- format(c(Sys.Date(), Sys.Date()+-5e5:5e5)) > system.time(dt1 <- as.Date.character(dtch)) user system elapsed 20.264 25.584 45.855 > system.time(dt2 <- as.Date.character2(dtch)) user system elapsed 20.525 24.809 45.335 > identical(dt1, dt2) [1] TRUE Alternatively, this logic should be built in to strpti...
2004 May 07
3
re-ordering a vector by name
Dear R-help, Let's say `x1' and `x2' are very long vectors (length=5e5, say) with same set of names but in different order. If I want to sort `x2' in the order of `x1', I would do x2[names(x1)] but the amount of time that takes is quite prohibitive! Does anyone have any suggestion on a more efficient way to do this? If the two vectors are exactly the s...
2017 Aug 22
4
How to benchmark speed of load/readRDS correctly
Dear all I was thinking about efficient reading data into R and tried several ways to test if load(file.Rdata) or readRDS(file.rds) is faster. The files file.Rdata and file.rds contain the same data, the first created with save(d, ' file.Rdata', compress=F) and the second with saveRDS(d, ' file.rds', compress=F). First I used the function microbenchmark() and was a astonished
2010 May 28
2
4 CPU with WinXP on Centos 5.5 KVM?
...with 32bit Windows 2003 (or was it Windows 2008?). I know KVM is granting the 4 CPU's since Linux VM can use 4 CPU's on the same computer. Thanks, Marcelino Marcelino Mata Engineering Technology Specialist Multimatic Technical Centre 85 Valleywood Drive Markham, ON Canada L3R 5E5 Tel.???+1 905 470 0025 ? ? ? CONFIDENTIALITY NOTE: This email (and attachments, if any) contain(s) information that is PRIVATE and CONFIDENTIAL, and may be LEGALLY PRIVILEGED or otherwise exempt from disclosure under applicable law. All copyright is reserved, and no right or license is granted to...
2005 Dec 27
1
No performance increase from dual-core processors?
Hey all, I was planning on getting a new computer for the new year to help with my dissertation research, and recently had an opportunity to compare the performance of my 1.6 GHz Pentium M laptop, and a 2.8 GHz dual-core Pentium processor (both running WinXP professional 32-bit). I run a lot of long simulations, so I was hoping to get something that would speed them up. I ran a few quick
2012 Aug 28
5
return first index for each unique value in a vector
I would like to efficiently find the first index of each unique value in a very large vector. For example, if I have a vector A<-c(9,2,9,5) I would like to return not only the unique values (2,5,9) but also their first indices (2,4,1). I tried using a for loop with which(A==unique(A)[i])[1] to find the first index of each unique value but it is very slow. What I am trying to do is easily
2002 Aug 28
4
Huge data frames?
A friend of mine recently mentioned that he had painlessly imported a data file with 8 columns and 500,000 rows into matlab. When I tried the same thing in R (both Unix and Windows variants) I had little success. The Windows version hung for a very long time, until I eventually more or less ran out of virtual memory; I tried to set the proper memory allocations for the Unix version, but it never
2007 Apr 30
0
[LLVMdev] Boostrap Failure -- Expected Differences?
...) > 5dc: 65 gs > @@ -11991,55 +11991,55 @@ > 5e1: 75 65 jne 648 <.str9+0x8> > ... > > -000005e4 <__FUNCTION__.22989>: > +000005e4 <__FUNCTION__.22896>: > 5e4: 6d insl (%dx),%es:(%edi) > 5e5: 61 popa > - 5e6: 72 6b jb 653 <__FUNCTION__.20708+0x4> > + 5e6: 72 6b jb 653 <__FUNCTION__.20622+0x4> > 5e8: 5f pop %edi > 5e9: 63 6f 6e arpl %bp,0x6e(%edi) > - 5ec: 73 74...
2007 Apr 27
2
[LLVMdev] Boostrap Failure -- Expected Differences?
The saga continues. I've been tracking the interface changes and merging them with the refactoring work I'm doing. I got as far as building stage3 of llvm-gcc but the object files from stage2 and stage3 differ: warning: ./cc1-checksum.o differs warning: ./cc1plus-checksum.o differs (Are the above two ok?) The list below is clearly bad. I think it's every object file in the