trace

Error in df(X0) : argument “df1” is missing, with no default--tracing R code

末鹿安然 提交于 2020-01-03 06:19:12
问题 I have written two gradient descent functions and in the second one I just have the alpha parameter and the initial alpha is different. I receive a weird error and was unable to trace the reason for it. Here's the code: k=19000 rho.prime<-function(t,k) ifelse (abs(t)<=k,2*t,(2*k*sign(t))) dMMSE <- function(b,k=19000, y=farmland$farm, x=farmland$land){ n = length(y) a=0 d=0 for (i in 1:n) { a = a + rho.prime(y[i]-b[1]-b[2]*x[i],k) d = d + x[i]*rho.prime(y[i]-b[1]-b[2]*x[i],k) } a <- (-a/n) d <

trace oracle statements

风格不统一 提交于 2020-01-03 03:31:11
问题 I'm developing an app using Oracle database and I would surely like to have an SQL statements tracer that could trace sessions and processes statements - like Toad's SQL Tracker/Monitor. But since the good one cost alot of money I'm thinking about building a small one myself. Any ideeas about wich would be the best solution for tracing oracle sql statements? 回答1: Sql Plus + tkprof. alter session set timed_statistics = true; alter session set sql_trace = true; show parameter user_dump_dest

can't write into log file using TraceSource Method in C#

守給你的承諾、 提交于 2020-01-02 11:21:12
问题 I am using the following code to log the exception, but it's not writing any logs into the file " mylistener.log ". What am I missing here? using System; using System.Diagnostics; namespace TraceSourceApp { class Program { private static TraceSource mySource = new TraceSource("TraceSourceApp"); static void Main(string[] args) { TextWriterTraceListener textListener = new TextWriterTraceListener("myListener.log"); mySource.Listeners.Add(textListener); int i = 10, j = 0, k; try { k = i / j; }

Tracing pthread scheduling

≯℡__Kan透↙ 提交于 2020-01-01 04:22:09
问题 What I want to do is create some kind of graph detailing the execution of (two) threads in Linux. I don't need to see what the threads do, just when they are scheduled and for how long, a time line basically. I've spend the last few hours searching the internet for a way to trace the scheduling of pthreads. Unfortunately, the two projects I found require either kernel recompilation (LTTng) or glibc patching (NPTL Trace Tool), both of which I can not do (large, centrally managed system, on

How can I use the same callback function to trace multiple variables?

被刻印的时光 ゝ 提交于 2019-12-31 05:18:06
问题 I would like to display the value of several StringVar() with some formatting on Labels. import tkinter as tk keys = range(2) # 2 for simplicity root = tk.Tk() myVars = {key: tk.StringVar() for key in range(5)} myStrVars = {key: tk.StringVar() for key in range(5)} def callback0(*args): blah = '{0:.3f}'.format(float(myVars[0].get())) myStrVars[0].set(blah) def callback1(*args): blah = '{0:.3f}'.format(float(myVars[1].get())) myStrVars[1].set(blah) #etc... myCallbacks = {0: callback0, 1:

WinDbg — TraceListener and Saturated ThreadPool

核能气质少年 提交于 2019-12-31 05:11:11
问题 I have a multithreaded .NET Windows Service that hangs intermittently -- maybe once every two weeks of 24/7 operation. When the hangs occurs the threadpool is completely saturated because calls to our custom tracelistener start blocking for some reason. There aren't any locks in the offending code nor anything blocking according to windbg, but they're definitely blocking somewhere. There aren't any exceptions on the stack either. There is a Thread.Sleep(1) that will occasionally be hit in the

How to intercept debugging information ( Debugview style ) in C#?

☆樱花仙子☆ 提交于 2019-12-31 02:14:11
问题 For testing purposes I'm planning to put together a little app that will listen for a particular event coming from an application and interact with it at that point. Given that we're at a point in the testing process where changing the application code is out of the question, the ideal from my point of view would be to listen to the debugging trace from the application, a little like debugview does, and respond to that. Can anyone offer guidance on how best to go about this? 回答1: The way I

Automatic tracing of program execution

三世轮回 提交于 2019-12-30 08:39:15
问题 I would like to know if we can enable tracing in any C or C++ application. For example, with a gcc option or a small tool, I will enable trace and either trace is printed on console or dumped to a file. Since there are lots of files and function / classes, I don't want to start adding the trace prints manually. If such tools are not available, next choice is use scripting and try to add at the trace printing. strace is not much useful as it gives mainly the system calls. 回答1: To trace the

WCF Tracing. How I can get the exact reason for closing connection?

久未见 提交于 2019-12-30 04:10:10
问题 In my WCF service, when trying transfer large data I constantly get an error: The underlying connection was closed: The connection was closed unexpectedly I want to know what particular reason invokes this error, so I set up WCF Tracing and can read traces.svclog file. The problem is, that I can see in this file a lot of information about flow of processes, I can see exact time when exception is appeared, but I can't see the exact reason for that. Is it due to MaxReceivedMessageSize or

Trace logs location, where to view them

元气小坏坏 提交于 2019-12-28 05:53:13
问题 Where do you see Trace.Write(""); logs while developing an MVC or WCF app? What is the correct place to look at? 回答1: When using the System.Diagnostics.Trace class, the Write method writes its trace output "to the trace listeners in the Listeners collection." The Trace.Listeners property by default only contains an instance of the DefaultTraceListener, which outputs messages to the debugger output window. To view those trace messages, you have to enable debugging, of course. So if you debug