Inputting a function into frameticks with ArrayPlot

Here’s some data:


Here’s the data plotted:


enter image description here

I want to modify the frame ticks such that the horizontal axis is {Sin[2],Sin[3],Sin[4]} and the vertical axis is {0.3,0.6,0.9}. How can I do this?

The documentation on FrameTicks suggests that I should define a function and input that. However, I can’t parse the example given. What are the arguments passed to the function when used in this way? Naively I’d guess that it’s just the index of the x- and y- arrays (so e.g. {1,1} would be the top-left box), but attempting to write my own function, e.g. with xaxis[min_,max_]:=min+1 and yaxis[min_,max_]:=min+2, doesn’t work. ArrayPlot[data,FrameTicks->{xaxis,yaxis}] leads to an ArrayPlot with no frame ticks.

How do I see the incoming traffic into my VM during the Nmap scan? [closed]

I’m testing this decoy feature from nmap, and pretend to be a bad guy. I will run it against my owned VM.

sudo nmap -sS -sV -D,, 

If I SSH into my server, wow do I see the incoming traffic into my VM (Ubuntu) during the Nmap scan ?

I’ve tried netstat -plant, and iftop, not so good.

Select into query, insert fails, but the table is created

I am using SQL Server 2016

I tried to the following query.

SELECT CONVERT(BIGINT, ‘A’) col1 INTO #tmp This query is obviously in error. Because it does not convert. However, the temporary table (#tmp) is created even if the query fails.

Why? I think this is by design, but I want to know.

P.S. PDW (parallel datawarehouse) does not create temporary table.

Why do b*trees partition 2 nodes into 3?

I’m writing a b*tree library in Rust. I’m thinking it might be better to make the purposeful decision to only implement half of the b* optimizations. (And not because it is easier, although it is.)

According to my reading B* is 2 optimizations (for insertion anyway):

  1. If a node is full but a sibling has free space, move something over to the sibling before adding, then no recursion is necessary. With circular buffers this is really fast.
  2. If a node is full and has a full sibling, split them into 3 nodes, distribute the existing elements as 2/3 2/3 2/3 among them.

Without the rule 2 optimization, when a node is full, it is just split into 2 nodes with a 1/2 1/2 distribution between them.

I see how theoretically rule 2 is interesting, it guarantees that every node in the tree is always 2/3 full (except for the root and for very small trees).

But for a downside, consider the use case where you usually add the nodes in order (for example, adding 1, 2, 3, 4, 5….mostly in order). When you keep rule 2 then the tree is almost always exactly 2/3 full and no better; because, after the sibling gets it allotted 2/3, it is never looked at again. But without rule 2, the tree (at least the leaves anyway) is nearly 100% full all the time. Because the last node which is full gets split into 2 nodes, they each get 1/2 of the elements, and the previous sibling remains full and untouched. On the subsequent insertions, due to rule 1, the last 2 nodes fill up to be 100% full again before splitting.

And about the case with random order insertions, with rule 1 and without rule 2, the worse case scenario (I think really rare and difficult to construct) is a 50% fill rate and the best case is still the 100% fill rate. The average I would guess is still the same as with rule 2, since the tree is still usually between 2/3 and 100% full.

For a tree with large nodes (approaching page size), a possible problem would be increasing the number of page loads because of the need to check siblings. But it seems to me that even though rule 2 reduces the variance in the density of the tree, it doesn’t do much to actually increase the absolute density of the tree, that is moreso accomplished by rule 1. So I would expect the average number of page accesses to be about the same or probably less.

Can someone give me a good reason to keep rule 2 when inserting into a B* Tree?

Deep learning: how to represent 24 fraction image into 1 image?

Goal: Represent 24 fractions images into one image. These 24 fractions belong to one patient. We want to represent one patient with one image. How to manipulate the data to achieve it: (T.A. suggested to divide the picture in 100 key parts with crucial data and merge only those key parts)

My Take on this: I have tried HOG and SIFT(Scale-Invariant Feature Transform)enter image description here algorithm and as you can see the HOG results in Black and white output picture as attached and the colorful picture is the SIFT output. The problem with this is that: The output image does not distinguish the red (cancer) and blue (non-cancer).i.e the color changes.

My Question: I am still learning Deep learning as I go along. Please excuse the naive questions. What are the steps necessary to represent 24 fraction images (red-blue dotted ones) into one image? without changing the colors? enter image description here

Does Heat Metal works with Descent Into Avernus vehicles?

As the title says, I’d like to know if I can use Heat Metal spell in Descent Into Avernus module and target a vehicle.

And more specifically, what happens about that part of the spell:

If a creature is holding or wearing the object and takes the damage from it, the creature must succeed on a Constitution saving throw or drop the object if it can.

What happens to the passengers?
Can the pilot continue to pilot?

For Ring of Shooting Stars, can Ball Lightning affect a creature when you move it into their space?

The Ring of Shooting Stars has the following feature (emphasis mine):

Ball Lightning.

You can expend 2 charges as an action to create one to four 3-foot-diameter spheres of lightning. The more spheres you create, the less powerful each sphere is individually.

Each sphere appears in an unoccupied space you can see within 120 feet of you. The spheres last as long as you concentrate (as if concentrating on a spell), up to 1 minute. Each sphere sheds dim light in a 30-foot radius.

As a bonus action, you can move each sphere up to 30 feet, but no farther than 120 feet away from you. When a creature other than you comes within 5 feet of a sphere, the sphere discharges lightning at that creature and disappears. That creature must make a DC 15 Dexterity saving throw. On a failed save, the creature takes lightning damage based on the number of spheres you created. (4 spheres = 2d4, 3 spheres = 2d6, 2 spheres = 5d4, 1 sphere = 4d12)

Does this mean that the sphere discharges lightning whether you move it within 5 feet of a creature or whether a creature moves within 5 feet of it?

What happens if you move it within 5 feet of multiple creatures at once (or multiple creatures move within 5 feet of it at once)?

When importing a rig into blender, the gun object’s transform and rotation are messed up

enter image description here

I have tried applying rotation and fixing origins but nothing is working. I have heard certain methods for fixing this involving importing the object as an fbx file into unity rather than just saving the blender file directly in unity, but I would really prefer not to do this as I want the advantage of realtime editing in blender, I have still not finished all of my animations

How to turn SELECT statement into a DELETE statement

I’m trying to turn this select statement into a delete statement and I’m struggling to not delete all the records in the table. Here is the select statement I’m using ->

"SELECT * FROM message_cus_board mcb where mcb.board_id IN (select mb.board_id FROM message_boards mb WHERE mb.customer_id = :customerid AND mb.universal_board = 'Y') ORDER BY mcb.created_on DESC" 

This queries all of the messages from the message_cus_board table and basically I want to delete all of the messages this would normally display except the last 15. One thing I’ve tried is taking all of those message_id’s and making an array of the most recent 15 then creating a delete statement with those id’s like so ->

"DELETE FROM message_cus_board WHERE message_id NOT IN ($  string_of_ids)" 

The only issue is that this delete query gets rid of ALL other messages, not just the ones associated with the right customer. I’m struggling to create a delete query that limits the delete to the right customer using similar logic to the select statement above. Thanks for any help!