0
votes

I am writing a Neural Network code to generate point patterns. In the loss function of my model, I want to use Kest, pcf, and Fest functions available in the spatstat package. if I use Fest as follows

F(r)=(1/m)*sum(1{d(u,x)<=r})

(the above equation is equation 8.33 on page 286 of "Spatial point pattern methodology and application with R" book, where m is the total number of points within the window, u represents pixels inside the window, x represents the points of the point pattern, r is a distance, and d is the minimum distance of a pixel to all the points of the point pattern)

then I cannot get backpropagate because of losing the graph due to comparison (i.e., assigning 1 to d(u,x)<=r). Is it acceptable from the statistical point of view if I write Fest as follows

F(r)=(1/m)*sum(max(r-d,0)) 
1
There is a lot of hidden math here. What is m? What is x? What is u? And what about d in the last equation? Finally, it may be that this question is better suited for the site stats.stackexchange.com - Ege Rubak
@EgeRubak I updated my question to be more clear. Also, should I copy this question to the link that you mentioned? Thanks for your help - Roberto

1 Answers

0
votes

If you change the calculation, then it is not the same function any more.

No, it would not be correct to call the result of this new calculation the "F function".

But does that matter? You want to do a calculation which is loosely based on the definition of the F function but is drastically modified so that the new quantity satisfies some properties that you need. That's fine! You can just call it something else.