Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsDiscussion Forum → Computer Science and Math and Stuff
1234567891011121314151617181920212223242526272829303132333435
Computer Science and Math and Stuff
2018-04-02, 12:22 PM #641
Praise Jesus.
2018-04-02, 2:04 PM #642
actually, hail satan
I had a blog. It sucked.
2018-04-03, 10:59 AM #643
Originally posted by Reverend Jones:
As a kid we had the Grolier 1995 Multimedia Encyclopedia. When you opened the program, it played a cool little sound collage of famous things from history, including the "ask not..." bit from JFK.

A couple years later in middle school, we had to give a speech presentation on somebody we admired. I remembered how noble sounding that JFK line was, so I picked him.

Anyway, I won the class contest because my teacher was a big fan of JFK. However, I lost the next round to a girl who picked Jesus as the person she admired, because I actually had no reason at all for admiring JFK other than his speech sounding admirable, and when I told the judges this they weren't impressed.


How timely

2018-04-03, 8:07 PM #644
That's a great channel there you've been linking us to to.

The one about Google and Facebook is pretty timely again given the last few weeks of tech news.
2018-04-04, 7:49 PM #645
Originally posted by Reid:
Thanks. There is actually a sort of comfort in knowing that this is supposed to be as hard as it is.

As cheesy as it is, I'm also reminded of the JFK speech where he said we choose to go to the moon because it's hard.


Don't worry, you have lot's to look forward to after you complete your doctorate.
2018-04-04, 7:52 PM #646
Originally posted by Reverend Jones:


all those paths are homotopic
2018-04-04, 8:06 PM #647
Originally posted by Reid:
all those paths are homotopic


That's true. But since the moment of your birth has passed, I am afraid your chances of ever becoming a 1st round NFL draft pick with a $100 million contract and Nike endorsement deal are slim to none.

But hey, it's quantum mechanics, so maybe?
2018-04-05, 4:20 AM #648
Originally posted by Reverend Jones:
That's true. But since the moment of your birth has passed, I am afraid your chances of ever becoming a 1st round NFL draft pick with a $100 million contract and Nike endorsement deal are slim to none.

But hey, it's quantum mechanics, so maybe?


I guess there should be some holes in the graph, representing places where one path can't be slid into another.
2018-04-05, 8:55 AM #649
Originally posted by Reid:
I guess there should be some holes in the graph, representing places where one path can't be slid into another.


What you are calling a 'hole' is just a particular segment of a path that contributes nothing (wait, can I say this? We're talking about superposition and complex probability amplitudes...) to the integral.

Quote:
Consider a trajectory x(t) between an initial point (x0,t0) and possible future point (x′,t′). Let the transition probability amplitude〈ψ(x,t)|ψ(x0,t0)〉be the inner product of the wavefunction in the Schrödinger picture of the particle evaluated at these two points. Feynman hinted at the “equivalence” of the probability amplitude and the exponent of the classical action of the trajectory exp [iS[x(t)]/ħ], where “equivalence” is not yet well-defined. It was not until 1948 that Feynman, as a post-doctoral student at Princeton, formalized this connection.

In his landmark paper [4], Feynman presented a formulation of quantum mechanics based on this principle. Let a given trajectory x(t) be associated with a transition probability amplitude with the same form as that given by Dirac. Of course, by quantum mechanics, we cannot speak of the particle taking any well-defined trajectory between two points (x0,t0) and (x′,t′). Instead, we can only speak of the probability of finding the particle at these locations, which is related to wavefunctions |ψ(x0,0)〉and |ψ(x′,t′)〉. That is, all that can be determined is the relative probability of the particle taking one path or another.

Feynman’s insight was this - the total transition probability amplitude can be obtained by summing the amplitudes of the particle having taken any individual path. If the quantity〈ψ(x′,t′)|ψ(x0,t0)〉can be calculated in the method suggestedby Feynman, the time-evolution of the state can be determined by considering contributions from all possible future states, and the problem is solved.


http://web.mit.edu/dvp/www/Work/8.06/dvp-8.06-paper.pdf
2018-04-05, 10:22 AM #650
Or something like that. I am almost certain that what I wrote was wrong, but I am fairly confident it is less wrong than what Reid wrote.
2018-04-05, 5:44 PM #651
in the complex plane closed line integrals are 0, which means any two homotopic paths produce the same integral. if the paths go around a singularity (fancy hole), then they'll be different. i have no idea if that's way different when dealing with quantum path integrals. apparently those are integrals over functionals, and i have no idea how they work.
2018-04-05, 7:05 PM #652
I really doubt that much of that applies here...
2018-04-06, 12:13 PM #653
i don't think the residue theorem is really applicable for this, otherwise you'd be able to make statements that multiple paths to the same point should contribute the same quantity to the integrand (since inverting one of the paths would close the loop), which is obviously not true. so long as your hamiltonian is well behaved you shouldn't have any singularities anyway.
I had a blog. It sucked.
2018-04-06, 12:16 PM #654
but as someone who has never actually studied QFT (or the path integral formulation of QM; i am a huge disappointment to RPF) i'm mostly talking out of my ass
I had a blog. It sucked.
2018-04-06, 1:23 PM #655
Originally posted by Zloc_Vergo:
i don't think the residue theorem is really applicable for this, otherwise you'd be able to make statements that multiple paths to the same point should contribute the same quantity to the integrand (since inverting one of the paths would close the loop), which is obviously not true. so long as your hamiltonian is well behaved you shouldn't have any singularities anyway.


maybe i wasn't clear, i was explaining my thought process. i don't know anything about the path integral formulation of quantum or if any of that applies. my original post may have been wrong.
2018-04-06, 1:27 PM #656
To be honest, I didn't even notice the integral in the bottom corner. Lol
2018-04-06, 1:33 PM #657
and i was trying to shed light on why the residue theorem isn't the right tool to go to here, not give you **** for not understanding the formulation/approaching it in a way that's not typically used
I had a blog. It sucked.
2018-04-06, 1:44 PM #658
Thank you for taking the time to explain
2018-04-06, 1:48 PM #659
Mathematicians and physicists tend to let their terminology conflict. (For example, I believe that the two professions talk of different subjects when referring to "group theory".)

Like a lot of arguments on this board this one probably comes down to language. AFAIK, path integral formulation of quantum mechanics ≠ integrating along a path in general.

[quote=Wikipedia article on Path integral formulation]This article is about a formulation of quantum mechanics. For integrals along a path, also known as line or contour integrals, see line integral.[/quote]

2018-04-06, 1:51 PM #660
This may result from physicists often getting by on intuition rather than consulting mathematicians to ensure that they have accumulated all the proper definitions that subsume the things they are talking about into settled language.

Of course once in a while the reverse happens, when a mathematician encounters a physicist and interprets his language literally in a technical sense, and al hell breaks loose.
2018-04-06, 1:57 PM #661
In other news, I'm trying to use reinforcement learning to reproduce the Bloch decomposition of single qubit unitaries using policy gradient methods. This is a simple problem that an undergrad who's good at RL should be able to do.

Essentially, you're given a 2x2 (special) unitary matrix (i.e. Det(U) = 1), and you want to decompose it into a sequence of simpler 2x2 unitaries that you have access to. In this case, we have access to the following unitaries: R_\Phi(\theta_i) where \Phi is either Z or Y (Pauli matrices), and \theta_i are the angles of rotation. R_\Phi(theta) = exp(-i\theta/2*\Phi). The Bloch decomposition is a sequence of rotations Z, Y, Z by different angles that can reproduce any 2x2 U. Using RL, I want to be able to observe the target unitary and recover the Bloch decomposition (either ZYZ, or YZY, and the correct sequence \theta_i).

The Policy Gradient Theorem gives a nice expression for the loss you use in order to train your policy (in my case, a neural net (NN)), and the REINFORCE algorithm tells you when/how to adjust the neural net. Using a slight modification, REINFORCE with Baseline, you actually train two NNs, one to predict your next move, and one to tell you the "value" of the state that you're currently in (state being the collection of observations about the state of the system, in this case the preceding moves I made and the target unitary, which are sufficient knowledge for the Bloch decomposition). With baseline, you train your NN not just to try to maximize the probability of whatever move it decides to take, but you modulate this slightly to weight it such that the closer your observed rewards are to your baseline's representation of what that NN expects the reward to be, the less you need to adjust your weights. The baseline NN should hopefully converge faster to a good representation of how "good" the choices you've made so far are, and this helps push your policy NN to make better and better decisions.

The problem is that the policy gradient loss is a fickle ***** that seems highly unstable. I have tested that I can train the baseline to reproduce the right values if I feed in the correct sequence of moves, so I know that my baseline NN works. However, when I let the policy loose (a NN which determines the mean of Gaussian that I sample to choose the angles, and another NN with Softmax to determine whether I do Z or Y rotations) it chooses really bizarre moves, that produce really ****ty losses, which it then attempts to minimize. The loss doesn't seem to follow any sort of a trend plotted over time (in fact, usually it ends up increasing :wtf:) and there's a ton of noise on the values chosen.

Occasionally the NN will get lucky and make a very efficient sequence of moves leading to a highly optimal loss, which I would anticipate yielding little adjustment of the NN. However, the next iteration usually ****s up whatever weights the NN had before and I'm back to a poor NN. I've tried tuning learning rates to slow down the convergence/reduce the impact of large gradients, I've tried clipping gradients, I've tried reducing the problem to a simple 1 step rotation (basically a 1D optimization problem) and can't get the damn thing to work. I believe there's something fundamentally wrong with my implementation, but the last 48 hours of coding have turned up nothing.
I had a blog. It sucked.
2018-04-06, 2:00 PM #662
ultimately I want to take RL and apply it to ion trap quantum computing control problems, but those are continuous-time and much more complicated in terms of the simulation you need to plug in for the environment. This is a simple, discrete problem with an analytic solution that I can't reproduce, and it's really disheartening.
I had a blog. It sucked.
2018-04-07, 8:00 PM #663
Originally posted by Zloc_Vergo:
Essentially, you're given a 2x2 (special) unitary matrix (i.e. Det(U) = 1), and you want to decompose it into a sequence of simpler 2x2 unitaries that you have access to. In this case, we have access to the following unitaries: R_\Phi(\theta_i) where \Phi is either Z or Y (Pauli matrices), and \theta_i are the angles of rotation. R_\Phi(theta) = exp(-i\theta/2*\Phi). The Bloch decomposition is a sequence of rotations Z, Y, Z by different angles that can reproduce any 2x2 U. Using RL, I want to be able to observe the target unitary and recover the Bloch decomposition (either ZYZ, or YZY, and the correct sequence \theta_i).


So, if I'm reading this right, your goal is to creating sums of three power series, using Pauli matrices as a basis, which sum to any 2x2 matrix in SL(2,C)? -i\theta/2 is just a scalar?
2018-04-09, 2:46 PM #664
We're creating products of the power series, rather than sums (since unitarity is preserved under products of matrices), but that appears to be correct. I'm not familiar with the SL(2,C) notation, but it looks like it's describing the same set as SU(2), so yeah. \theta is a scalar from 0 to 2\pi.

The more typical interpretation here is that 2x2 unitaries are used to describe rotations on a sphere, and X/Y/Z are the axes of rotation, and \theta is the angle of rotation about that axis. We want to decompose an arbitrary rotation about an arbitrary axis into a sequence of rotations about the Z axis, then the Y, then the Z again.

E- this looks like an alright description of what I'm talking about, page 10 is when this comes up http://www.vcpc.univie.ac.at/~ian/hotlist/qc/talks/bloch-sphere-rotations.pdf
I had a blog. It sucked.
2018-04-09, 3:01 PM #665
Honestly I'm just glad you guys use unitary matrices, and not unit quaternions.
2018-04-09, 3:17 PM #666
luckily QM has been very linear algebra heavy from the beginning, so the matrices arise out of Hamiltonian representation and then the rotations are the abstract approach. the physics of the two level system predate thinking about operations on the two level system as rotations, so we get nice matrix algebra to work with
I had a blog. It sucked.
2018-04-09, 3:21 PM #667
also i just found out i get to TA a probability class this fall instead of the same circuits class for a fifth semester in a row. i am unbelievably happy with this change because i no longer have to debug undergraduate circuits, and the teaching circuit theory part of this class has been the part i enjoyed. this fall i get legitimate teaching/tutorial session responsibilities, and i don't have to turn knobs on oscilloscopes for undergrads.
I had a blog. It sucked.
2018-04-12, 1:34 AM #668
Originally posted by Zloc_Vergo:
We're creating products of the power series, rather than sums (since unitarity is preserved under products of matrices), but that appears to be correct.


Got it, yeah. So is your software then attempting to calculate the coefficients of the power series?

I'm trying to figure out why this isn't just solvable. A few series and a product of matrices doesn't sound a priori like the kind of thing that would need machine learning to solve, so I'm not sure why this approach is necessary.

Originally posted by Zloc_Vergo:
I'm not familiar with the SL(2,C) notation, but it looks like it's describing the same set as SU(2), so yeah. \theta is a scalar from 0 to 2\pi.


SL(2,C) is the special linear (determinant 1) group of 2x2, complex-valued matrices. I wasn't sure if SU(2) was just the physicist name for SL(2,C), but apparently they're different, namely SU(2) is properly contained in SL(2,C). SU(2) are all 2x2 complex-value matrices which are also antihermitian.

Originally posted by Zloc_Vergo:
The more typical interpretation here is that 2x2 unitaries are used to describe rotations on a sphere, and X/Y/Z are the axes of rotation, and \theta is the angle of rotation about that axis. We want to decompose an arbitrary rotation about an arbitrary axis into a sequence of rotations about the Z axis, then the Y, then the Z again.

E- this looks like an alright description of what I'm talking about, page 10 is when this comes up http://www.vcpc.univie.ac.at/~ian/hotlist/qc/talks/bloch-sphere-rotations.pdf


So I tried multiplying those matrices out arbitrarily, and came up with 4 equations and 3 unknowns. I feel like it shouldn't be too hard to solve that..? What piece am I missing
2018-04-12, 10:08 AM #669
It's analytically solvable; the solution is known. This is a toy problem of trying to reproduce the analytic solution with reinforcement learning to make sure that I can make the RL method work. There's no new science happening here.

I think I finally got it (mostly) working just now, so it's time to clean up my Python notebook and write it up over the next day or so.
I had a blog. It sucked.
2018-04-14, 12:37 AM #670
Originally posted by Zloc_Vergo:
It's analytically solvable; the solution is known. This is a toy problem of trying to reproduce the analytic solution with reinforcement learning to make sure that I can make the RL method work. There's no new science happening here.

I think I finally got it (mostly) working just now, so it's time to clean up my Python notebook and write it up over the next day or so.


I see I see, this is about you playing around with mahine learning tools on a problem you understand. Is RL easy to pick up? I've been writing more complex botting software at times and I'd be curious to try it on card games where statistics and weighing card value is a heavy part of doing well.
2018-04-14, 12:48 AM #671
Also, read the essay "Computing Machinery and Intelligence" by Alan Turing, thought it was an insightful and well-written essay, and made me remember just how poor I think most popular science discussion really is.

Well, I say science loosely, because the essay is actually philosophical, and also speaks in a way that modern AI enthusiasts would think is too pessimistic.

Turing asks: "can machines think?" He says well, the only way it even makes sense to answer that is to find out if people want to use the word that way. If people want to call what machines do thinking, then they think, just like how we say planes fly, it has nothing to do with any sort of relationship to flying, but persists as a kind of metaphor.

But the notion that computers think in any way like a human can, he dismisses as an obvious absurdity.

When he elucidates what he thinks the imitation game will lead to, he thinks eventually we will come up with a chat bot that can trick people who speak to it for less than 5 minutes 30% of the time. Which is an ironic figure because it's something I said myself once about the Turing test, that it's more a question of how long can a computer fool youmore than anything, but I guess I shouldn't exect myself ever to be a smidge more clever than a man like Turing.

I think though that I want to metaphorically punch every person in the face who ever speaks about the Turing test as some kind of proof of machine intelligence. And now I also have a much deeper respect for Alan Turing than I already had.
2018-04-14, 1:01 AM #672
Though I have to say, Turing's prediction was probably too optimistic. A chat bot that can deceive someone after 5 minutes? Lol, show me that chat bot.
2018-04-14, 3:51 PM #673
I was thinking a bit more about computer intelligence, and I think I found a phrase that I think is more fitting.

When we speak of computers being intelligent, I think it's pretty much obvious, and I think most would agree, that the strongest type of strong AI cannot exist. I don't think we mean intelligent by any comparison of how humans think to how computers "think".

So what measure do we really want? I think what we're looking for is more "intelligible".

Now, computers can be made trivially intelligible. You can have a computer display the works of Shakespeare, that output is intelligible.

So I think what we mean is not just intelligible, but intelligible and novel. We want the computer to produce intelligible and new things.

However, we can already do this. You can have a computer simply pair a bunch of words together at random, and over a long enough time, it will generate new sentences that are intelligible. So moreoever, we don't just want intelligible and novel. We also want consistency.

When people discuss AI, I think this is what they mean: a program that produces new, consistent, and intelligible output.

Now, will we ever have that? You could say, "computers can invent new chess moves", for instance. But I don't think the way computers play chess is in any way novel. Rather, it's even something a human could do. For instance, you could make a chess game last many years, between each move give a human being a year to calculate all possible moves, and compare that to a massive record of professional games, figure out which further move produces the highest probability of winning, and boom, your algorithm is run by a human in the exact same way a computer does. The only real difference is a computer can do this very quickly. So I don't think the novelty is very novel, it's more just unexpected outputs. But even unexpected outputs aren't new. But I still believe that, even though you run the same dumb statistical analysis on food, the fact your algorithm is produced a crappy sauce in the same way it played a chess game isn't particularly novel, a human could have run that same algorithm and get the same unexpected output.

Neural nets are advancing computer intelligence by making outputs more intelligible. But I think the actual application of neural nets that matters, can't produce new results, or if it produces new results it's trading off for consistency. If maximizing all three at once is even possible, we are still a ways out I feel.
2018-04-14, 5:04 PM #674
The advantage, though, is labor-saving. I don't think computer learning would be an improvement over doctors in, say, diagnosing cancer, if doctors were given arbitrarily long amounts of time to analyze the X-rays, had a large database previous X-rays to compare to.

I would *expect* - and maybe this is wrong, but this is my suspicion, that in a setting with enough time, data and motivation, a doctor could achieve the same correct diagnoses rate as a machine learning algorithm. In other words, more mistakes are made due to exhaustion, stress, shortness of time than necessarily by the intrinsic ability of humans to make the judgments. But hiring that many doctors with that much free time is really impractical, so machine learning becomes a really good substitute for these kinds of decision making processes.
2018-04-14, 5:13 PM #675
I guess I just fail to see how computers are ever going to produce intelligible results that aren't just iterating a basic process really fast, with any "novel" results being things that just involved too much computation for humans to attempt in reasonable time frames. With machine learning we've basically automated statistics. That's cool in its own right, but I don't think it adds up to a real comparison of human intelligence.
2018-04-14, 9:53 PM #676
[https://i.imgur.com/IQWaMER.png]

I swear it's not as complicated as it looks!
2018-04-14, 11:16 PM #677
Originally posted by Reid:
I guess I just fail to see how computers are ever going to produce intelligible results that aren't just iterating a basic process really fast, with any "novel" results being things that just involved too much computation for humans to attempt in reasonable time frames. With machine learning we've basically automated statistics. That's cool in its own right, but I don't think it adds up to a real comparison of human intelligence.


What matters is what it's connected to. You mention that computers can "iterate fast", but this is just another way of saying that they aren't exposed to a very wide environment to adapt to.

For example, you brought up the notion that humans don't have the computational power that computers do.

Well, actually our bodies do. It's just not accessible to "you".
2018-04-14, 11:25 PM #678
Originally posted by Reid:
Neural nets are advancing computer intelligence by making outputs more intelligible.


I was under the impression that deep neural networks were famously opaque.

Quote:
In order for machine learning to be deployed and trusted in many applications, it is crucial to be able to reliably explain why the machine learning algorithm makes certain predictions. For example, if an algorithm classifies a given pathology image to be a malignant tumor, then the doctor may need to know which parts of the image led the algorithm to this classification. How to interpret black-box predictors is thus an important and active area of research. A fundamental question is: how much can we trust the interpretation itself? In this paper, we show that interpretation of deep learning predictions is extremely fragile in the following sense: two perceptively indistinguishable inputs with the same predicted label can be assigned very different interpretations. We systematically characterize the fragility of several widely-used feature-importance interpretation methods (saliency maps, integrated gradient, and DeepLIFT) on ImageNet and CIFAR-10. Our experiments show that even small random perturbation can change the feature importance and new systematic perturbations can lead to dramatically different interpretations without changing the label. We extend these results to show that interpretations based on exemplars (e.g. influence functions) are similarly fragile. Our analysis of the geometry of the Hessian matrix gives insight on why fragility could be a fundamental challenge to the current interpretation approaches.


https://arxiv.org/pdf/1710.10547.pdf
2018-04-14, 11:28 PM #679
Originally posted by Reverend Jones:
For example, you brought up the notion that humans don't have the computational power that computers do.

Well, actually our bodies do. It's just not accessible to "you".


(look inside a cell sometime)
2018-04-14, 11:28 PM #680
Originally posted by Reverend Jones:
What matters is what it's connected to. You mention that computers can "iterate fast", but this is just another way of saying that they aren't exposed to a very wide environment to adapt to.

For example, you brought up the notion that humans don't have the computational power that computers do.

Well, actually our bodies do. It's just not accessible to "you".


Maybe we could say "computational power available for directed tasks" or something or other.
1234567891011121314151617181920212223242526272829303132333435

↑ Up to the top!