similar to: Time-measurement in milliseconds

Displaying 20 results from an estimated 1000 matches similar to: "Time-measurement in milliseconds"

2005 Nov 07
3
R thread safe
Dear R-dev, I would like to accelerate my R computation by using parallel OpenMP compilers (e.g from Pathscale) on a 2-processor AMD server and I would like to know whether R is a tread safe library. The main kernel of the OpenMP parallelization is a C SEXP function that performs the computational routine in parallel with: ******************* SEXP example(SEXP list, SEXP expr, SEXP rho) {
2015 Apr 10
4
[LLVMdev] Optimization on Atomics (and the OpenMP memory model)
Hi everyone, The OpenMP standards committee has begun work to formalize their memory model, and define its relationship to the C/C++ memory models. A questionnaire has been put together (pasted below), and I'd like everyone's help in composing detailed answers to inform their decision-making process. While our OpenMP support is still in active development, many of these questions apply
2016 May 20
2
identical on closures
I'm confused by this: > identical(function() {}, function() {}) [1] FALSE Yet, after loading the Matrix package (which redefines det), the following is checked (in library.checkConflicts): > identical(get("det", baseenv()), get("det", asNamespace("Matrix")), ignore.environment=T) [1] TRUE I've looked at the code in identical.c and for closures it
2014 Jun 24
2
using C code to create data frame but always return as list
there is my code,  expect return value  is a data frame but R say it is list: SEXP Julia_R_MD_NA_DataFrame(jl_value_t* Var) {  SEXP ans,names,rownames;  char evalcmd[4096];  int i;  const char* dfname="DataFrameName0tmp";  jl_set_global(jl_main_module, jl_symbol(dfname), (jl_value_t*)Var);  //Get Frame cols   sprintf(evalcmd,"size(%s,2)",dfname);  jl_value_t*
2020 Jan 09
6
Get memory address of an R data frame
Hello, I would like for my C function to be able to manipulate some values stored in an R data frame. To achieve this, a need the (real) memory address where the R data frame stores its data (hopefully in a contiguous way). Then, from R, I call the C function and passing this memory address as a parameter. The question: how can we get the memory address of the R data frame? Thank you! L.
2009 Mar 30
1
Setting the names attribute of a list?
Hello, I have created a vector with 2 elements(see code below) I am calling this function many thousands of times (hundreds of thousands) after some time i get *** caught segfault *** address 0x5, cause 'memory not mapped' However, if i dont set the R_NamesSymbol, I do not get any such error. Am I doing this correctly? Thank you Saptarshi ==CODE=== // kxp and usar are two SEXP's
2006 Nov 17
1
Manipulating R lists in C
Hi, I have been studying the R manual on lists but cannot seem to create a simple R list in C - I keep on getting "'dimnames' applied to non-array" whenever I attempt to assign names to the list elements: Wanted output a list structure something like [ type="Bid", price=2.0, volume=1000 ] I can get up to a list of [ "Bid2, 2.0, 1000 ] But for the life of
2005 Nov 21
3
PNG-import into R
Hi there I'm looking for a function to read PNG-bitmap-images from a file into R. I only found: - the pixmap-package which cannot import png or similar formats - the rimage-package which can only import lossy jpeg-images (the convertion from png to jpeg modifies the data!) Is there any possibility to read PNG-files? Thanks for any help Dominic Sydler
2006 Mar 27
1
Safe to UNPROTECT() when object is assigned to a list?
Hi, I'm troubleshooting some native code on Windows that very occationally (and semi-randomly) crashes R. Already looked at "everything", I just want to double check that it is safe to UNPROTECT() allocated variables as soon as they are assigned to, say, a PROTECTed list. >From (R v2.3.0) Section 5.7.1 "Handling the effects of garbage collection" in "Writing R
2014 Mar 06
1
Create dataframe in C from table and return to R
Hi , I am trying to create a dataframe in C and sebd it back to R. Can anyone point me to the part of the source code where it is doing , let me explain the problem I am having . -------------------------------------------------------------------- My simple implementation is like this SEXP formDF() { SEXP dfm ,df , dfint , dfStr,lsnm; char *ab[3] =
2003 May 09
4
getAttr problem
Hi all, It seems that getAttr doesn't return "names" attribute properly as in getAttrib(x, R_NamesSymbol)); If you look at section 4.7.4 in "Writing R Extensions", the second example of SEXP out(SEXP, SEXP) returns NULL for the names attribute of the outer product. This is true for R 1.7.0 on both Win2000 with mingw and Redhat 9.0 with gcc. Is there something I am
2009 Jan 05
1
can't get names of R_env
Hi, I'm quite knew in R, so I might not have the R specific jargon. But here is my problem, I'm trying to access and use variabels given by a function environment, more specifically the rho in do_optim in src/main/optim.c According to the documentation http://cran.r-project.org/doc/manuals/R-ints.html#The-_0027data_0027 the envsxp is defined as a tagged pairlist. "ENVSXP: Pointers
2014 Apr 03
1
question regarding lang2 command in C
Hi , I am asking too many questions , sorry for that . I am creating a data frame in C itself , reading a table . The data frame calling code looks like this ====================================== *PROTECT(dfm=lang2(install("data.frame"),df));* *SEXP res = PROTECT(eval(dfm,R_GlobalEnv));* UNPROTECT(2); return res; ================================== It works fine , now the problem
2011 Aug 13
1
Latent flaw in SEXPREC definition
There seems to be a latent flaw in the definition of struct SEXPREC in Rinternals.h, which likely doesn't cause problems now, but could if the relative sizes of data types changes. The SEXPREC structure contains a union that includes a primsxp, symsxp, etc, but not a vecsxp. However, in allocVector in memory.c, zero-length vectors are allocated using allocSExpNonCons, which appears to
2013 Apr 01
2
Timing of SET_VECTOR_ELT
Assume a C program invoked by .Call, that returns a list. Near the top of the program we allocate space for all the list elements. (It is my habit to use "xyz2" for the name of the R object and "xyz" for the pointer to its contents.) PROTECT(means2 = allocVector(REALSXP, nvar)); means = REAL(means2); PROTECT(u2 = allocVector(REALSXP, nvar)); u =
2013 Jul 05
1
Get the tail of a list in C
Hi, I am write R extensions in C. Now I have a VECSXP variable, so how can I get the tail of it (all but the first one) as a new VECSXP. I tried CDR(), but it gives error. Thanks. -- View this message in context: http://r.789695.n4.nabble.com/Get-the-tail-of-a-list-in-C-tp4670900.html Sent from the R devel mailing list archive at Nabble.com.
2006 Nov 17
2
Data table in C
After getting one list done, I am now struggling to form a data frame in C. I tried to do a list of lists which gives me : $<NA> $<NA>[[1]] [1] "BID" $<NA>[[2]] [1] 0.6718 $<NA>[[3]] [1] 3e+06 $<NA> $<NA>[[1]] [1] "BID" $<NA>[[2]] [1] 0.6717 $<NA>[[3]] [1] 5e+06 $<NA> $<NA>[[1]] [1] "BID"
2014 Jun 26
1
using 2D array of SEXP for creating dataframe
Hi , For our production package i need to create a dataframein C . So I wrote the following code SEXP dfm ,head,df , dfint , dfStr,lsnm; *SEXP valueVector[2];* char *ab[3] = {"aa","vv","gy"}; int sn[3] ={99,89,12}; char *listnames[2] = {"int","string"}; int i,j; //============================= PROTECT(df = allocVector(VECSXP,2));
2003 Sep 05
1
Problem with S4 slots in C code (PR#4073)
This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. ------_=_NextPart_000_01C3738F.63DE3390 Content-Type: text/plain; charset="iso-8859-1" #I want to be able to create a new S4 class and read data into it using C code # Here is a very simple S4 object inheriting from "array", but with 5
2013 Nov 29
1
Self heal problem
Hi, I have a glusterfs volume replicated on three nodes. I am planing to use the volume as storage for vMware ESXi machines using NFS. The reason for using tree nodes is to be able to configure Quorum and avoid split-brains. However, during my initial testing when intentionally and gracefully restart the node "ned", a split-brain/self-heal error occurred. The log on "todd"