Displaying 20 results from an estimated 95 matches for "subfunction".
2001 Jan 18
0
summary/ returning variables from subfunction
Colleagues
----------------------------------
System info:
R version rw1020 on NT
ESS using emacs ver. 20.4
----------------------------------
Below is a summary on returning variable from subfunction, Thanks to
Brian Ripley and Douglas Bates:
To access the variables within a function, return a list or data structure
assigned to a variable in the calling function. For more than one varaible,
assign them to a list variable and separate the components in the calling
function using listname$va...
2009 Nov 10
1
source() vs attach()0
Hello,
After hours of googling I could not resolve the following (although it
seems simple):
I would like to put subfunctions in a separate .R file that is then
called with source() from inside several "main" functions. A crude
example would be as follows:
**** file subtest.R **********
subtest <- function() {
foo <<- foo+1
}
******************************
*** main function ************
test&l...
2010 Feb 26
2
Problem accessing sub-methods of functions stored in a vector
...t;- function(id) {
# MANY VARIABLES DECLARED
list(
set_id = function(newid) {
id <<- newid
},
get_id = function(newid) {
return(id)
},
# LOTS MORE SUB FUNCTIONS
)
}
If I create a variable to hold this function, I can then access all the
subfunctions without problem Example:
myAgent = agent(1)
myAgent$get_id() # Works fine
However, once this function is stored in a vector, I can no longer
access the subfunctions.
agents = c(agent(1), agent(2))
agents[[1]] # This shows the set_id function only, unnamed
agents[[1]]$get_id() # Leads to erro...
2002 Aug 28
1
memdisk possible bug
...the machine. However, if the USB
floppy was not attached to the machine when memdisk would boot the image it
would return with the "Non-system disk or disk error" message.
On further investigation it looks like this could be caused by the mbr on the
dos image calling the drive reset subfunction. It didn't look like this
subfunction was hooked by memdisk and so it is relying on the floppy drive
connected to the machine.
We modified the MBR of the DOS image to skip this drive reset call and are now
able to boot the DOS image without the floppy drive attached to the machine.
I am...
2013 Oct 29
0
[LLVMdev] Loop vectorizer dosen't find loop bounds
----- Original Message -----
> Thanks for the alternatives!
>
> I am trying the 'extracting sub-function' approach. However, it seems
> I
> can't get the 'subfunction' to pass the verifier. This is my
> subfunction:
>
> define void @main_extern([8 x i8]* %arg_ptr) {
> entrypoint:
> %0 = getelementptr [8 x i8]* %arg_ptr, i32 0
> %1 = bitcast [8 x i8]* %0 to i64*
> %2 = load i64* %1
> %3 = getelementptr [8 x i8]* %arg_ptr,...
2013 Oct 29
2
[LLVMdev] Loop vectorizer dosen't find loop bounds
Thanks for the alternatives!
I am trying the 'extracting sub-function' approach. However, it seems I
can't get the 'subfunction' to pass the verifier. This is my subfunction:
define void @main_extern([8 x i8]* %arg_ptr) {
entrypoint:
%0 = getelementptr [8 x i8]* %arg_ptr, i32 0
%1 = bitcast [8 x i8]* %0 to i64*
%2 = load i64* %1
%3 = getelementptr [8 x i8]* %arg_ptr, i32 1
%4 = bitcast [8 x i8]* %3 to i6...
2016 Jul 15
2
[PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
...e reliability[3].
>>
>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>
> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> audio subfunction, and prior to that, the nvidia gpu tended to be the
> only gpu, or hard-muxed.
I'd imagine there is a strap on the asic so the audio function is only
enabled if there is a connector actually wired to the dGPU. It
doesn't make much sense to expose audio if there is no way to use it.
Al...
2011 Sep 12
0
[LLVMdev] multi-threading in llvm
Hi Alexandra,
I don't know much, maybe this topic should be bridged with polly-dev
(adding it to CC) to bring it more attention.
Indeed, polly uses ScopPass, that creates serious limitations in
compatibility with other passes. To my understanding, scops are used
because ISL loop analysis tool uses scops. In fact, just for handling
OpenMP directives scops are not required, unless one need to
2011 Oct 12
2
How to transfer the variable into function in this code?
as shown in the code, four variables input: diff_expr,diff_coex, klist,
Pop_size, are included in the function. However, within the function,
another variable "vector" is utilized in some subfunction. How they get its
value?
thx
get_quantiles <-function(diff_expr,diff_coex,klist,pop_size){
##### The function to get the "node_score_term" and "edge_score_term" of a
sub-network denoted by "vector"
my.fun<-function(vector){
return(diff_coex[vector[1],vector[...
2009 Sep 08
1
optim() argument scoping: passing parameter values into user's subfunction
Dear useRs,
I have a complicated function to be optimized with optim(), and whose
parameters are passed to another function within its evaluation. This
function allows for the parameters to enter as arguments to various
probability distribution functions.
However, I am violating some scoping convention, as somewhere within the
hierarchy of calls a variable is not visible. I will give a
2016 Jul 15
1
[PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
...gt; Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>>
>>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>>> only gpu, or hard-muxed.
>>
>> I'd imagine there is a strap on the asic so the audio function is only
>> enabled if there is a connector actually wired to the dGPU. It
>> doesn't make much sense to exp...
2010 Feb 23
3
Best style to organize code, namespaces
...explicitly. Also there is no enforcement of code isolation
(i.e. anyone can call Foo.subf).
Style 3 is more explicitly object oriented. It has the advantage of
style 2 in that you don't need to pass x around, and the advantage of
style 1 in that you can still write tests and easily debug the
subfunctions. However to actually call the main function you have to
type "Foo(x)$Main()" instead of "Foo(x)", or else write a wrapper
function for this. Either way there is more typing.
So anyway, what is the best way to handle this? R does not seem to
have a good way of managing names...
2011 Sep 08
4
[LLVMdev] multi-threading in llvm
Hi,
I want to execute the iterations of a loop in parallel, by inserting calls either to pthreads or to the gomp library at the LLVM IR level. As a first step, I inserted an omp pragma in a C file and compiled it with llvm-gcc to check the generated LLVM code. If I understand correctly, to parallelize the loop in LLVM IR, I have to separate the loop in a new function, put all required parameters
2016 Jul 15
2
[PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
...liability[3].
> >
> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>
> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> audio subfunction, and prior to that, the nvidia gpu tended to be the
> only gpu, or hard-muxed.
>
> If that's the case, that's pretty much a non-starter, IMO.
For some reason the audio function tends to disappear/hide, so maybe it
is not as problematic as it appears (see
https://bugs.freedesktop....
2005 Aug 30
8
Who can help me?
I have own function wrote. I used an algorithm, which was written in Matlab.
in matlab:
...
gamma = inv(v)*g;
...
#v = matrix of variable size, v=vv(k) => k=2 => dimension of v 2x2
#g = a line vector with 4 elements e.g. g=[1,0,2,0];
my rewritten r-file:
...
gamma = solve(v)*g;
...
which is my error? Who can help me?
thank you in advance.
Chris
--
Lust, ein paar Euro nebenbei zu
2016 Jul 15
0
[PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
...t;>
>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>
>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>> only gpu, or hard-muxed.
>
> I'd imagine there is a strap on the asic so the audio function is only
> enabled if there is a connector actually wired to the dGPU. It
> doesn't make much sense to expose audio if there i...
2007 Apr 18
1
smbclient tar function : no password asked ?
Hello,
We're using samba 3.0.24 on a Linux box, to access and
backup some XP boxes. smbclient access is okay, but
there is something quite weird with the tar
subfunction
-----
$ smbclient //xpbox/Documents -U someuser -d 2 -Tc
/tmp/tarfile .
added interface ip=192.168.1.xxx bcast=192.168.1.255
nmask=255.255.255.0
session setup failed: NT_STATUS_LOGON_FAILURE
-----
Smbclient does NOT ask us for a password when used
that way. We have no problem if giving the passw...
2010 Sep 08
1
Celt 0.7.1 Fixed math
Hi,
I'm using Celt 0.7.1 in fixed math mode. In the celt_encode function, if
the variable has_pitch is true, the function pitch_search is called.
Within this function the find_best_pitch subfunction is called.
Here the variable "float score;" is defined.
Is this right? I was expecting not to see any float declaration in the
fixed math code. Is it possible to redefine it as integer?
Cheers
Riccardo
Riccardo Micci
Senior DSP Engineer, Wireless Group
Cambridge Consultants
Science...
2018 Feb 28
1
[PATCH v2 2/6] PCI: Scan all functions when running over Jailhouse
...&l) &&
> l != 0x0000 && l != 0xffff) {
> DBG("Found device at %02x:%02x [%04x]\n", busn, devfn, l);
Shouldn't that take the situation into account where the MFD bit is set on
a regular devfn, i.e. (devfn % 8) == 0? In that case you'd scan the
subfunctions twice.
Thanks,
tglx
2007 Jul 12
1
sub-function default arguments
...nmArg1=nm1); ... }
it runs okay. If I have nm1 defined outside of f1 and I run "result1<-f2()"
it also runs okay. So f2 doesn't seem to pick up the default argument value
inside the function f1, even when the default argument is defined inside f1.
Is there a way to have the subfunction default arguments recognized inside
of a function (perhaps a better protocol for using defaults than what I
did?), or do I just have to spell them out explicitly?
Thanks!
-- TMK --
212-460-5430 home
917-656-5351 cell