Git Product home page Git Product logo

featuredriven-hawkes's People

Contributors

andrei-rizoiu avatar s-mishra avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

featuredriven-hawkes's Issues

The issue of linear solver being used with ipopt

I just install as ./get ASL, ./getBlas, ./get.Lapack, ./get Metis, ./get Mumps and then

./configure -enable-debug -disable-shared -with-pic

then

make and make install

to success install the package ipoptr.

I really don't know what is the problem of it.

Numerical instability in getTotalEvents?

Hi,

First of all, thank you very much for sharing the code. It really helped me understand the paper. Together with the full derivation of the likelihood in the paper it makes up for a wonderful learning resource for Hawkes Process and its application to social modeling.

However, by running your code I have noticed that the getTotalEvents function is highly sensitive to the precision of the numbers inserted as parameters K, beta, c theta. For example, the parameters we found at the end of the optimization (see in the jupyter notebook), namely K=1.000000, beta=1.015493, c=250.657531, theta=1.338108 produce:

total
    216
nstar
    0.922294642616219
a1
    13.4134242589397

By only forcing the numbers to 3 decimal places, that is K=1.000, beta=1.015, c=250.657, theta=1.338 we get a terrible result:

total
    68
nstar
    0.468240281236122
a1
    13.3638977367008

In other words, by rounding up the number we get a jump in the relative error reaching as high as 68.95%. So, do you have an explanation to this? Is this a property of the objective function or a numerical error in the code? Can you do something to mitigate this problem? Can you please comment on that?

Thank you very much.
Best regards.

The issue of linear solver being used with ipopt

I just put the hsl source code in $IPOPTDIR/ThirdParty/HSL/coinhsl as document of coin.

To compile the HSL code as part of IPOPT, unpack the archive, then move and rename the resulting directory so that it becomes $IPOPTDIR/ThirdParty/HSL/coinhsl. IPOPT may then be configured as normal.

Compile the HSL code as part of IPOPT
then
./configure -enable-debug -disable-shared -with-pic
make
make install

And in Rstudio,

install.packages('/home/spring/Desktop/Ipopt-3.12.8/Ipopt/contrib/RInterface', repos=NULL, type='source')
setwd('/home/spring/Desktop/featuredriven/code')

but when I run the code, still meet the problem R session aborted. I don't know why? Would you mind helping me?

memory not mapped

I run this project as the provided tutorial, but found that there are errors like following:
*** caught segfault ***
address (nil), cause 'memory not mapped'

the detailed process as follows:

source('rscripts/marked_hawkes.R')
Loading required package: ipoptr
real_cascade <- read.csv(file = 'example_book.csv', header = T)
real_cascade[1:10, ]
X magnitude time
1 1 40989 0
2 2 1445 21
3 3 563 31
4 4 329 33
5 5 555 49
6 6 513 54
7 7 28145 58
8 8 100 62
9 9 164 82
10 10 491 87
predTime <- 600

history <- real_cascade[real_cascade$time <= predTime, ]
history <- history[ , 2:3]
oldw <- getOption("warn")
options(warn = -1)
startParams <- c(K= 1,beta=1, c=250, theta= 1)
result <- fitParameters(startParams, history)

*** caught segfault ***
address (nil), cause 'memory not mapped'

Traceback:
1: .Call(IpoptRSolve, ret)
2: ipoptr(x0 = c(K = start$K, beta = start$beta, c = start$c, theta = start$theta), eval_f = neg.log.likelihood, eval_grad_f = closedGradient, eval_g = constraint, eval_jac_g = jacobian, eval_jac_g_structure = list(c(1, 2, 3, 4)), lb = lb, ub = ub, constraint_lb = constraint_lb, constraint_ub = constraint_ub, opts = opts, history = history, kernel.type = kernel.type)
3: fitParameters(startParams, history)

Possible actions:
1: abort (with core dump, if enabled)
2: normal R exit
3: exit R without saving workspace
4: exit R saving workspace
Selection:

Note that I have installed the ipopt, including BLAS, LAPACK, ASL, HSL and MUMPS Linear Solver. Is there anything I missed?
Why this error occurred?

Thank you for your help!

Ipoptr use in R with R session aborted

I success to install ipoptr in Rstudio with Ubuntu14.04. But when I use the function ipoptr to achieve my program, I meet a bug with RstudioR Session Aborted. Then I try to use the r-base to run the program, and get the result as:

result <- fitParameters(startParams, history)

  • caught segfault *

address (nil), cause 'memory not mapped'

Traceback:
1: .Call(IpoptRSolve, ret)
2: ipoptr(x0 = c(K = start$K, beta = start$beta, c = start$c, theta = start$theta), eval_f = neg.log.likelihood, eval_grad_f = closedGradient, eval_g = constraint, eval_jac_g = jacobian, eval_jac_g_structure = list(c(1, 2, 3, 4)), lb = lb, ub = ub, constraint_lb = constraint_lb, constraint_ub = constraint_ub, opts = opts, history = history, kernel.type = kernel.type)
3: fitParameters(startParams, history)
Would you know what is the problem?

how to install ipoptr

I can not find the ipoptr packages, would you mind tell the detail about the install of ipoptr?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.