## Understanding CR calculations

I’ve been working on a tool to help me design monsters, specifically doing CR calculations as described in the DMG. In order to test it, I’ve tried it out on some monsters in the Monster Manual, which of course are giving me different results.

I just want to say up front that I’m fully aware that the DMG method doesn’t align with what’s actually in the MM, and that a different calculation was used for it. And for my purposes that’s ok, but it does make testing it rather difficult. I also understand that playtesting can influence the CR.

So what I want to check is: For these 3 test monsters, is my calculation correct, or have I overlooked something? And if it is correct, is there any widely accepted or documented reason for these monsters specifically to have different CRs?

### Wolf (MM CR: 1/4, calculated CR: 1/2)

HP: 11
AC: 13
Damage per round: 7
Attack bonus: 4 + 1 (for Pack Tactics) = 5

Defensive CR: 1/8
Offensive CR: 1
Average CR: 0.625 rounded = 1/2

### Wight (MM CR: 3, calculated CR: 2)

HP: 45 x 2 (for damage resistances) = 90
AC: 14
Damage per round: 2 x 6 (longsword) = 12
Attack bonus: 4

Defensive CR: 2
Offensive CR: 1
Average CR: 1.5 rounded = 2

### Planetar (MM CR: 16, calculated CR: 15)

HP: 200 x 1.25 (for damage resistances) = 250
AC: 19 + 2 (magic resistance) + 2 (3 saving throws) = 23
Damage per round: 2 x 43 (angelic greatsword) = 86
Attack bonus: 12

Defensive CR: 12 + 3 (adjust for AC) = 15
Offensive CR: 13 + 2 (adjust for attack) = 15
Average CR: 15

## Understanding the difference of branch between SVN and Git

I am a user of SVN and now I am learning Git.

In SVN I usually checkout on my local machine a repo, which includes all branches in my project and I used to select the folder for my branch I am interested to and work there.

I see a difference using Git.

Currently I am cloning a repo and clone a specific branch using gitk.

The project folder contains only the content for that branch and I cannot see all branches as in SVN, which is a little confusing for me.

I cannot find an easy way to see all branches in my local repository using Git.

• I would like to know if the Git process I described is “standard” and some how correct or I am missing something.

• Also I would like to know how to handle a process where I need to work on two branches at the same time in case, for example, I need to make an hotfix on master but keep the content of another branch too.

• What is a recommend name conventions to make the folders which include the branch cloned from the repo in Git, example myproject-branchname?

## How to Even Begin Understanding the Underworld’s Geography/Cosmology?

Each time I get curious about WtO and try reading about parts of its setting, I hit a lot of crosslinks but am having trouble envisioning the basic zoomed-out geography and how they all relate to each other. Maybe I’m missing some sort of cosmological assumption and don’t know how to ask about it because it’s an unknown unknown.

Sometimes I encounter writings that give an impression that some of these locations are ‘stacked’ in the three spatial dimensions but vary by a fourth spatial dimension coordinate, and at other times I have an impression they’re meant to be navigable by spatially-3D beings; which one is it? How exactly does a Wraith move from the ‘normal’ world where it can possess computers and scare mortals to the ‘esoteric’ one with maelstroms and kingdoms? What are the connecting paths or ‘paths’ like?

I am also unsure about whether some geographical terms are meant to be parsed mostly literally, or very metaphorically (e.g. whether ‘river’ with ‘shores’ refers to a watery path surrounded by solid ground, or is more like a current, and whether the Tempest is meant to be visualised as a literal water in which one may swim or drown).

## Not understanding how to include libraries in the source code [on hold]

I’m working on a music visualizer script in python. I’m using an audio library called aubio. If I upload my code on a website like Github how can I make the script available for everyone? Do I have to include the library in the code? Do I have just to explain in the readme that the library is required or adding directly the source code would be a solution? I’m really sorry for the trivial question but I’ve only worked on personal project and I don’t know the best way to make my code available to the public

## Understanding how to pass List Items to a “Print Page”

Trying to take a Display Page from a SharePoint list item and make it customized formatted print page.

New to SharePoint and totally doing all my coding in JavaScript (can’t use VS or SP Designer). Is it possible to do this?

I’ve been searching on here and can’t find a way to do it (or not knowing what to look for).

Currently the Printed Page preview basically looks like a the Display page that unnecessarily goes to a 2nd page.

Sorry if this question is too basic. Thanks.

I am just a newbie in the NLP field. Recently I came across the concepts like Attention and Transformer architecture. After studying the papers and many blogs, I understood the concepts. But recently one doubt is coming in my mind and that is related to Multi-headed attention. In Multi-headed attention, there are different query, key and value layers (dense layers). In some blogs I have seen some illustrations which show that different heads learn to apply attention on different parts of a sentence(I am mainly concerned about attention in text data). My question is, initially the weights of all dense layers are initialized randomly. So how does this mechanism ensure that different heads learn to apply different attention? Isn’t it more obvious that during applying back propagation , all heads will learn same thing, failing to satisfy the main purpose of applying multiple heads?

## Still not understanding why the Knapsack Problem does NOT have a polynomial-time solution

All the explanations for why the $$O(nW)$$ DP algorithm that solves the Knapsack Problem is NOT polynomial repeat the same thing: it is the length (in bits) of the input that matters, not its value/magnitude. The solution has the following structure:

# some preprocessing for i in range(n):     for w in range(W):         # compute stuff 

They repeat the same example: $$W=10_2=2$$, but $$W=100_2=4$$, i.e. every extra bit doubles the length of $$W$$. Here’s my confusion

• Why can’t I apply the same logic for $$n$$?

## Understanding Google Play Store Search censorship

I have an App in the Play Store called ‘Sexgame’ with a light sexual theme:

Unfortunately, the app cannot be found in the Play Store when searching for ‘sexgame’. Even when scrolling down a lot, it simply doesn’t show up. This has been tested by various Android users in different countries.

I’ve contacted the support from Google hoping they would explain to me why, but only received a very vague answer:

I’ve investigated this matter and identified an issue that may impact your app’s eligibility for promotion on the Play Store.

In an answer to a followup question they bluntly refused to explain this any further:

Naturally, I would like to know what exactly it is that led to this situation in order to examine, whether or not I can change something to change this situation. I don’t understand, why Google decides to be non-transparent about their censorship rules.

Here are a few things I’ve considered so far:

The App’s name contains the word ‘sex’. I’ve temporarily (for two weeks or so) renamed the App to ‘Game of Love’, but it did not show up in the search results either when searching for ‘game of love’.

Another thing I can think of is that although the App itself does not contain any reference to alcohol, the App’s description mentions the possibility to play the game as a drinking game. Could this be the issue?

If I were to change the description removing the option to play the game as a drinking game, how would I trigger a re-evaluation? Maybe the renaming of the App had no effect, because it was never re-evaluated.

I’ve been very careful with the wording of the texts in the App and avoided words that could be considered offensive or vulgar. But maybe they simply don’t like the game itself. That would be something I cannot change. I doubt however, that they really test all Apps in this depth.

I am aware that this is a difficult question for which there might not be a straight answer. It will probably solicit some guessing. I hope however, that the importance of this question out weights this concern.

I was participating in a CTF and there was a SQL Injection challenge. There is a WordPress page with a vulnerable plugin parameter (let’s call the website https://vulnerable.com/), and the solution comes from leaking values from the database. Using SQLMAP, it quickly found the payload.

When visiting the page, there is a “N” seconds delay.

http://vulnerable.com/wp-admin/admin.php?action=dt_duplicate_post_as_draft&post=1 AND (SELECT 1749 FROM (SELECT(SLEEP(N)))nQtm) 

SQLMAP went on to solve the problem with ease. This left me feeling a little guilty though, because I do not really understand the payload. I tried changing it to the following, but no delay takes place.

No delay took place.

http://vulnerable.com/wp-admin/admin.php?action=dt_duplicate_post_as_draft&post=1 AND SELECT(SLEEP(N)) 

Could someone help me understand the nested SELECT statements, the number 1749 and the seemingly random string nQtm?, are these random?, why does the payload fail without nested SELECT statements?

## Understanding Gillman’s proof of the Chernoff bound for expander graphs

My question is about Claim 1 in the proof here: Gillman (1993). At the end of the proof, the author says:

The matrix product $$U^\top\sqrt{D^{-1}}(P+(\mathrm{e}^x-1)B(0)-\mu I)\sqrt{D}U$$, which is equal to $$(D’-\mu I)(I+(D’-\mu I)^{-1}(\mathrm{e}^x-1)D’U^\top D_A U)$$, is singular. Therefore,

\begin{align*} 1&\leq \lVert (D’-\mu I)^{-1}(\mathrm{e}^x-1)D’U^\top D_A U \rVert_2 \ &\leq \frac{1}{\mu-\lambda_2}(\mathrm{e}^x -1). \end{align*}

(The first inequality uses the continuity of the function $$\lambda_2(y)$$.)

I understand why the two expressions at the beginning are equal and I understand the second inequality, but I do not understand the first inequality and also why the matrix product is singular.

Let me provide the definitions so you can avoid reading the whole paper. There is a weighted undirected graph $$G=(V, E, w)$$ where $$w_{ij}=0$$ if $$\{i,j\}\notin E$$. Denote $$w_i:=\sum_j w_{ij}$$. Let $$P$$ denote the transition matrix, so $$P_{ij}:=\frac{w_{ij}}{w_i}$$. Denote by $$\lambda_2$$ the second largest eigenvalue of $$P$$ and by $$\epsilon:=1-\lambda_2$$ the spectral gap. Next, let $$M$$ be the weighted adjacency matrix $$M_{ij}:=w_{ij}$$. Let $$A$$ be a set of vertices and $$\chi_A$$ be an indicator function. Some more definitions are:

\begin{align*} &E_r:=\operatorname{diag}(\mathrm{e}^{r\chi_A}) & &P(r):=PE_r \ &D:=\operatorname{diag}(\frac{1}{w_i}) & &S:=\sqrt{D}M\sqrt{D} \ &S_r:=\sqrt{DE_r}M\sqrt{DE_r} & & B(r):=\frac{1}{\mathrm{e}-1}(P(r+1)-P(r)) \end{align*}

Moreover, since $$S$$ is unitarily diagonalizable, there exist a unitary matrix $$U$$ and a diagonal matrix $$D’$$ such that $$D’=U^\top SU$$. Furthermore, there exists a diagonal matrix $$D_A$$ such that $$B(0)=PD_A$$.

Define $$\lambda(r)$$ to be the largest eigenvalue of $$P(r)$$ and $$\lambda_2(r)$$ to be its second largest eigenvalue. As before, $$\epsilon_r := \lambda(r)-\lambda_2(r)$$ is the spectral gap.

In Claim 1 the author lets $$0\leq x\leq r$$ be some number. He also defines $$\mu<\lambda(x)$$ to be any other eigenvalue of $$P(x)$$. At the end of the proof, we are only interested in $$\mu>\lambda_2$$.

Some other facts are:

\begin{align*} &\lVert D’ \rVert_2 = \lVert D_A \rVert_2 = 1 & &D’=U^\top\sqrt{D^{-1}}P\sqrt{D}U \ &P(0)=P & &\lambda(0)=1 & &\lambda_2(0)=\lambda_2 \ &P=\sqrt{D}S\sqrt{D^{-1}} & &P(r)=\sqrt{DE_r^{-1}}S_r\sqrt{E_rD^{-1}} \end{align*}

I hope I didn’t miss anything relevant. Thank you for your help.